正在显示
1 个修改的文件
包含
24 行增加
和
20 行删除
| @@ -63,6 +63,27 @@ class ProjectController extends BaseController | @@ -63,6 +63,27 @@ class ProjectController extends BaseController | ||
| 63 | } | 63 | } |
| 64 | 64 | ||
| 65 | /** | 65 | /** |
| 66 | + * @remark :搜索参数处理 | ||
| 67 | + * @name :searchParam | ||
| 68 | + * @author :lyh | ||
| 69 | + * @method :post | ||
| 70 | + * @time :2023/8/18 10:58 | ||
| 71 | + */ | ||
| 72 | + public function searchParam(&$query){ | ||
| 73 | + //参数type | ||
| 74 | + $query = $this->searchType($query); | ||
| 75 | + //根据查看权限获取项目搜索条件(必带) | ||
| 76 | + $query = $this->getManagerRole($query); | ||
| 77 | + //搜索技术组 | ||
| 78 | + $query = $this->searchDept($query); | ||
| 79 | + //搜索技术人员 | ||
| 80 | + $query = $this->searchManager($query); | ||
| 81 | + //按类型搜索 | ||
| 82 | + $query = $this->searchContent($query); | ||
| 83 | + return $query; | ||
| 84 | + } | ||
| 85 | + | ||
| 86 | + /** | ||
| 66 | * @remark :type类型 | 87 | * @remark :type类型 |
| 67 | * @name :searchType | 88 | * @name :searchType |
| 68 | * @author :lyh | 89 | * @author :lyh |
| @@ -128,26 +149,6 @@ class ProjectController extends BaseController | @@ -128,26 +149,6 @@ class ProjectController extends BaseController | ||
| 128 | ]; | 149 | ]; |
| 129 | return $select; | 150 | return $select; |
| 130 | } | 151 | } |
| 131 | - /** | ||
| 132 | - * @remark :搜索参数处理 | ||
| 133 | - * @name :searchParam | ||
| 134 | - * @author :lyh | ||
| 135 | - * @method :post | ||
| 136 | - * @time :2023/8/18 10:58 | ||
| 137 | - */ | ||
| 138 | - public function searchParam(&$query){ | ||
| 139 | - //参数type | ||
| 140 | - $query = $this->searchType($query); | ||
| 141 | - //根据查看权限获取项目搜索条件(必带) | ||
| 142 | - $query = $this->getManagerRole($query); | ||
| 143 | - //搜索技术组 | ||
| 144 | - $query = $this->searchDept($query); | ||
| 145 | - //搜索技术人员 | ||
| 146 | - $query = $this->searchManager($query); | ||
| 147 | - //按类型搜索 | ||
| 148 | - $query = $this->searchContent($query); | ||
| 149 | - return $query; | ||
| 150 | - } | ||
| 151 | 152 | ||
| 152 | /** | 153 | /** |
| 153 | * @remark :按需搜索 | 154 | * @remark :按需搜索 |
| @@ -268,7 +269,10 @@ class ProjectController extends BaseController | @@ -268,7 +269,10 @@ class ProjectController extends BaseController | ||
| 268 | $item['plan'] = Project::planMap()[$item['plan']]; | 269 | $item['plan'] = Project::planMap()[$item['plan']]; |
| 269 | $item['created_at'] = date('Y年m月d日', strtotime($item['created_at'])); | 270 | $item['created_at'] = date('Y年m月d日', strtotime($item['created_at'])); |
| 270 | $item['autologin_code'] = getAutoLoginCode($item['id']); | 271 | $item['autologin_code'] = getAutoLoginCode($item['id']); |
| 272 | + $domainModel = new DomainInfo(); | ||
| 273 | + $item['domain'] = !empty($item['domain']) ? $domainModel->getDomain($item['domain']) : ''; | ||
| 271 | $item['product_num'] = $data['product'] ?? 0; | 274 | $item['product_num'] = $data['product'] ?? 0; |
| 275 | + $item['keyword_num'] = $item['key'] ?? 0; | ||
| 272 | $item['autologin_code'] = getAutoLoginCode($item['id']); | 276 | $item['autologin_code'] = getAutoLoginCode($item['id']); |
| 273 | $item['article_num'] = ($data['blog'] ?? 0) + ($data['news'] ?? 0); | 277 | $item['article_num'] = ($data['blog'] ?? 0) + ($data['news'] ?? 0); |
| 274 | $item['task_finish_num'] = Task::getNumByProjectId($item['id'], Task::STATUS_DOWN); | 278 | $item['task_finish_num'] = Task::getNumByProjectId($item['id'], Task::STATUS_DOWN); |
-
请 注册 或 登录 后发表评论