api.js 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324
  1. import { fetch, uploadFile } from './util.js'
  2. const fetchFn = url => paras => fetch(Object.assign({ url }, paras))
  3. const uploadFileFn = url => paras => uploadFile(Object.assign({ url }, paras))
  4. // 上传图片资源
  5. export const UploadFile = uploadFileFn('/wxapi/images/uploadForm')
  6. // 验证token是否失效
  7. // export const CheckToken = fetchFn('/wxapi/user/checkToken')
  8. // 小程序普通登录
  9. export const WxLogin = fetchFn('/wxapi/user/readingLogin')
  10. // 小程序首次登录
  11. export const FirstWxLogin = fetchFn('/wxapi/user/newReadingLogin')
  12. // 获取家长端我的首页
  13. export const GetMineInfo = fetchFn('/wxapi/reading/mine')
  14. // 获取家长端我的个人资料
  15. export const GetVipInfo = fetchFn('/wxapi/reading/vipInfo')
  16. // 保存个人资料信息
  17. export const SaveVipInfo = fetchFn('/wxapi/reading/saveLibVip')
  18. // 获取图书馆
  19. export const GetLibrary = fetchFn('/wxapi/reading/positionJoin')
  20. // 根据馆定位获取学校信息
  21. export const GetpositionArea = fetchFn('/wxapi/reading/positionArea')
  22. // 获取家长端首页
  23. export const GetParentHome = fetchFn('/wxapi/reading/goodbook')
  24. // 判断还可以借用多少本书
  25. export const GetBorrowBookNum = fetchFn('/wxapi/reading/lendingTimes')
  26. // 扫一扫借书
  27. // export const ScanningBooks = fetchFn('/wxapi/reading/scanningBooks')
  28. // 图书详情借阅,预约,心愿,添加
  29. export const AddWishBooks = fetchFn('/wxapi/reading/addWish')
  30. // 获取图书详情
  31. export const GetBookDetail = fetchFn('/wxapi/reading/bookIsbnDetail')
  32. // 获取借阅书籍
  33. export const GetBorrowBook = fetchFn('/wxapi/reading/haveToBorrow')
  34. // 借阅书籍
  35. export const BorrowBook = fetchFn('/wxapi/reading/confirmBorrowing')
  36. // 获取好书推荐列表
  37. export const GetBookRecommend = fetchFn('/wxapi/reading/bookRecommend')
  38. // 获取成长记录列表
  39. export const GetGrowthRecord = fetchFn('/wxapi/reading/growthRecord')
  40. // 获取常见问题列表
  41. export const GetQuestion = fetchFn('/api/problem/list')
  42. // 我要预约
  43. export const ToReservation = fetchFn('/wxapi/reading/woYaoReservation')
  44. // 全部预约
  45. export const AlreadyReservation = fetchFn('/wxapi/reading/alreadyReservation')
  46. // 搜索
  47. export const SearchIndex = fetchFn('/wxapi/reading/searchIndex')
  48. // 图书列表
  49. export const SearchBookList = fetchFn('/wxapi/reading/bookList')
  50. // 主题搜索
  51. export const ThemeSearch = fetchFn('/wxapi/reading/themeSearch')
  52. // 我的心愿书籍
  53. export const MyWishBook = fetchFn('/wxapi/reading/myWish')
  54. // 其他心愿书籍
  55. export const OthersWishBook = fetchFn('/wxapi/reading/othersWish')
  56. // 心愿助力
  57. export const WishHelp = fetchFn('/wxapi/reading/wishHelp')
  58. // 心愿详情
  59. export const WishBookDetail = fetchFn('/wxapi/reading/wishDetails')
  60. // 调度馆
  61. export const DispatcherIndex = fetchFn('/wxapi/reading/dispatcherIndex')
  62. // 确认拒绝调度员
  63. export const DispatcherAudit = fetchFn('/wxapi/reading/dispatcherAudit')
  64. // 获取带书入馆
  65. // export const GetDispatchGo = fetchFn('/wxapi/reading/libDispatching')
  66. // 获取图书列表
  67. export const GetSweepedBooks = fetchFn('/wxapi/reading/scanBookList')
  68. // 删除图书列表
  69. export const DeleteSweepedBooks = fetchFn('/wxapi/reading/deleteBooks')
  70. // 扫书入馆
  71. export const DispatcherScanning = fetchFn('/wxapi/reading/dispatcherScanning')
  72. // 提交送书到馆
  73. export const ConfirmToLib = fetchFn('/wxapi/reading/confirmToLib')
  74. // 提交带书离馆
  75. export const ConfirmToZb = fetchFn('/wxapi/reading/confirmToZb')
  76. // 调度员信息
  77. export const GetDispatcherInfo = fetchFn('/wxapi/reading/dispatcherInfo')
  78. // 获取撤馆列表
  79. export const GetWithdrawLibrary = fetchFn('/wxapi/reading/cancelLibList')
  80. // 获取所撤馆信息
  81. export const GetWithdrawLibraryDetail = fetchFn('/wxapi/reading/cancelLibBookInfo')
  82. // 确定撤馆
  83. export const ComfirmWithdrawLibrary = fetchFn('/wxapi/reading/cancelComfirm')
  84. // 获取撤馆图书列表头部
  85. export const GetRecoveryListHeadInfo = fetchFn('/wxapi/reading/cancelLibHeadInfo')
  86. // 获取撤馆图书列表
  87. export const GetRecoveryList = fetchFn('/wxapi/reading/recoveryList')
  88. // 回收入库扫描书籍详情
  89. export const DispatcherRecovery = fetchFn('/wxapi/reading/dispatcherRecovery')
  90. // 确认收入或者入库
  91. export const ConfirmRecovery = fetchFn('/wxapi/reading/confirmRecovery')
  92. // 图书调度员--根据扫码二维码获取书籍信息 (新增)
  93. export const ScanForBookDetail = fetchFn('/wxapi/reading/scanForBookDetail')
  94. // 图书调度员--解绑图书 (新增)
  95. export const RemoveBookLib = fetchFn('/wxapi/reading/removeBookLib')
  96. // 图书调度员--归还图书 (新增)
  97. export const BackBookLib = fetchFn('/wxapi/reading/backBookLib')
  98. // 书籍详情
  99. export const BookDetailView = fetchFn('/wxapi/readingcurator/bookDetailView')
  100. // 获取校长端首页头部
  101. export const GetBooksTab = fetchFn('/wxapi/readingcurator/bookstab')
  102. // 书籍搜索列表Top10
  103. export const GetLibraryTopTen = fetchFn('/wxapi/readingcurator/libraryTopTen')
  104. // 获取校长端首页数据
  105. export const GetBooksInlibrary = fetchFn('/wxapi/readingcurator/booksinthelibrary')
  106. // 调入书籍
  107. export const CallInBooks = fetchFn('/wxapi/readingcurator/callInBooks')
  108. // 调出书籍
  109. export const CallOutBooks = fetchFn('/wxapi/readingcurator/callOutBooks')
  110. // 调出
  111. export const CallOutList = fetchFn('/wxapi/readingcurator/callOutList')
  112. // 调入
  113. export const CallInList = fetchFn('/wxapi/readingcurator/callInList')
  114. // 删除书籍
  115. export const DeleteBooks = fetchFn('/wxapi/readingcurator/deleteBooks')
  116. // 锁定库存
  117. export const SaveLocking = fetchFn('/wxapi/readingcurator/saveLocking')
  118. // 获取校长主题系列书籍
  119. // export const GoodBooksToRead = fetchFn('/wxapi/readingcurator/goodBooksToRead')
  120. // 获取部分调入图书
  121. export const GetThemeAllBook = fetchFn('/wxapi/readingcurator/themeAll')
  122. // 确认调入
  123. export const BatchCallInBooks = fetchFn('/wxapi/readingcurator/batchCallInBooks')
  124. // 提交申请书单
  125. export const PostApplyBookList = fetchFn('/wxapi/readingcurator/postApplyBookList')
  126. // 找好书2.0
  127. // 好书推荐(20191010修改)
  128. export const GoodBooksToRead = fetchFn('/wxapi/readingcurator/goodBooksToRead')
  129. // 随机选书提交(2019-10-10)
  130. export const RandomBook = fetchFn('/wxapi/readingcurator/randomBook')
  131. // 好书推荐搜索(2019-10-10)
  132. export const GoodBooksSearch = fetchFn('/wxapi/readingcurator/goodBooksSearch')
  133. // 家长端迭代
  134. // 首页
  135. export const GoodIndex = fetchFn('/wxapi/reading/parent/goodIndex')
  136. // 找好书搜索
  137. export const GoodIndexSearch = fetchFn('/wxapi/reading/parent/goodIndexSearch')
  138. // 搜索历史
  139. export const IndexSearchHis = fetchFn('/wxapi/reading/parent/indexSearchHis')
  140. // 清除搜索历史
  141. export const ClearSearchHis = fetchFn('/wxapi/reading/parent/clearSearchHis')
  142. // 书籍详情
  143. // export const BookDetailView = fetchFn('/wxapi/reading/parent/bookDetailView')
  144. // 图书分类
  145. export const BookSort = fetchFn('/wxapi/reading/parent/bookSort')
  146. // 初始化借阅车
  147. export const InitBorrowCar = fetchFn('/wxapi/reading/parent/initBorrowCar')
  148. // 扫码书籍加入借阅单
  149. export const ScanningBooksTwo = fetchFn('/wxapi/reading/parent/scanningBooks')
  150. // 首页滚动栏
  151. export const IndexBarList = fetchFn('/wxapi/reading/parent/IndexBarList')
  152. // 定位获取图书馆信息
  153. export const PositionJoin = fetchFn('/wxapi/reading/parent/positionJoin')
  154. // 确定借阅
  155. export const ConfirmBorrow = fetchFn('/wxapi/reading/parent/confirmBorrow')
  156. // 借阅记录
  157. export const BorrowInfoList = fetchFn('/wxapi/reading/parent/borrowInfoList')
  158. // 主题借阅记录
  159. export const ThemeBorrowedList = fetchFn('/wxapi/reading/parent/themeBorrowedList')
  160. // 馆内当前排名
  161. export const UserRankingLib = fetchFn('/wxapi/reading/parent/userRankingLib')
  162. // 馆内历史排名
  163. export const LibRankingHis = fetchFn('/wxapi/reading/parent/libRankingHis')
  164. // 成长轨迹
  165. export const UserReadInfo = fetchFn('/wxapi/reading/parent/userReadInfo')
  166. // 提交申请书单
  167. export const ApplyBook = fetchFn('/wxapi/reading/parent/applyBook')
  168. // 申请书单记录
  169. export const ApplyBookHis = fetchFn('/wxapi/reading/parent/applyBookHis')
  170. // 图书分类查询
  171. export const SortSearch = fetchFn('/wxapi/reading/parent/sortSearch')
  172. // 馆长端迭代
  173. // 签到签离列表
  174. export const SignList = fetchFn('/wxapi/readingcurator/signList')
  175. // 签到签离提交
  176. export const SignSubmit = fetchFn('/wxapi/readingcurator/signSubmit')
  177. // 数据统计-日统计
  178. export const DayCount = fetchFn('/wxapi/readingcurator/dayCount')
  179. // 数据统计-月统计
  180. export const MonthCount = fetchFn('/wxapi/readingcurator/monthCount')
  181. // 本月到馆人数列表
  182. export const SignMonthList = fetchFn('/wxapi/readingcurator/signMonthList')
  183. // 本月到馆人数列表
  184. export const DayInfoList = fetchFn('/wxapi/readingcurator/dayInfoList')
  185. // 代办借阅会员列表
  186. export const AgencyVipList = fetchFn('/wxapi/readingcurator/agencyVipList')
  187. // 馆内排行榜
  188. export const RankingLib = fetchFn('/wxapi/readingcurator/rankingLib')
  189. // 借阅记录
  190. export const ReadingBorrowInfoList = fetchFn('/wxapi/readingcurator/borrowInfoList')
  191. // 会员管理列表
  192. export const LibVipList = fetchFn('/wxapi/readingcurator/libVipList')
  193. // 会员管理列表
  194. export const ManagerList = fetchFn('/wxapi/readingcurator/managerList')
  195. // 人员搜索
  196. export const LibSearch = fetchFn('/wxapi/readingcurator/libSearch')
  197. // 会员管理详情
  198. export const VipDetailInfo = fetchFn('/wxapi/readingcurator/vipDetailInfo')
  199. // 修改会员服务有效期
  200. export const EditVipservice = fetchFn('/wxapi/readingcurator/editVipservice')
  201. // 会员个人信息详情
  202. export const VipInfo = fetchFn('/wxapi/readingcurator/vipInfo')
  203. // 保存个人信息详情
  204. export const ReadingAaveVipInfo = fetchFn('/wxapi/readingcurator/saveVipInfo')
  205. // 会员到馆详情
  206. export const VipSignInfoList = fetchFn('/wxapi/readingcurator/vipSignInfoList')
  207. // 馆内人员信息编辑
  208. export const ManagerEdit = fetchFn('/wxapi/readingcurator/managerEdit')
  209. // 馆内人员信息保存
  210. export const ManagerSave = fetchFn('/wxapi/readingcurator/managerSave')
  211. // 删除馆内人员
  212. export const ManagerDel = fetchFn('/wxapi/readingcurator/managerDel')
  213. // 调书申请记录
  214. export const ApplyInfoList = fetchFn('/wxapi/readingcurator/ApplyInfoList')
  215. // 调书申请明细记录
  216. export const ApplyInfoDetailList = fetchFn('/wxapi/readingcurator/ApplyInfoDetailList')
  217. // 新书申请记录
  218. export const NewBookApplyInfoList = fetchFn('/wxapi/readingcurator/NewBookApplyInfoList')
  219. // 新书申请明细记录
  220. export const NewBookApplyDetailList = fetchFn('/wxapi/readingcurator/NewBookApplyDetailList')
  221. // 确定还书
  222. export const ConfirmBackBorrow = fetchFn('/wxapi/readingcurator/confirmBackBorrow')
  223. // 获取角色信息
  224. export const CheckRole = fetchFn('/wxapi/readingcurator/checkRole')
  225. // 扫码书籍加入还书车
  226. export const ScanningBackBooks = fetchFn('/wxapi/readingcurator/scanningBackBooks')
  227. // 在馆书籍主题年段详情
  228. export const BookInLibInfo = fetchFn('/wxapi/readingcurator/bookInLibInfo')
  229. // 录入识别二维码是否有效
  230. export const CheckBookCard = fetchFn('/wxapi/readingcurator/checkBookCard')
  231. // 根据isbn13查询书籍信息
  232. export const GetBookInfoByIsbn = fetchFn('/wxapi/readingcurator/getBookInfoByIsbn')
  233. // 录书保存
  234. export const AddBook = fetchFn('/wxapi/readingcurator/addBook')
  235. // 根据id获取书籍信息完善书架
  236. export const BookCase = fetchFn('/wxapi/readingcurator/bookCase')
  237. // 保存书架信息
  238. export const SaveBookcase = fetchFn('/wxapi/readingcurator/saveBookcase')
  239. // 保存书架信息
  240. export const ReadinglibRankingHis = fetchFn('/wxapi/readingcurator/libRankingHis')
  241. // 催还书籍提交
  242. export const CallBookBack = fetchFn('/wxapi/readingcurator/callBookBack')
  243. // 馆内人员添加搜索
  244. export const LibManagerSearch = fetchFn('/wxapi/readingcurator/libManagerSearch')
  245. // 馆内人员添加搜索
  246. export const SearchUserApplyList = fetchFn('/wxapi/readingcurator/userApplyList')
  247. // 馆内人员添加搜索
  248. export const CheckNext = fetchFn('/wxapi/readingcurator/checkNext')
  249. // 关于私塾家
  250. export const AboutSharingSchool = fetchFn('/api/problem/aboutSharingSchool')