修改物流发货信息推送
This commit is contained in:
parent
ddfc7f06e1
commit
57816f58b4
@ -139,26 +139,26 @@ class getPrescriptionOrderStatusCommand extends HyperfCommand
|
|||||||
// 订阅快递推送
|
// 订阅快递推送
|
||||||
$Kuaidi = new Kuaidi();
|
$Kuaidi = new Kuaidi();
|
||||||
$Kuaidi->subscribe($result['deliveryId'],$logistics_company_code,$item['consignee_tel']);
|
$Kuaidi->subscribe($result['deliveryId'],$logistics_company_code,$item['consignee_tel']);
|
||||||
|
|
||||||
|
try {
|
||||||
|
// 获取患者数据
|
||||||
|
$params = array();
|
||||||
|
$params['patient_id'] = $order_prescription['patient_id'];
|
||||||
|
$user_patient = UserPatient::getOne($params);
|
||||||
|
if (empty($user_patient)){
|
||||||
|
$this->line("推送消息错误:用户数据错误");
|
||||||
|
}
|
||||||
|
|
||||||
|
// 患者-药品已发货-订阅失败发送短信
|
||||||
|
$MessagePush = new MessagePush($user_patient['user_id']);
|
||||||
|
$MessagePush->productDelivery($item['order_product_id']);
|
||||||
|
}catch (\Exception $e){
|
||||||
|
$this->line("推送消息错误:" . $e->getMessage());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 修改成功时药品订单数据
|
// 修改成功时药品订单数据
|
||||||
$this->savePreSuccessOrderStatus($item,$result['deliveryId'],$logistics_company_code,$result['deliveryTime']);
|
$this->savePreSuccessOrderStatus($item,$result['deliveryId'],$logistics_company_code,$result['deliveryTime']);
|
||||||
|
|
||||||
try {
|
|
||||||
// 获取患者数据
|
|
||||||
$params = array();
|
|
||||||
$params['patient_id'] = $order_prescription['patient_id'];
|
|
||||||
$user_patient = UserPatient::getOne($params);
|
|
||||||
if (empty($user_patient)){
|
|
||||||
$this->line("推送消息错误:用户数据错误");
|
|
||||||
}
|
|
||||||
|
|
||||||
// 患者-药品已发货-订阅失败发送短信
|
|
||||||
$MessagePush = new MessagePush($user_patient['user_id']);
|
|
||||||
$MessagePush->productDelivery($item['order_product_id']);
|
|
||||||
}catch (\Exception $e){
|
|
||||||
$this->line("推送消息错误:" . $e->getMessage());
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->line("获取处方平台订单数据结束:处理完毕");
|
$this->line("获取处方平台订单数据结束:处理完毕");
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user