diff --git a/modules/client/front/balance/create/index.js b/modules/client/front/balance/create/index.js
index f5d6e7abf0..22426a2693 100644
--- a/modules/client/front/balance/create/index.js
+++ b/modules/client/front/balance/create/index.js
@@ -6,8 +6,7 @@ class Controller extends Dialog {
super($element, $, $transclude);
this.receipt = {
- payed: new Date(),
- clientFk: this.$params.id
+ payed: new Date()
};
}
@@ -99,7 +98,7 @@ class Controller extends Dialog {
if (response !== 'accept')
return super.responseHandler(response);
- return this.$http.post(`Clients/${this.$params.id}/createReceipt`, this.receipt)
+ return this.$http.post(`Clients/${this.clientFk}/createReceipt`, this.receipt)
.then(() => super.responseHandler(response))
.then(() => this.vnApp.showSuccess(this.$t('Data saved!')));
}
diff --git a/modules/client/front/balance/index/index.html b/modules/client/front/balance/index/index.html
index ac9c39d7f8..468ac98c38 100644
--- a/modules/client/front/balance/index/index.html
+++ b/modules/client/front/balance/index/index.html
@@ -139,7 +139,8 @@
+ company-fk="$ctrl.companyId"
+ client-fk="$ctrl.$params.id">