router.js
5.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
/**
* api router
* @author: chenfeng <feng.chen@yoho.cn>
* @date: 29/06/2017
*/
const express = require('express');
const router = express.Router(); // eslint-disable-line
const qiniu = require('./controllers/qiniu');
const wechat = require('./controllers/wechat');
const prize = require('./controllers/prize');
const shoes = require('./controllers/shoes');
const yohood = require('./controllers/yohood');
const coupon = require('./controllers/coupon');
const guochao = require('./controllers/guochao');
const redpac = require('./controllers/redpac');
const excel = require('./controllers/excel');
const multipart = require('connect-multiparty');
const wheelSurf = require('./controllers/wheel-surf');
const coupon511 = require('./controllers/coupon511');
const common = require('./controllers/common');
const mutilpartMiddleware = multipart();
const yohoActivitys = require('./controllers/yoho-activitys');
const dailyCheckIn = require('./controllers/daily-check-in');
const share = require('./controllers/share');
const NewProFesController = require('./controllers/new-pro-fes');
router.get('/gettoken', qiniu.getToken);
router.get('/share/getSignPackage', wechat.getSignPackage);
router.get('/prize/checkPrize', prize.checkPrize);
router.post('/prize/getPrize', prize.getPrize);
router.post('/prize/getNewPrize', prize.getNewPrize);
router.post('/prize/updatePrize', prize.updatePrize);
router.post('/info/saveUserInfo', prize.saveUserInfo);
// router.get('/excel/xml', excel.excelToXml);
// router.get('/excel/sendMail', excel.sendMail);
router.get('/excel/load', excel.getExcelData);
router.get('/excel/loady100', excel.getY100Data);
router.get('/excel/deletey100', excel.deleteY100Data);
router.post('/excel/loady100file', mutilpartMiddleware, excel.getY100ExcelFile);
router.get('/shoes/checkFriend', shoes.checkAddFriends);
router.get('/shoes/checkPlayed', shoes.checkUserPlayed);
router.post('/shoes/saveResult', shoes.saveUserResult);
router.post('/shoes/saveResultNew', shoes.saveUserResultWithToken);
router.post('/shoes/saveResultR', shoes.saveUserResultWithReplay); // 可以重复游戏的保存结果
router.get('/shoes/getUserShareInfo', shoes.getUserShareInfo);
router.get('/shoes/getUserPlayInfo', shoes.getUserPlayInfo);
router.get('/shoes/uay172hu27', shoes.deleteUserPlayInfo);
router.post('/shoes/getShoesToken', shoes.getShoesToken);
router.get('/shoes/getUserPhoneList', shoes.getUserPhoneList);
// yohood
router.get('/yohood/getBrandList', yohood.getBrandList);
router.get('/yohood/getBrandById', yohood.getBrandById);
router.get('/yohood/getNewsList', yohood.getNewsList);
router.get('/yohood/getNewsDetail', yohood.getNewsDetail);
router.get('/yohood/getRecommend', yohood.getRecommend);
router.get('/yohood/getResource', yohood.getYohoBuyResource);
router.get('/yohood/getShopProduct', yohood.getYohoBuyShopProduct);
router.get('/yohood/getCoupon', yohood.getCoupon);
// coupon
router.get('/coupon/getCouponList', coupon.couponList);
router.get('/coupon/getCouponSendFlags', coupon.couponSendFlag);
router.post('/coupon/couponGet', coupon.couponGet);
router.get('/coupon/couponUserOwner', coupon.couponUserOwner);
// guochao
router.post('/guochao/addFav', guochao.addFav);
router.get('/guochao/list', guochao.list);
router.post('/guochao/checkFav', guochao.checkFav);
// 图片处理git
router.get('/shoes/getBase64ImageData', shoes.getImageData);
// 查询专属客服微信号
router.post('/getWechatCs', wechat.getWechatCs);
// 红包雨活动
router.post('/redpac/getRedpac', redpac.getRedpac);
router.get('/redpac/getToken', redpac.getRedpacToken);
router.get('/redpac/getMyRedpac', redpac.getMyRedpac);
// wheelSurf
router.post('/activity/wheelSurf/conf', wheelSurf.getNowConf);
router.post('/activity/wheelSurf/start', wheelSurf.goPrize);
router.post('/activity/wheelSurf/user/prize', wheelSurf.getUserPrize);
// 公共服务
router.get('/common/resource', common.getResource);
router.post('/coupon511/status', coupon511.status);
router.post('/coupon511/take', coupon511.take);
router.get('/activity/yohoActivitys/create', yohoActivitys.actCreate); // 创建一个活动
router.get('/activity/yohoActivitys/actInfo', yohoActivitys.getActInfo); // 获取活动信息
router.get('/activity/yohoActivitys/createArticle', yohoActivitys.createArticle); // 创建文章
router.get('/activity/yohoActivitys/getArticleList', yohoActivitys.getArticleList); // 获取文章列表
router.post('/activity/yohoActivitys/addLike', yohoActivitys.addLike);// 给对应文章点赞
// router.get('/activity/yohoActivitys/removeRangeByRand', yohoActivitys.removeRangeByRand); // 删除所有文章
// 签到活动
router.post('/activity/checkIn/checkInNormal', dailyCheckIn.checkInNormal);// 每日签到
router.get('/activity/checkIn/getUserCumulativeData', dailyCheckIn.getUserCumulativeData); // 获取签到信息
router.post('/activity/checkIn/checkInCumulative', dailyCheckIn.checkInCumulative);// 累计签到
router.post('/activity/checkIn/saveUserInfo', dailyCheckIn.saveUserInfo); // 保存用户信息
router.get('/activity/checkIn/getWinnerList', dailyCheckIn.getWinnerList); // 获取实物奖品中奖用户
router.get('/activity/checkIn/getUserInfo', dailyCheckIn.getUserInfo); // 获取用户信息
router.get('/share/collect', share.collect); // 分享
router.get('/share/preshare', share.preshare); // 分享
router.get('/newProFes/getBuyerList', NewProFesController.getBuyerList); // 获取新品节购买用户列表
router.get('/newProFes/getActivityInfo', NewProFesController.getActivityInfo); // 获取新品节活动信息
router.post('/newProFes/sendStar', NewProFesController.sendStar); // 点赞
router.get('/newProFes/getProductPool', NewProFesController.getProductPool); // 获取商品池列表
router.get('/newProFes/getProductBySkn', NewProFesController.getProductBySkn); // 获取商品列表
router.post('/newProFes/sendCoupon', NewProFesController.sendCoupon); // 领券
module.exports = router;