作者 lyh

gx

... ... @@ -63,6 +63,27 @@ class ProjectController extends BaseController
}
/**
* @remark :搜索参数处理
* @name :searchParam
* @author :lyh
* @method :post
* @time :2023/8/18 10:58
*/
public function searchParam(&$query){
//参数type
$query = $this->searchType($query);
//根据查看权限获取项目搜索条件(必带)
$query = $this->getManagerRole($query);
//搜索技术组
$query = $this->searchDept($query);
//搜索技术人员
$query = $this->searchManager($query);
//按类型搜索
$query = $this->searchContent($query);
return $query;
}
/**
* @remark :type类型
* @name :searchType
* @author :lyh
... ... @@ -128,26 +149,6 @@ class ProjectController extends BaseController
];
return $select;
}
/**
* @remark :搜索参数处理
* @name :searchParam
* @author :lyh
* @method :post
* @time :2023/8/18 10:58
*/
public function searchParam(&$query){
//参数type
$query = $this->searchType($query);
//根据查看权限获取项目搜索条件(必带)
$query = $this->getManagerRole($query);
//搜索技术组
$query = $this->searchDept($query);
//搜索技术人员
$query = $this->searchManager($query);
//按类型搜索
$query = $this->searchContent($query);
return $query;
}
/**
* @remark :按需搜索
... ... @@ -268,7 +269,10 @@ class ProjectController extends BaseController
$item['plan'] = Project::planMap()[$item['plan']];
$item['created_at'] = date('Y年m月d日', strtotime($item['created_at']));
$item['autologin_code'] = getAutoLoginCode($item['id']);
$domainModel = new DomainInfo();
$item['domain'] = !empty($item['domain']) ? $domainModel->getDomain($item['domain']) : '';
$item['product_num'] = $data['product'] ?? 0;
$item['keyword_num'] = $item['key'] ?? 0;
$item['autologin_code'] = getAutoLoginCode($item['id']);
$item['article_num'] = ($data['blog'] ?? 0) + ($data['news'] ?? 0);
$item['task_finish_num'] = Task::getNumByProjectId($item['id'], Task::STATUS_DOWN);
... ...