From eeda02632ea0260f9806ae53cf4fa24d1abaacd4 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Thu, 23 Apr 2020 21:49:49 +0200 Subject: [PATCH] Continued: - sorted members MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../model/bonus_card/RoyalityCard.java | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/src/org/mxchange/jbonuscard/model/bonus_card/RoyalityCard.java b/src/org/mxchange/jbonuscard/model/bonus_card/RoyalityCard.java index c3a6e06..478aded 100644 --- a/src/org/mxchange/jbonuscard/model/bonus_card/RoyalityCard.java +++ b/src/org/mxchange/jbonuscard/model/bonus_card/RoyalityCard.java @@ -75,6 +75,13 @@ public class RoyalityCard implements BonusCard { @OneToOne (targetEntity = UserContact.class, cascade = CascadeType.REFRESH, optional = false) private Contact bonusCardContact; + /** + * Bonus card customer id + */ + @JoinColumn (name = "bonus_card_customer_id", referencedColumnName = "customer_id") + @OneToOne (targetEntity = ContactCustomer.class, cascade = CascadeType.REFRESH) + private Customer bonusCardCustomer; + /** * When this entry has been created */ @@ -90,13 +97,6 @@ public class RoyalityCard implements BonusCard { @Temporal (TemporalType.TIMESTAMP) private Date bonusCardEntryUpdated; - /** - * Bonus card customer id - */ - @JoinColumn (name = "bonus_card_customer_id", referencedColumnName = "customer_id") - @OneToOne (targetEntity = ContactCustomer.class, cascade = CascadeType.REFRESH) - private Customer bonusCardCustomer; - /** * Id number */ @@ -252,25 +252,25 @@ public class RoyalityCard implements BonusCard { } @Override - @SuppressWarnings ("ReturnOfDateField") - public Date getBonusCardEntryCreated () { - return this.bonusCardEntryCreated; + public Customer getBonusCardCustomer () { + return this.bonusCardCustomer; } @Override - @SuppressWarnings ("AssignmentToDateFieldFromParameter") - public void setBonusCardEntryCreated (final Date bonusCardEntryCreated) { - this.bonusCardEntryCreated = bonusCardEntryCreated; + public void setBonusCardCustomer (final Customer bonusCardCustomer) { + this.bonusCardCustomer = bonusCardCustomer; } @Override - public Customer getBonusCardCustomer () { - return this.bonusCardCustomer; + @SuppressWarnings ("ReturnOfDateField") + public Date getBonusCardEntryCreated () { + return this.bonusCardEntryCreated; } @Override - public void setBonusCardCustomer (final Customer bonusCardCustomer) { - this.bonusCardCustomer = bonusCardCustomer; + @SuppressWarnings ("AssignmentToDateFieldFromParameter") + public void setBonusCardEntryCreated (final Date bonusCardEntryCreated) { + this.bonusCardEntryCreated = bonusCardEntryCreated; } @Override -- 2.39.5