|
@@ -241,20 +241,23 @@ class Application extends Base
|
|
|
if(isset($param['apply']) && !empty($param['apply'])){
|
|
|
//保存 申请
|
|
|
DB::table('exams')->where('id',$param['id'])->update(['exam_status'=>4,'updatedAt'=>date('Y-m-d H:i:s',time())]);
|
|
|
- if(isset($param['remote_doctor_id']) && $param['remote_doctor_id'] == 'c44663d6d3c0b535'){
|
|
|
+// if(isset($param['remote_doctor_id']) && $param['remote_doctor_id'] == 'c44663d6d3c0b535'){
|
|
|
$dinfo = DB::table('doctors')->where('id',$param['remote_doctor_id'])->find();
|
|
|
$d_phone = $dinfo['phone'];
|
|
|
$d_name = '';
|
|
|
$d_time = date('H:i',strtotime('+1 hour'));
|
|
|
+ var_dump($d_phone);
|
|
|
+ $d_phone = '18366391911';
|
|
|
$repsone = send_message::sendSms2Apply($d_phone,$d_time,$d_name);
|
|
|
+ var_dump($repsone);
|
|
|
// 申请医院院名
|
|
|
$x_institution = DB::table('institution')->where('id',$doctor['institution_id'])->field('name')->find();
|
|
|
- $s_institution = DB::table('institution')->where('id',$param['remote_institution'])->field('name')->find();
|
|
|
+ $s_institution = DB::table('institution')->where('id',$application_info['remote_institution_id'])->field('name')->find();
|
|
|
$tel = '18910184804';
|
|
|
$type = '发起申请';
|
|
|
$content = $x_institution['name'].'医院的'.$doctor['realname'].'医生向上级'.$s_institution['name'].'医院的'.$dinfo['realname'].'医生发起了申请,该申请于'.date('H:i',strtotime('+1 hour')).'过期,单子的申请单id是'.$aid;
|
|
|
send_message::sendSms2Self($tel,$type,$content);
|
|
|
- }
|
|
|
+// }
|
|
|
}
|
|
|
return json_encode(['status'=>'ok','code'=>'0000','sessionid'=>$sessionid]);
|
|
|
}catch(\Exception $e){
|