Regarding database design
Posted on 2014-03-29
I am writing the code in struts2 with spring security by assigning the roles and permissions. I am trying to accomplish the following:
There is a status of the employee as bench or blocked. Blocked means the employee is alloted for a project but not yet assigned. An employee (by default in bench state) can be blocked by Project manager. Blocking indicates that employee is alloted for a particular project and if not assigned into the project in two weeks he will be released, indicates that the employee is in bench again.
An blocked employee can be made assigned if he selected into the project. Assigned is the subset of block.
Clicking a link called assign, the status of the employee (default is bench) should change from bench to assigned. (assigned is a status given to an employee).
Clicking a link called block, the status of the employee (default is bench) should change from bench to blocked. (blocked is also status of the employee).
Clicking a link called release, the status of the employee should change from assigned to release.
A resource can be blocked which means they can be assigned a project but not yet be assigned. A blocked resource that has not assigned for two weeks needs to be released automatically, how can I do that?
How should I structure the database for this? Also, how do I declare the pojo classes for this type of design?
Blocked means he is into project but not yet confirmed, assigned means he is into the project and confirmed as billing.
How to design the pojo classes and database design for this type of situation ?
I just want the table structure and pojo classes so that i can develop the coding
thanks in advance