import java.io.Serializable;
import java.util.Date;
import org.mxchange.jcontactsbusiness.model.branchoffice.BranchOffice;
-import org.mxchange.jcontactsbusiness.model.employee.Employee;
import org.mxchange.jproduct.model.payment.PaymentType;
import org.mxchange.jusercore.model.user.User;
+import org.mxchange.jcontactsbusiness.model.employee.Employable;
/**
* An interface for receipts
* <p>
* @return Seller (employee)
*/
- Employee getReceiptSellerEmployee ();
+ Employable getReceiptSellerEmployee ();
/**
* Setter for seller (employee)
* <p>
* @param receiptSellerEmployee Seller (employee)
*/
- void setReceiptSellerEmployee (final Employee receiptSellerEmployee);
+ void setReceiptSellerEmployee (final Employable receiptSellerEmployee);
/**
* Getter for receipt number
import javax.persistence.TemporalType;
import javax.persistence.Transient;
import org.mxchange.jcontactsbusiness.model.branchoffice.BranchOffice;
-import org.mxchange.jcontactsbusiness.model.branchoffice.CompanyBranchOffice;
-import org.mxchange.jcontactsbusiness.model.employee.CompanyEmployee;
-import org.mxchange.jcontactsbusiness.model.employee.Employee;
+import org.mxchange.jcontactsbusiness.model.branchoffice.BusinessBranchOffice;
+import org.mxchange.jcontactsbusiness.model.employee.BusinessEmployee;
import org.mxchange.jproduct.model.payment.PaymentType;
import org.mxchange.jusercore.model.user.LoginUser;
import org.mxchange.jusercore.model.user.User;
+import org.mxchange.jcontactsbusiness.model.employee.Employable;
/**
*
* Seller instance
*/
@JoinColumn (name = "receipt_branch_id", referencedColumnName = "branch_id", nullable = false, updatable = false)
- @OneToOne (targetEntity = CompanyBranchOffice.class, cascade = CascadeType.REFRESH, optional = false)
+ @OneToOne (targetEntity = BusinessBranchOffice.class, cascade = CascadeType.REFRESH, optional = false)
private BranchOffice receiptBranchOffice;
/**
* Selling employee instance
*/
@JoinColumn (name = "receipt_seller_id", referencedColumnName = "employee_id")
- @OneToOne (targetEntity = CompanyEmployee.class, cascade = CascadeType.REFRESH)
- private Employee receiptSellerEmployee;
+ @OneToOne (targetEntity = BusinessEmployee.class, cascade = CascadeType.REFRESH)
+ private Employable receiptSellerEmployee;
/**
* Which user this receipt belongs to
}
@Override
- public Employee getReceiptSellerEmployee () {
+ public Employable getReceiptSellerEmployee () {
return this.receiptSellerEmployee;
}
@Override
- public void setReceiptSellerEmployee (final Employee receiptSellerEmployee) {
+ public void setReceiptSellerEmployee (final Employable receiptSellerEmployee) {
this.receiptSellerEmployee = receiptSellerEmployee;
}