Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix
gitea/salix/pipeline/head This commit looks good Details

This commit is contained in:
Alex Moreno 2023-06-19 07:20:00 +02:00
commit 2197441159
2 changed files with 8 additions and 2 deletions

View File

@ -69,7 +69,7 @@
<vn-th ng-click="$ctrl.sortBy('price')" field="price" number>Price</vn-th>
<vn-th ng-click="$ctrl.sortBy('discount')" field="discount" number>Disc</vn-th>
<vn-th ng-click="$ctrl.sortBy('amount')" field="amount" number>Amount</vn-th>
<vn-th ng-click="$ctrl.sortBy('itemPackingTypeFk')" field="itemPackingTypeFk" shrink>Packaging</vn-th>
<vn-th ng-click="$ctrl.sortBy('item.itemPackingTypeFk')" field="itemPackingTypeFk" shrink>Packaging</vn-th>
<vn-th shrink></vn-th>
</vn-tr>
</vn-thead>
@ -202,7 +202,7 @@
</span>
</vn-td>
<vn-td number>
{{$ctrl.getSaleTotal(sale) | currency: 'EUR':2}}
{{sale.amount | currency: 'EUR':2}}
</vn-td>
<vn-td shrink>
{{::sale.item.itemPackingTypeFk | dashIfEmpty}}

View File

@ -34,6 +34,11 @@ class Controller extends Section {
}
get sales() {
if (this._sales) {
for (let sale of this._sales)
sale.amount = this.getSaleTotal(sale);
}
return this._sales;
}
@ -49,6 +54,7 @@ class Controller extends Section {
return ticketState && ticketState.state.code;
}
getConfig() {
let filter = {
fields: ['daysForWarningClaim'],