作者 lyh

gx

@@ -58,6 +58,9 @@ class Count extends Command @@ -58,6 +58,9 @@ class Count extends Command
58 $v['test_domain'] = $info['domain']; 58 $v['test_domain'] = $info['domain'];
59 } 59 }
60 } 60 }
  61 + if($v['type'] == Project::TYPE_ZERO){
  62 + continue;
  63 + }
61 $arr = []; 64 $arr = [];
62 //统计时间 65 //统计时间
63 $arr['date'] = $yesterday; 66 $arr['date'] = $yesterday;
@@ -168,6 +171,7 @@ class Count extends Command @@ -168,6 +171,7 @@ class Count extends Command
168 public function selectParam(){ 171 public function selectParam(){
169 $select = [ 172 $select = [
170 'gl_project.id AS id', 173 'gl_project.id AS id',
  174 + 'gl_project.type AS type',
171 'gl_project.extend_type AS extend_type', 175 'gl_project.extend_type AS extend_type',
172 'gl_project_deploy_build.test_domain AS test_domain', 176 'gl_project_deploy_build.test_domain AS test_domain',
173 'gl_project_deploy_optimize.domain AS domain', 177 'gl_project_deploy_optimize.domain AS domain',
@@ -4,6 +4,7 @@ namespace App\Console\Commands\MonthlyCount; @@ -4,6 +4,7 @@ namespace App\Console\Commands\MonthlyCount;
4 4
5 use App\Helper\FormGlobalsoApi; 5 use App\Helper\FormGlobalsoApi;
6 use App\Models\Domain\DomainInfo; 6 use App\Models\Domain\DomainInfo;
  7 +use App\Models\Project\Project;
7 use App\Services\ProjectServer; 8 use App\Services\ProjectServer;
8 use Carbon\Carbon; 9 use Carbon\Carbon;
9 use Illuminate\Console\Command; 10 use Illuminate\Console\Command;
@@ -45,6 +46,9 @@ class InquiryMonthlyCount extends Command @@ -45,6 +46,9 @@ class InquiryMonthlyCount extends Command
45 $endTime = Carbon::now()->subMonth()->endOfMonth()->toDateString(); 46 $endTime = Carbon::now()->subMonth()->endOfMonth()->toDateString();
46 $domainInfo = new DomainInfo(); 47 $domainInfo = new DomainInfo();
47 foreach ($list as $value){ 48 foreach ($list as $value){
  49 + if($value['type'] == Project::TYPE_ZERO){
  50 + continue;
  51 + }
48 $value = (array)$value; 52 $value = (array)$value;
49 if(!empty($value['domain'])){ 53 if(!empty($value['domain'])){
50 $info = $domainInfo->read(['id'=>$value['domain']]); 54 $info = $domainInfo->read(['id'=>$value['domain']]);
@@ -177,6 +181,7 @@ class InquiryMonthlyCount extends Command @@ -177,6 +181,7 @@ class InquiryMonthlyCount extends Command
177 public function selectParam(){ 181 public function selectParam(){
178 $select = [ 182 $select = [
179 'gl_project.id AS id', 183 'gl_project.id AS id',
  184 + 'gl_project.type AS type',
180 'gl_project.extend_type AS extend_type', 185 'gl_project.extend_type AS extend_type',
181 'gl_project_deploy_build.test_domain AS test_domain', 186 'gl_project_deploy_build.test_domain AS test_domain',
182 'gl_project_deploy_optimize.domain AS domain', 187 'gl_project_deploy_optimize.domain AS domain',
@@ -241,7 +241,7 @@ class SyncProject extends Command @@ -241,7 +241,7 @@ class SyncProject extends Command
241 $projectModel = new Project(); 241 $projectModel = new Project();
242 $info = $projectModel->read(['from_order_id'=>$param['from_order_id']]); 242 $info = $projectModel->read(['from_order_id'=>$param['from_order_id']]);
243 if($info !== false){ 243 if($info !== false){
244 - $projectModel->edit($param, ['from_order_id' => $param['from_order_id']]); 244 + $projectModel->edit($param, ['id' => $info['id']]);
245 return $info['id']; 245 return $info['id'];
246 }else{ 246 }else{
247 return $projectModel->addReturnId($param); 247 return $projectModel->addReturnId($param);