You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2021/05/05 06:30:24 UTC
[isis] 02/03: ISIS-2619: reconciled annotations vs layouts for
ApplicationUser
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch ISIS-2619
in repository https://gitbox.apache.org/repos/asf/isis.git
commit 5a3a2e2ffccb528e20dabaff32628a820a6e47d3
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Wed May 5 06:57:58 2021 +0100
ISIS-2619: reconciled annotations vs layouts for ApplicationUser
---
.../secman/api/user/ApplicationUser.java | 134 ++++++++++-------
.../secman/jdo/dom/user/ApplicationUser.java | 129 +++++++++-------
.../dom/user/ApplicationUser.layout.fallback.xml | 165 +++++++++------------
.../secman/jpa/dom/user/ApplicationUser.java | 123 ++++++++-------
.../dom/user/ApplicationUser.layout.fallback.xml | 134 +++++++++--------
5 files changed, 374 insertions(+), 311 deletions(-)
diff --git a/extensions/security/secman/api/src/main/java/org/apache/isis/extensions/secman/api/user/ApplicationUser.java b/extensions/security/secman/api/src/main/java/org/apache/isis/extensions/secman/api/user/ApplicationUser.java
index 3e95d2c..d29fd62 100644
--- a/extensions/security/secman/api/src/main/java/org/apache/isis/extensions/secman/api/user/ApplicationUser.java
+++ b/extensions/security/secman/api/src/main/java/org/apache/isis/extensions/secman/api/user/ApplicationUser.java
@@ -95,14 +95,63 @@ public interface ApplicationUser extends HasUsername, HasAtPath {
maxLength = MAX_LENGTH_USERNAME
)
@PropertyLayout(
- hidden=Where.PARENTED_TABLES,
fieldSetId="identity",
- sequence = "1")
+ sequence = "1"
+ )
@Override
String getUsername();
void setUsername(String username);
+ // -- accountType (property)
+
+ class AccountTypeDomainEvent extends PropertyDomainEvent<AccountType> {}
+
+ @Property(
+ domainEvent = AccountTypeDomainEvent.class,
+ editing = Editing.DISABLED
+ )
+ @PropertyLayout(
+ fieldSetId="status",
+ sequence = "1"
+ )
+ AccountType getAccountType();
+ void setAccountType(AccountType accountType);
+
+
+ // -- status (property)
+
+ class StatusDomainEvent extends PropertyDomainEvent<ApplicationUserStatus> {}
+
+ @Property(
+ domainEvent = StatusDomainEvent.class,
+ editing = Editing.DISABLED
+ )
+ @PropertyLayout(
+ fieldSetId="status",
+ sequence = "2"
+ )
+ ApplicationUserStatus getStatus();
+ void setStatus(ApplicationUserStatus disabled);
+
+
+ // -- atPath (property)
+
+ class AtPathDomainEvent extends PropertyDomainEvent<String> {}
+
+ @Property(
+ domainEvent = AtPathDomainEvent.class,
+ editing = Editing.DISABLED,
+ maxLength = MAX_LENGTH_AT_PATH
+ )
+ @PropertyLayout(
+ fieldSetId="status",
+ sequence = "3"
+ )
+ @Override
+ String getAtPath();
+ void setAtPath(String atPath);
+
// -- familyName (property)
class FamilyNameDomainEvent extends PropertyDomainEvent<String> {}
@@ -114,8 +163,9 @@ public interface ApplicationUser extends HasUsername, HasAtPath {
)
@PropertyLayout(
hidden=Where.ALL_TABLES,
- fieldSetId="Name",
- sequence = "2.1")
+ fieldSetId="name",
+ sequence = "1"
+ )
String getFamilyName();
void setFamilyName(String familyName);
@@ -131,8 +181,9 @@ public interface ApplicationUser extends HasUsername, HasAtPath {
)
@PropertyLayout(
hidden=Where.ALL_TABLES,
- fieldSetId="Name",
- sequence = "2.2")
+ fieldSetId="name",
+ sequence = "2"
+ )
String getGivenName();
void setGivenName(String givenName);
@@ -148,8 +199,9 @@ public interface ApplicationUser extends HasUsername, HasAtPath {
)
@PropertyLayout(
hidden=Where.ALL_TABLES,
- fieldSetId="Name",
- sequence = "2.3")
+ fieldSetId="name",
+ sequence = "3"
+ )
String getKnownAs();
void setKnownAs(String knownAs);
@@ -163,7 +215,10 @@ public interface ApplicationUser extends HasUsername, HasAtPath {
editing = Editing.DISABLED,
maxLength = MAX_LENGTH_EMAIL_ADDRESS
)
- @PropertyLayout(fieldSetId="Contact Details", sequence = "3.1")
+ @PropertyLayout(
+ fieldSetId="contactDetails",
+ sequence = "1"
+ )
String getEmailAddress();
void setEmailAddress(String emailAddress);
@@ -177,7 +232,11 @@ public interface ApplicationUser extends HasUsername, HasAtPath {
editing = Editing.DISABLED,
maxLength = MAX_LENGTH_PHONE_NUMBER
)
- @PropertyLayout(fieldSetId="Contact Details", sequence = "3.2")
+ @PropertyLayout(
+ hidden = Where.PARENTED_TABLES,
+ fieldSetId="contactDetails",
+ sequence = "2"
+ )
String getPhoneNumber();
void setPhoneNumber(String phoneNumber);
@@ -192,53 +251,14 @@ public interface ApplicationUser extends HasUsername, HasAtPath {
maxLength = MAX_LENGTH_PHONE_NUMBER
)
@PropertyLayout(
- hidden=Where.PARENTED_TABLES,
- fieldSetId="Contact Details",
- sequence = "3.3")
+ hidden=Where.ALL_TABLES,
+ fieldSetId="contactDetails",
+ sequence = "3"
+ )
String getFaxNumber();
void setFaxNumber(String faxNumber);
- // -- atPath (property)
-
- class AtPathDomainEvent extends PropertyDomainEvent<String> {}
-
- @Property(
- domainEvent = AtPathDomainEvent.class,
- editing = Editing.DISABLED,
- maxLength = MAX_LENGTH_AT_PATH
- )
- @PropertyLayout(fieldSetId="atPath", sequence = "3.4")
- @Override
- String getAtPath();
- void setAtPath(String atPath);
-
- // -- accountType (property)
-
- class AccountTypeDomainEvent extends PropertyDomainEvent<AccountType> {}
-
- @Property(
- domainEvent = AccountTypeDomainEvent.class,
- editing = Editing.DISABLED
- )
- @PropertyLayout(fieldSetId="Status", sequence = "3")
- AccountType getAccountType();
- void setAccountType(AccountType accountType);
-
-
- // -- status (property)
-
- class StatusDomainEvent extends PropertyDomainEvent<ApplicationUserStatus> {}
-
- @Property(
- domainEvent = StatusDomainEvent.class,
- editing = Editing.DISABLED
- )
- @PropertyLayout(fieldSetId="Status", sequence = "4")
- ApplicationUserStatus getStatus();
- void setStatus(ApplicationUserStatus disabled);
-
-
// -- encryptedPassword (hidden property)
@PropertyLayout(hidden=Where.EVERYWHERE)
@@ -255,7 +275,10 @@ public interface ApplicationUser extends HasUsername, HasAtPath {
domainEvent = HasPasswordDomainEvent.class,
editing = Editing.DISABLED
)
- @PropertyLayout(fieldSetId="Status", sequence = "4")
+ @PropertyLayout(
+ fieldSetId="password",
+ sequence = "1"
+ )
default boolean isHasPassword() {
return _Strings.isNotEmpty(getEncryptedPassword());
}
@@ -292,7 +315,8 @@ public interface ApplicationUser extends HasUsername, HasAtPath {
)
@CollectionLayout(
defaultView="table",
- sequence = "20")
+ sequence = "20"
+ )
Set<? extends ApplicationRole> getRoles();
diff --git a/extensions/security/secman/persistence-jdo/src/main/java/org/apache/isis/extensions/secman/jdo/dom/user/ApplicationUser.java b/extensions/security/secman/persistence-jdo/src/main/java/org/apache/isis/extensions/secman/jdo/dom/user/ApplicationUser.java
index 4ea2885..d7acfae 100644
--- a/extensions/security/secman/persistence-jdo/src/main/java/org/apache/isis/extensions/secman/jdo/dom/user/ApplicationUser.java
+++ b/extensions/security/secman/persistence-jdo/src/main/java/org/apache/isis/extensions/secman/jdo/dom/user/ApplicationUser.java
@@ -142,14 +142,60 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
maxLength = MAX_LENGTH_USERNAME
)
@PropertyLayout(
- hidden=Where.PARENTED_TABLES,
- fieldSetId="Id",
- sequence = "1")
+ fieldSetId="identity",
+ sequence = "1"
+ )
@javax.jdo.annotations.Column(allowsNull="false", length = MAX_LENGTH_USERNAME)
@Getter @Setter
private String username;
+ // -- accountType (property)
+
+ @Property(
+ domainEvent = AccountTypeDomainEvent.class,
+ editing = Editing.DISABLED
+ )
+ @PropertyLayout(
+ fieldSetId="status",
+ sequence = "1"
+ )
+ @javax.jdo.annotations.Column(allowsNull="false")
+ @Getter @Setter
+ private AccountType accountType;
+
+
+ // -- status (property)
+
+ @Property(
+ domainEvent = StatusDomainEvent.class,
+ editing = Editing.DISABLED
+ )
+ @PropertyLayout(
+ fieldSetId="status",
+ sequence = "2"
+ )
+ @javax.jdo.annotations.Column(allowsNull="false")
+ @Getter @Setter
+ private ApplicationUserStatus status;
+
+
+ // -- atPath (property)
+
+ @Property(
+ domainEvent = AtPathDomainEvent.class,
+ editing = Editing.DISABLED,
+ maxLength = MAX_LENGTH_AT_PATH
+ )
+ @PropertyLayout(
+ fieldSetId="status",
+ sequence = "3"
+ )
+ @javax.jdo.annotations.Column(name = "atPath", allowsNull="true", length = MAX_LENGTH_AT_PATH)
+ @Getter @Setter
+ private String atPath;
+
+
// -- familyName (property)
@Property(
@@ -159,8 +205,9 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
)
@PropertyLayout(
hidden=Where.ALL_TABLES,
- fieldSetId="Name",
- sequence = "2.1")
+ fieldSetId="name",
+ sequence = "1"
+ )
@javax.jdo.annotations.Column(allowsNull="true", length = MAX_LENGTH_FAMILY_NAME)
@Getter @Setter
private String familyName;
@@ -175,8 +222,9 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
)
@PropertyLayout(
hidden=Where.ALL_TABLES,
- fieldSetId="Name",
- sequence = "2.2")
+ fieldSetId="name",
+ sequence = "2"
+ )
@javax.jdo.annotations.Column(allowsNull="true", length = MAX_LENGTH_GIVEN_NAME)
@Getter @Setter
private String givenName;
@@ -191,8 +239,9 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
)
@PropertyLayout(
hidden=Where.ALL_TABLES,
- fieldSetId="Name",
- sequence = "2.3")
+ fieldSetId="name",
+ sequence = "3"
+ )
@javax.jdo.annotations.Column(allowsNull="true", length = MAX_LENGTH_KNOWN_AS)
@Getter @Setter
private String knownAs;
@@ -205,7 +254,10 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
editing = Editing.DISABLED,
maxLength = MAX_LENGTH_EMAIL_ADDRESS
)
- @PropertyLayout(fieldSetId="Contact Details", sequence = "3.1")
+ @PropertyLayout(
+ fieldSetId="contactDetails",
+ sequence = "1"
+ )
@javax.jdo.annotations.Column(allowsNull="true", length = MAX_LENGTH_EMAIL_ADDRESS)
@Getter @Setter
private String emailAddress;
@@ -218,7 +270,11 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
editing = Editing.DISABLED,
maxLength = MAX_LENGTH_PHONE_NUMBER
)
- @PropertyLayout(fieldSetId="Contact Details", sequence = "3.2")
+ @PropertyLayout(
+ hidden = Where.PARENTED_TABLES,
+ fieldSetId="contactDetails",
+ sequence = "2"
+ )
@javax.jdo.annotations.Column(allowsNull="true", length = MAX_LENGTH_PHONE_NUMBER)
@Getter @Setter
private String phoneNumber;
@@ -232,50 +288,15 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
maxLength = MAX_LENGTH_PHONE_NUMBER
)
@PropertyLayout(
- hidden=Where.PARENTED_TABLES,
- fieldSetId="Contact Details",
- sequence = "3.3")
+ hidden=Where.ALL_TABLES,
+ fieldSetId="contactDetails",
+ sequence = "3"
+ )
@javax.jdo.annotations.Column(allowsNull="true", length = MAX_LENGTH_PHONE_NUMBER)
@Getter @Setter
private String faxNumber;
- // -- atPath (property)
-
- @Property(
- domainEvent = AtPathDomainEvent.class,
- editing = Editing.DISABLED,
- maxLength = MAX_LENGTH_AT_PATH
- )
- @PropertyLayout(fieldSetId="atPath", sequence = "3.4")
- @javax.jdo.annotations.Column(name = "atPath", allowsNull="true", length = MAX_LENGTH_AT_PATH)
- @Getter @Setter
- private String atPath;
-
- // -- accountType (property)
-
- @Property(
- domainEvent = AccountTypeDomainEvent.class,
- editing = Editing.DISABLED
- )
- @PropertyLayout(fieldSetId="Status", sequence = "3")
- @javax.jdo.annotations.Column(allowsNull="false")
- @Getter @Setter
- private AccountType accountType;
-
-
- // -- status (property)
-
- @Property(
- domainEvent = StatusDomainEvent.class,
- editing = Editing.DISABLED
- )
- @PropertyLayout(fieldSetId="Status", sequence = "4")
- @javax.jdo.annotations.Column(allowsNull="false")
- @Getter @Setter
- private ApplicationUserStatus status;
-
-
// -- encryptedPassword (hidden property)
@PropertyLayout(hidden=Where.EVERYWHERE)
@@ -291,7 +312,10 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
domainEvent = HasPasswordDomainEvent.class,
editing = Editing.DISABLED
)
- @PropertyLayout(fieldSetId="Status", sequence = "4")
+ @PropertyLayout(
+ fieldSetId="password",
+ sequence = "1"
+ )
@Override
public boolean isHasPassword() {
return org.apache.isis.extensions.secman.api.user.ApplicationUser.super.isHasPassword();
@@ -305,7 +329,8 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
)
@CollectionLayout(
defaultView="table",
- sequence = "20")
+ sequence = "20"
+ )
@javax.jdo.annotations.Persistent(table="ApplicationUserRoles")
@javax.jdo.annotations.Join(column="userId")
@javax.jdo.annotations.Element(column="roleId")
diff --git a/extensions/security/secman/persistence-jdo/src/main/java/org/apache/isis/extensions/secman/jdo/dom/user/ApplicationUser.layout.fallback.xml b/extensions/security/secman/persistence-jdo/src/main/java/org/apache/isis/extensions/secman/jdo/dom/user/ApplicationUser.layout.fallback.xml
index 59f3058..ad58077 100644
--- a/extensions/security/secman/persistence-jdo/src/main/java/org/apache/isis/extensions/secman/jdo/dom/user/ApplicationUser.layout.fallback.xml
+++ b/extensions/security/secman/persistence-jdo/src/main/java/org/apache/isis/extensions/secman/jdo/dom/user/ApplicationUser.layout.fallback.xml
@@ -27,101 +27,80 @@ under the License.
</bs3:row>
<bs3:row>
<bs3:col span="3">
- <bs3:row>
- <bs3:col span="12">
- <bs3:tabGroup>
- <bs3:tab name="Identity">
- <bs3:row>
- <bs3:col span="12">
- <cpt:fieldSet name="Identity" id="identity"/>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- <bs3:tab name="Other">
- <bs3:row>
- <bs3:col span="12">
- <cpt:fieldSet name="Other" id="other" unreferencedProperties="true"/>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- <bs3:tab name="Metadata">
- <bs3:row>
- <bs3:col span="12">
- <cpt:fieldSet name="Metadata" id="metadata">
- <cpt:property id="objectType"/>
- <cpt:property id="objectIdentifier"/>
- <cpt:property id="datanucleusVersionLong"/>
- <cpt:property id="datanucleusVersionTimestamp"/>
- </cpt:fieldSet>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- </bs3:tabGroup>
- </bs3:col>
- </bs3:row>
- <cpt:fieldSet name="Status" id="status">
- <cpt:property id="accountType"/>
- <cpt:property id="status"/>
- <cpt:property id="atPath"/>
- </cpt:fieldSet>
+ <bs3:row>
+ <bs3:col span="12">
+ <bs3:tabGroup>
+ <bs3:tab name="Identity">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Identity" id="identity"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ <bs3:tab name="Other">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Other" id="other" unreferencedProperties="true"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ <bs3:tab name="Metadata">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Metadata" id="metadata"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ </bs3:tabGroup>
+ </bs3:col>
+ </bs3:row>
+ <cpt:fieldSet name="Status" id="status"/>
+ </bs3:col>
+ <bs3:col span="3">
+ <bs3:tabGroup>
+ <bs3:tab name="Name">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Name" id="name"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ <bs3:tab name="Contact Details">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Contact Details" id="contactDetails"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ </bs3:tabGroup>
+ <cpt:fieldSet name="Password" id="password"/>
</bs3:col>
- <bs3:col span="3">
- <bs3:tabGroup>
- <bs3:tab name="Name">
- <bs3:row>
- <bs3:col span="12">
- <cpt:fieldSet name="Name" id="name">
- <cpt:property id="familyName">
- <cpt:action id="updateName"/>
- </cpt:property>
- <cpt:property id="givenName"/>
- <cpt:property id="knownAs"/>
- </cpt:fieldSet>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- <bs3:tab name="Contact Details">
- <bs3:row>
- <bs3:col span="12">
- <cpt:fieldSet name="Contact Details" id="contactDetails">
- <cpt:property id="emailAddress"/>
- <cpt:property id="phoneNumber"/>
- <cpt:property id="faxNumber"/>
- </cpt:fieldSet>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- </bs3:tabGroup>
- <cpt:fieldSet name="Password" id="password">
- <cpt:property id="hasPassword"/>
- </cpt:fieldSet>
- </bs3:col>
<bs3:col span="6">
- <bs3:row>
- <bs3:col span="12">
- <bs3:tabGroup>
- <bs3:tab name="Roles">
- <bs3:row>
- <bs3:col span="12">
- <cpt:collection id="roles"/>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- <bs3:tab name="Permissions">
- <bs3:row>
- <bs3:col span="12">
- <cpt:collection id="permissions"/>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- </bs3:tabGroup>
- </bs3:col>
- </bs3:row>
+ <bs3:row>
+ <bs3:col span="12">
+ <bs3:tabGroup>
+ <bs3:tab name="Roles">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:collection id="roles"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ <bs3:tab name="Permissions">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:collection id="permissions"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ </bs3:tabGroup>
+ </bs3:col>
+ </bs3:row>
+ </bs3:col>
+ </bs3:row>
+ <bs3:row>
+ <bs3:col span="12">
+ <bs3:tabGroup unreferencedCollections="true"/>
</bs3:col>
</bs3:row>
- <bs3:row>
- <bs3:col span="12">
- <bs3:tabGroup unreferencedCollections="true"/>
- </bs3:col>
- </bs3:row>
</bs3:grid>
diff --git a/extensions/security/secman/persistence-jpa/src/main/java/org/apache/isis/extensions/secman/jpa/dom/user/ApplicationUser.java b/extensions/security/secman/persistence-jpa/src/main/java/org/apache/isis/extensions/secman/jpa/dom/user/ApplicationUser.java
index b14455d..a0a570e 100644
--- a/extensions/security/secman/persistence-jpa/src/main/java/org/apache/isis/extensions/secman/jpa/dom/user/ApplicationUser.java
+++ b/extensions/security/secman/persistence-jpa/src/main/java/org/apache/isis/extensions/secman/jpa/dom/user/ApplicationUser.java
@@ -133,6 +133,7 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
@Inject private transient PermissionsEvaluationService permissionsEvaluationService;
@Inject private transient SecmanConfiguration configBean;
+
@Id
@GeneratedValue
private Long id;
@@ -149,14 +150,62 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
maxLength = MAX_LENGTH_USERNAME
)
@PropertyLayout(
- hidden=Where.PARENTED_TABLES,
- fieldSetId="Id",
- sequence = "1")
+ fieldSetId="identity",
+ sequence = "1"
+ )
@Column(nullable=false, length=MAX_LENGTH_USERNAME)
@Getter @Setter
private String username;
+ // -- accountType (property)
+
+ @Property(
+ domainEvent = AccountTypeDomainEvent.class,
+ editing = Editing.DISABLED
+ )
+ @PropertyLayout(
+ fieldSetId="status",
+ sequence = "1"
+ )
+ @Column(nullable=false)
+ @Enumerated(EnumType.STRING)
+ @Getter @Setter
+ private AccountType accountType;
+
+
+ // -- status (property)
+
+ @Property(
+ domainEvent = StatusDomainEvent.class,
+ editing = Editing.DISABLED
+ )
+ @PropertyLayout(
+ fieldSetId="status",
+ sequence = "2"
+ )
+ @Column(nullable=false)
+ @Enumerated(EnumType.STRING)
+ @Getter @Setter
+ private ApplicationUserStatus status;
+
+
+ // -- atPath (property)
+
+ @Property(
+ domainEvent = AtPathDomainEvent.class,
+ editing = Editing.DISABLED,
+ maxLength = MAX_LENGTH_AT_PATH
+ )
+ @PropertyLayout(
+ fieldSetId="atPath",
+ sequence = "3"
+ )
+ @Column(name="atPath", nullable=true, length = MAX_LENGTH_AT_PATH)
+ @Getter @Setter
+ private String atPath;
+
+
// -- familyName (property)
@Property(
@@ -166,8 +215,9 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
)
@PropertyLayout(
hidden=Where.ALL_TABLES,
- fieldSetId="Name",
- sequence = "2.1")
+ fieldSetId="name",
+ sequence = "1"
+ )
@Column(nullable=true, length=MAX_LENGTH_FAMILY_NAME)
@Getter @Setter
private String familyName;
@@ -182,8 +232,9 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
)
@PropertyLayout(
hidden=Where.ALL_TABLES,
- fieldSetId="Name",
- sequence = "2.2")
+ fieldSetId="name",
+ sequence = "2"
+ )
@Column(nullable=true, length=MAX_LENGTH_GIVEN_NAME)
@Getter @Setter
private String givenName;
@@ -198,8 +249,9 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
)
@PropertyLayout(
hidden=Where.ALL_TABLES,
- fieldSetId="Name",
- sequence = "2.3")
+ fieldSetId="name",
+ sequence = "3"
+ )
@Column(nullable=true, length=MAX_LENGTH_KNOWN_AS)
@Getter @Setter
private String knownAs;
@@ -212,7 +264,10 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
editing = Editing.DISABLED,
maxLength = MAX_LENGTH_EMAIL_ADDRESS
)
- @PropertyLayout(fieldSetId="Contact Details", sequence = "3.1")
+ @PropertyLayout(
+ fieldSetId="contactDetails",
+ sequence = "1"
+ )
@Column(nullable=true, length=MAX_LENGTH_EMAIL_ADDRESS)
@Getter @Setter
private String emailAddress;
@@ -225,7 +280,10 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
editing = Editing.DISABLED,
maxLength = MAX_LENGTH_PHONE_NUMBER
)
- @PropertyLayout(fieldSetId="Contact Details", sequence = "3.2")
+ @PropertyLayout(
+ fieldSetId="contactDetails",
+ sequence = "2"
+ )
@Column(nullable=true, length=MAX_LENGTH_PHONE_NUMBER)
@Getter @Setter
private String phoneNumber;
@@ -240,51 +298,14 @@ org.apache.isis.extensions.secman.api.user.ApplicationUser {
)
@PropertyLayout(
hidden=Where.PARENTED_TABLES,
- fieldSetId="Contact Details",
- sequence = "3.3")
+ fieldSetId="contactDetails",
+ sequence = "3"
+ )
@Column(nullable=true, length=MAX_LENGTH_PHONE_NUMBER)
@Getter @Setter
private String faxNumber;
- // -- atPath (property)
-
- @Property(
- domainEvent = AtPathDomainEvent.class,
- editing = Editing.DISABLED,
- maxLength = MAX_LENGTH_AT_PATH
- )
- @PropertyLayout(fieldSetId="atPath", sequence = "3.4")
- @Column(name="atPath", nullable=true, length = MAX_LENGTH_AT_PATH)
- @Getter @Setter
- private String atPath;
-
- // -- accountType (property)
-
- @Property(
- domainEvent = AccountTypeDomainEvent.class,
- editing = Editing.DISABLED
- )
- @PropertyLayout(fieldSetId="Status", sequence = "3")
- @Column(nullable=false)
- @Enumerated(EnumType.STRING)
- @Getter @Setter
- private AccountType accountType;
-
-
- // -- status (property)
-
- @Property(
- domainEvent = StatusDomainEvent.class,
- editing = Editing.DISABLED
- )
- @PropertyLayout(fieldSetId="Status", sequence = "4")
- @Column(nullable=false)
- @Enumerated(EnumType.STRING)
- @Getter @Setter
- private ApplicationUserStatus status;
-
-
// -- encryptedPassword (hidden property)
@PropertyLayout(hidden=Where.EVERYWHERE)
diff --git a/extensions/security/secman/persistence-jpa/src/main/java/org/apache/isis/extensions/secman/jpa/dom/user/ApplicationUser.layout.fallback.xml b/extensions/security/secman/persistence-jpa/src/main/java/org/apache/isis/extensions/secman/jpa/dom/user/ApplicationUser.layout.fallback.xml
index 9a6256d..ad58077 100644
--- a/extensions/security/secman/persistence-jpa/src/main/java/org/apache/isis/extensions/secman/jpa/dom/user/ApplicationUser.layout.fallback.xml
+++ b/extensions/security/secman/persistence-jpa/src/main/java/org/apache/isis/extensions/secman/jpa/dom/user/ApplicationUser.layout.fallback.xml
@@ -26,67 +26,81 @@ under the License.
</bs3:col>
</bs3:row>
<bs3:row>
- <bs3:col span="4">
- <cpt:fieldSet name="Id" id="id" unreferencedProperties="true">
- <cpt:property id="name"/>
- <cpt:property id="username"/>
- <cpt:property id="encryptedPassword"/>
- </cpt:fieldSet>
- <cpt:fieldSet name="Status" id="status">
- <cpt:property id="accountType"/>
- <cpt:property id="hasPassword"/>
- <cpt:property id="status"/>
- <cpt:property id="atPath"/>
- </cpt:fieldSet>
- <cpt:fieldSet name="Metadata" id="metadata">
- <cpt:property id="datanucleusVersionLong"/>
- <cpt:property id="datanucleusVersionTimestamp"/>
- </cpt:fieldSet>
+ <bs3:col span="3">
+ <bs3:row>
+ <bs3:col span="12">
+ <bs3:tabGroup>
+ <bs3:tab name="Identity">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Identity" id="identity"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ <bs3:tab name="Other">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Other" id="other" unreferencedProperties="true"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ <bs3:tab name="Metadata">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Metadata" id="metadata"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ </bs3:tabGroup>
+ </bs3:col>
+ </bs3:row>
+ <cpt:fieldSet name="Status" id="status"/>
</bs3:col>
- <bs3:col span="8">
- <bs3:row>
- <bs3:col span="12">
- <bs3:tabGroup>
- <bs3:tab name="Name and Contact Details">
- <bs3:row>
- <bs3:col span="6">
- <cpt:fieldSet name="Contact Details" id="contactDetails">
- <cpt:property id="emailAddress"/>
- <cpt:property id="phoneNumber"/>
- <cpt:property id="faxNumber"/>
- </cpt:fieldSet>
- </bs3:col>
- <bs3:col span="6">
- <cpt:fieldSet name="Name" id="name">
- <cpt:property id="familyName"/>
- <cpt:property id="givenName"/>
- <cpt:property id="knownAs"/>
- </cpt:fieldSet>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- <bs3:tab name="Roles">
- <bs3:row>
- <bs3:col span="12">
- <cpt:collection id="roles"/>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- <bs3:tab name="Permissions">
- <bs3:row>
- <bs3:col span="12">
- <cpt:collection id="permissions"/>
- </bs3:col>
- </bs3:row>
- </bs3:tab>
- <bs3:tab name="Other">
- <bs3:row>
- <bs3:col span="12" unreferencedCollections="true" />
- </bs3:row>
- </bs3:tab>
- </bs3:tabGroup>
- </bs3:col>
- </bs3:row>
+ <bs3:col span="3">
+ <bs3:tabGroup>
+ <bs3:tab name="Name">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Name" id="name"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ <bs3:tab name="Contact Details">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:fieldSet name="Contact Details" id="contactDetails"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ </bs3:tabGroup>
+ <cpt:fieldSet name="Password" id="password"/>
+ </bs3:col>
+ <bs3:col span="6">
+ <bs3:row>
+ <bs3:col span="12">
+ <bs3:tabGroup>
+ <bs3:tab name="Roles">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:collection id="roles"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ <bs3:tab name="Permissions">
+ <bs3:row>
+ <bs3:col span="12">
+ <cpt:collection id="permissions"/>
+ </bs3:col>
+ </bs3:row>
+ </bs3:tab>
+ </bs3:tabGroup>
+ </bs3:col>
+ </bs3:row>
+ </bs3:col>
+ </bs3:row>
+ <bs3:row>
+ <bs3:col span="12">
+ <bs3:tabGroup unreferencedCollections="true"/>
</bs3:col>
</bs3:row>
</bs3:grid>