Sample BSV: Filtering list of references in "Add"

Contains tips for configurators working with Aware IM
Post Reply
tford
Posts: 4238
Joined: Sat Mar 10, 2007 6:44 pm

Sample BSV: Filtering list of references in "Add"

Post by tford »

This sample BSV demonstrates how to:

1) Have a form to filter choices in a reference list (see screen shot below):

Image




2) Show only instances NOT currently on the reference list:

Image


The key is the query: "Country Choices List". The query's FIND action is modeled after the workaround shown in the User Guide -- Appendix B #14:

FIND Country WHERE COUNT RegularUser WHERE (RegularUser IN Country.Users AND RegularUser=ThisRegularUser)=0 ORDER BY Country.Name

Note that this query uses the form "Country Choices Filter". This form produces the "Country Choices Filter" in the first screen shot above.


Download Sample BSV: Add_Country_Filter_8_31_2009.bsv

After download, remove the .bin extension
Tom - V8.8 build 3137 - MySql / PostGres
tford
Posts: 4238
Joined: Sat Mar 10, 2007 6:44 pm

Post by tford »

BSV Improvement challenge.

I would love to be able to restrict the region list below to only include the Regions associated with Countries NOT currently on the list:

Image


I would like the list above to only include Region 50 and Region 000.

Image


Can anyone devise a Filter to the Region attribute of the "Country Filter Choices" form that will accomplish this?
Tom - V8.8 build 3137 - MySql / PostGres
bartthefish
Posts: 116
Joined: Sat Oct 25, 2008 3:16 pm

Post by bartthefish »

The only way that i can see it being possible is to modify the BO's so that it will keep record of What countries belong to a specific region, and then build a query that checks the countries that are not in the User's profile; and then find's the regions that they fall under.

I will have a look at the bsv later and see if i can figure out the wording of the query.
Justin
(v7.0 Build 2144) Windows. MSSQL Server
Post Reply