Forum Discussion
FICO
14 years agoCommunity Manager
Custom Association Provider
Custom Association Provider
Hi,
I need help in implementing RMA requirement.
I need to fetch a list of values from database and display in RMA as a list box. Say I display a list of all user ids in the drop-down. When a user selects an ID from the drop-down list then I need to fetch the corresponding values from another table in the database where userid = the value selected in the drop down. Then I need to give an option to update the values returned from the second query. There are many userids, so the imp thing is to pass the selected user id in the "where" clause of second query so that I get only the corresponding values for the selected user.
I am thinking of implementing this with custom Association provider. Here is the snapshot of the implementation I am thinking of.
Implement custom Association provider to fetch all userids from database.
Association:
Key: userid1
Provider: custom database provider to fetch the values of userid1
Association:
Key: userid2
Provider: custom database provider to fetch the values of userid2
Is this implementation correct? If so, I need help in implementing custom Assoication Provider - which class should I extend to do so?
If the above implementation is not correct, please provide a better implementation approach.
Appreciate your help!
Thanks.
1 Reply
- FICOCommunity Manager
that key in the association I dont think is dynamic.
You can create a custom proverider with arguments. then you need to do a dynamic override with the id value holder that was selected. Since you're custom providers are hitting the database you should be caching the values as these provider classes will get instatiated 100's of times. this is true and the more rules you have in the ruleset the more times it will get called which will cause performance issues due to so many database calls. anyhow then your second list will be populated off your first.
Related Content
Related Content
- 0Views0likes1Comment