<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://atk-framework.com/index.php?action=history&amp;feed=atom&amp;title=Grouping_attributes_into_two_columns</id>
	<title>Grouping attributes into two columns - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://atk-framework.com/index.php?action=history&amp;feed=atom&amp;title=Grouping_attributes_into_two_columns"/>
	<link rel="alternate" type="text/html" href="https://atk-framework.com/index.php?title=Grouping_attributes_into_two_columns&amp;action=history"/>
	<updated>2026-09-20T19:21:50Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.1</generator>
	<entry>
		<id>https://atk-framework.com/index.php?title=Grouping_attributes_into_two_columns&amp;diff=17961&amp;oldid=prev</id>
		<title>Jgarifuna at 03:56, 30 January 2009</title>
		<link rel="alternate" type="text/html" href="https://atk-framework.com/index.php?title=Grouping_attributes_into_two_columns&amp;diff=17961&amp;oldid=prev"/>
		<updated>2009-01-30T03:56:02Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 03:56, 30 January 2009&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{howto|easy|Jorge Garifuna &amp;lt;info at garidigital.com&amp;gt;}}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{howto|easy|Jorge Garifuna &amp;lt;info at garidigital.com&amp;gt;}}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{{unstable}}&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Requirements ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Requirements ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Jgarifuna</name></author>
	</entry>
	<entry>
		<id>https://atk-framework.com/index.php?title=Grouping_attributes_into_two_columns&amp;diff=14011&amp;oldid=prev</id>
		<title>bahtiar at 22:57, 28 August 2008</title>
		<link rel="alternate" type="text/html" href="https://atk-framework.com/index.php?title=Grouping_attributes_into_two_columns&amp;diff=14011&amp;oldid=prev"/>
		<updated>2008-08-28T22:57:16Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 22:57, 28 August 2008&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{howto|easy|Jorge Garifuna &amp;lt;info at garidigital.com&amp;gt;}}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{howto|easy|Jorge Garifuna &amp;lt;info at garidigital.com&amp;gt;}}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{{unstable}}&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Requirements ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Requirements ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>bahtiar</name></author>
	</entry>
	<entry>
		<id>https://atk-framework.com/index.php?title=Grouping_attributes_into_two_columns&amp;diff=12501&amp;oldid=prev</id>
		<title>Jgarifuna at 21:19, 30 July 2008</title>
		<link rel="alternate" type="text/html" href="https://atk-framework.com/index.php?title=Grouping_attributes_into_two_columns&amp;diff=12501&amp;oldid=prev"/>
		<updated>2008-07-30T21:19:08Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{howto|easy|Jorge Garifuna &amp;lt;info at garidigital.com&amp;gt;}}&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
