正在显示
1 个修改的文件
包含
3 行增加
和
3 行删除
| @@ -120,7 +120,6 @@ class SyncProject extends Command | @@ -120,7 +120,6 @@ class SyncProject extends Command | ||
| 120 | 'contract' => json_encode($param['files']), | 120 | 'contract' => json_encode($param['files']), |
| 121 | 'bill' => json_encode($param['images']), | 121 | 'bill' => json_encode($param['images']), |
| 122 | ]; | 122 | ]; |
| 123 | -// @file_put_contents(storage_path('logs/lyh_error.log'), var_export($data, true) . PHP_EOL, FILE_APPEND); | ||
| 124 | $renewModel = new ProjectRenew(); | 123 | $renewModel = new ProjectRenew(); |
| 125 | $rs = $renewModel->add($data); | 124 | $rs = $renewModel->add($data); |
| 126 | if($rs === false){ | 125 | if($rs === false){ |
| @@ -184,8 +183,8 @@ class SyncProject extends Command | @@ -184,8 +183,8 @@ class SyncProject extends Command | ||
| 184 | ]; | 183 | ]; |
| 185 | // DB::beginTransaction(); | 184 | // DB::beginTransaction(); |
| 186 | // try { | 185 | // try { |
| 187 | - $res = $this->saveProject($data['project']); | ||
| 188 | - $id = $res; | 186 | + $id = $this->saveProject($data['project']); |
| 187 | + @file_put_contents(storage_path('logs/lyh_error.log'), var_export($data['deploy_build']['plan'], true) . PHP_EOL, FILE_APPEND); | ||
| 189 | $this->setPostId($data['deploy_build']['plan'],$id); | 188 | $this->setPostId($data['deploy_build']['plan'],$id); |
| 190 | $this->savePayment($data['payment'],$id); | 189 | $this->savePayment($data['payment'],$id); |
| 191 | $this->saveDeployBuild($data['deploy_build'],$id); | 190 | $this->saveDeployBuild($data['deploy_build'],$id); |
| @@ -211,6 +210,7 @@ class SyncProject extends Command | @@ -211,6 +210,7 @@ class SyncProject extends Command | ||
| 211 | $paddingLength = Project::TYPE_FIVE - $length; // 计算填充前面的 0 的位数 | 210 | $paddingLength = Project::TYPE_FIVE - $length; // 计算填充前面的 0 的位数 |
| 212 | $zeros = str_repeat("0", $paddingLength); | 211 | $zeros = str_repeat("0", $paddingLength); |
| 213 | $number = Project::TYPE_SIX.$plan.$zeros.$id; | 212 | $number = Project::TYPE_SIX.$plan.$zeros.$id; |
| 213 | + @file_put_contents(storage_path('logs/lyh_error.log'), var_export($number, true) . PHP_EOL, FILE_APPEND); | ||
| 214 | $projectModel = new Project(); | 214 | $projectModel = new Project(); |
| 215 | $projectModel->edit(['post_id'=>$number],['id'=>$id]); | 215 | $projectModel->edit(['post_id'=>$number],['id'=>$id]); |
| 216 | return true; | 216 | return true; |
-
请 注册 或 登录 后发表评论