|
@@ -1,50 +1,16 @@
|
|
|
<template>
|
|
<template>
|
|
|
<div class="workSpace">
|
|
<div class="workSpace">
|
|
|
- <searchForm :keys="['userName']" ref="searchForm" @on-search="onSearch"></searchForm>
|
|
|
|
|
|
|
+ <searchForm :keys="['userName','roleId']" ref="searchForm" @on-search="onSearch"></searchForm>
|
|
|
<VaCard tag="b" class="table">
|
|
<VaCard tag="b" class="table">
|
|
|
<div class="va-table-responsive">
|
|
<div class="va-table-responsive">
|
|
|
- <!-- <table class="va-table">-->
|
|
|
|
|
- <!-- <thead>-->
|
|
|
|
|
- <!-- <tr>-->
|
|
|
|
|
- <!-- <th>用户名称</th>-->
|
|
|
|
|
- <!-- <th>联系方式</th>-->
|
|
|
|
|
- <!-- <th>角色名称</th>-->
|
|
|
|
|
- <!-- <th>状态</th>-->
|
|
|
|
|
- <!-- <th>设置</th>-->
|
|
|
|
|
- <!-- </tr>-->
|
|
|
|
|
- <!-- </thead>-->
|
|
|
|
|
- <!-- <tbody>-->
|
|
|
|
|
- <!-- <tr-->
|
|
|
|
|
- <!-- v-for="user in users"-->
|
|
|
|
|
- <!-- :key="user.id"-->
|
|
|
|
|
- <!-- >-->
|
|
|
|
|
- <!-- <td>{{ user.userName }}</td>-->
|
|
|
|
|
- <!-- <td>{{ user.userName }}</td>-->
|
|
|
|
|
- <!-- <td>{{ user.userName }}</td>-->
|
|
|
|
|
- <!-- <td>-->
|
|
|
|
|
- <!-- <VaChip-->
|
|
|
|
|
- <!-- size='small'-->
|
|
|
|
|
- <!-- :color="'success'"-->
|
|
|
|
|
- <!-- class="mr-6 mb-2"-->
|
|
|
|
|
- <!-- >-->
|
|
|
|
|
- <!-- 使用中-->
|
|
|
|
|
- <!-- </VaChip>-->
|
|
|
|
|
- <!-- </td>-->
|
|
|
|
|
- <!-- <td>-->
|
|
|
|
|
- <!-- <editUserBtn></editUserBtn>-->
|
|
|
|
|
- <!-- <deleteUserBtn></deleteUserBtn>-->
|
|
|
|
|
- <!-- </td>-->
|
|
|
|
|
- <!-- </tr>-->
|
|
|
|
|
- <!-- </tbody>-->
|
|
|
|
|
- <!-- </table>-->
|
|
|
|
|
-
|
|
|
|
|
<VaDataTable :items="users" :columns="columns" :loading="loading">
|
|
<VaDataTable :items="users" :columns="columns" :loading="loading">
|
|
|
<template #cell(setting)="{ rowData }">
|
|
<template #cell(setting)="{ rowData }">
|
|
|
- <editUserBtn :params="rowData"></editUserBtn>
|
|
|
|
|
- <deleteUserBtn @after-op="afterOp" :params="rowData"></deleteUserBtn>
|
|
|
|
|
|
|
+ <editUserBtn :params="rowData" @after-op="afterOp"></editUserBtn>
|
|
|
|
|
+ <deleteUserBtn @after-op="afterOp" :params="rowData"></deleteUserBtn>
|
|
|
</template>
|
|
</template>
|
|
|
<template #cell(birthDate)="{ value }">
|
|
<template #cell(birthDate)="{ value }">
|
|
|
- <VaChip size="small" :color="'success'" class="mr-6 mb-2"> {{value}} </VaChip>
|
|
|
|
|
|
|
+ {{value?getTime(value):'-'}}
|
|
|
|
|
+<!-- <VaChip size="small" :color="'success'" class="mr-6 mb-2"> {{value}} </VaChip>-->
|
|
|
</template>
|
|
</template>
|
|
|
</VaDataTable>
|
|
</VaDataTable>
|
|
|
</div>
|
|
</div>
|
|
@@ -66,6 +32,7 @@
|
|
|
import editUserBtn from './editUserBtn.vue'
|
|
import editUserBtn from './editUserBtn.vue'
|
|
|
import deleteUserBtn from './deleteUserBtn.vue'
|
|
import deleteUserBtn from './deleteUserBtn.vue'
|
|
|
import dict from '../../../../common/dict'
|
|
import dict from '../../../../common/dict'
|
|
|
|
|
+ import moment from 'moment'
|
|
|
export default {
|
|
export default {
|
|
|
name: 'workSpace',
|
|
name: 'workSpace',
|
|
|
components: {
|
|
components: {
|
|
@@ -74,6 +41,9 @@
|
|
|
deleteUserBtn,
|
|
deleteUserBtn,
|
|
|
},
|
|
},
|
|
|
methods: {
|
|
methods: {
|
|
|
|
|
+ getTime(time){
|
|
|
|
|
+ return moment(new Date(parseInt(time))).format('yyyy-MM-DD')
|
|
|
|
|
+ },
|
|
|
afterOp() {
|
|
afterOp() {
|
|
|
this.getList()
|
|
this.getList()
|
|
|
},
|
|
},
|
|
@@ -88,6 +58,7 @@
|
|
|
pageNum: this.pageInfo.pageNum,
|
|
pageNum: this.pageInfo.pageNum,
|
|
|
pageSize: this.pageInfo.pageSize,
|
|
pageSize: this.pageInfo.pageSize,
|
|
|
orgId: this.orgId || '',
|
|
orgId: this.orgId || '',
|
|
|
|
|
+ roleIds: this.$refs.searchForm.form.roleId.join(','),
|
|
|
}
|
|
}
|
|
|
this.$api.getUserList(params).then((res) => {
|
|
this.$api.getUserList(params).then((res) => {
|
|
|
this.loading = false
|
|
this.loading = false
|
|
@@ -105,9 +76,10 @@
|
|
|
orgId: '',
|
|
orgId: '',
|
|
|
columns: [
|
|
columns: [
|
|
|
{ key: 'userName', label: '用户名' },
|
|
{ key: 'userName', label: '用户名' },
|
|
|
|
|
+ { key: 'roleName', label: '角色' },
|
|
|
{ key: 'gender', label: '性别' },
|
|
{ key: 'gender', label: '性别' },
|
|
|
{ key: 'phone', label: '联系方式' },
|
|
{ key: 'phone', label: '联系方式' },
|
|
|
- { key: 'status', label: '状态' },
|
|
|
|
|
|
|
+ { key: 'birthDate', label: '生日' },
|
|
|
{ key: 'setting', label: '设置' },
|
|
{ key: 'setting', label: '设置' },
|
|
|
],
|
|
],
|
|
|
pageInfo: {
|
|
pageInfo: {
|