联调 前置管理页面
This commit is contained in:
@@ -158,3 +158,11 @@ export function nodeDeviceTree(data: any) {
|
||||
params: data
|
||||
})
|
||||
}
|
||||
//更新设备进程号
|
||||
export function updateDeviceProcess(data: any) {
|
||||
return createAxios({
|
||||
url: '/device-boot/nodeDevice/updateDeviceProcess',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
@@ -54,7 +54,6 @@
|
||||
default-expand-all
|
||||
:props="defaultProps"
|
||||
:filter-node-method="filterNode"
|
||||
|
||||
>
|
||||
<template #default="{ node, data }">
|
||||
<div class="custom-tree-node">
|
||||
@@ -164,7 +163,7 @@
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { ref, onMounted, provide, reactive, nextTick } from 'vue'
|
||||
import { addNode, delNode, updateNode, nodeDeviceTree } from '@/api/device-boot/Business'
|
||||
import { addNode, delNode, updateNode, nodeDeviceTree, updateDeviceProcess } from '@/api/device-boot/Business'
|
||||
import TableStore from '@/utils/tableStore'
|
||||
import Table from '@/components/table/index.vue'
|
||||
import TableHeader from '@/components/table/header/index.vue'
|
||||
@@ -192,7 +191,7 @@ const popUps = ref(false)
|
||||
const tableRef = ref()
|
||||
const processNo = ref('')
|
||||
const ruleFormRef = ref()
|
||||
const dataSource = ref([])
|
||||
const dataSource:any = ref([])
|
||||
const defaultProps = {
|
||||
children: 'deviceInfoList',
|
||||
label: 'name'
|
||||
@@ -218,7 +217,7 @@ const rules = reactive({
|
||||
const dialogFormVisible = ref(false)
|
||||
|
||||
const dialogTitle = ref('新增前置机')
|
||||
|
||||
const processId = ref('')
|
||||
const tableStore = new TableStore({
|
||||
url: '/device-boot/node/nodeList',
|
||||
method: 'POST',
|
||||
@@ -339,11 +338,22 @@ const change = val => {
|
||||
treeRef.value!.filter(filterText.value)
|
||||
}
|
||||
const edit = (data: any) => {
|
||||
console.log("🚀 ~ edit ~ data:", data)
|
||||
console.log('🚀 ~ edit ~ data:', data)
|
||||
processNo.value = data.processNo
|
||||
processId.value = data.id
|
||||
popUps.value = true
|
||||
}
|
||||
const bindTheProcess = () => {}
|
||||
// 更新进程号
|
||||
const bindTheProcess = () => {
|
||||
updateDeviceProcess({
|
||||
id: processId.value,
|
||||
processNo: processNo.value
|
||||
}).then(res => {
|
||||
ElMessage.success('修改成功!')
|
||||
popUps.value = false
|
||||
currentChangeEvent()
|
||||
})
|
||||
}
|
||||
const filterNode = (value: string, data: any, node: any) => {
|
||||
if (!value) return true
|
||||
// return data.name.includes(value)
|
||||
|
||||
@@ -73,6 +73,11 @@
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="电网标志">
|
||||
<el-select v-model="tableStore.table.params.powerFlag" placeholder="请选择电网标志">
|
||||
<el-option v-for="item in sign" :key="item.id" :label="item.name" :value="item.algoDescribe" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</TableHeader>
|
||||
</div>
|
||||
@@ -117,6 +122,7 @@ const interfereoption = dictData.getBasicData('Interference_Source')
|
||||
//字典获取统计类型
|
||||
const classificationData = dictData.getBasicData('Statistical_Type', ['Report_Type'])
|
||||
//调用区域接口获取区域
|
||||
const sign = dictData.getBasicData('power_flag')
|
||||
const treeData = ref([])
|
||||
const idArr = ref([])
|
||||
const activeName = ref(0)
|
||||
@@ -204,6 +210,7 @@ tableStore.table.params.statisticalType = classificationData[0]
|
||||
tableStore.table.params.scale = []
|
||||
tableStore.table.params.manufacturer = []
|
||||
tableStore.table.params.loadType = []
|
||||
tableStore.table.params.powerFlag = sign[0]?.algoDescribe || 0
|
||||
tableStore.table.params.serverName = 'harmonicBoot'
|
||||
provide('tableStore', tableStore)
|
||||
const tree2List = (list: any, pid?: string) => {
|
||||
|
||||
@@ -2,6 +2,11 @@
|
||||
<div class="default-main">
|
||||
<TableHeader datePicker ref="header">
|
||||
<template v-slot:select>
|
||||
<el-form-item label="电网标志">
|
||||
<el-select v-model="tableStore.table.params.powerFlag" placeholder="请选择电网标志">
|
||||
<el-option v-for="item in sign" :key="item.id" :label="item.name" :value="item.algoDescribe" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</TableHeader>
|
||||
<div v-loading="tableStore.table.loading" class="pr10">
|
||||
@@ -138,7 +143,7 @@ defineOptions({
|
||||
})
|
||||
const dictData = useDictData()
|
||||
const echartList = ref({})
|
||||
|
||||
const sign = dictData.getBasicData('power_flag')
|
||||
const header = ref()
|
||||
const options = dictData.getBasicData('Pollution_Statis', ['I_Neg', 'V_Inharm', 'V_Dev', 'V_Unbalance', 'Plt', 'Freq_Dev'])
|
||||
const tableStore = new TableStore({
|
||||
@@ -158,7 +163,7 @@ provide('tableStore', tableStore)
|
||||
|
||||
tableStore.table.params.deptIndex = dictData.state.area[0].id
|
||||
tableStore.table.params.monitorFlag = 2
|
||||
tableStore.table.params.powerFlag = 2
|
||||
tableStore.table.params.powerFlag = sign[0]?.algoDescribe || 0
|
||||
tableStore.table.params.statisticalType = {}
|
||||
|
||||
|
||||
|
||||
@@ -129,6 +129,7 @@ const tableStore = new TableStore({
|
||||
url: '/harmonic-boot/steadyQualify/getSteadyQualifyCensus',
|
||||
showPage: false,
|
||||
method: 'POST',
|
||||
// publicHeight: 10,
|
||||
column: [],
|
||||
beforeSearchFun: () => {
|
||||
tableStore.table.params = tableStoreParams.value
|
||||
|
||||
@@ -73,6 +73,11 @@
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="电网标志">
|
||||
<el-select v-model="tableStore.table.params.powerFlag" placeholder="请选择电网标志">
|
||||
<el-option v-for="item in sign" :key="item.id" :label="item.name" :value="item.algoDescribe" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</TableHeader>
|
||||
</div>
|
||||
@@ -118,6 +123,7 @@ const interfereoption = dictData.getBasicData('Interference_Source')
|
||||
const classificationData = dictData.getBasicData('Statistical_Type', ['Report_Type'])
|
||||
//调用区域接口获取区域
|
||||
const treeData = ref([])
|
||||
const sign = dictData.getBasicData('power_flag')
|
||||
const idArr = ref([])
|
||||
const activeName = ref(0)
|
||||
const getTreeData = async () => {
|
||||
@@ -263,6 +269,7 @@ tableStore.table.params.scale = []
|
||||
tableStore.table.params.manufacturer = []
|
||||
tableStore.table.params.loadType = []
|
||||
tableStore.table.params.serverName = 'harmonicBoot'
|
||||
tableStore.table.params.powerFlag = sign[0]?.algoDescribe || 0
|
||||
provide('tableStore', tableStore)
|
||||
const tree2List = (list: any, pid?: string) => {
|
||||
//存储结果的数组
|
||||
|
||||
Reference in New Issue
Block a user