mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-02-20 14:54:15 +01:00
(bug) update VAT name in front after change
This commit is contained in:
parent
29b92475bb
commit
5630872b5f
@ -128,6 +128,17 @@ Application.Controllers.controller('InvoicesController', ['$scope', '$state', 'I
|
||||
growl.error(message);
|
||||
};
|
||||
|
||||
/**
|
||||
* Callback triggered when the VAT settings were successfully updated
|
||||
*/
|
||||
$scope.onVATSuccess = (message) => {
|
||||
$scope.onSuccess(message);
|
||||
Setting.query({ names: "['invoice_VAT-name', 'invoice_VAT-rate']" }, (vatSettings) => {
|
||||
$scope.invoice.VAT.rate = vatSettings['invoice_VAT-rate'];
|
||||
$scope.invoice.VAT.name = vatSettings['invoice_VAT-name'];
|
||||
}, $scope.onError);
|
||||
};
|
||||
|
||||
/**
|
||||
* Callback triggered in case of success
|
||||
*/
|
||||
@ -526,20 +537,6 @@ Application.Controllers.controller('InvoicesController', ['$scope', '$state', 'I
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* Callback used in PaymentScheduleList, in case of error
|
||||
*/
|
||||
$scope.onError = function (message) {
|
||||
growl.error(message);
|
||||
};
|
||||
|
||||
/**
|
||||
* Callback triggered when the user has successfully updated his card
|
||||
*/
|
||||
$scope.onSuccess = function (message) {
|
||||
growl.success(message);
|
||||
};
|
||||
|
||||
/**
|
||||
* Callback triggered after the gateway failed to be configured
|
||||
*/
|
||||
|
@ -93,7 +93,7 @@
|
||||
ng-blur="legalsEditEnd($event)">
|
||||
</div>
|
||||
</form>
|
||||
<vat-settings-modal is-open="isOpenVatModal" toggle-modal="toggleVatModal" on-error="onError" on-success="onSuccess"></vat-settings-modal>
|
||||
<vat-settings-modal is-open="isOpenVatModal" toggle-modal="toggleVatModal" on-error="onError" on-success="onVATSuccess"></vat-settings-modal>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
|
@ -721,7 +721,7 @@ fr:
|
||||
total_including_all_taxes: "Total TTC"
|
||||
VAT_disabled: "TVA désactivée"
|
||||
VAT_enabled: "TVA activée"
|
||||
including_VAT: "Dont TVA {RATE} % de {AMOUNT}"
|
||||
including_VAT: "Dont {NAME} {RATE} % de {AMOUNT}"
|
||||
including_total_excluding_taxes: "Dont total HT"
|
||||
including_amount_payed_on_ordering: "Dont montant payé à la commande"
|
||||
settlement_by_debit_card_on_DATE_at_TIME_for_an_amount_of_AMOUNT: "Règlement effectué par carte bancaire le {DATE} à {TIME}, pour un montant de {AMOUNT}"
|
||||
|
Loading…
x
Reference in New Issue
Block a user