Authored by dongjunjie

Merge branch 'master' into yohobuy_portak_dev_v4.8_20160620

@@ -24,26 +24,31 @@ module.exports = { @@ -24,26 +24,31 @@ module.exports = {
24 } else { 24 } else {
25 var data = {}; 25 var data = {};
26 data.list = []; 26 data.list = [];
27 - body = JSON.parse(body);  
28 - var dataList = body.data.product_list;  
29 - var goodslist = [];  
30 - var goodslist1 = [];  
31 - for (var m = 0; m < dataList.length; m++) {  
32 - if (dataList[m].goods_list && dataList[m].goods_list.length != 0) {  
33 - for (var n = 0; n < dataList[m].goods_list.length; n++) {  
34 - goodslist.push({a: dataList[m], b: dataList[m].goods_list[n]}) 27 + try{
  28 + body = JSON.parse(body);
  29 + var dataList = body.data.product_list;
  30 + var goodslist = [];
  31 + var goodslist1 = [];
  32 + for (var m = 0; m < dataList.length; m++) {
  33 + if (dataList[m].goods_list && dataList[m].goods_list.length != 0) {
  34 + for (var n = 0; n < dataList[m].goods_list.length; n++) {
  35 + goodslist.push({a: dataList[m], b: dataList[m].goods_list[n]})
  36 + }
  37 + } else {
  38 + goodslist.push({a: dataList[m], b: {}});
35 } 39 }
36 - } else {  
37 - goodslist.push({a: dataList[m], b: {}});  
38 } 40 }
  41 + for (var i = 0; i < goodslist.length; i++) {
  42 + goodslist1[i] = _.assign({}, goodslist[i].a, goodslist[i].b);
  43 + }
  44 + data.list = goodslist1.concat();//显示数据
  45 + data.page = body.data.page;//页码
  46 + data.totalPage = 1;//body.data.page_total;
  47 + data.nums = data.list.length;//记录每一页数据量
  48 + }catch(ex){
  49 + return callback(null, {data: data, code: 500});
39 } 50 }
40 - for (var i = 0; i < goodslist.length; i++) {  
41 - goodslist1[i] = _.assign({}, goodslist[i].a, goodslist[i].b);  
42 - }  
43 - data.list = goodslist1.concat();//显示数据  
44 - data.page = body.data.page;//页码  
45 - data.totalPage = 1;//body.data.page_total;  
46 - data.nums = data.list.length;//记录每一页数据量 51 +
47 return callback(null, {data: data, code: 200}); 52 return callback(null, {data: data, code: 200});
48 } 53 }
49 }); 54 });
@@ -4,11 +4,12 @@ @@ -4,11 +4,12 @@
4 <div> 4 <div>
5 <ul class="nav nav-pills" style="margin-bottom: 10px"> 5 <ul class="nav nav-pills" style="margin-bottom: 10px">
6 <li> 6 <li>
7 - <a class="tag" href="/goods/special/index" style="font-size: 14px;padding:10px">特殊商品</a> 7 + <a class="tag" href="/goods/special/index" style="font-size: 14px;padding:20px;color: black">特殊商品</a>
8 </li> 8 </li>
9 - <li class="active">  
10 - <a class="hand" href="javascript:void(0)" style="font-size: 14px;padding:10px">货到付款</a> 9 + <li>
  10 + <a class="hand active" href="javascript:void(0)" style="font-size: 14px;padding:20px;color: #428bca">货到付款</a>
11 </li> 11 </li>
  12 +
