检验项目界面

This commit is contained in:
jiangs 2025-11-03 18:07:12 +08:00
parent 007ead7a1d
commit be1ebb4193
6 changed files with 184 additions and 44 deletions

View File

@ -1,28 +1,29 @@
//字典数据管理 //字典数据管理
import { defineStore } from 'pinia' import { defineStore } from 'pinia'
// export const useDictDataStore = defineStore('dictData', {
// state: () => ({
// dictData: {
// XMGL: [],
// ITEMCLASS: []
// }
// }),
// actions: {
// setDictData(data: any) {
// this.dictData = { ...this.dictData, ...data }
// }
// }
// })
//仪器数据 export const useComDictStore = defineStore('comDict', {
export const useYQStore = defineStore('yqStore', {
state: () => ({ state: () => ({
yqList: [] as any[], // 存储仪器列表 dictData: {
XMGL: [],
ITEMCLASS: []
}
}), }),
actions: { actions: {
setYQList(data: any[]) { setDictData(data: any) {
this.yqList = data this.dictData = { ...this.dictData, ...data }
} }
} }
}) })
//仪器数据
// export const useYQStore = defineStore('yqStore', {
// state: () => ({
// yqList: [] as any[], // 存储仪器列表
// }),
// actions: {
// setYQList(data: any[]) {
// this.yqList = data
// }
// }
// })

View File

