Page 1 of 1

how to apply filters to the relationship table?

PostPosted: Thu Jan 14, 2010 5:10 pm
by kevinwen
Now I have 2 tables: A and B, and I have a couple of filters to be used in Table B. Is that possible? My code is as follows:

table_a/relationships.ini:
Code: Select all
[Captures]
__sql__ = "seelct * from table_b where ref_id = '$ref_id' "



table_a/fields.ini:
Code: Select all
[category_name]
widget:label = "Category"
widget:type = hidden
visibility:list = hidden
visibility:browse = hidden
group = categories
filter = 1
order = 5

[subcategory_name]
widget:label = "Subcategory"
widget:type = hidden
visibility:list = hidden
visibility:browse = hidden
group = categories
filter = 1
order = 7


So, How do I define the filters above in table_b's fields.ini? Is that possible?

Re: how to apply filters to the relationship table?

PostPosted: Thu Jan 14, 2010 10:20 pm
by shannah
So are you wanting these filters to show up on the related records tab for your relationship? This feature isn't available currently. It sounds like a good feature though.

Re: how to apply filters to the relationship table?

PostPosted: Thu Jan 14, 2010 11:25 pm
by kevinwen
Yes, exactly. I want these filters to show up on the related records tab just next to view/edit and before history tab (if enabled). However, can you tell me how do the filters work? Can you point it out in the code where actually do the filtering? Thanks.