statistics.js 1.9 KB

123456789101112131415161718192021222324
  1. 'use strict';
  2. // 路由配置
  3. const path = require('path');
  4. const regPath = path.resolve('app', 'public', 'routerRegister');
  5. const routerRegister = require(regPath);
  6. const rkey = 'statistics';
  7. const ckey = 'statistics';
  8. const keyZh = '统计';
  9. const routes = [
  10. { method: 'post', path: `${rkey}/studentSign`, controller: `${ckey}.studentSign`, name: `${ckey}studentSign`, zh: `${keyZh}-学员签到情况` },
  11. { method: 'get', path: `${rkey}/schoolInByLesson`, middleware: [ 'dealQuery' ], controller: `${ckey}.schoolInByLesson`, name: `${ckey}schoolInByLesson`, zh: `${keyZh}-收入明细` },
  12. { method: 'get', path: `${rkey}/coachStudentLesson`, controller: `${ckey}.coachStudentLesson`, name: `${ckey}coachStudentLesson`, zh: `${keyZh}-教练,学员情况` },
  13. { method: 'get', path: `${rkey}/coachLesson`, controller: `${ckey}.coachLesson`, name: `${ckey}coachLesson`, zh: `${keyZh}-教练,授课情况` },
  14. { method: 'get', path: `${rkey}/studentPay`, controller: `${ckey}.studentPay`, name: `${ckey}studentPay`, zh: `${keyZh}-学员,付费情况` },
  15. { method: 'get', path: `${rkey}/studentLearning`, controller: `${ckey}.studentLearning`, name: `${ckey}studentLearning`, zh: `${keyZh}-学员,学习情况` },
  16. { method: 'get', path: `${rkey}/schoolCoachIn`, controller: `${ckey}.schoolCoachIn`, name: `${ckey}schoolCoachIn`, zh: `${keyZh}-羽校,教练收入` },
  17. { method: 'get', path: `${rkey}/schoolSignCoach`, controller: `${ckey}.schoolSignCoach`, name: `${ckey}schoolSignCoach`, zh: `${keyZh}-羽校,教练出勤率` },
  18. { method: 'get', path: `${rkey}/schoolStudentAge`, controller: `${ckey}.schoolStudentAge`, name: `${ckey}schoolStudentAge`, zh: `${keyZh}-羽校,学员区间` },
  19. { method: 'get', path: `${rkey}/schoolTotalIn`, controller: `${ckey}.schoolTotalIn`, name: `${ckey}schoolTotalIn`, zh: `${keyZh}-羽校总收入` },
  20. ];
  21. module.exports = app => {
  22. routerRegister(app, routes, keyZh, rkey, ckey);
  23. };