|
@@ -141,9 +141,8 @@ class ProjectLogic extends BaseLogic |
|
@@ -141,9 +141,8 @@ class ProjectLogic extends BaseLogic |
|
141
|
* @time :2023/8/30 11:57
|
141
|
* @time :2023/8/30 11:57
|
|
142
|
*/
|
142
|
*/
|
|
143
|
public function projectSave(){
|
143
|
public function projectSave(){
|
|
144
|
- DB::beginTransaction();
|
|
|
|
145
|
- try {
|
|
|
|
146
|
-// $this->param['project_location'] = 0;//TODO::图片文件存储不同地方,上线后删除
|
144
|
+// DB::beginTransaction();
|
|
|
|
145
|
+// try {
|
|
147
|
if($this->param['type'] == Project::TYPE_SEVEN){
|
146
|
if($this->param['type'] == Project::TYPE_SEVEN){
|
|
148
|
//错误单直接返回,单独处理
|
147
|
//错误单直接返回,单独处理
|
|
149
|
$this->setTypeSevenEdit($this->param);
|
148
|
$this->setTypeSevenEdit($this->param);
|
|
@@ -164,11 +163,11 @@ class ProjectLogic extends BaseLogic |
|
@@ -164,11 +163,11 @@ class ProjectLogic extends BaseLogic |
|
164
|
$this->syncImageFile($this->param['project_location'],$this->param['id']);
|
163
|
$this->syncImageFile($this->param['project_location'],$this->param['id']);
|
|
165
|
(new SyncService())->projectAcceptAddress($this->param['id']);
|
164
|
(new SyncService())->projectAcceptAddress($this->param['id']);
|
|
166
|
}
|
165
|
}
|
|
167
|
- DB::commit();
|
|
|
|
168
|
- }catch (\Exception $e){
|
|
|
|
169
|
- DB::rollBack();
|
|
|
|
170
|
- $this->fail('保存失败,请联系管理员');
|
|
|
|
171
|
- }
|
166
|
+// DB::commit();
|
|
|
|
167
|
+// }catch (\Exception $e){
|
|
|
|
168
|
+// DB::rollBack();
|
|
|
|
169
|
+// $this->fail('保存失败,请联系管理员');
|
|
|
|
170
|
+// }
|
|
172
|
return $this->success();
|
171
|
return $this->success();
|
|
173
|
}
|
172
|
}
|
|
174
|
|
173
|
|
|
@@ -187,16 +186,16 @@ class ProjectLogic extends BaseLogic |
|
@@ -187,16 +186,16 @@ class ProjectLogic extends BaseLogic |
|
187
|
* @time :2023/8/30 12:14
|
186
|
* @time :2023/8/30 12:14
|
|
188
|
*/
|
187
|
*/
|
|
189
|
public function saveProject($param){
|
188
|
public function saveProject($param){
|
|
190
|
- if($param['type'] == Project::TYPE_FIVE){
|
|
|
|
191
|
- $param['extend_type'] = Project::TYPE_FIVE;
|
|
|
|
192
|
- unset($param['type']);
|
|
|
|
193
|
- }
|
|
|
|
194
|
if($param['type'] == Project::TYPE_ONE){
|
189
|
if($param['type'] == Project::TYPE_ONE){
|
|
195
|
$param['serve_id'] = 9;
|
190
|
$param['serve_id'] = 9;
|
|
196
|
}
|
191
|
}
|
|
197
|
if((($param['type'] == Project::TYPE_TWO) || ($param['type'] == Project::TYPE_THREE)) && empty($param['uptime'])){
|
192
|
if((($param['type'] == Project::TYPE_TWO) || ($param['type'] == Project::TYPE_THREE)) && empty($param['uptime'])){
|
|
198
|
$param['uptime'] = date('Y-m-d H:i:s');
|
193
|
$param['uptime'] = date('Y-m-d H:i:s');
|
|
199
|
}
|
194
|
}
|
|
|
|
195
|
+ if($param['type'] == Project::TYPE_FIVE){
|
|
|
|
196
|
+ $param['extend_type'] = Project::TYPE_FIVE;
|
|
|
|
197
|
+ unset($param['type']);
|
|
|
|
198
|
+ }
|
|
200
|
if(isset($param['level']) && !empty($param['level'])){
|
199
|
if(isset($param['level']) && !empty($param['level'])){
|
|
201
|
$param['level'] = Arr::arrToSet($param['level']);
|
200
|
$param['level'] = Arr::arrToSet($param['level']);
|
|
202
|
}
|
201
|
}
|