Authored by yyq

qs err

@@ -50,10 +50,7 @@ module.exports = class extends global.yoho.BaseModel { @@ -50,10 +50,7 @@ module.exports = class extends global.yoho.BaseModel {
50 ]).then(result => { 50 ]).then(result => {
51 let resData = {}; 51 let resData = {};
52 52
53 - if (_.get(result, '[0].code', '') !== 200) {  
54 - resData.errText = _.get(result, '[0].message', '哟,本次调研已经飞走了,请移步其他调研呗!');  
55 - }  
56 - 53 + if (_.get(result, '[0].code', '') === 200) {
57 let data = _.get(result, '[1].data', {}); 54 let data = _.get(result, '[1].data', {});
58 55
59 if (data.questions) { 56 if (data.questions) {
@@ -67,6 +64,9 @@ module.exports = class extends global.yoho.BaseModel { @@ -67,6 +64,9 @@ module.exports = class extends global.yoho.BaseModel {
67 if (!_.isEmpty(data)) { 64 if (!_.isEmpty(data)) {
68 resData.detail = data; 65 resData.detail = data;
69 } 66 }
  67 + } else {
  68 + resData.errText = _.get(result, '[0].message', '哟,本次调研已经飞走了,请移步其他调研呗!');
  69 + }
70 70
71 return resData; 71 return resData;
72 }); 72 });