...
|
...
|
@@ -25,9 +25,9 @@ module.exports = [ |
|
|
{
|
|
|
type: TYPE.rewrite,
|
|
|
origin: /^\/(boys|girls|kids|lifestyle)(\/*)$/,
|
|
|
target: (req, match, p1) => {
|
|
|
req.query.channel = p1;
|
|
|
return `/guang/?chanel=${p1}`;
|
|
|
target: (req, match, channel) => {
|
|
|
req.query.channel = channel;
|
|
|
return `/guang/?chanel=${channel}`;
|
|
|
}
|
|
|
},
|
|
|
|
...
|
...
|
@@ -48,10 +48,10 @@ module.exports = [ |
|
|
{
|
|
|
type: TYPE.rewrite,
|
|
|
origin: /^\/(boys|girls|kids|lifestyle)-t([\d]+)(\/*)$/,
|
|
|
target: (req, match, p1, p2) => {
|
|
|
req.query.channel = p1;
|
|
|
req.query.type = p2;
|
|
|
return `/guang/?chanel=${p1}&type=${p2}`;
|
|
|
target: (req, match, channel, type) => {
|
|
|
req.query.channel = channel;
|
|
|
req.query.type = type;
|
|
|
return `/guang/?chanel=${channel}&type=${type}`;
|
|
|
}
|
|
|
},
|
|
|
|
...
|
...
|
@@ -59,11 +59,11 @@ module.exports = [ |
|
|
{
|
|
|
type: TYPE.rewrite,
|
|
|
origin: /^\/(boys|girls|kids|lifestyle)-t([\d]+)-p([\d]+)(\/*)$/,
|
|
|
target: (req, match, p1, p2, p3) => {
|
|
|
req.query.channel = p1;
|
|
|
req.query.type = p2;
|
|
|
req.query.page = p3;
|
|
|
return `/guang/index/index/?type=${p2}&channel=${p3}`;
|
|
|
target: (req, match, channel, type, page) => {
|
|
|
req.query.channel = channel;
|
|
|
req.query.type = type;
|
|
|
req.query.page = page;
|
|
|
return `/guang/index/index/?type=${type}&channel=${page}`;
|
|
|
}
|
|
|
},
|
|
|
|
...
|
...
|
|