Simplification détails membre (suite)

This commit is contained in:
Jean-Christophe Engel 2025-10-27 12:11:29 +01:00
parent 8266ab8aeb
commit ec29f26176

View file

@ -151,27 +151,16 @@
<th>Matériel</th> <th>Matériel</th>
<th>Opération</th> <th>Opération</th>
<th>Quantité</th> <th>Quantité</th>
<th>Total</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
{{#foreach from=$def_mat}} {{#foreach from=$def_mat}}
{{:assign var="type_mvt" from="config.%s_nature.%s.type"|args:$direction:$operation}}
{{:assign var="op_label" from="config.%s_nature.%s.label"|args:$direction:$operation}} {{:assign var="op_label" from="config.%s_nature.%s.label"|args:$direction:$operation}}
{{:assign var="total" from="reste.%s"|args:$eqpmt_key}}
{{if $total == null}}
{{:assign total=0}}
{{/if}}
{{if $direction == 'output' && $type_mvt == 'définitif'}}
{{:assign var="reste.%s"|args:$eqpmt_key value="%d+%d"|math:$total:$amount}}
{{/if}}
{{:assign var="total" from="reste.%s"|args:$eqpmt_key}}
<tr> <tr>
<td>{{$date|date_short}}</td> <td>{{$date|date_short}}</td>
<td>{{$eqpmt_name}}</td> <td>{{$eqpmt_name}}</td>
<td>{{$op_label}}</td> <td>{{$op_label}}</td>
<td>{{$amount}}</td> <td>{{$amount}}</td>
<td>{{$total}}</td>
</tr> </tr>
{{/foreach}} {{/foreach}}
</tbody> </tbody>