shop.php 3.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. <?php
  2. // +----------------------------------------------------------------------
  3. // | Niucloud-mall 企业快速开发的多应用管理平台
  4. // +----------------------------------------------------------------------
  5. // | 官方网址:https://www.niucloud.com
  6. // +----------------------------------------------------------------------
  7. // | niucloud团队 版权所有 开源版本可自由商用
  8. // +----------------------------------------------------------------------
  9. // | Author: Niucloud Team
  10. // +----------------------------------------------------------------------
  11. use app\api\middleware\ApiChannel;
  12. use app\api\middleware\ApiCheckToken;
  13. use app\api\middleware\ApiLog;
  14. use think\facade\Route;
  15. /**
  16. * 商城系统
  17. */
  18. Route::group('shop/web', function() {
  19. /***************************************************** 店铺列表 ****************************************************/
  20. // 店铺列表
  21. Route::get('shop', 'shop.Shop/lists');
  22. // 甄选好店列表(web端)
  23. Route::get('select_shop_list', 'shop.Shop/selectShopLists');
  24. // 店铺列表(wap端)
  25. Route::get('shop_list', 'shop.Shop/shopLists');
  26. // 店铺列表
  27. Route::get('shop/all', 'shop.Shop/all');
  28. // 店铺分类
  29. Route::get('shop_category', 'shop.ShopCategory/all');
  30. // 店铺详情
  31. Route::get('shop/:id', 'shop.Shop/info');
  32. // 品牌好店组件
  33. Route::get('shop/component', 'shop.Shop/components');
  34. // 店铺二维码
  35. Route::get('shop/qrcode/:id', 'shop.Shop/qrcode');
  36. // 店铺申请状态
  37. Route::get('shop_apply/status', 'shop.ShopApply/statusList');
  38. /***************************************************** 店铺转账 ****************************************************/
  39. // 店铺提现详情
  40. Route::get('cash_out/:id', 'shop.ShopCashOut/info');
  41. // 转账校验
  42. Route::get('cash_out/transfer/check', 'shop.ShopCashOut/checkTransfer');
  43. })->middleware(ApiChannel::class)
  44. ->middleware(ApiCheckToken::class)//false表示不验证登录
  45. ->middleware(ApiLog::class);
  46. Route::group('shop/web', function() {
  47. /***************************************************** 店铺申请 ****************************************************/
  48. // 店铺申请列表
  49. Route::get('shop_apply', 'shop.ShopApply/lists');
  50. // 店铺申请
  51. Route::post('shop_apply', 'shop.ShopApply/add');
  52. // 店铺申请详情
  53. Route::get('shop_apply/:id', 'shop.ShopApply/info');
  54. // 店铺申请编辑
  55. Route::put('shop_apply/:id', 'shop.ShopApply/edit');
  56. // 店铺分类列表
  57. Route::get('shop_apply/shop_category', 'shop.ShopApply/shopCategory');
  58. // 店铺套餐列表
  59. Route::get('shop_apply/site_group', 'shop.ShopApply/shopSiteGroup');
  60. // 店铺申请协议
  61. Route::get('shop_apply/agreement', 'shop.ShopApply/agreement');
  62. /***************************************************** 店铺收藏 ****************************************************/
  63. // 店铺收藏
  64. Route::put('shop/:id/:is_follow', 'shop.Shop/follow');
  65. // 店铺收藏列表
  66. Route::get('follow', 'shop.ShopMember/lists');
  67. /***************************************************** 店铺转账 ****************************************************/
  68. // 转账
  69. Route::post('cash_out/transfer/:id', 'shop.ShopCashOut/transfer');
  70. })->middleware(ApiChannel::class)
  71. ->middleware(ApiCheckToken::class, true)//表示验证登录
  72. ->middleware(ApiLog::class);