...
|
...
|
@@ -111,9 +111,11 @@ class AdminFaultAuditController extends AdminBaseController{ |
|
|
try{
|
|
|
Db::startTrans();
|
|
|
Db::name('users')->where('id',$fault['users_id'])->update(['is_use'=>0]);
|
|
|
Db::name('equipment')->where('name',$order['eq_name'])->update(['use'=>0]);
|
|
|
Db::name('order')->where('id',$order['id'])->update($data);
|
|
|
Db::name('fault')->where('id',$id)->update(['state'=>3]);
|
|
|
// if (!Db::name('order')->where(['eq_name'=>$order['eq_name'],'state'=>1])->find()){
|
|
|
Db::name('equipment')->where('name',$order['eq_name'])->update(['use'=>0]);
|
|
|
// }
|
|
|
}catch (\Exception $exception){
|
|
|
Db::rollback();
|
|
|
$this->error('错误:'.$exception->getMessage());
|
...
|
...
|
|