样式调整
This commit is contained in:
@@ -101,6 +101,8 @@
|
||||
<!-- <el-button type="primary" :icon="CirclePlus" @click="addDevice('设备新增')" v-if="form.activeTabs === 0"
|
||||
>设备新增</el-button> -->
|
||||
|
||||
<el-button type="primary" :icon="Odometer" @click="handleTest('系数校准')" v-if="form.activeTabs === 0"
|
||||
>系数校准</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</template>
|
||||
@@ -120,7 +122,7 @@
|
||||
link
|
||||
:icon="Download"
|
||||
@click="openDrawer('报告下载', scope.row)"
|
||||
v-if="form.activeTabs === 3 && form.activeChildTabs === 0"
|
||||
v-if="form.activeTabs === 3 && form.activeChildTabs === 0 && scope.row.reportState === 1"
|
||||
>报告下载</el-button
|
||||
>
|
||||
|
||||
@@ -206,12 +208,13 @@
|
||||
</ProTable>
|
||||
|
||||
<!-- 检测过程对话框 -->
|
||||
<testPopup
|
||||
<!-- <testPopup
|
||||
:visible="dialogFormVisible"
|
||||
:formData="dialogForm"
|
||||
:dialogTitle="dialogTitle"
|
||||
@update:visible="dialogFormVisible = $event"
|
||||
/>
|
||||
/> -->
|
||||
<TestPopup ref="testPopup"></TestPopup>
|
||||
|
||||
<reportPopup
|
||||
:visible="reportDialogVisible"
|
||||
@@ -232,6 +235,9 @@
|
||||
:visible="matchDialogVisible"
|
||||
@update:visible="matchDialogVisible = $event"
|
||||
></matchPopup>
|
||||
|
||||
<!--系数校准-->>
|
||||
<ChannelsTest ref="channelsTest"></ChannelsTest>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -243,17 +249,19 @@ import { ElMessage, ElMessageBox, ElLoading, Action} from "element-plus";
|
||||
import ProTable from "@/components/ProTable/index.vue";
|
||||
import { type ProTableInstance, type ColumnProps } from '@/components/ProTable/interface'
|
||||
import {
|
||||
Search,View,Delete,Download,EditPen,Clock,ChatLineRound,ChatLineSquare,ChatDotSquare,Postcard,Notebook,Switch,PieChart,CirclePlus
|
||||
Search,View,Delete,Download,EditPen,Clock,ChatLineRound,ChatLineSquare,ChatDotSquare,Postcard,Notebook,Switch,PieChart,CirclePlus,Odometer
|
||||
} from "@element-plus/icons-vue";
|
||||
import { getPlanList } from "@/api/plan/planList";
|
||||
import deviceDataList from '@/api/device/device/deviceData'
|
||||
import testPopup from "./testPopup.vue";
|
||||
import TestPopup from "./testPopup.vue";
|
||||
import reportPopup from "./reportPopup.vue";
|
||||
import dataCheckPopup from "./dataCheckPopup.vue";
|
||||
import dataCheckChangeErrSysPopup from "./dataCheckChangeErrSysPopup.vue";
|
||||
import { getBoundPqDevList } from '@/api/plan/plan.ts'
|
||||
import { onMounted, reactive, ref, watch } from "vue";
|
||||
import { useDictStore } from '@/stores/modules/dict'
|
||||
import ChannelsTest from './channelsTest.vue'
|
||||
import { useModeStore } from '@/stores/modules/mode'; // 引入模式 store
|
||||
|
||||
const dictStore = useDictStore()
|
||||
let devNum = 0;//当前选取的被检设备数量
|
||||
@@ -264,7 +272,6 @@ const router = useRouter();
|
||||
const value1 = ref("");
|
||||
const value2 = ref("");
|
||||
const tableHeight = ref(0);
|
||||
const dialogFormVisible = ref(false)
|
||||
const reportDialogVisible = ref(false)
|
||||
const dataCheckDialogVisible = ref(false)
|
||||
const dataCheckChangeErrSysDialogVisible = ref(false)
|
||||
@@ -280,6 +287,7 @@ const dialogForm = ref<any>({
|
||||
enable:1,
|
||||
state:1,
|
||||
});
|
||||
const modeStore = useModeStore();
|
||||
const shouldShowOption = (item) => {
|
||||
//return !item.disabled;
|
||||
return item;
|
||||
@@ -292,12 +300,18 @@ const documentStateShow = ref(false);
|
||||
const checkStateShow = ref(true);
|
||||
const operationMinWidth = ref(200);
|
||||
const selectionShow = ref(true);
|
||||
const channelsTest = ref()
|
||||
const testPopup = ref()
|
||||
|
||||
const props = defineProps({
|
||||
id: {
|
||||
type: String,
|
||||
required: true,
|
||||
},
|
||||
isTimeCheck: {
|
||||
type: Boolean,
|
||||
required: true,
|
||||
},
|
||||
})
|
||||
|
||||
//下拉框数据
|
||||
@@ -383,7 +397,6 @@ const proTable = ref<ProTableInstance>();
|
||||
const boundPqDevList=ref<Device.ReqPqDevParams[]>([])//根据检测计划id查询出所有已绑定的设备
|
||||
|
||||
const getTableList = async (params: any) => {
|
||||
console.log('activeTabs',form.activeTabs)
|
||||
if(props.id){
|
||||
const checkStateList = ref<any>()
|
||||
if(form.value.checkStatus != null){
|
||||
@@ -508,6 +521,7 @@ const columns = reactive<ColumnProps<Device.ResPqDev>[]>([
|
||||
])
|
||||
|
||||
|
||||
|
||||
// 跳转详情页
|
||||
const toDetail = () => {
|
||||
router.push(
|
||||
@@ -536,8 +550,8 @@ const handleSelectionChange = (selection: any[]) => {
|
||||
devChannelsNum += selection[i].dev_Chns;
|
||||
}
|
||||
|
||||
devTestedNum = selection.filter((item) => item.check_State === '检测完成').length;
|
||||
const result = selection.filter((item) => item.check_Result != "不符合")
|
||||
devTestedNum = selection.filter((item) => item.checkState === 2).length;
|
||||
const result = selection.filter((item) => item.checkResult != 0)
|
||||
if(result.length > 0)
|
||||
{
|
||||
testType= "test";
|
||||
@@ -584,7 +598,6 @@ const changeActiveTabs = (val: number,val2: number,tabledata:any[]) => {
|
||||
|
||||
//根据当前功能,初始化表头下拉框中的默认值和禁用值
|
||||
function tableHeaderInit(val: number) {
|
||||
console.log("tableHeader",val)
|
||||
refreshStatusList()
|
||||
switch (val) {
|
||||
case 0://设备检测
|
||||
@@ -715,7 +728,7 @@ const addDevice = (val:string) => {
|
||||
path: "/machine/device",
|
||||
});
|
||||
};
|
||||
const handleTest = (val:string) => {
|
||||
const handleTest = async (val:string) => {
|
||||
|
||||
if(devNum == 0)
|
||||
{
|
||||
@@ -773,23 +786,29 @@ const handleTest = (val:string) => {
|
||||
.then(() => {
|
||||
ElMessage.success('不合格项复检');
|
||||
dialogTitle.value = val;
|
||||
dialogFormVisible.value = true; // 打开对话框
|
||||
testPopup.value?.open(dialogTitle.value,props.isTimeCheck)// 打开对话框
|
||||
})
|
||||
.catch((action: Action) => {
|
||||
ElMessage.success('全部复检');
|
||||
dialogTitle.value = val;
|
||||
dialogFormVisible.value = true; // 打开对话框
|
||||
testPopup.value?.open(dialogTitle.value,props.isTimeCheck) // 打开对话框
|
||||
})
|
||||
}
|
||||
else
|
||||
{
|
||||
ElMessage.success(val);
|
||||
dialogTitle.value = val;
|
||||
dialogFormVisible.value = true; // 打开对话框
|
||||
testPopup.value?.open(dialogTitle.value,props.isTimeCheck)
|
||||
}
|
||||
return
|
||||
|
||||
}
|
||||
|
||||
if(val==='系数校准')
|
||||
{
|
||||
channelsTest.value?.open()
|
||||
return
|
||||
}
|
||||
|
||||
if(devTestedNum == 0)
|
||||
{
|
||||
@@ -822,6 +841,9 @@ const handleTest = (val:string) => {
|
||||
ElMessage.success("归档成功");
|
||||
}, 2000)
|
||||
}
|
||||
|
||||
|
||||
|
||||
};
|
||||
|
||||
|
||||
@@ -829,7 +851,6 @@ const handleTest = (val:string) => {
|
||||
const openDrawer = (title: string, row: any) => {
|
||||
if (title === '查看')
|
||||
{
|
||||
console.log(title);
|
||||
const link = document.createElement('a');
|
||||
const fileUrl = 'G:/南网数研院非结构化数据生成程序MMS_JSON修改记录.docx'; // 文件路径
|
||||
link.href = fileUrl;
|
||||
|
||||
Reference in New Issue
Block a user