feat(print_deliveryNote): add withoutPrices type
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
19df1fe382
commit
0dc1848870
|
@ -21,7 +21,7 @@
|
|||
<vn-list>
|
||||
<vn-item
|
||||
ng-if="!$ctrl.hasDocuwareFile"
|
||||
ng-click="$ctrl.showPdfDeliveryNote()"
|
||||
ng-click="$ctrl.showPdfDeliveryNote('deliveryNote')"
|
||||
translate>
|
||||
as PDF
|
||||
</vn-item>
|
||||
|
@ -32,6 +32,12 @@
|
|||
translate>
|
||||
as PDF
|
||||
</a>
|
||||
<vn-item
|
||||
ng-if="!$ctrl.hasDocuwareFile"
|
||||
ng-click="$ctrl.showPdfDeliveryNote('withoutPrices')"
|
||||
translate>
|
||||
as PDF without prices
|
||||
</vn-item>
|
||||
<vn-item
|
||||
ng-click="$ctrl.showCsvDeliveryNote()"
|
||||
translate>
|
||||
|
@ -44,7 +50,6 @@
|
|||
vn-click-stop="sendDeliveryNoteMenu.show($event, 'left')"
|
||||
translate>
|
||||
Send Delivery Note...
|
||||
|
||||
<vn-menu vn-id="sendDeliveryNoteMenu">
|
||||
<vn-list>
|
||||
<vn-item
|
||||
|
|
|
@ -116,10 +116,11 @@ class Controller extends Section {
|
|||
});
|
||||
}
|
||||
|
||||
showPdfDeliveryNote() {
|
||||
showPdfDeliveryNote(type) {
|
||||
this.vnReport.show('delivery-note', {
|
||||
recipientId: this.ticket.client.id,
|
||||
ticketId: this.id,
|
||||
type: type
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@ Show Delivery Note...: Ver albarán...
|
|||
Send Delivery Note...: Enviar albarán...
|
||||
as PDF: como PDF
|
||||
as CSV: como CSV
|
||||
as PDF without prices: como PDF sin precios
|
||||
Send PDF: Enviar PDF
|
||||
Send CSV: Enviar CSV
|
||||
Send CSV Delivery Note: Enviar albarán en CSV
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<div class="columns">
|
||||
<div class="size50">
|
||||
<div class="size75 vn-mt-ml">
|
||||
<h1 class="title uppercase">{{$t('title')}}</h1>
|
||||
<h1 class="title uppercase">{{$t(type)}}</h1>
|
||||
<table class="row-oriented ticket-info">
|
||||
<tbody>
|
||||
<tr>
|
||||
|
@ -23,7 +23,7 @@
|
|||
<th>{{client.id}}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="font gray uppercase">{{$t('ticketId')}}</td>
|
||||
<td class="font gray uppercase">{{$t(type)}}</td>
|
||||
<th>{{ticket.id}}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
|
@ -77,10 +77,10 @@
|
|||
<th width="5%">{{$t('reference')}}</th>
|
||||
<th class="number">{{$t('quantity')}}</th>
|
||||
<th width="50%">{{$t('concept')}}</th>
|
||||
<th class="number">{{$t('price')}}</th>
|
||||
<th class="centered" width="5%">{{$t('discount')}}</th>
|
||||
<th class="centered">{{$t('vat')}}</th>
|
||||
<th class="number">{{$t('amount')}}</th>
|
||||
<th class="number" v-if="type != 'withoutPrices'">{{$t('price')}}</th>
|
||||
<th class="centered" width="5%" v-if="type != 'withoutPrices'">{{$t('discount')}}</th>
|
||||
<th class="centered" v-if="type != 'withoutPrices'">{{$t('vat')}}</th>
|
||||
<th class="number" v-if="type != 'withoutPrices'">{{$t('amount')}}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody v-for="sale in sales" class="no-page-break">
|
||||
|
@ -88,10 +88,10 @@
|
|||
<td width="5%">{{sale.itemFk | zerofill('000000')}}</td>
|
||||
<td class="number">{{sale.quantity}}</td>
|
||||
<td width="50%">{{sale.concept}}</td>
|
||||
<td class="number">{{sale.price | currency('EUR', $i18n.locale)}}</td>
|
||||
<td class="centered" width="5%">{{(sale.discount / 100) | percentage}}</td>
|
||||
<td class="centered">{{sale.vatType}}</td>
|
||||
<td class="number">{{sale.price * sale.quantity * (1 - sale.discount / 100) | currency('EUR', $i18n.locale)}}</td>
|
||||
<td class="number" v-if="type != 'withoutPrices'">{{sale.price | currency('EUR', $i18n.locale)}}</td>
|
||||
<td class="centered" width="5%" v-if="type != 'withoutPrices'">{{(sale.discount / 100) | percentage}}</td>
|
||||
<td class="centered" v-if="type != 'withoutPrices'">{{sale.vatType}}</td>
|
||||
<td class="number" v-if="type != 'withoutPrices'">{{sale.price * sale.quantity * (1 - sale.discount / 100) | currency('EUR', $i18n.locale)}}</td>
|
||||
</tr>
|
||||
<tr class="description font light-gray">
|
||||
<td colspan="7">
|
||||
|
@ -107,7 +107,7 @@
|
|||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tfoot v-if="type != 'withoutPrices'">
|
||||
<tr>
|
||||
<td colspan="6" class="font bold">
|
||||
<span class="pull-right">{{$t('subtotal')}}</span>
|
||||
|
@ -181,7 +181,7 @@
|
|||
</div>
|
||||
<!-- End of packages block -->
|
||||
</div>
|
||||
<div class="columns vn-mt-xl">
|
||||
<div class="columns vn-mt-xl" v-if="type != 'withoutPrices'">
|
||||
<!-- Taxes block -->
|
||||
<div id="taxes" class="size50 pull-right no-page-break" v-if="taxes">
|
||||
<table class="column-oriented">
|
||||
|
|
|
@ -119,6 +119,10 @@ module.exports = {
|
|||
ticketId: {
|
||||
type: [Number, String],
|
||||
required: true
|
||||
},
|
||||
type: {
|
||||
type: String,
|
||||
required: true
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue