Skip to content
This repository has been archived by the owner on Nov 26, 2024. It is now read-only.

Commit

Permalink
PFM-5998: Added Sarpanch, Secretory, Revenue Collector
Browse files Browse the repository at this point in the history
  • Loading branch information
anilsingha-eGov committed Apr 10, 2024
1 parent 3d43c79 commit 35fda66
Showing 1 changed file with 18 additions and 16 deletions.
34 changes: 18 additions & 16 deletions frontend/mgramseva/lib/utils/role_actions.dart
Original file line number Diff line number Diff line change
Expand Up @@ -89,55 +89,57 @@ class RoleActionsFiltering {
switch (route) {
// GP Admin
case Routes.HOUSEHOLD:
return ['COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN'];
return ['COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN','SARPANCH','SECRETORY'];

case Routes.CONSUMER_UPDATE:
return ['GP_ADMIN', 'SUPERUSER', 'COLLECTION_OPERATOR', 'DIV_ADMIN'];
return ['GP_ADMIN', 'SUPERUSER', 'COLLECTION_OPERATOR', 'DIV_ADMIN','SARPANCH','SECRETORY'];

case Routes.CONSUMER_SEARCH_UPDATE:
return ['GP_ADMIN', 'SUPERUSER', 'COLLECTION_OPERATOR', 'DIV_ADMIN'];
return ['GP_ADMIN', 'SUPERUSER', 'COLLECTION_OPERATOR', 'DIV_ADMIN','SARPANCH','SECRETORY'];

case Routes.CONSUMER_CREATE:
return ['GP_ADMIN', 'SUPERUSER', 'COLLECTION_OPERATOR', 'DIV_ADMIN'];
return ['GP_ADMIN', 'SUPERUSER', 'COLLECTION_OPERATOR', 'DIV_ADMIN','SARPANCH','SECRETORY'];

case Routes.HOUSEHOLD_DETAILS:
return ['BULK_DEMAND_PROCESSING', 'COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN'];
return ['BULK_DEMAND_PROCESSING', 'COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN','SARPANCH','SECRETORY'];

case Routes.SEARCH_CONSUMER_RESULT:
return [
'GP_ADMIN',
'BULK_DEMAND_PROCESSING',
'COLLECTION_OPERATOR',
'SUPERUSER',
'DIV_ADMIN'
'DIV_ADMIN',
'SARPANCH',
'SECRETORY'
];

case Routes.HOUSEHOLD_REGISTER:
return ['COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN'];
return ['COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN','SARPANCH','SECRETORY'];

// Expense Processing
case Routes.EXPENSE_SEARCH:
return ['EXPENSE_PROCESSING', 'SUPERUSER', 'DIV_ADMIN'];
return ['EXPENSE_PROCESSING', 'SUPERUSER', 'DIV_ADMIN','SARPANCH','SECRETORY'];
case Routes.EXPENSES_ADD:
return ['EXPENSE_PROCESSING', 'SUPERUSER', 'DIV_ADMIN'];
return ['EXPENSE_PROCESSING', 'SUPERUSER', 'DIV_ADMIN','SARPANCH','SECRETORY'];
case Routes.EXPENSE_UPDATE:
return ['EXPENSE_PROCESSING', 'SUPERUSER', 'DIV_ADMIN'];
return ['EXPENSE_PROCESSING', 'SUPERUSER', 'DIV_ADMIN','SARPANCH','SECRETORY'];
case Routes.HOUSEHOLDRECEIPTS:
return ['BULK_DEMAND_PROCESSING', 'COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN'];
return ['BULK_DEMAND_PROCESSING', 'COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN','SARPANCH','SECRETORY'];

case Routes.MANUAL_BILL_GENERATE:
return ['BULK_DEMAND_PROCESSING', 'SUPERUSER', 'DIV_ADMIN'];
return ['BULK_DEMAND_PROCESSING', 'SUPERUSER', 'DIV_ADMIN','SARPANCH','SECRETORY'];

// Collection Operator
case Routes.CONSUMER_SEARCH:
return ['COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN'];
return ['COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN','REVENUE_COLLECTOR','SARPANCH','SECRETORY','REVENUE_COLLECTOR'];
case Routes.BILL_GENERATE:
return ['COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN'];
return ['COLLECTION_OPERATOR', 'SUPERUSER', 'DIV_ADMIN','SARPANCH','SECRETORY','REVENUE_COLLECTOR'];

case Routes.DASHBOARD:
return ['SUPERUSER', 'DASHBOARD_VIEWER', 'GP_ADMIN', 'DIV_ADMIN'];
return ['SUPERUSER', 'DASHBOARD_VIEWER', 'GP_ADMIN', 'DIV_ADMIN','SARPANCH','SECRETORY','REVENUE_COLLECTOR'];
case Routes.REPORTS:
return ['SUPERUSER', 'DASHBOARD_VIEWER', 'GP_ADMIN', 'DIV_ADMIN'];
return ['SUPERUSER', 'DASHBOARD_VIEWER', 'GP_ADMIN', 'DIV_ADMIN','SARPANCH''SECRETORY','REVENUE_COLLECTOR'];
default:
return [];
}
Expand Down

0 comments on commit 35fda66

Please sign in to comment.