作者 lyh

gx

@@ -3,6 +3,7 @@ @@ -3,6 +3,7 @@
3 namespace App\Http\Logic\Bside\Setting; 3 namespace App\Http\Logic\Bside\Setting;
4 4
5 use App\Http\Logic\Bside\BaseLogic; 5 use App\Http\Logic\Bside\BaseLogic;
  6 +use App\Models\Project\Country;
6 use App\Models\Project\Country as CountryModel; 7 use App\Models\Project\Country as CountryModel;
7 use App\Models\WebSetting\WebSettingCountry; 8 use App\Models\WebSetting\WebSettingCountry;
8 9
@@ -23,8 +24,7 @@ class WebSettingCountryLogic extends BaseLogic @@ -23,8 +24,7 @@ class WebSettingCountryLogic extends BaseLogic
23 * @time :2023/4/28 16:18 24 * @time :2023/4/28 16:18
24 */ 25 */
25 public function country_list(){ 26 public function country_list(){
26 - $settingCountryModel = new WebSettingCountry();  
27 - $lists = $settingCountryModel->list($this->param,'id',['id','name','image']); 27 + $lists = $this->model->list($this->param,'id',['id','name','image']);
28 if (empty($lists)){ 28 if (empty($lists)){
29 $this->fail('当前数据不存在'); 29 $this->fail('当前数据不存在');
30 } 30 }
@@ -38,7 +38,8 @@ class WebSettingCountryLogic extends BaseLogic @@ -38,7 +38,8 @@ class WebSettingCountryLogic extends BaseLogic
38 * @time :2023/4/28 17:03 38 * @time :2023/4/28 17:03
39 */ 39 */
40 public function get_country_info(){ 40 public function get_country_info(){
41 - $lists = $this->model->read(['project_id'=>$this->param['project_id']]); 41 + $countryModel = new CountryModel();
  42 + $lists = $countryModel->read(['project_id'=>$this->param['project_id']]);
42 if (empty($lists)){ 43 if (empty($lists)){
43 $this->fail('当前数据不存在'); 44 $this->fail('当前数据不存在');
44 } 45 }