Click here to Skip to main content
15,904,288 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have come across a complex scenario where I have to design a database for a in-house project of my company. The project is claim management system where employee can

submit their different claims i.g medical, traveling etc. But this claims will also have to get approval from specific managers before they are accepted. Here the heirarchy of

the approval managers can b different based on the designation of the employee and type of the claim. Lets suppose for a medical claim if employee designation is Senior Software

Engineer then their claim gets first approved by Team Lead then from Manager. For the same designation for a traveling allowance claim will directly approved by Director. If

designation is manager then for his medical claim, he will get directly approval from Director. So far, I have come across following tables,

ClaimTypes(ClaimId, Claim)

EmployeeDesignation(Id, Designation, Manager(parentId))

ClaimApprovalLevel(Id, ClaimId, designationId, Approvallevel, approvalAuthority)

But here I am confused that what if a same employee of same designation need approval from two different managers ? Is my solution viable if there has to be added further heirarchies of managers in future ?
Posted

1 solution

We use such a system here (hierarchical approval chain) for Leave Approval, Software and Hardware requests, purchases, &etc: JavaScript/PHP/SQL.

It works rather well, too, as no one can ever lose a paper on their desktop. Also, it has a built in annoyance feature so that emails are periodically dispatched to the next-in-line approver until they do their job. It even branches, in the case of purchases, to different chains based upon the $ amount.

The chains you want should give an order and terminate when the max value for that particular chain is reached - this should be gotten dynamically so you can implement multiple such hierarchies for various purposes.

The details, unfortunately, are company property unless they say otherwise. The concept, however, of multiple chains with multiple tiers is really the general case for such problems.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900