修改海南测试问题

This commit is contained in:
GGJ
2024-10-30 09:29:39 +08:00
parent 1aa7e4263b
commit 1df2b26b04
32 changed files with 469 additions and 478 deletions

View File

@@ -265,12 +265,22 @@ const deleteEven = () => {
message: '请选择要删除的数据'
})
} else {
deleteTempLineDebugReport(tableStore.table.selection.map(item => item.id)).then(res => {
ElMessage({
type: 'success',
message: '删除成功!'
})
tableStore.index()
ElMessageBox.confirm('此操作将永久删除, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
})
.then(() => {
deleteTempLineDebugReport(tableStore.table.selection.map(item => item.id)).then(res => {
ElMessage({
type: 'success',
message: '删除成功!'
})
tableStore.index()
})
})
}
}

View File

@@ -3,20 +3,13 @@
<TableHeader area datePicker nextFlag theCurrentTime ref="TableHeaderRef">
<template #select>
<el-form-item label="搜索">
<el-input
v-model="tableStore.table.params.searchValue"
placeholder="输入变电站、终端、监测点名称"
clearable
></el-input>
<el-input v-model="tableStore.table.params.searchValue" placeholder="输入变电站、终端、监测点名称"
clearable></el-input>
</el-form-item>
<el-form-item label="流程状态">
<el-select v-model="tableStore.table.params.status" clearable placeholder="请选择流程状态">
<el-option
v-for="item in statusSelect"
:key="item.id"
:label="item.name"
:value="item.id"
></el-option>
<el-option v-for="item in statusSelect" :key="item.id" :label="item.name"
:value="item.id"></el-option>
</el-select>
</el-form-item>
</template>
@@ -43,9 +36,9 @@ import addForm from './addForm.vue'
import { useAdminInfo } from '@/stores/adminInfo'
import { ElMessage } from 'element-plus'
import { ElMessageBox } from 'element-plus/es'
import {cancelMointorPointFormData, getTempLineDetailsById} from '@/api/supervision-boot/monitorpoint/index'
import { cancelMointorPointFormData, getTempLineDetailsById } from '@/api/supervision-boot/monitorpoint/index'
import { deleteTempLineReport } from '@/api/supervision-boot/delete/index'
import {getTerminalDetailsById} from "@/api/supervision-boot/terminal";
import { getTerminalDetailsById } from "@/api/supervision-boot/terminal";
//获取登陆用户姓名和部门
const adminInfo = useAdminInfo()
const dictData = useDictData()
@@ -240,13 +233,23 @@ const deleteEven = () => {
message: '请选择要删除的数据'
})
} else {
deleteTempLineReport(tableStore.table.selection.map(item => item.id)).then(res => {
ElMessage({
type: 'success',
message: '删除成功!'
})
tableStore.index()
ElMessageBox.confirm('此操作将永久删除, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
})
.then(() => {
deleteTempLineReport(tableStore.table.selection.map(item => item.id)).then(res => {
ElMessage({
type: 'success',
message: '删除成功!'
})
tableStore.index()
})
})
}
}
@@ -294,22 +297,22 @@ const handleAudit = (instanceId: any, historyInstanceId: any) => {
})
}
const props = defineProps({id: {type: String, default: 'null'}})
const props = defineProps({ id: { type: String, default: 'null' } })
watch(() => props.id, async (newValue, oldValue) => {
if (newValue === 'null') return // 直接返回,避免后续逻辑执行
const fullId = newValue.split('@')[0]
let nowTime = Date.now()
const routeTime = Number(newValue.split('@')[1])
if (isNaN(routeTime) || nowTime - routeTime > import.meta.env.VITE_ROUTE_TIME_OUT) return // 路由时间超过500ms则不执行
await getTempLineDetailsById({id:fullId}).then(res => {
if (res && res.code == 'A0000') {
addForms.value.open({
title: '重新发起',
row: res.data
})
}
})
}, {immediate: true})
if (newValue === 'null') return // 直接返回,避免后续逻辑执行
const fullId = newValue.split('@')[0]
let nowTime = Date.now()
const routeTime = Number(newValue.split('@')[1])
if (isNaN(routeTime) || nowTime - routeTime > import.meta.env.VITE_ROUTE_TIME_OUT) return // 路由时间超过500ms则不执行
await getTempLineDetailsById({ id: fullId }).then(res => {
if (res && res.code == 'A0000') {
addForms.value.open({
title: '重新发起',
row: res.data
})
}
})
}, { immediate: true })
</script>
<style scoped lang="scss">

