* <p>
* @return Company contact person
*/
- Employee getCompanyContact ();
+ Employee getCompanyContactEmployee ();
/**
* Setter for company contact person
* <p>
* @param companyContact Company contact person
*/
- void setCompanyContact (final Employee companyContact);
+ void setCompanyContactEmployee (final Employee companyContact);
/**
* Getter for business contact id
@Table (name = "company_basic_data")
@NamedQueries (
{
- @NamedQuery (name = "AllBusinessData", query = "SELECT b FROM company_basic_data AS b ORDER BY b.businessDataId")
+ @NamedQuery (name = "AllBusinessData", query = "SELECT b FROM company_basic_data AS b ORDER BY b.businessDataId"),
+ @NamedQuery (name = "SearchBusinessDataById", query = "SELECT b FROM company_basic_data AS b WHERE b.businessDataId = :businessDataId")
}
)
@SuppressWarnings ("PersistenceUnitPresent")
/**
* Reference to contact person
*/
- @JoinColumn (name = "company_contact_id")
+ @JoinColumn (name = "company_contact_employee_id")
@OneToOne (targetEntity = CompanyEmployee.class, cascade = CascadeType.ALL)
- private Employee companyContact;
+ private Employee companyContactEmployee;
/**
* Company's main email address (example: info@company.com)
return false;
} else if (!Objects.equals(this.getHeadQuartersData(), other.getHeadQuartersData())) {
return false;
- } else if (!Objects.equals(this.getCompanyContact(), other.getCompanyContact())) {
+ } else if (!Objects.equals(this.getCompanyContactEmployee(), other.getCompanyContactEmployee())) {
return false;
} else if (!Objects.equals(this.getCompanyFounder(), other.getCompanyFounder())) {
return false;
}
@Override
- public Employee getCompanyContact () {
- return this.companyContact;
+ public Employee getCompanyContactEmployee () {
+ return this.companyContactEmployee;
}
@Override
- public void setCompanyContact (final Employee companyContact) {
- this.companyContact = companyContact;
+ public void setCompanyContactEmployee (final Employee companyContactEmployee) {
+ this.companyContactEmployee = companyContactEmployee;
}
@Override
hash = 37 * hash + Objects.hashCode(this.getCompanyName());
hash = 37 * hash + Objects.hashCode(this.getCompanyLegalStatus());
hash = 37 * hash + Objects.hashCode(this.getHeadQuartersData());
- hash = 37 * hash + Objects.hashCode(this.getCompanyContact());
+ hash = 37 * hash + Objects.hashCode(this.getCompanyContactEmployee());
hash = 37 * hash + Objects.hashCode(this.getCompanyFounder());
return hash;