ATK 6.2+&lt;br /&gt;
&lt;br /&gt;
== Summary ==&lt;br /&gt;
&lt;br /&gt;
As of the ATK 6.2 nightly after July 29, 2008, there is a new way to add  attributes into two columns. This howto walks you through the process.&lt;br /&gt;
&lt;br /&gt;
I would like to commend [Rik http://forum.achievo.org/forum/viewtopic.php?t=10341&amp;amp;highlight=column] for bringing this great contribution to the ATK community.&lt;br /&gt;
&lt;br /&gt;
== Procedures ==&lt;br /&gt;
&lt;br /&gt;
By default attributes are position on one single column in ATK. To position attributes on the right column you will need to call the following new method within your node:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
    $this-&amp;gt;setColumnAttribs($attributes=array())&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This method will position any provided attributes to the right column of the node, to make a two column layout.&lt;br /&gt;
&lt;br /&gt;
Assuming you had the following node:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
        function employee()&lt;br /&gt;
        {&lt;br /&gt;
            $this-&amp;gt;atkNode(&amp;quot;employee&amp;quot;, NF_ADD_LINK);//&lt;br /&gt;
&lt;br /&gt;
            $this-&amp;gt;add(new atkAttribute(&amp;quot;id&amp;quot;, AF_AUTOKEY));&lt;br /&gt;
            $this-&amp;gt;add(new atkAttribute(&amp;quot;name&amp;quot;, AF_OBLIGATORY|AF_UNIQUE|AF_SEARCHABLE));&lt;br /&gt;
            $this-&amp;gt;add(new atkManyToOneRelation(&amp;quot;department_id&amp;quot;,&amp;quot;lesson3.department&amp;quot;, AF_SEARCHABLE));&lt;br /&gt;
            $this-&amp;gt;add(new atkManyToOneRelation(&amp;quot;manager_id&amp;quot;,&amp;quot;lesson3.employee&amp;quot;, AF_SEARCHABLE|AF_RELATION_AUTOCOMPLETE));&lt;br /&gt;
&lt;br /&gt;
            $this-&amp;gt;add(new atkDateAttribute(&amp;quot;hiredate&amp;quot;));&lt;br /&gt;
            $this-&amp;gt;add(new atkNumberAttribute(&amp;quot;salary&amp;quot;, AF_TOTAL));&lt;br /&gt;
            $this-&amp;gt;add(new atkTextAttribute(&amp;quot;notes&amp;quot;, 0, AF_HIDE_LIST));&lt;br /&gt;
&lt;br /&gt;
            $this-&amp;gt;setOrder(&amp;quot;name&amp;quot;);&lt;br /&gt;
            $this-&amp;gt;setIndex(&amp;quot;name&amp;quot;);&lt;br /&gt;
            $this-&amp;gt;setTable(&amp;quot;lesson3_employee&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To display the attributes, name, salary and hiredate on the right column, you would need to apply the following to your node:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
$this-&amp;gt;setColumnAttribs(array(&amp;quot;name&amp;quot;,&amp;quot;salary&amp;quot;,&amp;quot;hiredate&amp;quot;));&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
So your final code would look as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
        function employee()&lt;br /&gt;
        {&lt;br /&gt;
            $this-&amp;gt;atkNode(&amp;quot;employee&amp;quot;, NF_ADD_LINK);//&lt;br /&gt;
&lt;br /&gt;
            $this-&amp;gt;add(new atkAttribute(&amp;quot;id&amp;quot;, AF_AUTOKEY));&lt;br /&gt;
            $this-&amp;gt;add(new atkAttribute(&amp;quot;name&amp;quot;, AF_OBLIGATORY|AF_UNIQUE|AF_SEARCHABLE));&lt;br /&gt;
            $this-&amp;gt;add(new atkManyToOneRelation(&amp;quot;department_id&amp;quot;,&amp;quot;lesson3.department&amp;quot;, AF_SEARCHABLE));&lt;br /&gt;
            $this-&amp;gt;add(new atkManyToOneRelation(&amp;quot;manager_id&amp;quot;,&amp;quot;lesson3.employee&amp;quot;, AF_SEARCHABLE|AF_RELATION_AUTOCOMPLETE));&lt;br /&gt;
&lt;br /&gt;
            $this-&amp;gt;add(new atkDateAttribute(&amp;quot;hiredate&amp;quot;));&lt;br /&gt;
            $this-&amp;gt;add(new atkNumberAttribute(&amp;quot;salary&amp;quot;, AF_TOTAL));&lt;br /&gt;
            $this-&amp;gt;add(new atkTextAttribute(&amp;quot;notes&amp;quot;, 0, AF_HIDE_LIST));&lt;br /&gt;
&lt;br /&gt;
            $this-&amp;gt;setColumnAttribs(array(&amp;quot;name&amp;quot;,&amp;quot;salary&amp;quot;,&amp;quot;hiredate&amp;quot;)); // places name, salary and hiredate on the right column&lt;br /&gt;
            $this-&amp;gt;setOrder(&amp;quot;name&amp;quot;);&lt;br /&gt;
            $this-&amp;gt;setIndex(&amp;quot;name&amp;quot;);&lt;br /&gt;
            $this-&amp;gt;setTable(&amp;quot;lesson3_employee&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Below is an additional example with other options to display other fields on the right column:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;php&amp;quot;&amp;gt;&lt;br /&gt;
        function employee()&lt;br /&gt;
        {&lt;br /&gt;
            $this-&amp;gt;atkNode(&amp;quot;employee&amp;quot;, NF_ADD_LINK);//&lt;br /&gt;
&lt;br /&gt;
            $this-&amp;gt;add(new atkAttribute(&amp;quot;id&amp;quot;, AF_AUTOKEY));&lt;br /&gt;
            $this-&amp;gt;add(new atkAttribute(&amp;quot;name&amp;quot;, AF_OBLIGATORY|AF_UNIQUE|AF_SEARCHABLE));&lt;br /&gt;
            $this-&amp;gt;add(new atkManyToOneRelation(&amp;quot;department_id&amp;quot;,&amp;quot;lesson3.department&amp;quot;, AF_SEARCHABLE));&lt;br /&gt;
            $this-&amp;gt;add(new atkManyToOneRelation(&amp;quot;manager_id&amp;quot;,&amp;quot;lesson3.employee&amp;quot;, AF_SEARCHABLE|AF_RELATION_AUTOCOMPLETE));&lt;br /&gt;
&lt;br /&gt;
            $this-&amp;gt;add(new atkDateAttribute(&amp;quot;hiredate&amp;quot;));&lt;br /&gt;
            $this-&amp;gt;add(new atkNumberAttribute(&amp;quot;salary&amp;quot;, AF_TOTAL));&lt;br /&gt;
            $this-&amp;gt;add(new atkTextAttribute(&amp;quot;notes&amp;quot;, 0, AF_HIDE_LIST));&lt;br /&gt;
&lt;br /&gt;
            // $this-&amp;gt;setColumnAttribs(array(&amp;quot;name&amp;quot;,&amp;quot;salary&amp;quot;,&amp;quot;hiredate&amp;quot;)); // places name, salary and hiredate on the right column&lt;br /&gt;
            $this-&amp;gt;setColumnAttribs(array(&amp;quot;name&amp;quot;,&amp;quot;department_id&amp;quot;)); // places name and department_id  on the right column&lt;br /&gt;
            // $this-&amp;gt;setColumnAttribs(array(&amp;quot;manager_id&amp;quot;,&amp;quot;hiredate&amp;quot;,&amp;quot;salary&amp;quot;,&amp;quot;notes&amp;quot;)); // places manager_id, hiredate, salary and notes on the right column&lt;br /&gt;
            // $this-&amp;gt;setColumnAttribs(array(&amp;quot;salary&amp;quot;,&amp;quot;notes&amp;quot;)); // place salary and notes on right column&lt;br /&gt;
            $this-&amp;gt;setOrder(&amp;quot;name&amp;quot;);&lt;br /&gt;
            $this-&amp;gt;setIndex(&amp;quot;name&amp;quot;);&lt;br /&gt;
            $this-&amp;gt;setTable(&amp;quot;lesson3_employee&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Until next time,&lt;br /&gt;
&lt;br /&gt;
[Jorge Garifuna http://www.GariDigital.com]&lt;/div&gt;</summary>
		<author><name>Jgarifuna</name></author>
	</entry>
</feed>