增加web端产品库模块,并增加埋点
This commit is contained in:
@@ -2,6 +2,7 @@ import store from "../store";
|
||||
import {waiting} from "../utils";
|
||||
import appEntry from "../views/apps/appEntry";
|
||||
import router from "./router";
|
||||
import axios from "./axios";
|
||||
|
||||
export default {
|
||||
routes: () => store.state.apps,
|
||||
@@ -29,6 +30,13 @@ export default {
|
||||
//命名规范入口文件必须以App开头
|
||||
return store.commit("addApp", addApp)
|
||||
} else return 0
|
||||
}))).then(() => waiting.close())
|
||||
}))).then(() => {
|
||||
axios.post("/node/wechatapps/addOrUpdate", {
|
||||
list: this.routes().map(({path: libPath, label, module: {name}, name: id}) => ({
|
||||
id, type: 'web', libPath, label, name
|
||||
}))
|
||||
}, {baseURL: "/ns"}).catch(() => 0)
|
||||
waiting.close()
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user