图书馆小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

141 lines
3.0 KiB

2 months ago
1 month ago
2 months ago
1 month ago
2 months ago
1 month ago
2 months ago
1 month ago
2 months ago
1 month ago
2 months ago
1 month ago
2 months ago
1 month ago
2 months ago
1 month ago
2 months ago
1 month ago
2 months ago
1 month ago
1 month ago
1 month ago
  1. import request from '../utils/request';
  2. // 获取第三方url/appid/Secret/sm4_key
  3. export function FetchInitScreenSetting(data) {
  4. return request({
  5. url: '/api/screenSetting/initScreenSetting',
  6. data
  7. })
  8. }
  9. //根据微信code 获取openId
  10. export function FetchOpenId(data) {
  11. return request({
  12. url: '/api/weixin/getOpenId',
  13. data
  14. });
  15. }
  16. // 根据openid获取所有绑定读者证列表
  17. // ?libcode=&openId=
  18. export function FetchFindAllReaderBindByOpenId(data) {
  19. return request({
  20. url: '/api/weixin/findAllReaderBindByOpenId',
  21. data
  22. });
  23. }
  24. // 根据openid获取用户信息
  25. // ?libcode=&openId=
  26. export function FetchFindAllReaderByOpenId(data) {
  27. return request({
  28. url: '/api/weixin/findReaderByOpenId',
  29. data
  30. });
  31. }
  32. // 读者认证
  33. export function FetchReaderList(data) {
  34. return request({
  35. url: '/api/screenSetting/searchreaderlist2',
  36. data
  37. });
  38. }
  39. // 用户绑定读者证
  40. // {
  41. // "openid":"小程序用户openID",
  42. // "bindValue":"绑定值",
  43. // "bindType":"绑定方式(rdid 读者证号 rdname读者姓名 rdcertify身份证号 othercardno其他编号 workcardno工作/学生证号 rdphone电话 rdloginid手机 cardid附属卡(IC卡))",
  44. // "libcode":"馆代码"
  45. // }
  46. export function FetchBindReadCard(data) {
  47. return request({
  48. url: '/api/weixin/bindReadCard',
  49. method: 'POST',
  50. data
  51. });
  52. }
  53. // 绑定用户
  54. // {
  55. // "avatar": "头像",
  56. // "libcode": "馆代码",
  57. // "nickname": "昵称",
  58. // "openid": ""
  59. // }
  60. export function FetchBindRead(data) {
  61. return request({
  62. url: '/api/weixin/bindReader',
  63. method: 'POST',
  64. data
  65. });
  66. }
  67. // 设置默认读者证
  68. // {
  69. // "bindType": "string",
  70. // "bindValue": "string",
  71. // "libcode": "string",
  72. // "openid": "string"
  73. // }
  74. export function FetchSetDefaultReadCard(data) {
  75. return request({
  76. url: '/api/weixin/setDefaultReadCard',
  77. method: 'POST',
  78. data
  79. });
  80. }
  81. // 用户解绑读者证
  82. // {
  83. // "bindType": "string",
  84. // "bindValue": "string",
  85. // "libcode": "string",
  86. // "openid": "string"
  87. // }
  88. export function FetchUnbindReadCard(data) {
  89. return request({
  90. url: '/api/weixin/unbindReadCard',
  91. method: 'POST',
  92. data
  93. });
  94. }
  95. // 读者留言列表
  96. // ?libcode=1&openId=1&page=0&phone=1&readCardNo=1&readName=1&size=10&title=1
  97. // libcode openId page phone readCardNo readName size title
  98. export function FetchInitReaderMessage(data) {
  99. return request({
  100. url: '/api/weixin/initReaderMessage',
  101. data
  102. });
  103. }
  104. // 根据id查看读者留言详情
  105. // ?id=1
  106. export function FetchReaderMessageDetailsById(data) {
  107. return request({
  108. url: '/api/weixin/getReaderMessageDetailsById',
  109. data
  110. });
  111. }
  112. // 读者留言
  113. // {
  114. // "libcode": "馆代码",
  115. // "openid": "string",
  116. // "phone": "联系方式",
  117. // "readCardNo": "读者证号",
  118. // "readName": "读者名称",
  119. // "suggestion": "建议",
  120. // "title": "标题"
  121. // }
  122. export function FetchReaderMessage(data) {
  123. return request({
  124. url: '/api/weixin/readerMessage',
  125. method: 'POST',
  126. data
  127. });
  128. }