Hello,
i'm a newbie in using TBS and an i have encountered an problem that the documentation coudn't solve for me.
We are using TBS in our statistic backend for various reports or parts of these reports. So we have an existing template for i.e. the shipping costs in an existing transport category and
an multidimensional Array that contains an array list of all products grouped by the transportation-method and the shipping report for these category.
but i coudn't use the pre existing "shipping"-templates because i cant get the subarray/subblock to work with the existing block-label "shipping".
I should avoid to alter the looping or creation process of the array. something i would normal do - simply merge the block for shipping in an loop.
so i've have to merge the block in the template ....kind of.
Array-Structure:
$groupArticle[$key]['category'] = string
$groupArticle[$key]['products'] = array( ..... )
$groupArticle[$key]['shipping'] = array( ..... )
|
Template:
<tr class="[shipping.#;ope=mod:2;if [val]=0;then 'even';else 'odd';]">
<td align="left">[shipping.amount;block=tr;htmlconv=no;]</td>
<td align="left">[shipping.type;block=tr;htmlconv=no;]</td>
<td align="right">[shipping.handling;block=tr;frm='0.000,00'] €</td>
<td align="right">[shipping.cont_price;block=tr;frm='0.000,00'] €</td>
</tr>
|
Has anyone an idea how to solve this and avoid to copying the template and rename the block?