@ -76,31 +76,31 @@
<tabView :tabList="tabList" v-model:activeTab="activeTab" /> <tabView :tabList="tabList" v-model:activeTab="activeTab" />
<div class="tabDiv"> <div class="tabDiv">
<template v-if="activeTab === 1"> <template v-if="activeTab === 1">
<Basic :visible="true" :dataList="basicTabData"/> <KeepAlive :is="Basic"><Basic :visible="true" :dataList="basicTabData"/></KeepAlive>
</template> </template>
<template v-if="activeTab === 2"> <template v-if="activeTab === 2">
<CommmonlyValues :visible="true"/> <KeepAlive><CommmonlyValues :visible="true"/></KeepAlive>
</template> </template>
<template v-if="activeTab === 3"> <template v-if="activeTab === 3">
<UseInstr :visible="true" :dataList="instrOptions"/> <KeepAlive><UseInstr :visible="true" :dataList="instrOptions"/></KeepAlive>
</template> </template>
<template v-if="activeTab === 4"> <template v-if="activeTab === 4">
<Knowledge :visible="true"/> <KeepAlive><Knowledge :visible="true"/></KeepAlive>
</template> </template>
<template v-if="activeTab === 5"> <template v-if="activeTab === 5">
<Sort :visible="true"/> <KeepAlive><Sort :visible="true"/></KeepAlive>
</template> </template>
<template v-if="activeTab === 6"> <template v-if="activeTab === 6">
<CommonDescriptions :visible="true"/> <KeepAlive><CommonDescriptions :visible="true"/></KeepAlive>
</template> </template>
<template v-if="activeTab === 7"> <template v-if="activeTab === 7">
<Parameter :visible="true"/> <KeepAlive><Parameter :visible="true"/></KeepAlive>
</template> </template>
<template v-if="activeTab === 8"> <template v-if="activeTab === 8">
<ChannelNumber :visible="true"/> <KeepAlive><ChannelNumber :visible="true"/></KeepAlive>
</template> </template>
<template v-if="activeTab === 9"> <template v-if="activeTab === 9">
<ReferenceValueDetails :visible="true"/> <KeepAlive><ReferenceValueDetails :visible="true"/></KeepAlive>
</template> </template>
</div> </div>
</el-col> </el-col>
@ -110,17 +110,17 @@
<script setup lang="ts"> <script setup lang="ts">
import { onMounted, ref,toRaw } from 'vue'; import { onMounted, ref,toRaw } from 'vue';
import Basic from './tab/basic.vue' import Basic from './tab/base/Basic.vue'
import CommmonlyValues from './tab/commmonlyValues.vue' import CommmonlyValues from './tab/CommmonlyValues.vue'
import UseInstr from './tab/useInstr.vue' import UseInstr from './tab/UseInstr.vue'
import Knowledge from './tab/knowledge.vue' import Knowledge from './tab/Knowledge.vue'
import CommonDescriptions from './tab/commonDescriptions.vue' import CommonDescriptions from './tab/CommonDescriptions.vue'
import CustomTable from '@/components/elTable/index.vue' import CustomTable from '@/components/elTable/index.vue'
import Sort from './tab/sort.vue' import Sort from './tab/Sort.vue'
import Parameter from './tab/parameter.vue'; import Parameter from './tab/Parameter.vue';
import ChannelNumber from './tab/channelNumber.vue'; import ChannelNumber from './tab/ChannelNumber.vue';
import ReferenceValueDetails from './tab/referenceValueDetails.vue'; import ReferenceValueDetails from './tab/ReferenceValueDetails.vue';
import { queryXmInfoNewService,queryXmInfoNewDetailService } from '@/api/liswork/labItem/LabItemApi'; import { queryXmInfoNewService,queryXmInfoNewDetailService } from '@/api/liswork/labItem/labItemApi';
import SelectTable from '@/components/SelectTable/index.vue' import SelectTable from '@/components/SelectTable/index.vue'
import { getGroupInstrdList } from '@/api/liswork/work/LisWork'; import { getGroupInstrdList } from '@/api/liswork/work/LisWork';
import tabView from '@/components/tabViews/index.vue'; import tabView from '@/components/tabViews/index.vue';
@ -145,7 +145,6 @@ const queryParams = ref({
isMIC: false || null //是否隐藏微生物项目 isMIC: false || null //是否隐藏微生物项目
}) })
//字典数据 //字典数据
//const dictData = ref<DictData>({});
const tableRef = ref() const tableRef = ref()
const xmglFields = ref([ const xmglFields = ref([
{ prop: 'value', label: '代号', width: 80, enablePinyinSearch: true }, { prop: 'value', label: '代号', width: 80, enablePinyinSearch: true },
@ -163,8 +162,8 @@ const tabList = ref([
{ label: '知识库', value: 4 }, { label: '知识库', value: 4 },
{ label: '整体排序', value: 5 }, { label: '整体排序', value: 5 },
{ label: '常见描述', value: 6 }, { label: '常见描述', value: 6 },
{ label: '参数', value: 7 }, // { label: '参数', value: 7 },
{ label: '通道号', value: 8 }, // { label: '通道号', value: 8 },
{ label: '参考值明细', value: 9 }, { label: '参考值明细', value: 9 },
]); ]);
const activeTab = ref(1) const activeTab = ref(1)

View File

@ -93,7 +93,7 @@
</el-form-item> </el-form-item>
<el-form-item label="参考值" prop="dyckz" label-width="60px"> <el-form-item label="参考值" prop="dyckz" label-width="60px">
<el-input placeholder="参考值" v-model="formData.dyckz"></el-input> <el-input placeholder="参考值" v-model="formData.dyckz"></el-input>
<el-button type="primary">多行参考值向导...</el-button> <el-button type="primary" @click="multiRefClick">多行参考值向导...</el-button>
</el-form-item> </el-form-item>
<el-form-item label="公式" prop="jsgs" label-width="40px" > <el-form-item label="公式" prop="jsgs" label-width="40px" >
<el-input placeholder="公式" v-model="formData.jsgs"></el-input> <el-input placeholder="公式" v-model="formData.jsgs"></el-input>
@ -163,12 +163,14 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
<MultiRef :refData="formData.dyckz" v-model:dialog-table-visible="mulitDialogTableVisible" @closeWithReturn="closeWithReturnMultiRef" />
</div> </div>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import { formatDict,getDictData } from '@/hooks'; import { formatDict,getDictData } from '@/hooks';
import { ref, computed, onMounted, PropType } from 'vue'; import MultiRef from './child/MultiRef.vue';
const props = defineProps({ const props = defineProps({
//是否显示 //是否显示
@ -186,6 +188,7 @@ const props = defineProps({
const formRef = ref(); const formRef = ref();
const formData = ref<any>({}); const formData = ref<any>({});
const mulitDialogTableVisible = ref(false)
computed(() => { computed(() => {
switch(formData.value.jgbz){ switch(formData.value.jgbz){
@ -200,11 +203,21 @@ computed(() => {
watch( watch(
() => props.dataList, () => props.dataList,
(newVal, oldVal) => { (newVal) => {
formData.value = newVal; formData.value = newVal;
} }
); );
//多行参考值
const multiRefClick = () => {
mulitDialogTableVisible.value = true
}
const closeWithReturnMultiRef = (val: string) => {
formData.value.dyckz = val;
mulitDialogTableVisible.value = false;
}
onMounted(() => { onMounted(() => {
getDictData('XMGL'); getDictData('XMGL');

View File

@ -0,0 +1,45 @@
<template>
<!-- 计算项目表达式生成向导 -->
<el-dialog title="计算项目表达式生成向导" width="600px" @close="onClose">
<el-row :gutter="0">
<el-input type="textarea" v-model="inputText"></el-input>
</el-row>
<el-row :gutter="0">
</el-row>
<!-- <el-form ref="form" :model="formData" label-width="80px">
<el-form-item>
<el-input type="textarea" v-model="formData.name"></el-input>
</el-form-item>
<el-form-item label="性别" prop="sex">
<el-select placeholder="请选择性别" v-model="formData.sex"></el-select>
</el-form-item>
<el-form-item label="" prop="">
<el-button size="small" @click="handleCancel">取 消</el-button>
<el-button size="small" type="primary" @click="handleOk">确 定</el-button>
</el-form-item>
</el-form> -->
</el-dialog>
</template>
<script setup lang="ts">
import CustomTable from '@/components/elTable/index.vue'
const formData = ref()
const inputText = ref('')
const onClose = () => {
}
const handleOk = () => {
}
const handleCancel = () => {
}
</script>
<style scoped lang="scss">
</style>

View File

@ -0,0 +1,82 @@
<template>
<!-- 多行参考值配置界面 -->
<el-dialog v-model="dialogTableVisibleVal" @close="handleDialogClose" title="多行参考值" width="600px" align-center>
<el-form :model="formData" inline>
<el-form-item prop="formData.refText">
<el-input v-model="formData.refText" type="textarea" autosize style="width: 400px;"></el-input>
</el-form-item>
<el-form-item>
<h3>多行参考值,每行作为一段:</h3>
<h3>如果系统使用标准性激素报告单,</h3>
<h3>则第一行表示:男性</h3>
<h3>第二行表示:女卵泡期</h3>
<h3>第三行表示:排卵期</h3>
<h3>第四行表示:黄体期</h3>
<h3>第五行表示:绝经期</h3>
</el-form-item>
</el-form>
<template #footer>
<div class="dialog-footer">
<el-button type="primary" @click="handClickOK">确定</el-button>
<el-button @click="handCancel">取消</el-button>
</div>
</template>
</el-dialog>
</template>
<script setup lang="ts">
const props = defineProps({
dialogTableVisible:{
type: Boolean,
default: false
},
refData:{
type: String,
required: true,
default: ''
}
})
const emit = defineEmits(['closeWithReturn','update:dialogTableVisible'])
const formData = ref<any>({
refText: ''
});
const dialogTableVisibleVal = ref(props.dialogTableVisible)
const handClickOK = () =>{
const refReturn = formData.value.refText.replace('\n','|')
emit('closeWithReturn',refReturn)
dialogTableVisibleVal.value = false;
}
const handCancel = () =>{
emit('update:dialogTableVisible', false); // 通知父组件关闭
}
const handleDialogClose = () => {
emit('update:dialogTableVisible', false); // 通知父组件关闭
}
const initFormData = () => {
const refList = props.refData?.split('|') || [];
formData.value.refText = refList.join('\n');
}
watch(
()=> props.dialogTableVisible,
(newVal)=>{
dialogTableVisibleVal.value = newVal
if(newVal){
initFormData();
}
},{ immediate: true } // 初始化时立即执行一次
)
</script>
<style scoped lang="scss">
</style>

View File

@ -42,7 +42,7 @@
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import {addReportService,queryReportService,updateReportService,deleteReportService} from '@/api/liswork/xtwh/ReportSettingApi'; import {addReportService,queryReportService,updateReportService,deleteReportService} from '@/api/liswork/xtwh/reportSettingApi';
import { LabReportInstr } from '@/types/index'; import { LabReportInstr } from '@/types/index';
import YQSelectTable from '@/components/SelectTable/YQSelectTable/index.vue'; import YQSelectTable from '@/components/SelectTable/YQSelectTable/index.vue';
import { ElMessage,ElMessageBox } from 'element-plus'; import { ElMessage,ElMessageBox } from 'element-plus';