index.js 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. const {
  2. globalData: {
  3. util: {
  4. regeneratorRuntime,
  5. api: {
  6. reservationDetail,
  7. },
  8. request: {
  9. get
  10. },
  11. goHome,
  12. navigate_auth_native,
  13. }
  14. }
  15. } = getApp()
  16. Page({
  17. async onLoad(option) {
  18. this.data.option=option
  19. this.setData({
  20. msg: await this.getMsg(option)
  21. })
  22. },
  23. async getMsg({ type, id }) {
  24. switch (type) {
  25. case 'reservation': //在线预约
  26. let { reservationNumber, reservationDate, reservationInterval, deptName, _err } = await get(reservationDetail, { id })
  27. if (_err) return ''
  28. return `尊敬的用户:您好,您预约的事项已经预约成功,预约号码【${reservationNumber}】,请于${reservationDate} ${reservationInterval == 'AM' ? '上午' : '下午'}准时到达行政服务中心${deptName}窗口进行办理,并注意查收手机短信。`
  29. case 'interaction'://互动
  30. return ''
  31. case 'userinfo'://用户信息
  32. return ''
  33. case 'assess'://用户评价
  34. return ''
  35. case 'handle'://在线办理
  36. return '尊敬的用户:您好,您申报的办件已经申报成功,办件编号【' +this.data.option.code+'】请在个人中心 —〉 我的办件中查询办件进度。'
  37. }
  38. },
  39. goHome,
  40. navigate_auth_native
  41. })