GMSC Discussions

GeoMedia Smart Client community discussion board is where you can create, contribute and share information and knowledge in regards to configuring as well as working with GeoMedia Smart Client. Find your answers, share your knowledge and help build a strong GeoMedia Smart Client community.
Showing results for 
Search instead for 
Do you mean 
Reply
Highlighted
Frequent Contributor
Posts: 86
Registered: ‎11-20-2015

Custom FormFilter

Hi!

 

Has anyone written a custom FormFilter and can send me an example?

No Idea which baseclass I have to implement and wha I am supposed to return.

 

I want to join some values from a status colmn. With the standard filter I can only do something like:

<FormField name="STATUS" visible="filter" type="combobox" lov="SQL[select stKey, stValue from dbStatus]" />

where I can filter for 0 ("new") or 1 ("in progress") or 2 ("finished").

What I want to do for example, is fill the combobox with a LIST[...] and then filter with "(STATUS = 0 or STATUS = 1)

 

regards

Wolfgang

Highlighted
Staff
Posts: 45
Registered: ‎02-27-2018

Re: Custom FormFilter

Hi,

 

If I understand you correctly, you are trying to add a filter in the top area above a list?

 

I can tell you more about my example and you can see if it matches yours.

 

I have a table where poles are saved and then another table where the types of poles are saved. In the table with the poles, the ID of the type of poles is use as a foreign key.

 

In the list-view of the workflow, I want to be able to filter according to pole types (but not by typing the ID of the types, but the name of the type).

For this, I use sqlselect to define how the filter works (see below the code and image).

  • name=colum of the foreign key in the pole table
  • sqlselect = condition to match the value of the foreign key (ID of the pole type in the pole table) to the text of the pole type

 

<FormField name="GG170_GG171_ID" label="Typ:" type="combobox" datatype="number" required="true" maxlength="22" persisted="false"
    sqlselect="SQL[select GG171_MASTARTTEXT from GG171_MASTART where GG170_GG171_ID=GG171_ID]"
    visible="filter"/>