removes admin flag from user object

This commit is contained in:
Sebastian Sdorra
2019-03-13 12:07:18 +01:00
parent 9d0e3e568a
commit a2f83e2429
12 changed files with 193 additions and 267 deletions

View File

@@ -157,12 +157,6 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
{
boolean result = false;
if (user.isAdmin() != admin)
{
result = true;
user.setAdmin(admin);
}
if (user.isActive() != active)
{
result = true;
@@ -229,7 +223,6 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
&& Objects.equal(displayName, other.displayName)
&& Objects.equal(mail, other.mail)
&& Objects.equal(type, other.type)
&& Objects.equal(admin, other.admin)
&& Objects.equal(active, other.active)
&& Objects.equal(password, other.password)
&& Objects.equal(creationDate, other.creationDate)
@@ -246,7 +239,7 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
@Override
public int hashCode()
{
return Objects.hashCode(name, displayName, mail, type, admin, password,
return Objects.hashCode(name, displayName, mail, type, password,
active, creationDate, lastModified, properties);
}
@@ -269,7 +262,6 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
.add("displayName",displayName)
.add("mail", mail)
.add("password", pwd)
.add("admin", admin)
.add("type", type)
.add("active", active)
.add("creationDate", creationDate)
@@ -385,17 +377,6 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
return active;
}
/**
* Method description
*
*
* @return
*/
public boolean isAdmin()
{
return admin;
}
/**
* Method description
*
@@ -424,17 +405,6 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
this.active = active;
}
/**
* Method description
*
*
* @param admin
*/
public void setAdmin(boolean admin)
{
this.admin = admin;
}
/**
* Method description
*
@@ -518,9 +488,6 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
/** Field description */
private boolean active = true;
/** Field description */
private boolean admin = false;
/** Field description */
private Long creationDate;