LjhController.php 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. namespace pt\controllers;
  3. use bizHd\ljh\classes\LjhApplyClass;
  4. use common\components\util;
  5. use Yii;
  6. class LjhController extends BaseController
  7. {
  8. public $guestAccess = ['list'];
  9. //申请列表
  10. public function actionList()
  11. {
  12. ini_set('memory_limit', '2045M');
  13. set_time_limit(0);
  14. $list = LjhApplyClass::getAllByCondition(['status' => 2], 'payTime DESC', '*');
  15. if (empty($list)) {
  16. echo '暂无报名';
  17. }
  18. echo "<table border='1'>";
  19. echo "<tr><th>花店名称</th><th>姓名</th><th>手机号</th><th>头像</th><th>报名费</th><th>地址</th></tr>";
  20. foreach ($list as $custom) {
  21. $shopName = $custom['name'] ?? '';
  22. $adminName = $custom['adminName'] ?? '';
  23. $mobile = $custom['mobile'] ?? '';
  24. $cover = $custom['cover'] ?? '';
  25. $actPrice = $custom['actPrice'] ?? 0;
  26. $address = $custom['address'] ?? '';
  27. echo "<tr>";
  28. echo "<td>{$shopName}</td><td>{$adminName}</td><td>{$mobile}</td><td>{$cover}</td><td>{$actPrice}</td><td>{$address}</td>";
  29. echo "</tr>";
  30. }
  31. echo "</table>";
  32. }
  33. }