处理回写患者病例1
This commit is contained in:
parent
0d5ee9e6ad
commit
2aea3c3f5f
@ -311,240 +311,247 @@ class AutoFinishInquiryDelayDirectConsumer extends ConsumerMessage
|
|||||||
*/
|
*/
|
||||||
protected function handleOrderInquiryCase(array|object $order_inquiry): bool
|
protected function handleOrderInquiryCase(array|object $order_inquiry): bool
|
||||||
{
|
{
|
||||||
// 获取订单-问诊病例表
|
try {
|
||||||
$params = array();
|
// 获取订单-问诊病例表
|
||||||
$params['order_inquiry_id'] = $order_inquiry['order_inquiry_id'];
|
|
||||||
$order_inquiry_case = OrderInquiryCase::getOne($params);
|
|
||||||
if (empty($order_inquiry_case)) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 获取患者家庭成员信息表-基本信息
|
|
||||||
$params = array();
|
|
||||||
$params['family_id'] = $order_inquiry['family_id'];
|
|
||||||
$params['patient_id'] = $order_inquiry['patient_id'];
|
|
||||||
$params['status'] = 1;
|
|
||||||
$patient_family = PatientFamily::getOne($params);
|
|
||||||
if (empty($patient_family)){
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
$data = array();
|
|
||||||
|
|
||||||
// 身高
|
|
||||||
if ($patient_family['height'] == null && $order_inquiry_case['height'] != null){
|
|
||||||
$data['height'] = $order_inquiry_case['height'];
|
|
||||||
}
|
|
||||||
|
|
||||||
// 体重
|
|
||||||
if ($patient_family['weight'] == null && $order_inquiry_case['weight'] != null){
|
|
||||||
$data['weight'] = $order_inquiry_case['weight'];
|
|
||||||
}
|
|
||||||
|
|
||||||
// 婚姻状况(0:未婚 1:已婚 2:离异)
|
|
||||||
if ($patient_family['marital_status'] == null && $order_inquiry_case['marital_status'] != null){
|
|
||||||
$data['marital_status'] = $order_inquiry_case['marital_status'];
|
|
||||||
}
|
|
||||||
|
|
||||||
// 民族
|
|
||||||
if ($patient_family['nation_id'] == null && $order_inquiry_case['nation_id'] != null){
|
|
||||||
$data['nation_id'] = $order_inquiry_case['nation_id'];
|
|
||||||
|
|
||||||
// 民族名称
|
|
||||||
if ($patient_family['nation_name'] == null && $order_inquiry_case['nation_name'] != null){
|
|
||||||
$data['nation_name'] = $order_inquiry_case['nation_name'];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 职业
|
|
||||||
if ($patient_family['job_id'] == null && $order_inquiry_case['job_id'] != null){
|
|
||||||
$data['job_id'] = $order_inquiry_case['job_id'];
|
|
||||||
|
|
||||||
// 职业名称
|
|
||||||
if ($patient_family['job_name'] == null && $order_inquiry_case['job_name'] != null){
|
|
||||||
$data['job_name'] = $order_inquiry_case['job_name'];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!empty($data)) {
|
|
||||||
$params = array();
|
$params = array();
|
||||||
$params['family_id'] = $patient_family['family_id'];
|
$params['order_inquiry_id'] = $order_inquiry['order_inquiry_id'];
|
||||||
PatientFamily::edit($params, $data);
|
$order_inquiry_case = OrderInquiryCase::getOne($params);
|
||||||
}
|
if (empty($order_inquiry_case)) {
|
||||||
|
return false;
|
||||||
// 获取患者家庭成员信息表-健康情况
|
|
||||||
$params = array();
|
|
||||||
$params['family_id'] = $order_inquiry['family_id'];
|
|
||||||
$params['patient_id'] = $order_inquiry['patient_id'];
|
|
||||||
$patient_family_health = PatientFamilyHealth::getOne($params);
|
|
||||||
if (empty($patient_family_health)) {
|
|
||||||
// 表数据为空
|
|
||||||
$data = array();
|
|
||||||
$data['family_id'] = $order_inquiry['family_id'];
|
|
||||||
$data['patient_id'] = $order_inquiry['patient_id'];
|
|
||||||
$data['disease_class_id'] = $order_inquiry_case['disease_class_id']; // 疾病分类id-系统
|
|
||||||
$data['disease_class_name'] = $order_inquiry_case['disease_class_name']; // 疾病名称-系统
|
|
||||||
$data['diagnosis_date'] = $order_inquiry_case['diagnosis_date']; // 确诊日期
|
|
||||||
$data['diagnosis_hospital'] = $order_inquiry_case['diagnosis_hospital']; // 确诊医院
|
|
||||||
$data['is_take_medicine'] = $order_inquiry_case['is_take_medicine']; // 正在服药(0:否 1:是)
|
|
||||||
$data['drugs_name'] = $order_inquiry_case['drugs_name']; // 正在服药名称
|
|
||||||
$patient_family_health = PatientFamilyHealth::addPatientFamilyHealth($data);
|
|
||||||
if (empty($patient_family_health)) {
|
|
||||||
Log::getInstance("queue-AutoFinishInquiry")->error("错误:回写患者家庭成员信息表-健康情况表失败");
|
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
|
// 获取患者家庭成员信息表-基本信息
|
||||||
|
$params = array();
|
||||||
|
$params['family_id'] = $order_inquiry['family_id'];
|
||||||
|
$params['patient_id'] = $order_inquiry['patient_id'];
|
||||||
|
$params['status'] = 1;
|
||||||
|
$patient_family = PatientFamily::getOne($params);
|
||||||
|
if (empty($patient_family)){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
$data = array();
|
$data = array();
|
||||||
|
|
||||||
// 疾病分类id-系统
|
// 身高
|
||||||
if ($patient_family_health['disease_class_id'] == null && $order_inquiry_case['disease_class_id'] != null) {
|
if ($patient_family['height'] == null && $order_inquiry_case['height'] != null){
|
||||||
$data['disease_class_id'] = $order_inquiry_case['disease_class_id'];
|
$data['height'] = $order_inquiry_case['height'];
|
||||||
|
}
|
||||||
|
|
||||||
// 疾病名称-系统
|
// 体重
|
||||||
if ($patient_family_health['disease_class_name'] == null && $order_inquiry_case['disease_class_name'] != null) {
|
if ($patient_family['weight'] == null && $order_inquiry_case['weight'] != null){
|
||||||
$data['disease_class_name'] = $order_inquiry_case['disease_class_name'];
|
$data['weight'] = $order_inquiry_case['weight'];
|
||||||
|
}
|
||||||
|
|
||||||
|
// 婚姻状况(0:未婚 1:已婚 2:离异)
|
||||||
|
if ($patient_family['marital_status'] == null && $order_inquiry_case['marital_status'] != null){
|
||||||
|
$data['marital_status'] = $order_inquiry_case['marital_status'];
|
||||||
|
}
|
||||||
|
|
||||||
|
// 民族
|
||||||
|
if ($patient_family['nation_id'] == null && $order_inquiry_case['nation_id'] != null){
|
||||||
|
$data['nation_id'] = $order_inquiry_case['nation_id'];
|
||||||
|
|
||||||
|
// 民族名称
|
||||||
|
if ($patient_family['nation_name'] == null && $order_inquiry_case['nation_name'] != null){
|
||||||
|
$data['nation_name'] = $order_inquiry_case['nation_name'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 确诊日期
|
// 职业
|
||||||
if ($patient_family_health['diagnosis_date'] == null && $order_inquiry_case['diagnosis_date'] != null) {
|
if ($patient_family['job_id'] == null && $order_inquiry_case['job_id'] != null){
|
||||||
$data['diagnosis_date'] = $order_inquiry_case['diagnosis_date'];
|
$data['job_id'] = $order_inquiry_case['job_id'];
|
||||||
}
|
|
||||||
|
|
||||||
// 确诊医院
|
// 职业名称
|
||||||
if ($patient_family_health['diagnosis_hospital'] == null && $order_inquiry_case['diagnosis_hospital'] != null) {
|
if ($patient_family['job_name'] == null && $order_inquiry_case['job_name'] != null){
|
||||||
$data['diagnosis_hospital'] = $order_inquiry_case['diagnosis_hospital'];
|
$data['job_name'] = $order_inquiry_case['job_name'];
|
||||||
}
|
|
||||||
|
|
||||||
// 正在服药
|
|
||||||
if ($patient_family_health['is_take_medicine'] == null && $order_inquiry_case['is_take_medicine'] != null) {
|
|
||||||
$data['is_take_medicine'] = $order_inquiry_case['is_take_medicine'];
|
|
||||||
|
|
||||||
// 正在服药名称
|
|
||||||
if ($patient_family_health['drugs_name'] == null && $order_inquiry_case['drugs_name'] != null) {
|
|
||||||
$data['drugs_name'] = $order_inquiry_case['drugs_name'];
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!empty($data)) {
|
if (!empty($data)) {
|
||||||
$params = array();
|
$params = array();
|
||||||
$params['family_health_id'] = $patient_family_health['family_health_id'];
|
$params['family_id'] = $patient_family['family_id'];
|
||||||
PatientFamilyHealth::edit($params, $data);
|
PatientFamily::edit($params, $data);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// 获取患者家庭成员信息表-个人情况
|
// 获取患者家庭成员信息表-健康情况
|
||||||
$params = array();
|
$params = array();
|
||||||
$params['family_id'] = $order_inquiry['family_id'];
|
$params['family_id'] = $order_inquiry['family_id'];
|
||||||
$params['patient_id'] = $order_inquiry['patient_id'];
|
$params['patient_id'] = $order_inquiry['patient_id'];
|
||||||
$patient_family_personal = PatientFamilyPersonal::getOne($params);
|
$patient_family_health = PatientFamilyHealth::getOne($params);
|
||||||
if (empty($patient_family_personal)) {
|
if (empty($patient_family_health)) {
|
||||||
$data = array();
|
// 表数据为空
|
||||||
$data['family_id'] = $order_inquiry['family_id'];
|
$data = array();
|
||||||
$data['patient_id'] = $order_inquiry['patient_id'];
|
$data['family_id'] = $order_inquiry['family_id'];
|
||||||
|
$data['patient_id'] = $order_inquiry['patient_id'];
|
||||||
|
$data['disease_class_id'] = $order_inquiry_case['disease_class_id']; // 疾病分类id-系统
|
||||||
|
$data['disease_class_name'] = $order_inquiry_case['disease_class_name']; // 疾病名称-系统
|
||||||
|
$data['diagnosis_date'] = $order_inquiry_case['diagnosis_date']; // 确诊日期
|
||||||
|
$data['diagnosis_hospital'] = $order_inquiry_case['diagnosis_hospital']; // 确诊医院
|
||||||
|
$data['is_take_medicine'] = $order_inquiry_case['is_take_medicine']; // 正在服药(0:否 1:是)
|
||||||
|
$data['drugs_name'] = $order_inquiry_case['drugs_name']; // 正在服药名称
|
||||||
|
$patient_family_health = PatientFamilyHealth::addPatientFamilyHealth($data);
|
||||||
|
if (empty($patient_family_health)) {
|
||||||
|
Log::getInstance("queue-AutoFinishInquiry")->error("回写患者家庭成员信息表-健康情况表失败");
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$data = array();
|
||||||
|
|
||||||
// 是否存在过敏史(0:否 1:是)
|
// 疾病分类id-系统
|
||||||
if ($order_inquiry_case['is_allergy_history'] !== null) {
|
if ($patient_family_health['disease_class_id'] == null && $order_inquiry_case['disease_class_id'] != null) {
|
||||||
$data['is_allergy_history'] = $order_inquiry_case['is_allergy_history'];
|
$data['disease_class_id'] = $order_inquiry_case['disease_class_id'];
|
||||||
|
|
||||||
// 过敏史描述
|
// 疾病名称-系统
|
||||||
if ($order_inquiry_case['allergy_history'] != null) {
|
if ($patient_family_health['disease_class_name'] == null && $order_inquiry_case['disease_class_name'] != null) {
|
||||||
$data['allergy_history'] = $order_inquiry_case['allergy_history'];
|
$data['disease_class_name'] = $order_inquiry_case['disease_class_name'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 确诊日期
|
||||||
|
if ($patient_family_health['diagnosis_date'] == null && $order_inquiry_case['diagnosis_date'] != null) {
|
||||||
|
$data['diagnosis_date'] = $order_inquiry_case['diagnosis_date'];
|
||||||
|
}
|
||||||
|
|
||||||
|
// 确诊医院
|
||||||
|
if ($patient_family_health['diagnosis_hospital'] == null && $order_inquiry_case['diagnosis_hospital'] != null) {
|
||||||
|
$data['diagnosis_hospital'] = $order_inquiry_case['diagnosis_hospital'];
|
||||||
|
}
|
||||||
|
|
||||||
|
// 正在服药
|
||||||
|
if ($patient_family_health['is_take_medicine'] == null && $order_inquiry_case['is_take_medicine'] != null) {
|
||||||
|
$data['is_take_medicine'] = $order_inquiry_case['is_take_medicine'];
|
||||||
|
|
||||||
|
// 正在服药名称
|
||||||
|
if ($patient_family_health['drugs_name'] == null && $order_inquiry_case['drugs_name'] != null) {
|
||||||
|
$data['drugs_name'] = $order_inquiry_case['drugs_name'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!empty($data)) {
|
||||||
|
$params = array();
|
||||||
|
$params['family_health_id'] = $patient_family_health['family_health_id'];
|
||||||
|
PatientFamilyHealth::edit($params, $data);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 获取患者家庭成员信息表-个人情况
|
||||||
|
$params = array();
|
||||||
|
$params['family_id'] = $order_inquiry['family_id'];
|
||||||
|
$params['patient_id'] = $order_inquiry['patient_id'];
|
||||||
|
$patient_family_personal = PatientFamilyPersonal::getOne($params);
|
||||||
|
if (empty($patient_family_personal)) {
|
||||||
|
$data = array();
|
||||||
|
$data['family_id'] = $order_inquiry['family_id'];
|
||||||
|
$data['patient_id'] = $order_inquiry['patient_id'];
|
||||||
|
|
||||||
// 是否存在家族病史(0:否 1:是)
|
// 是否存在过敏史(0:否 1:是)
|
||||||
if ($order_inquiry_case['is_family_history'] !== null) {
|
if ($order_inquiry_case['is_allergy_history'] !== null) {
|
||||||
$data['is_family_history'] = $order_inquiry_case['is_family_history'];
|
$data['is_allergy_history'] = $order_inquiry_case['is_allergy_history'];
|
||||||
|
|
||||||
// 家族病史描述
|
// 过敏史描述
|
||||||
if ($order_inquiry_case['family_history'] != null) {
|
if ($order_inquiry_case['allergy_history'] != null) {
|
||||||
$data['family_history'] = $order_inquiry_case['family_history'];
|
$data['allergy_history'] = $order_inquiry_case['allergy_history'];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// 是否备孕、妊娠、哺乳期(0:否 1:是)
|
|
||||||
if ($order_inquiry_case['is_pregnant'] !== null) {
|
// 是否存在家族病史(0:否 1:是)
|
||||||
$data['is_pregnant'] = $order_inquiry_case['is_pregnant'];
|
if ($order_inquiry_case['is_family_history'] !== null) {
|
||||||
|
$data['is_family_history'] = $order_inquiry_case['is_family_history'];
|
||||||
|
|
||||||
|
// 家族病史描述
|
||||||
|
if ($order_inquiry_case['family_history'] != null) {
|
||||||
|
$data['family_history'] = $order_inquiry_case['family_history'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 是否备孕、妊娠、哺乳期(0:否 1:是)
|
// 是否备孕、妊娠、哺乳期(0:否 1:是)
|
||||||
if ($order_inquiry_case['pregnant'] != null) {
|
if ($order_inquiry_case['is_pregnant'] !== null) {
|
||||||
$data['pregnant'] = $order_inquiry_case['pregnant'];
|
$data['is_pregnant'] = $order_inquiry_case['is_pregnant'];
|
||||||
|
|
||||||
|
// 是否备孕、妊娠、哺乳期(0:否 1:是)
|
||||||
|
if ($order_inquiry_case['pregnant'] != null) {
|
||||||
|
$data['pregnant'] = $order_inquiry_case['pregnant'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$patient_family_personal = PatientFamilyPersonal::addPatientFamilyPersonal($data);
|
||||||
|
if (empty($patient_family_personal)) {
|
||||||
|
Log::getInstance("queue-AutoFinishInquiry")->error("回写患者家庭成员信息表-个人情况表失败");
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$data = array();
|
||||||
|
|
||||||
|
// 是否存在过敏史(0:否 1:是)
|
||||||
|
if ($patient_family_personal['is_allergy_history'] == null && $order_inquiry_case['is_allergy_history'] != null){
|
||||||
|
$data['is_allergy_history'] = $order_inquiry_case['is_allergy_history'];
|
||||||
|
|
||||||
|
// 过敏史描述
|
||||||
|
if ($patient_family_personal['allergy_history'] == null && $order_inquiry_case['allergy_history'] != null){
|
||||||
|
$data['allergy_history'] = $order_inquiry_case['allergy_history'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 是否存在家族病史(0:否 1:是)
|
||||||
|
if ($patient_family_personal['is_family_history'] == null && $order_inquiry_case['is_family_history'] != null){
|
||||||
|
$data['is_family_history'] = $order_inquiry_case['is_family_history'];
|
||||||
|
|
||||||
|
// 家族病史描述
|
||||||
|
if ($patient_family_personal['family_history'] == null && $order_inquiry_case['family_history'] != null){
|
||||||
|
$data['family_history'] = $order_inquiry_case['family_history'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 是否备孕、妊娠、哺乳期(0:否 1:是)
|
||||||
|
if ($patient_family_personal['is_pregnant'] == null && $order_inquiry_case['is_pregnant'] != null){
|
||||||
|
$data['is_pregnant'] = $order_inquiry_case['is_pregnant'];
|
||||||
|
|
||||||
|
// 备孕、妊娠、哺乳期描述
|
||||||
|
if ($patient_family_personal['pregnant'] == null && $order_inquiry_case['pregnant'] != null){
|
||||||
|
$data['pregnant'] = $order_inquiry_case['pregnant'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 是否存在手术(0:否 1:是)
|
||||||
|
if ($patient_family_personal['is_operation'] == null && $order_inquiry_case['is_operation'] != null){
|
||||||
|
$data['is_operation'] = $order_inquiry_case['is_operation'];
|
||||||
|
|
||||||
|
// 手术描述
|
||||||
|
if ($patient_family_personal['operation'] == null && $order_inquiry_case['operation'] != null){
|
||||||
|
$data['operation'] = $order_inquiry_case['operation'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 饮酒状态(1:从不 2:偶尔 3:经常 4:每天 5:已戒酒)
|
||||||
|
if ($patient_family_personal['drink_wine_status'] == null && $order_inquiry_case['drink_wine_status'] != null){
|
||||||
|
$data['drink_wine_status'] = $order_inquiry_case['drink_wine_status'];
|
||||||
|
}
|
||||||
|
|
||||||
|
// 吸烟状态(1:从不 2:偶尔 3:经常 4:每天 5:已戒烟)
|
||||||
|
if ($patient_family_personal['smoke_status'] == null && $order_inquiry_case['smoke_status'] != null){
|
||||||
|
$data['smoke_status'] = $order_inquiry_case['smoke_status'];
|
||||||
|
}
|
||||||
|
|
||||||
|
// 化合物状态(1:从不 2:偶尔 3:经常 4:每天)
|
||||||
|
if ($patient_family_personal['chemical_compound_status'] == null && $order_inquiry_case['chemical_compound_status'] != null){
|
||||||
|
$data['chemical_compound_status'] = $order_inquiry_case['chemical_compound_status'];
|
||||||
|
|
||||||
|
// 化合物描述
|
||||||
|
if ($patient_family_personal['chemical_compound_describe'] == null && $order_inquiry_case['chemical_compound_describe'] != null){
|
||||||
|
$data['chemical_compound_describe'] = $order_inquiry_case['chemical_compound_describe'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!empty($data)) {
|
||||||
|
$params = array();
|
||||||
|
$params['family_personal_id'] = $patient_family_personal['family_personal_id'];
|
||||||
|
PatientFamilyPersonal::edit($params, $data);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$patient_family_personal = PatientFamilyPersonal::addPatientFamilyPersonal($data);
|
return true;
|
||||||
if (empty($patient_family_personal)) {
|
}catch (\Throwable $e){
|
||||||
Log::getInstance("queue-AutoFinishInquiry")->error("错误:回写患者家庭成员信息表-个人情况表失败");
|
Log::getInstance("queue-AutoFinishInquiry")->error($e->getMessage());
|
||||||
}
|
return false;
|
||||||
} else {
|
|
||||||
$data = array();
|
|
||||||
|
|
||||||
// 是否存在过敏史(0:否 1:是)
|
|
||||||
if ($patient_family_personal['is_allergy_history'] == null && $order_inquiry_case['is_allergy_history'] != null){
|
|
||||||
$data['is_allergy_history'] = $order_inquiry_case['is_allergy_history'];
|
|
||||||
|
|
||||||
// 过敏史描述
|
|
||||||
if ($patient_family_personal['allergy_history'] == null && $order_inquiry_case['allergy_history'] != null){
|
|
||||||
$data['allergy_history'] = $order_inquiry_case['allergy_history'];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 是否存在家族病史(0:否 1:是)
|
|
||||||
if ($patient_family_personal['is_family_history'] == null && $order_inquiry_case['is_family_history'] != null){
|
|
||||||
$data['is_family_history'] = $order_inquiry_case['is_family_history'];
|
|
||||||
|
|
||||||
// 家族病史描述
|
|
||||||
if ($patient_family_personal['family_history'] == null && $order_inquiry_case['family_history'] != null){
|
|
||||||
$data['family_history'] = $order_inquiry_case['family_history'];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 是否备孕、妊娠、哺乳期(0:否 1:是)
|
|
||||||
if ($patient_family_personal['is_pregnant'] == null && $order_inquiry_case['is_pregnant'] != null){
|
|
||||||
$data['is_pregnant'] = $order_inquiry_case['is_pregnant'];
|
|
||||||
|
|
||||||
// 备孕、妊娠、哺乳期描述
|
|
||||||
if ($patient_family_personal['pregnant'] == null && $order_inquiry_case['pregnant'] != null){
|
|
||||||
$data['pregnant'] = $order_inquiry_case['pregnant'];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 是否存在手术(0:否 1:是)
|
|
||||||
if ($patient_family_personal['is_operation'] == null && $order_inquiry_case['is_operation'] != null){
|
|
||||||
$data['is_operation'] = $order_inquiry_case['is_operation'];
|
|
||||||
|
|
||||||
// 手术描述
|
|
||||||
if ($patient_family_personal['operation'] == null && $order_inquiry_case['operation'] != null){
|
|
||||||
$data['operation'] = $order_inquiry_case['operation'];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 饮酒状态(1:从不 2:偶尔 3:经常 4:每天 5:已戒酒)
|
|
||||||
if ($patient_family_personal['drink_wine_status'] == null && $order_inquiry_case['drink_wine_status'] != null){
|
|
||||||
$data['drink_wine_status'] = $order_inquiry_case['drink_wine_status'];
|
|
||||||
}
|
|
||||||
|
|
||||||
// 吸烟状态(1:从不 2:偶尔 3:经常 4:每天 5:已戒烟)
|
|
||||||
if ($patient_family_personal['smoke_status'] == null && $order_inquiry_case['smoke_status'] != null){
|
|
||||||
$data['smoke_status'] = $order_inquiry_case['smoke_status'];
|
|
||||||
}
|
|
||||||
|
|
||||||
// 化合物状态(1:从不 2:偶尔 3:经常 4:每天)
|
|
||||||
if ($patient_family_personal['chemical_compound_status'] == null && $order_inquiry_case['chemical_compound_status'] != null){
|
|
||||||
$data['chemical_compound_status'] = $order_inquiry_case['chemical_compound_status'];
|
|
||||||
|
|
||||||
// 化合物描述
|
|
||||||
if ($patient_family_personal['chemical_compound_describe'] == null && $order_inquiry_case['chemical_compound_describe'] != null){
|
|
||||||
$data['chemical_compound_describe'] = $order_inquiry_case['chemical_compound_describe'];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!empty($data)) {
|
|
||||||
$params = array();
|
|
||||||
$params['family_personal_id'] = $patient_family_personal['family_personal_id'];
|
|
||||||
PatientFamilyPersonal::edit($params, $data);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -288,7 +288,6 @@ class PatientCaseService extends BaseService
|
|||||||
|
|
||||||
// 缓存
|
// 缓存
|
||||||
if (!empty($redis_value)){
|
if (!empty($redis_value)){
|
||||||
dump($redis_value);
|
|
||||||
$redis_value = json_decode($redis_value,true);
|
$redis_value = json_decode($redis_value,true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user