...
|
...
|
@@ -22,15 +22,16 @@ module.exports = () => { |
|
|
}
|
|
|
break;
|
|
|
case 'search': // search
|
|
|
if (req.path === '/' && _.keys(req.query).length) {
|
|
|
if (req.path === '/') {
|
|
|
|
|
|
// 有查询关键字
|
|
|
if (_.keys(req.query).length) {
|
|
|
req.url = `/product/search/list?${querystring.stringify(req.query)}`;
|
|
|
} else {
|
|
|
|
|
|
// 无查询关键字
|
|
|
req.url = `/product/search/index?${querystring.stringify(req.query)}`;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
if (req.path === '/search') {
|
|
|
req.url = `/product/search/index?${querystring.stringify(req.query)}`;
|
|
|
}
|
...
|
...
|
|