已修改3个文件
已删除1个文件
已重命名2个文件
已添加2个文件
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <!--æä»¶æç®¡ç--> |
| | | <basic-container> |
| | | <avue-crud |
| | | ref="fileCrud" |
| | | :data="tableData" |
| | | :option="option" |
| | | :page.sync="page" |
| | | :table-loading="tableLoading" |
| | | @on-load="getTableList" |
| | | @refresh-change="handleRefresh" |
| | | @search-change="handleSearch" |
| | | @search-reset="handleReset" |
| | | @size-change="sizeChange" |
| | | @current-change="currentChange" |
| | | > |
| | | <template slot="menuLeft" slot-scope="scope"> |
| | | <el-button icon="el-icon-download" plain size="small" type="primary" @click="allDelHandler">导åº</el-button> |
| | | </template> |
| | | </avue-crud> |
| | | </basic-container> |
| | | </template> |
| | | |
| | | <script> |
| | | import basicOption from "@/util/basic-option"; |
| | | import {getLogListByContion} from "@/api/system/log/logBasic"; |
| | | |
| | | export default { |
| | | name: "index", |
| | | data: function () { |
| | | return { |
| | | tableLoading: false, |
| | | tableData: [], |
| | | option: { |
| | | ...basicOption, |
| | | addBtn:false, |
| | | editBtn: false, |
| | | delBtn: false, |
| | | calcHeight: -60, |
| | | align:'left', |
| | | headerAlign:'center', |
| | | menu:false, |
| | | searchMenuSpan: 6, |
| | | searchIcon:false, |
| | | column: [ |
| | | { |
| | | label: 'ç¨æ·å', |
| | | prop: 'truename', |
| | | search:true, |
| | | searchSpan: 4, |
| | | searchLabel:'æä½ç¨æ·', |
| | | type:'select', |
| | | dicUrl:'/api/loginBasicController/getOperatingUsers', |
| | | sortable:true, |
| | | width: 150 |
| | | }, { |
| | | label: 'å§å', |
| | | prop: 'username', |
| | | sortable:true, |
| | | width: 150 |
| | | },{ |
| | | label: 'ç¨æ·IP', |
| | | prop: 'userIp', |
| | | search:true, |
| | | searchSpan: 4, |
| | | sortable:true, |
| | | width: 150 |
| | | },{ |
| | | label: '模å', |
| | | prop: 'moduleName', |
| | | sortable:true, |
| | | overHidden: true, |
| | | },{ |
| | | label: 'æä½', |
| | | prop: 'type', |
| | | sortable:true, |
| | | width: 150 |
| | | },{ |
| | | label: 'æ¶é´', |
| | | prop: 'date', |
| | | type:'date', |
| | | search:true, |
| | | searchOrder: 1, |
| | | searchSpan: 8, |
| | | searchRange: true, |
| | | searchLabel:'æ¥è¯¢æ¥æ', |
| | | valueFormat:'yyyy-MM-dd', |
| | | width: 160 |
| | | },{ |
| | | label: 'æè¿°', |
| | | prop: 'result', |
| | | overHidden: true, |
| | | width:380, |
| | | }, |
| | | ] |
| | | }, |
| | | page: { |
| | | currentPage: 1, |
| | | pageSize: 50, |
| | | total: 0, |
| | | pageSizes: [10, 30, 50, 100], |
| | | }, |
| | | searchParams: {} |
| | | } |
| | | }, |
| | | methods: { |
| | | // è¡¨æ ¼è¯·æ± |
| | | getTableList() { |
| | | this.tableLoading = true; |
| | | getLogListByContion(this.page.currentPage, this.page.pageSize, {'logType':this.$route.query.logType,...this.searchParams}).then(res => { |
| | | this.tableData = res.data.data; |
| | | this.page.total = res.data.total; |
| | | this.tableLoading = false; |
| | | }) |
| | | }, |
| | | |
| | | // æç´¢æ¥è¯¢ |
| | | handleSearch(params, done) { |
| | | this.searchParams = { |
| | | userName:params.truename, |
| | | ipText:params.userIp, |
| | | startDate:params.date[0], |
| | | endDate:params.date[1] |
| | | }; |
| | | |
| | | this.getTableList(); |
| | | done(); |
| | | }, |
| | | |
| | | // éç½®æç´¢æ¡ä»¶ |
| | | handleReset() { |
| | | this.searchParams = {}; |
| | | this.getTableList(); |
| | | }, |
| | | |
| | | // æ¡æ° |
| | | sizeChange(val) { |
| | | this.page.pageSize = val; |
| | | }, |
| | | |
| | | // 页ç |
| | | currentChange(val) { |
| | | this.page.currentPage = val; |
| | | }, |
| | | |
| | | handleRefresh(){ |
| | | this.getTableList(); |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | |
| | | </style> |
ÎļþÃû´Ó Source/plt-web/plt-web-ui/src/api/log/logBasic.js ÐÞ¸Ä |
| | |
| | | }) |
| | | } |
| | | |
| | | //è·åæä½ç¨æ· |
| | | export function getOperatingUsers( params) { |
| | | return request({ |
| | | url: "/api/loginBasicController/getOperatingUsers", |
| | | method: "get", |
| | | params |
| | | }); |
| | | } |
| | | |
| | | export function getLogListByContion(page, limit, params) { |
| | | return request({ |
| | | url: "/api/loginBasicController/getLogListByContion", |
| | |
| | | } |
| | | }); |
| | | } |
| | | |
| | | // å¯¼åº |
| | | export const exportLog = (params) => { |
| | | return request({ |
| | | url: '/api/loginBasicController/exportLog', |
| | | method: 'get', |
| | | headers: {'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8'}, |
| | | responseType: 'blob', |
| | | params |
| | | }) |
| | | } |
ÎļþÃû´Ó Source/plt-web/plt-web-ui/src/views/log/basicConf.vue ÐÞ¸Ä |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import {getPeroid,savePeriod,deleteLog} from "@/api/log/logBasic"; |
| | | import {getPeroid,savePeriod,deleteLog} from "@/api/system/log/logBasic"; |
| | | export default { |
| | | name: "basicConf", |
| | | data: function () { |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <basic-container> |
| | | <avue-crud |
| | | ref="logCrud" |
| | | :data="tableData" |
| | | :option="option" |
| | | :page.sync="page" |
| | | :table-loading="tableLoading" |
| | | @on-load="getTableList" |
| | | @refresh-change="handleRefresh" |
| | | @search-change="handleSearch" |
| | | @search-reset="handleReset" |
| | | @size-change="sizeChange" |
| | | @current-change="currentChange" |
| | | > |
| | | <template slot="menuLeft" slot-scope="scope"> |
| | | <el-button icon="el-icon-download" plain size="small" type="primary" @click="exportClickHandler">导åº</el-button> |
| | | </template> |
| | | </avue-crud> |
| | | </basic-container> |
| | | </template> |
| | | |
| | | <script> |
| | | import basicOption from "@/util/basic-option"; |
| | | import {getLogListByContion,getOperatingUsers,exportLog} from "@/api/system/log/logBasic"; |
| | | import func from "@/util/func"; |
| | | |
| | | export default { |
| | | name: "index", |
| | | data: function () { |
| | | return { |
| | | tableLoading: false, |
| | | tableData: [], |
| | | option: { |
| | | ...basicOption, |
| | | addBtn:false, |
| | | editBtn: false, |
| | | delBtn: false, |
| | | calcHeight: -60, |
| | | align:'left', |
| | | headerAlign:'center', |
| | | menu:false, |
| | | searchMenuSpan: 6, |
| | | searchIcon:false, |
| | | column: [ |
| | | { |
| | | label: 'ç¨æ·å', |
| | | prop: 'truename', |
| | | search:true, |
| | | searchSpan: 4, |
| | | searchLabel:'æä½ç¨æ·', |
| | | type:'select', |
| | | dicUrl:'/api/loginBasicController/getOperatingUsers', |
| | | sortable:true, |
| | | width: 150 |
| | | }, { |
| | | label: 'å§å', |
| | | prop: 'username', |
| | | sortable:true, |
| | | width: 150 |
| | | },{ |
| | | label: 'ç¨æ·IP', |
| | | prop: 'userIp', |
| | | search:true, |
| | | searchSpan: 4, |
| | | sortable:true, |
| | | width: 150 |
| | | },{ |
| | | label: '模å', |
| | | prop: 'moduleName', |
| | | sortable:true, |
| | | overHidden: true, |
| | | },{ |
| | | label: 'æä½', |
| | | prop: 'type', |
| | | sortable:true, |
| | | width: 150 |
| | | },{ |
| | | label: 'æ¶é´', |
| | | prop: 'date', |
| | | type:'date', |
| | | search:true, |
| | | searchOrder: 1, |
| | | searchSpan: 8, |
| | | searchRange: true, |
| | | searchLabel:'æ¥è¯¢æ¥æ', |
| | | valueFormat:'yyyy-MM-dd', |
| | | width: 160 |
| | | },{ |
| | | label: 'æè¿°', |
| | | prop: 'result', |
| | | overHidden: true, |
| | | width:380, |
| | | }, |
| | | ] |
| | | }, |
| | | page: { |
| | | currentPage: 1, |
| | | pageSize: 50, |
| | | total: 0, |
| | | pageSizes: [10, 30, 50, 100], |
| | | }, |
| | | searchParams: {} |
| | | } |
| | | }, |
| | | watch: { |
| | | $route(to, from) { |
| | | this.getTableList(); |
| | | } |
| | | }, |
| | | methods: { |
| | | // è¡¨æ ¼è¯·æ± |
| | | getTableList() { |
| | | this.tableLoading = true; |
| | | getLogListByContion(this.page.currentPage, this.page.pageSize, {'logType':this.$route.query.logType,...this.searchParams}).then(res => { |
| | | this.tableData = res.data.data; |
| | | this.page.total = res.data.total; |
| | | this.tableLoading = false; |
| | | }) |
| | | }, |
| | | |
| | | // æç´¢æ¥è¯¢ |
| | | handleSearch(params, done) { |
| | | this.searchParams = { |
| | | userName:params.truename, |
| | | ipText:params.userIp, |
| | | startDate:params.date[0], |
| | | endDate:params.date[1] |
| | | }; |
| | | |
| | | this.getTableList(); |
| | | done(); |
| | | }, |
| | | |
| | | // éç½®æç´¢æ¡ä»¶ |
| | | handleReset() { |
| | | this.searchParams = {}; |
| | | this.getTableList(); |
| | | }, |
| | | |
| | | // æ¡æ° |
| | | sizeChange(val) { |
| | | this.page.pageSize = val; |
| | | }, |
| | | |
| | | // 页ç |
| | | currentChange(val) { |
| | | this.page.currentPage = val; |
| | | }, |
| | | |
| | | handleRefresh(){ |
| | | this.getTableList(); |
| | | }, |
| | | // å¯¼åº |
| | | exportClickHandler() { |
| | | const loading = this.$loading({}); |
| | | exportLog().then(res => { |
| | | func.downloadFileByBlobHandler(res); |
| | | this.createdLoading = false |
| | | this.$message.success('å¯¼åºæå'); |
| | | loading.close(); |
| | | }) |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | |
| | | </style> |
| | |
| | | <el-container v-loading="createdLoading"> |
| | | <el-aside> |
| | | <basic-container> |
| | | <div style="max-height: calc(100vh - 170px);overflow: auto"> |
| | | <avue-tree :key="refresh" ref="tree" :data="treeData" :option="treeOption" @node-click="nodeClick"> |
| | | <div style="max-height: calc(100vh - 150px);overflow: auto"> |
| | | <avue-tree :key="refresh" node-key="id" ref="tree" :data="treeData" :option="treeOption" @node-click="nodeClick"> |
| | | <span slot-scope="{ node, data }" class="el-tree-node__label"> |
| | | <span style="font-size: 15px"> |
| | | <i class="el-icon-s-promotion"></i> |
| | |
| | | |
| | | <el-main> |
| | | <basic-container> |
| | | <el-form ref="form" :model="form" label-width="85px" style="height: 79vh"> |
| | | <el-form ref="form" :model="form" label-width="85px" style="max-height: calc(100vh - 180px);overflow: auto;"> |
| | | <span v-if="form.childType !== 0"> |
| | | <el-form-item label="模ååï¼"> |
| | | <el-input v-model="form.name" placeholder="请è¾å
¥æ¨¡åå"></el-input> |
| | |
| | | addStatus: false, |
| | | editStatus: false, |
| | | nodeRow: {}, |
| | | currentClickNode:null, |
| | | form: {}, |
| | | treeData: [], |
| | | treeOption: { |
| | |
| | | }, |
| | | methods: { |
| | | // æ è¡ç¹å» |
| | | nodeClick(row) { |
| | | nodeClick(row,node) { |
| | | this.form = {...row}; |
| | | this.nodeRow = {...row}; |
| | | this.currentClickNode=node; |
| | | this.addStatus = false; |
| | | this.editStatus = false; |
| | | }, |
| | |
| | | this.addStatus = false; |
| | | // this.resetFormValue(); |
| | | this.form.childType = null; |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | this.handleRefreshTree('add') |
| | | } |
| | | }) |
| | | }, |
| | |
| | | this.editStatus = false; |
| | | // this.resetFormValue(); |
| | | this.form.childType = null; |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | this.handleRefreshTree('edit') |
| | | } |
| | | }) |
| | | }, |
| | |
| | | delModule(this.form).then(res => { |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.msg); |
| | | this.resetFormValue(); |
| | | this.handleRefreshTree('del') |
| | | this.addStatus = false; |
| | | this.editStatus = false; |
| | | } |
| | |
| | | exportFunctionSql({isFunction: true}).then(res => { |
| | | func.downloadFileByBlobHandler(res); |
| | | this.$message.success('å¯¼åºæå'); |
| | | }).catch(err => { |
| | | this.$message.error(err); |
| | | }); |
| | | }, |
| | | |
| | |
| | | } |
| | | }) |
| | | addOperationType(list).then(res => { |
| | | console.log(res) |
| | | if (res.data.code === 200) { |
| | | this.methodsVisble = false; |
| | | this.$message.success(res.data.msg); |
| | | this.form.childType = null; |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | this.handleRefreshTree('add') // å·æ°å·¦ä¾§æ |
| | | } |
| | | }) |
| | | }, |
| | |
| | | updateAlias(params).then(res => { |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.msg); |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | this.handleRefreshTree('edit') |
| | | } |
| | | }) |
| | | }, |
| | |
| | | console.log(res); |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.msg); |
| | | this.resetFormValue(); |
| | | this.handleRefreshTree('del'); |
| | | } |
| | | }) |
| | | }).catch(() => { |
| | |
| | | // 导å
¥ |
| | | upLoadClickHandler() { |
| | | this.$refs.upload.visible = true; |
| | | }, |
| | | handleRefreshTree(type) { |
| | | //type:add\edit\del |
| | | if(type=="del"){ |
| | | this.$refs.tree.remove(this.currentClickNode); |
| | | this.currentClickNode=null; |
| | | this.form={}; |
| | | }else{ |
| | | if (this.currentClickNode) { |
| | | let node = this.currentClickNode.parent; |
| | | node.loaded = false; |
| | | node.expand(); |
| | | this.$refs.tree.setCurrentNode(this.currentClickNode); |
| | | }else { |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | <el-container v-loading="createdLoading"> |
| | | <el-aside> |
| | | <basic-container> |
| | | <div style="max-height: calc(100vh - 170px);overflow: auto"> |
| | | <avue-tree :key="refresh" ref="tree" :data="treeData" :option="treeOption" @node-click="nodeClick"> |
| | | <div style="max-height: calc(100vh - 150px);overflow: auto"> |
| | | <avue-tree :key="refresh" node-key="id" ref="tree" :data="treeData" :option="treeOption" @node-click="nodeClick"> |
| | | <span slot-scope="{ node, data }" class="el-tree-node__label"> |
| | | <span style="font-size: 15px"> |
| | | <i class="el-icon-s-promotion"></i> |
| | |
| | | |
| | | <el-main> |
| | | <basic-container> |
| | | <el-form ref="form" :model="form" label-width="85px" style="height: 79vh"> |
| | | <el-form ref="form" :model="form" label-width="85px" style="max-height: calc(100vh - 180px);overflow: auto;"> |
| | | <span v-if="form.childType !== 0"> |
| | | <el-form-item label="模ååï¼"> |
| | | <el-input v-model="form.name" placeholder="请è¾å
¥æ¨¡åå"></el-input> |
| | |
| | | addStatus: false, |
| | | editStatus: false, |
| | | nodeRow: {}, |
| | | currentClickNode:null, |
| | | form: {}, |
| | | treeData: [], |
| | | treeOption: { |
| | |
| | | }, |
| | | methods: { |
| | | // æ è¡ç¹å» |
| | | nodeClick(row) { |
| | | nodeClick(row,node) { |
| | | console.log(row.childType); |
| | | this.form = {...row}; |
| | | this.nodeRow = {...row}; |
| | | this.currentClickNode = node; |
| | | this.addStatus = false; |
| | | this.editStatus = false; |
| | | }, |
| | |
| | | this.addStatus = false; |
| | | // this.resetFormValue(); |
| | | this.form.childType = null; |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | this.handleRefreshTree('add') |
| | | } |
| | | }) |
| | | }, |
| | |
| | | this.editStatus = false; |
| | | // this.resetFormValue(); |
| | | this.form.childType = null; |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | this.handleRefreshTree('edit') |
| | | } |
| | | }) |
| | | }, |
| | |
| | | delModule(this.form).then(res => { |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.msg); |
| | | this.resetFormValue(); |
| | | this.handleRefreshTree('del') |
| | | this.addStatus = false; |
| | | this.editStatus = false; |
| | | } |
| | |
| | | updateAlias(params).then(res => { |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.msg); |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | this.handleRefreshTree('edit') |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | // å 餿¨¡åä¸å
³èçæä½ç±»å |
| | | deleteOperationClickHandler() { |
| | | console.log(this.form); |
| | | const params = { |
| | | funcId: this.form.funcId, |
| | | operId: this.form.operId |
| | | } |
| | | delFuncOperation(params).then(res => { |
| | | console.log(res); |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.msg); |
| | | this.resetFormValue(); |
| | | this.handleRefreshTree('del'); |
| | | } |
| | | }) |
| | | }, |
| | |
| | | func.downloadFileByBlobHandler(res); |
| | | this.createdLoading = false |
| | | this.$message.success('å¯¼åºæå'); |
| | | }).catch(err => { |
| | | this.$message.error(err); |
| | | }) |
| | | }, |
| | | |
| | | // 导å
¥ |
| | | upLoadClickHandler() { |
| | | this.$refs.upload.visible = true; |
| | | }, |
| | | handleRefreshTree(type) { |
| | | //type:add\edit\del |
| | | if(type=="del"){ |
| | | this.$refs.tree.remove(this.currentClickNode); |
| | | this.currentClickNode=null; |
| | | this.form={}; |
| | | }else{ |
| | | if (this.currentClickNode) { |
| | | let node = this.currentClickNode.parent; |
| | | node.loaded = false; |
| | | node.expand(); |
| | | this.$refs.tree.setCurrentNode(this.currentClickNode); |
| | | }else { |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | <el-container> |
| | | <el-aside> |
| | | <basic-container> |
| | | <div style="max-height: calc(100vh - 170px);overflow: auto"> |
| | | <avue-tree :key="refresh" ref="tree" :data="treeData" :option="treeOption" @node-click="nodeClick"> |
| | | <div style="max-height: calc(100vh - 150px);overflow: auto"> |
| | | <avue-tree :key="refresh" node-key="id" ref="tree" :data="treeData" :option="treeOption" @node-click="nodeClick"> |
| | | <span slot-scope="{ node, data }" class="el-tree-node__label"> |
| | | <span style="font-size: 15px"> |
| | | <i class="el-icon-s-promotion"></i> |
| | |
| | | |
| | | <el-main> |
| | | <basic-container> |
| | | <el-form ref="form" :model="form" label-width="85px" style="height: 79vh"> |
| | | <el-form ref="form" :model="form" label-width="85px" style="max-height: calc(100vh - 180px);overflow: auto;"> |
| | | <el-form-item label="åç§°ï¼"> |
| | | <el-input v-model="form.name" placeholder="请è¾å
¥åç§°"></el-input> |
| | | </el-form-item> |
| | |
| | | editStatus:false, |
| | | addStatus: false, |
| | | nodeRow: {}, |
| | | currentClickNode:null, |
| | | form: {}, |
| | | treeData: [], |
| | | treeOption: { |
| | |
| | | }, |
| | | methods: { |
| | | // æ è¡ç¹å» |
| | | nodeClick(row) { |
| | | nodeClick(row,node) { |
| | | console.log(row); |
| | | this.form = {...row}; |
| | | this.nodeRow = {...row}; |
| | | this.currentClickNode=node; |
| | | this.addStatus = false; |
| | | this.editStatus = false; |
| | | }, |
| | |
| | | addOperationType(params).then(res => { |
| | | if(res.data.code === 200){ |
| | | this.$message.success(res.data.msg); |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | this.handleRefreshTree('add') |
| | | this.addStatus = false; |
| | | } |
| | | }) |
| | |
| | | updateOperationType(params).then(res => { |
| | | if(res.data.code === 200){ |
| | | this.$message.success(res.data.msg); |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | this.handleRefreshTree('edit') |
| | | this.editStatus = false; |
| | | } |
| | | }) |
| | |
| | | delOperationType(this.form).then(res => { |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.msg); |
| | | this.resetFormValue(); |
| | | this.handleRefreshTree('del') |
| | | this.addStatus = false; |
| | | this.editStatus = false; |
| | | this.nodeRow = {}; |
| | |
| | | exportFunctionSql({isFunction: false}).then(res => { |
| | | func.downloadFileByBlobHandler(res); |
| | | this.$message.success('å¯¼åºæå'); |
| | | }).catch(err => { |
| | | this.$message.error(err); |
| | | }); |
| | | }, |
| | | handleRefreshTree(type) { |
| | | //type:add\edit\del |
| | | if(type=="del"){ |
| | | this.$refs.tree.remove(this.currentClickNode); |
| | | this.currentClickNode=null; |
| | | this.form={}; |
| | | }else{ |
| | | if (this.currentClickNode) { |
| | | let node = this.currentClickNode.parent; |
| | | node.loaded = false; |
| | | node.expand(); |
| | | this.$refs.tree.setCurrentNode(this.currentClickNode); |
| | | }else { |
| | | this.refresh = Math.random(); // å·æ°å·¦ä¾§æ |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | </script> |