Authored by ccbikai(👎🏻🍜)

Merge branch 'release/newSearch'

@@ -133,12 +133,7 @@ const _getChannelResource = (params) => { @@ -133,12 +133,7 @@ const _getChannelResource = (params) => {
133 return api.get('operations/api/v5/resource/home', params, { 133 return api.get('operations/api/v5/resource/home', params, {
134 cache: true 134 cache: true
135 }).then(result => { 135 }).then(result => {
136 - if (result && result.code === 200 && result.data && result.data.list) {  
137 - for (let item of result.data.list) {  
138 - item.template_name === 'single_image' &&  
139 - item.data.length === 1 &&  
140 - (item.singleOne = true);  
141 - } 136 + if (result && result.code === 200) {
142 return resourcesProcess(result.data.list); 137 return resourcesProcess(result.data.list);
143 } else { 138 } else {
144 logger.error('index resouce is not 200'); 139 logger.error('index resouce is not 200');
@@ -70,6 +70,11 @@ module.exports = (list) => { @@ -70,6 +70,11 @@ module.exports = (list) => {
70 floor.data.data = floor.data.image; 70 floor.data.data = floor.data.image;
71 } 71 }
72 72
  73 + // 单张轮播图
  74 + floor.singleImage &&
  75 + floor.data.length === 1 &&
  76 + (floor.singleOne = true);
  77 +
73 formatData.push(floor); 78 formatData.push(floor);
74 }); 79 });
75 80