获取问诊订单消息内页基础数据问诊回合修改
This commit is contained in:
parent
641a304caf
commit
fd4c65a924
@ -13,6 +13,7 @@ use App\Exception\BusinessException;
|
|||||||
use App\Model\DetectionProject;
|
use App\Model\DetectionProject;
|
||||||
use App\Model\DiseaseClass;
|
use App\Model\DiseaseClass;
|
||||||
use App\Model\DoctorInquiryConfig;
|
use App\Model\DoctorInquiryConfig;
|
||||||
|
use App\Model\DoctorInquiryConfigService;
|
||||||
use App\Model\Hospital;
|
use App\Model\Hospital;
|
||||||
use App\Model\InquiryCaseProduct;
|
use App\Model\InquiryCaseProduct;
|
||||||
use App\Model\MessageIm;
|
use App\Model\MessageIm;
|
||||||
@ -241,7 +242,7 @@ class InquiryService extends BaseService
|
|||||||
$data['patient_name'] = $patient_family['card_name'];// 患者姓名-就诊人
|
$data['patient_name'] = $patient_family['card_name'];// 患者姓名-就诊人
|
||||||
$data['patient_name_mask'] = $patient_family['card_name_mask'];// 患者姓名-就诊人(掩码)
|
$data['patient_name_mask'] = $patient_family['card_name_mask'];// 患者姓名-就诊人(掩码)
|
||||||
$data['patient_sex'] = $patient_family['sex'];// 患者性别-就诊人(0:未知 1:男 2:女)
|
$data['patient_sex'] = $patient_family['sex'];// 患者性别-就诊人(0:未知 1:男 2:女)
|
||||||
$data['patient_age'] = $patient_family['age'];// 患者年龄-就诊人
|
$data['patient_age'] = getIdCardAge($patient_family['age']);// 患者年龄-就诊人
|
||||||
$order_inquiry = OrderInquiry::addOrderInquiry($data);
|
$order_inquiry = OrderInquiry::addOrderInquiry($data);
|
||||||
if (empty($order_inquiry)) {
|
if (empty($order_inquiry)) {
|
||||||
Db::rollBack();
|
Db::rollBack();
|
||||||
@ -264,7 +265,7 @@ class InquiryService extends BaseService
|
|||||||
$data['diagnose_images'] = $diagnose_images ?? ""; // 复诊凭证(多个使用逗号分隔)
|
$data['diagnose_images'] = $diagnose_images ?? ""; // 复诊凭证(多个使用逗号分隔)
|
||||||
|
|
||||||
if ($patient_family['age'] != null) {
|
if ($patient_family['age'] != null) {
|
||||||
$data['age'] = $patient_family['age'];// 患者年龄
|
$data['age'] = getIdCardAge($patient_family['age']);// 患者年龄
|
||||||
}
|
}
|
||||||
|
|
||||||
// 身高(cm)
|
// 身高(cm)
|
||||||
@ -923,21 +924,37 @@ class InquiryService extends BaseService
|
|||||||
|
|
||||||
// 处理问诊回合数及时长-兼容旧数据
|
// 处理问诊回合数及时长-兼容旧数据
|
||||||
if (empty($order_inquiry['times_number']) || empty($order_inquiry['duration'])) {
|
if (empty($order_inquiry['times_number']) || empty($order_inquiry['duration'])) {
|
||||||
$params = array();
|
// 疑难问诊特殊处理
|
||||||
$params['inquiry_type'] = $order_inquiry['inquiry_type'];
|
if ($order_inquiry['inquiry_type'] == 1 && $order_inquiry['inquiry_mode'] == 6 ){
|
||||||
$params['inquiry_mode'] = $order_inquiry['inquiry_mode'];
|
$params = array();
|
||||||
$system_inquiry_config = SystemInquiryConfig::getOne($params);
|
$params['doctor_id'] = $order_inquiry['doctor_id'];
|
||||||
if (empty($system_inquiry_config)) {
|
$params['inquiry_type'] = $order_inquiry['inquiry_type'];
|
||||||
return fail();
|
$params['inquiry_mode'] = $order_inquiry['inquiry_mode'];
|
||||||
|
$doctor_inquiry_config_service = DoctorInquiryConfigService::getOne($params);
|
||||||
|
if (empty($doctor_inquiry_config_service)){
|
||||||
|
return fail();
|
||||||
|
}
|
||||||
|
|
||||||
|
$order_inquiry['times_number'] = $doctor_inquiry_config_service['service_period']; // 服务回合数(0表示不限次)
|
||||||
|
$order_inquiry['duration'] = $doctor_inquiry_config_service['duration']; // 服务周期(天,不存在0的情况)
|
||||||
|
}else{
|
||||||
|
$params = array();
|
||||||
|
$params['inquiry_type'] = $order_inquiry['inquiry_type'];
|
||||||
|
$params['inquiry_mode'] = $order_inquiry['inquiry_mode'];
|
||||||
|
$system_inquiry_config = SystemInquiryConfig::getOne($params);
|
||||||
|
if (empty($system_inquiry_config)) {
|
||||||
|
return fail();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (empty($order_inquiry['times_number'])) {
|
||||||
|
$order_inquiry['times_number'] = $system_inquiry_config['times_number'];
|
||||||
|
}
|
||||||
|
|
||||||
|
if (empty($order_inquiry['duration'])) {
|
||||||
|
$order_inquiry['duration'] = $system_inquiry_config['duration'];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (empty($order_inquiry['times_number'])) {
|
|
||||||
$order_inquiry['times_number'] = $system_inquiry_config['times_number'];
|
|
||||||
}
|
|
||||||
|
|
||||||
if (empty($order_inquiry['duration'])) {
|
|
||||||
$order_inquiry['duration'] = $system_inquiry_config['duration'];
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$result = array();
|
$result = array();
|
||||||
@ -1032,7 +1049,6 @@ class InquiryService extends BaseService
|
|||||||
/**
|
/**
|
||||||
* 结束问诊
|
* 结束问诊
|
||||||
* @return array
|
* @return array
|
||||||
* @throws GuzzleException
|
|
||||||
*/
|
*/
|
||||||
public function putFinishInquiry(): array
|
public function putFinishInquiry(): array
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user