Page 1 of 1
Hide fields in Relationship.ini

Posted:
Wed Feb 18, 2009 12:33 pm
by rwzhao
Hello, Steve,
I have a relationships.ini where I use customs SQL which left join with another table. On the list, I can see the all of fileds out the two tables. And I follow the visibility:tableA.somefiled=hidden but the somefield is still shown in the list. I have tried two options in relationships.ini as below:
1. [somerelations]
tableA.r_id="$r_id"
tableA.code=tableB.code
visibility:tableB.description=hidden
2. [somerelations]
__sql__ = "SELECT tableB.title, tableA.others from tableA where tableA.code=tableA.code and tableA.r_id='$r_id'"
visibility:tableB.description=hidden
I still get all the fileds from both tableA and tableB.
Any suggestion?

Posted:
Wed Feb 18, 2009 1:07 pm
by shannah
Try just:
- Code: Select all
visibility:description=hidden

Posted:
Wed Feb 18, 2009 2:22 pm
by rwzhao
Tried but still shown.

Posted:
Wed Feb 18, 2009 2:25 pm
by rwzhao
Steve,
It only work without tableB.

Posted:
Wed Feb 18, 2009 2:30 pm
by shannah
Isn't that what I said in my previous reply? Did you get it working?

Posted:
Wed Feb 18, 2009 2:40 pm
by rwzhao
Steve,
It works. Thank you.
How about the order of these fields?
Re: Hide fields in Relationship.ini

Posted:
Sun Jan 09, 2011 8:35 pm
by ichia99
Hi! I'm having the same problem in trying to hide the tables fields listed in the relationship.ini from appearing in lower section of the find form.
Upon adding the relationships.ini. The related tables appears at the second section of the find form.
In my case I'm trying to build a database for a car park season card which is assigned to a car park bay.
Below is my relationships.ini
[Card]
card.BayID = "$BayID"
bay.BayID = card.BayID
section:visible=0
visibility:description=hidden
The above configuaration did not hide the related tables.
Please advice.
Re: Hide fields in Relationship.ini

Posted:
Tue Jan 11, 2011 6:38 pm
by ichia99
Is this something that I've done wrong?
Can anyone with a solution to my problem please help?
Re: Hide fields in Relationship.ini

Posted:
Fri Jan 14, 2011 12:50 pm
by shannah
I think you're trying to do a slightly different thing. This thread was asking about hiding the field in a relationship list view. You're trying to hide it from the find form.
I don't recall if there is an easy way to do what you are trying to do right now. You could just hide the fields in question from all find forms by updating the fields.ini file visibility:find directive for the fields in question. A cheap way would be to use CSS or javascript to hide the sections in question (just look at the HTML source of the resulting find form to see what the CSS selector should be for your section... there should be a way to specify it).
-Steve