mGramSeva - Water Service
Overview
Water service is the egov application, which helps and gives flexibility to municipal and citizen to handle the water service like apply for water connection, search water connection. The application will go on different stages that state can verify by given roles, If that role can take the action then the application will go to the next state. Based on the state, citizen will get notification (SMS and in-app ). Citizens also can pay for application fees or employees can collect the fee for the application.
Pre-requisites
Before you proceed with the documentation, make sure the following pre-requisites are met -
Java 8
Kafka server is up and running
egov-persister service is running and has water service persister config path added in it
PSQL server is running and database is created to store water connection / application data
knowledge of eGov-mdms service, eGov-persister, eGov-idgen, eGov-sms, eGov-email,eGov-user, eGov-localization, eGov-workflow-service will be helpful.
Key Functionalities
Add old water connection to the system with/with out arrears.
Create new Water Connection.
Searching for water connections.
Notifications on creation , bill generation, payment of Connection
Environment Variables | Description |
| This variable contain the idgen format name for water application |
| This variable contain the idgen format for water application |
| This variable contain the idgen format name for water connection |
| This variable contain the idgen format for water connection |
| This variable is to check the SMS notifications are enabled or not. |
| This variable is used to get the bill pdf sms link to download from mobile sms link. |
| This variable is used to check the localizations are state level or not. |
| This variable is used to download the receipt pdf from sms link provided |
| This variable is used to download the reciept from user events / on screen display download at download reciept. |
| This variable is used to give the link to user via SMS to get the survey feed back regarding water services. |
Interaction Diagram:
Table UML diagram:
Configuration Details
Mdms configuration:
mdms-mgramseva/data at DEV · egovernments/egov-mdms-data
master-config.json for water service
"ws-services-masters": {
"CheckList": {
"masterName": "CheckList",
"isStateLevel": true,
"uniqueKeys": [
"$.code"
]
},
"Category": {
"masterName": "Category",
"isStateLevel": true,
"uniqueKeys": [
"$.code"
]
},
"SubCategory": {
"masterName": "SubCategory",
"isStateLevel": true,
"uniqueKeys": [
"$.code"
]
},
"connectionType": {
"masterName": "connectionType",
"isStateLevel": true,
"uniqueKeys": [
"$.code"
]
},
}
ConnectionType
Two connectiontype supported Metered and Non metered
{
"tenantId": "pb",
"moduleName": "ws-services-masters",
"connectionType": [
{
"name": "Metered",
"code": "Metered",
"active": true
},
{
"name": "Non Metered",
"code": "Non_Metered",
"active": true
}
]
}
CheckList
CheckList is used to define the Q & A for the feedback form and its validation
{
"tenantId": "pb",
"moduleName": "ws-services-masters",
"CheckList": [{
"code": "HAPPY_WATER_SUPPLY",
"name":"Are you happy with water supply?",
"active": true,
"required": true,
"type": "SINGLE_SELECT",
"options": [
"1",
"2",
"3",
"4",
"5"
]
},
{
"code": "WATER_SUPPLY_REGULAR",
"name": "Is the water supply regular?",
"active": true,
"type": "SINGLE_SELECT",
"required": true,
"options": [
"1",
"2",
"3",
"4",
"5"
]
},
{
"code": "WATER_QUALITY_GOOD",
"name":"Is the water quality good?",
"active": true,
"type": "SINGLE_SELECT",
"required": true,
"options": [
"1",
"2",
"3",
"4",
"5"
]
}
]
}
Category
Predefined list of categories allowed
SubCategory
Predefined list of subcategories allowed
Persister configuration:
config-mgramseva/water-persist.yml at DEV · egovernments/configs
https://github.com/egovernments/configs/blob/master/egov-persister/water-meter.yml
Actions & Role Action Mapping
Actions
Role Action Mapping
Roles to be available:
Workflow business service config:
Create businessService (workflow configuration) using the /businessservice/_create
. Following is the product configuration for water service
Indexer config for water-service:
The indexer provides the facility for indexing the data to elastic search. https://github.com/egovernments/config-mgramseva/blob/DEV/egov-indexer/water-service.yml
Setup:
Write the configuration for water service. https://github.com/egovernments/config-mgramseva/blob/DEV/egov-indexer/water-service.yml
Provide the absolute path of the checked-in file to DevOps, to add it to the file-read path of egov-indexer. The file will be added to the egov-indexer's environment manifest file for it to be read at the start-up of the application.
Put indexer config file to the config repo under egov-indexer folder.(https://github.com/egovernments/configs/tree/master )
Run the egov-indexer app, Since it is a consumer, it starts listening to the configured topics and indexes the data.
Notification :
Notification will be sent to the property owners and connection holders on
Demand Generation for connection
On Payment
Deployment Details
Add mdms configs required for water connection registration and restart mdms service.
Deploy the latest version of ws-services service.
Add water-service and water-services-meter persister yaml path in persister configuration and restart persister service.
Add Role-Action mapping for API’s.
Create businessService (workflow configuration) according for trade water connection, modify water connection
Add ws-service indexer yaml path in indexer service configuration and restart indexer service.
Integration
Integration Scope
This ws-service module is use to manage water service connections against a property in the system.
Integration Benefits
Provide backend support for the different water connection registration process.
Mseva and SMS notifications on application status changes.
Elastic search index for creating visualizations and Dashboards.
Supports workflow which is configurable
Steps to Integration
To integrate, host of ws-service module should be overwritten in helm chart.
/ws-services/wc/_create
should be added as the create endpoint for creating water application/connection in the system/ws-services/wc/_search
should be added as the search endpoint .This method handles all requests to search existing records depending on different search criteria/ws-services/wc/_update
should be added as the update endpoint. This method is used to update fields in existing records or to update status of application based on workflow./ws-services/wc/_revenueDashboard
Should be added to get the revenue dashboard metrix data. It will show the data of revenue collections information./ws-services/wc/_revenueCollectionData
Should be added to get the main monthly dashboard details. It is used to show the table data based on the no of months for selected financial year.
Reference Docs
Doc Links
Title | Link |
API Swagger Documentation | |
Water Calculator Service |
API List
Title | Link |
/ws-services/wc/_create | |
/ws-services/wc/_update | |
/ws-services/wc/_search | |
/ws-services/wc/_submitfeedback | |
/ws-services/wc/_getfeedback | |
/ws-services/wc/_revenueDashboard | |
/ws-services/wc/_revenueCollectionData |
(Note: All the API’s are in the same postman collection therefore same link is added in each row)