api.js 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. //index 0开发环境 1测试环境 2正式环境
  2. const index = 0,
  3. api = {
  4. login: 'auth/login_by_weixin', //登录
  5. getMyPrivateMsgCount: 'message/getMyPrivateMsgCount', //加载是否有未读消息
  6. home: 'home/index', //首页数据
  7. club: 'organize/selectOrganizeByUserId', // 委办局
  8. clubDetails: 'organize/detail', // 委办局详情
  9. guidanceDocList: 'items/guidanceDocList', // 服务大厅 办事指南
  10. newsDetail: 'news/read', //新闻详情
  11. newsList: 'news/list', //新闻列表
  12. allDept: 'getAllVillagesDept.if',
  13. // level: 'getAllDeptByLevel.if', //服务大厅部门类别
  14. // levelDetail: 'getPreServiceByParam.if', //服务大厅事项列表
  15. // consultancyBm: 'getAllDeptByLevel.if', //互动页查询咨询部门
  16. matters: 'getServiceListBydeptId.if', //互动页查询部门可办事项
  17. interactionSave: 'consulting/save', //互动页保存咨询信息
  18. reservationDetail: 'reservation/getInfo.if', //预约详情
  19. reservationCancel: 'reservation/cancel.if', //取消预约
  20. reservationSave: 'reservation/save.if', //在线预约
  21. reservationServiceList: 'getReservationServiceList.if', //可预约部门列表
  22. reservationDateStatus: 'reservation/getReservationCount.if', //查询事项某个日期的预约情况
  23. myCase: 'getPreApasinfoListByUserId.if', //我的办件
  24. // param: 'getPreServiceByParam.if', //事项办理
  25. caseDetail: 'getPreApasinfoDetails.if', //办件详情
  26. setImg: 'material/getList', //选择我的材料,材料列表
  27. saveDataName: 'material/save', //保存我的材料,设置材料名称
  28. apasinfo: 'savePreApasinfo.if', //提交在线办理表单
  29. // Server: 'getClassificationByCode.if', //服务大厅列表
  30. Level: 'getAllDeptByLevel.if', //服务大厅部门类别
  31. // LevelDetail: 'getPreServiceByParam.if', //服务大厅事项列表
  32. // Guide: 'getPreServiceByUnid.if',//查询办事详情
  33. // MyReservation: 'reservation/getPageList.if',//我的预约
  34. ReservationDetail: 'reservation/getInfo.if', //预约详情
  35. ReservationCancel: 'reservation/cancel.if', //取消预约
  36. sendVerifCode: '/sms//sendVerifCode.if', //发送短信验证码
  37. // Param: 'getPreServiceByParam.if',//事项办理
  38. // Code: 'getClassificationByCode.if',//证件类型
  39. // GetUser: 'user/getUserInfo',//获取用户信息
  40. // UpdateUser: 'user/updateUserInfo',//更新用户信息
  41. // UploadImg: 'uploadFile.if',//上传
  42. // SetImg: 'material/getList',//选择我的材料,材料列表
  43. // SaveDataName: 'material/save',//保存我的材料,设置材料名称
  44. Apasinfo: 'savePreApasinfo.if', //提交在线办理表单
  45. UploadAudio: 'getPreServiceByServiceName.if', //语音文件上传
  46. HotService: 'getHotServiceList.if', //搜索咨询对象
  47. // myData: 'material/getList',//我的材料
  48. // addData: 'material/save',//上传资料
  49. // deleteData: 'material/delete',//删除材料
  50. advisoryList: 'consulting/getListPage', //我的咨询
  51. advisoryDetail: 'consulting/getInfo', //咨询详情
  52. // new apis
  53. departments: 'getAllDeptByLevel.if', //部门列表
  54. server: 'getClassificationByCode.if', //根据code得到相应类型
  55. handles: 'getPreServiceByParam.if', //服务大厅事项列表
  56. guide: 'getPreServiceByUnid.if',
  57. getUser: 'user/getUserInfo', //获取用户信息
  58. updateUser: 'user/updateUserInfo', //更新用户信息
  59. uploadImg: 'uploadFile.if', //上传图片
  60. myMaterial: 'material/getList', //我的材料
  61. addMaterial: 'material/save', //上传资料
  62. delMaterial: 'material/delete', //删除材料
  63. myReservation: 'reservation/getPageList.if', //我的预约
  64. addCollect: 'collect/save', //添加收藏
  65. delCollect: 'collect/cancel', //删除收藏
  66. myCollection: 'collect/getListByUserId', //我的收藏
  67. verifSmsCode: 'sms/verifSmsCode.if', //验证手机验证码是否正确
  68. evaluate: 'evaluate/save.if', //增加评价
  69. evaluateList: 'evaluate/list.if', //评价列表
  70. evaluateInfo: 'evaluate/info.if', //评价详情
  71. // 宿管系统--学生端
  72. getAccessInfo: 'access/getAccessInfo.if', //通行记录
  73. sendPhoneCode: 'visitor/sendPhoneCode.if', //访客申请
  74. userLogin: 'appletLogin/userLogin.if', //登录
  75. selfInfo: 'access/selfInfo.if', //访客统计
  76. //宿管系统--教师端
  77. getDeptInfo: 'deptInfo/getDeptInfolevel.if', //获取学院信息
  78. getRegisterInfo: 'dormManage/registerInfo.if', //获取注册和未注册的用户信息
  79. getVisitorCheckInfo: 'visitor/visitorInfo.if', //获取审批中和已审批的访客信息
  80. getDeviceInfo: 'access/selectDevices.if', //获取所有设备信息
  81. getPassInfo: '/access/getAccess.if', //通行记录
  82. getStatisticsInfo: '/access/statistics.if', //考勤统计
  83. getOutAndInInfo: '/access/outAndIn.if', //已出已归记录
  84. getVisitorInfo: '/visitor/searchInviteVisitor.if', //查询访客详情
  85. getVisitorCheck: '/visitor/approvalAlumniVisitor.if', //访客信息审批
  86. getUnInfo: '/access/unIn.if' //未归记录
  87. },
  88. [root] = [
  89. ["http://10.32.2.209:7088/oneportal/"],
  90. // ["http://192.168.0.27:9082/wx/"],
  91. ["http://192.168.0.27:8080/wx/"],
  92. ["https://zhll.dgtis.com/wx/"]
  93. ][index]
  94. Object.keys(api).forEach(x => {
  95. let v = api[x]
  96. api[x] = `${root}${v}`
  97. })
  98. module.exports = api