Apply BPA OC

The BPA OC 'apply' is the major feature in BPA OC Module. It allows Stakeholder to create BPA OC Applications .

Every application is a part of the workflow.

Stepper 1 :

https://egov-micro-qa.egovernments.org/citizen/oc-bpa/apply?tenantId=pb.amritsar

Source path : https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-config/screens/specs/oc-bpa/apply.js

All the drop down data are mapped through mdms response.

For to display MDMS data we have common container in UI Framework ( “getSelectField“ ).

In BPA OC : We used common container for Application Type , Service Type , Risk Type , Occupancy Type and Sub Occupancy Type .

Sample JSON for Structure Type and Sub Structure Type :

applicationType: getSelectField({ label: { labelName: "Application Type", labelKey: "BPA_BASIC_DETAILS_APPLICATION_TYPE_LABEL" }, placeholder: { labelName: "Select Application Type", labelKey: "BPA_BASIC_DETAILS_APPLICATION_TYPE_PLACEHOLDER" }, jsonPath: "BPA.applicationType", sourceJsonPath: "applyScreenMdmsData.BPA.ApplicationType", required: true, gridDefination: { xs: 12, sm: 12, md: 6 } }),

jsonPath is used to store the data in specified path when clicking event triggers or on handleFieldChange.

sourceJsonPath is the path where the data is fetched to populate in the dropdown.

Mdms data :

Application Type data is fetched from https://github.com/egovernments/egov-mdms-data/blob/master/data/pb/BPA/ApplicationType.json

Service Type data is fetched from https://github.com/egovernments/egov-mdms-data/blob/master/data/pb/BPA/ServiceType.json.

Occupancy Type data is fetched from https://github.com/egovernments/egov-mdms-data/blob/master/data/pb/BPA/OccupancyType.json

Sub Occupancy data is fetched from https://github.com/egovernments/egov-mdms-data/blob/master/data/pb/BPA/SubOccupancyType.json

Basic details is the first stepper of BPA OC:

Source Path: https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-config/screens/specs/oc-bpa/applyResource/scrutinyDetails.js

The disable fields data is fetched once the Occupancy Certificate Scrutiny Number field is filled and made a search call on edcr-service.

Apply Footer

https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-config/screens/specs/oc-bpa/applyResource/footer.js

The Next and Previous buttons are configured this json file.

BPA OC create call is triggered on 1st stepper’s Next button onclick().

NOC Search call is triggered after success of BPA Create.

 

Stepper 2 :

Source Path : https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-config/screens/specs/oc-bpa/applyResource/documentAndNocDetails.js

Mdms data : https://github.com/egovernments/egov-mdms-data/blob/master/data/pb/BPA/DocTypeMapping.json

The data formatting logic is as shown below. prepareDocumentsUploadData(state, dispatch); in https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-utils/commons.js

NOC Section :
Source Path : https://github.com/egovernments/frontend/blob/develop/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-config/screens/specs/egov-bpa/noc.js

 

MDMS Date: https://github.com/egovernments/egov-mdms-data/blob/master/data/pb/NOC/DocumentTypeMapping.json

The data formatting logic is as shown below.

prepareNOCUploadData(state, dispatch) and prepareNocFinalCards(state, dispatch) in https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-utils/commons.js

Stepper 3:

This is the Review/Summary screen - https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-config/screens/specs/oc-bpa/summary.js

Update BPA OC API - bpa-services/v1/bpa/_update and Update NOC API - /noc-services/v1/noc/_update is called on SEND TO CITIZEN.

 

Success Screen :

Souce path : https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-config/screens/specs/oc-bpa/acknowledgement.js

Search-Preview :

Source Path : https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-bpa-dev/src/ui-config/screens/specs/oc-bpa/search-preview.js

To load search preview page egov-workflow-v2/egov-wf/process/_search?businessIds=PB-BP-2020-07-23-003480&history=true&tenantId=pb.amritsar API should return workflow history.

The topmost card is mainly rendered using the workflow response.https://github.com/egovernments/frontend/blob/master/web/rainmaker/dev-packages/egov-workflow-dev/src/ui-molecules-local/TaskStatusComponents/index.js

View History Buttons gives the list of workflow actions performed on the application.

 

BPA OC Workflow :

Role

Action

Next State

Status

Role

Action

Next State

Status

BPA_ARCHITECT/BPA_ENGINEER/BPA_BUILDER/BPA_STRUCTURALENGINEER/BPA_TOWNPLANNER/BPA_SUPERVISOR

