From 9c81ab87188929f98abfd56eb3d0aa13e0077990 Mon Sep 17 00:00:00 2001
From: yangys <y_ys79@sina.com>
Date: 星期日, 14 九月 2025 19:42:01 +0800
Subject: [PATCH] 删除无用代码
---
src/views/wel/shemi.vue | 37 ++++++++++++++++++++++++-------------
1 files changed, 24 insertions(+), 13 deletions(-)
diff --git a/src/views/wel/shemi.vue b/src/views/wel/shemi.vue
index 195c1be..fdd59b0 100644
--- a/src/views/wel/shemi.vue
+++ b/src/views/wel/shemi.vue
@@ -1,7 +1,7 @@
<template>
<basic-container>
<div class="norightmenu" v-if="!isSearch">
- <avue-crud :addBtn="false" :option="option" :row-style="{height:'20px'}" :cell-style="{padding:'0px'}" :table-loading="loading" :data="treeData" ref="crud"
+ <avue-crud :addBtn="false" :option="option" :row-style="{height:'20px'}" :cell-style="{padding:'0px'}" :table-loading="loading" :data="treeData" ref="crud0"
v-model:search="search" v-model:page="mypage" @current-change="currentChange" @size-change="sizeChange"
@refresh-change="refreshChange" @on-load="onLoad" @tree-load="treeLoad" @row-click="rowClick">
<template #search>
@@ -14,20 +14,20 @@
<el-checkbox value="3" label="鍋忕" />
</el-checkbox-group>
</el-col>
- <el-col :span="6" class="search-data-flex">
+ <el-col :span="4" class="search-data-flex">
<span class="search-data-title">闆剁粍浠跺彿:</span>
<el-select v-model="searchTreeData.drawingNo" clearable filterable remote reserve-keyword placeholder="杈撳叆鑷冲皯3涓瓧绗﹁繃婊ゆ暟鎹�"
:remote-method="remoteMethod" :loading="searchLoading">
<el-option v-for="item in drawingNoList" :key="item.value" :label="item.label"
:value="item.value" /></el-select>
</el-col>
- <el-col :span="8" class="search-data-flex">
+ <el-col :span="6" class="search-data-flex">
<span class="search-data-title">鏃堕棿鑼冨洿:</span>
<el-date-picker v-model="searchTreeData.createTime" type="daterange" start-placeholder="寮�濮嬫椂闂�"
end-placeholder="缁撴潫鏃堕棿" :size="size" format="YYYY-MM-DD" value-format="YYYY-MM-DD"
@change="createTimeChange" /><!--:disabled-date="disabledDate" 涓嶉渶瑕佺鐢ㄦ棩鏈�-->
</el-col>
- <el-col :span="4" class="search-data-flex">
+ <el-col :span="6" class="search-data-flex">
<el-button type="primary" @click="searchTree" :loading="treeSearchLoad"><el-icon class="el-icon--right"
style="margin-right: 6px;">
<Search />
@@ -36,6 +36,7 @@
style="margin-right: 6px;">
<Delete />
</el-icon>娓呯┖</el-button>
+ <el-button type="danger" @click="refresh('crud0')">閲嶇疆琛ㄦ牸</el-button>
</el-col>
</el-row>
</template>
@@ -43,8 +44,7 @@
<template #name="{ row }">
<span>{{ row.name }}</span>
- <!-- 鏇挎崲 v-if="permission.auto_dispatch" icon="el-icon-unlock"-->
- <el-button class="treebtn" :size="size" text v-if="row.nodeType == 60 && row.parentIds.indexOf('0,1,') > -1"
+ <el-button class="treebtn" :size="size" text v-if="permission.replace_button && row.nodeType == 60 && row.parentIds.indexOf('0,1,') > -1"
icon="el-icon-switch" type="primary" @click="replacement(row)" placeholder="鏇挎崲" title="鏇挎崲"></el-button>
<!---->
<el-button icon="el-icon-unlock" class="treebtn" v-if="permission.lock_button && row.nodeType == 60 && row.parentIds.indexOf('0,2') > -1 && row.isLocked != 1"text type="primary" @click="showLockDlg(row)" placeholder="閿佸畾" title="閿佸畾"></el-button>
@@ -57,7 +57,7 @@
</avue-crud>
</div>
<div class="norightmenu" v-else>
- <avue-crud :addBtn="false" :option="option" :row-style="{height:'20px'}" :cell-style="{padding:'0px'}" :table-loading="loading" :data="treeData" ref="crud"
+ <avue-crud :addBtn="false" :option="option" :row-style="{height:'20px'}" :cell-style="{padding:'0px'}" :table-loading="loading" :data="treeData" ref="crud1"
v-model:search="search" v-model:page="mypage" @current-change="currentChange" @size-change="sizeChange"
@refresh-change="refreshChange" @on-load="onLoad" @tree-load="treeLoad" @row-click="rowClick">
<template #search>
@@ -77,13 +77,13 @@
<el-option v-for="item in drawingNoList" :key="item.value" :label="item.label"
:value="item.value" /></el-select>
</el-col>
- <el-col :span="8" class="search-data-flex">
+ <el-col :span="6" class="search-data-flex">
<span class="search-data-title">鏃堕棿鑼冨洿:</span>
<el-date-picker v-model="searchTreeData.createTime" type="daterange" start-placeholder="寮�濮嬫椂闂�"
end-placeholder="缁撴潫鏃堕棿" :size="size" format="YYYY-MM-DD" value-format="YYYY-MM-DD"
@change="createTimeChange" /><!--:disabled-date="disabledDate" 涓嶉渶瑕佺鐢ㄦ棩鏈�-->
</el-col>
- <el-col :span="6" class="search-data-flex">
+ <el-col :span="8" class="search-data-flex">
<el-button type="primary" @click="searchTree" :loading="treeSearchLoad"><el-icon class="el-icon--right"
style="margin-right: 6px;">
<Search />
@@ -92,6 +92,7 @@
style="margin-right: 6px;">
<Delete />
</el-icon>娓呯┖</el-button>
+ <el-button type="danger" @click="refresh('crud1')">閲嶇疆琛ㄦ牸</el-button>
</el-col>
</el-row>
</template>
@@ -102,7 +103,7 @@
<span>{{ row.name }}</span>
<!-- 鏇挎崲 v-if="permission.auto_dispatch"-->
- <el-button class="treebtn" :size="size" text v-if="row.nodeType == 60 && row.parentIds.indexOf('0,1,') > -1"
+ <el-button class="treebtn" :size="size" text v-if="permission.replace_button && row.nodeType == 60 && row.parentIds.indexOf('0,1,') > -1"
icon="el-icon-switch" type="primary" @click="replacement(row)" placeholder="鏇挎崲" title="鏇挎崲"></el-button>
<el-button class="treebtn" :size="size" text
v-if="permission.lock_button && row.nodeType == 60 && row.parentIds.indexOf('0,2') > -1 && row.isLocked != 1"
@@ -801,6 +802,15 @@
this.drawingNoList = drawingNoList;
});
},
+ refresh(refname){
+ this.treeData=[];
+ //this.$refs[refname].doLayout();
+ this.$refs[refname].refreshTable();
+ let curS = this.isSearch;
+ this.isSearch = null;
+ this.onLoad();
+ this.isSearch = !curS
+ },
showLockDlg(row){
//this.lockForm = row;
this.lockForm.id = row.id;
@@ -832,7 +842,7 @@
if (res.data.code == 200) {
this.$message({ type: 'success', message: '鎿嶄綔鎴愬姛!' });
this.addLocalTreeNode(this.lockForm.parentId);
- this.unlockBox = false;
+ this.lockBox = false;
} else {
this.$message({ type: 'error', message: res.data.msg });
}
@@ -860,6 +870,7 @@
if (res.data.code == 200) {
this.$message({ type: 'success', message: '瑙i攣娴佺▼宸插惎鍔�!' });
this.addLocalTreeNode(row.parentId);
+ this.unlockBox = false;
} else {
this.$message({ type: 'error', message: res.data.msg });
}
@@ -1166,7 +1177,7 @@
this.tabsOption = this.tabsOption1;
} else {
this.tabsOption = this.tabsOption2;
- //鑾峰彇鏂囦欢list
+ //鑾峰彇鏂囦欢鍐呭
this.getFile(row.id);
//鑾峰彇鍘嗗彶璁板綍
this.getHistory(row.id);
@@ -1201,7 +1212,7 @@
getFile(id) { //鏌ョ湅鏂囦欢鍐呭
this.loading = true;
axios({
- url: '/blade-mdm/program/ncfile/content-by-nodeid',
+ url: '/blade-mdm/program/node/content-by-nodeid',
method: 'get',
params: { nodeId: id },
}).then(
--
Gitblit v1.9.3