diff --git a/openhis-server-new/openhis-application/src/main/java/com/openhis/web/clinicalmanage/dto/OpScheduleDto.java b/openhis-server-new/openhis-application/src/main/java/com/openhis/web/clinicalmanage/dto/OpScheduleDto.java index 5e5c2274..72ec3016 100755 --- a/openhis-server-new/openhis-application/src/main/java/com/openhis/web/clinicalmanage/dto/OpScheduleDto.java +++ b/openhis-server-new/openhis-application/src/main/java/com/openhis/web/clinicalmanage/dto/OpScheduleDto.java @@ -106,9 +106,4 @@ public class OpScheduleDto extends OpSchedule { * 创建人名称 */ private String createByName; - - /** - * 费用类别 - */ - private String feeType; } diff --git a/openhis-server-new/openhis-application/src/main/resources/mapper/clinicalmanage/SurgicalScheduleAppMapper.xml b/openhis-server-new/openhis-application/src/main/resources/mapper/clinicalmanage/SurgicalScheduleAppMapper.xml index 42c1a6d5..305c3e8e 100755 --- a/openhis-server-new/openhis-application/src/main/resources/mapper/clinicalmanage/SurgicalScheduleAppMapper.xml +++ b/openhis-server-new/openhis-application/src/main/resources/mapper/clinicalmanage/SurgicalScheduleAppMapper.xml @@ -89,15 +89,12 @@ cs.apply_doctor_name AS apply_doctor_name, drf.create_time AS apply_time, os.surgery_nature AS surgeryType, - fc.contract_name AS feeType, + os.fee_type AS feeType, COALESCE(pi.identifier_no, ap.bus_no, '') AS identifierNo FROM op_schedule os LEFT JOIN adm_patient ap ON os.patient_id = ap.id INNER JOIN cli_surgery cs ON os.oper_code = cs.surgery_no AND cs.delete_flag = '0' LEFT JOIN adm_organization o ON cs.org_id = o.id - LEFT JOIN adm_encounter ae ON ae.id = cs.encounter_id AND ae.delete_flag = '0' - LEFT JOIN adm_account aa ON aa.encounter_id = ae.id AND aa.delete_flag = '0' - LEFT JOIN fin_contract fc ON fc.bus_no = aa.contract_no AND fc.delete_flag = '0' LEFT JOIN doc_request_form drf ON drf.prescription_no=cs.surgery_no LEFT JOIN ( SELECT patient_id, identifier_no diff --git a/openhis-server-new/openhis-domain/src/main/java/com/openhis/surgicalschedule/domain/OpSchedule.java b/openhis-server-new/openhis-domain/src/main/java/com/openhis/surgicalschedule/domain/OpSchedule.java index 0846f921..99936b21 100755 --- a/openhis-server-new/openhis-domain/src/main/java/com/openhis/surgicalschedule/domain/OpSchedule.java +++ b/openhis-server-new/openhis-domain/src/main/java/com/openhis/surgicalschedule/domain/OpSchedule.java @@ -193,6 +193,9 @@ public class OpSchedule extends HisBaseEntity { /** 外请专家姓名 */ private String externalExpertName; + /** 费用类别 */ + private String feeType; + /** 备注信息 */ private String remark; diff --git a/sql/迁移记录-DB变更记录/20260513_add_fee_type_to_op_schedule.sql b/sql/迁移记录-DB变更记录/20260513_add_fee_type_to_op_schedule.sql new file mode 100644 index 00000000..4f4683b1 --- /dev/null +++ b/sql/迁移记录-DB变更记录/20260513_add_fee_type_to_op_schedule.sql @@ -0,0 +1,10 @@ +-- Bug #435: 门诊手术安排编辑弹窗中"费用类别"字段数据未回显 +-- 原因:op_schedule 表缺少 fee_type 字段,导致手术安排创建时费用类别未被持久化 +ALTER TABLE op_schedule ADD COLUMN IF NOT EXISTS fee_type VARCHAR(50); +COMMENT ON COLUMN op_schedule.fee_type IS '费用类别'; + +-- 验证字段是否添加成功 +SELECT column_name, data_type, character_maximum_length +FROM information_schema.columns +WHERE table_name = 'op_schedule' + AND column_name = 'fee_type';