Filter Mapping for OneToMany Relationship Entity
Posted: Wed Jul 09, 2014 9:26 am
Hi All,
I have a functionality to build here and i need to know what could be the right way for doing this.
We have customer entity. I need to extend this functionality a bit. We are implementing multichannel approach for this a customer can be created through multiple channel. So there is a channelmaster entity and than there is a join table holding the customer id and channelid. In db terms this can be viewed as a manytomany relationship.
Now i need to build this in admin to filter out customers based on particular channels. I am putting a list of channels in customerimpl, now i have to build this filtermapping. I need to build a generic approach for this instead of going through named queries or detach criteria.
What i have understood that there are different persistence modules (basic, adorned etc) currently customerimpl falls in basic persistance module category. Now i have to put a criteria in persistence perspective so that correct filter mappings are created for it. Not sure how to achieve this and which one to chose.
Kindly help me out on this feature, looking for guidance.
Thanks
Dev
I have a functionality to build here and i need to know what could be the right way for doing this.
We have customer entity. I need to extend this functionality a bit. We are implementing multichannel approach for this a customer can be created through multiple channel. So there is a channelmaster entity and than there is a join table holding the customer id and channelid. In db terms this can be viewed as a manytomany relationship.
Now i need to build this in admin to filter out customers based on particular channels. I am putting a list of channels in customerimpl, now i have to build this filtermapping. I need to build a generic approach for this instead of going through named queries or detach criteria.
What i have understood that there are different persistence modules (basic, adorned etc) currently customerimpl falls in basic persistance module category. Now i have to put a criteria in persistence perspective so that correct filter mappings are created for it. Not sure how to achieve this and which one to chose.
Kindly help me out on this feature, looking for guidance.
Thanks
Dev