Merge pull request 'Added logic to the employee list to hide the 'Manage Role' and 'Suspend' buttons for system-defined employees' (#85) from Ashutosh_Enhancement#198_Added_IsSystem into Issue_May_2W
Reviewed-on: #85
This commit is contained in:
commit
284d36e5ac
@ -556,7 +556,7 @@ const EmployeeList = () => {
|
|||||||
>
|
>
|
||||||
<i className="bx bx-edit bx-sm"></i> Edit
|
<i className="bx bx-edit bx-sm"></i> Edit
|
||||||
</Link>
|
</Link>
|
||||||
<button
|
{!item.isSystem && (<><button
|
||||||
className="dropdown-item py-1"
|
className="dropdown-item py-1"
|
||||||
onClick={() => suspendEmployee(item.id)}
|
onClick={() => suspendEmployee(item.id)}
|
||||||
>
|
>
|
||||||
@ -572,7 +572,7 @@ const EmployeeList = () => {
|
|||||||
>
|
>
|
||||||
<i className="bx bx-cog bx-sm"></i> Manage
|
<i className="bx bx-cog bx-sm"></i> Manage
|
||||||
Role
|
Role
|
||||||
</button>
|
</button></>)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
|||||||
@ -15,7 +15,7 @@ export const RolesRepository = {
|
|||||||
|
|
||||||
|
|
||||||
getEmployeeRoles:(id)=>api.get(`/api/employee/roles/${id}`),
|
getEmployeeRoles:(id)=>api.get(`/api/employee/roles/${id}`),
|
||||||
createEmployeeRoles:(data)=>api.post("/api/employee/roles",data)
|
createEmployeeRoles:(data)=>api.post("/api/roles/assign-roles",data)
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user