Showing
5 changed files
with
5 additions
and
3 deletions
@@ -107,6 +107,7 @@ const createConsult = (req, res, next) => { | @@ -107,6 +107,7 @@ const createConsult = (req, res, next) => { | ||
107 | if (content && uid) { | 107 | if (content && uid) { |
108 | service.createConsultAsync(uid, pid, content) | 108 | service.createConsultAsync(uid, pid, content) |
109 | .then(result => { | 109 | .then(result => { |
110 | + console.log(result); | ||
110 | res.json(result); | 111 | res.json(result); |
111 | }) | 112 | }) |
112 | .catch(next); | 113 | .catch(next); |
@@ -130,7 +131,6 @@ const createConsult = (req, res, next) => { | @@ -130,7 +131,6 @@ const createConsult = (req, res, next) => { | ||
130 | res.json({ | 131 | res.json({ |
131 | code: 400, | 132 | code: 400, |
132 | message: '请输入咨询内容', | 133 | message: '请输入咨询内容', |
133 | - data: '' | ||
134 | }); | 134 | }); |
135 | } | 135 | } |
136 | 136 |
@@ -17,7 +17,7 @@ const indexAsync = (pid, page, size) => { | @@ -17,7 +17,7 @@ const indexAsync = (pid, page, size) => { | ||
17 | return co(function *() { | 17 | return co(function *() { |
18 | let commentList = yield api.indexAsync(pid, page, size); | 18 | let commentList = yield api.indexAsync(pid, page, size); |
19 | 19 | ||
20 | - if (!commentList.code && commentList.code === 200) { | 20 | + if (!(commentList.code && commentList.code === 200)) { |
21 | return []; | 21 | return []; |
22 | } | 22 | } |
23 | 23 |
@@ -1345,6 +1345,7 @@ module.exports.showMainAsync = (data) => { | @@ -1345,6 +1345,7 @@ module.exports.showMainAsync = (data) => { | ||
1345 | // 获取商品尺寸相关 | 1345 | // 获取商品尺寸相关 |
1346 | let sizeInfo = getSizeInfo(productInfo.goodsInfo, productInfo.goodsInfo.maxSortId); | 1346 | let sizeInfo = getSizeInfo(productInfo.goodsInfo, productInfo.goodsInfo.maxSortId); |
1347 | 1347 | ||
1348 | + // 分类导航 | ||
1348 | let navs = requestData[0]; | 1349 | let navs = requestData[0]; |
1349 | 1350 | ||
1350 | result.headerData = requestData[1]; | 1351 | result.headerData = requestData[1]; |
@@ -63,6 +63,7 @@ | @@ -63,6 +63,7 @@ | ||
63 | "ava": "^0.15.2", | 63 | "ava": "^0.15.2", |
64 | "babel-preset-es2015": "^6.9.0", | 64 | "babel-preset-es2015": "^6.9.0", |
65 | "babel-register": "^6.9.0", | 65 | "babel-register": "^6.9.0", |
66 | + "cross-env": "^1.0.8", | ||
66 | "eslint": "^2.12.0", | 67 | "eslint": "^2.12.0", |
67 | "eslint-config-yoho": "^1.0.1", | 68 | "eslint-config-yoho": "^1.0.1", |
68 | "gulp": "^3.9.1", | 69 | "gulp": "^3.9.1", |
-
Please register or login to post a comment