shopAdd.js
1.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
module.exports = function (app){
app.get("/supplier/store/index", "shop.Index", function (req,res){
this.$extend={
moduleName:"店铺管理",
pageName:"店铺创建",
add:true,
gridurl:'/supplier/shop/indexPage',
authority:'{"btn":false,"info":"info","create":true,"operationStatus":1,"checkStatusArr":"100,200,900"}'
};
});
app.get("/supplier/store/add", "shop.Edit", function () {
this.$extend={
moduleName:"店铺管理",
pageName:"店铺创建",
editTitle:"创建新店铺",
action:'/store/add',
data:{shopId:0}
}
});
app.get("/supplier/store/update/:shopsId", "shop.Edit", "shopAdd_getShopDetailById", function (rs,req,res){
this.$extend={
moduleName:"店铺管理",
pageName:"店铺编辑",
editTitle:"编辑店铺信息",
action:'/store/update',
data:rs.data
}
});
app.get("/supplier/store/info/:shopsId", "shop.Info", "shopAdd_getShopDetailById", function (rs,req,res){
this.$extend={
moduleName:"店铺管理",
pageName:"店铺详情",
backhref:'/supplier/store/index',
data:rs.data
}
});
//添加店铺
app.post("/store/add","shopAdd_addShops");
}