update 用户管理,角色管理表格左对齐

This commit is contained in:
lb 2022-11-14 11:02:21 +08:00
parent 1f73240063
commit 35051463ad
2 changed files with 61 additions and 66 deletions

View File

@ -7,10 +7,7 @@
-->
<template>
<div class="app-container">
<head-form
:form-config="headFormConfig"
@headBtnClick="btnClick"
/>
<head-form :form-config="headFormConfig" @headBtnClick="btnClick" />
<base-table
:top-btn-config="topBtnConfig"
:table-config="tableProps"
@ -20,14 +17,15 @@
:limit="listQuery.size"
@clickTopBtn="clickTopBtn"
>
<method-btn
slot="handleBtn"
:width="trueWidth"
:method-list="tableBtn"
@clickBtn="handleClick"
/>
<method-btn slot="handleBtn" :width="trueWidth" :method-list="tableBtn" @clickBtn="handleClick" />
</base-table>
<pagination v-show="total > 0" :total="total" :page.sync="listQuery.current" :limit.sync="listQuery.size" @pagination="getList" />
<pagination
v-show="total > 0"
:total="total"
:page.sync="listQuery.current"
:limit.sync="listQuery.size"
@pagination="getList"
/>
<add-form :visible.sync="showDialog" @done="getList" />
<edit-form :visible.sync="showEditDialog" :target-info="{ id: curEditId }" @done="getList" />
<menu-empower ref="empowerRef" :visible.sync="empowerDialog" @done="getList" />
@ -45,29 +43,33 @@ const topBtnConfig = [
}
]
// edit here
const tableBtn = [{
const tableBtn = [
{
type: 'edit',
btnName: 'btn.edit'
}, {
},
{
type: 'EmPower',
btnName: i18n.t('roleManage.roleEmPower')
}, {
},
{
type: 'delete',
btnName: 'btn.delete'
}
]
const tableProps = [{
const tableProps = [
{
prop: 'code',
label: i18n.t('roleManage.roleCode'),
align: 'center'
}, {
label: i18n.t('roleManage.roleCode')
},
{
prop: 'name',
label: i18n.t('roleManage.roleName'),
align: 'center'
}, {
label: i18n.t('roleManage.roleName')
},
{
prop: 'enabled',
label: i18n.t('roleManage.status'),
align: 'center',
filter: basicData('enableState')
},
// {
@ -78,9 +80,9 @@ const tableProps = [{
// },
{
prop: 'remark',
label: i18n.t('roleManage.remark'),
align: 'center'
}]
label: i18n.t('roleManage.remark')
}
]
import AddForm from './AddForm'
import EditForm from './EditForm'
import menuEmpower from './menuEmpower'

View File

@ -112,55 +112,48 @@ const tableBtn = [
const tableProps = [
{
prop: 'name',
label: i18n.t('userManage.userName'),
align: 'center'
label: i18n.t('userManage.userName')
},
{
prop: 'email',
label: i18n.t('userManage.email'),
align: 'center'
label: i18n.t('userManage.email')
},
{
prop: 'mobile',
label: i18n.t('userManage.mobile'),
align: 'center'
label: i18n.t('userManage.mobile')
},
// {
// prop: 'birthday',
// label: i18n.t('userManage.birthday'),
// align: 'center'
//
// },
{
prop: 'orgName',
label: i18n.t('userManage.orgName'),
align: 'center'
label: i18n.t('userManage.orgName')
},
{
prop: 'roleName',
label: i18n.t('roleManage.roleName'),
align: 'center'
label: i18n.t('roleManage.roleName')
},
// {
// prop: 'sex',
// label: i18n.t('userManage.sex'),
// align: 'center',
//
// filter: dataDict('sex')
// },
{
prop: 'code',
label: i18n.t('userManage.code'),
align: 'center'
label: i18n.t('userManage.code')
},
{
prop: 'enabled',
label: i18n.t('userManage.status'),
align: 'center',
filter: dataDict('enableState')
},
{
prop: 'remark',
label: i18n.t('userManage.remark'),
align: 'center'
label: i18n.t('userManage.remark')
}
]
export default {