Authored by 周少峰

del sub domain

... ... @@ -13,7 +13,6 @@ const check = require(`${cRoot}/check`);
const question = require(`${cRoot}/question`);
const validateCode = require('../passport/controllers/validateCode');
const auth = require('../../doraemon/middleware/auth');
const sitemap = require(`${cRoot}/sitemap`);
// routers
... ... @@ -26,6 +25,5 @@ router.get('/questionnaire', auth, question.list);
router.post('/questionnaire/check', question.check);
router.post('/questionnaire/submit', question.submit);
router.get('/questionnaire/:id', auth, question.detail);
router.get('/sitemap.xml', sitemap.siteMap);
module.exports = router;
... ...
... ... @@ -13,7 +13,7 @@ const cate = require(cRoot + '/cate');
const brandController = require(`${cRoot}/brand`);
const custom = require(`${cRoot}/custom`);
const rewrite = require('../../doraemon/middleware/rewrite');
const sitemap = require('../3party/controllers/sitemap');
const router = express.Router(); // eslint-disable-line
router.get('/', channel.switchChannel, channel.index); // 首页,频道选择页
... ... @@ -45,4 +45,7 @@ router.get('/channel/2fb054e8315300a1ae1f80c3a4fda862.html', custom.zhihui);
// 自定义频道
router.get('/channel/:id.html', custom.index);
// 站点地图
router.get('/sitemap.xml', sitemap.siteMap);
module.exports = router;
... ...
... ... @@ -20,7 +20,7 @@ const detail = require(cRoot + '/detail');
const plustar = require(cRoot + '/plustar');
const rss = require(cRoot + '/rss');
const brand = require(cRoot + '/brand-list');
const sitemap = require('../3party/controllers/sitemap');
const router = express.Router(); // eslint-disable-line
router.get('/star', star.index); // 星潮教室首页
... ... @@ -72,5 +72,6 @@ router.get('/info/detailData', index.detailDynamicData);
router.get('/plusstar/cate', brand.index);
router.get('/plusstar/brandList', brand.brandList);
router.get('/sitemap.xml', sitemap.siteMap);
module.exports = router;
... ...
... ... @@ -11,11 +11,6 @@ const helpers = global.yoho.helpers;
module.exports = () => {
return (req, res, next) => {
if (req.url === '/sitemap.xml') {
req.url = '/3party/sitemap.xml';
return next();
}
if (req.hostname === 'activity.yoho.cn') {
// 活动模版的活动页
if (req.path === '/') {
... ...