Employee Inbox

Employee Inbox

Objective

Provide Employee to show the Assigned applications and all the applications which are pending for action .

Route - https://egov-micro-uat.egovernments.org/employee/inbox

Technical Implementation Details:

Inbox screen is loaded based on the file https://github.com/egovernments/frontend/blob/master/web/rainmaker/packages/employee/src/modules/employee/Inbox/index.js

Inbox screen can be divided into 4 sub components as listed below,

  1. Sidebar

  2. Quick action button

  3. Service List

  4. Inbox worklist

Sidebar:

Action Menu is the component which shows the menu items in the sidebar based on the response from the

access/v1/actions/mdms/_get API .

Action Menu component file is present inhttps://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-ui-kit-dev/src/common/common/ActionMenu/index.js

based on the response the actions gets filtered based on the condition navigationURL

Quick action:

Quick Action button which shows the menu based on the response from the

access/v1/actions/mdms/_get API .

Quick Action button is present in https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-ui-framework-core/src/ui-molecules/MenuButton/index.js

based on the response the actions gets filtered based on the condition item.url === "quickAction"

Service List:

Service List is the component which shows the menu based on the response from the

access/v1/actions/mdms/_get API .

based on the response the actions gets filtered based on the condition item.url === "card"

Inbox worklist

Inbox worklist is the component which shows the records based on the response from the

/egov-workflow-v2/egov-wf/process/_search API .

Inbox worklist contains options to filter and search the records based the options.

Fetching all the records from the process instance is not made a single call since we might lot of records,

so we make a call to get the total count from egov-workflow-v2/egov-wf/process/_count API

then we load initial records by 2 network calls one maximum 500 and the remaining records.

once we receive all the records we load locality of the records. based on the locality search provided from the service (BUSINESS SERVICE). Except for the Property Services , as for property records we load through property search.

 

Assigned to me Tab :

Assigned to me Tab which shows the Assigned applications based on the logged in user.

from the process instance response we get all the records from which we filter the records based on the following condition

get(item, 'assignes[0].uuid')=== uuid;

here uuid is the logged in Employees User id and item is the total records .

SLA,

SLA of the Application is based on the businesssServiceSla  and it is converted in the following conversion.

item.businesssServiceSla / (1000 * 60 * 60 * 24)

Nearing Escalation and Escalated

Nearing Escalation and Escalated is identified based on the businesssServiceSla  present in that record and the configured MDMS data wfSlaConfig

it contains the slot color and percentage.

Pagination

Pagination is configured in the mdms to hold default records and default options to show rows per page

Table and Table pagination can be accessed from this file

MDMS config

 

{ "tenantId": "pb", "moduleName": "common-masters", "TablePaginationOptions": [ { "rowsPerPageOptions": [25, 50, 100], "defaultValue": 100 } ] }

Application Redirection

In every row we have a option to view / perform action on the record , for that it redirects to the module,

it is configured in

Filter Options,

Here all the filter options are derived from the records that we receive through the process instances.

it was not from any MDMS data.

 

  • ROLE ACTION MAPPING

API

ROLES

ACTION ID

API

ROLES

ACTION ID

1

egov-mdms-service/v1/_search

SUPERUSER , LOA_CREATOR , WO_CREATOR , AE_CREATOR , WORKS_MASTER_CREATOR

954

2

access/v1/actions/mdms/_get

SUPERUSER,EMPLOYEE ,CITIZEN

870

3

user/_search

SUPERUSER,EMPLOYEE ,CITIZEN

604

4

egov-workflow-v2/egov-wf/process/_count

SUPERUSER,EMPLOYEE ,NOC_CEMP,PT_CEMP,TLCEMP

2027

5

egov-workflow-v2/egov-wf/process/_search

EMPLOYEE,CITIZEN,SUPERUSER

1730

6

egov-workflow-v2/egov-wf/businessservice/_search

EMPLOYEE,CITIZEN,SUPERUSER

1743