优化
This commit is contained in:
parent
dc30a21d8f
commit
38189dfd11
@ -356,7 +356,8 @@ const handleSave = async (flag: any) => {
|
|||||||
const valid = await tableTabRef.value.validate(); // 调用基本资料子组件的验证方法
|
const valid = await tableTabRef.value.validate(); // 调用基本资料子组件的验证方法
|
||||||
if (!valid) return ElMessage.error('表单验证失败,请检查输入项!');
|
if (!valid) return ElMessage.error('表单验证失败,请检查输入项!');
|
||||||
}
|
}
|
||||||
|
const flagCommon = modelParam.value.commonlyValuesData.every((item: any) => item.qz && item.srm && item.jgbz)
|
||||||
|
if (!flagCommon) return ElMessage.warning('请完整填写常用取值项!');
|
||||||
saveDataService({
|
saveDataService({
|
||||||
xmInfoNew: modelParam.value.basicData,
|
xmInfoNew: modelParam.value.basicData,
|
||||||
xmDoubleRows: [],
|
xmDoubleRows: [],
|
||||||
|
|||||||
@ -25,12 +25,12 @@
|
|||||||
<el-form-item label="日期:" prop="jyrq">
|
<el-form-item label="日期:" prop="jyrq">
|
||||||
<el-date-picker v-model="ybJyrq" type="date" label-width="1.25rem" placeholder="检验日期"
|
<el-date-picker v-model="ybJyrq" type="date" label-width="1.25rem" placeholder="检验日期"
|
||||||
value-format="YYYY-MM-DD" :clearable="false" @change="jyrqChange" ref="datePickerRef"
|
value-format="YYYY-MM-DD" :clearable="false" @change="jyrqChange" ref="datePickerRef"
|
||||||
style="width:7.5rem" />
|
style="width: 8.5rem" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="部门:" prop="instrGroup">
|
<el-form-item label="部门:" prop="instrGroup">
|
||||||
<SelectTable v-model:data="queryParams.instrGroup" :fields="instrGroupFields"
|
<SelectTable v-model:data="queryParams.instrGroup" :fields="instrGroupFields"
|
||||||
:tableData="instrGroupOptions" label="zdmc" value="zddh" objKey="zddh" :border="true" width="9rem"
|
:tableData="instrGroupOptions" label="zdmc" value="zddh" objKey="zddh" :border="true" width="8rem"
|
||||||
placeholder="请选择部门" @getDataValue="handleinstrGroupChange" :clearable="false" :size="aotuSize" />
|
placeholder="请选择部门" @getDataValue="handleinstrGroupChange" :clearable="false" :size="aotuSize" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
@ -572,8 +572,12 @@ const delSampleHd = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const row = labPatList.value[highlightRowIndex.value];
|
const row = labPatList.value[highlightRowIndex.value];
|
||||||
labPatListRef.value.setCurrentRow(row);
|
if (row) {
|
||||||
selectJob(row);
|
labPatListRef.value.setCurrentRow(row);
|
||||||
|
selectJob(row);
|
||||||
|
} else {
|
||||||
|
handleCreate()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
@ -665,7 +669,11 @@ const changeStatus = (updatedPat: any, flag: boolean) => {
|
|||||||
// 更新样本列表中的样本信息
|
// 更新样本列表中的样本信息
|
||||||
labPatList.value = labPatList.value.map((item, i) => i === index ? { ...labPat.value } : item);
|
labPatList.value = labPatList.value.map((item, i) => i === index ? { ...labPat.value } : item);
|
||||||
highlightRowIndex.value = index;
|
highlightRowIndex.value = index;
|
||||||
|
setTimeout(() => {
|
||||||
|
nextTick(() => {
|
||||||
|
labPatListRef.value.setCurrentRow(labPatList.value[index]);
|
||||||
|
});
|
||||||
|
}, 10)
|
||||||
// 条码号输入后操作
|
// 条码号输入后操作
|
||||||
if (flag) {
|
if (flag) {
|
||||||
setTimeout(() => { handleNext() }, 10)
|
setTimeout(() => { handleNext() }, 10)
|
||||||
@ -719,16 +727,17 @@ const fetchlabPatList = () => {
|
|||||||
const row = labPatList.value[index];
|
const row = labPatList.value[index];
|
||||||
setTimeout(() => { labPatListRef.value.setCurrentRow(row); }, 10)
|
setTimeout(() => { labPatListRef.value.setCurrentRow(row); }, 10)
|
||||||
selectJob(row);
|
selectJob(row);
|
||||||
|
} else {
|
||||||
|
highlightRowIndex.value = 0;
|
||||||
|
setTimeout(() => { labPatListRef.value.setCurrentRow(res.data[0]) }, 10)
|
||||||
|
selectJob(res.data[0])
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
highlightRowIndex.value = 0;
|
|
||||||
setTimeout(() => { labPatListRef.value.setCurrentRow(res.data[0]) }, 10)
|
|
||||||
selectJob(res.data[0])
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
labInfo.value = {}
|
labInfo.value = {}
|
||||||
labPat.value = {}
|
labPat.value = {}
|
||||||
zbLabResuts.value = []
|
zbLabResuts.value = []
|
||||||
|
handleCreate()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -850,11 +859,12 @@ const initSocket = () => {
|
|||||||
|
|
||||||
// 页面卸载时清理
|
// 页面卸载时清理
|
||||||
onUnmounted(() => {
|
onUnmounted(() => {
|
||||||
closeWebSocket();
|
// closeWebSocket();
|
||||||
});
|
});
|
||||||
|
|
||||||
// 发送消息
|
// 发送消息
|
||||||
const sendMessage = () => {
|
const sendMessage = () => {
|
||||||
|
return
|
||||||
const isSuccess = sendWebSocketMessage({ yq: queryParams.value.yq });
|
const isSuccess = sendWebSocketMessage({ yq: queryParams.value.yq });
|
||||||
if (isSuccess) {
|
if (isSuccess) {
|
||||||
console.log(`发送消息`);
|
console.log(`发送消息`);
|
||||||
|
|||||||
@ -61,7 +61,7 @@
|
|||||||
<el-input v-model="fcYbh" @keyup.enter="subHandle()" />
|
<el-input v-model="fcYbh" @keyup.enter="subHandle()" />
|
||||||
</div>
|
</div>
|
||||||
<div class="mt10" style="text-align: center; width: 100%;">
|
<div class="mt10" style="text-align: center; width: 100%;">
|
||||||
<el-button type="primary" @click="subHandle()"> 确认 </el-button>
|
<el-button type="primary" :loading="subloading" @click="subHandle()"> 确认 </el-button>
|
||||||
<el-button @click="closeHandle">取消</el-button>
|
<el-button @click="closeHandle">取消</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
@ -100,9 +100,10 @@ const show = ref(false)
|
|||||||
|
|
||||||
const fcYbh = ref('')
|
const fcYbh = ref('')
|
||||||
const fcYq = ref('')
|
const fcYq = ref('')
|
||||||
|
const subloading = ref(false)
|
||||||
const subHandle = () => {
|
const subHandle = () => {
|
||||||
if (!fcYbh.value.trim()) return ElMessage.warning('请输入复查的样本号')
|
if (!fcYbh.value.trim()) return ElMessage.warning('请输入复查的样本号')
|
||||||
|
subloading.value = true
|
||||||
const data = {
|
const data = {
|
||||||
newybh: fcYbh.value,
|
newybh: fcYbh.value,
|
||||||
newyq: fcYq.value,
|
newyq: fcYq.value,
|
||||||
@ -113,6 +114,8 @@ const subHandle = () => {
|
|||||||
ElMessage.success('操作成功')
|
ElMessage.success('操作成功')
|
||||||
closeHandle()
|
closeHandle()
|
||||||
}
|
}
|
||||||
|
}).finally(() => {
|
||||||
|
subloading.value = false
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
const closeHandle = () => {
|
const closeHandle = () => {
|
||||||
|
|||||||
@ -26,12 +26,12 @@
|
|||||||
<el-form-item label="日期:" prop="jyrq">
|
<el-form-item label="日期:" prop="jyrq">
|
||||||
<el-date-picker v-model="queryParams.jyrq" type="date" label-width="1.25rem" placeholder="检验日期"
|
<el-date-picker v-model="queryParams.jyrq" type="date" label-width="1.25rem" placeholder="检验日期"
|
||||||
value-format="YYYY-MM-DD" :clearable="false" @change="fetchlabPatList"
|
value-format="YYYY-MM-DD" :clearable="false" @change="fetchlabPatList"
|
||||||
style="width:7.5rem"></el-date-picker>
|
style="width:8.5rem"></el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="部门:" prop="instrGroup">
|
<el-form-item label="部门:" prop="instrGroup">
|
||||||
<SelectTable v-model:data="queryParams.instrGroup" :fields="instrGroupFields"
|
<SelectTable v-model:data="queryParams.instrGroup" :fields="instrGroupFields"
|
||||||
:tableData="instrGroupOptions" label="zdmc" value="zddh" objKey="zddh" :border="true" width="9rem"
|
:tableData="instrGroupOptions" label="zdmc" value="zddh" objKey="zddh" :border="true" width="8rem"
|
||||||
placeholder="请选择部门" @getDataValue="handleinstrGroupChange" :clearable="false" :size="aotuSize" />
|
placeholder="请选择部门" @getDataValue="handleinstrGroupChange" :clearable="false" :size="aotuSize" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
@ -460,8 +460,12 @@ const delSampleHd = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const row = labPatList.value[highlightRowIndex.value];
|
const row = labPatList.value[highlightRowIndex.value];
|
||||||
labPatListRef.value.setCurrentRow(row);
|
if (row) {
|
||||||
selectJob(row);
|
labPatListRef.value.setCurrentRow(row);
|
||||||
|
selectJob(row);
|
||||||
|
} else {
|
||||||
|
handleCreate()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
@ -549,10 +553,11 @@ const changeStatus = (updatedPat: any, flag: boolean) => {
|
|||||||
// 更新列表中对应的样本信息
|
// 更新列表中对应的样本信息
|
||||||
labPatList.value = labPatList.value.map((item, i) => i === index ? { ...labPat.value } : item);
|
labPatList.value = labPatList.value.map((item, i) => i === index ? { ...labPat.value } : item);
|
||||||
highlightRowIndex.value = index;
|
highlightRowIndex.value = index;
|
||||||
|
setTimeout(() => {
|
||||||
// nextTick(() => {
|
nextTick(() => {
|
||||||
// labPatListRef.value.setCurrentRow(labPat.value);
|
labPatListRef.value.setCurrentRow(labPatList.value[index]);
|
||||||
// });
|
});
|
||||||
|
}, 10)
|
||||||
|
|
||||||
// 条码号输入后操作
|
// 条码号输入后操作
|
||||||
if (flag) {
|
if (flag) {
|
||||||
@ -602,13 +607,13 @@ const fetchlabPatList = () => {
|
|||||||
if (index !== -1) {
|
if (index !== -1) {
|
||||||
highlightRowIndex.value = index;
|
highlightRowIndex.value = index;
|
||||||
const row = labPatList.value[index];
|
const row = labPatList.value[index];
|
||||||
setTimeout(() => { labPatListRef.value.setCurrentRow(row); }, 100)
|
setTimeout(() => { labPatListRef.value.setCurrentRow(row); }, 10)
|
||||||
selectJob(row);
|
selectJob(row);
|
||||||
|
} else {
|
||||||
|
highlightRowIndex.value = 0;
|
||||||
|
setTimeout(() => { labPatListRef.value.setCurrentRow(res.data[0]); }, 10)
|
||||||
|
selectJob(res.data[0])
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
highlightRowIndex.value = 0;
|
|
||||||
setTimeout(() => { labPatListRef.value.setCurrentRow(res.data[0]); }, 100)
|
|
||||||
selectJob(res.data[0])
|
|
||||||
}
|
}
|
||||||
getTotals()
|
getTotals()
|
||||||
} else {
|
} else {
|
||||||
@ -739,11 +744,12 @@ const initSocket = () => {
|
|||||||
|
|
||||||
// 页面卸载时清理
|
// 页面卸载时清理
|
||||||
onUnmounted(() => {
|
onUnmounted(() => {
|
||||||
closeWebSocket();
|
// closeWebSocket();
|
||||||
});
|
});
|
||||||
|
|
||||||
// 发送消息
|
// 发送消息
|
||||||
const sendMessage = () => {
|
const sendMessage = () => {
|
||||||
|
return
|
||||||
const isSuccess = sendWebSocketMessage({ yq: queryParams.value.yq });
|
const isSuccess = sendWebSocketMessage({ yq: queryParams.value.yq });
|
||||||
if (isSuccess) {
|
if (isSuccess) {
|
||||||
console.log(`发送消息`);
|
console.log(`发送消息`);
|
||||||
|
|||||||
@ -227,7 +227,7 @@ const handleFieldChange = async () => {
|
|||||||
// 保存病人信息
|
// 保存病人信息
|
||||||
const saveLabPat = async (changedField: any) => {
|
const saveLabPat = async (changedField: any) => {
|
||||||
if (props.labPat.id) {
|
if (props.labPat.id) {
|
||||||
updateLabPat({ ...props.labPatKey, ...props.labPat }).then((res: any) => {
|
updateLabPat({ ...props.labPatKey, ...props.labPat, ybh: props.labPatKey.ybh }).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
if (sqhFlag.value) {
|
if (sqhFlag.value) {
|
||||||
sqhValue.value = ''
|
sqhValue.value = ''
|
||||||
@ -245,7 +245,7 @@ const saveLabPat = async (changedField: any) => {
|
|||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
if (!changedField) return
|
if (!changedField) return
|
||||||
changepatcolumn({ ...props.labPatKey, column: changedField?.field, value: changedField?.newValue }).then((res: any) => {
|
changepatcolumn({ ...props.labPatKey, column: changedField?.field, value: changedField?.newValue, ybh: props.labPatKey.ybh }).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
if (sqhFlag.value) {
|
if (sqhFlag.value) {
|
||||||
sqhValue.value = ''
|
sqhValue.value = ''
|
||||||
|
|||||||
@ -68,7 +68,7 @@
|
|||||||
<el-input v-model="fcYbh" @keyup.enter="subHandle()" />
|
<el-input v-model="fcYbh" @keyup.enter="subHandle()" />
|
||||||
</div>
|
</div>
|
||||||
<div class="mt10" style="text-align: center; width: 100%;">
|
<div class="mt10" style="text-align: center; width: 100%;">
|
||||||
<el-button type="primary" @click="subHandle()"> 确认 </el-button>
|
<el-button type="primary" :loading="subloading" @click="subHandle()"> 确认 </el-button>
|
||||||
<el-button @click="closeHandle">取消</el-button>
|
<el-button @click="closeHandle">取消</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
@ -107,9 +107,10 @@ const show = ref(false)
|
|||||||
|
|
||||||
const fcYbh = ref('')
|
const fcYbh = ref('')
|
||||||
const fcYq = ref('')
|
const fcYq = ref('')
|
||||||
|
const subloading = ref(false)
|
||||||
const subHandle = () => {
|
const subHandle = () => {
|
||||||
if (!fcYbh.value.trim()) return ElMessage.warning('请输入复查的样本号')
|
if (!fcYbh.value.trim()) return ElMessage.warning('请输入复查的样本号')
|
||||||
|
subloading.value = true
|
||||||
const data = {
|
const data = {
|
||||||
newybh: fcYbh.value,
|
newybh: fcYbh.value,
|
||||||
newyq: fcYq.value,
|
newyq: fcYq.value,
|
||||||
@ -120,6 +121,8 @@ const subHandle = () => {
|
|||||||
ElMessage.success('操作成功')
|
ElMessage.success('操作成功')
|
||||||
closeHandle()
|
closeHandle()
|
||||||
}
|
}
|
||||||
|
}).finally(() => {
|
||||||
|
subloading.value = false
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
const closeHandle = () => {
|
const closeHandle = () => {
|
||||||
|
|||||||
@ -29,8 +29,8 @@
|
|||||||
<el-table v-if="refreshTable" v-loading="loading" :data="deptList" row-key="deptId"
|
<el-table v-if="refreshTable" v-loading="loading" :data="deptList" row-key="deptId"
|
||||||
:default-expand-all="isExpandAll" :tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
|
:default-expand-all="isExpandAll" :tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
|
||||||
height="calc(100vh - 280px)">
|
height="calc(100vh - 280px)">
|
||||||
<el-table-column prop="deptName" label="部门名称" width="260"></el-table-column>
|
<el-table-column prop="deptName" label="部门名称"></el-table-column>
|
||||||
<el-table-column prop="orderNum" label="排序" width="200"></el-table-column>
|
<el-table-column prop="orderNum" label="排序" width="100"></el-table-column>
|
||||||
<el-table-column prop="status" label="状态" width="100">
|
<el-table-column prop="status" label="状态" width="100">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<dict-tag :options="sys_normal_disable" :value="scope.row.status" />
|
<dict-tag :options="sys_normal_disable" :value="scope.row.status" />
|
||||||
@ -93,7 +93,7 @@
|
|||||||
<el-form-item label="部门状态">
|
<el-form-item label="部门状态">
|
||||||
<el-radio-group v-model="form.status">
|
<el-radio-group v-model="form.status">
|
||||||
<el-radio v-for="dict in sys_normal_disable" :key="dict.value" :label="dict.value">{{ dict.label
|
<el-radio v-for="dict in sys_normal_disable" :key="dict.value" :label="dict.value">{{ dict.label
|
||||||
}}</el-radio>
|
}}</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user