...
/{entityName}/user.defined.report/{reportId}?entityId=10&parse=true
where
...
{entityName} = Name of the entity (Client, Loan etc)
{reportId} = The Identifier for the report template
entityId =
...
(Optional Query param) Identifier for compound Entities (Ex: The Loan Product Id for a Loan)
...
parse=(Optional Query param) When present, causes the server to replace placeholders with actual values. Else, the server would return the actual report Template (used when we want to display/edit the template at the client side etc)
2.2 Client side Parser
Alternatively, we could also have services at the server side that exposes the context sensitive data and a Client side parser that would take care of merging the report template with the actual values exposed by the RESTful service
The Restful service would have a URL similar to
/{entityName}/report
3 Database changes
...