This is an automated email from the ASF dual-hosted git repository. danhaywood pushed a commit to branch v2 in repository https://gitbox.apache.org/repos/asf/causeway-app-petclinic.git
commit 711e0571752986f2f251197f8570ce092922a250 Author: Dan Haywood <[email protected]> AuthorDate: Sun May 26 09:18:26 2024 +0100 updates PetOwner#emailAddress to use new value type Changes optionality of EmailAddress --- .../java/domainapp/modules/petowner/dom/petowner/PetOwner.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/module-petowner/src/main/java/domainapp/modules/petowner/dom/petowner/PetOwner.java b/module-petowner/src/main/java/domainapp/modules/petowner/dom/petowner/PetOwner.java index 4cbe325..60fa583 100644 --- a/module-petowner/src/main/java/domainapp/modules/petowner/dom/petowner/PetOwner.java +++ b/module-petowner/src/main/java/domainapp/modules/petowner/dom/petowner/PetOwner.java @@ -65,6 +65,8 @@ import domainapp.modules.petowner.types.Notes; import domainapp.modules.petowner.types.PhoneNumber; +import domainapp.modules.petowner.value.EmailAddress; + import lombok.AccessLevel; import lombok.Getter; import lombok.NoArgsConstructor; @@ -147,11 +149,11 @@ public class PetOwner implements Comparable<PetOwner>, CalendarEventable { @PropertyLayout(fieldSetId = "contact", sequence = "1.1") private String telephoneNumber; - @Column(length = 40, nullable = true, name = "emailAddress") + @javax.persistence.Embedded @Getter @Setter - @Property(editing = Editing.ENABLED) + @Property(editing = Editing.ENABLED, optionality = Optionality.OPTIONAL) @PropertyLayout(fieldSetId = "contact", sequence = "1.2") - private String emailAddress; + private EmailAddress emailAddress; @Notes @Column(length = Notes.MAX_LEN, nullable = true)
