| xqd
@@ -547,9 +547,9 @@ class ApiController extends Controller
|
|
|
|
|
|
|
|
|
if($type == 1){//门诊
|
|
|
- $today = SchedulePeriod::where(['docter_id'=>$docter_id,'schedule_date'=>$scheduleDate])->where('organization_id','=',$org_id)->distinct('organization_id')
|
|
|
+ $today = SchedulePeriod::where(['docter_id'=>$docter_id,'schedule_date'=>$scheduleDate,'organization_id','=',$org_id])->distinct('organization_id')
|
|
|
->distinct('type')->get(['organization_id','type'])->GroupBy('type')->toArray();
|
|
|
- $self = SelfSchedule::where(['schedule_date'=>$scheduleDate,'docter_id'=>$docter_id,'organization_id'=>$org_id])
|
|
|
+ $self = SelfSchedule::where(['docter_id'=>$docter_id,'schedule_date'=>$scheduleDate,'organization_id','=',$org_id])
|
|
|
->pluck('type','organization_id')->toArray();
|
|
|
// //检查排班详情
|
|
|
// self::checkDaySchedule($date,$type,$docter_id,$org_id);
|
| xqd
@@ -579,6 +579,7 @@ class ApiController extends Controller
|
|
|
if($org != $org_id) $newBase[$tType-1]['status'] = 'other';
|
|
|
}
|
|
|
}
|
|
|
+//
|
|
|
// dump($newBase);
|
|
|
$scheduleList[] = [
|
|
|
'schedulelingList'=>$newBase,
|