<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="FeedCreator 1.7.2" -->
<rss version="2.0">
    <channel>
        <title>grid[ Search for &quot;&quot;]</title>
        <description></description>
        <link>http://xataface.com/wiki/index.php?-action=single_record_search&amp;-table=wiki&amp;page_id=%3D67&amp;-cursor=0&amp;-skip=0&amp;-limit=30&amp;-mode=list&amp;--subsearch=</link>
        <lastBuildDate>Thu, 20 Jun 2013 05:29:51 +0100</lastBuildDate>
        <generator>FeedCreator 1.7.2</generator>
        <item>
            <title>grid</title>
            <link>http://www.xataface.com/wiki/grid</link>
            <description>&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Field&lt;/th&gt;&lt;th&gt;Value&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td valign=&quot;top&quot;&gt;Page name&lt;/td&gt;&lt;td valign=&quot;top&quot;&gt;grid&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td valign=&quot;top&quot;&gt;Page id&lt;/td&gt;&lt;td valign=&quot;top&quot;&gt;67&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td valign=&quot;top&quot;&gt;Page title&lt;/td&gt;&lt;td valign=&quot;top&quot;&gt;grid&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td valign=&quot;top&quot;&gt;Content&lt;/td&gt;&lt;td valign=&quot;top&quot;&gt;
&lt;h2 id=&quot;toc0&quot;&gt;widget:type = grid&lt;/h2&gt;
&lt;p&gt;Suppose we have two tables, tbl_organisation and tbl_individuals, in the edit view for a record in the organisations table (tbl_organisations) we also want to be able to view and edit the individuals within this organisation we can use widget:type=grid&lt;/p&gt;

&lt;p&gt;In the /tables/tbl_organisation/fields.ini we create a transient field by adding:&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;[Individuals]
widget:label = &amp;quot;Individuals&amp;quot;
transient=1
relationship=individuals
widget:type=grid
widget:columns=&amp;quot;ind_firstname,ind_lastname,ind_tel&amp;quot;&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;The above assumes we have a relationship entry in our /tables/tbl_organisation/relationships.ini that looks like this:&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;[individuals]
__sql__ = &amp;quot;SELECT * FROM tbl_individual WHERE org_id='$org_id'&amp;quot;&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;The fields.ini will show the three columns shown in widget:columns from the table tbl_individual&lt;/p&gt;

&lt;p&gt;Correct permissions need to be set to enable editing and deletion etc of these records.&lt;/p&gt;

&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td valign=&quot;top&quot;&gt;Language&lt;/td&gt;&lt;td valign=&quot;top&quot;&gt;en&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;</description>
            <author>grid</author>
        </item>
    </channel>
</rss>
