#744 fix edit sale bug, boton MAS descuento

This commit is contained in:
Gerard 2018-10-23 12:39:25 +02:00
parent 86f6253ed7
commit 6b03ead37d
1 changed files with 2 additions and 5 deletions

View File

@ -23,13 +23,10 @@ class Controller {
this.imagesPath = '//verdnatura.es/vn-image-data/catalog';
}
$postLink() {
this.loadVAT();
}
set sales(value) {
this._sales = value;
this.loadSubTotal();
this.loadVAT();
}
get sales() {
@ -48,7 +45,7 @@ class Controller {
loadVAT() {
this.VAT = 0.0;
if (!this.$stateParams.id) return;
if (!this.$stateParams.id || !this.sales) return;
this.$http.get(`/ticket/api/Tickets/${this.$stateParams.id}/getVAT`).then(res => {
this.VAT = res.data || 0.0;
});