INITIATE

SEND_TO_CITIZEN

INITIATED

BPA_ARCHITECT/BPA_ENGINEER/BPA_BUILDER/BPA_STRUCTURALENGINEER/BPA_TOWNPLANNER/BPA_SUPERVISOR

SEND_TO_CITIZEN

CITIZEN_APPROVAL_PENDING

CITIZEN_APPROVAL_INPROCESS

CITIZEN

SEND_TO_ARCHITECT

INPROGRESS

INPROGRESS

BPA_ARCHITECT/BPA_ENGINEER/BPA_BUILDER/BPA_STRUCTURALENGINEER/BPA_TOWNPLANNER/BPA_SUPERVISOR

APPLY

PENDING_APPL_FEE_PAYMENT

PENDING_APPL_FEE

CITIZEN/BPA_ARCHITECT/BPA_ENGINEER/BPA_BUILDER/BPA_STRUCTURALENGINEER/BPA_TOWNPLANNER/BPA_SUPERVISOR/SYSTEM_PAYMENT/CEMP

PAY

DOC_VERIFICATION_PENDING

DOC_VERIFICATION_INPROGRESS

BPA_VERIFIER

FORWARD

FIELDINSPECTION_PENDING

FIELDINSPECTION_INPROGRESS

BPA_FIELD_INSPECTOR

FORWARD

NOC_VERIFICATION_PENDING

NOC_VERIFICATION_INPROGRESS

BPA_NOC_VERIFIER

FORWARD

PENDINGAPPROVAL

APPROVAL_INPROGRESS

BPA_APPROVER

APPROVE

PENDING_SANC_FEE_PAYMENT

PENDING_SANC_FEE_PAYMENT

CITIZEN/BPA_ARCHITECT/BPA_ENGINEER/BPA_BUILDER/BPA_STRUCTURALENGINEER/BPA_TOWNPLANNER/BPA_SUPERVISOR/SYSTEM_PAYMENT/CEMP

PAY

APPROVED

APPROVED

 

API Call Role Action mapping:

API

Action id

Roles

API

Action id

Roles

1

/egov-mdms-service/v1/_search

954

LOA_CREATOR,SUPERUSER,WO_CREATOR,AE_CREATOR,WORKS_MASTER_CREATOR,

2

/egov-location/location/v11/boundarys/_search

1429

EMPLOYEE,CITIZEN,GRO,PGR-ADMIN,CSR,TL_APPROVER,TL_CEMP,SUPERUSER,DE_CREATOR,

3

/user/_search

604

SUPERUSER,SYS_INTEGRATOR_FINANCE,SYS_INTEGRATOR_WATER_SEW,EGF_BILL_CREATOR,EMPLOYEE,EMPLOYEE_FINANCE,

4

/bpa-services/v1/bpa/_create

1924

BPA_ARCHITECT

5

/bpa-services/v1/bpa/_update

1931

BPA_ARCHITECT, CITIZEN, BPA_VERIFIER, BPA_APPROVER, BPA_FIELD_INSPECTOR, BPA_NOC_VERIFIER

6

/filestore/v1/files/url

1528

SUPERUSER,EMPLOYEE,CITIZEN,GRO,DGRO,

7

/billing-service/bill/v2/_fetchbill

1862

EMPLOYEE,CITIZEN

 

NOC Workflow :

Role

Action

Next State

Status

Role

Action

Next State

Status

BPA_ARCHITECT/BPA_ENGINEER/BPA_BUILDER/BPA_STRUCTURALENGINEER/BPA_TOWNPLANNER/BPA_SUPERVISOR

INITIATE

INPROGRESS

INITIATED

BPA_VERIFIER/BPA_FIELD_INSPECTOR/BPA_NOC_VERIFIER

INPROGRESS

APPROVE

INPROGRESS

FIRE_NOC_APPROVER

APPROVE

APPROVED

APPROVED

API Call Role Action mapping:

API

Action id

Roles

API

Action id

Roles

1

/egov-mdms-service/v1/_search

954

LOA_CREATOR,SUPERUSER,WO_CREATOR,AE_CREATOR,WORKS_MASTER_CREATOR,

2

/noc-services/v1/noc/_update

2002

BPA_ARCHITECT, CITIZEN, EMPLOYEE

3

/filestore/v1/files/url

1528

SUPERUSER,EMPLOYEE,CITIZEN,GRO,DGRO,

4

/noc-services/v1/noc/_search

2001

CITIZEN, EMPLOYEE

Â