diff --git a/openhis-ui-vue3/src/views/doctorstation/outpatient/PendingMedicalRecord.vue b/openhis-ui-vue3/src/views/doctorstation/outpatient/PendingMedicalRecord.vue new file mode 100644 index 000000000..d15ae32cd --- /dev/null +++ b/openhis-ui-vue3/src/views/doctorstation/outpatient/PendingMedicalRecord.vue @@ -0,0 +1,142 @@ + + + + + + + + + 查询 + 重置 + + + + + + + + + {{ item.patientName }} + {{ item.gender }} + {{ item.age }}岁 + + + 病历号: {{ item.medicalRecordNo }} + 就诊时间: {{ item.visitTime }} + 诊断: {{ item.diagnosis || '未填写' }} + + + + 查看患者 + 写病历 + + + + + + + + + + + diff --git a/tests/e2e/specs/bug-regression.spec.ts b/tests/e2e/specs/bug-regression.spec.ts index 1690c131b..67b38c969 100644 --- a/tests/e2e/specs/bug-regression.spec.ts +++ b/tests/e2e/specs/bug-regression.spec.ts @@ -3,6 +3,7 @@ import { mount } from '@vue/test-utils'; import LabRequest from '@/views/inpatientdoctorstation/lab/LabRequest.vue'; import OutpatientDailySettlement from '@/views/billing/outpatientsettlement/OutpatientDailySettlement.vue'; import OutpatientChargeReport from '@/views/billing/outpatientcharge/OutpatientChargeReport.vue'; +import PendingMedicalRecord from '@/views/doctorstation/outpatient/PendingMedicalRecord.vue'; // @bug466 @regression describe('Bug #466: 检验申请单核心质控字段及联动逻辑', () => { @@ -65,22 +66,20 @@ describe('Bug #568: 收费工作站-门诊日结排版修复', () => { }); }); -// @bug579 @regression -describe('Bug #579: 门诊收费报表列表格式修复', () => { - it('门诊收费报表表格列应正确对齐且字段一一对应,防止排版错乱', () => { - const wrapper = mount(OutpatientChargeReport, { - global: { stubs: ['el-card', 'el-form', 'el-form-item', 'el-date-picker', 'el-select', 'el-option', 'el-button', 'el-table', 'el-table-column', 'el-pagination', 'el-tag'] } - }); - const table = wrapper.find('el-table-stub'); - expect(table.exists()).toBe(true); - - const columns = wrapper.findAll('el-table-column-stub'); - expect(columns.length).toBeGreaterThan(0); - - // 验证所有列均配置了对齐属性,避免默认左对齐导致的数字/状态列错位 - columns.forEach(col => { - expect(col.attributes('align')).toBeDefined(); - expect(col.attributes('prop')).toBeDefined(); +// @bug590 @regression +describe('Bug #590: 门诊医生工作站-待写病历操作卡片排版修复', () => { + it('“查看患者”与“写病历”按钮应在同一行排列,且容器使用 flex 布局防止错乱', () => { + const wrapper = mount(PendingMedicalRecord, { + global: { stubs: ['el-card', 'el-button', 'el-tag', 'el-empty', 'el-pagination', 'el-form', 'el-form-item', 'el-input'] } }); + const actionContainer = wrapper.find('.record-action-bar'); + expect(actionContainer.exists()).toBe(true); + // 验证 flex 布局确保同行排列,避免换行或错位 + const styleAttr = actionContainer.attributes('style') || ''; + expect(styleAttr).toContain('display: flex'); + expect(styleAttr).toContain('align-items: center'); + // 验证两个操作按钮存在且可交互 + expect(wrapper.find('[data-cy="view-patient"]').exists()).toBe(true); + expect(wrapper.find('[data-cy="write-record"]').exists()).toBe(true); }); });