View File

@@ -15,7 +15,8 @@
<template #operation>
<el-button icon="el-icon-Plus" type="primary" @click="addFormModel">新增</el-button>
<el-button icon="el-icon-Delete" type="primary" @click="deleteEven">删除</el-button>
<el-button icon="el-icon-Download" type="primary" @click="exportExcelTemplate" :loading="loading">模版下载</el-button>
<el-button icon="el-icon-Download" type="primary" @click="exportExcelTemplate"
:loading="loading">模版下载</el-button>
<el-button icon="el-icon-Upload" type="primary" @click="importUserData">批量导入</el-button>
</template>
</TableHeader>
@@ -268,13 +269,24 @@ const deleteEven = () => {
message: '请选择要删除的数据'
})
} else {
deleteDevReport(tableStore.table.selection.map(item => item.id)).then(res => {
ElMessage({
type: 'success',
message: '删除成功!'
})
tableStore.index()
ElMessageBox.confirm('此操作将永久删除, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
})
.then(() => {
deleteDevReport(tableStore.table.selection.map(item => item.id)).then(res => {
ElMessage({
type: 'success',
message: '删除成功!'
})
tableStore.index()
})
})
}
}

View File

@@ -2,29 +2,29 @@
<div class="default-main">
<el-tabs v-model="activeName" type="border-card">
<el-tab-pane label="终端入网检测" name="1">
<terminal :id="id" v-if="activeName == '1'"/>
<terminal :id="id" v-if="activeName == '1'" />
</el-tab-pane>
<el-tab-pane label="监测点台账录入" name="2">
<monitorpoint :id="id" v-if="activeName == '2'"/>
<monitorpoint :id="id" v-if="activeName == '2'" />
</el-tab-pane>
<el-tab-pane label="监测点联调列表" name="3">
<jointDebugList :id="id" v-if="activeName == '3'"/>
<jointDebugList :id="id" v-if="activeName == '3'" />
</el-tab-pane>
<el-tab-pane label="终端周期检测" name="4">
<cycleDetection :id="id" :businessKey='key' v-if="activeName == '4'"/>
<cycleDetection :id="id" :businessKey='key' v-if="activeName == '4'" />
</el-tab-pane>
</el-tabs>
</div>
</template>
<script setup lang="ts">
import {ref} from 'vue'
import {mainHeight} from '@/utils/layout'
import { ref } from 'vue'
import { mainHeight } from '@/utils/layout'
import terminal from './components/terminainal/index.vue'
import monitorpoint from './components/monitorpoint/index.vue'
import jointDebugList from './components/jointDebugList/index.vue'
import cycleDetection from './components/cycleDetection/index.vue'
import {useRoute} from "vue-router";
import { useRoute } from "vue-router";
defineOptions({
name: 'terminalNetwotk'
@@ -38,7 +38,8 @@ const key = ref('')
watch(() => route.query.t, async (newValue, oldValue) => {
if (route.fullPath.includes('terminalNetwotk')) {
let type = (route.query.type as string) || 'null'
if (type == 'null' || type == '1') {
if (type == 'null') { }
else if (type == '1') {
activeName.value = '1'
} else if (type == '2') {
activeName.value = '2'
@@ -51,7 +52,7 @@ watch(() => route.query.t, async (newValue, oldValue) => {
key.value = (route.query.key as string) || 'null'
id.value = id.value + '@' + route.query.t
}
}, {deep: true, immediate: true})
}, { deep: true, immediate: true })
const layout = mainHeight(63) as any