Authored by ccbikai(👎🏻🍜)

路由分发整理

@@ -18,7 +18,7 @@ const hotfix = require(`${cRoot}/hotfix`); @@ -18,7 +18,7 @@ const hotfix = require(`${cRoot}/hotfix`);
18 18
19 // routers 19 // routers
20 20
21 -router.post('/upload/image', multipartMiddleware, uploadApi.uploadImg); 21 +router.post('/api/upload/image', multipartMiddleware, uploadApi.uploadImg);
22 router.post('/hf/v1', hotfix.v1); 22 router.post('/hf/v1', hotfix.v1);
23 23
24 module.exports = router; 24 module.exports = router;
@@ -11,9 +11,9 @@ module.exports = app => { @@ -11,9 +11,9 @@ module.exports = app => {
11 // 四个频道页,频道选择页面 /boys,/girls,/,/kids,/lifestyle 等页面,就直接占用路由了 11 // 四个频道页,频道选择页面 /boys,/girls,/,/kids,/lifestyle 等页面,就直接占用路由了
12 app.use(require('./apps/channel')); 12 app.use(require('./apps/channel'));
13 app.use(require('./apps/passport')); 13 app.use(require('./apps/passport'));
  14 + app.use(require('./apps/api')); // 一些只返回json的通用api
14 15
15 // 业务模块 16 // 业务模块
16 - app.use('/api', require('./apps/api')); // 各模块公有 API  
17 app.use('/product', require('./apps/product')); 17 app.use('/product', require('./apps/product'));
18 app.use('/guang', require('./apps/guang')); 18 app.use('/guang', require('./apps/guang'));
19 app.use('/activity', require('./apps/activity')); 19 app.use('/activity', require('./apps/activity'));
@@ -21,7 +21,4 @@ module.exports = app => { @@ -21,7 +21,4 @@ module.exports = app => {
21 21
22 // 分期付款 22 // 分期付款
23 app.use('/home', require('./apps/home')); 23 app.use('/home', require('./apps/home'));
24 -  
25 - // 一些只返回json的通用api  
26 - app.use('/', require('./apps/api'));  
27 }; 24 };