Hi All,
I have @OneToOne relationship between two entity in blc admin.
For example
1. Office
2. Office billing address
Now here office billing address is optional.
In OfficeImpl
@OneToOne(mappedBy = "office",targetEntity = OfficeBillingAddressImpl.class)
@Cascade(value={org.hibernate.annotations.CascadeType.MERGE, org.hibernate.annotations.CascadeType.PERSIST, org.hibernate.annotations.CascadeType.SAVE_UPDATE})
protected OfficeBillingAddress address;
In OfficeAddressImpl
@OneToOne(targetEntity = OfficeImpl.class)
@JoinColumn(name = "OFFICE_ID", unique = true)
private Office office;
Now, From BLC Admin UI, If I create Office with office address, it is working fine.
But if i create office first and save it.. after that when i update office with office address ,
at that time there is duplicate entry is falling in office address table, one has office_id and other has null.
Thanks,
Ankit
This forum is in readonly mode and serves as an archive of old information. All posting, registration and commenting abilities have been turned off. To get help, the Broadleaf team reguarly monitors the broadleaf-commerce tag on Stack Overflow so please ask your questions there.