refactor
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
161514582d
commit
93417e9676
|
@ -1,3 +1,3 @@
|
|||
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('FixedPrice', '*', '*', 'ALLOW', 'ROLE', 'buyer');
|
||||
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('PayDem', '*', 'READ', 'ALLOW', 'ROLE', 'employee');
|
||||
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Receipt', 'createReceipt', '*', 'ALLOW', 'ROLE', 'administrative');
|
||||
INSERT INTO `salix`.`ACL` (`model`, `property`, `accessType`, `permission`, `principalType`, `principalId`) VALUES ('Client', 'createReceipt', '*', 'ALLOW', 'ROLE', 'administrative');
|
|
@ -1,6 +1,6 @@
|
|||
module.exports = function(Self) {
|
||||
require('../methods/receipt/filter')(Self);
|
||||
require('../methods/receipt/createReceipt')(Self);
|
||||
require('../methods/client/createReceipt')(Self);
|
||||
|
||||
Self.validateBinded('amountPaid', isNotZero, {
|
||||
message: 'Amount cannot be zero',
|
||||
|
|
|
@ -99,7 +99,7 @@ class Controller extends Dialog {
|
|||
if (response !== 'accept')
|
||||
return super.responseHandler(response);
|
||||
|
||||
return this.$http.post(`Receipts/${this.$params.id}/createReceipt`, this.receipt)
|
||||
return this.$http.post(`Clients/${this.$params.id}/createReceipt`, this.receipt)
|
||||
.then(() => super.responseHandler(response))
|
||||
.then(() => this.vnApp.showSuccess(this.$t('Data saved!')));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue