完成 电能质量问题管理页面 修改 谐波普测管理页面
This commit is contained in:
@@ -1,45 +1,54 @@
|
||||
<template>
|
||||
<div>
|
||||
<div>
|
||||
<TableHeader area datePicker ref="TableHeaderRef">
|
||||
<template #select>
|
||||
<el-form-item label="问题来源">
|
||||
<el-select
|
||||
v-model="tableStore.table.params.problemSources"
|
||||
clearable
|
||||
placeholder="请选择问题来源"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in problemData"
|
||||
:key="item.code"
|
||||
:label="item.name"
|
||||
:value="item.code"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="填报进度">
|
||||
<el-select v-model="tableStore.table.params.reportProcess" clearable placeholder="请选择填报进度">
|
||||
<el-option
|
||||
v-for="item in fillingProgress"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<TableHeader area datePicker ref="TableHeaderRef">
|
||||
<template #select>
|
||||
<el-form-item label="问题来源">
|
||||
<el-select v-model="tableStore.table.params.problemSources" clearable placeholder="请选择问题来源">
|
||||
<el-option
|
||||
v-for="item in problemData"
|
||||
:key="item.code"
|
||||
:label="item.name"
|
||||
:value="item.code"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="填报进度">
|
||||
<el-select v-model="tableStore.table.params.reportProcess" clearable placeholder="请选择填报进度">
|
||||
<el-option
|
||||
v-for="item in fillingProgress"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="问题名称">
|
||||
<el-input
|
||||
v-model="tableStore.table.params.problemName"
|
||||
clearable
|
||||
placeholder="请输入问题名称"
|
||||
style="width: 100%"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</TableHeader>
|
||||
<Table ref="tableRef" />
|
||||
</div>
|
||||
<el-form-item label="问题名称">
|
||||
<el-input
|
||||
v-model="tableStore.table.params.problemName"
|
||||
clearable
|
||||
placeholder="请输入问题名称"
|
||||
style="width: 100%"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</TableHeader>
|
||||
<Table ref="tableRef" />
|
||||
|
||||
<!-- 审核 -->
|
||||
<el-dialog draggable title="问题审核" v-model="dialogVisible" width="1400px" :before-close="beforeClose">
|
||||
<Filling
|
||||
ref="FillingRef"
|
||||
v-if="dialogVisible"
|
||||
:isDisabled="true"
|
||||
:audit="true"
|
||||
:flag="true"
|
||||
@beforeClose="beforeClose"
|
||||
/>
|
||||
</el-dialog>
|
||||
|
||||
<!-- 审核记录 -->
|
||||
<recording ref="recordingRef" />
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
@@ -47,23 +56,25 @@ import { ref, onMounted, provide, nextTick } from 'vue'
|
||||
import TableStore from '@/utils/tableStore'
|
||||
import Table from '@/components/table/index.vue'
|
||||
import TableHeader from '@/components/table/header/index.vue'
|
||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
||||
import { mainHeight } from '@/utils/layout'
|
||||
import { useDictData } from '@/stores/dictData'
|
||||
import { addUse, updateUse, removeUse } from '@/api/advance-boot/bearingCapacity'
|
||||
|
||||
import Filling from './filling.vue'
|
||||
import recording from './recording.vue'
|
||||
const dictData = useDictData()
|
||||
const problemData = dictData.getBasicData('Problem_Sources')
|
||||
const fillingProgress = dictData.getBasicData('Fill_Progress')
|
||||
const TableHeaderRef = ref()
|
||||
|
||||
const FillingRef = ref()
|
||||
const ruleFormRef = ref()
|
||||
|
||||
const list: any = ref({})
|
||||
const recordingRef = ref(false)
|
||||
const dialogVisible = ref(false)
|
||||
const tableStore = new TableStore({
|
||||
url: '/process-boot/electricityQuality/getIssues',
|
||||
publicHeight: 65,
|
||||
method: 'POST',
|
||||
column: [
|
||||
// { width: '60', type: 'checkbox' },
|
||||
{
|
||||
field: 'index',
|
||||
title: '序号',
|
||||
@@ -99,7 +110,13 @@ const tableStore = new TableStore({
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Plus',
|
||||
render: 'basicButton',
|
||||
click: async row => {}
|
||||
click: async row => {
|
||||
dialogVisible.value = true
|
||||
setTimeout(() => {
|
||||
list.value = row
|
||||
FillingRef.value.open(row)
|
||||
}, 10)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
@@ -107,7 +124,9 @@ const tableStore = new TableStore({
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Plus',
|
||||
render: 'basicButton',
|
||||
click: async row => {}
|
||||
click: async row => {
|
||||
recordingRef.value.open(row)
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -124,7 +143,12 @@ tableStore.table.params.reportProcess = ''
|
||||
tableStore.table.params.problemName = ''
|
||||
tableStore.table.params.reportProcessStatus = 'Auditt'
|
||||
|
||||
const beforeClose = () => {
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
}
|
||||
provide('tableStore', tableStore)
|
||||
|
||||
onMounted(() => {
|
||||
tableStore.index()
|
||||
})
|
||||
|
||||
@@ -166,7 +166,7 @@
|
||||
</el-form>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="流程" name="2">
|
||||
<Filling v-if="dialogVisible" :isDisabled="true" ref="FillingRef" />
|
||||
<Filling v-if="dialogVisible" :isDisabled="true" :audit="true" ref="FillingRef" />
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
</el-dialog>
|
||||
|
||||
@@ -72,10 +72,37 @@
|
||||
@handleClose="handleClose"
|
||||
/>
|
||||
|
||||
<!-- 填报 -->
|
||||
<div style="display: flex; justify-content: center; margin-top: 10px" v-show="!disabled">
|
||||
<el-button type="primary" @click="Submit">提交审核</el-button>
|
||||
<el-button @click="handleClose">取消</el-button>
|
||||
</div>
|
||||
<!-- 审核 -->
|
||||
<el-form
|
||||
label-width="100px"
|
||||
:model="form"
|
||||
ref="ruleFormRef"
|
||||
:rules="rules"
|
||||
v-if="disabled && audit && flag && control == active"
|
||||
>
|
||||
<el-form-item prop="checkComment" label="审核意见:">
|
||||
<el-input
|
||||
type="textarea"
|
||||
style="width: 400px"
|
||||
:autosize="{ minRows: 2, maxRows: 4 }"
|
||||
placeholder="请输入内容"
|
||||
v-model="form.checkComment"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div
|
||||
style="display: flex; justify-content: center; margin-top: 10px"
|
||||
v-if="disabled && audit && flag && control == active"
|
||||
>
|
||||
<el-button type="primary" @click="adopt(1)">通过</el-button>
|
||||
<el-button type="primary" @click="adopt(0)">不通过</el-button>
|
||||
<el-button @click="handleClose">取消</el-button>
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { ref, onMounted } from 'vue'
|
||||
@@ -84,11 +111,13 @@ import process1 from './process1.vue'
|
||||
import process2 from './process2.vue'
|
||||
import process3 from './process3.vue'
|
||||
import process4 from './process4.vue'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import {
|
||||
getAbnormalDetail,
|
||||
getComplaintDetail,
|
||||
getGeneralSurveyDetail,
|
||||
getExcessiveDetail
|
||||
getExcessiveDetail,
|
||||
checkPowerQuality
|
||||
} from '@/api/process-boot/electricitymanagement'
|
||||
const emit = defineEmits(['beforeClose'])
|
||||
const dictData = useDictData()
|
||||
@@ -96,18 +125,31 @@ const addData: any = ref({})
|
||||
const List: any = ref({})
|
||||
const active = ref(4)
|
||||
const control = ref()
|
||||
const ruleFormRef = ref()
|
||||
const stepTitle = ['原因分析', '计划整改措施', '实际采取措施', '成效分析']
|
||||
const process0Ref = ref()
|
||||
const process1Ref = ref()
|
||||
const process2Ref = ref()
|
||||
const process3Ref = ref()
|
||||
const form = ref({
|
||||
checkComment: ''
|
||||
})
|
||||
const disabled = ref(false)
|
||||
const prop = defineProps({
|
||||
isDisabled: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
audit: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
flag: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
}
|
||||
})
|
||||
|
||||
const problemData = dictData.getBasicData('Problem_Sources')
|
||||
const open = async (row: any) => {
|
||||
addData.value = row
|
||||
@@ -124,7 +166,6 @@ const open = async (row: any) => {
|
||||
|
||||
setTimeout(() => {
|
||||
List.value = res.data
|
||||
|
||||
if (res.data.filePathYyfx == null) {
|
||||
active.value = 0
|
||||
} else if (res.data.filePathJhzg == null) {
|
||||
@@ -143,9 +184,18 @@ const open = async (row: any) => {
|
||||
active.value = 2
|
||||
}
|
||||
}
|
||||
|
||||
// 审核判断
|
||||
if (prop.audit) {
|
||||
active.value == 0 ? 0 : (active.value = active.value - 1)
|
||||
}
|
||||
|
||||
control.value = active.value == 4 ? 3 : active.value
|
||||
}, 0)
|
||||
}
|
||||
const rules = {
|
||||
checkComment: [{ required: true, message: '请输入审核意见', trigger: 'blur' }]
|
||||
}
|
||||
|
||||
const step = (e: number) => {
|
||||
if (active.value >= e) {
|
||||
@@ -176,8 +226,31 @@ const Submit = () => {
|
||||
}
|
||||
// 取消
|
||||
const handleClose = () => {
|
||||
form.value.checkComment = ''
|
||||
emit('beforeClose')
|
||||
}
|
||||
|
||||
// 审核
|
||||
const adopt = (type: number) => {
|
||||
ruleFormRef.value.validate((valid: any) => {
|
||||
if (valid) {
|
||||
const adminInfo = window.localStorage.getItem('adminInfo')
|
||||
const adminName = adminInfo ? JSON.parse(adminInfo).name : ''
|
||||
|
||||
checkPowerQuality({
|
||||
checkComment: form.value.checkComment,
|
||||
checkPerson: adminName,
|
||||
checkResult: type,
|
||||
powerQualityProblemNo: addData.value.powerQualityProblemNo,
|
||||
reportProcess: addData.value.reportProcess
|
||||
}).then((res: any) => {
|
||||
ElMessage.success(res.message)
|
||||
handleClose()
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
defineExpose({ open })
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
|
||||
@@ -15,9 +15,9 @@
|
||||
<el-select v-model="tableStore.table.params.reportProcess" clearable placeholder="请选择填报进度">
|
||||
<el-option
|
||||
v-for="item in fillingProgress"
|
||||
:key="item.id"
|
||||
:key="item.code"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
:value="item.code"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -25,9 +25,9 @@
|
||||
<el-select v-model="tableStore.table.params.reportProcessStatus" clearable placeholder="请选择审核状态">
|
||||
<el-option
|
||||
v-for="item in auditStatus"
|
||||
:key="item.id"
|
||||
:key="item.code"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
:value="item.code"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -49,11 +49,14 @@
|
||||
<NewlyAdd v-if="showNewlyAdded" @handleClose="handleClose" @onSubmit="beforeClose" />
|
||||
<!-- 填报 -->
|
||||
<el-dialog draggable title="填报" v-model="dialogVisible" width="1400px" :before-close="beforeClose">
|
||||
<Filling ref="FillingRef" v-if="dialogVisible"@beforeClose="beforeClose" />
|
||||
<Filling ref="FillingRef" v-if="dialogVisible" @beforeClose="beforeClose" />
|
||||
</el-dialog>
|
||||
|
||||
<!-- 详情 -->
|
||||
<Detail ref="detailRef" />
|
||||
|
||||
<!-- 审核记录 -->
|
||||
<recording ref="recordingRef" />
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { ref, onMounted, provide, nextTick } from 'vue'
|
||||
@@ -66,11 +69,13 @@ import { useDictData } from '@/stores/dictData'
|
||||
import NewlyAdd from './NewlyAdd.vue'
|
||||
import Filling from './filling.vue'
|
||||
import Detail from './detail.vue'
|
||||
import recording from './recording.vue'
|
||||
const dictData = useDictData()
|
||||
const FillingRef = ref()
|
||||
|
||||
const showNewlyAdded = ref(false)
|
||||
const dialogVisible = ref(false)
|
||||
const recordingRef = ref(false)
|
||||
const TableHeaderRef = ref()
|
||||
const detailRef = ref()
|
||||
const problemData = dictData.getBasicData('Problem_Sources')
|
||||
@@ -82,7 +87,7 @@ const tableStore: any = new TableStore({
|
||||
publicHeight: 65,
|
||||
method: 'POST',
|
||||
column: [
|
||||
{ width: '60', type: 'checkbox' },
|
||||
// { width: '60', type: 'checkbox' },
|
||||
{
|
||||
field: 'index',
|
||||
title: '序号',
|
||||
@@ -182,7 +187,9 @@ const tableStore: any = new TableStore({
|
||||
},
|
||||
icon: 'el-icon-PieChart',
|
||||
render: 'basicButton',
|
||||
click: async row => {}
|
||||
click: row => {
|
||||
recordingRef.value.open(row)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'del',
|
||||
|
||||
@@ -153,7 +153,6 @@ onMounted(() => {
|
||||
if (prop.List.filePathYyfx != null) {
|
||||
causeAnalysisData.value = prop.List
|
||||
}
|
||||
console.log(prop.disabled)
|
||||
})
|
||||
const submit = (num: number) => {
|
||||
console.log(prop.addData.problemSources)
|
||||
|
||||
@@ -1,16 +1,43 @@
|
||||
<template>
|
||||
<div>
|
||||
<vxe-table v-bind="defaultAttribute" height="350" ref="xTable1Ref" :data="list">
|
||||
<vxe-column field="sustationName" title="变电站"></vxe-column>
|
||||
<vxe-column field="barName" title="母线"></vxe-column>
|
||||
<vxe-column field="measurementPointName" title="监测点名称"></vxe-column>
|
||||
<el-dialog draggable v-model="dialogVisible" title="历史审核记录" width="1000px">
|
||||
<vxe-table v-bind="defaultAttribute" height="500" ref="xTable1Ref" :data="list">
|
||||
<vxe-column field="reportProcess" title="审核节点" :formatter="formatter"></vxe-column>
|
||||
<vxe-column field="type" title="审核结果" :formatter="formatter"></vxe-column>
|
||||
<vxe-column field="checker" title="审核人"></vxe-column>
|
||||
<vxe-column field="orgName" title="审核人单位"></vxe-column>
|
||||
<vxe-column field="dataDate" title="审核时间" min-width="100px"></vxe-column>
|
||||
<vxe-column field="description" title="审核意见" min-width="180px"></vxe-column>
|
||||
</vxe-table>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { ref, reactive } from 'vue'
|
||||
import { defaultAttribute } from '@/components/table/defaultAttribute'
|
||||
|
||||
import { queryCheckTrack } from '@/api/process-boot/electricitymanagement'
|
||||
import { useDictData } from '@/stores/dictData'
|
||||
const dictData = useDictData()
|
||||
const problemData = dictData.getBasicData('Fill_Progress')
|
||||
const auditStatus = dictData.getBasicData('Audit_Status')
|
||||
const list = ref([])
|
||||
const dialogVisible = ref(false)
|
||||
|
||||
const formatter = (row: any) => {
|
||||
if (row.column.field == 'reportProcess') {
|
||||
return problemData.filter((item: any) => item.code == row.cellValue)[0]?.name
|
||||
} else if (row.column.field == 'type') {
|
||||
return auditStatus.filter((item: any) => item.code == row.cellValue)[0]?.name
|
||||
} else {
|
||||
return row.cellValue
|
||||
}
|
||||
}
|
||||
|
||||
const open = (row: any) => {
|
||||
dialogVisible.value = true
|
||||
queryCheckTrack(row.powerQualityProblemNo).then((res: any) => {
|
||||
list.value = res.data
|
||||
})
|
||||
}
|
||||
|
||||
defineExpose({ open })
|
||||
</script>
|
||||
<style lang="scss" scoped></style>
|
||||
|
||||
Reference in New Issue
Block a user