资源管理1.2

This commit is contained in:
xbx 2023-11-21 18:52:06 +08:00
parent 8291e41fd3
commit 93a25ec424
12 changed files with 705 additions and 551 deletions

View File

@ -1,5 +1,5 @@
NODE_ENV=development
VUE_APP_API_BASE_URL=http://localhost:8088/jeecg-boot
VUE_APP_API_BASE_URL=http://localhost:8888/jeecg-boot
VUE_APP_CAS_BASE_URL=http://cas.example.org:8443/cas
VUE_APP_ONLINE_BASE_URL=http://fileview.jeecg.com/onlinePreview

View File

@ -1,62 +1,34 @@
<template>
<j-modal
:width="modalWidth"
:visible="visible"
:title="title"
switchFullscreen
wrapClassName="j-user-select-modal"
@ok="handleSubmit"
@cancel="close"
style="top:50px"
cancelText="关闭"
>
<j-modal :width="modalWidth" :visible="visible" :title="title" switchFullscreen wrapClassName="j-user-select-modal"
@ok="handleSubmit" @cancel="close" style="top:50px" cancelText="关闭">
<a-row :gutter="10" style="background-color: #ececec; padding: 10px; margin: -10px">
<a-col :md="6" :sm="24">
<a-card :bordered="false">
<!--组织机构-->
<a-directory-tree
selectable
:selectedKeys="selectedDepIds"
:checkStrictly="true"
:dropdownStyle="{maxHeight:'200px',overflow:'auto'}"
:treeData="departTree"
:expandAction="false"
@select="onDepSelect"
:load-data="onLoadDepartment"
/>
<a-directory-tree selectable :selectedKeys="selectedDepIds" :checkStrictly="true"
:dropdownStyle="{ maxHeight: '200px', overflow: 'auto' }" :treeData="departTree" :expandAction="false"
@select="onDepSelect" :load-data="onLoadDepartment" />
</a-card>
</a-col>
<a-col :md="18" :sm="24">
<a-card :bordered="false">
<a-form-model>
<a-form-model-item label="用户账号" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-row type="flex" :gutter="8">
<a-col :span="18">
<a-input-search
:style="{width:'100%'}"
placeholder="请输入账号"
v-model="queryParam.username"
@search="onSearch"
></a-input-search>
</a-col>
<a-col :span="6">
<a-button @click="searchReset(1)" icon="redo">重置</a-button>
</a-col>
</a-row>
</a-form-model-item>
</a-form-model>
用户姓名:
<a-input-search :style="{ width: '150px', marginBottom: '15px' }" placeholder="请输入姓名"
v-model="queryParam.realname" @search="onSearch"></a-input-search>
<span style="margin-left: 10px"></span>
用户账号:
<a-input-search :style="{ width: '150px', marginBottom: '15px' }" placeholder="请输入账号"
v-model="queryParam.username" @search="onSearch"></a-input-search>
<!-- 间隔 -->
<span style="margin-left: 10px"></span>
<a-button @click="searchReset(1)" icon="redo">重置</a-button>
<!--用户列表-->
<a-table
ref="table"
:scroll="scrollTrigger"
size="middle"
rowKey="id"
:columns="columns"
:dataSource="dataSource"
:pagination="ipagination"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange,type: getType}"
:loading="loading"
@change="handleTableChange">
<a-table ref="table" :scroll="scrollTrigger" size="middle" rowKey="id" :columns="columns"
:dataSource="dataSource" :pagination="ipagination"
:rowSelection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type: getType }"
:loading="loading" @change="handleTableChange">
</a-table>
</a-card>
</a-col>
@ -65,302 +37,303 @@
</template>
<script>
import { pushIfNotExist, filterObj } from '@/utils/util'
import {queryDepartTreeList, getUserList, queryUserByDepId, queryDepartTreeSync} from '@/api/api'
import { getAction } from '@/api/manage'
import { pushIfNotExist, filterObj } from '@/utils/util'
import { queryDepartTreeList, getUserList, queryUserByDepId, queryDepartTreeSync } from '@/api/api'
import { getAction } from '@/api/manage'
export default {
name: 'JSelectUserByDepModal',
components: {},
props: ['modalWidth', 'multi', 'userIds', 'store', 'text'],
data() {
return {
queryParam: {
username: "",
export default {
name: 'JSelectUserByDepModal',
components: {},
props: ['modalWidth', 'multi', 'userIds', 'store', 'text'],
data() {
return {
queryParam: {
username: "",
realname: ""
},
columns: [
{
title: '用户账号',
align: 'center',
dataIndex: 'username'
},
columns: [
{
title: '用户账号',
align: 'center',
dataIndex: 'username'
},
{
title: '用户姓名',
align: 'center',
dataIndex: 'realname'
},
{
title: '性别',
align: 'center',
dataIndex: 'sex',
customRender: function (text) {
if (text === 1) {
return '男'
} else if (text === 2) {
return '女'
} else {
return text
}
{
title: '用户姓名',
align: 'center',
dataIndex: 'realname'
},
{
title: '性别',
align: 'center',
dataIndex: 'sex',
customRender: function (text) {
if (text === 1) {
return '男'
} else if (text === 2) {
return '女'
} else {
return text
}
},
{
title: '手机',
align: 'center',
dataIndex: 'phone'
},
{
title: '部门',
align: 'center',
dataIndex: 'orgCodeTxt'
}
],
scrollTrigger: {},
dataSource: [],
selectionRows: [],
selectedRowKeys: [],
selectUserRows: [],
selectUserIds: [],
title: '根据部门选择用户',
ipagination: {
current: 1,
pageSize: 10,
pageSizeOptions: ['10', '20', '30'],
showTotal: (total, range) => {
return range[0] + '-' + range[1] + ' 共' + total + '条'
},
showQuickJumper: true,
showSizeChanger: true,
total: 0
},
isorter: {
column: 'createTime',
order: 'desc'
{
title: '手机',
align: 'center',
dataIndex: 'phone'
},
selectedDepIds: [],
departTree: [],
visible: false,
form: this.$form.createForm(this),
loading: false,
expandedKeys: [],
labelCol: {
xs: { span: 24 },
sm: { span: 4 },
{
title: '部门',
align: 'center',
dataIndex: 'orgCodeTxt'
}
],
scrollTrigger: {},
dataSource: [],
selectionRows: [],
selectedRowKeys: [],
selectUserRows: [],
selectUserIds: [],
title: '根据部门选择用户',
ipagination: {
current: 1,
pageSize: 10,
pageSizeOptions: ['10', '20', '30'],
showTotal: (total, range) => {
return range[0] + '-' + range[1] + ' 共' + total + '条'
},
wrapperCol: {
xs: { span: 24 },
sm: { span: 10 },
},
}
},
computed: {
// getter
getType: function () {
return this.multi == true ? 'checkbox' : 'radio';
}
},
watch: {
userIds: {
immediate: true,
handler() {
this.initUserNames()
}
showQuickJumper: true,
showSizeChanger: true,
total: 0
},
},
created() {
//
this.resetScreenSize();
this.loadData()
},
methods: {
initUserNames() {
if (this.userIds) {
// , 使 in
let values = this.userIds.split(',') + ','
let param = {[this.store]: values}
getAction('/sys/user/getMultiUser', param).then((list)=>{
this.selectionRows = []
let selectedRowKeys = []
let textArray = []
if(list && list.length>0){
for(let user of list){
textArray.push(user[this.text])
selectedRowKeys.push(user['id'])
this.selectionRows.push(user)
}
}
this.selectedRowKeys = selectedRowKeys
this.$emit('initComp', textArray.join(','))
})
} else {
// JSelectUserByDepbug issues/I16634
this.$emit('initComp', '')
// #2610
this.selectedRowKeys = []
}
isorter: {
column: 'createTime',
order: 'desc'
},
async loadData(arg) {
if (arg === 1) {
this.ipagination.current = 1;
}
let params = this.getQueryParams()//
this.loading = true
getAction('/sys/user/queryUserComponentData', params).then(res=>{
if (res.success) {
this.dataSource = res.result.records
this.ipagination.total = res.result.total
}
}).finally(() => {
this.loading = false
})
selectedDepIds: [],
departTree: [],
visible: false,
form: this.$form.createForm(this),
loading: false,
expandedKeys: [],
labelCol: {
xs: { span: 24 },
sm: { span: 4 },
},
//
resetScreenSize() {
let screenWidth = document.body.clientWidth;
if (screenWidth < 500) {
this.scrollTrigger = {x: 800};
} else {
this.scrollTrigger = {};
}
wrapperCol: {
xs: { span: 24 },
sm: { span: 10 },
},
showModal() {
this.visible = true;
this.queryDepartTree();
}
},
computed: {
// getter
getType: function () {
return this.multi == true ? 'checkbox' : 'radio';
}
},
watch: {
userIds: {
immediate: true,
handler() {
this.initUserNames()
this.loadData();
this.form.resetFields();
},
getQueryParams() {
let param = Object.assign({}, this.queryParam, this.isorter);
param.field = this.getQueryField();
param.pageNo = this.ipagination.current;
param.pageSize = this.ipagination.pageSize;
param.departId = this.selectedDepIds.join(',')
return filterObj(param);
},
getQueryField() {
let str = 'id,';
for (let a = 0; a < this.columns.length; a++) {
str += ',' + this.columns[a].dataIndex;
}
return str;
},
searchReset(num) {
let that = this;
that.selectedRowKeys = [];
that.selectUserIds = [];
that.selectedDepIds = [];
if (num !== 0) {
that.queryParam = {};
that.loadData(1);
}
},
close() {
this.searchReset(0);
this.visible = false;
},
handleTableChange(pagination, filters, sorter) {
//TODO
if (Object.keys(sorter).length > 0) {
this.isorter.column = sorter.field;
this.isorter.order = 'ascend' === sorter.order ? 'asc' : 'desc';
}
this.ipagination = pagination;
this.loadData();
},
handleSubmit() {
let that = this;
this.getSelectUserRows();
that.$emit('ok', that.selectUserRows);
that.searchReset(0)
that.close();
},
//
getSelectUserRows() {
this.selectUserRows = []
for (let row of this.selectionRows) {
if (this.selectedRowKeys.includes(row.id)) {
this.selectUserRows.push(row)
}
}
this.selectUserIds = this.selectUserRows.map(row => row.username).join(',')
},
// ,
onDepSelect(selectedDepIds) {
if (selectedDepIds[0] != null) {
if (this.selectedDepIds[0] !== selectedDepIds[0]) {
this.selectedDepIds = [selectedDepIds[0]];
}
this.loadData(1);
}
},
onSelectChange(selectedRowKeys, selectionRows) {
this.selectedRowKeys = selectedRowKeys;
selectionRows.forEach(row => pushIfNotExist(this.selectionRows, row, 'id'))
},
onSearch() {
this.loadData(1);
},
// id
initQueryUserByDepId(selectedDepIds) {
this.loading = true
return queryUserByDepId({id: selectedDepIds.toString()}).then((res) => {
if (res.success) {
this.dataSource = res.result;
this.ipagination.total = res.result.length;
}
}).finally(() => {
this.loading = false
})
},
queryDepartTree() {
//update-begin-author:taoyan date:20211202 for: https://github.com/jeecgboot/jeecg-boot/issues/3196
this.expandedKeys = []
this.departTree = []
queryDepartTreeSync().then((res) => {
if (res.success) {
for (let i = 0; i < res.result.length; i++) {
let temp = res.result[i]
this.departTree.push(temp)
}
}
})
},
onLoadDepartment(treeNode){
return new Promise(resolve => {
queryDepartTreeSync({pid:treeNode.dataRef.id}).then((res) => {
if (res.success) {
//chidlrenisLeaf
if(res.result.length == 0){
treeNode.dataRef['isLeaf']=true
return;
}else{
treeNode.dataRef['children']= res.result;
}
}
})
resolve();
});
},
//update-end-author:taoyan date:20211202 for: https://github.com/jeecgboot/jeecg-boot/issues/3196
modalFormOk() {
this.loadData();
}
},
},
created() {
//
this.resetScreenSize();
this.loadData()
},
methods: {
initUserNames() {
if (this.userIds) {
// , 使 in
let values = this.userIds.split(',') + ','
let param = { [this.store]: values }
getAction('/sys/user/getMultiUser', param).then((list) => {
this.selectionRows = []
let selectedRowKeys = []
let textArray = []
if (list && list.length > 0) {
for (let user of list) {
textArray.push(user[this.text])
selectedRowKeys.push(user['id'])
this.selectionRows.push(user)
}
}
this.selectedRowKeys = selectedRowKeys
this.$emit('initComp', textArray.join(','))
})
} else {
// JSelectUserByDepbug issues/I16634
this.$emit('initComp', '')
// #2610
this.selectedRowKeys = []
}
},
async loadData(arg) {
if (arg === 1) {
this.ipagination.current = 1;
}
let params = this.getQueryParams()//
this.loading = true
getAction('/sys/user/queryUserComponentData', params).then(res => {
if (res.success) {
this.dataSource = res.result.records
this.ipagination.total = res.result.total
}
}).finally(() => {
this.loading = false
})
},
//
resetScreenSize() {
let screenWidth = document.body.clientWidth;
if (screenWidth < 500) {
this.scrollTrigger = { x: 800 };
} else {
this.scrollTrigger = {};
}
},
showModal() {
this.visible = true;
this.queryDepartTree();
this.initUserNames()
this.loadData();
this.form.resetFields();
},
getQueryParams() {
let param = Object.assign({}, this.queryParam, this.isorter);
param.field = this.getQueryField();
param.pageNo = this.ipagination.current;
param.pageSize = this.ipagination.pageSize;
param.departId = this.selectedDepIds.join(',')
return filterObj(param);
},
getQueryField() {
let str = 'id,';
for (let a = 0; a < this.columns.length; a++) {
str += ',' + this.columns[a].dataIndex;
}
return str;
},
searchReset(num) {
let that = this;
that.selectedRowKeys = [];
that.selectUserIds = [];
that.selectedDepIds = [];
if (num !== 0) {
that.queryParam = {};
that.loadData(1);
}
},
close() {
this.searchReset(0);
this.visible = false;
},
handleTableChange(pagination, filters, sorter) {
//TODO
if (Object.keys(sorter).length > 0) {
this.isorter.column = sorter.field;
this.isorter.order = 'ascend' === sorter.order ? 'asc' : 'desc';
}
this.ipagination = pagination;
this.loadData();
},
handleSubmit() {
let that = this;
this.getSelectUserRows();
that.$emit('ok', that.selectUserRows);
that.searchReset(0)
that.close();
},
//
getSelectUserRows() {
this.selectUserRows = []
for (let row of this.selectionRows) {
if (this.selectedRowKeys.includes(row.id)) {
this.selectUserRows.push(row)
}
}
this.selectUserIds = this.selectUserRows.map(row => row.username).join(',')
},
// ,
onDepSelect(selectedDepIds) {
if (selectedDepIds[0] != null) {
if (this.selectedDepIds[0] !== selectedDepIds[0]) {
this.selectedDepIds = [selectedDepIds[0]];
}
this.loadData(1);
}
},
onSelectChange(selectedRowKeys, selectionRows) {
this.selectedRowKeys = selectedRowKeys;
selectionRows.forEach(row => pushIfNotExist(this.selectionRows, row, 'id'))
},
onSearch() {
this.loadData(1);
},
// id
initQueryUserByDepId(selectedDepIds) {
this.loading = true
return queryUserByDepId({ id: selectedDepIds.toString() }).then((res) => {
if (res.success) {
this.dataSource = res.result;
this.ipagination.total = res.result.length;
}
}).finally(() => {
this.loading = false
})
},
queryDepartTree() {
//update-begin-author:taoyan date:20211202 for: https://github.com/jeecgboot/jeecg-boot/issues/3196
this.expandedKeys = []
this.departTree = []
queryDepartTreeSync().then((res) => {
if (res.success) {
for (let i = 0; i < res.result.length; i++) {
let temp = res.result[i]
this.departTree.push(temp)
}
}
})
},
onLoadDepartment(treeNode) {
return new Promise(resolve => {
queryDepartTreeSync({ pid: treeNode.dataRef.id }).then((res) => {
if (res.success) {
//chidlrenisLeaf
if (res.result.length == 0) {
treeNode.dataRef['isLeaf'] = true
return;
} else {
treeNode.dataRef['children'] = res.result;
}
}
})
resolve();
});
},
//update-end-author:taoyan date:20211202 for: https://github.com/jeecgboot/jeecg-boot/issues/3196
modalFormOk() {
this.loadData();
}
}
}
</script>
<style scoped>
.ant-table-tbody .ant-table-row td {
padding-top: 10px;
padding-bottom: 10px;
}
.ant-table-tbody .ant-table-row td {
padding-top: 10px;
padding-bottom: 10px;
}
#components-layout-demo-custom-trigger .trigger {
font-size: 18px;
line-height: 64px;
padding: 0 24px;
cursor: pointer;
transition: color .3s;
}
#components-layout-demo-custom-trigger .trigger {
font-size: 18px;
line-height: 64px;
padding: 0 24px;
cursor: pointer;
transition: color .3s;
}
</style>

View File

@ -1,7 +1,7 @@
<template>
<div>
<index-chart v-if="indexStyle==1"></index-chart>
<index-bdc v-if="indexStyle==2"></index-bdc>
<!-- <index-bdc v-if="indexStyle==2"></index-bdc>
<index-task v-if="indexStyle==3"></index-task>
<div style="width: 100%;text-align: right;margin-top: 20px">
请选择首页样式
@ -10,7 +10,7 @@
<a-radio :value="2">统计图表2</a-radio>
<a-radio :value="3">任务表格</a-radio>
</a-radio-group>
</div>
</div> -->
</div>
</template>

View File

@ -12,39 +12,40 @@
</chart-card>
</a-col>
</a-row> -->
<a-row :gutter="24">
<a-row :gutter="24">
<a-col :sm="24" :md="12" :xl="6" :style="{ marginBottom: '24px' }">
<chart-card title="成员访问次数" :total="cardCount.sll | NumberFormat">
<template slot="footer">今日访问量<span>{{ todaySll }}</span></template>
<chart-card title="仪器总数" :total="this.InstrumentCount">
<template slot="footer">资产总数<span>{{ this.ChartDataSum }}</span></template>
</chart-card>
</a-col>
<a-col :sm="24" :md="12" :xl="6" :style="{ marginBottom: '24px' }">
<chart-card title="办结量" :total="cardCount.bjl | NumberFormat">
<template slot="footer">今日办结量<span>{{ todayBjl }}</span></template>
<chart-card title="仪器总价" :total="this.InstrumentAmount">
<template slot="footer">总资产价值量<span>{{ this.InstrumentAmount+this.FurnitureAmount }}</span></template>
</chart-card>
</a-col>
<a-col :sm="24" :md="12" :xl="6" :style="{ marginBottom: '24px' }">
<chart-card title="用户受理量" :total="cardCount.isll | NumberFormat">
<template slot="footer">用户今日受理量<span>{{ todayISll }}</span></template>
<chart-card title="家具总数" :total="this.FurnitureCount">
<template slot="footer">资产总数<span>{{ this.ChartDataSum }}</span></template>
</chart-card>
</a-col>
<a-col :sm="24" :md="12" :xl="6" :style="{ marginBottom: '24px' }">
<chart-card title="用户办结量" :total="cardCount.ibjl | NumberFormat">
<template slot="footer">用户今日办结量<span>{{ todayIBjl }}</span></template>
<chart-card title="家具总价" :total="this.FurnitureAmount">
<template slot="footer">总资产价值量<span>{{ this.InstrumentAmount+this.FurnitureAmount }}</span></template>
</chart-card>
</a-col>
</a-row>
<div class="container">
<div id="main" style="width: 600px; height: 400px" ></div>
<div id="pie" style="width: 600px; height: 400px" ></div>
</div>
<div id="main" style="width: 600px; height: 400px"></div>
<div id="pie" style="width: 600px; height: 400px"></div>
</div>
</div>
</template>
<script>
import ACol from "ant-design-vue/es/grid/Col"
import ChartCard from '@/components/ChartCard'
import { getAction } from '../../api/manage'
export default {
components: {
@ -72,12 +73,63 @@ export default {
isll: [],
ibjl: []
},
PieChartData: [],
ChartData: [],
ChartDataSum: 0,
InstrumentCount: 0,
FurnitureCount: 0,
InstrumentAmount: 0,
FurnitureAmount: 0,
}
},
methods: {
getChart() {
getAction('/rms/rmsDepart/getChart').then(res => {
this.ChartData = res;
this.drawChart();
})
},
getPieChart() {
getAction('/rms/rmsDepart/getPieChart').then(res => {
this.PieChartData = res;
this.drawPie();
})
},
getInstrumentCount() {
getAction('/rms/rmsDepart/getInstrumentCount').then(res => {
this.InstrumentCount = res;
})
},
getFurnitureCount() {
getAction('/rms/rmsDepart/getFurnitureCount').then(res => {
this.FurnitureCount = res;
})
},
getInstrumentAmount() {
getAction('/rms/rmsDepart/getInstrumentAmount').then(res => {
this.InstrumentAmount = res;
})
},
getFurnitureAmount() {
getAction('/rms/rmsDepart/getFurnitureAmount').then(res => {
this.FurnitureAmount = res;
})
},
getSum() {
for (let i = 0; i < this.ChartData.length; i++) {
this.ChartDataSum += this.ChartData[i];
}
console.log(this.ChartDataSum);
},
drawChart() {
// domecharts main
let myChart = this.$echarts.init(document.getElementById("main"));
//
for (let i = 0; i < this.ChartData.length; i++) {
this.ChartDataSum += this.ChartData[i];
}
console.log(this.ChartDataSum);
//
let option = {
title: {
@ -88,14 +140,21 @@ export default {
data: ["资产数量"],
},
xAxis: {
data: ["理工一", "崇实楼", "行知楼", "理工二"],
data: ["理工一号楼", "行知楼", "体育楼", "崇师楼", "新实验楼", "社科楼"],
},
yAxis: {},
series: [
{
name: "资产数量",
type: "bar",
data: [5, 20, 36, 10],
data: this.ChartData,
label: {
normal: {
show: true,
position: 'top'
},
formatter: '{@value}'
}
},
],
};
@ -138,13 +197,7 @@ export default {
labelLine: {
show: false
},
data: [
{ value: 706, name: '821501:终端室' },
{ value: 761, name: '821502:微机室' },
{ value: 97, name: '821503:硬件实验室' },
{ value: 55, name: '821511:计算机总控室' },
{ value: 180, name: '821512:12年前盘亏' }
]
data: this.PieChartData
}
]
};
@ -154,8 +207,16 @@ export default {
},
mounted() {
this.drawChart();
this.drawPie();
},
created() {
this.getPieChart();
this.getChart();
this.getInstrumentCount();
this.getFurnitureCount();
this.getInstrumentAmount();
this.getFurnitureAmount();
this.getSum(); // getSum
},
}

View File

@ -1,96 +1,98 @@
<template>
<a-card :bordered="false">
<!-- 查询区域 -->
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="领用人">
<a-card :bordered="false" style="height: 770px;">
<a-row>
<a-col :span="5">
<locationaTree ref="locationaTree" :height="600" @onSelect="onSelect"></locationaTree>
</a-col>
<a-col :span="19">
<!-- 查询区域 -->
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :xl="7" :lg="7" :md="8" :sm="24">
<a-form-item label="领用人">
<j-select-user-by-dep placeholder="请选择领用人" v-model="queryParam.recipient" />
</a-form-item>
</a-col>
<!-- <a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="存放地址">
<j-select-user-by-dep placeholder="请选择领用人" v-model="queryParam.recipient" />
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span>
</a-col>
</a-row>
</a-form>
</div>
<!-- 查询区域-END -->
</a-col> -->
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span>
</a-col>
</a-row>
</a-form>
</div>
<!-- 查询区域-END -->
<!-- 操作按钮区域 -->
<div class="table-operator">
<a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
<a-button type="primary" icon="download" @click="handleExportXls('家具信息表')">导出</a-button>
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl"
@change="handleImportExcel">
<a-button type="primary" icon="import">导入</a-button>
</a-upload>
<!-- 高级查询区域 -->
<j-super-query :fieldList="superFieldList" ref="superQueryModal"
@handleSuperQuery="handleSuperQuery"></j-super-query>
<a-dropdown v-if="selectedRowKeys.length > 0">
<a-menu slot="overlay">
<a-menu-item key="1" @click="batchDel"><a-icon type="delete" />删除</a-menu-item>
</a-menu>
<a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
</a-dropdown>
</div>
<!-- 操作按钮区域 -->
<div class="table-operator">
<a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
<a-button @click="addData()" type="primary" icon="plus">导数据</a-button>
<!-- table区域-begin -->
<div>
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{
selectedRowKeys.length }}</a>
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
</div>
<a-button type="primary" icon="download" @click="handleExportXls('家具信息表')">导出</a-button>
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader"
:action="importExcelUrl" @change="handleImportExcel">
<a-button type="primary" icon="import">导入</a-button>
</a-upload>
<!-- 高级查询区域 -->
<j-super-query :fieldList="superFieldList" ref="superQueryModal"
@handleSuperQuery="handleSuperQuery"></j-super-query>
<a-dropdown v-if="selectedRowKeys.length > 0">
<a-menu slot="overlay">
<a-menu-item key="1" @click="batchDel"><a-icon type="delete" />删除</a-menu-item>
</a-menu>
<a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
</a-dropdown>
</div>
<a-table ref="table" size="middle" :scroll="{ x: true }" bordered rowKey="id" :columns="columns"
:dataSource="dataSource" :pagination="ipagination" :loading="loading"
:rowSelection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" class="j-table-force-nowrap"
@change="handleTableChange">
<!-- table区域-begin -->
<div>
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{
selectedRowKeys.length }}</a>
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
</div>
<a-row>
<template slot="htmlSlot" slot-scope="text">
<div v-html="text"></div>
</template>
<template slot="imgSlot" slot-scope="text,record">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
<img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt=""
style="max-width:80px;font-size: 12px;font-style: italic;" />
</template>
<template slot="fileSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
<a-button v-else :ghost="true" type="primary" icon="download" size="small" @click="downloadFile(text)">
下载
</a-button>
</template>
<!-- <a-col :span=""> -->
<span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
<a-table ref="table" size="middle" :scroll="{ x: true }" bordered rowKey="id" :columns="columns"
:dataSource="dataSource" :pagination="ipagination" :loading="loading"
:rowSelection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
class="j-table-force-nowrap" @change="handleTableChange">
<a-divider type="vertical" />
<a-dropdown>
<a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
<a-menu slot="overlay">
<a-menu-item>
<a @click="handleDetail(record)">详情</a>
</a-menu-item>
<a-menu-item>
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</a-menu-item>
</a-menu>
</a-dropdown>
</span>
<template slot="usageYears" slot-scope="text">
{{ text + '年' }}
</template>
</a-table>
</div>
<span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
<rms-furniture-modal ref="modalForm" @ok="modalFormOk"></rms-furniture-modal>
</a-card>
<a-divider type="vertical" />
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
<a-divider type="vertical" />
<a @click="handleDetail(record)">详情</a>
</span>
</a-table>
<!-- </a-col> -->
</a-row>
</div>
<rms-furniture-modal ref="modalForm" @ok="modalFormOk"></rms-furniture-modal>
</a-col>
</a-row>
</a-card>
</template>
<script>
@ -100,12 +102,17 @@ import { mixinDevice } from '@/utils/mixin'
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import RmsFurnitureModal from './modules/RmsFurnitureModal'
import { filterMultiDictText } from '@/components/dict/JDictSelectUtil'
import { postAction } from '../../../api/manage'
import RmsLocationModal from '../LocationList/modules/RmsLocationModal'
import locationaTree from '../components/locationaTree'
export default {
name: 'RmsFurnitureList',
mixins: [JeecgListMixin, mixinDevice],
components: {
RmsFurnitureModal
RmsFurnitureModal,
RmsLocationModal,
locationaTree
},
data() {
return {
@ -140,13 +147,13 @@ export default {
title: '型号',
align: "center",
dataIndex: 'model',
width: 80
width: 120
},
{
title: '规格',
align: "center",
dataIndex: 'specifications',
width: 80
width: 150
},
{
title: '数量',
@ -170,7 +177,7 @@ export default {
title: '厂家',
align: "center",
dataIndex: 'manufactuer',
width: 120
width: 200
},
{
title: '购置日期',
@ -178,7 +185,8 @@ export default {
dataIndex: 'purchaseDate',
customRender: function (text) {
return !text ? "" : (text.length > 10 ? text.substr(0, 10) : text)
}
},
width: 120
},
{
title: '领用人',
@ -202,7 +210,7 @@ export default {
title: '备注',
align: "center",
dataIndex: 'note',
width: 120
width: 180
},
{
title: '审核状态',
@ -219,14 +227,15 @@ export default {
{
title: '使用年限',
align: "center",
dataIndex: 'usageYears'
dataIndex: 'usageYears',
scopedSlots: { customRender: 'usageYears' }
},
{
title: '操作',
dataIndex: 'action',
align: "center",
fixed: "right",
width: 147,
width: 160,
scopedSlots: { customRender: 'action' }
}
],
@ -251,6 +260,19 @@ export default {
},
},
methods: {
addData() {
postAction("http://localhost:8088/jeecg-boot/rms/rmsInstrument/addData", {}).then(res => {
this.loadData()
})
},
onSelect(selectedRowKeys) {
//
selectedRowKeys = selectedRowKeys.join(',')
console.log(selectedRowKeys)
this.queryParam.locationId = selectedRowKeys
this.loadData(1)
},
initDictConfig() {
},
getSuperFieldList() {

View File

@ -5,7 +5,7 @@
<a-row>
<a-col :span="12">
<a-form-model-item label="领用单位号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="collectingUnitNumber">
<j-select-depart v-model="model.collectingUnitNumber" :multi="true" />
<j-select-depart v-model="model.collectingUnitNumber" :multi="false" />
</a-form-model-item>
</a-col>
<a-col :span="12">
@ -60,7 +60,7 @@
</a-col>
<a-col :span="12">
<a-form-model-item label="领用人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="recipient">
<j-select-user-by-dep v-model="model.recipient" :multi="true" />
<j-select-user-by-dep v-model="model.recipient" :multi="false" />
</a-form-model-item>
</a-col>
<a-col :span="12">
@ -132,6 +132,55 @@ export default {
},
confirmLoading: false,
validatorRules: {
approvalStatus: [
{ required: true, message: '请选择审核状态', trigger: 'change' },
],
initialAudit: [
{ required: true, message: '请选择初审状态', trigger: 'change' },
],
collectingUnitNumber: [
{ required: true, message: '请选择领用单位号', trigger: 'change' },
],
furnitureNumber: [
{ required: true, message: '请输入家具编号', trigger: 'blur' },
],
furnitureName: [
{ required: true, message: '请输入家具名称', trigger: 'blur' },
],
categoryId: [
{ required: true, message: '请输入分类号', trigger: 'blur' },
],
number: [
{ required: true, message: '请输入数量', trigger: 'blur' },
],
unitPrice: [
{ required: true, message: '请输入单价', trigger: 'blur' },
],
amount: [
{ required: true, message: '请输入金额', trigger: 'blur' },
],
manufactuer: [
{ required: true, message: '请输入厂家', trigger: 'blur' },
],
purchaseDate: [
{ required: true, message: '请选择购置日期', trigger: 'change' },
],
recipient: [
{ required: true, message: '请选择领用人', trigger: 'change' },
],
documentNumber: [
{ required: true, message: '请输入单据号', trigger: 'blur' },
],
locationId: [
{ required: true, message: '请选择存放地地址', trigger: 'change' },
],
usageYears: [
{ required: true, message: '请输入使用年限', trigger: 'blur' },
]
},
url: {
add: "/rms/rmsFurniture/add",

View File

@ -23,7 +23,7 @@
data () {
return {
title:'',
width:800,
width:1000,
visible: false,
disableSubmit: false
}

View File

@ -1,95 +1,94 @@
<template>
<a-card :bordered="false">
<!-- 查询区域 -->
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="领用人">
<j-select-user-by-dep placeholder="请选择领用人" v-model="queryParam.recipient" />
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span>
</a-col>
</a-row>
</a-form>
</div>
<!-- 查询区域-END -->
<a-row>
<a-col :span="5">
<locationaTree ref="locationaTree" :height="640" @onSelect="onSelect"></locationaTree>
</a-col>
<a-col :span="19">
<!-- 查询区域 -->
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :xl="7" :lg="7" :md="8" :sm="24">
<a-form-item label="领用人">
<j-select-user-by-dep placeholder="请选择领用人" v-model="queryParam.recipient" />
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span>
</a-col>
</a-row>
</a-form>
</div>
<!-- 查询区域-END -->
<!-- 操作按钮区域 -->
<div class="table-operator">
<a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
<a-button type="primary" icon="download" @click="handleExportXls('仪器信息表')">导出</a-button>
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl"
@change="handleImportExcel">
<a-button type="primary" icon="import">导入</a-button>
</a-upload>
<!-- 高级查询区域 -->
<j-super-query :fieldList="superFieldList" ref="superQueryModal"
@handleSuperQuery="handleSuperQuery"></j-super-query>
<a-dropdown v-if="selectedRowKeys.length > 0">
<a-menu slot="overlay">
<a-menu-item key="1" @click="batchDel"><a-icon type="delete" />删除</a-menu-item>
</a-menu>
<a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
</a-dropdown>
</div>
<!-- table区域-begin -->
<div>
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{
selectedRowKeys.length }}</a>
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
</div>
<a-table ref="table" size="middle" :scroll="{ x: true }" bordered rowKey="id" :columns="columns"
:dataSource="dataSource" :pagination="ipagination" :loading="loading"
:rowSelection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" class="j-table-force-nowrap"
@change="handleTableChange">
<template slot="htmlSlot" slot-scope="text">
<div v-html="text"></div>
</template>
<template slot="imgSlot" slot-scope="text,record">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
<img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt=""
style="max-width:80px;font-size: 12px;font-style: italic;" />
</template>
<template slot="fileSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
<a-button v-else :ghost="true" type="primary" icon="download" size="small" @click="downloadFile(text)">
下载
</a-button>
</template>
<span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
<a-divider type="vertical" />
<a-dropdown>
<a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
<!-- 操作按钮区域 -->
<div class="table-operator">
<a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
<a-button type="primary" icon="download" @click="handleExportXls('仪器信息表')">导出</a-button>
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl"
@change="handleImportExcel">
<a-button type="primary" icon="import">导入</a-button>
</a-upload>
<!-- 高级查询区域 -->
<j-super-query :fieldList="superFieldList" ref="superQueryModal"
@handleSuperQuery="handleSuperQuery"></j-super-query>
<a-dropdown v-if="selectedRowKeys.length > 0">
<a-menu slot="overlay">
<a-menu-item>
<a @click="handleDetail(record)">详情</a>
</a-menu-item>
<a-menu-item>
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</a-menu-item>
<a-menu-item key="1" @click="batchDel"><a-icon type="delete" />删除</a-menu-item>
</a-menu>
<a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
</a-dropdown>
</span>
</div>
</a-table>
</div>
<!-- table区域-begin -->
<div>
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{
selectedRowKeys.length }}</a>
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
</div>
<rms-instrument-modal ref="modalForm" @ok="modalFormOk"></rms-instrument-modal>
<a-table ref="table" size="middle" :scroll="{ x: true }" bordered rowKey="id" :columns="columns"
:dataSource="dataSource" :pagination="ipagination" :loading="loading"
:rowSelection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" class="j-table-force-nowrap"
@change="handleTableChange">
<template slot="htmlSlot" slot-scope="text">
<div v-html="text"></div>
</template>
<template slot="imgSlot" slot-scope="text,record">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
<img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt=""
style="max-width:80px;font-size: 12px;font-style: italic;" />
</template>
<template slot="fileSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
<a-button v-else :ghost="true" type="primary" icon="download" size="small" @click="downloadFile(text)">
下载
</a-button>
</template>
<span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
<a-divider type="vertical" />
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
<a-divider type="vertical" />
<a @click="handleDetail(record)">详情</a>
</span>
</a-table>
</div>
<rms-instrument-modal ref="modalForm" @ok="modalFormOk"></rms-instrument-modal>
</a-col>
</a-row>
</a-card>
</template>
@ -100,12 +99,15 @@ import { mixinDevice } from '@/utils/mixin'
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import RmsInstrumentModal from './modules/RmsInstrumentModal'
import { filterMultiDictText } from '@/components/dict/JDictSelectUtil'
import RmsLocationModal from '../LocationList/modules/RmsLocationModal'
import locationaTree from '../components/locationaTree'
export default {
name: 'RmsInstrumentList',
mixins: [JeecgListMixin, mixinDevice],
components: {
RmsInstrumentModal
RmsInstrumentModal,
RmsLocationModal,
locationaTree
},
data() {
return {
@ -165,7 +167,7 @@ export default {
{
title: '购置日期',
align: "center",
dataIndex: 'purchasedate',
dataIndex: 'purchaseDate',
customRender: function (text) {
return !text ? "" : (text.length > 10 ? text.substr(0, 10) : text)
},
@ -220,7 +222,7 @@ export default {
dataIndex: 'action',
align: "center",
fixed: "right",
width: 147,
width: 160,
scopedSlots: { customRender: 'action' }
}
],
@ -245,6 +247,13 @@ export default {
},
},
methods: {
onSelect(selectedRowKeys) {
//
selectedRowKeys = selectedRowKeys.join(',')
console.log(selectedRowKeys)
this.queryParam.locationId = selectedRowKeys
this.loadData(1)
},
initDictConfig() {
},
getSuperFieldList() {
@ -257,7 +266,7 @@ export default {
fieldList.push({ type: 'string', value: 'specifications', text: '规格', dictCode: '' })
fieldList.push({ type: 'string', value: 'unitPrice', text: '单价', dictCode: '' })
fieldList.push({ type: 'string', value: 'manufactuer', text: '厂家', dictCode: '' })
fieldList.push({ type: 'date', value: 'purchasedate', text: '购置日期' })
fieldList.push({ type: 'date', value: 'purchaseDate', text: '购置日期' })
fieldList.push({ type: 'sel_user', value: 'recipient', text: '领用人' })
fieldList.push({ type: 'date', value: 'entryDate', text: '入库时间' })
fieldList.push({ type: 'string', value: 'documentNumber', text: '单据号', dictCode: '' })

View File

@ -5,7 +5,7 @@
<a-row>
<a-col :span="12">
<a-form-model-item label="领用单位号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="collectingUnitNumber">
<j-select-depart v-model="model.collectingUnitNumber" :multi="true" />
<j-select-depart v-model="model.collectingUnitNumber" :multi="false" />
</a-form-model-item>
</a-col>
<a-col :span="12">
@ -44,13 +44,13 @@
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="购置日期" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="purchasedate">
<j-date placeholder="请选择购置日期" v-model="model.purchasedate" style="width: 100%" />
<a-form-model-item label="购置日期" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="purchaseDate">
<j-date placeholder="请选择购置日期" v-model="model.purchaseDate" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="领用人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="recipient">
<j-select-user-by-dep v-model="model.recipient" :multi="true" />
<j-select-user-by-dep v-model="model.recipient" :multi="false" />
</a-form-model-item>
</a-col>
<a-col :span="12">
@ -122,6 +122,45 @@ export default {
},
confirmLoading: false,
validatorRules: {
approvalStatus: [
{ required: true, message: '请选择审核状态', trigger: 'change' },
],
initialAudit: [
{ required: true, message: '请选择初审状态', trigger: 'change' },
],
collectingUnitNumber: [
{ required: true, message: '请选择领用单位号', trigger: 'change' },
],
instrumentNumber: [
{ required: true, message: '请输入家具编号', trigger: 'blur' },
],
instrumentName: [
{ required: true, message: '请输入家具名称', trigger: 'blur' },
],
categoryId: [
{ required: true, message: '请输入分类号', trigger: 'blur' },
],
unitPrice: [
{ required: true, message: '请输入单价', trigger: 'blur' },
],
manufactuer: [
{ required: true, message: '请输入厂家', trigger: 'blur' },
],
purchaseDate: [
{ required: true, message: '请选择购置日期', trigger: 'change' },
],
recipient: [
{ required: true, message: '请选择领用人', trigger: 'change' },
],
entryDate: [
{ required: true, message: '请选择入库时间', trigger: 'change' },
],
documentNumber: [
{ required: true, message: '请输入单据号', trigger: 'blur' },
],
locationId: [
{ required: true, message: '请选择存放地地址', trigger: 'blur' },
],
},
url: {
add: "/rms/rmsInstrument/add",

View File

@ -23,7 +23,7 @@
data () {
return {
title:'',
width:800,
width:1000,
visible: false,
disableSubmit: false
}

View File

@ -3,10 +3,10 @@
<!-- 表单结构 -->
<div class="page">
<a-row>
<a-col :span="4" class="tree">
<locationaTree ref="locationaTree" :height="500" @onSelect="onSelect"></locationaTree>
<a-col :span="5" class="tree">
<locationaTree ref="locationaTree" :height="500" @onSelect="onSelect" ></locationaTree>
</a-col>
<a-col :span="20" class="table">
<a-col :span="19" class="table">
<!-- 操作按钮区域 -->
<div class="table-operator" style="padding-bottom: 15px;">
@ -122,12 +122,6 @@ export default {
.page {
height: 600px;
.tree {
height: 500px;
}
.table {
height: 500px;
}
}
</style>

View File

@ -7,7 +7,7 @@
<div v-if="isLoading" class="example">
<a-spin tip="加载中..."></a-spin>
</div>
<a-tree default-expand-all :tree-data="treeData" @select="onSelect" v-if="treeData.length > 0 && !isLoading">
<a-tree :default-expanded-keys="this.keySecond" :tree-data="treeData" @select="onSelect" v-if="treeData.length > 0 && !isLoading">
<template #title="{ key: treeKey, title }">
<span>{{ title }}</span>
</template>
@ -34,6 +34,7 @@ export default {
treeData: [],
getTreeUrl: '/rms/rmsLocation/getTree',
isLoading: false,
keySecond: [],
};
},
mounted() {
@ -78,6 +79,9 @@ export default {
if (node.children) {
for (let child of node.children) {
keys.push(child.key);
for (let subChild of child.children) {
keys.push(subChild.key);
}
}
}
return keys;
@ -88,6 +92,9 @@ export default {
if (res.success) {
this.isLoading = false;
this.treeData = res.result;
for (let node of this.treeData) {
this.keySecond.push(node.key);
}
}
});
},