How to change dashboard as per roles to employees in yii2?

60 views Asked by At

I am using yii2 basic and Admin LTE

I have Employee table and I have assigned Employee model to user application component and implemented RBAC.

I have Dashboard Controller and view.

1. Now when admin logs in, and clicks on Dashboard menu, he can see 4 info boxes showing statistics as follows:

  1. Total no of employees
  2. Total SHG Groups
  3. Total Churches
  4. Total Courses

2. Now when fieldofficer logs in, and clicks on Dashboard, he can also view the same statistics.

fieldofficer creates, views, updates and deletes only his own created SHGGroups.

So fieldofficer on his dashboard should be able to see only one info box showing total no of SHGGroups he own/creates

How to accomplish this?

0

There are 0 answers