{foreach from=$list_fields_array item=name key=key}
{strparse var=fmt value=$name}
{if $key == "storehouse_id"}
|
{assign var="tmpval" value=$row.$key}{$storehouse_array[$tmpval]|del:$row.disabled}({assign var="tmpval2" value=$row.storehouse_id}{$storehouse_branch_array[$tmpval2]|del:$row.disabled})
|
{elseif $key == "username"}
{$row.$key|del:$row.disabled}({$branch_array[$row.branch_id]|del:$row.disabled}) |
{elseif $key == "branch_id"}
{assign var="tmpval2" value=$row.storehouse_id}{$storehouse_branch_array[$tmpval2]|del:$row.disabled} |
{elseif in_array($key,array("in_number","out_number","bad_number","balance_number","place_number","pins_number","batch_number"))}
{if $row.$key > 0}{/if}{$row.$key|string_format:"%.02f"|del:$row.disabled}{if $row.$key}{/if} |
{elseif $key == "stock_age"}
{$row.$key|del:$row.disabled} 天 |
{else}
{$row.$key|del:$row.disabled} |
{/if}
{*合计字段处理开始*}
{if $fmt.sum}
{php}
$key = $this->_tpl_vars["key"];
$value = $this->_tpl_vars["row"][$key];
$_total_list_array[$key] += $value +0;
$this->_tpl_vars["_total_list_array"] = $_total_list_array;
$_total_single_list_array[$key] += $value +0;
$this->_tpl_vars["_total_single_list_array"] = $_total_single_list_array;
{/php}
{/if}
{*合计字段处理结束*}
{/foreach}
{/foreach}
{if !$smarty.request.show_batch}
{foreach from=$uls item=row}