12 </ul> 13 </ul>
13 </div> 14 </div>
14 <div class="panel panel-default" style="margin-bottom:10px;"> 15 <div class="panel panel-default" style="margin-bottom:10px;">
@@ -6,73 +6,73 @@ @@ -6,73 +6,73 @@
6 module.exports=function(app) { 6 module.exports=function(app) {
7 7
8 /*活动模板首页*/ 8 /*活动模板首页*/
9 - app.get("/operations/activitytemplate/index","operations.activitytemplate.Index", function () {  
10 - this.$extend = {  
11 - moduleName: "活动模板管理",  
12 - pageName: "活动模板管理"  
13 - }  
14 - }); 9 + // app.get("/operations/activitytemplate/index","operations.activitytemplate.Index", function () {
  10 + // this.$extend = {
  11 + // moduleName: "活动模板管理",
  12 + // pageName: "活动模板管理"
  13 + // }
  14 + // });
15 15
16 - /*活动模板添加页*/  
17 - app.get("/operations/activitytemplate/add","operations.activitytemplate.Edit", "resourceManage_getUrlAction", function (response) {  
18 - this.$extend = {  
19 - moduleName: "活动模板管理",  
20 - pageName: "添加活动模板",  
21 - type: "add",  
22 - url: "/activityTemplate/addTemplate",  
23 - data: response.data  
24 - }  
25 - }); 16 + // /*活动模板添加页*/
  17 + // app.get("/operations/activitytemplate/add","operations.activitytemplate.Edit", "resourceManage_getUrlAction", function (response) {
  18 + // this.$extend = {
  19 + // moduleName: "活动模板管理",
  20 + // pageName: "添加活动模板",
  21 + // type: "add",
  22 + // url: "/activityTemplate/addTemplate",
  23 + // data: response.data
  24 + // }
  25 + // });
26 26
27 - /*活动模板编辑*/  
28 - app.get("/operations/activitytemplate/edit/:id","operations.activitytemplate.Edit","resourceManage_getUrlAction", function (response,req) {  
29 - this.$extend = {  
30 - moduleName: "活动模板管理",  
31 - pageName: "编辑活动模板",  
32 - type: "edit",  
33 - id: req.params.id,  
34 - url: "/activityTemplate/updateTemplate",  
35 - data: response.data  
36 - }  
37 - }); 27 + // /*活动模板编辑*/
  28 + // app.get("/operations/activitytemplate/edit/:id","operations.activitytemplate.Edit","resourceManage_getUrlAction", function (response,req) {
  29 + // this.$extend = {
  30 + // moduleName: "活动模板管理",
  31 + // pageName: "编辑活动模板",
  32 + // type: "edit",
  33 + // id: req.params.id,
  34 + // url: "/activityTemplate/updateTemplate",
  35 + // data: response.data
  36 + // }
  37 + // });
38 38
39 - /*活动模板编辑*/  
40 - app.get("/operations/activitytemplate/product/:id","operations.activitytemplate.Product", function (req) {  
41 - this.$extend = {  
42 - moduleName: "模板商品管理",  
43 - pageName: "模板商品管理",  
44 - id: req.params.id,  
45 - url: req.originalUrl  
46 - }  
47 - }); 39 + // /*活动模板编辑*/
  40 + // app.get("/operations/activitytemplate/product/:id","operations.activitytemplate.Product", function (req) {
  41 + // this.$extend = {
  42 + // moduleName: "模板商品管理",
  43 + // pageName: "模板商品管理",
  44 + // id: req.params.id,
  45 + // url: req.originalUrl
  46 + // }
  47 + // });
48 48
49 - /*查询模板列表接口*/  
50 - app.post("/activityTemplate/selectTemplateList","activitytemplate_selectTemplateList"); 49 + // /*查询模板列表接口*/
  50 + // app.post("/activityTemplate/selectTemplateList","activitytemplate_selectTemplateList");
51 51
52 - /*添加模板接口*/  
53 - app.post("/activityTemplate/addTemplate","activitytemplate_addTemplate"); 52 + // /*添加模板接口*/
  53 + // app.post("/activityTemplate/addTemplate","activitytemplate_addTemplate");
54 54
55 - /*获取单个模板接口*/  
56 - app.post("/activityTemplate/getTemplate","activitytemplate_getTemplate"); 55 + // /*获取单个模板接口*/
  56 + // app.post("/activityTemplate/getTemplate","activitytemplate_getTemplate");
57 57
58 - /*更新模板接口*/  
59 - app.post("/activityTemplate/updateTemplate","activitytemplate_updateTemplate"); 58 + // /*更新模板接口*/
  59 + // app.post("/activityTemplate/updateTemplate","activitytemplate_updateTemplate");
60 60
61 - /*开启模板接口*/  
62 - app.post("/activityTemplate/publishTemplate","activitytemplate_publishTemplate"); 61 + // /*开启模板接口*/
  62 + // app.post("/activityTemplate/publishTemplate","activitytemplate_publishTemplate");
63 63
64 - /*关闭模板接口*/  
65 - app.post("/activityTemplate/closeTemplate","activitytemplate_closeTemplate"); 64 + // /*关闭模板接口*/
  65 + // app.post("/activityTemplate/closeTemplate","activitytemplate_closeTemplate");
66 66
67 - /*根据条件查询活动商品列表接口*/  
68 - app.post("/activityTemplate/getProductListByCondition","activitytemplate_getProductListByCondition"); 67 + // /*根据条件查询活动商品列表接口*/
  68 + // app.post("/activityTemplate/getProductListByCondition","activitytemplate_getProductListByCondition");
69 69
70 - /*插入活动商品信息接口*/  
71 - app.post("/activityTemplate/insertProduct","activitytemplate_insertProduct"); 70 + // /*插入活动商品信息接口*/
  71 + // app.post("/activityTemplate/insertProduct","activitytemplate_insertProduct");
72 72
73 - /*更新商品信息接口*/  
74 - app.post("/activityTemplate/updateProduct","activitytemplate_updateProduct"); 73 + // /*更新商品信息接口*/
  74 + // app.post("/activityTemplate/updateProduct","activitytemplate_updateProduct");
75 75
76 - /*删除商品信息接口*/  
77 - app.post("/activityTemplate/delOneProduct","activitytemplate_delOneProduct"); 76 + // /*删除商品信息接口*/
  77 + // app.post("/activityTemplate/delOneProduct","activitytemplate_delOneProduct");
78 } 78 }
@@ -5,29 +5,29 @@ @@ -5,29 +5,29 @@
5 5
6 module.exports=function(app) { 6 module.exports=function(app) {
7 7
8 - /*图标管理首页*/  
9 - app.get("/operations/icon/index","operations.icon.Index", function () {  
10 - this.$extend = {  
11 - moduleName: "图标管理",  
12 - pageName: "图标管理"  
13 - }  
14 - }); 8 + // /*图标管理首页*/
  9 + // app.get("/operations/icon/index","operations.icon.Index", function () {
  10 + // this.$extend = {
  11 + // moduleName: "图标管理",
  12 + // pageName: "图标管理"
  13 + // }
  14 + // });
15 15
16 - /*列表*/  
17 - app.post("/icon/getList","icon_getList"); 16 + // /*列表*/
  17 + // app.post("/icon/getList","icon_getList");
18 18
19 - /*添加图标*/  
20 - app.post("/icon/addIcon","icon_addIcon"); 19 + // /*添加图标*/
  20 + // app.post("/icon/addIcon","icon_addIcon");
21 21
22 - /*根据ID获取图标信息*/  
23 - app.post("/icon/getOneIcon","icon_getOneIcon"); 22 + // /*根据ID获取图标信息*/
  23 + // app.post("/icon/getOneIcon","icon_getOneIcon");
24 24
25 - /*更新图标信息*/  
26 - app.post("/icon/updateIcon","icon_updateIcon"); 25 + // /*更新图标信息*/
  26 + // app.post("/icon/updateIcon","icon_updateIcon");
27 27
28 - /*开启图标入口*/  
29 - app.post("/icon/publishIcon","icon_publishIcon"); 28 + // /*开启图标入口*/
  29 + // app.post("/icon/publishIcon","icon_publishIcon");
30 30
31 - /*关闭图标信息入口*/  
32 - app.post("/icon/closeIcon","icon_closeIcon"); 31 + // /*关闭图标信息入口*/
  32 + // app.post("/icon/closeIcon","icon_closeIcon");
33 } 33 }
@@ -5,42 +5,42 @@ @@ -5,42 +5,42 @@
5 5
6 module.exports = function (app) { 6 module.exports = function (app) {
7 7
8 - /*活动分享管理首页*/  
9 - app.get("/operations/webshare/index", "operations.webshare.Index", function () {  
10 - this.$extend = {  
11 - moduleName: "活动分享管理",  
12 - pageName: "活动分享列表管理"  
13 - }  
14 - });  
15 -  
16 - /*添加活动分享页面*/  
17 - app.get("/operations/webshare/add", "operations.webshare.Edit", function () {  
18 - this.$extend = {  
19 - moduleName: "活动分享管理",  
20 - pageName: "添加活动分享",  
21 - url: "/webShare/addWebShare"  
22 - }  
23 - });  
24 -  
25 - /*编辑活动分享*/  
26 - app.get("/operations/webshare/edit/:id", "operations.webshare.Edit", function (req) {  
27 - this.$extend = {  
28 - moduleName: "活动分享管理",  
29 - pageName: "编辑活动分享",  
30 - id: req.params.id,  
31 - url: "/webShare/updateWebShare"  
32 - }  
33 - });  
34 -  
35 - /*首页列表*/  
36 - app.post("/webShare/getWebShareList", "webshare_getWebShareList");  
37 -  
38 - /*新增活动分享 [注意在shareImage加上客户端需要的imageView参数]*/  
39 - app.post("/webShare/addWebShare", "webshare_addWebShare");  
40 -  
41 - /*更新活动分享*/  
42 - app.post("/webShare/updateWebShare", "webshare_updateWebShare");  
43 -  
44 - /*根据id查询数据*/  
45 - app.post("/webShare/selectWebShare", "webshare_selectWebShare"); 8 + // /*活动分享管理首页*/
  9 + // app.get("/operations/webshare/index", "operations.webshare.Index", function () {
  10 + // this.$extend = {
  11 + // moduleName: "活动分享管理",
  12 + // pageName: "活动分享列表管理"
  13 + // }
  14 + // });
  15 +
  16 + // /*添加活动分享页面*/
  17 + // app.get("/operations/webshare/add", "operations.webshare.Edit", function () {
  18 + // this.$extend = {
  19 + // moduleName: "活动分享管理",
  20 + // pageName: "添加活动分享",
  21 + // url: "/webShare/addWebShare"
  22 + // }
  23 + // });
  24 +
  25 + // /*编辑活动分享*/
  26 + // app.get("/operations/webshare/edit/:id", "operations.webshare.Edit", function (req) {
  27 + // this.$extend = {
  28 + // moduleName: "活动分享管理",
  29 + // pageName: "编辑活动分享",
  30 + // id: req.params.id,
  31 + // url: "/webShare/updateWebShare"
  32 + // }
  33 + // });
  34 +
  35 + // /*首页列表*/
  36 + // app.post("/webShare/getWebShareList", "webshare_getWebShareList");
  37 +
  38 + // /*新增活动分享 [注意在shareImage加上客户端需要的imageView参数]*/
  39 + // app.post("/webShare/addWebShare", "webshare_addWebShare");
  40 +
  41 + // /*更新活动分享*/
  42 + // app.post("/webShare/updateWebShare", "webshare_updateWebShare");
  43 +
  44 + // /*根据id查询数据*/
  45 + // app.post("/webShare/selectWebShare", "webshare_selectWebShare");
46 } 46 }
@@ -5,23 +5,23 @@ @@ -5,23 +5,23 @@
5 5
6 module.exports=function(app) { 6 module.exports=function(app) {
7 7
8 - /*图片包首页*/  
9 - app.get("/operations/icon/ziplist","operations.ziplist.Index", function () {  
10 - this.$extend = {  
11 - moduleName: "图片包管理",  
12 - pageName: "图片包管理"  
13 - }  
14 - }); 8 + // /*图片包首页*/
  9 + // app.get("/operations/icon/ziplist","operations.ziplist.Index", function () {
  10 + // this.$extend = {
  11 + // moduleName: "图片包管理",
  12 + // pageName: "图片包管理"
  13 + // }
  14 + // });
15 15
16 - /*列表*/  
17 - app.post("/icon/getZipList","ziplist_getZipList"); 16 + // /*列表*/
  17 + // app.post("/icon/getZipList","ziplist_getZipList");
18 18
19 - /*上传图片包*/  
20 - app.post("/icon/addZip","ziplist_addZip"); 19 + // /*上传图片包*/
  20 + // app.post("/icon/addZip","ziplist_addZip");
21 21
22 - /*启用图片包*/  
23 - app.post("/icon/publishZip","ziplist_publishZip"); 22 + // /*启用图片包*/
  23 + // app.post("/icon/publishZip","ziplist_publishZip");
24 24
25 - /*关闭图片包*/  
26 - app.post("/icon/closeZip","ziplist_closeZip"); 25 + // /*关闭图片包*/
  26 + // app.post("/icon/closeZip","ziplist_closeZip");
27 } 27 }
1 { 1 {
2 "name": "yohobuy-portal-fe", 2 "name": "yohobuy-portal-fe",
3 - "version": "4.7.0", 3 + "version": "4.7.6",
4 "description": "Construction of the presentation layer solution is based on express, handlebars", 4 "description": "Construction of the presentation layer solution is based on express, handlebars",
5 "main": "app.js", 5 "main": "app.js",
6 "scripts": { 6 "scripts": {
@@ -6,73 +6,73 @@ @@ -6,73 +6,73 @@
6 module.exports=function(app) { 6 module.exports=function(app) {
7 7
8 /*活动模板首页*/ 8 /*活动模板首页*/
9 - app.get("/operations/activitytemplate/index","operations.activitytemplate.Index", function () {  
10 - this.$extend = {  
11 - moduleName: "活动模板管理",  
12 - pageName: "活动模板管理"  
13 - }  
14 - }); 9 + // app.get("/operations/activitytemplate/index","operations.activitytemplate.Index", function () {
  10 + // this.$extend = {
  11 + // moduleName: "活动模板管理",
  12 + // pageName: "活动模板管理"
  13 + // }
  14 + // });
15 15
16 - /*活动模板添加页*/  
17 - app.get("/operations/activitytemplate/add","operations.activitytemplate.Edit", "resourceManage_getUrlAction", function (response) {  
18 - this.$extend = {  
19 - moduleName: "活动模板管理",  
20 - pageName: "添加活动模板",  
21 - type: "add",  
22 - url: "/activityTemplate/addTemplate",  
23 - data: response.data  
24 - }  
25 - }); 16 + // /*活动模板添加页*/
  17 + // app.get("/operations/activitytemplate/add","operations.activitytemplate.Edit", "resourceManage_getUrlAction", function (response) {
  18 + // this.$extend = {
  19 + // moduleName: "活动模板管理",
  20 + // pageName: "添加活动模板",
  21 + // type: "add",
  22 + // url: "/activityTemplate/addTemplate",
  23 + // data: response.data
  24 + // }
  25 + // });
26 26
27 - /*活动模板编辑*/  
28 - app.get("/operations/activitytemplate/edit/:id","operations.activitytemplate.Edit","resourceManage_getUrlAction", function (response,req) {  
29 - this.$extend = {  
30 - moduleName: "活动模板管理",  
31 - pageName: "编辑活动模板",  
32 - type: "edit",  
33 - id: req.params.id,  
34 - url: "/activityTemplate/updateTemplate",  
35 - data: response.data  
36 - }  
37 - }); 27 + // /*活动模板编辑*/
  28 + // app.get("/operations/activitytemplate/edit/:id","operations.activitytemplate.Edit","resourceManage_getUrlAction", function (response,req) {
  29 + // this.$extend = {
  30 + // moduleName: "活动模板管理",
  31 + // pageName: "编辑活动模板",
  32 + // type: "edit",
  33 + // id: req.params.id,
  34 + // url: "/activityTemplate/updateTemplate",
  35 + // data: response.data
  36 + // }
  37 + // });
38 38
39 - /*活动模板编辑*/  
40 - app.get("/operations/activitytemplate/product/:id","operations.activitytemplate.Product", function (req) {  
41 - this.$extend = {  
42 - moduleName: "模板商品管理",  
43 - pageName: "模板商品管理",  
44 - id: req.params.id,  
45 - url: req.originalUrl  
46 - }  
47 - }); 39 + // /*活动模板编辑*/
  40 + // app.get("/operations/activitytemplate/product/:id","operations.activitytemplate.Product", function (req) {
  41 + // this.$extend = {
  42 + // moduleName: "模板商品管理",
  43 + // pageName: "模板商品管理",
  44 + // id: req.params.id,
  45 + // url: req.originalUrl
  46 + // }
  47 + // });
48 48
49 - /*查询模板列表接口*/  
50 - app.post("/activityTemplate/selectTemplateList","activitytemplate_selectTemplateList"); 49 + // /*查询模板列表接口*/
  50 + // app.post("/activityTemplate/selectTemplateList","activitytemplate_selectTemplateList");
51 51
52 - /*添加模板接口*/  
53 - app.post("/activityTemplate/addTemplate","activitytemplate_addTemplate"); 52 + // /*添加模板接口*/
  53 + // app.post("/activityTemplate/addTemplate","activitytemplate_addTemplate");
54 54
55 - /*获取单个模板接口*/  
56 - app.post("/activityTemplate/getTemplate","activitytemplate_getTemplate"); 55 + // /*获取单个模板接口*/
  56 + // app.post("/activityTemplate/getTemplate","activitytemplate_getTemplate");
57 57
58 - /*更新模板接口*/  
59 - app.post("/activityTemplate/updateTemplate","activitytemplate_updateTemplate"); 58 + // /*更新模板接口*/
  59 + // app.post("/activityTemplate/updateTemplate","activitytemplate_updateTemplate");
60 60
61 - /*开启模板接口*/  
62 - app.post("/activityTemplate/publishTemplate","activitytemplate_publishTemplate"); 61 + // /*开启模板接口*/
  62 + // app.post("/activityTemplate/publishTemplate","activitytemplate_publishTemplate");
63 63
64 - /*关闭模板接口*/  
65 - app.post("/activityTemplate/closeTemplate","activitytemplate_closeTemplate"); 64 + // /*关闭模板接口*/
  65 + // app.post("/activityTemplate/closeTemplate","activitytemplate_closeTemplate");
66 66
67 - /*根据条件查询活动商品列表接口*/  
68 - app.post("/activityTemplate/getProductListByCondition","activitytemplate_getProductListByCondition"); 67 + // /*根据条件查询活动商品列表接口*/
  68 + // app.post("/activityTemplate/getProductListByCondition","activitytemplate_getProductListByCondition");
69 69
70 - /*插入活动商品信息接口*/  
71 - app.post("/activityTemplate/insertProduct","activitytemplate_insertProduct"); 70 + // /*插入活动商品信息接口*/
  71 + // app.post("/activityTemplate/insertProduct","activitytemplate_insertProduct");
72 72
73 - /*更新商品信息接口*/  
74 - app.post("/activityTemplate/updateProduct","activitytemplate_updateProduct"); 73 + // /*更新商品信息接口*/
  74 + // app.post("/activityTemplate/updateProduct","activitytemplate_updateProduct");
75 75
76 - /*删除商品信息接口*/  
77 - app.post("/activityTemplate/delOneProduct","activitytemplate_delOneProduct"); 76 + // /*删除商品信息接口*/
  77 + // app.post("/activityTemplate/delOneProduct","activitytemplate_delOneProduct");
78 } 78 }
@@ -5,29 +5,29 @@ @@ -5,29 +5,29 @@
5 5
6 module.exports=function(app) { 6 module.exports=function(app) {
7 7
8 - /*图标管理首页*/  
9 - app.get("/operations/icon/index","operations.icon.Index", function () {  
10 - this.$extend = {  
11 - moduleName: "图标管理",  
12 - pageName: "图标管理"  
13 - }  
14 - }); 8 + // /*图标管理首页*/
  9 + // app.get("/operations/icon/index","operations.icon.Index", function () {
  10 + // this.$extend = {
  11 + // moduleName: "图标管理",
  12 + // pageName: "图标管理"
  13 + // }
  14 + // });
15 15
16 - /*列表*/  
17 - app.post("/icon/getList","icon_getList"); 16 + // /*列表*/
  17 + // app.post("/icon/getList","icon_getList");
18 18
19 - /*添加图标*/  
20 - app.post("/icon/addIcon","icon_addIcon"); 19 + // /*添加图标*/
  20 + // app.post("/icon/addIcon","icon_addIcon");
21 21
22 - /*根据ID获取图标信息*/  
23 - app.post("/icon/getOneIcon","icon_getOneIcon"); 22 + // /*根据ID获取图标信息*/
  23 + // app.post("/icon/getOneIcon","icon_getOneIcon");
24 24
25 - /*更新图标信息*/  
26 - app.post("/icon/updateIcon","icon_updateIcon"); 25 + // /*更新图标信息*/
  26 + // app.post("/icon/updateIcon","icon_updateIcon");
27 27
28 - /*开启图标入口*/  
29 - app.post("/icon/publishIcon","icon_publishIcon"); 28 + // /*开启图标入口*/
  29 + // app.post("/icon/publishIcon","icon_publishIcon");
30 30
31 - /*关闭图标信息入口*/  
32 - app.post("/icon/closeIcon","icon_closeIcon"); 31 + // /*关闭图标信息入口*/
  32 + // app.post("/icon/closeIcon","icon_closeIcon");
33 } 33 }
@@ -5,42 +5,42 @@ @@ -5,42 +5,42 @@
5 5
6 module.exports = function (app) { 6 module.exports = function (app) {
7 7
8 - /*活动分享管理首页*/  
9 - app.get("/operations/webshare/index", "operations.webshare.Index", function () {  
10 - this.$extend = {  
11 - moduleName: "活动分享管理",  
12 - pageName: "活动分享列表管理"  
13 - }  
14 - });  
15 -  
16 - /*添加活动分享页面*/  
17 - app.get("/operations/webshare/add", "operations.webshare.Edit", function () {  
18 - this.$extend = {  
19 - moduleName: "活动分享管理",  
20 - pageName: "添加活动分享",  
21 - url: "/webShare/addWebShare"  
22 - }  
23 - });  
24 -  
25 - /*编辑活动分享*/  
26 - app.get("/operations/webshare/edit/:id", "operations.webshare.Edit", function (req) {  
27 - this.$extend = {  
28 - moduleName: "活动分享管理",  
29 - pageName: "编辑活动分享",  
30 - id: req.params.id,  
31 - url: "/webShare/updateWebShare"  
32 - }  
33 - });  
34 -  
35 - /*首页列表*/  
36 - app.post("/webShare/getWebShareList", "webshare_getWebShareList");  
37 -  
38 - /*新增活动分享 [注意在shareImage加上客户端需要的imageView参数]*/  
39 - app.post("/webShare/addWebShare", "webshare_addWebShare");  
40 -  
41 - /*更新活动分享*/  
42 - app.post("/webShare/updateWebShare", "webshare_updateWebShare");  
43 -  
44 - /*根据id查询数据*/  
45 - app.post("/webShare/selectWebShare", "webshare_selectWebShare"); 8 + // /*活动分享管理首页*/
  9 + // app.get("/operations/webshare/index", "operations.webshare.Index", function () {
  10 + // this.$extend = {
  11 + // moduleName: "活动分享管理",
  12 + // pageName: "活动分享列表管理"
  13 + // }
  14 + // });
  15 +
  16 + // /*添加活动分享页面*/
  17 + // app.get("/operations/webshare/add", "operations.webshare.Edit", function () {
  18 + // this.$extend = {
  19 + // moduleName: "活动分享管理",
  20 + // pageName: "添加活动分享",
  21 + // url: "/webShare/addWebShare"
  22 + // }
  23 + // });
  24 +
  25 + // /*编辑活动分享*/
  26 + // app.get("/operations/webshare/edit/:id", "operations.webshare.Edit", function (req) {
  27 + // this.$extend = {
  28 + // moduleName: "活动分享管理",
  29 + // pageName: "编辑活动分享",
  30 + // id: req.params.id,
  31 + // url: "/webShare/updateWebShare"
  32 + // }
  33 + // });
  34 +
  35 + // /*首页列表*/
  36 + // app.post("/webShare/getWebShareList", "webshare_getWebShareList");
  37 +
  38 + // /*新增活动分享 [注意在shareImage加上客户端需要的imageView参数]*/
  39 + // app.post("/webShare/addWebShare", "webshare_addWebShare");
  40 +
  41 + // /*更新活动分享*/
  42 + // app.post("/webShare/updateWebShare", "webshare_updateWebShare");
  43 +
  44 + // /*根据id查询数据*/
  45 + // app.post("/webShare/selectWebShare", "webshare_selectWebShare");
46 } 46 }
@@ -5,23 +5,23 @@ @@ -5,23 +5,23 @@
5 5
6 module.exports=function(app) { 6 module.exports=function(app) {
7 7
8 - /*图片包首页*/  
9 - app.get("/operations/icon/ziplist","operations.ziplist.Index", function () {  
10 - this.$extend = {  
11 - moduleName: "图片包管理",  
12 - pageName: "图片包管理"  
13 - }  
14 - }); 8 + // /*图片包首页*/
  9 + // app.get("/operations/icon/ziplist","operations.ziplist.Index", function () {
  10 + // this.$extend = {
  11 + // moduleName: "图片包管理",
  12 + // pageName: "图片包管理"
  13 + // }
  14 + // });
15 15
16 - /*列表*/  
17 - app.post("/icon/getZipList","ziplist_getZipList"); 16 + // /*列表*/
  17 + // app.post("/icon/getZipList","ziplist_getZipList");
18 18
19 - /*上传图片包*/  
20 - app.post("/icon/addZip","ziplist_addZip"); 19 + // /*上传图片包*/
  20 + // app.post("/icon/addZip","ziplist_addZip");
21 21
22 - /*启用图片包*/  
23 - app.post("/icon/publishZip","ziplist_publishZip"); 22 + // /*启用图片包*/
  23 + // app.post("/icon/publishZip","ziplist_publishZip");
24 24
25 - /*关闭图片包*/  
26 - app.post("/icon/closeZip","ziplist_closeZip"); 25 + // /*关闭图片包*/
  26 + // app.post("/icon/closeZip","ziplist_closeZip");
27 } 27 }
@@ -24,26 +24,31 @@ module.exports = { @@ -24,26 +24,31 @@ module.exports = {
24 } else { 24 } else {
25 var data = {}; 25 var data = {};
26 data.list = []; 26 data.list = [];
27 - body = JSON.parse(body);  
28 - var dataList = body.data.product_list;  
29 - var goodslist = [];  
30 - var goodslist1 = [];  
31 - for (var m = 0; m < dataList.length; m++) {  
32 - if (dataList[m].goods_list && dataList[m].goods_list.length != 0) {  
33 - for (var n = 0; n < dataList[m].goods_list.length; n++) {  
34 - goodslist.push({a: dataList[m], b: dataList[m].goods_list[n]}) 27 + try{
  28 + body = JSON.parse(body);
  29 + var dataList = body.data.product_list;
  30 + var goodslist = [];
  31 + var goodslist1 = [];
  32 + for (var m = 0; m < dataList.length; m++) {
  33 + if (dataList[m].goods_list && dataList[m].goods_list.length != 0) {
  34 + for (var n = 0; n < dataList[m].goods_list.length; n++) {
  35 + goodslist.push({a: dataList[m], b: dataList[m].goods_list[n]})
  36 + }
  37 + } else {
  38 + goodslist.push({a: dataList[m], b: {}});
35 } 39 }
36 - } else {  
37 - goodslist.push({a: dataList[m], b: {}});  
38 } 40 }
  41 + for (var i = 0; i < goodslist.length; i++) {
  42 + goodslist1[i] = _.assign({}, goodslist[i].a, goodslist[i].b);
  43 + }
  44 + data.list = goodslist1.concat();//显示数据
  45 + data.page = body.data.page;//页码
  46 + data.totalPage = 1;//body.data.page_total;
  47 + data.nums = data.list.length;//记录每一页数据量
  48 + }catch(ex){
  49 + return callback(null, {data: data, code: 500});
39 } 50 }
40 - for (var i = 0; i < goodslist.length; i++) {  
41 - goodslist1[i] = _.assign({}, goodslist[i].a, goodslist[i].b);  
42 - }  
43 - data.list = goodslist1.concat();//显示数据  
44 - data.page = body.data.page;//页码  
45 - data.totalPage = 1;//body.data.page_total;  
46 - data.nums = data.list.length;//记录每一页数据量 51 +
47 return callback(null, {data: data, code: 200}); 52 return callback(null, {data: data, code: 200});
48 } 53 }
49 }); 54 });
1 -{"name":"yohobuy-portal-fe","version":"4.7.0","description":"Construction of the presentation layer solution is based on express, handlebars","main":"app.js","scripts":{"code":"set NODE_ENV=coding&& gulp start","build":"set NODE_ENV=production && gulp && gulp mvc","server":"set NODE_ENV=server&& gulp start"},"dependencies":{"art-template":"^3.0.3","async":"^2.0.0-rc.3","body-parser":"^1.15.0","connect-multiparty":"^2.0.0","connect-redis":"^3.0.2","cookie-parser":"^1.4.1","express":"^4.13.4","express-session":"^1.13.0","lodash":"^4.11.1","md5":"^2.1.0","mkdirp":"^0.5.1","request":"^2.72.0","winston":"^2.2.0","glob":"^7.0.3"}}  
  1 +{"name":"yohobuy-portal-fe","version":"4.7.6","description":"Construction of the presentation layer solution is based on express, handlebars","main":"app.js","scripts":{"code":"set NODE_ENV=coding&& gulp start","build":"set NODE_ENV=production && gulp && gulp mvc","server":"set NODE_ENV=server&& gulp start"},"dependencies":{"art-template":"^3.0.3","async":"^2.0.0-rc.3","body-parser":"^1.15.0","connect-multiparty":"^2.0.0","connect-redis":"^3.0.2","cookie-parser":"^1.4.1","express":"^4.13.4","express-session":"^1.13.0","lodash":"^4.11.1","md5":"^2.1.0","mkdirp":"^0.5.1","request":"^2.72.0","winston":"^2.2.0","glob":"^7.0.3"}}
@@ -4,11 +4,12 @@ @@ -4,11 +4,12 @@
4 <div> 4 <div>
5 <ul class="nav nav-pills" style="margin-bottom: 10px"> 5 <ul class="nav nav-pills" style="margin-bottom: 10px">
6 <li> 6 <li>
7 - <a class="tag" href="/goods/special/index" style="font-size: 14px;padding:10px">特殊商品</a> 7 + <a class="tag" href="/goods/special/index" style="font-size: 14px;padding:20px;color: black">特殊商品</a>
8 </li> 8 </li>
9 - <li class="active">  
10 - <a class="hand" href="javascript:void(0)" style="font-size: 14px;padding:10px">货到付款</a> 9 + <li>
  10 + <a class="hand active" href="javascript:void(0)" style="font-size: 14px;padding:20px;color: #428bca">货到付款</a>
11 </li> 11 </li>
  12 +
12 </ul> 13 </ul>
13 </div> 14 </div>
14 <div class="panel panel-default" style="margin-bottom:10px;"> 15 <div class="panel panel-default" style="margin-bottom:10px;">