fix: Modify UserGroups and User definition
1. Modify UserGroups class definition to make it extensible 2. Modify getColumns definition to make it extensible Change-Id: I8e97da2ec2078a8620cc212f76cfab9e1bedb14e
This commit is contained in:
parent
30229526a4
commit
d76bd458fc
@ -73,7 +73,7 @@ export class User extends Base {
|
|||||||
return this.inDetailPage && path.includes('identity/role-admin');
|
return this.inDetailPage && path.includes('identity/role-admin');
|
||||||
}
|
}
|
||||||
|
|
||||||
getColumns = () => {
|
getColumns() {
|
||||||
// const {
|
// const {
|
||||||
// match: { path },
|
// match: { path },
|
||||||
// } = this.props;
|
// } = this.props;
|
||||||
@ -254,7 +254,7 @@ export class User extends Base {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
return columns;
|
return columns;
|
||||||
};
|
}
|
||||||
|
|
||||||
get actionConfigs() {
|
get actionConfigs() {
|
||||||
if (this.inDomainDetail) {
|
if (this.inDomainDetail) {
|
||||||
|
@ -20,9 +20,7 @@ import { Badge } from 'antd';
|
|||||||
import { emptyActionConfig } from 'utils/constants';
|
import { emptyActionConfig } from 'utils/constants';
|
||||||
import actionConfigs from './actions';
|
import actionConfigs from './actions';
|
||||||
|
|
||||||
@inject('rootStore')
|
export class UserGroups extends Base {
|
||||||
@observer
|
|
||||||
export default class UserGroups extends Base {
|
|
||||||
init() {
|
init() {
|
||||||
this.store = globalGroupStore;
|
this.store = globalGroupStore;
|
||||||
}
|
}
|
||||||
@ -43,7 +41,7 @@ export default class UserGroups extends Base {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
getColumns = () => {
|
getColumns() {
|
||||||
const {
|
const {
|
||||||
match: { path },
|
match: { path },
|
||||||
} = this.props;
|
} = this.props;
|
||||||
@ -102,7 +100,7 @@ export default class UserGroups extends Base {
|
|||||||
components.splice(2, 1);
|
components.splice(2, 1);
|
||||||
}
|
}
|
||||||
return components;
|
return components;
|
||||||
};
|
}
|
||||||
|
|
||||||
get actionConfigs() {
|
get actionConfigs() {
|
||||||
const {
|
const {
|
||||||
@ -145,3 +143,5 @@ export default class UserGroups extends Base {
|
|||||||
this.list.silent = false;
|
this.list.silent = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export default inject('rootStore')(observer(UserGroups));
|
||||||
|
Loading…
Reference in New Issue
Block a user