Compare commits
No commits in common. "5a4fa5a63dd748de015978130309c97b7744d45c" and "df477c69889330032294bc24b2c1d4b7258d1587" have entirely different histories.
5a4fa5a63d
...
df477c6988
|
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<el-dialog v-if="visible" :visible.sync="visible" v-dialogDrag width="540px" :close-on-click-modal="false"
|
<el-dialog v-if="visible" :visible.sync="visible" v-dialogDrag width="540px" :close-on-click-modal="false"
|
||||||
:close-on-press-escape="false" append-to-body :title="$t('system:userlist:button:groups')"
|
:close-on-press-escape="false" append-to-body :title="$t('system:userlist:roleList:title')"
|
||||||
:before-close="cancel">
|
:before-close="cancel">
|
||||||
<el-button size="mini" type="primary" @click.stop="openAdd" style="float: right">
|
<el-button size="mini" type="primary" @click.stop="openAdd" style="float: right">
|
||||||
{{ $t('common:button:new') }}
|
{{ $t('common:button:new') }}
|
||||||
|
|
|
||||||
|
|
@ -21,14 +21,6 @@
|
||||||
<template slot="genderSlot" slot-scope="{ scope }">
|
<template slot="genderSlot" slot-scope="{ scope }">
|
||||||
{{ scope.row.Sex ? 'Male' : 'Female' }}
|
{{ scope.row.Sex ? 'Male' : 'Female' }}
|
||||||
</template>
|
</template>
|
||||||
<template slot="HospitalGroupListSlot" slot-scope="{ scope }">
|
|
||||||
{{
|
|
||||||
Array.isArray(scope.row.HospitalGroupList) &&
|
|
||||||
scope.row.HospitalGroupList.length > 0
|
|
||||||
? scope.row.HospitalGroupList.map((item) => item.Name).join(', ')
|
|
||||||
: ''
|
|
||||||
}}
|
|
||||||
</template>
|
|
||||||
<template slot="UserTypeSlot" slot-scope="{ scope }">
|
<template slot="UserTypeSlot" slot-scope="{ scope }">
|
||||||
{{
|
{{
|
||||||
Array.isArray(scope.row.UserRoleList) &&
|
Array.isArray(scope.row.UserRoleList) &&
|
||||||
|
|
@ -67,7 +59,7 @@
|
||||||
</box-content>
|
</box-content>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getUserList, getUserTypeList, deleteSysUser, getHospitalGroupList } from "@/api/admin";
|
import { getUserList, getUserTypeList, deleteSysUser } from "@/api/admin";
|
||||||
// import { searchForm, searchHandle, columns } from './list'
|
// import { searchForm, searchHandle, columns } from './list'
|
||||||
import BoxContent from "@/components/BoxContent";
|
import BoxContent from "@/components/BoxContent";
|
||||||
import SearchForm from "@/components/BaseForm/search-form";
|
import SearchForm from "@/components/BaseForm/search-form";
|
||||||
|
|
@ -154,14 +146,6 @@ export default {
|
||||||
minWidth: 130,
|
minWidth: 130,
|
||||||
showOverflowTooltip: true,
|
showOverflowTooltip: true,
|
||||||
},
|
},
|
||||||
{
|
|
||||||
prop: 'HospitalGroupId',
|
|
||||||
label: this.$t('system:userlist:table:HospitalGroupList'),
|
|
||||||
minWidth: 100,
|
|
||||||
slot: 'HospitalGroupListSlot',
|
|
||||||
// sortable: 'custom',
|
|
||||||
showOverflowTooltip: true,
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
prop: 'UserType',
|
prop: 'UserType',
|
||||||
label: this.$t('system:userlist:table:UserType'),
|
label: this.$t('system:userlist:table:UserType'),
|
||||||
|
|
@ -179,15 +163,15 @@ export default {
|
||||||
sortable: 'custom',
|
sortable: 'custom',
|
||||||
showOverflowTooltip: true,
|
showOverflowTooltip: true,
|
||||||
},
|
},
|
||||||
// {
|
{
|
||||||
// prop: 'IsTestUser',
|
prop: 'IsTestUser',
|
||||||
// label: this.$t('system:userlist:table:IsTestUser'),
|
label: this.$t('system:userlist:table:IsTestUser'),
|
||||||
// hidden: true,
|
hidden: true,
|
||||||
// slot: 'isTestUserSlot',
|
slot: 'isTestUserSlot',
|
||||||
// minWidth: 120,
|
minWidth: 120,
|
||||||
// sortable: 'custom',
|
sortable: 'custom',
|
||||||
// showOverflowTooltip: true,
|
showOverflowTooltip: true,
|
||||||
// },
|
},
|
||||||
{
|
{
|
||||||
prop: 'Status',
|
prop: 'Status',
|
||||||
label: this.$t('system:userlist:table:Status'),
|
label: this.$t('system:userlist:table:Status'),
|
||||||
|
|
@ -296,25 +280,25 @@ export default {
|
||||||
change: (scope) => '',
|
change: (scope) => '',
|
||||||
placeholder: '',
|
placeholder: '',
|
||||||
},
|
},
|
||||||
// {
|
{
|
||||||
// type: 'Select',
|
type: 'Select',
|
||||||
// label: this.$t('system:userlist:label:IsTestUser'),
|
label: this.$t('system:userlist:label:IsTestUser'),
|
||||||
// prop: 'IsTestUser',
|
prop: 'IsTestUser',
|
||||||
// width: '100px',
|
width: '100px',
|
||||||
// options: [
|
options: [
|
||||||
// {
|
{
|
||||||
// label: this.$t('system:userlist:label:IsTestUser:Yes'),
|
label: this.$t('system:userlist:label:IsTestUser:Yes'),
|
||||||
// value: true,
|
value: true,
|
||||||
// },
|
},
|
||||||
// {
|
{
|
||||||
// label: this.$t('system:userlist:label:IsTestUser:No'),
|
label: this.$t('system:userlist:label:IsTestUser:No'),
|
||||||
// value: false,
|
value: false,
|
||||||
// },
|
},
|
||||||
// ],
|
],
|
||||||
// props: { label: 'label', value: 'value' },
|
props: { label: 'label', value: 'value' },
|
||||||
// change: (scope) => '',
|
change: (scope) => '',
|
||||||
// placeholder: '',
|
placeholder: '',
|
||||||
// },
|
},
|
||||||
{
|
{
|
||||||
type: 'Select',
|
type: 'Select',
|
||||||
label: this.$t('system:userlist:label:Status'),
|
label: this.$t('system:userlist:label:Status'),
|
||||||
|
|
@ -331,15 +315,6 @@ export default {
|
||||||
change: (scope) => '',
|
change: (scope) => '',
|
||||||
placeholder: '',
|
placeholder: '',
|
||||||
},
|
},
|
||||||
{
|
|
||||||
type: 'Select',
|
|
||||||
label: this.$t('system:userlist:label:HospitalGroupList'),
|
|
||||||
prop: 'HospitalGroupId',
|
|
||||||
width: '100px',
|
|
||||||
options: [], // 下拉选项
|
|
||||||
props: { label: 'Name', value: 'Id' }, // 下拉选项配置信息,必填
|
|
||||||
placeholder: '',
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
type: 'Select',
|
type: 'Select',
|
||||||
label: this.$t('system:userlist:label:UserType'),
|
label: this.$t('system:userlist:label:UserType'),
|
||||||
|
|
@ -399,24 +374,11 @@ export default {
|
||||||
created() {
|
created() {
|
||||||
this.getList();
|
this.getList();
|
||||||
this.getInfo();
|
this.getInfo();
|
||||||
this.getHospitalGroupList()
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
diffTime(time) {
|
diffTime(time) {
|
||||||
return moment(new Date()).diff(time, 'days')
|
return moment(new Date()).diff(time, 'days')
|
||||||
},
|
},
|
||||||
async getHospitalGroupList() {
|
|
||||||
try {
|
|
||||||
let res = await getHospitalGroupList({})
|
|
||||||
if (res.IsSuccess) {
|
|
||||||
let hospitalGroupList = res.Result
|
|
||||||
const index = this.findItemIndex("HospitalGroupId");
|
|
||||||
this.$set(this.searchForm[index], "options", hospitalGroupList);
|
|
||||||
}
|
|
||||||
} catch (err) {
|
|
||||||
console.log(err)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 获取用户信息
|
// 获取用户信息
|
||||||
getList() {
|
getList() {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue