GroupPurchaseController.php 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <?php
  2. namespace app\modules\client\controllers\v1\shareGroup;
  3. use app\modules\client\controllers\BaseController;
  4. use app\modules\client\models\v1\shareGroup\GroupPurchaseForm;
  5. class GroupPurchaseController extends BaseController
  6. {
  7. //拼购区中心
  8. public function actionIndex() {
  9. $form = new GroupPurchaseForm();
  10. $form->attributes = get_params();
  11. $form->store_id = get_store_id();
  12. $form->user_id = get_user_id();
  13. $form->saas_id = get_saas_user_id();
  14. return $this->asJson($form->groupPurchaseCenter());
  15. }
  16. //拼购区商品
  17. public function actionGoodsList() {
  18. $form = new GroupPurchaseForm();
  19. $form->attributes = get_params();
  20. $form->store_id = get_store_id();
  21. return $this->asJson($form->goodsList());
  22. }
  23. //我的拼购订单
  24. public function actionGroupPurchaseOrder() {
  25. $form = new GroupPurchaseForm();
  26. $form->attributes = get_params();
  27. $form->user_id = get_user_id();
  28. $form->store_id = get_store_id();
  29. return $this->asJson($form->groupPurchaseOrder());
  30. }
  31. //拼购参团订单
  32. public function actionGroupPurchaseDetail() {
  33. $form = new GroupPurchaseForm();
  34. $form->attributes = get_params();
  35. $form->user_id = get_user_id();
  36. $form->store_id = get_store_id();
  37. return $this->asJson($form->groupPurchaseDetail());
  38. }
  39. //冻结佣金
  40. public function actionFreezeMoney() {
  41. $form = new GroupPurchaseForm();
  42. $form->attributes = get_params();
  43. $form->user_id = get_user_id();
  44. $form->store_id = get_store_id();
  45. return $this->asJson($form->freezeMoney());
  46. }
  47. //冻结佣金明细
  48. public function actionFreezeMoneyList() {
  49. $form = new GroupPurchaseForm();
  50. $form->attributes = get_params();
  51. $form->user_id = get_user_id();
  52. $form->store_id = get_store_id();
  53. return $this->asJson($form->freezeMoneyList());
  54. }
  55. //佣金明细(包含冻结)
  56. public function actionMoneyList() {
  57. $form = new GroupPurchaseForm();
  58. $form->attributes = get_params();
  59. $form->user_id = get_user_id();
  60. $form->store_id = get_store_id();
  61. return $this->asJson($form->moneyList());
  62. }
  63. //帮扶区
  64. public function actionSupportList() {
  65. $form = new GroupPurchaseForm();
  66. $form->attributes = get_params();
  67. $form->user_id = get_user_id();
  68. $form->store_id = get_store_id();
  69. return $this->asJson($form->supportList());
  70. }
  71. }