Compare commits
8 Commits
dafa5961c4
...
b4d452995f
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b4d452995f | ||
|
|
23c75b147e | ||
|
|
1e431d096d | ||
|
|
e1de467b68 | ||
| 53a3460092 | |||
|
|
084d04d518 | ||
|
|
d7f8a20d76 | ||
| 331fc532fc |
@@ -25,7 +25,7 @@ public class SysTenantController extends BaseController {
|
|||||||
private ISysTenantService sysTenantService;
|
private ISysTenantService sysTenantService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询租户分页列表
|
* 查询租户分页列表(只读操作,不限制租户管理权限)
|
||||||
*
|
*
|
||||||
* @param tenantId 租户ID查询
|
* @param tenantId 租户ID查询
|
||||||
* @param tenantCode 租户编码模糊查询
|
* @param tenantCode 租户编码模糊查询
|
||||||
@@ -35,7 +35,7 @@ public class SysTenantController extends BaseController {
|
|||||||
* @param pageSize 每页多少条
|
* @param pageSize 每页多少条
|
||||||
* @return 租户分页列表
|
* @return 租户分页列表
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:tenant:operate')")
|
@PreAuthorize("@ss.hasPermi('system:tenant:list')")
|
||||||
@GetMapping("/page")
|
@GetMapping("/page")
|
||||||
public R<IPage<SysTenant>> getTenantPage(@RequestParam(required = false) Integer tenantId,
|
public R<IPage<SysTenant>> getTenantPage(@RequestParam(required = false) Integer tenantId,
|
||||||
@RequestParam(required = false) String tenantCode, @RequestParam(required = false) String tenantName,
|
@RequestParam(required = false) String tenantCode, @RequestParam(required = false) String tenantName,
|
||||||
@@ -45,19 +45,19 @@ public class SysTenantController extends BaseController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询租户详情
|
* 查询租户详情(只读操作)
|
||||||
*
|
*
|
||||||
* @param tenantId 租户ID
|
* @param tenantId 租户ID
|
||||||
* @return 租户分页列表
|
* @return 租户分页列表
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:tenant:operate')")
|
@PreAuthorize("@ss.hasPermi('system:tenant:list')")
|
||||||
@GetMapping("/{tenantId}")
|
@GetMapping("/{tenantId}")
|
||||||
public R<SysTenant> getTenantDetail(@PathVariable Integer tenantId) {
|
public R<SysTenant> getTenantDetail(@PathVariable Integer tenantId) {
|
||||||
return R.ok(sysTenantService.getById(tenantId));
|
return R.ok(sysTenantService.getById(tenantId));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询租户所属用户分页列表
|
* 查询租户所属用户分页列表(只读操作)
|
||||||
*
|
*
|
||||||
* @param tenantId 租户ID查询
|
* @param tenantId 租户ID查询
|
||||||
* @param userName 用户昵称模糊查询
|
* @param userName 用户昵称模糊查询
|
||||||
@@ -67,7 +67,7 @@ public class SysTenantController extends BaseController {
|
|||||||
* @param pageSize 每页多少条
|
* @param pageSize 每页多少条
|
||||||
* @return 租户所属用户分页列表
|
* @return 租户所属用户分页列表
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:tenant:operate')")
|
@PreAuthorize("@ss.hasPermi('system:tenant:list')")
|
||||||
@GetMapping("/user/page")
|
@GetMapping("/user/page")
|
||||||
public R<IPage<SysUser>> getTenantUserPage(@RequestParam(required = false) Integer tenantId,
|
public R<IPage<SysUser>> getTenantUserPage(@RequestParam(required = false) Integer tenantId,
|
||||||
@RequestParam(required = false) String userName, @RequestParam(required = false) String nickName,
|
@RequestParam(required = false) String userName, @RequestParam(required = false) String nickName,
|
||||||
@@ -141,14 +141,14 @@ public class SysTenantController extends BaseController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询租户未绑定的用户列表
|
* 查询租户未绑定的用户列表(只读操作)
|
||||||
*
|
*
|
||||||
* @param tenantId 租户ID
|
* @param tenantId 租户ID
|
||||||
* @param pageNum 当前页
|
* @param pageNum 当前页
|
||||||
* @param pageSize 每页多少条
|
* @param pageSize 每页多少条
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:tenant:operate')")
|
@PreAuthorize("@ss.hasPermi('system:tenant:list')")
|
||||||
@GetMapping("/{tenantId}/unbind-users")
|
@GetMapping("/{tenantId}/unbind-users")
|
||||||
public R<IPage<SysUser>> getUnbindTenantUserList(@PathVariable Integer tenantId,
|
public R<IPage<SysUser>> getUnbindTenantUserList(@PathVariable Integer tenantId,
|
||||||
@RequestParam(required = false) String userName, @RequestParam(required = false) String nickName,
|
@RequestParam(required = false) String userName, @RequestParam(required = false) String nickName,
|
||||||
@@ -194,4 +194,4 @@ public class SysTenantController extends BaseController {
|
|||||||
public R<List<SysTenant>> getUserBindTenantList(@PathVariable String username) {
|
public R<List<SysTenant>> getUserBindTenantList(@PathVariable String username) {
|
||||||
return sysTenantService.getUserBindTenantList(username);
|
return sysTenantService.getUserBindTenantList(username);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -106,4 +106,9 @@ public class OpScheduleDto extends OpSchedule {
|
|||||||
* 创建人名称
|
* 创建人名称
|
||||||
*/
|
*/
|
||||||
private String createByName;
|
private String createByName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 费用类别
|
||||||
|
*/
|
||||||
|
private String feeType;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ spring:
|
|||||||
druid:
|
druid:
|
||||||
# 主库数据源
|
# 主库数据源
|
||||||
master:
|
master:
|
||||||
url: jdbc:postgresql://192.168.110.252:15432/postgresql?currentSchema=histest&characterEncoding=UTF-8&client_encoding=UTF-8
|
url: jdbc:postgresql://192.168.110.252:15432/postgresql?currentSchema=histest1&characterEncoding=UTF-8&client_encoding=UTF-8
|
||||||
username: postgresql
|
username: postgresql
|
||||||
password: Jchl1528
|
password: Jchl1528
|
||||||
# 从库数据源
|
# 从库数据源
|
||||||
|
|||||||
@@ -89,11 +89,15 @@
|
|||||||
cs.apply_doctor_name AS apply_doctor_name,
|
cs.apply_doctor_name AS apply_doctor_name,
|
||||||
drf.create_time AS apply_time,
|
drf.create_time AS apply_time,
|
||||||
os.surgery_nature AS surgeryType,
|
os.surgery_nature AS surgeryType,
|
||||||
|
fc.contract_name AS feeType,
|
||||||
COALESCE(pi.identifier_no, ap.bus_no, '') AS identifierNo
|
COALESCE(pi.identifier_no, ap.bus_no, '') AS identifierNo
|
||||||
FROM op_schedule os
|
FROM op_schedule os
|
||||||
LEFT JOIN adm_patient ap ON os.patient_id = ap.id
|
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'
|
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_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 doc_request_form drf ON drf.prescription_no=cs.surgery_no
|
||||||
LEFT JOIN (
|
LEFT JOIN (
|
||||||
SELECT patient_id, identifier_no
|
SELECT patient_id, identifier_no
|
||||||
|
|||||||
@@ -197,7 +197,6 @@
|
|||||||
style="width: 62%"
|
style="width: 62%"
|
||||||
v-model="scope.row.adviceName"
|
v-model="scope.row.adviceName"
|
||||||
placeholder="请选择项目"
|
placeholder="请选择项目"
|
||||||
@input="handleChange"
|
|
||||||
@click="handleFocus(scope.row, scope.$index)"
|
@click="handleFocus(scope.row, scope.$index)"
|
||||||
@keyup.enter.stop="handleFocus(scope.row, scope.$index)"
|
@keyup.enter.stop="handleFocus(scope.row, scope.$index)"
|
||||||
@keydown="
|
@keydown="
|
||||||
@@ -380,7 +379,7 @@ const form = ref({
|
|||||||
prescriptionList: prescriptionList.value,
|
prescriptionList: prescriptionList.value,
|
||||||
});
|
});
|
||||||
const adviceQueryParams = ref({
|
const adviceQueryParams = ref({
|
||||||
adviceType: 1,
|
adviceType: '',
|
||||||
categoryCode: '', // 初始为空,等待加载配置后动态设置
|
categoryCode: '', // 初始为空,等待加载配置后动态设置
|
||||||
searchKey: '',
|
searchKey: '',
|
||||||
});
|
});
|
||||||
@@ -686,7 +685,7 @@ function loadConfiguredCategories() {
|
|||||||
nextTick(() => {
|
nextTick(() => {
|
||||||
// 创建新对象触发响应式更新
|
// 创建新对象触发响应式更新
|
||||||
adviceQueryParams.value = {
|
adviceQueryParams.value = {
|
||||||
adviceType: 1,
|
adviceType: '',
|
||||||
categoryCode: defaultCategoryCode,
|
categoryCode: defaultCategoryCode,
|
||||||
searchKey: '',
|
searchKey: '',
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -270,7 +270,7 @@ function normalizeDayTimeHm(part) {
|
|||||||
return `${h}:${m}`;
|
return `${h}:${m}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
function handleGetPrescription() {
|
function handleGetPrescription(skipAutoSelectAll = false) {
|
||||||
if (patientInfoList.value.length > 0) {
|
if (patientInfoList.value.length > 0) {
|
||||||
loading.value = true;
|
loading.value = true;
|
||||||
let encounterIds = patientInfoList.value.map((i) => i.encounterId).join(',');
|
let encounterIds = patientInfoList.value.map((i) => i.encounterId).join(',');
|
||||||
@@ -430,10 +430,12 @@ function handleGetPrescription() {
|
|||||||
|
|
||||||
// 将分组结果转换为数组形式
|
// 将分组结果转换为数组形式
|
||||||
prescriptionList.value = Object.values(groupedPrescriptions);
|
prescriptionList.value = Object.values(groupedPrescriptions);
|
||||||
// 默认选中全部行
|
// 默认选中全部行(执行后刷新时不自动全选,保持用户操作状态)
|
||||||
nextTick(() => {
|
if (!skipAutoSelectAll) {
|
||||||
defaultSelectAllRows();
|
nextTick(() => {
|
||||||
});
|
defaultSelectAllRows();
|
||||||
|
});
|
||||||
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('医嘱执行-获取处方列表数据处理失败:', error);
|
console.error('医嘱执行-获取处方列表数据处理失败:', error);
|
||||||
prescriptionList.value = [];
|
prescriptionList.value = [];
|
||||||
@@ -469,18 +471,17 @@ function handleExecute() {
|
|||||||
console.log(list, 'list');
|
console.log(list, 'list');
|
||||||
adviceExecute({ exeDate: exeDate.value, adviceExecuteDetailList: list }).then((res) => {
|
adviceExecute({ exeDate: exeDate.value, adviceExecuteDetailList: list }).then((res) => {
|
||||||
if (res.code == 200) {
|
if (res.code == 200) {
|
||||||
handleGetPrescription();
|
// 仅当选中医嘱中包含耗材类医嘱时,才调用耗材批号匹配(排除纯药品医嘱场景)
|
||||||
// 仅当选中医嘱中包含药品/耗材类医嘱时,才调用耗材批号匹配
|
const hasDevice = list.some((item) =>
|
||||||
const hasMedOrDevice = list.some(
|
String(item.adviceTable || '').includes('device'),
|
||||||
(item) =>
|
|
||||||
item.adviceTable === 'med_medication_request' ||
|
|
||||||
String(item.adviceTable || '').includes('device'),
|
|
||||||
);
|
);
|
||||||
if (hasMedOrDevice) {
|
if (hasDevice) {
|
||||||
lotNumberMatch({ encounterIdList: encounterIds }, { skipErrorMsg: true }).catch((error) => {
|
lotNumberMatch({ encounterIdList: encounterIds }, { skipErrorMsg: true }).catch((error) => {
|
||||||
console.warn('lotNumberMatch failed after adviceExecute:', error);
|
console.warn('lotNumberMatch failed after adviceExecute:', error);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
// 刷新列表(不自动全选,保持用户操作前的选择状态)
|
||||||
|
handleGetPrescription(true);
|
||||||
proxy.$modal.msgSuccess(res.msg || '医嘱执行成功');
|
proxy.$modal.msgSuccess(res.msg || '医嘱执行成功');
|
||||||
} else {
|
} else {
|
||||||
proxy.$modal.msgError(res.msg || '医嘱执行失败');
|
proxy.$modal.msgError(res.msg || '医嘱执行失败');
|
||||||
@@ -504,7 +505,7 @@ function handleNoExecute() {
|
|||||||
adviceNoExecute({ adviceExecuteDetailList: list }).then((res) => {
|
adviceNoExecute({ adviceExecuteDetailList: list }).then((res) => {
|
||||||
if (res.code == 200) {
|
if (res.code == 200) {
|
||||||
proxy.$modal.msgSuccess(res.msg || '操作成功');
|
proxy.$modal.msgSuccess(res.msg || '操作成功');
|
||||||
handleGetPrescription();
|
handleGetPrescription(true);
|
||||||
} else {
|
} else {
|
||||||
proxy.$modal.msgError(res.msg || '操作失败');
|
proxy.$modal.msgError(res.msg || '操作失败');
|
||||||
}
|
}
|
||||||
@@ -543,7 +544,7 @@ function handleCancel() {
|
|||||||
adviceCancel({ adviceExecuteDetailList: producerIds }).then((res) => {
|
adviceCancel({ adviceExecuteDetailList: producerIds }).then((res) => {
|
||||||
if (res.code == 200) {
|
if (res.code == 200) {
|
||||||
proxy.$modal.msgSuccess(res.msg || '取消执行成功');
|
proxy.$modal.msgSuccess(res.msg || '取消执行成功');
|
||||||
handleGetPrescription();
|
handleGetPrescription(true);
|
||||||
} else {
|
} else {
|
||||||
proxy.$modal.msgError(res.msg || '取消执行失败');
|
proxy.$modal.msgError(res.msg || '取消执行失败');
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1136,12 +1136,14 @@ function loadDeptList() {
|
|||||||
const tree = res.data?.records || res.data || []
|
const tree = res.data?.records || res.data || []
|
||||||
deptList.value = flattenOrgTree(tree)
|
deptList.value = flattenOrgTree(tree)
|
||||||
} else {
|
} else {
|
||||||
proxy.$modal.msgError('获取科室列表失败')
|
// 权限不足时静默降级,不弹窗阻断(Bug #441)
|
||||||
|
console.warn('科室列表加载失败(可能无权限):', res.message || res.code)
|
||||||
deptList.value = []
|
deptList.value = []
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(error => {
|
.catch(error => {
|
||||||
proxy.$modal.msgError('获取科室列表失败')
|
// 网络错误或权限拒绝:静默降级
|
||||||
|
console.warn('科室列表加载失败:', error?.message || error)
|
||||||
deptList.value = []
|
deptList.value = []
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -1154,12 +1156,14 @@ function loadDoctorList() {
|
|||||||
const records = res.data?.records || []
|
const records = res.data?.records || []
|
||||||
doctorList.value = records.map(mapPractitionerToOption).filter(it => it.code && it.name)
|
doctorList.value = records.map(mapPractitionerToOption).filter(it => it.code && it.name)
|
||||||
} else {
|
} else {
|
||||||
proxy.$modal.msgError('获取医生列表失败')
|
// 权限不足时静默降级,不弹窗阻断(Bug #441)
|
||||||
|
console.warn('医生列表加载失败(可能无权限):', res.message || res.code)
|
||||||
doctorList.value = []
|
doctorList.value = []
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(error => {
|
.catch(error => {
|
||||||
proxy.$modal.msgError('获取医生列表失败')
|
// 网络错误或权限拒绝:静默降级
|
||||||
|
console.warn('医生列表加载失败:', error?.message || error)
|
||||||
doctorList.value = []
|
doctorList.value = []
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -1172,12 +1176,14 @@ function loadNurseList() {
|
|||||||
const records = res.data?.records || []
|
const records = res.data?.records || []
|
||||||
nurseList.value = records.map(mapPractitionerToOption).filter(it => it.code && it.name)
|
nurseList.value = records.map(mapPractitionerToOption).filter(it => it.code && it.name)
|
||||||
} else {
|
} else {
|
||||||
proxy.$modal.msgError('获取护士列表失败')
|
// 权限不足时静默降级,不弹窗阻断(Bug #441)
|
||||||
|
console.warn('护士列表加载失败(可能无权限):', res.message || res.code)
|
||||||
nurseList.value = []
|
nurseList.value = []
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(error => {
|
.catch(error => {
|
||||||
proxy.$modal.msgError('获取护士列表失败')
|
// 网络错误或权限拒绝:静默降级
|
||||||
|
console.warn('护士列表加载失败:', error?.message || error)
|
||||||
nurseList.value = []
|
nurseList.value = []
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -1190,12 +1196,14 @@ function loadOperatingRoomList() {
|
|||||||
const records = res.data?.records || []
|
const records = res.data?.records || []
|
||||||
operatingRoomList.value = records.map(mapOperatingRoomToOption).filter(it => it.roomCode)
|
operatingRoomList.value = records.map(mapOperatingRoomToOption).filter(it => it.roomCode)
|
||||||
} else {
|
} else {
|
||||||
proxy.$modal.msgError('获取手术室列表失败')
|
// 权限不足时静默降级,不弹窗阻断(Bug #441)
|
||||||
|
console.warn('手术室列表加载失败(可能无权限):', res.message || res.code)
|
||||||
operatingRoomList.value = []
|
operatingRoomList.value = []
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(error => {
|
.catch(error => {
|
||||||
proxy.$modal.msgError('获取手术室列表失败')
|
// 网络错误或权限拒绝:静默降级
|
||||||
|
console.warn('手术室列表加载失败:', error?.message || error)
|
||||||
operatingRoomList.value = []
|
operatingRoomList.value = []
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -1404,6 +1412,10 @@ async function handleChargeCharge(row) {
|
|||||||
|
|
||||||
// 关闭计费弹窗
|
// 关闭计费弹窗
|
||||||
function closeChargeDialog() {
|
function closeChargeDialog() {
|
||||||
|
// 先关闭 prescriptionlist 内所有已打开的项目字典 popover
|
||||||
|
if (prescriptionRef.value && prescriptionRef.value.closeAllPopovers) {
|
||||||
|
prescriptionRef.value.closeAllPopovers()
|
||||||
|
}
|
||||||
showChargeDialog.value = false
|
showChargeDialog.value = false
|
||||||
chargePatientInfo.value = {}
|
chargePatientInfo.value = {}
|
||||||
chargeSurgeryInfo.value = {}
|
chargeSurgeryInfo.value = {}
|
||||||
@@ -1910,6 +1922,7 @@ function resetForm() {
|
|||||||
allergyRemark: undefined,
|
allergyRemark: undefined,
|
||||||
surgeryNature: undefined,
|
surgeryNature: undefined,
|
||||||
surgerySite: undefined,
|
surgerySite: undefined,
|
||||||
|
incisionType: undefined,
|
||||||
admissionTime: undefined,
|
admissionTime: undefined,
|
||||||
entryTime: undefined,
|
entryTime: undefined,
|
||||||
roomCode: undefined,
|
roomCode: undefined,
|
||||||
|
|||||||
18
sql/bug_462_add_specimen_code_dict.sql
Normal file
18
sql/bug_462_add_specimen_code_dict.sql
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
-- Bug #462: 诊疗目录编辑弹窗中"所需标本"下拉框数据加载失败
|
||||||
|
-- 根因: sys_dict_type 表中缺少 specimen_code 字典类型,sys_dict_data 表中缺少对应数据
|
||||||
|
-- 修复: 插入字典类型及7条标本数据
|
||||||
|
|
||||||
|
-- 插入字典类型
|
||||||
|
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
|
||||||
|
(1, '血液', '1', 'specimen_code', '0', 'admin', NOW(), '血液标本'),
|
||||||
|
(2, '尿液', '2', 'specimen_code', '0', 'admin', NOW(), '尿液标本'),
|
||||||
|
(3, '粪便', '3', 'specimen_code', '0', 'admin', NOW(), '粪便标本'),
|
||||||
|
(4, '呼吸道', '4', 'specimen_code', '0', 'admin', NOW(), '呼吸道标本'),
|
||||||
|
(5, '无菌体液', '5', 'specimen_code', '0', 'admin', NOW(), '无菌体液标本'),
|
||||||
|
(6, '生殖道', '6', 'specimen_code', '0', 'admin', NOW(), '生殖道标本'),
|
||||||
|
(7, '其他', '7', 'specimen_code', '0', 'admin', NOW(), '其他标本');
|
||||||
Reference in New Issue
Block a user