A restruant is a facility so you would add a facility type for it.
you can associate a party to a facitility with current code and ui. this
lets then list all the restruants they go to.
you can have a partyrelationship role of FavoriteRestruant.
OfBizSuds sent the following on 8/6/2010 6:20 AM:
Thanks again Raj. I think I can achieve my application specific requirement
using the existing Data Model itself.
But I am running into some problem. Hopefully someone can help me.
My requirement is that for every user I need to save their favorite
restaurant. In order to try out the back end I did the following.
So I
* created a user from ecommerce app - got created with PartyId = 10000
Then, through webtools I
* created an entry "RESTAURANT" in PartyType
* added a sample restaurant called "RESTAURANT1" to Party table with
PartyType = "RESTAURANT"
* created an entry "RESTAURANT" in RoleType
* created an entry "RESTAURANT1" to PartyRole table with RoleType =
"RESTAURANT"
* created an entry "FAVORITE_RESTAURANT" in PartyRelationshipType table
These went fine but the following is causing a problem
* on trying to create an entry in PartyRelationship for PartyIdFrom = 10000;
PartyIdTo = "RESTAURANT1";
roleTypeIdFrom = "PERSON"; roleTypeIdTo = "RESTAURANT";
partyRelationshipTypeId = "FAVORITE_RESTAURANT"
This is the error message
For Entity: PartyRelationship
With PK: [GenericEntity:PartyRelationship][fromDate,2010-07-03
11:16:29.0(java.sql.Timestamp)][partyIdFrom,10000(java.lang.String)][partyIdTo,RESTAURANT1(java.lang.String)][roleTypeIdFrom,PERSON(java.lang.String)][roleTypeIdTo,RESTAURANT(java.lang.String)]
Any ideas??