feat: muestra en número de clientes en vez de su id
gitea/salix/pipeline/head There was a failure building this commit
Details
gitea/salix/pipeline/head There was a failure building this commit
Details
This commit is contained in:
parent
61b0aa079a
commit
06b4e03320
|
@ -1,10 +1,10 @@
|
|||
<vn-card class="vn-w-lg">
|
||||
<h5 ng-if="$ctrl.packageInvoicing" translate text-center class="vn-pa-md">{{'Calculating packages to invoice...'}}</h5>
|
||||
<vn-vertical ng-if="$ctrl.lastClientId" text-center class="vn-pa-md">
|
||||
<vn-vertical ng-if="$ctrl.clients.length" text-center class="vn-pa-md">
|
||||
<h5 translate>Invoicing</h5>
|
||||
<div>
|
||||
{{'Id Client' | translate}}: {{$ctrl.currentClientId}}
|
||||
{{'of' | translate}} {{::$ctrl.lastClientId}}
|
||||
{{'Client' | translate}}: {{$ctrl.currentClient}}
|
||||
{{'of' | translate}} {{::$ctrl.clients.length}}
|
||||
</div>
|
||||
<div>
|
||||
{{($ctrl.percentage / 100) | percentage: 0}}
|
||||
|
|
|
@ -10,6 +10,10 @@ class Controller extends Section {
|
|||
maxShipped: new Date(),
|
||||
companyFk: this.vnConfig.companyFk
|
||||
};
|
||||
|
||||
this.invoice.invoiceDate = new Date();
|
||||
this.invoice.companyFk = 442;
|
||||
this.invoice.printerFk = 1;
|
||||
}
|
||||
|
||||
$onInit() {
|
||||
|
@ -50,9 +54,10 @@ class Controller extends Section {
|
|||
invoiceOut(invoice, clientsAndAddresses) {
|
||||
const [clientAndAddress] = clientsAndAddresses;
|
||||
if (!clientAndAddress) return;
|
||||
this.currentClientId = clientAndAddress.clientId;
|
||||
|
||||
this.currentClient = ++this.currentClient;
|
||||
this.getPercentage();
|
||||
|
||||
const params = {
|
||||
clientId: clientAndAddress.clientId,
|
||||
addressId: clientAndAddress.addressId,
|
||||
|
@ -63,7 +68,6 @@ class Controller extends Section {
|
|||
printerFk: this.invoice.printerFk,
|
||||
|
||||
};
|
||||
|
||||
this.$http.get(`Addresses/${clientAndAddress.addressId}`)
|
||||
.then(res => {
|
||||
this.address = res.data;
|
||||
|
@ -118,7 +122,6 @@ class Controller extends Section {
|
|||
for (const clientAndAddress of clientsAndAddresses)
|
||||
this.clients.push(clientAndAddress.clientId);
|
||||
this.currentClient = 0;
|
||||
this.lastClientId = clientsAndAddresses[clientsAndAddresses.length - 1].clientId;
|
||||
|
||||
return this.invoiceOut(invoice, clientsAndAddresses);
|
||||
})
|
||||
|
|
|
@ -14,5 +14,5 @@ To client: Hasta cliente
|
|||
Address id: Id dirección
|
||||
Printer: Impresora
|
||||
of: de
|
||||
Id Client: Id Cliente
|
||||
Client: Cliente
|
||||
Invoicing: Facturando
|
||||
|
|
Loading…
Reference in New Issue