From b267ac7499877043675bbd25d1478b1731c12ec9 Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期五, 24 十一月 2023 15:14:03 +0800
Subject: [PATCH] 代码提交
---
Source/UBCS-WEB/src/api/logs.js | 22 ++
Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java | 2
Source/UBCS-WEB/src/views/monitor/log/localLog.vue | 405 +++++++++++++++++++++++++-------------------------
3 files changed, 225 insertions(+), 204 deletions(-)
diff --git a/Source/UBCS-WEB/src/api/logs.js b/Source/UBCS-WEB/src/api/logs.js
index 7538730..6655657 100644
--- a/Source/UBCS-WEB/src/api/logs.js
+++ b/Source/UBCS-WEB/src/api/logs.js
@@ -62,3 +62,25 @@
})
}
+export const getLazyList = (data) => {
+ return request({
+ url: '/api/ubcs-log/localLog/lazy-list',
+ method: 'post',
+ data: data,
+ })
+}
+export const downLoadLog = (data) => {
+ return request({
+ url: '/api/ubcs-log/localLog/downLoadLog',
+ method: 'post',
+ data:data,
+ })
+}
+export const deleteLocalLog = (data) => {
+ return request({
+ url: '/api/ubcs-log/localLog/deleteLogFile',
+ method: 'delete',
+ data: data
+ })
+}
+
diff --git a/Source/UBCS-WEB/src/views/monitor/log/localLog.vue b/Source/UBCS-WEB/src/views/monitor/log/localLog.vue
index 9f2a50b..90d9130 100644
--- a/Source/UBCS-WEB/src/views/monitor/log/localLog.vue
+++ b/Source/UBCS-WEB/src/views/monitor/log/localLog.vue
@@ -1,208 +1,207 @@
<template>
- <basic-container>
- <avue-crud ref="crud"
- v-model="form"
- :before-close="beforeClose"
- :before-open="beforeOpen"
- :data="data"
- :option="option"
- :permission="permissionList"
- :table-loading="loading"
- @row-del="rowDel"
- @search-change="searchChange"
- @search-reset="searchReset"
- @selection-change="selectionChange"
- @row-click="clickRowChange"
- @current-change="currentChange"
- @size-change="sizeChange"
- @refresh-change="refreshChange"
- @on-load="onLoad"
- @tree-load="treeLoad">
- <template slot="menu" slot-scope="scope">
- <el-button
- icon="el-icon-download el-icon--right"
- size="small"
- type="text"
- :loading="downloadLoading"
- @click="downLoadLogFile(scope.row)"
- v-if="permissionList.downLoadBtn"
- >涓嬭浇
- </el-button>
- </template>
- </avue-crud>
- </basic-container>
- </template>
-
- <script>
- import {getLazyList, deleteLocalLog,downLoadLog} from "@/api/logs";
- import func from "@/util/func";
- import {mapGetters} from "vuex";
-
- export default {
- data() {
- return {
- form: {},
- selectionList: [],
- query: {},
- logPath: "",
- loading: true,
- page: {
- pageSize: 10,
- currentPage: 1,
- total: 0
- },
- option: {
- height: "auto",
- lazy: true,
- columnBtn: false,
- tip: false,
- searchShow: true,
- searchMenuSpan: 6,
- tree: true,
- border: true,
- index: true,
- selection: true,
- editBtn: false,
- delBtn: true,
- addBtn: false,
- viewBtn: false,
- // menuWidth: 300,
- dialogClickModal: false,
- highlightCurrentRow: true, //琛岄�変腑鏃堕珮浜�
- rowKey: "logName", //琛屾暟鎹殑 Key锛岀敤鏉ヤ紭鍖� Table 鐨勬覆鏌�
- column: [
- {
- label: "鏈嶅姟鍚嶇О",
- prop: "serviceName",
- width:'120',
- search: true
- },
- {
- label: "鏈嶅姟ID",
- prop: "serviceId",
- search: true
- },
- {
- label: "鏃ュ織璺緞",
- prop: "logPath",
- width:'160'
- },
- {
- label: "鏃ュ織鍚嶇О",
- prop: "logName",
- width:'80',
- },
- {
- label: "鏃ュ織绫诲瀷",
- prop: "logType"
- },
- {
- label: "鍒涘缓鏃堕棿",
- prop: "createTime",
- width:'180'
- },
- {
- label: "鏈�鍚庝慨鏀规椂闂�",
- prop: "lastModifier",
- width:'180'
- }
- ]
- },
- data: [],
- downloadLoading: false,
- };
- },
- computed: {
- ...mapGetters(["permission"]),
- permissionList() {
- return {
- delBtn: this.vaildData(this.permission.localLog.localLog_delete, false),
- downLoadBtn: this.vaildData(this.permission.localLog.localLog_dwonload, false)
- };
- }
- },
- methods: {
+ <basic-container>
+ <avue-crud ref="crud"
+ v-model="form"
+ :before-close="beforeClose"
+ :before-open="beforeOpen"
+ :data="data"
+ :option="option"
+ :permission="permissionList"
+ :table-loading="loading"
+ @row-del="rowDel"
+ @search-change="searchChange"
+ @search-reset="searchReset"
+ @selection-change="selectionChange"
+ @row-click="clickRowChange"
+ @current-change="currentChange"
+ @size-change="sizeChange"
+ @refresh-change="refreshChange"
+ @on-load="onLoad"
+ @tree-load="treeLoad">
+ <template slot="menu" slot-scope="scope">
+ <el-button
+ icon="el-icon-download el-icon--right"
+ size="small"
+ type="text"
+ :loading="downloadLoading"
+ @click="downLoadLogFile(scope.row)"
+ v-if="permissionList.downLoadBtn"
+ >涓嬭浇
+ </el-button>
+ </template>
+ </avue-crud>
+ </basic-container>
+</template>
- downLoadLogFile(row){
- this.downloadLoading = true;
- let logPath = row.hasChildren ? row.logPath:row.logPath+"\\"+row.logName;
- downLoadLog(Object.assign({},row,{logFullPaths:logPath})).then(res=>{
- func.downloadFileByBlobHandler(res);
- this.downloadLoading = false;
- }).catch((res)=>{
- //this.$message.warning(res)
- this.downloadLoading = false;
- })
+<script>
+ import {getLazyList, deleteLocalLog,downLoadLog} from "@/api/logs";
+ import func from "@/util/func";
+ import {mapGetters} from "vuex";
+
+ export default {
+ data() {
+ return {
+ form: {},
+ selectionList: [],
+ query: {},
+ logPath: "",
+ loading: true,
+ page: {
+ pageSize: 10,
+ currentPage: 1,
+ total: 0
},
- // 琛屽垹闄�
- rowDel(row, index, done) {
- this.$confirm("纭畾灏嗛�夋嫨鐨勬棩蹇楁枃浠跺垹闄�?", {
- confirmButtonText: "纭畾",
- cancelButtonText: "鍙栨秷",
- type: "warning"
- })
- .then(() => {
- let logPath = row.hasChildren ? row.logPath:row.logPath+"\\"+row.logName;
- return deleteLocalLog(Object.assign({},row,{logFullPaths:logPath}));
- })
- .then(() => {
- this.$message({
- type: "success",
- message: "鎿嶄綔鎴愬姛!"
- });
- // 鏁版嵁鍥炶皟杩涜鍒锋柊
- done(row);
- //this.onLoad();
- });
+ option: {
+ height: "auto",
+ lazy: true,
+ columnBtn: false,
+ tip: false,
+ searchShow: true,
+ searchMenuSpan: 6,
+ tree: true,
+ border: true,
+ index: true,
+ selection: true,
+ editBtn: false,
+ delBtn: true,
+ addBtn: false,
+ viewBtn: false,
+ // menuWidth: 300,
+ dialogClickModal: false,
+ highlightCurrentRow: true, //琛岄�変腑鏃堕珮浜�
+ rowKey: "logName", //琛屾暟鎹殑 Key锛岀敤鏉ヤ紭鍖� Table 鐨勬覆鏌�
+ column: [
+ {
+ label: "鏈嶅姟鍚嶇О",
+ prop: "serviceName",
+ width:'120',
+ search: true
+ },
+ {
+ label: "鏈嶅姟ID",
+ prop: "serviceId",
+ search: true
+ },
+ {
+ label: "鏃ュ織璺緞",
+ prop: "logPath",
+ width:'160'
+ },
+ {
+ label: "鏃ュ織鍚嶇О",
+ prop: "logName",
+ width:'80',
+ },
+ {
+ label: "鏃ュ織绫诲瀷",
+ prop: "logType"
+ },
+ {
+ label: "鍒涘缓鏃堕棿",
+ prop: "createTime",
+ width:'180'
+ },
+ {
+ label: "鏈�鍚庝慨鏀规椂闂�",
+ prop: "lastModifier",
+ width:'180'
+ }
+ ]
},
- searchReset() {
- this.query = {};
- this.parentId = 0;
- this.onLoad(this.page);
- },
- searchChange(params, done) {
- this.query = params;
- this.parentId = '';
- this.page.currentPage = 1;
- this.onLoad(this.page, params);
- done();
- },
- clickRowChange(row) {
- this.$refs.crud.toggleSelection();
- this.selectionList = row;
- this.$refs.crud.setCurrentRow(row);
- this.$refs.crud.toggleRowSelection(row); //閫変腑褰撳墠琛�
- },
- selectionChange(list) {
- this.selectionList = list;
- this.$refs.crud.setCurrentRow(this.selectionList[list.length - 1]);
- },
- selectionClear() {
- this.selectionList = [];
- this.$refs.crud.toggleSelection();
- },
- refreshChange() {
- this.onLoad(this.page, this.query);
- },
- onLoad(page, params = {}) {
- this.loading = true;
- //Object.assign(params, this.query)
- getLazyList({"logPath": this.logPath}).then(res => {
- this.data = res.data.data;
- this.loading = false;
- this.selectionClear();
- });
- },
- treeLoad(tree, treeNode, resolve) {
- const logPath = tree.logPath;
- getLazyList({"logPath": logPath}).then(res => {
- resolve(res.data.data);
- });
- }
+ data: [],
+ downloadLoading: false,
+ };
+ },
+ computed: {
+ ...mapGetters(["permission"]),
+ permissionList() {
+ return {
+ delBtn: this.vaildData(this.permission.localLog.localLog_delete, false),
+ downLoadBtn: this.vaildData(this.permission.localLog.localLog_dwonload, false)
+ };
}
- };
- </script>
-
- <style>
- </style>
-
\ No newline at end of file
+ },
+ methods: {
+
+ downLoadLogFile(row){
+ this.downloadLoading = true;
+ let logPath = row.hasChildren ? row.logPath:row.logPath+"\\"+row.logName;
+ downLoadLog(Object.assign({},row,{logFullPaths:logPath})).then(res=>{
+ func.downloadFileByBlobHandler(res);
+ this.downloadLoading = false;
+ }).catch((res)=>{
+ //this.$message.warning(res)
+ this.downloadLoading = false;
+ })
+ },
+ // 琛屽垹闄�
+ rowDel(row, index, done) {
+ this.$confirm("纭畾灏嗛�夋嫨鐨勬棩蹇楁枃浠跺垹闄�?", {
+ confirmButtonText: "纭畾",
+ cancelButtonText: "鍙栨秷",
+ type: "warning"
+ })
+ .then(() => {
+ let logPath = row.hasChildren ? row.logPath:row.logPath+"\\"+row.logName;
+ return deleteLocalLog(Object.assign({},row,{logFullPaths:logPath}));
+ })
+ .then(() => {
+ this.$message({
+ type: "success",
+ message: "鎿嶄綔鎴愬姛!"
+ });
+ // 鏁版嵁鍥炶皟杩涜鍒锋柊
+ done(row);
+ //this.onLoad();
+ });
+ },
+ searchReset() {
+ this.query = {};
+ this.parentId = 0;
+ this.onLoad(this.page);
+ },
+ searchChange(params, done) {
+ this.query = params;
+ this.parentId = '';
+ this.page.currentPage = 1;
+ this.onLoad(this.page, params);
+ done();
+ },
+ clickRowChange(row) {
+ this.$refs.crud.toggleSelection();
+ this.selectionList = row;
+ this.$refs.crud.setCurrentRow(row);
+ this.$refs.crud.toggleRowSelection(row); //閫変腑褰撳墠琛�
+ },
+ selectionChange(list) {
+ this.selectionList = list;
+ this.$refs.crud.setCurrentRow(this.selectionList[list.length - 1]);
+ },
+ selectionClear() {
+ this.selectionList = [];
+ this.$refs.crud.toggleSelection();
+ },
+ refreshChange() {
+ this.onLoad(this.page, this.query);
+ },
+ onLoad(page, params = {}) {
+ this.loading = true;
+ //Object.assign(params, this.query)
+ getLazyList({"logPath": this.logPath}).then(res => {
+ this.data = res.data.data;
+ this.loading = false;
+ this.selectionClear();
+ });
+ },
+ treeLoad(tree, treeNode, resolve) {
+ const logPath = tree.logPath;
+ getLazyList({"logPath": logPath}).then(res => {
+ resolve(res.data.data);
+ });
+ }
+ }
+ };
+</script>
+
+<style>
+</style>
diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java
index 52470cd..c168c16 100644
--- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java
+++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java
@@ -885,7 +885,7 @@
String idFieldName = attrVOS.stream().filter(s -> VciQueryWrapperForDO.ID_FIELD.equalsIgnoreCase(s.getId())).findFirst().orElseGet(() -> new CodeClassifyTemplateAttrVO()).getName();
getFieldIndexMap(titleRowData, attrNameIdMap, fieldIndexMap);
//鍏堜笉鐢ㄧ灞炴�ф槸鍚﹂兘瀛樺湪锛屽厛杞崲涓�涓嬫暟鎹�
- List<ClientBusinessObject> cboList = new CopyOnWriteArrayList<>();
+ List<ClientBusinessObject> cboList = new ArrayList<>();
String fullPath = getFullPath(classifyFullInfo);
//鎴戜滑闇�瑕佽幏鍙栧埌鎵�鏈夌殑涓嬬骇鍒嗙被鐨刼id鐨勮矾寰勶紝鍥犱负鍚庨潰闇�瑕�
Map<String/**涓婚敭**/, String/**璺緞**/> childOidPathMap = getChildClassifyPathMap(classifyFullInfo, fullPath);
--
Gitblit v1.9.3