You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Cash Payments page is fairly complex since it deals with both Cautions and Cash Payments against invoices. The current implementation does not block Cash Payment requests from submitting if there are no cash items (though the server rejects them). We can do better by blocking the submit before it even sends an HTTP request and create an error message that informs the user the need to add invoices to the bill.
Steps to Reproduce
Load the cash payments page.
Select a cashbox with any currency defined.
Submit a payment without invoice items.
Expected Result
The module should error with a nice error message ('You have not added invoices to pay against. Please add them and resubmit')
Actual Result
An HTTP POST is sent to /cash and returned as a 400 error without a good error message.
The text was updated successfully, but these errors were encountered:
This commit introduces a check to verify that invoices are being paid
against when a user submits the cash form. If there are no invoices, a
danger notification is emitted telling the user to add some invoices and
no HTTP request is sent.
Previous, this would be validated on the server - the client no longer
even needs to make the HTTP request.
ClosesThird-Culture-Software#772.
jniles
pushed a commit
to jniles/bhima
that referenced
this issue
Nov 25, 2016
This commit introduces a check to verify that invoices are being paid
against when a user submits the cash form. If there are no invoices, a
danger notification is emitted telling the user to add some invoices and
no HTTP request is sent.
Previous, this would be validated on the server - the client no longer
even needs to make the HTTP request.
ClosesThird-Culture-Software#772.
This commit introduces a check to verify that invoices are being paid
against when a user submits the cash form. If there are no invoices, a
danger notification is emitted telling the user to add some invoices and
no HTTP request is sent.
Previous, this would be validated on the server - the client no longer
even needs to make the HTTP request.
Closes#772.
The Cash Payments page is fairly complex since it deals with both Cautions and Cash Payments against invoices. The current implementation does not block Cash Payment requests from submitting if there are no cash items (though the server rejects them). We can do better by blocking the submit before it even sends an HTTP request and create an error message that informs the user the need to add invoices to the bill.
Steps to Reproduce
Expected Result
The module should error with a nice error message ('You have not added invoices to pay against. Please add them and resubmit')
Actual Result
An HTTP POST is sent to
/cash
and returned as a 400 error without a good error message.The text was updated successfully, but these errors were encountered: