Skip to content

Commit

Permalink
修改路径
Browse files Browse the repository at this point in the history
  • Loading branch information
zhongshaofa committed Aug 18, 2019
1 parent dd52205 commit b1f2464
Show file tree
Hide file tree
Showing 16 changed files with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions js/lay-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,13 @@
* description:此处放layui自定义扩展
*/

window.rootPath = (function () {
var curWwwPath = window.document.location.href,
pathName = window.document.location.pathname;
var localhostPaht = curWwwPath.substring(0, curWwwPath.indexOf(pathName)),
projectName = pathName.substring(0, pathName.substr(1).indexOf('/') + 1);
return localhostPaht + projectName;
window.rootPath = (function (src) {
src = document.scripts[document.scripts.length - 1].src;
return src.substring(0, src.lastIndexOf("/") + 1);
})();

layui.config({
base: rootPath + "/lib/lay-module/",
base: rootPath + "lay-module/",
version: true
}).extend({
layuimini: "layuimini/layuimini", // layuimini扩展
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit b1f2464

Please sign in to comment.