master
cody 3 weeks ago
parent 91748327fb
commit 38e29c7040

@ -48,7 +48,7 @@ class CompanyController extends BaseController
// 企业标签
$companiesTags = Company::where('company_tag', '!=', '')->pluck('company_tag');
$companiesTags = $companiesTags->flatten()->implode(',');
$companiesTags =array_unique(explode(',', $companiesTags));
$companiesTags = array_unique(explode(',', $companiesTags));
// 去除$companiesTags中包含小数点的元素
$companiesTags = array_filter($companiesTags, function ($item) {
return !strpos($item, '.');
@ -96,10 +96,12 @@ class CompanyController extends BaseController
if (!isset($key) || !isset($op) || !isset($value)) {
continue;
}
if ($key == 'company_tag' && $value == '被投企业') {
$query->where('is_yh_invested', 1);
if ($key == 'company_tag') {
$valueArray = explode(',', $value);
$query->whereIn($key, $valueArray);
continue;
}
// 等于
if ($op == 'eq') {
$query->where($key, $value);

Loading…
Cancel
Save