调整对接pacs ,报到后推送pacs

main
yanzai 7 months ago
parent 63e6f90885
commit a66a29c59e

@ -282,7 +282,7 @@ class WorkMainController extends Controller
->whereTime('entrust_time', '<', $currentDateTime->toTimeString());
})->get();
$success_count=0;
$pacs=new CSharpController();
foreach ($list as $key=>$item){
$u_data=[
'list_status' => 0,
@ -309,7 +309,6 @@ class WorkMainController extends Controller
$u_count = DB::table('s_source_roster_detail_count')->where(['roster_detail_id' => $item->roster_id, 'appointment_type_id' => $item->appointment_type_id])->decrement('used_count');
if($u_count){
$success_count++;
$pacs->CancelApply($item->entrust_id);
}
}
return \Yz::Return(true,"执行完成",['success_count'=>$success_count]);

@ -31,7 +31,7 @@ class CSharpController extends Controller
}
Log::info('推送申请单'.$orderNo);
$entrust = DB::table('s_list')->where(['entrust_id' => $orderNo, 'list_status' => 1, 'is_nullify' => 0])->first();
$entrust = DB::table('s_list')->where(['entrust_id' => $orderNo, 'list_status' => 2, 'is_nullify' => 0])->first();
$reservation_time='';
if(isset($entrust->roster_id) and !empty($entrust->roster_id)){
$plan= DB::table('s_source_roster_detail')->where(['id' => $entrust->roster_id])->first();

@ -100,7 +100,10 @@ class PacsController extends Controller
];
$u = DB::table('s_list')->where(['entrust_id' => $orderNo])->update($data);
if($u){
return \Yz::JsonReturn(true,'报道成功',['orderNo'=>$orderNo]);
//通知pacs
$pacs=new CSharpController();
$pacs_res=$pacs->SaveApply($entrust->entrust_id);
return \Yz::JsonReturn(true,'报道成功',['orderNo'=>$orderNo,'pacs_info'=>$pacs_res]);
}else{
return \Yz::JsonError('报道失败');
}

@ -421,15 +421,6 @@ WHERE
}
if ($u_mainList) {
DB::commit();
//通知pacs
$pacs=new CSharpController();
foreach ($oldMainInfos as $key => $oldMainInfo) {
if ($do_type == 2) {
$pacs->CancelApply($oldMainInfo->entrust_id);
}
$oldMainInfo->roster_id=$planInfo->id;
$pacs->SaveApply($oldMainInfo->entrust_id);
}
if(config('app.globals.预约完成短信通知')==1){
$this->SendMsg($oldMainInfos,$do_type);
}
@ -540,8 +531,6 @@ WHERE
$u_count = DB::table('s_source_roster_detail_count')->where(['roster_detail_id' => $mainInfo->roster_id, 'appointment_type_id' => $mainInfo->appointment_type_id])->decrement('used_count');
if ($u_mainList && $u_count) {
DB::commit();
$pacs=new CSharpController();
$pacs->CancelApply($mainInfo->entrust_id);
return \Yz::Return(true, '取消成功', []);
} else {
DB::rollBack();

Loading…
Cancel
Save