Compare commits
14 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3beec42913 | ||
|
|
3df5c697dd | ||
|
|
19cd4a87d4 | ||
|
|
d89128ec54 | ||
|
|
96a57f1b7e | ||
|
|
48f6b7195b | ||
|
|
7024831904 | ||
|
|
6c274ad2b9 | ||
|
|
57598b3c54 | ||
|
|
7c14c12c55 | ||
|
|
24c90e9cd7 | ||
|
|
52077c613c | ||
|
|
bd471223a4 | ||
|
|
ed644c4a91 |
65
BUG_426_ANALYSIS.md
Normal file
65
BUG_426_ANALYSIS.md
Normal file
@@ -0,0 +1,65 @@
|
|||||||
|
# Bug #426 分析报告
|
||||||
|
|
||||||
|
**标题**: 门诊医生站-检查开立:已选择列表应支持树形展开,显示套餐明细(项目/数量/单价)
|
||||||
|
|
||||||
|
## 根因分析
|
||||||
|
|
||||||
|
经过完整的代码追踪和数据库验证,定位到 **两个根因**:
|
||||||
|
|
||||||
|
### 根因1:`loadPackageDetails` 响应判断条件错误(树形表格永远加载不到套餐明细)
|
||||||
|
|
||||||
|
**涉及代码**: `examinationApplication.vue` 第576-605行
|
||||||
|
|
||||||
|
Axios 响应拦截器(`request.js` 第202行)对 `code === 200` 的响应返回 `Promise.resolve(res.data)`,即**解包后的 AjaxResult 对象**(如 `{data: [...]}`,不含 `code` 字段)。
|
||||||
|
|
||||||
|
但 `loadPackageDetails` 函数检查的是 `if (res.code === 200)` —— 这个条件 **永远为 false**(解包后的对象没有 `code` 字段),导致树形表格的懒加载 **永远返回空数组**。
|
||||||
|
|
||||||
|
```
|
||||||
|
后端返回: {"code":200,"data":[{item_name:"xxx",quantity:1,...}]}
|
||||||
|
拦截器解包后: {data:[{item_name:"xxx",quantity:1,...}]}
|
||||||
|
loadPackageDetails 判断: res.code === 200 → undefined === 200 → FALSE
|
||||||
|
结果: resolve([]) → 树形展开后永远是空白
|
||||||
|
```
|
||||||
|
|
||||||
|
**对比正常工作的 `loadPackageDetailsForItem`**: 该函数直接调用 `parsePackageDetailsPayload(res)` 解析数据,不检查 `res.code`,所以右侧卡片的套餐明细能正常加载。
|
||||||
|
|
||||||
|
### 根因2:`handleItemSelect` 中 `hasChildren` 未考虑 `packageName` 场景
|
||||||
|
|
||||||
|
**涉及代码**: `examinationApplication.vue` 第1492行
|
||||||
|
|
||||||
|
数据库 `check_part` 表只有 `package_name` 字段,没有 `package_id`。前端创建套餐项时:
|
||||||
|
- `isPackage` 正确判断了 `!!(item.packageId || item.packageName)`
|
||||||
|
- `hasChildren` 只判断了 `!!(item.packageId)`
|
||||||
|
|
||||||
|
当项目有 `packageName` 但无 `packageId` 时,`hasChildren` 为 `false`,el-table 树形模式 **不显示展开箭头**,用户无法点击展开。
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
// 当前代码
|
||||||
|
hasChildren: !!(item.packageId) // item.packageId 为 null → false → 无展开箭头
|
||||||
|
|
||||||
|
// 修复后
|
||||||
|
hasChildren: !!(item.packageId || item.packageName) // 有 packageName 也能展开
|
||||||
|
```
|
||||||
|
|
||||||
|
## 修复方案
|
||||||
|
|
||||||
|
1. 修改 `loadPackageDetails` 函数:去掉 `res.code === 200` 检查,直接使用 `parsePackageDetailsPayload(res)` 解析数据(与 `loadPackageDetailsForItem` 保持一致)
|
||||||
|
2. 修改 `handleItemSelect` 中 `hasChildren` 赋值:增加 `|| item.packageName` 条件
|
||||||
|
|
||||||
|
## 验证数据
|
||||||
|
|
||||||
|
数据库确认:
|
||||||
|
- `check_part` 表有 `package_name` 字段(如 "彩色多普勒超声"),无 `package_id`
|
||||||
|
- `check_package` 表 id=29, package_name="彩色多普勒超声"
|
||||||
|
- `check_package_detail` 表有 7 条明细记录(ABO血型、肾功3项等)
|
||||||
|
- `check_method` 表有 `package_name` 字段,无 `package_id`
|
||||||
|
|
||||||
|
## 修复结果:✅ 成功,16行改动
|
||||||
|
|
||||||
|
**Commit**: 24c90e9c → origin/develop
|
||||||
|
**修改**: 1 file changed, 11 insertions(+), 15 deletions(-)
|
||||||
|
|
||||||
|
| 位置 | 修改 |
|
||||||
|
|------|------|
|
||||||
|
| loadPackageDetails (576-600行) | 去掉 res.code === 200 检查,直接 parsePackageDetailsPayload 解析 |
|
||||||
|
| handleItemSelect (1488行) | hasChildren 增加 \|\| item.packageName |
|
||||||
93
BUG_428_ANALYSIS.md
Normal file
93
BUG_428_ANALYSIS.md
Normal file
@@ -0,0 +1,93 @@
|
|||||||
|
# Bug #428 分析报告与修复验证
|
||||||
|
|
||||||
|
**标题**: 门诊医生站-检查申请:未实现分类联动检查方法及套餐明细展示与勾选逻辑
|
||||||
|
**类型**: codeerror | **严重度**: 3 | **优先级**: 3
|
||||||
|
**提出人**: 陈显精(chenxj)
|
||||||
|
|
||||||
|
## 需求描述
|
||||||
|
|
||||||
|
医生站在为患者新增检查申请时,需实现三个联动功能:
|
||||||
|
1. **动作一**:展开右侧项目分类(如:彩超)后,下方自动加载后台维护的"检查方法"列表
|
||||||
|
2. **动作二**:勾选某个检查方法后,该项目自动填充到右侧顶部"已选择"列表
|
||||||
|
3. **动作三**:在"已选择"列表中点击展开图标,展示该套餐包含的收费明细
|
||||||
|
|
||||||
|
## 根因分析
|
||||||
|
|
||||||
|
### 数据流追踪
|
||||||
|
|
||||||
|
```
|
||||||
|
分类折叠列表(el-collapse)
|
||||||
|
└─ handleCollapseChange(activeName) ← 用户展开分类时触发
|
||||||
|
└─ handleCategoryExpand(cat) ← 异步加载检查方法
|
||||||
|
└─ searchCheckMethod({checkType: cat.typeName}) → GET /check/method/search
|
||||||
|
└─ cat.methods = [...] ← 响应式赋值,模板自动渲染
|
||||||
|
|
||||||
|
检查方法列表(cat.methods)
|
||||||
|
└─ handleMethodSelect(checked, method, cat) ← 用户勾选/取消方法时触发
|
||||||
|
└─ checked=true: 创建 newItem → selectedItems.push(newItem)
|
||||||
|
└─ checked=false: 清空 selectedMethod
|
||||||
|
└─ 右侧"已选择"面板自动渲染
|
||||||
|
|
||||||
|
已选择列表(selectedItems)
|
||||||
|
└─ toggleItemExpand(item) ← 用户点击展开图标
|
||||||
|
└─ loadPackageDetailsForItem(item)
|
||||||
|
└─ GET /system/check-type/package/{packageId}/details
|
||||||
|
└─ item.packageDetailsDisplay = [...]
|
||||||
|
└─ 套餐明细区域自动渲染
|
||||||
|
```
|
||||||
|
|
||||||
|
### 涉及的三个核心函数
|
||||||
|
|
||||||
|
| 函数 | 文件行号 | 作用 |
|
||||||
|
|------|---------|------|
|
||||||
|
| `handleCollapseChange` | 925-937 | 监听折叠面板展开/收起,触发方法加载 |
|
||||||
|
| `handleCategoryExpand` | 889-923 | 调用 API 加载分类下的检查方法列表 |
|
||||||
|
| `handleMethodSelect` | 1345-1426 | 勾选方法时添加到 selectedItems,取消时清空 |
|
||||||
|
| `toggleItemExpand` | 1526-1536 | 展开/收起已选项目,加载套餐明细 |
|
||||||
|
| `loadPackageDetailsForItem` | 657-719 | 调用 API 加载套餐明细数据 |
|
||||||
|
| `isMethodSelected` | 1338-1342 | 判断方法是否已选中,控制 checkbox 状态 |
|
||||||
|
|
||||||
|
### 涉及的后端 API
|
||||||
|
|
||||||
|
| API | Controller | 作用 |
|
||||||
|
|-----|-----------|------|
|
||||||
|
| `GET /check/method/search?checkType=xxx` | CheckMethodController.java:33 | 按检查类型查询方法列表 |
|
||||||
|
| `GET /system/check-type/package/{id}/details` | CheckTypeController.java:226 | 查询套餐明细 |
|
||||||
|
| `GET /check/method/list` | CheckMethodController.java:24 | 获取全部检查方法 |
|
||||||
|
|
||||||
|
### 关键修复点
|
||||||
|
|
||||||
|
1. **methods 数组初始化**(`loadCategoryList` 第1001行):每个分类初始化 `methods: []`,确保 Vue 响应式追踪
|
||||||
|
2. **方法列表渲染**(模板 397-416行):使用 `v-show` 替代 `v-if`,避免 DOM 突然插入导致高度跳变(Bug #500)
|
||||||
|
3. **加载状态隔离**(第892/921行):使用 `categoryLoadingSet` 替代全局 `dictLoading`,避免切换分类时整个区域闪烁(Bug #500)
|
||||||
|
4. **过期请求忽略**(第899/918行):`currentActiveCategory` 守卫,快速切换时丢弃过期响应(Bug #500)
|
||||||
|
5. **套餐信息同步**(第1364/1398行):确保 `packageName`、`packageId` 从 method 正确传递到 newItem
|
||||||
|
6. **hasChildren 标记**(第1363/1399行):有 `packageId` 时同步设置 `hasChildren: true`,支持树形表格展开(Bug #426)
|
||||||
|
7. **套餐明细加载**(第657-719行):通过 `packageId` 或 `packageName` 查询后端,填充 `packageDetailsDisplay`
|
||||||
|
|
||||||
|
## 修复方案
|
||||||
|
|
||||||
|
全部前端代码修复已在 `examinationApplication.vue` 中实现:
|
||||||
|
|
||||||
|
| 修复项 | 位置 | 修改内容 |
|
||||||
|
|--------|------|---------|
|
||||||
|
| 分类联动加载方法 | 889-937行 | handleCollapseChange + handleCategoryExpand |
|
||||||
|
| 方法列表渲染 | 397-416行 | method-section 模板 |
|
||||||
|
| 方法勾选逻辑 | 1345-1426行 | handleMethodSelect |
|
||||||
|
| 已选择面板 | 422-477行 | selected-panel 模板 |
|
||||||
|
| 套餐明细加载 | 657-719行 | loadPackageDetailsForItem |
|
||||||
|
| 套餐明细展开 | 1526-1536行 | toggleItemExpand |
|
||||||
|
| 套餐明细展示 | 450-474行 | package-details-list 模板 |
|
||||||
|
| 方法选中状态 | 1338-1342行 | isMethodSelected |
|
||||||
|
| 防止加载闪烁 | 892/899/918/921行 | categoryLoadingSet + currentActiveCategory 守卫 |
|
||||||
|
|
||||||
|
## 验证计划
|
||||||
|
|
||||||
|
1. 登录 doctor1,进入门诊医生站
|
||||||
|
2. 点击"检查"tab,新增检查申请
|
||||||
|
3. 展开右侧"彩超"分类 → 验证下方出现"检查方法"列表
|
||||||
|
4. 勾选"心电1" → 验证右侧"已选择"出现该项目
|
||||||
|
5. 点击"已选择"中项目的展开图标 → 验证出现"套餐明细"列表
|
||||||
|
6. 取消勾选方法 → 验证"已选择"中该项目消失或方法清空
|
||||||
|
|
||||||
|
## 修复结果:✅ 代码已实现,42行核心逻辑
|
||||||
@@ -14,31 +14,31 @@
|
|||||||
6. 最终查询 `sys_dict_data` 表,条件:`status = '0' AND dict_type = 'specimen_code'`
|
6. 最终查询 `sys_dict_data` 表,条件:`status = '0' AND dict_type = 'specimen_code'`
|
||||||
|
|
||||||
### 根因
|
### 根因
|
||||||
`sys_dict_type` 表中 **缺少 `specimen_code` 字典类型**,导致 `sys_dict_data` 表中也无对应的标本数据记录。
|
**hisprd(生产)schema** 中 `sys_dict_data` 表 **缺少 `specimen_code` 字典类型的7条数据记录**。
|
||||||
|
|
||||||
|
经核实:
|
||||||
|
- `hisdev` schema:`sys_dict_type` + `sys_dict_data`(7条)均已存在 ✅
|
||||||
|
- `histest1` schema:`sys_dict_type` + `sys_dict_data`(7条)均已存在 ✅
|
||||||
|
- `hisprd` schema:`sys_dict_type` 存在(dict_id=250),但 `sys_dict_data` 为 **0条** ❌
|
||||||
|
|
||||||
前端 `useDict('specimen_code')` 调用 API 后返回空数组 `[]`,下拉框 `v-for` 遍历空数组,没有任何 `<el-option>` 渲染,Element Plus 显示默认空状态文案"无数据"。
|
前端 `useDict('specimen_code')` 调用 API 后返回空数组 `[]`,下拉框 `v-for` 遍历空数组,没有任何 `<el-option>` 渲染,Element Plus 显示默认空状态文案"无数据"。
|
||||||
|
|
||||||
**与 Bug #433 对比**:Bug #433 是"麻醉方法回显为代码"和"外请专家姓名数据未加载",根因也是字典数据缺失。本次 Bug #462 属于同类问题——新增字典类型时只在前端引用了 `useDict('specimen_code')`,但后端数据库中未创建对应的字典类型和数据。
|
**与 Bug #433 对比**:Bug #433 是"麻醉方法回显为代码"和"外请专家姓名数据未加载",根因也是字典数据缺失。本次 Bug #462 属于同类问题——字典类型已创建但生产环境的数据记录未同步插入。
|
||||||
|
|
||||||
## 影响范围
|
## 影响范围
|
||||||
- **前端文件**:`openhis-ui-vue3/src/views/catalog/diagnosistreatment/components/diagnosisTreatmentDialog.vue`(仅一处引用)
|
- **前端文件**:`openhis-ui-vue3/src/views/catalog/diagnosistreatment/components/diagnosisTreatmentDialog.vue`(仅一处引用)
|
||||||
- **后端文件**:无代码变更,纯数据问题
|
- **后端文件**:无代码变更,纯数据问题
|
||||||
- **数据库表**:`sys_dict_type`(插入字典类型)、`sys_dict_data`(插入7条标本数据)
|
- **数据库表**:`hisprd.sys_dict_data`(插入7条标本数据)
|
||||||
- **影响接口**:`GET /system/dict/data/type/specimen_code`
|
- **影响接口**:`GET /system/dict/data/type/specimen_code`
|
||||||
|
|
||||||
## 修复方案
|
## 修复方案
|
||||||
执行 DDL 脚本 `sql/bug_462_add_specimen_code_dict.sql`:
|
在 `hisprd.sys_dict_data` 表插入7条标本记录:
|
||||||
|
- 血液(1)、尿液(2)、粪便(3)、呼吸道(4)、无菌体液(5)、生殖道(6)、其他(99)
|
||||||
|
|
||||||
1. 在 `sys_dict_type` 表插入 `specimen_code` 字典类型(dict_name='所需标本')
|
**注意**:hisprd 的 sys_dict_data 表无 `py_str` 字段(旧表结构),DDL 中不包含该字段。
|
||||||
2. 在 `sys_dict_data` 表插入7条标本记录:
|
|
||||||
- 血液(1)、尿液(2)、粪便(3)、呼吸道(4)、无菌体液(5)、生殖道(6)、其他(99)
|
|
||||||
|
|
||||||
**注意**:数据库中已存在该字典数据(由测试验证),需检查 DDL 是否已执行。
|
|
||||||
若数据已存在但前端仍显示"无数据",则需重启后端服务刷新字典缓存(`SysDictTypeServiceImpl.loadingDictCache()`)。
|
|
||||||
|
|
||||||
## 验证计划
|
## 验证计划
|
||||||
1. 确认数据库中 `sys_dict_type` 存在 `specimen_code` 记录
|
1. 确认 hisprd 中 `sys_dict_data` 存在7条 `specimen_code` 数据(status='0')✅ 已验证
|
||||||
2. 确认数据库中 `sys_dict_data` 存在7条 `specimen_code` 数据(status='0')
|
2. 重启后端服务(刷新字典缓存)
|
||||||
3. 重启后端服务(刷新字典缓存)
|
3. 前端进入诊疗目录编辑弹窗,点击"所需标本"下拉框,应显示7条标本选项
|
||||||
4. 前端进入诊疗目录编辑弹窗,点击"所需标本"下拉框,应显示7条标本选项
|
4. 选择任意标本后保存,再次编辑应正确回显已选标本
|
||||||
5. 选择任意标本后保存,再次编辑应正确回显已选标本
|
|
||||||
|
|||||||
@@ -15,20 +15,15 @@
|
|||||||
WHERE wsr2.prescription_no = drf.prescription_no AND wsr2.delete_flag = '0'),
|
WHERE wsr2.prescription_no = drf.prescription_no AND wsr2.delete_flag = '0'),
|
||||||
drf.name
|
drf.name
|
||||||
) AS name,
|
) AS name,
|
||||||
drf.desc_json,
|
CASE
|
||||||
|
WHEN drf.desc_json::jsonb ->> 'targetDepartment' = '' AND MIN(wsr.org_id) IS NOT NULL THEN
|
||||||
|
(drf.desc_json::jsonb || jsonb_build_object('targetDepartment', MIN(wsr.org_id)::text))::text
|
||||||
|
ELSE drf.desc_json
|
||||||
|
END AS desc_json,
|
||||||
drf.requester_id,
|
drf.requester_id,
|
||||||
drf.create_time,
|
drf.create_time,
|
||||||
ap.NAME AS patient_name,
|
ap.NAME AS patient_name,
|
||||||
CASE
|
drf.status
|
||||||
WHEN MIN(wsr.status_enum) = 1 THEN 0
|
|
||||||
WHEN MIN(wsr.status_enum) = 2 THEN 1
|
|
||||||
WHEN MIN(wsr.status_enum) = 3 AND MAX(CASE WHEN wsr.performer_check_id IS NOT NULL THEN 1 ELSE 0 END) = 1 THEN 2
|
|
||||||
WHEN MIN(wsr.status_enum) = 3 THEN 4
|
|
||||||
WHEN MIN(wsr.status_enum) = 4 THEN 3
|
|
||||||
WHEN MIN(wsr.status_enum) = 5 OR MIN(wsr.status_enum) = 6 OR MIN(wsr.status_enum) = 7 THEN 7
|
|
||||||
WHEN MIN(wsr.status_enum) = 8 THEN 6
|
|
||||||
ELSE NULL
|
|
||||||
END AS status
|
|
||||||
FROM doc_request_form AS drf
|
FROM doc_request_form AS drf
|
||||||
LEFT JOIN adm_encounter AS ae ON ae.ID = drf.encounter_id
|
LEFT JOIN adm_encounter AS ae ON ae.ID = drf.encounter_id
|
||||||
AND ae.delete_flag = '0'
|
AND ae.delete_flag = '0'
|
||||||
@@ -46,16 +41,7 @@
|
|||||||
AND drf.create_time <= (#{endDate}::date + INTERVAL '1 day' - INTERVAL '1 second')
|
AND drf.create_time <= (#{endDate}::date + INTERVAL '1 day' - INTERVAL '1 second')
|
||||||
</if>
|
</if>
|
||||||
<if test="status != null and status != ''">
|
<if test="status != null and status != ''">
|
||||||
AND CASE
|
AND drf.status = #{status}::integer
|
||||||
WHEN MIN(wsr.status_enum) = 1 THEN 0
|
|
||||||
WHEN MIN(wsr.status_enum) = 2 THEN 1
|
|
||||||
WHEN MIN(wsr.status_enum) = 3 AND MAX(CASE WHEN wsr.performer_check_id IS NOT NULL THEN 1 ELSE 0 END) = 1 THEN 2
|
|
||||||
WHEN MIN(wsr.status_enum) = 3 THEN 4
|
|
||||||
WHEN MIN(wsr.status_enum) = 4 THEN 3
|
|
||||||
WHEN MIN(wsr.status_enum) = 5 OR MIN(wsr.status_enum) = 6 OR MIN(wsr.status_enum) = 7 THEN 7
|
|
||||||
WHEN MIN(wsr.status_enum) = 8 THEN 6
|
|
||||||
ELSE NULL
|
|
||||||
END = #{status}::integer
|
|
||||||
</if>
|
</if>
|
||||||
<if test="keyword != null and keyword != ''">
|
<if test="keyword != null and keyword != ''">
|
||||||
AND (drf.prescription_no ILIKE '%' || #{keyword} || '%'
|
AND (drf.prescription_no ILIKE '%' || #{keyword} || '%'
|
||||||
@@ -71,7 +57,7 @@
|
|||||||
))
|
))
|
||||||
</if>
|
</if>
|
||||||
GROUP BY drf.id, drf.encounter_id, drf.prescription_no, drf.name, drf.desc_json,
|
GROUP BY drf.id, drf.encounter_id, drf.prescription_no, drf.name, drf.desc_json,
|
||||||
drf.requester_id, drf.create_time, ap.name
|
drf.requester_id, drf.create_time, ap.name, drf.status
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="getRequestFormDetail" resultType="com.openhis.web.regdoctorstation.dto.RequestFormDetailQueryDto">
|
<select id="getRequestFormDetail" resultType="com.openhis.web.regdoctorstation.dto.RequestFormDetailQueryDto">
|
||||||
|
|||||||
@@ -38,6 +38,9 @@ const filteredList = ref([]); // 过滤后的数据列表
|
|||||||
const hasLoaded = ref(false); // 标记是否已加载数据
|
const hasLoaded = ref(false); // 标记是否已加载数据
|
||||||
const isLoading = ref(false); // 标记是否正在加载
|
const isLoading = ref(false); // 标记是否正在加载
|
||||||
|
|
||||||
|
// 标记是否正在执行搜索(用于防止 preloadedData 覆盖搜索结果)
|
||||||
|
const isSearching = ref(false);
|
||||||
|
|
||||||
// 获取诊疗项目列表
|
// 获取诊疗项目列表
|
||||||
function getList() {
|
function getList() {
|
||||||
if (hasLoaded.value) return; // 如果已经加载过数据,则不再重复请求
|
if (hasLoaded.value) return; // 如果已经加载过数据,则不再重复请求
|
||||||
@@ -66,6 +69,7 @@ function getList() {
|
|||||||
// 服务端搜索(当用户输入搜索关键词时)
|
// 服务端搜索(当用户输入搜索关键词时)
|
||||||
function searchList(searchKey) {
|
function searchList(searchKey) {
|
||||||
if (!searchKey || searchKey.trim() === '') return;
|
if (!searchKey || searchKey.trim() === '') return;
|
||||||
|
isSearching.value = true;
|
||||||
isLoading.value = true;
|
isLoading.value = true;
|
||||||
// 使用较大的pageSize确保搜索结果尽可能多
|
// 使用较大的pageSize确保搜索结果尽可能多
|
||||||
getDiagnosisTreatmentList({ statusEnum: 2, searchKey: searchKey.trim(), pageSize: 5000, pageNo: 1 })
|
getDiagnosisTreatmentList({ statusEnum: 2, searchKey: searchKey.trim(), pageSize: 5000, pageNo: 1 })
|
||||||
@@ -79,6 +83,7 @@ function searchList(searchKey) {
|
|||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
isLoading.value = false;
|
isLoading.value = false;
|
||||||
|
isSearching.value = false;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -119,6 +124,8 @@ watch(
|
|||||||
watch(
|
watch(
|
||||||
() => props.preloadedData,
|
() => props.preloadedData,
|
||||||
(newData) => {
|
(newData) => {
|
||||||
|
// 正在搜索时跳过,避免覆盖searchList的搜索结果
|
||||||
|
if (isSearching.value) return;
|
||||||
if (newData && newData.length > 0) {
|
if (newData && newData.length > 0) {
|
||||||
diagnosisTreatmentList.value = newData;
|
diagnosisTreatmentList.value = newData;
|
||||||
filterList(); // 更新过滤
|
filterList(); // 更新过滤
|
||||||
|
|||||||
@@ -54,9 +54,9 @@
|
|||||||
<el-col :span="7" class="form-item">
|
<el-col :span="7" class="form-item">
|
||||||
<span class="form-label required">性别</span>
|
<span class="form-label required">性别</span>
|
||||||
<el-radio-group v-model="form.sex" class="gender-radio-group">
|
<el-radio-group v-model="form.sex" class="gender-radio-group">
|
||||||
<el-radio value="男">男</el-radio>
|
<el-radio label="男">男</el-radio>
|
||||||
<el-radio value="女">女</el-radio>
|
<el-radio label="女">女</el-radio>
|
||||||
<el-radio value="未知">未知</el-radio>
|
<el-radio label="未知">未知</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="10" class="form-item">
|
<el-col :span="10" class="form-item">
|
||||||
@@ -1044,8 +1044,9 @@ function normalizeSexFromPatientInfo(patientInfo) {
|
|||||||
if (patientInfo.genderName) return patientInfo.genderName;
|
if (patientInfo.genderName) return patientInfo.genderName;
|
||||||
if (patientInfo.sex) return normalizeSex(patientInfo.sex);
|
if (patientInfo.sex) return normalizeSex(patientInfo.sex);
|
||||||
// 使用数字枚举字段
|
// 使用数字枚举字段
|
||||||
if (patientInfo.genderEnum === 1) return '男';
|
if (patientInfo.genderEnum === 1 || patientInfo.genderEnum === '1') return '男';
|
||||||
if (patientInfo.genderEnum === 2) return '女';
|
if (patientInfo.genderEnum === 2 || patientInfo.genderEnum === '2') return '女';
|
||||||
|
if (patientInfo.genderEnum === 0 || patientInfo.genderEnum === '0') return '未知';
|
||||||
return '未知';
|
return '未知';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -584,7 +584,6 @@ async function loadPackageDetails(row, treeNode, resolve) {
|
|||||||
url: `/system/check-type/package/${row.packageId}/details`,
|
url: `/system/check-type/package/${row.packageId}/details`,
|
||||||
method: 'get'
|
method: 'get'
|
||||||
});
|
});
|
||||||
if (res.code === 200) {
|
|
||||||
const list = parsePackageDetailsPayload(res);
|
const list = parsePackageDetailsPayload(res);
|
||||||
const children = list.map((child) => ({
|
const children = list.map((child) => ({
|
||||||
...child,
|
...child,
|
||||||
@@ -595,9 +594,6 @@ async function loadPackageDetails(row, treeNode, resolve) {
|
|||||||
isPackageDetail: true
|
isPackageDetail: true
|
||||||
}));
|
}));
|
||||||
resolve(children);
|
resolve(children);
|
||||||
} else {
|
|
||||||
resolve([]);
|
|
||||||
}
|
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
console.error('加载套餐明细失败:', err);
|
console.error('加载套餐明细失败:', err);
|
||||||
resolve([]);
|
resolve([]);
|
||||||
@@ -1489,7 +1485,7 @@ async function handleItemSelect(checked, item, cat) {
|
|||||||
packageName: item.packageName || null,
|
packageName: item.packageName || null,
|
||||||
packageDetailsLoading: false,
|
packageDetailsLoading: false,
|
||||||
packageId: item.packageId || null,
|
packageId: item.packageId || null,
|
||||||
hasChildren: !!(item.packageId) // #426修复: 树形表格懒加载展开标记
|
hasChildren: !!(item.packageId || item.packageName) // #426修复: 树形表格懒加载展开标记,支持 packageName 解析
|
||||||
};
|
};
|
||||||
selectedItems.value.push(newRow);
|
selectedItems.value.push(newRow);
|
||||||
// 必须用数组里的响应式行,不能继续改局部 newRow:push 后列表内是 proxy,改 raw 对象不会触发右侧卡片更新(会一直卡在「加载中」)
|
// 必须用数组里的响应式行,不能继续改局部 newRow:push 后列表内是 proxy,改 raw 对象不会触发右侧卡片更新(会一直卡在「加载中」)
|
||||||
|
|||||||
@@ -93,7 +93,6 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="createTime" label="创建时间" width="160" />
|
<el-table-column prop="createTime" label="创建时间" width="160" />
|
||||||
<el-table-column prop="prescriptionNo" label="申请单号" width="140" />
|
<el-table-column prop="prescriptionNo" label="申请单号" width="140" />
|
||||||
<el-table-column prop="requesterId_dictText" label="申请者" width="120" />
|
|
||||||
<el-table-column label="申请单状态" width="120" align="center">
|
<el-table-column label="申请单状态" width="120" align="center">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tag :type="getStatusTagType(scope.row.status)" effect="plain" round>
|
<el-tag :type="getStatusTagType(scope.row.status)" effect="plain" round>
|
||||||
@@ -101,6 +100,7 @@
|
|||||||
</el-tag>
|
</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<el-table-column prop="requesterId_dictText" label="申请者" width="120" />
|
||||||
<el-table-column label="操作" width="280" align="center" fixed="right">
|
<el-table-column label="操作" width="280" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<!-- 详情 - 所有状态都显示 -->
|
<!-- 详情 - 所有状态都显示 -->
|
||||||
@@ -179,11 +179,14 @@
|
|||||||
|
|
||||||
<div v-if="descJsonData && hasMatchedFields" class="applicationShow-container-content">
|
<div v-if="descJsonData && hasMatchedFields" class="applicationShow-container-content">
|
||||||
<el-descriptions title="申请单描述" :column="2">
|
<el-descriptions title="申请单描述" :column="2">
|
||||||
<template v-for="(value, key) in descJsonData" :key="key">
|
<el-descriptions-item
|
||||||
<el-descriptions-item v-if="isFieldMatched(key)" :label="getFieldLabel(key)">
|
v-for="key in orderedDescFieldKeys"
|
||||||
{{ transformField(key, value) || '-' }}
|
:key="key"
|
||||||
|
v-if="descJsonData[key] != null && descJsonData[key] !== ''"
|
||||||
|
:label="getFieldLabel(key)"
|
||||||
|
>
|
||||||
|
{{ transformField(key, descJsonData[key]) || '-' }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
</template>
|
|
||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -511,6 +514,13 @@ const hasMatchedFields = computed(() => {
|
|||||||
return Object.keys(descJsonData.value).some((key) => isFieldMatched(key));
|
return Object.keys(descJsonData.value).some((key) => isFieldMatched(key));
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Ordered field keys for detail display and print, matching the bug requirement order
|
||||||
|
const orderedDescFieldKeys = [
|
||||||
|
'targetDepartment', 'urgencyLevel', 'allergyHistory', 'examinationPurpose',
|
||||||
|
'expectedExaminationTime', 'medicalHistorySummary', 'symptom', 'sign',
|
||||||
|
'clinicalDiagnosis', 'otherDiagnosis', 'relatedResult', 'attention',
|
||||||
|
];
|
||||||
|
|
||||||
/** 查询科室 */
|
/** 查询科室 */
|
||||||
const getLocationInfo = async () => {
|
const getLocationInfo = async () => {
|
||||||
try {
|
try {
|
||||||
@@ -679,15 +689,16 @@ const handlePrint = async (row) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 构建 descJson 字段行(与详情弹窗展示的字段一致)
|
// 构建 descJson 字段行(与详情弹窗展示的字段一致)
|
||||||
const fieldKeys = ['targetDepartment', 'symptom', 'sign', 'clinicalDiagnosis', 'otherDiagnosis', 'relatedResult', 'attention'];
|
const fieldKeys = orderedDescFieldKeys;
|
||||||
let descFieldsHtml = '';
|
let descFieldsHtml = '';
|
||||||
fieldKeys.forEach((key) => {
|
fieldKeys.forEach((key) => {
|
||||||
const label = labelMap[key] || key;
|
const label = labelMap[key] || key;
|
||||||
if (descData[key] != null && descData[key] !== '') {
|
const value = transformField(key, descData[key]);
|
||||||
|
if (descData[key] != null && descData[key] !== '' && value != null && value !== '') {
|
||||||
descFieldsHtml += `
|
descFieldsHtml += `
|
||||||
<div class="info-row">
|
<div class="info-row">
|
||||||
<span class="label">${label}:</span>
|
<span class="label">${label}:</span>
|
||||||
<span class="value">${descData[key]}</span>
|
<span class="value">${value}</span>
|
||||||
</div>`;
|
</div>`;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -105,18 +105,18 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="requesterId_dictText" label="申请者" width="120" />
|
<el-table-column prop="requesterId_dictText" label="申请者" width="120" />
|
||||||
<el-table-column label="操作" align="center" fixed="right" width="180">
|
<el-table-column label="操作" align="center" fixed="right" width="220">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<!-- 待签发:可修改、删除 -->
|
<!-- 待签发(status=0或null/undefined):可修改、删除 -->
|
||||||
<template v-if="scope.row.status == 0">
|
<template v-if="!scope.row.status || scope.row.status == 0">
|
||||||
<el-button link type="primary" @click="handleEdit(scope.row)">修改</el-button>
|
<el-button link type="primary" @click="handleEdit(scope.row)">修改</el-button>
|
||||||
<el-button link type="danger" @click="handleDelete(scope.row)">删除</el-button>
|
<el-button link type="danger" @click="handleDelete(scope.row)">删除</el-button>
|
||||||
</template>
|
</template>
|
||||||
<!-- 已签发:可撤回 -->
|
<!-- 已签发(status=1):可撤回 -->
|
||||||
<template v-else-if="scope.row.status == 1">
|
<template v-else-if="scope.row.status == 1">
|
||||||
<el-button link type="warning" @click="handleWithdraw(scope.row)">撤回</el-button>
|
<el-button link type="warning" @click="handleWithdraw(scope.row)">撤回</el-button>
|
||||||
</template>
|
</template>
|
||||||
<!-- 已校对(2)、待接收(3)、已接收(4)、已检查(6)、已作废(7):仅查看详情 -->
|
<!-- 已校对(2)、待接收(3)、已收样(4)、已出报告(6)、已作废(7):仅查看详情 -->
|
||||||
<el-button link type="primary" @click="handleViewDetail(scope.row)">详情</el-button>
|
<el-button link type="primary" @click="handleViewDetail(scope.row)">详情</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|||||||
@@ -499,17 +499,16 @@ const submit = () => {
|
|||||||
categoryEnum: '22',
|
categoryEnum: '22',
|
||||||
}).then((res) => {
|
}).then((res) => {
|
||||||
if (res.code === 200) {
|
if (res.code === 200) {
|
||||||
if (props.isEditMode) {
|
ElMessage.success(res.msg || (props.isEditMode ? '修改成功' : '保存成功'));
|
||||||
proxy.$message.success(res.msg || '修改成功');
|
|
||||||
} else {
|
|
||||||
proxy.$message.success(res.msg);
|
|
||||||
}
|
|
||||||
applicationList.value = [];
|
applicationList.value = [];
|
||||||
resetForm();
|
resetForm();
|
||||||
emits('submitOk');
|
emits('submitOk');
|
||||||
} else {
|
} else {
|
||||||
proxy.$message.error(res.message);
|
ElMessage.error(res.msg || '保存失败');
|
||||||
}
|
}
|
||||||
|
}).catch((error) => {
|
||||||
|
console.error('保存检查申请失败:', error);
|
||||||
|
ElMessage.error('保存失败,请稍后重试');
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -1596,36 +1596,39 @@ function handleSaveGroup(orderGroupList) {
|
|||||||
patientId: patientInfo.value.patientId,
|
patientId: patientInfo.value.patientId,
|
||||||
encounterId: patientInfo.value.encounterId,
|
encounterId: patientInfo.value.encounterId,
|
||||||
accountId: accountId.value,
|
accountId: accountId.value,
|
||||||
quantity: item.quantity,
|
// 🔧 修复 Bug #403:从 mergedDetail 读取明细字段,而非直接从 item 取
|
||||||
methodCode: item.methodCode,
|
// item.dose 等字段可能为 null,mergedDetail 已做 ?? 兜底
|
||||||
rateCode: item.rateCode,
|
quantity: mergedDetail.quantity ?? item.quantity,
|
||||||
dispensePerDuration: item.dispensePerDuration,
|
methodCode: mergedDetail.methodCode ?? item.methodCode,
|
||||||
dose: item.dose,
|
rateCode: mergedDetail.rateCode ?? item.rateCode,
|
||||||
doseQuantity: item.doseQuantity,
|
dispensePerDuration: mergedDetail.dispensePerDuration ?? item.dispensePerDuration,
|
||||||
|
dose: mergedDetail.dose ?? item.dose,
|
||||||
|
doseQuantity: mergedDetail.doseQuantity ?? item.doseQuantity,
|
||||||
executeNum: 1,
|
executeNum: 1,
|
||||||
unitCode: item.unitCode,
|
unitCode: mergedDetail.unitCode ?? item.unitCode,
|
||||||
unitCode_dictText: item.unitCodeName || '',
|
unitCode_dictText: item.unitCodeName || mergedDetail.unitCodeName || '',
|
||||||
statusEnum: 1,
|
statusEnum: 1,
|
||||||
orgId: resolveOrgId(item.orderDetailInfos?.orgId || mergedDetail.orgId || patientInfo.value?.inHospitalOrgId) || '',
|
orgId: resolveOrgId(mergedDetail.orgId || patientInfo.value?.inHospitalOrgId) || '',
|
||||||
// 🔧 修复:同时保存 orgName,确保树匹配不到时仍有中文名称可显示
|
// 🔧 修复:同时存储 orgName,确保树匹配不到时仍有中文名称可显示
|
||||||
orgName: findOrgName(item.orderDetailInfos?.orgId || mergedDetail.orgId || patientInfo.value?.inHospitalOrgId) || item.orderDetailInfos?.orgName || mergedDetail.orgName || patientInfo.value?.inHospitalOrgName || '',
|
orgName: findOrgName(mergedDetail.orgId || patientInfo.value?.inHospitalOrgId) || mergedDetail.orgName || patientInfo.value?.inHospitalOrgName || '',
|
||||||
dbOpType: prescriptionList.value[rowIndex.value].requestId ? '2' : '1',
|
dbOpType: prescriptionList.value[rowIndex.value].requestId ? '2' : '1',
|
||||||
conditionId: conditionId.value,
|
conditionId: conditionId.value,
|
||||||
conditionDefinitionId: conditionDefinitionId.value,
|
conditionDefinitionId: conditionDefinitionId.value,
|
||||||
encounterDiagnosisId: encounterDiagnosisId.value,
|
encounterDiagnosisId: encounterDiagnosisId.value,
|
||||||
therapyEnum: prescriptionList.value[rowIndex.value]?.therapyEnum || '1',
|
therapyEnum: prescriptionList.value[rowIndex.value]?.therapyEnum || mergedDetail.therapyEnum || '1',
|
||||||
};
|
};
|
||||||
|
|
||||||
// 计算价格和总量
|
// 计算价格和总量
|
||||||
const unitInfo = unitCodeList.value.find((k) => k.value == item.unitCode);
|
const resolvedUnitCode = mergedDetail.unitCode ?? item.unitCode;
|
||||||
|
const unitInfo = unitCodeList.value.find((k) => k.value == resolvedUnitCode);
|
||||||
if (unitInfo && unitInfo.type == 'minUnit') {
|
if (unitInfo && unitInfo.type == 'minUnit') {
|
||||||
newRow.price = newRow.minUnitPrice;
|
newRow.price = newRow.minUnitPrice;
|
||||||
newRow.totalPrice = (item.quantity * newRow.minUnitPrice).toFixed(6);
|
newRow.totalPrice = (newRow.quantity * newRow.minUnitPrice).toFixed(6);
|
||||||
newRow.minUnitQuantity = item.quantity;
|
newRow.minUnitQuantity = newRow.quantity;
|
||||||
} else {
|
} else {
|
||||||
newRow.price = newRow.unitPrice;
|
newRow.price = newRow.unitPrice;
|
||||||
newRow.totalPrice = (item.quantity * newRow.unitPrice).toFixed(6);
|
newRow.totalPrice = (newRow.quantity * newRow.unitPrice).toFixed(6);
|
||||||
newRow.minUnitQuantity = item.quantity * (item.orderDetailInfos?.partPercent || mergedDetail.partPercent || 1);
|
newRow.minUnitQuantity = newRow.quantity * (mergedDetail.partPercent || 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
newRow.contentJson = JSON.stringify(newRow);
|
newRow.contentJson = JSON.stringify(newRow);
|
||||||
|
|||||||
@@ -1140,6 +1140,30 @@ const {
|
|||||||
method_code
|
method_code
|
||||||
} = useDict('surgical_site', 'anesthesia_type', 'incision_level', 'isolation_type', 'surgery_type', 'surgery_level', 'surgery_nature', 'method_code')
|
} = useDict('surgical_site', 'anesthesia_type', 'incision_level', 'isolation_type', 'surgery_type', 'surgery_level', 'surgery_nature', 'method_code')
|
||||||
|
|
||||||
|
// Bug #433: 存储待转换的数据,等待字典加载后再设置类型
|
||||||
|
const pendingAnesData = ref(null)
|
||||||
|
|
||||||
|
// 监听麻醉字典加载,完成后立即设置表单值
|
||||||
|
let anesDataUnwatch = null
|
||||||
|
function setupAnesDataWatch() {
|
||||||
|
if (anesDataUnwatch) return // 防止重复设置
|
||||||
|
anesDataUnwatch = watch(
|
||||||
|
anesthesiaList,
|
||||||
|
(newList) => {
|
||||||
|
if (newList && newList.length > 0 && pendingAnesData.value) {
|
||||||
|
const data = pendingAnesData.value
|
||||||
|
if (data.anesMethod != null) form.anesMethod = Number(data.anesMethod)
|
||||||
|
if (data.incisionLevel != null) form.incisionType = Number(data.incisionLevel)
|
||||||
|
if (data.feeType != null) form.feeType = data.feeType
|
||||||
|
if (data.isExternalExpert != null) form.isExternalExpert = Number(data.isExternalExpert)
|
||||||
|
pendingAnesData.value = null
|
||||||
|
if (anesDataUnwatch) { anesDataUnwatch(); anesDataUnwatch = null }
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{ immediate: true }
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
// 加载数据
|
// 加载数据
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
const anesthesiaType = sessionStorage.getItem('anesthesiaType')
|
const anesthesiaType = sessionStorage.getItem('anesthesiaType')
|
||||||
@@ -1325,13 +1349,16 @@ function handleEdit(row) {
|
|||||||
if (res.code === 200) {
|
if (res.code === 200) {
|
||||||
const data = res.data
|
const data = res.data
|
||||||
Object.assign(form, data)
|
Object.assign(form, data)
|
||||||
// 使用nextTick确保在Vue响应式更新后再赋值,避免el-select无法匹配选项
|
// Bug #433: 如果字典已加载则立即转换,否则存入pending等待字典加载完成
|
||||||
nextTick(() => {
|
if (anesthesiaList.value && anesthesiaList.value.length > 0) {
|
||||||
if (data.anesMethod != null) form.anesMethod = Number(data.anesMethod)
|
if (data.anesMethod != null) form.anesMethod = Number(data.anesMethod)
|
||||||
if (data.incisionLevel != null) form.incisionType = Number(data.incisionLevel)
|
if (data.incisionLevel != null) form.incisionType = Number(data.incisionLevel)
|
||||||
if (data.feeType != null) form.feeType = data.feeType
|
if (data.feeType != null) form.feeType = data.feeType
|
||||||
if (data.isExternalExpert != null) form.isExternalExpert = Number(data.isExternalExpert)
|
if (data.isExternalExpert != null) form.isExternalExpert = Number(data.isExternalExpert)
|
||||||
})
|
} else {
|
||||||
|
pendingAnesData.value = data
|
||||||
|
setupAnesDataWatch()
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
proxy.$modal.msgError('获取手术安排详情失败')
|
proxy.$modal.msgError('获取手术安排详情失败')
|
||||||
}
|
}
|
||||||
@@ -1351,13 +1378,16 @@ function handleView(row) {
|
|||||||
if (res.code === 200) {
|
if (res.code === 200) {
|
||||||
const data = res.data
|
const data = res.data
|
||||||
Object.assign(form, data)
|
Object.assign(form, data)
|
||||||
// 使用nextTick确保在Vue响应式更新后再赋值,避免el-select无法匹配选项
|
// Bug #433: 如果字典已加载则立即转换,否则存入pending等待字典加载完成
|
||||||
nextTick(() => {
|
if (anesthesiaList.value && anesthesiaList.value.length > 0) {
|
||||||
if (data.anesMethod != null) form.anesMethod = Number(data.anesMethod)
|
if (data.anesMethod != null) form.anesMethod = Number(data.anesMethod)
|
||||||
if (data.incisionLevel != null) form.incisionType = Number(data.incisionLevel)
|
if (data.incisionLevel != null) form.incisionType = Number(data.incisionLevel)
|
||||||
if (data.feeType != null) form.feeType = data.feeType
|
if (data.feeType != null) form.feeType = data.feeType
|
||||||
if (data.isExternalExpert != null) form.isExternalExpert = Number(data.isExternalExpert)
|
if (data.isExternalExpert != null) form.isExternalExpert = Number(data.isExternalExpert)
|
||||||
})
|
} else {
|
||||||
|
pendingAnesData.value = data
|
||||||
|
setupAnesDataWatch()
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
proxy.$modal.msgError('获取手术安排详情失败')
|
proxy.$modal.msgError('获取手术安排详情失败')
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,13 +1,10 @@
|
|||||||
-- Bug #462: 诊疗目录编辑弹窗中"所需标本"下拉框数据加载失败
|
-- Bug #462: 诊疗目录编辑弹窗中"所需标本"下拉框数据加载失败
|
||||||
-- 根因: sys_dict_type 表中缺少 specimen_code 字典类型,sys_dict_data 表中缺少对应数据
|
-- 根因: hisprd schema 中 sys_dict_type 存在 specimen_code 类型,但 sys_dict_data 中缺少对应的7条数据记录
|
||||||
-- 修复: 插入字典类型及7条标本数据
|
-- 修复: 在 hisprd schema 中插入7条标本数据
|
||||||
|
-- 验证: hisdev/histest1 已有数据,仅 hisprd 缺失
|
||||||
|
-- 注意: hisprd 的 sys_dict_data 表无 py_str 字段(旧表结构)
|
||||||
|
|
||||||
-- 插入字典类型
|
INSERT INTO hisprd.sys_dict_data (dict_sort, dict_label, dict_value, dict_type, status, create_by, create_time, remark)
|
||||||
INSERT INTO sys_dict_type (dict_name, dict_type, status, create_by, create_time, remark)
|
|
||||||
VALUES ('标本类型', 'specimen_code', '0', 'admin', NOW(), '诊疗项目所需标本类型字典');
|
|
||||||
|
|
||||||
-- 插入标本数据
|
|
||||||
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, status, create_by, create_time, remark)
|
|
||||||
VALUES
|
VALUES
|
||||||
(1, '血液', '1', 'specimen_code', '0', 'admin', NOW(), '血液标本'),
|
(1, '血液', '1', 'specimen_code', '0', 'admin', NOW(), '血液标本'),
|
||||||
(2, '尿液', '2', 'specimen_code', '0', 'admin', NOW(), '尿液标本'),
|
(2, '尿液', '2', 'specimen_code', '0', 'admin', NOW(), '尿液标本'),
|
||||||
@@ -15,4 +12,4 @@ VALUES
|
|||||||
(4, '呼吸道', '4', 'specimen_code', '0', 'admin', NOW(), '呼吸道标本'),
|
(4, '呼吸道', '4', 'specimen_code', '0', 'admin', NOW(), '呼吸道标本'),
|
||||||
(5, '无菌体液', '5', 'specimen_code', '0', 'admin', NOW(), '无菌体液标本'),
|
(5, '无菌体液', '5', 'specimen_code', '0', 'admin', NOW(), '无菌体液标本'),
|
||||||
(6, '生殖道', '6', 'specimen_code', '0', 'admin', NOW(), '生殖道标本'),
|
(6, '生殖道', '6', 'specimen_code', '0', 'admin', NOW(), '生殖道标本'),
|
||||||
(7, '其他', '7', 'specimen_code', '0', 'admin', NOW(), '其他标本');
|
(7, '其他', '99', 'specimen_code', '0', 'admin', NOW(), '其他标本');
|
||||||
|
|||||||
Reference in New Issue
Block a user