正在显示
1 个修改的文件
包含
9 行增加
和
0 行删除
| @@ -22,6 +22,7 @@ use App\Models\Com\UpdateLog; | @@ -22,6 +22,7 @@ use App\Models\Com\UpdateLog; | ||
| 22 | use App\Models\Devops\Servers; | 22 | use App\Models\Devops\Servers; |
| 23 | use App\Models\Devops\ServersIp; | 23 | use App\Models\Devops\ServersIp; |
| 24 | use App\Models\Domain\DomainInfo; | 24 | use App\Models\Domain\DomainInfo; |
| 25 | +use App\Models\Domain\DomainInfo as DomainInfoModel; | ||
| 25 | use App\Models\Industry\ProjectIndustryRelated; | 26 | use App\Models\Industry\ProjectIndustryRelated; |
| 26 | use App\Models\Inquiry\InquiryIP; | 27 | use App\Models\Inquiry\InquiryIP; |
| 27 | use App\Models\Inquiry\InquirySet; | 28 | use App\Models\Inquiry\InquirySet; |
| @@ -796,6 +797,14 @@ class ProjectLogic extends BaseLogic | @@ -796,6 +797,14 @@ class ProjectLogic extends BaseLogic | ||
| 796 | } | 797 | } |
| 797 | if($param['type'] == Project::TYPE_CLOSE){ | 798 | if($param['type'] == Project::TYPE_CLOSE){ |
| 798 | $param['site_status'] = 1;//关闭站点 | 799 | $param['site_status'] = 1;//关闭站点 |
| 800 | + $domainModel = new DomainInfoModel(); | ||
| 801 | + $domainInfo = $domainModel->read(['project_id'=>$this->param['id']],['id','domain','amp_status']); | ||
| 802 | + if($domainInfo){ | ||
| 803 | + $re = curl_get('https://'.$domainInfo['domain'].'/api/stop_or_start_website'); | ||
| 804 | + if(isset($re['status']) && $re['status'] !== 200){ | ||
| 805 | + $this->fail($re['message']); | ||
| 806 | + } | ||
| 807 | + } | ||
| 799 | } | 808 | } |
| 800 | //创建默认数据库 | 809 | //创建默认数据库 |
| 801 | if($param['type'] == Project::TYPE_ONE){ | 810 | if($param['type'] == Project::TYPE_ONE){ |
-
请 注册 或 登录 后发表评论