this.users = [];
this['user-name'] = '';
this['user-domain'] = 'system';
- this.disabled = false;
+ this.disabled = "FALSE";
this.platformRoles = {
super_admin: false,
platform_admin: false,
this.isReadOnly = true;
this.userOpen = false;
this.hideColumns = false;
+ //There is probably a better way of handling the view/edit/readonly matrix conditions for some of these inputs. Should definitely revist
this.isEdit = false;
+ this.isEditUser = false;
// this.exportPublicMethods({})
}
/**
'user-name': user['user-name'],
'user-domain': user['user-domain'],
platformRoles: user.platformRoles || this.platformRoles,
- disabled: user.disabled || this.disabled,
- projectRoles: user.projectRoles || this.projectRoles
+ disabled: user.hasOwnProperty('disabled').toString().toUpperCase(),
+ projectRoles: user.projectRoles || this.projectRoles,
+ currentPassword: user.password
}
let state = _.merge({
activeIndex: userIndex,
}
editUser(isEdit) {
this.setState({
+ isEditUser: !isEdit,
isReadOnly: isEdit
})
}
resetUser() {
let username = '';
let domain = 'system';
- let disabled = false;
+ let disabled = "FALSE";
let platformRoles = {
super_admin: false,
platform_admin: false,
}
handleCreateUser() {
+ }
+ handleDisabledChange(value) {
+ this.disabled = value;
}
handleUpdateUser() {