Published on : May 24, 2020
URL : https://loantap.in/dummy-app/sample-ps.check_rules
Service Description: This service will be used to check the eligibility against the given check in the form of string.
Input 1 :
Comma seperated string
config="job_type,loan_city"
Usage :
[product_services.rules.check config="job_type,loan_city" o.set=template.result /]
Logic :
- Creates an array of calc and error summary at root level, this service would internally call one more service called sublan_eligibility:
- calc : array will have calculation returned by sublan calc
- Summary: It will give success or error in case if any of the eligibility fails will result in an error.
- Return the array with calc and summary
Sample Output :
array(2)
[
"calc" => array(2)
[
"job_type" => array(1)
"loan_city" => array(3)
[
"status" => string(5) "error"
"debug" => array(0)
"message" => string(12) "invalid city"
]
]
"summary" => array(2)
]