apis.js 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773
  1. /**
  2. * 接口列表文件
  3. */
  4. export default {
  5. /** 公共 ↓ **/
  6. common: {
  7. init: {
  8. url: "index/init",
  9. auth: false,
  10. method: "GET",
  11. // desc: '初始化数据',end
  12. },
  13. chat: {
  14. url: "chat.index/init",
  15. auth: false,
  16. method: "GET",
  17. // desc: '初始化聊天配置',
  18. },
  19. upload: {
  20. url: "index/upload",
  21. auth: true,
  22. method: "POST",
  23. // desc: '上传图片',
  24. },
  25. template: {
  26. url: "index/template",
  27. auth: false,
  28. method: "GET",
  29. // desc: '模板信息',end
  30. },
  31. custom: {
  32. url: "index/custom",
  33. auth: false,
  34. method: "GET",
  35. // desc: '自定义模板页面',
  36. },
  37. live: {
  38. url: "live",
  39. auth: false,
  40. method: "GET",
  41. // desc: '直播列表',
  42. },
  43. wxJssdk: {
  44. url: "wechat/jssdk",
  45. auth: false,
  46. method: "POST",
  47. // desc: '微信Jssdk',
  48. },
  49. syncPages: {
  50. url: "index/asyncPages",
  51. auth: false,
  52. method: "POST",
  53. // desc: '路由表 DEV开发模式下有效',end
  54. },
  55. debug: {
  56. url: "index/debugLog",
  57. auth: false,
  58. method: "POST",
  59. // desc: '上传DEBUG信息',
  60. },
  61. richText: {
  62. url: "index/richtext",
  63. auth: false,
  64. method: "GET",
  65. // desc: '富文本数据',
  66. },
  67. shareAdd: {
  68. url: "share/add",
  69. auth: false,
  70. method: "POST",
  71. // desc: '添加分享记录',
  72. },
  73. smsSend: {
  74. url: "sms/send",
  75. auth: false,
  76. method: "POST",
  77. // desc: '发送短信',
  78. },
  79. },
  80. /** 分类 ↓ **/
  81. category: {
  82. info: {
  83. url: "category/detail",
  84. auth: false,
  85. method: "GET",
  86. // desc: '分类类别',
  87. },
  88. detail: {
  89. url: "category",
  90. auth: false,
  91. method: "GET",
  92. // desc: '分类详情',
  93. },
  94. list: {
  95. url: "category/list",
  96. auth: false,
  97. method: "GET",
  98. // desc: '首页分类商品列表',
  99. }
  100. },
  101. /** 门店 ↓ **/
  102. store: {
  103. list: {
  104. url: "store/index",
  105. auth: true,
  106. method: "GET",
  107. // desc: '商户列表,不需要storeId',
  108. },
  109. info: {
  110. url: "store.store/index",
  111. auth: true,
  112. method: "GET",
  113. // desc: '商户信息',
  114. },
  115. order: {
  116. url: "store.order/index",
  117. auth: true,
  118. method: "GET",
  119. // desc: '商户订单',
  120. },
  121. orderDetail: {
  122. url: "store.order/detail",
  123. auth: true,
  124. method: "GET",
  125. // desc: '订单详情',
  126. },
  127. orderSend: {
  128. url: "store.order/send",
  129. auth: true,
  130. method: "POST",
  131. // desc: '订单发货',
  132. },
  133. orderConfirm: {
  134. url: "store.order/confirm",
  135. auth: true,
  136. method: "POST",
  137. // desc: '核销订单',
  138. },
  139. apply: {
  140. url: "store.apply/apply",
  141. auth: true,
  142. method: "POST",
  143. // desc: '申请门店',
  144. },
  145. shopInfo: {
  146. url: "store.apply/info",
  147. auth: true,
  148. method: "POST",
  149. // desc: '门店信息',
  150. }
  151. },
  152. /** 商品 ↓ **/
  153. goods: {
  154. lists: {
  155. url: "goods/lists",
  156. auth: false,
  157. method: "GET",
  158. // desc: '商品列表',
  159. },
  160. seckillList: {
  161. url: "goods/seckillList",
  162. auth: false,
  163. method: "GET",
  164. // desc: '秒杀列表',
  165. },
  166. activity: {
  167. url: "goods/activity",
  168. auth: false,
  169. method: "GET",
  170. // desc: '活动商品',
  171. },
  172. myGroupon: {
  173. url: "activity_groupon/myGroupon",
  174. auth: true,
  175. method: "GET",
  176. // desc: '我的拼团',
  177. },
  178. grouponDetail: {
  179. url: "activity_groupon/detail",
  180. auth: false,
  181. method: "GET",
  182. // desc: '拼团详情',
  183. },
  184. grouponItem: {
  185. url: "activity_groupon/index",
  186. auth: false,
  187. method: "GET",
  188. // desc: '拼购列表',
  189. },
  190. grouponList: {
  191. url: "goods/grouponList",
  192. auth: false,
  193. method: "GET",
  194. // desc: '拼团商品列表',
  195. },
  196. detail: {
  197. url: "goods/detail",
  198. auth: false,
  199. method: "GET",
  200. // desc: '商品详情',
  201. },
  202. favorite: {
  203. url: "goods/favorite",
  204. auth: true,
  205. method: "POST",
  206. // desc: '商品收藏',
  207. },
  208. storeAddress: {
  209. url: "goods/store",
  210. auth: true,
  211. method: "GET",
  212. // desc: '商品支持的自提点',
  213. },
  214. scoreList: {
  215. url: "score_goods_sku_price/index",
  216. auth: false,
  217. method: "GET",
  218. // desc: '积分商品列表',
  219. },
  220. scoreDetail: {
  221. url: "score_goods_sku_price/detail",
  222. auth: false,
  223. method: "GET",
  224. // desc: '积分详情',
  225. },
  226. commentList: {
  227. url: "goods_comment/index",
  228. auth: false,
  229. method: "GET",
  230. // desc: '商品评论列表',
  231. },
  232. commentType: {
  233. url: "goods_comment/type",
  234. auth: false,
  235. method: "GET",
  236. // desc: '商品评论分类',
  237. },
  238. },
  239. /** 用户 ↓ **/
  240. user: {
  241. accountLogin: {
  242. url: "user/accountLogin",
  243. auth: false,
  244. method: "POST",
  245. // desc: '账号密码登录',
  246. },
  247. smsLogin: {
  248. url: "user/smsLogin",
  249. auth: false,
  250. method: "POST",
  251. // desc: '短信登录',
  252. },
  253. register: {
  254. url: "user/register",
  255. auth: false,
  256. method: "POST",
  257. // desc: '注册',
  258. },
  259. forgotPwd: {
  260. url: "user/forgotPwd",
  261. auth: false,
  262. method: "POST",
  263. // desc: '重置密码',
  264. },
  265. bindMobile: {
  266. url: "user/bindMobile",
  267. auth: true,
  268. method: "POST",
  269. // desc: '修改手机号',
  270. },
  271. changePwd: {
  272. url: "user/changePwd",
  273. auth: true,
  274. method: "POST",
  275. // desc: '修改密码',
  276. },
  277. info: {
  278. url: "user",
  279. auth: true,
  280. method: "GET",
  281. // desc: '用户信息',end
  282. },
  283. profile: {
  284. url: "user/profile",
  285. auth: true,
  286. method: "POST",
  287. // desc: '修改用户信息',end
  288. },
  289. logout: {
  290. url: "user/logout",
  291. auth: true,
  292. method: "POST",
  293. // desc: '退出登录',end
  294. },
  295. getWxMiniProgramSessionKey: {
  296. url: "user/getWxMiniProgramSessionKey",
  297. auth: false,
  298. method: "POST",
  299. // desc: '获取用户session_key',
  300. },
  301. wxMiniProgramOauth: {
  302. url: "user/wxMiniProgramOauth",
  303. auth: false,
  304. method: "POST",
  305. // desc: '微信小程序登录',
  306. },
  307. wxOpenPlatformOauth: {
  308. url: "user/wxOpenPlatformOauth",
  309. auth: false,
  310. method: "POST",
  311. // desc: '微信APP登录',
  312. },
  313. thirdOauthInfo: {
  314. url: "user/thirdOauthInfo",
  315. auth: true,
  316. method: "GET",
  317. // desc: '第三方绑定信息',
  318. },
  319. unbindThirdOauth: {
  320. url: "user/unbindThirdOauth",
  321. auth: true,
  322. method: "POST",
  323. // desc: '解绑信息',
  324. },
  325. signList: {
  326. url: "user_sign/index",
  327. auth: true,
  328. method: "GET",
  329. // desc: '签到记录',
  330. },
  331. sign: {
  332. url: "user_sign/sign",
  333. auth: true,
  334. method: "POST",
  335. // desc: '签到',
  336. },
  337. messageIds: {
  338. url: "notification/template",
  339. auth: false,
  340. method: "GET",
  341. // desc: '订阅消息模板ids',
  342. },
  343. favoriteList: {
  344. url: "goods/favoriteList",
  345. auth: true,
  346. method: "GET",
  347. // desc: '商品收藏列表',
  348. },
  349. viewList: {
  350. url: "goods/viewList",
  351. auth: true,
  352. method: "GET",
  353. // desc: '足迹列表',end
  354. },
  355. viewDelete: {
  356. url: "goods/viewDelete",
  357. auth: true,
  358. method: "POST",
  359. // desc: '删除足迹',end
  360. },
  361. userData: {
  362. url: "user/userData",
  363. auth: true,
  364. method: "GET",
  365. // desc: '用户其他信息',
  366. },
  367. appleIdOauth: {
  368. url: "user/appleIdOauth",
  369. auth: false,
  370. method: "POST",
  371. // desc: 'appleId授权',
  372. }
  373. },
  374. /** 位置 ↓ **/
  375. address: {
  376. area: {
  377. url: "address/area",
  378. auth: false,
  379. method: "GET",
  380. // desc: '省市区',
  381. },
  382. list: {
  383. url: "address",
  384. auth: true,
  385. method: "GET",
  386. // desc: '地址列表',
  387. },
  388. edit: {
  389. url: "address/edit",
  390. auth: true,
  391. method: "POST",
  392. // desc: '修改地址',
  393. },
  394. defaults: {
  395. url: "address/defaults",
  396. auth: true,
  397. method: "GET",
  398. // desc: '默认地址',
  399. },
  400. info: {
  401. url: "address/info",
  402. auth: true,
  403. method: "GET",
  404. // desc: '地址详情',
  405. },
  406. del: {
  407. url: "address/del",
  408. auth: true,
  409. method: "POST",
  410. // desc: '删除',
  411. },
  412. },
  413. /** 常见问题 ↓ **/
  414. other: {
  415. faqList: {
  416. url: "faq",
  417. auth: false,
  418. method: "GET",
  419. // desc: '常见问题列表',
  420. },
  421. feedbackType: {
  422. url: "feedback/type",
  423. auth: true,
  424. method: "GET",
  425. // desc: '意见反馈类型',
  426. },
  427. feedbackAdd: {
  428. url: "feedback/add",
  429. auth: true,
  430. method: "POST",
  431. // desc: '提交意见',
  432. },
  433. commentAdd: {
  434. url: "comment/submit",
  435. auth: true,
  436. method: "POST",
  437. // desc: '提交评论',
  438. },
  439. commentList: {
  440. url: "comment/list",
  441. auth: true,
  442. method: "GET",
  443. // desc: '评论列表',
  444. }
  445. },
  446. /** 购物车 ↓ **/
  447. cart: {
  448. index: {
  449. url: "cart",
  450. auth: true,
  451. method: "POST",
  452. // desc: '购物车商品列表',
  453. },
  454. add: {
  455. url: "cart/add",
  456. auth: true,
  457. method: "POST",
  458. // desc: '添加购物车',
  459. },
  460. edit: {
  461. url: "cart/edit",
  462. auth: true,
  463. method: "POST",
  464. // desc: '编辑购物车',
  465. },
  466. },
  467. /** 订单 ↓ **/
  468. order: {
  469. index: {
  470. url: "order/index",
  471. auth: true,
  472. method: "GET",
  473. // desc: '订单列表',
  474. },
  475. pre: {
  476. url: "order/pre",
  477. auth: true,
  478. method: "POST",
  479. // desc: '预备提交订单',
  480. },
  481. createOrder: {
  482. url: "order/createOrder",
  483. auth: true,
  484. method: "POST",
  485. // desc: '提交订单',
  486. },
  487. detail: {
  488. url: "order/detail",
  489. auth: true,
  490. method: "GET",
  491. // desc: '订单详情',
  492. },
  493. itemDetail: {
  494. url: "order/itemDetail",
  495. auth: true,
  496. method: "GET",
  497. // desc: '订单商品详情',
  498. },
  499. confirm: {
  500. url: "order/confirm",
  501. auth: true,
  502. method: "POST",
  503. // desc: '确认收货',
  504. },
  505. cancel: {
  506. url: "order/cancel",
  507. auth: true,
  508. method: "POST",
  509. // desc: '取消订单',
  510. },
  511. comment: {
  512. url: "order/comment",
  513. auth: true,
  514. method: "POST",
  515. // desc: '评价商品',
  516. },
  517. coupons: {
  518. url: "order/coupons",
  519. auth: true,
  520. method: "POST",
  521. // desc: '商品可用优惠券',
  522. },
  523. aftersale: {
  524. url: "order_aftersale/aftersale",
  525. auth: true,
  526. method: "POST",
  527. // desc: '申请售后',
  528. },
  529. aftersaleList: {
  530. url: "order_aftersale/index",
  531. auth: true,
  532. method: "GET",
  533. // desc: '售后列表',
  534. },
  535. aftersaleDetail: {
  536. url: "order_aftersale/detail",
  537. auth: true,
  538. method: "GET",
  539. // desc: '售后列表详情',
  540. },
  541. deleteOrder: {
  542. url: "order/delete",
  543. auth: true,
  544. method: "POST",
  545. // desc: '删除订单',
  546. },
  547. deleteAftersaleOrder: {
  548. url: "order_aftersale/delete",
  549. auth: true,
  550. method: "POST",
  551. // desc: '删除售后订单',
  552. },
  553. cancelAftersaleOrder: {
  554. url: "order_aftersale/cancel",
  555. auth: true,
  556. method: "POST",
  557. // desc: '取消售后订单',
  558. },
  559. expressList: {
  560. url: "order_express/index",
  561. auth: true,
  562. method: "GET",
  563. // desc: '包裹列表',
  564. },
  565. expressDetail: {
  566. url: "order_express/detail",
  567. auth: true,
  568. method: "GET",
  569. // desc: '包裹详情',
  570. },
  571. itemDetail: {
  572. url: "order/itemDetail",
  573. auth: true,
  574. method: "GET",
  575. // desc: '订单商品详情',
  576. }
  577. },
  578. /** 支付金钱 ↓ **/
  579. money: {
  580. prepay: {
  581. url: "pay/prepay",
  582. auth: true,
  583. method: "POST",
  584. // desc: '发起支付',
  585. },
  586. walletApply: {
  587. url: "user_wallet_apply/apply",
  588. auth: true,
  589. method: "POST",
  590. // desc: '申请提现',end
  591. },
  592. walletRule: {
  593. url: "user_wallet_apply/rule",
  594. auth: true,
  595. method: "GET",
  596. // desc: '提现规则',end
  597. },
  598. walletLog: {
  599. url: "user_wallet_log",
  600. auth: true,
  601. method: "GET",
  602. // desc: '钱包,积分明细',end
  603. },
  604. bankInfo: {
  605. url: "user_bank/info",
  606. auth: true,
  607. method: "GET",
  608. // desc: '银行卡信息',end
  609. },
  610. bankEdit: {
  611. url: "user_bank/edit",
  612. auth: true,
  613. method: "POST",
  614. // desc: '编辑银行卡信息',end
  615. },
  616. withdrawLog: {
  617. url: "user_wallet_apply/index",
  618. auth: true,
  619. method: "GET",
  620. // desc: '提现记录',end
  621. },
  622. recharge: {
  623. url: "trade_order/recharge",
  624. auth: true,
  625. method: "POST",
  626. // desc: '充值'
  627. },
  628. rechargeLog: {
  629. url: "trade_order/index",
  630. auth: true,
  631. method: "GET",
  632. // desc: '充值记录'
  633. },
  634. rechargeDetail: {
  635. url: "trade_order/detail",
  636. auth: true,
  637. method: "GET",
  638. // desc: '充值订单详情'
  639. }
  640. },
  641. /** 优惠券 ↓ **/
  642. coupons: {
  643. list: {
  644. url: "coupons",
  645. auth: false,
  646. method: "GET",
  647. // desc: '个人中心优惠券列表',
  648. },
  649. templateList: {
  650. url: "coupons/lists",
  651. auth: false,
  652. method: "GET",
  653. // desc: '首页优惠券',
  654. },
  655. get: {
  656. url: "coupons/get",
  657. auth: true,
  658. method: "GET",
  659. // desc: '领取',
  660. },
  661. detail: {
  662. url: "coupons/detail",
  663. auth: true,
  664. method: "GET",
  665. // desc: '购物券详情',
  666. },
  667. goods: {
  668. url: "coupons/goods",
  669. auth: false,
  670. method: "GET",
  671. // desc: '适用商品',
  672. }
  673. },
  674. /** 分销 ↓ **/
  675. commission: {
  676. auth: {
  677. url: "commission.agent/info",
  678. auth: true,
  679. method: "GET",
  680. // desc: '分销身份鉴权',
  681. },
  682. log: {
  683. url: "commission.log/index",
  684. auth: true,
  685. method: "GET",
  686. // desc: '分销动态',
  687. },
  688. goods: {
  689. url: "commission.goods/index",
  690. auth: true,
  691. method: "GET",
  692. // desc: '分销商品',
  693. },
  694. ranking: {
  695. url: "commission.agent/ranking",
  696. auth: true,
  697. method: "GET",
  698. // desc: '分销商排行榜',
  699. },
  700. form: {
  701. url: "commission.agent/agentForm",
  702. auth: true,
  703. method: "GET",
  704. // desc: '申请成为分销商表单',
  705. },
  706. apply: {
  707. url: "commission.agent/applyForm",
  708. auth: true,
  709. method: "POST",
  710. // desc: '申请成为分销商',
  711. },
  712. team: {
  713. url: "commission.agent/team",
  714. auth: true,
  715. method: "GET",
  716. // desc: '我的团队',
  717. },
  718. share: {
  719. url: "share/index",
  720. auth: true,
  721. method: "GET",
  722. // desc: '分享记录',
  723. },
  724. orderLog: {
  725. url: "commission.order/index",
  726. auth: true,
  727. method: "GET",
  728. // desc: '分销订单',
  729. },
  730. rewardLog: {
  731. url: "commission.reward/index",
  732. auth: true,
  733. method: "GET",
  734. // desc: '佣金记录',
  735. },
  736. lv: {
  737. url: "commission.agent/level",
  738. auth: true,
  739. method: "GET",
  740. // desc: '佣金记录',
  741. }
  742. }
  743. };