微调
This commit is contained in:
@@ -328,11 +328,15 @@ const checkStatus: Dict[] = [
|
||||
const checkReportStatus: Dict[] = [
|
||||
{
|
||||
id: "0",
|
||||
label: '已生成',
|
||||
label: '未生成',
|
||||
},
|
||||
{
|
||||
id: "1",
|
||||
label: '未生成',
|
||||
label: '已生成',
|
||||
},
|
||||
{
|
||||
id: "2",
|
||||
label: '未检',
|
||||
},
|
||||
]
|
||||
//检测结果数组
|
||||
@@ -379,7 +383,8 @@ const proTable = ref<ProTableInstance>();
|
||||
const boundPqDevList=ref<Device.ReqPqDevParams[]>([])//根据检测计划id查询出所有已绑定的设备
|
||||
|
||||
const getTableList = async (params: any) => {
|
||||
<<<<<<< HEAD
|
||||
console.log('activeTabs',form.activeTabs)
|
||||
if(props.id){
|
||||
const checkStateList = ref<any>()
|
||||
if(form.value.checkStatus != null){
|
||||
checkStateList.value = [form.value.checkStatus]
|
||||
@@ -392,14 +397,8 @@ const getTableList = async (params: any) => {
|
||||
'reportState': form.value.checkReportStatus,
|
||||
'name':form.value.search
|
||||
});
|
||||
=======
|
||||
debugger
|
||||
if(props.id) {
|
||||
// const pqDevList_Result2 = await getBoundPqDevList({'planId': props.id,'checkStateList':[0,1,2]});
|
||||
// boundPqDevList.value = pqDevList_Result2.data as Device.ReqPqDevParams[];
|
||||
return getBoundPqDevList({'planId': props.id,'checkStateList':[0,1,2]});
|
||||
}
|
||||
>>>>>>> 07d02307e2507c32fc2b3c8b745b074d7a9bb74d
|
||||
|
||||
};
|
||||
|
||||
|
||||
@@ -478,10 +477,20 @@ const columns = reactive<ColumnProps<Device.ResPqDev>[]>([
|
||||
minWidth: 100,
|
||||
sortable:true,
|
||||
render: scope => {
|
||||
return (
|
||||
scope.row.checkState === 0 ? '已生成' : '未生成'
|
||||
)
|
||||
},
|
||||
if (scope.row.reportState === 0)
|
||||
{
|
||||
return '未生成';
|
||||
}
|
||||
else if (scope.row.reportState === 1)
|
||||
{
|
||||
return '已生成';
|
||||
}
|
||||
else if (scope.row.reportState === 2)
|
||||
{
|
||||
return '未检';
|
||||
}
|
||||
return '';
|
||||
}
|
||||
},
|
||||
{
|
||||
prop: 'documentState',
|
||||
@@ -491,7 +500,7 @@ const columns = reactive<ColumnProps<Device.ResPqDev>[]>([
|
||||
isShow: documentStateShow,
|
||||
render: scope => {
|
||||
return (
|
||||
scope.row.documentState === 0 ? '未归档' : '归档'
|
||||
scope.row.documentState === 0 ? '未归档' : '已归档'
|
||||
)
|
||||
},
|
||||
},
|
||||
|
||||
@@ -115,7 +115,7 @@ import Table from "../components/table.vue";
|
||||
//import { data } from "@/api/plan/static.json";
|
||||
import deviceDataList from '@/api/device/device/deviceData'
|
||||
import {getPlanListByPattern } from '@/api/plan/plan.ts'
|
||||
import { onMounted, onUnmounted, ref, watch } from "vue";
|
||||
import { onBeforeMount, onMounted, onUnmounted, ref, watch } from "vue";
|
||||
import { useModeStore } from '@/stores/modules/mode'; // 引入模式 store
|
||||
import { useDictStore } from '@/stores/modules/dict'
|
||||
import { type Plan } from "@/api/plan/interface";
|
||||
@@ -272,11 +272,8 @@ const getPieData = async (id: string) => {
|
||||
currentId.value = id; // 设置当前ID
|
||||
//handleCheckFunction(0)//切换左侧树,默认css功能是设备检测
|
||||
const boundPqDevList=ref<Device.ResPqDev[]>([])//根据检测计划id查询出所有已绑定的设备
|
||||
<<<<<<< HEAD
|
||||
const pqDevList_Result2 = await getBoundPqDevList({'planId': id,'checkStateList':[0,1,2,3]});
|
||||
=======
|
||||
const pqDevList_Result2 = await getBoundPqDevList({'planId': id,'checkStateList':[0,1,2]});
|
||||
>>>>>>> 07d02307e2507c32fc2b3c8b745b074d7a9bb74d
|
||||
|
||||
boundPqDevList.value = pqDevList_Result2.data as Device.ResPqDev[];
|
||||
console.log('饼图列',boundPqDevList)
|
||||
// 初始化计数对象
|
||||
@@ -314,14 +311,14 @@ console.log('饼图列',boundPqDevList)
|
||||
{ value: checkStateCount[3], name: "归档", itemStyle: { color: '#5470c6' } },
|
||||
];
|
||||
chartsData2.value = [
|
||||
{ value: checkResultCount[0], name: "未检" , itemStyle: { color: '#fac858' } },
|
||||
{ value: checkResultCount[1], name: "不符合" , itemStyle: { color: '#ee6666' } },
|
||||
{ value: checkResultCount[2], name: "符合", itemStyle: { color: '#91cc75' } },
|
||||
{ value: checkResultCount[2], name: "未检" , itemStyle: { color: '#fac858' } },
|
||||
{ value: checkResultCount[0], name: "不符合" , itemStyle: { color: '#ee6666' } },
|
||||
{ value: checkResultCount[1], name: "符合", itemStyle: { color: '#91cc75' } },
|
||||
];
|
||||
chartsData3.value = [
|
||||
{ value: reportStateCount[0], name: "未检" , itemStyle: { color: '#fac858' } },
|
||||
{ value: reportStateCount[1], name: "未生成" , itemStyle: { color: '#ee6666' } },
|
||||
{ value: reportStateCount[2], name: "已生成", itemStyle: { color: '#91cc75' } },
|
||||
{ value: reportStateCount[2], name: "未检" , itemStyle: { color: '#fac858' } },
|
||||
{ value: reportStateCount[0], name: "未生成" , itemStyle: { color: '#ee6666' } },
|
||||
{ value: reportStateCount[1], name: "已生成", itemStyle: { color: '#91cc75' } },
|
||||
];
|
||||
|
||||
pieRef1.value.init();
|
||||
@@ -425,15 +422,12 @@ onBeforeMount(async () => {
|
||||
code: 0,
|
||||
state: 0
|
||||
};
|
||||
<<<<<<< HEAD
|
||||
const planList = await getPlanListByPattern(reqPlan);
|
||||
=======
|
||||
|
||||
// debugger;
|
||||
const planList = await getPlanListByPattern(reqPlan);
|
||||
if (planList.data[0].children[0]) {
|
||||
currentId.value = planList.data[0].children[0].id;
|
||||
}
|
||||
>>>>>>> 07d02307e2507c32fc2b3c8b745b074d7a9bb74d
|
||||
if (chartsInfoRef.value) {
|
||||
resizeObserver.observe(chartsInfoRef.value);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user