From f54465f4fdca8f29af0e54d7fff63f268dc332bb Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Fri, 13 Oct 2017 23:35:11 +0200 Subject: [PATCH] Continued: - switched from Calendar to Date as p:calendar does want it MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../model/customer/ContactCustomer.java | 21 +++++++++---------- .../model/customer/Customer.java | 14 ++++++------- 2 files changed, 17 insertions(+), 18 deletions(-) diff --git a/src/org/mxchange/jcustomercore/model/customer/ContactCustomer.java b/src/org/mxchange/jcustomercore/model/customer/ContactCustomer.java index 4b02c44..3e27213 100644 --- a/src/org/mxchange/jcustomercore/model/customer/ContactCustomer.java +++ b/src/org/mxchange/jcustomercore/model/customer/ContactCustomer.java @@ -16,7 +16,7 @@ */ package org.mxchange.jcustomercore.model.customer; -import java.util.Calendar; +import java.util.Date; import java.util.Objects; import javax.persistence.Basic; import javax.persistence.CascadeType; @@ -38,7 +38,6 @@ import javax.persistence.TemporalType; import javax.persistence.Transient; import org.mxchange.jcontacts.model.contact.Contact; import org.mxchange.jcontacts.model.contact.UserContact; -import org.mxchange.jcustomercore.model.customer.Customer; import org.mxchange.jcustomercore.model.customer.status.CustomerAccountStatus; /** @@ -87,7 +86,7 @@ public class ContactCustomer implements Customer { @Basic (optional = false) @Column (name = "customer_created", nullable = false, updatable = false) @Temporal (TemporalType.TIMESTAMP) - private Calendar customerCreated; + private Date customerCreated; /** * Id number for this entry @@ -102,7 +101,7 @@ public class ContactCustomer implements Customer { */ @Column (name = "customer_last_locked") @Temporal (TemporalType.TIMESTAMP) - private Calendar customerLastLocked; + private Date customerLastLocked; /** * Last locked reason @@ -123,7 +122,7 @@ public class ContactCustomer implements Customer { */ @Column (name = "customer_updated") @Temporal (TemporalType.TIMESTAMP) - private Calendar customerUpdated; + private Date customerUpdated; /** * Default constructor @@ -227,13 +226,13 @@ public class ContactCustomer implements Customer { @Override @SuppressWarnings ("ReturnOfDateField") - public Calendar getCustomerCreated () { + public Date getCustomerCreated () { return this.customerCreated; } @Override @SuppressWarnings ("AssignmentToDateFieldFromParameter") - public void setCustomerCreated (final Calendar customerCreated) { + public void setCustomerCreated (final Date customerCreated) { this.customerCreated = customerCreated; } @@ -249,13 +248,13 @@ public class ContactCustomer implements Customer { @Override @SuppressWarnings ("ReturnOfDateField") - public Calendar getCustomerLastLocked () { + public Date getCustomerLastLocked () { return this.customerLastLocked; } @Override @SuppressWarnings ("AssignmentToDateFieldFromParameter") - public void setCustomerLastLocked (final Calendar customerLastLocked) { + public void setCustomerLastLocked (final Date customerLastLocked) { this.customerLastLocked = customerLastLocked; } @@ -291,13 +290,13 @@ public class ContactCustomer implements Customer { @Override @SuppressWarnings ("ReturnOfDateField") - public Calendar getCustomerUpdated () { + public Date getCustomerUpdated () { return this.customerUpdated; } @Override @SuppressWarnings ("AssignmentToDateFieldFromParameter") - public void setCustomerUpdated (final Calendar customerUpdated) { + public void setCustomerUpdated (final Date customerUpdated) { this.customerUpdated = customerUpdated; } diff --git a/src/org/mxchange/jcustomercore/model/customer/Customer.java b/src/org/mxchange/jcustomercore/model/customer/Customer.java index ec80cca..583d538 100644 --- a/src/org/mxchange/jcustomercore/model/customer/Customer.java +++ b/src/org/mxchange/jcustomercore/model/customer/Customer.java @@ -17,7 +17,7 @@ package org.mxchange.jcustomercore.model.customer; import java.io.Serializable; -import java.util.Calendar; +import java.util.Date; import org.mxchange.jcontacts.model.contact.Contact; import org.mxchange.jcustomercore.model.customer.status.CustomerAccountStatus; @@ -68,28 +68,28 @@ public interface Customer extends Serializable { *

* @return "created" timestamp */ - Calendar getCustomerCreated (); + Date getCustomerCreated (); /** * Setter for "created" timestamp *

* @param customerCreated "created" timestamp */ - void setCustomerCreated (final Calendar customerCreated); + void setCustomerCreated (final Date customerCreated); /** * Getter for "updated" timestamp *

* @return "updated" timestamp */ - Calendar getCustomerUpdated (); + Date getCustomerUpdated (); /** * Setter for "updated" timestamp *

* @param customerUpdated "updated" timestamp */ - void setCustomerUpdated (final Calendar customerUpdated); + void setCustomerUpdated (final Date customerUpdated); /** * Getter for customer id number @@ -110,14 +110,14 @@ public interface Customer extends Serializable { *

* @return "locked" timestamp */ - Calendar getCustomerLastLocked (); + Date getCustomerLastLocked (); /** * Getter for "locked" timestamp *

* @param customerLocked "locked" timestamp */ - void setCustomerLastLocked (final Calendar customerLocked); + void setCustomerLastLocked (final Date customerLocked); /** * Getter for reason of last locked -- 2.39.5