...
|
...
|
@@ -39,7 +39,7 @@ module.exports = class extends global.yoho.BaseModel { |
|
|
if (firstItem.sub && firstItem.sub.length) {
|
|
|
_.map(firstItem.sub, function(secondItem) {
|
|
|
secondItem.url = helpers.urlFormat('/', utils.mapSort({
|
|
|
sort: _.get(secondItem, 'relation_parameter.sort'),
|
|
|
categoryId: _.get(secondItem, 'category_id'),
|
|
|
sort_name: secondItem.category_name,
|
|
|
gender: genderMap[key] || ''
|
|
|
}), 'list');
|
...
|
...
|
@@ -48,14 +48,14 @@ module.exports = class extends global.yoho.BaseModel { |
|
|
firstItem.sub.unshift({
|
|
|
category_name: `全部${firstItem.category_name}`,
|
|
|
url: helpers.urlFormat('/', utils.mapSort({
|
|
|
sort: _.get(firstItem, 'relation_parameter.sort'),
|
|
|
categoryId: _.get(firstItem, 'category_id'),
|
|
|
sort_name: firstItem.category_name,
|
|
|
gender: genderMap[key] || ''
|
|
|
}), 'list')
|
|
|
});
|
|
|
} else {
|
|
|
firstItem.url = helpers.urlFormat('/', utils.mapSort({
|
|
|
sort: _.get(firstItem, 'relation_parameter.sort'),
|
|
|
categoryId: _.get(firstItem, 'category_id'),
|
|
|
sort_name: firstItem.category_name,
|
|
|
gender: genderMap[key] || ''
|
|
|
}), 'list');
|
...
|
...
|
|