Authored by 周少峰

Merge branch 'feature/seoUrl302' of git.yoho.cn:fe/yohobuy-node into feature/seoUrl302

@@ -10,6 +10,18 @@ const TYPE = require('../type'); @@ -10,6 +10,18 @@ const TYPE = require('../type');
10 module.exports = [ 10 module.exports = [
11 { 11 {
12 type: TYPE.redirect, 12 type: TYPE.redirect,
  13 + origin: /\/product\/sale\/\?channel=(.*)/,
  14 + target: (req, match, channel) => {
  15 + return helpers.urlFormat(`/product/${channel}-sale/`);
  16 + }
  17 + },
  18 + {
  19 + type: TYPE.redirect,
  20 + origin: '/product/sale/?msort=10',
  21 + target: helpers.urlFormat('/product/lifestyle-sale/')
  22 + },
  23 + {
  24 + type: TYPE.redirect,
13 origin: /\/about?shopId=([\d]+)/, 25 origin: /\/about?shopId=([\d]+)/,
14 target: (req, match, id) => { 26 target: (req, match, id) => {
15 return helpers.urlFormat(`/shop${id}-about`, null, req.subdomains[0]); 27 return helpers.urlFormat(`/shop${id}-about`, null, req.subdomains[0]);
@@ -14,22 +14,22 @@ module.exports = [ @@ -14,22 +14,22 @@ module.exports = [
14 { 14 {
15 type: TYPE.redirect, 15 type: TYPE.redirect,
16 origin: '/new?gender=1,3&order=s_t_desc&msort=1,3,4,6,7,8,308,360', 16 origin: '/new?gender=1,3&order=s_t_desc&msort=1,3,4,6,7,8,308,360',
17 - target: helpers.urlFormat('/boys-new', null, 'list') 17 + target: helpers.urlFormat('/boys-new/', null, 'list')
18 }, 18 },
19 { 19 {
20 type: TYPE.redirect, 20 type: TYPE.redirect,
21 origin: '/new?gender=2,3&order=s_t_desc&msort=1,3,4,6,7,8,308,360', 21 origin: '/new?gender=2,3&order=s_t_desc&msort=1,3,4,6,7,8,308,360',
22 - target: helpers.urlFormat('/girls-new', null, 'list') 22 + target: helpers.urlFormat('/girls-new/', null, 'list')
23 }, 23 },
24 { 24 {
25 type: TYPE.redirect, 25 type: TYPE.redirect,
26 origin: '/new?order=s_t_desc&msort=365', 26 origin: '/new?order=s_t_desc&msort=365',
27 - target: helpers.urlFormat('/kids-new', null, 'list') 27 + target: helpers.urlFormat('/kids-new/', null, 'list')
28 }, 28 },
29 { 29 {
30 type: TYPE.redirect, 30 type: TYPE.redirect,
31 origin: '/new?order=s_t_desc&msort=10', 31 origin: '/new?order=s_t_desc&msort=10',
32 - target: helpers.urlFormat('/lifestyle-new', null, 'list') 32 + target: helpers.urlFormat('/lifestyle-new/', null, 'list')
33 }, 33 },
34 34
35 // 筛选参数排序匹配 35 // 筛选参数排序匹配