From: Roland Häder Date: Sun, 23 Jul 2017 13:54:43 +0000 (+0200) Subject: BusinessBasicData is now the "super entity" (whole company). X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=45e2e498ac5ff1ba87e077684d9e948928ca1b2a;p=jfinancials-core.git BusinessBasicData is now the "super entity" (whole company). Signed-off-by: Roland Häder --- diff --git a/src/org/mxchange/jfinancials/model/receipt/BillableReceipt.java b/src/org/mxchange/jfinancials/model/receipt/BillableReceipt.java index e39cf9b..0f111a0 100644 --- a/src/org/mxchange/jfinancials/model/receipt/BillableReceipt.java +++ b/src/org/mxchange/jfinancials/model/receipt/BillableReceipt.java @@ -18,7 +18,7 @@ package org.mxchange.jfinancials.model.receipt; import java.io.Serializable; import java.util.Calendar; -import org.mxchange.jcontactsbusiness.BusinessContact; +import org.mxchange.jcontactsbusiness.BusinessBasicData; import org.mxchange.jproduct.model.payment.PaymentType; import org.mxchange.jusercore.model.user.User; @@ -90,14 +90,14 @@ public interface BillableReceipt extends Serializable { *

* @return Seller instance */ - BusinessContact getReceiptSeller (); + BusinessBasicData getReceiptSeller (); /** * Setter for seller instance *

* @param receiptSeller Seller instance */ - void setReceiptSeller (final BusinessContact receiptSeller); + void setReceiptSeller (final BusinessBasicData receiptSeller); /** * Getter for payment type diff --git a/src/org/mxchange/jfinancials/model/receipt/FinancialReceipt.java b/src/org/mxchange/jfinancials/model/receipt/FinancialReceipt.java index 62b4c29..b24970d 100644 --- a/src/org/mxchange/jfinancials/model/receipt/FinancialReceipt.java +++ b/src/org/mxchange/jfinancials/model/receipt/FinancialReceipt.java @@ -33,8 +33,8 @@ import javax.persistence.Table; import javax.persistence.Temporal; import javax.persistence.TemporalType; import javax.persistence.Transient; -import org.mxchange.jcontactsbusiness.BusinessContact; -import org.mxchange.jcontactsbusiness.CompanyContact; +import org.mxchange.jcontactsbusiness.BusinessBasicData; +import org.mxchange.jcontactsbusiness.CompanyBasicData; import org.mxchange.jproduct.model.payment.PaymentType; import org.mxchange.jusercore.model.user.LoginUser; import org.mxchange.jusercore.model.user.User; @@ -92,8 +92,8 @@ public class FinancialReceipt implements BillableReceipt { * Seller instance */ @JoinColumn (name = "receipt_seller_id", referencedColumnName = "business_contact_id", nullable = false, updatable = false) - @OneToOne (targetEntity = CompanyContact.class, cascade = CascadeType.REFRESH, optional = false) - private BusinessContact receiptSeller; + @OneToOne (targetEntity = CompanyBasicData.class, cascade = CascadeType.REFRESH, optional = false) + private BusinessBasicData receiptSeller; /** * Which user this receipt belongs to @@ -116,7 +116,7 @@ public class FinancialReceipt implements BillableReceipt { * @param receiptUser User instance * @param receiptIssued When this receipt has been issued */ - public FinancialReceipt (final PaymentType receiptPaymentType, final BusinessContact receiptSeller, final User receiptUser, final Calendar receiptIssued) { + public FinancialReceipt (final PaymentType receiptPaymentType, final BusinessBasicData receiptSeller, final User receiptUser, final Calendar receiptIssued) { // Call other constructor first this(); @@ -200,12 +200,12 @@ public class FinancialReceipt implements BillableReceipt { } @Override - public BusinessContact getReceiptSeller () { + public BusinessBasicData getReceiptSeller () { return this.receiptSeller; } @Override - public void setReceiptSeller (final BusinessContact receiptSeller) { + public void setReceiptSeller (final BusinessBasicData receiptSeller) { this.receiptSeller = receiptSeller; }