From 76ab72d2d4f443060448e20bb74230a8040b85f5 Mon Sep 17 00:00:00 2001
From: fuliqi <fuliqi@qq.com>
Date: 星期二, 05 十一月 2024 11:00:33 +0800
Subject: [PATCH] 文件上传大小、工单审核后刷新
---
src/views/system/point/index.vue | 28 ++++++++++++++++++++++++++--
1 files changed, 26 insertions(+), 2 deletions(-)
diff --git a/src/views/system/point/index.vue b/src/views/system/point/index.vue
index 5f162cf..fe4a301 100644
--- a/src/views/system/point/index.vue
+++ b/src/views/system/point/index.vue
@@ -91,10 +91,10 @@
<!-- <el-button type="danger" plain icon="el-icon-receiving" size="mini" @click="handleEditBatch"-->
<!-- v-hasPermi="['point:edit']">鎵归噺淇敼</el-button>-->
<!-- </el-col>-->
- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+ <right-toolbar @refreshHeader= "getDyColumn" :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
- <el-table v-loading="loading" :data="pointList" @selection-change="handleSelectionChange">
+ <el-table :key = "refreshkey" v-loading="loading" :data="pointList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="鐐逛綅鍚嶇О" prop="pointName" width="200" show-overflow-tooltip/>
<el-table-column label="鏍囩" align="center" width="200" show-overflow-tooltip>
@@ -110,6 +110,11 @@
<el-table-column label="杩愮淮鍗曚綅" align="center" prop="unitName" />
<el-table-column label="鐩戠閮ㄩ棬" align="center" prop="deptName" />
<el-table-column label="澶囨敞" align="center" prop="remark" />
+ <el-table-column v-for="(column, index) in dynamicColumnList" :key="index" :label="column.labelValue" :prop="column.propName" align="center">
+ <template slot-scope="scope">
+ {{ getDynamicValue(scope.row, column.propName) }}
+ </template>
+ </el-table-column>
<el-table-column label="鎿嶄綔" align="center" fixed="right" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
@@ -235,6 +240,7 @@
</template>
<script>
+import { addDynamicColumn, deleteDynamicColumnById, editDynamicColumn, getDynamicColumnList } from '@/api/platform/dynamicColumn'
import { listPoint, getPoint, delPoint, addPoint, batchEdit, updatePoint, exportData, importData, timeRange } from "@/api/platform/point";
import { unitSelect } from "@/api/platform/unit";
import { getCascader } from '@/api/platform/region'
@@ -245,6 +251,8 @@
dicts: ['point_tag', 'area_code'],
data() {
return {
+ refreshkey : 0,
+ dynamicColumnList: [],
needUpdateUnit: false,
importantTag: false,
provinceTag: false,
@@ -328,8 +336,24 @@
this.getUnitSelect();
// this.getCascader();
this.getDeptCascader();
+ this.getDyColumn();
},
methods: {
+ getDyColumn() {
+ // 鏌ヨ鍔ㄦ�佸垪
+ let params = {
+ tableName: 't_yw_point'
+ }
+ getDynamicColumnList(params).then(res => {
+ this.dynamicColumnList = res.data
+ this.refreshkey+=1
+ console.log("鍔犺浇鍔ㄦ�佸垪"+this.refreshkey)
+ })
+ },
+ getDynamicValue(row, propName) {
+ let target = row.dynamicColumnList.filter(item => item.propName === propName)
+ return target && target.length > 0 ? target[0].columnValue : ''
+ },
getTagText(row) {
let text = '';
--
Gitblit v1.8.0