HdController.php 683 B

123456789101112131415161718192021222324252627
  1. <?php
  2. namespace mall\controllers;
  3. use bizHd\custom\classes\CustomClass;
  4. use bizHd\custom\classes\HdClass;
  5. use common\components\httpUtil;
  6. use common\components\util;
  7. class HdController extends BaseController
  8. {
  9. public function actionList()
  10. {
  11. $showGlInfo = getenv('SHOW_GL_INFO');
  12. $info = $showGlInfo === false ? 1 : $showGlInfo;
  13. if (isset($this->userId) || empty($this->userId)) {
  14. util::success(['list' => [], 'showGlInfo' => $info]);
  15. }
  16. $where = [];
  17. $where['userId'] = $this->userId;
  18. $respond = HdClass::getHdList($where);
  19. $respond['showGlInfo'] = $info;
  20. util::success($respond);
  21. }
  22. }