// List columns can be fixed width or extensible

This commit is contained in:
tDidierjean
2011-11-03 14:35:15 +00:00
parent 2ec2a3d25f
commit d9c30b9064
3 changed files with 18 additions and 10 deletions
@@ -103,16 +103,25 @@
cellpadding="0" cellspacing="0"
style="width: 100%; margin-bottom:10px;"
>
<col width="10px" />
{foreach $fields_display AS $key => $params}
<col {if isset($params.width) && $params.width != 'auto'}width="{$params.width}px"{/if}/>
{/foreach}
{if $shop_link_type}
<col width="80px" />
{/if}
{if $has_actions}
<col width="52px" />
{/if}
<thead>
<tr class="nodrag nodrop">
<th style="width:10px;">
<th>
{if $has_bulk_actions}
<input type="checkbox" name="checkme" class="noborder" onclick="checkDelBoxes(this.form, '{$table}Box[]', this.checked)" />
{/if}
</th>
{foreach $fields_display AS $key => $params}
<th {if isset($params.widthColumn)} style="width: {if $params.widthColumn == 'auto'}auto{else}{$params.widthColumn}px{/if}"{/if}
{if isset($params.align)} class="{$params.align}"{/if}>
<th {if isset($params.align)} class="{$params.align}"{/if}>
{$params.title}
{if (!isset($params.orderby) || $params.orderby) && !$simple_header}
<br />
@@ -125,9 +134,8 @@
{/if}
</th>
{/foreach}
{if $shop_link_type}
<th style="width: 80px">
<th>
{if $shop_link_type == 'shop'}
{l s='shop'}
{else}
@@ -136,7 +144,7 @@
</th>
{/if}
{if $has_actions}
<th style="width: 52px">{l s='Actions'}</th>
<th>{l s='Actions'}</th>
{/if}
</tr>
{if !$simple_header}
@@ -51,9 +51,9 @@ class AdminAddressesControllerCore extends AdminController
$this->fieldsDisplay = array(
'id_address' => array('title' => $this->l('ID'), 'align' => 'center', 'width' => 25),
'firstname' => array('title' => $this->l('First name'), 'width' => 80, 'filter_key' => 'a!firstname'),
'lastname' => array('title' => $this->l('Last name'), 'width' => 100, 'filter_key' => 'a!lastname'),
'address1' => array('title' => $this->l('Address'), 'width' => 200),
'firstname' => array('title' => $this->l('First name'), 'width' => 120, 'filter_key' => 'a!firstname'),
'lastname' => array('title' => $this->l('Last name'), 'width' => 140, 'filter_key' => 'a!lastname'),
'address1' => array('title' => $this->l('Address')),
'postcode' => array('title' => $this->l('Postcode/ Zip Code'), 'align' => 'right', 'width' => 50),
'city' => array('title' => $this->l('City'), 'width' => 150),
'country' => array('title' => $this->l('Country'), 'width' => 100, 'type' => 'select', 'list' => $this->countriesArray, 'filter_key' => 'cl!id_country'));
+1 -1
View File
@@ -38,7 +38,7 @@ class AdminTaxesControllerCore extends AdminController
$this->fieldsDisplay = array(
'id_tax' => array('title' => $this->l('ID'), 'align' => 'center', 'width' => 25),
'name' => array('title' => $this->l('Name'), 'width' => 140),
'name' => array('title' => $this->l('Name'), 'width' => 'auto'),
'rate' => array('title' => $this->l('Rate'), 'align' => 'center', 'suffix' => '%', 'width' => 50),
'active' => array('title' => $this->l('Enabled'), 'width' => 25, 'align' => 'center', 'active' => 'status', 'type' => 'bool', 'orderby' => false));