ajency / cashflow-issue-tracker

Issue Tracker for issues
0 stars 1 forks source link

BUG - Bill payment can be passed for a bill parent ID that does not exist #829

Closed HazelColaco19 closed 4 years ago

HazelColaco19 commented 4 years ago

Describe the bug

Bill payment can be passed for a bill parent ID that does not exist.

image

[Link](http://ajency-qa.kibana.toppeq.com/app/kibana#/discover?_g=()&_a=(columns:!(accountSubType,_id),filters:!((%27$state%27:(store:appState),meta:(alias:!n,disabled:!f,index:%27971c7830-77db-11ea-9bff-17296d6cdc0e%27,key:companyId,negate:!f,params:(query:5545,type:phrase),type:phrase,value:%275,545%27),query:(match:(companyId:(query:5545,type:phrase)))),(%27$state%27:(store:appState),meta:(alias:!n,disabled:!t,index:%27971c7830-77db-11ea-9bff-17296d6cdc0e%27,key:accountSubType.keyword,negate:!f,params:(query:OtherMiscellaneousServiceCost,type:phrase),type:phrase,value:OtherMiscellaneousServiceCost),query:(match:(accountSubType.keyword:(query:OtherMiscellaneousServiceCost,type:phrase))))),index:%275bf98340-726a-11ea-9bff-17296d6cdc0e%27,interval:auto,query:(language:lucene,query:%27%27),sort:!(_score,desc)))

Expected:

If the bill does not exist, the bill payment request should not go through

legred21 commented 4 years ago

fetch bill method did not called in Validation method. Issue fixed by calling fetch bill method to check for bill

HazelColaco19 commented 4 years ago

Fixed. If bill number doesnt exist, it throws error