作者 李宇航

合并分支 'lyh-server' 到 'master'

gx



查看合并请求 !1765
@@ -29,7 +29,6 @@ class ProjectCountryLogic extends BaseLogic @@ -29,7 +29,6 @@ class ProjectCountryLogic extends BaseLogic
29 } 29 }
30 $lists['country_lists'] = $this->countryListsFormat($lists['country_lists']); 30 $lists['country_lists'] = $this->countryListsFormat($lists['country_lists']);
31 $lists['country_sort'] = $this->countrySortFormat($lists['country_sort']); 31 $lists['country_sort'] = $this->countrySortFormat($lists['country_sort']);
32 -  
33 return $this->success($lists); 32 return $this->success($lists);
34 } 33 }
35 34
@@ -116,12 +115,9 @@ class ProjectCountryLogic extends BaseLogic @@ -116,12 +115,9 @@ class ProjectCountryLogic extends BaseLogic
116 } 115 }
117 116
118 protected function countrySortFormat($country_sort){ 117 protected function countrySortFormat($country_sort){
119 - if(empty($country_sort)){  
120 - $webLanguageModel = new WebLanguage();  
121 - $all_language_ids = array_column($webLanguageModel->list([],'id',['id'],'asc'),'id');  
122 - $country_sort = implode(',',$all_language_ids);  
123 - }  
124 -  
125 - return $country_sort; 118 + $webLanguageModel = new WebLanguage();
  119 + $idArr = $webLanguageModel->selectField(['id'=>['not in',explode(',',$country_sort)]],'id');
  120 + $countryStr = $country_sort.','.implode(',',$idArr);
  121 + return $countryStr;
126 } 122 }
127 } 123 }