Only this pageAll pages
Powered by GitBook
Couldn't generate the PDF for 124 pages, generation stopped at 100.
Extend with 50 more pages.
1 of 100

NalJalSeva

Loading...

NalJal

Loading...

Loading...

Loading...

Product Specifications

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Reference Implementations

Loading...

NalJalSeva Platform

Loading...

Loading...

Setup NalJalSeva

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Approach

NalJalSeva: Empowering Rural Water Management With DIGIT

NalJalSeva, powered by the DIGIT platform, is designed for rural communities to independently manage their water supply infrastructure. The solution allows users to add new consumers, generate demand, collect revenue, and record expenditure transactions. It simplifies record-keeping, maintains a consumer database, monitors user charges, and provides a unified system for benchmarking rural governance and operations.

The NalJalSeva solution design impacts the financial and operational governance outcomes in multiple ways. Some of these include:

  • Empowering Local Communities: Villages gain full control over their water systems, promoting long-term sustainability.

  • Digital Governance: Built on DIGIT, NalJalSeva streamlines revenue and expense management, ensuring smooth operation.

  • Transparent and Accountable: Financial and operational activities are visible to local governments, ensuring transparency and accountability.

Problems Addressed By NalJalSeva

The Finance Department and Water Supply and Sanitation Department have limited visibility over the fiscal sustainability of water schemes and get hit by the sudden demand for large funds to clear electricity bills.

The Department of Water Supply & Sanitation (DWSS) face several problems due to the lack of financial visibility of schemes:

  • Unreliable and poor-quality water—Ineffective fiscal resource tracking often results in underfunding of water quality or treatment schemes.

  • Inability to collect adequate water charges — Manual methods of revenue collection from households on account of water charges often lead to shortfalls. Pending dues often accumulate and adversely impact financial planning and proposed schemes.

  • Lack of visibility of revenue and expenditure information - Inadequate financial transparency offers limited insight into how funds are being managed and spent by the local governing bodies. This creates financial blind spots, leading to misallocation of resources and unplanned expenses.

NalJalSeva helps digitise the revenue and expense records of Gram Panchayat Water Supply Committees. The dashboards and data insights provide DWSS and FD officials with visibility into the GPWSC's financial status.

The app offers capabilities to:

  • track and manage the revenue and expenditure records using the digital platform

  • share reports over WhatsApp

  • access updated insights on consumer satisfaction/quality of services provided by local governing bodies

  • view dashboards for a snapshot of collections and expenditures to the Sarpanch/other rural administrative officials

Approach

NalJalSeva integrates with the Fiscal Information Exchange (iFIX) platform to promote transparency and accountability in fiscal transactions. The fiscal events are posted on the platform in a standardised format making it easier to track and manage financial performance. The events are aggregated and processed to provide rich insights on key performance metrics which are available to users in the form of fiscal sustainability dashboards.

The illustration below provides a visualisation of how multiple actors interact with the distinctive Gram Panchayat Water Supply & Sanitation system registries to manage and coordinate various fiscal events. The key actors or stakeholders of the system include system administrators, department workers, local governing bodies, citizens and collection agents. Streamlined interaction between these actors is crucial for effective operations and management of fiscal events to facilitate sustainable and equitable access to basic services within the community.

The NalJalSeva app offers multiple benefits that promote the efficiency and transparency of water management services within local governing bodies.

  • Digital book-keeping - maintains all receipt and expense records in digital format reducing the reliance on physical documents.

  • Account management - simplified consumer and vendor account creation or management

  • Low-effort operations - easy to use and environmentally friendly

  • Minimise manual work - a simple mobile app that saves the time and effort of managing revenue & expenditure transactions

Introducing NalJalSeva

Application designed to collect, manage revenue and expenditure

About NalJalSeva

A digital solution powered by DIGIT that enables the gram panchayat water committee to collect & manage revenue and expenditure.

NalJalSeva meets the objectives of the Jal Jeevan Mission launched by the Department of Drinking Water & Sanitation (DDWS), which aims to "provide safe and adequate drinking water through individual household tap connections by 2024 to all households in rural India." The solution empowers the village communities with the ease of consumer management, billing, collection, expense management and monitoring water supply schemes.

The NalJalSeva mobile app enables rural local bodies to manage revenue and expenditures related to water supply projects. It is designed for water management committee members and collection agents. The collection agents can add consumers (or households) and generate bills and receipt acknowledgements. The app provides an intuitive interface for users at the local governance level along with insightful dashboards for effective decision-making.

Features

NalJalSeva offers multiple features required to manage revenues and expenditures (listed below).

  • Create and maintain household registers

  • Collect payments

  • Download bills & receipts

  • Add and update expense records

Section Overview

This section contains all docs and information required to understand NalJalSeva, its key features, functional scope, and configuration details. Click on the links below to learn more about deploying, configuring, customizing, and using the NalJalSeva app.

Navigation Tips

  • Click on the embedded links within the content to browse topic details

  • Use the contents links available on the right side of the screen to move to a specific heading

  • Find the list of Related Docs links at the bottom of each page to browse through additional product details

Contact Us

Demo Video

A quick walkthrough of NalJalSeva app

access detailed collection reports from each household for accurate insights into consumption and demand

Environment friendly - digital operations ensure all accounts are managed digitally thus reducing paper usage

  • Accountability and transparency - recorded fiscal events and data-driven insights available through performance dashboards ensure accountability and transparency in operations

  • Seamless handover - easy to handover records from one to another Sarpanch

  • Dashboard insights - configurable dashboards provide easy and effective visualisation of local governance performance metrics

  • Better planning - helps in better planning and efficient fund management, leading to better services

  • Builds trust - information sharing about GPWSCs’ performance with citizens helps build trust and confidence

  • Online and cash payment - Online payment through multiple options - Netbanking, Credit/Debit Card, Mobile Wallets. Cash payment is also available

  • Notifications and alerts - SMS alerts, digital bills and receipts shared on registered mobile numbers, active SMS alerts

  • Consumer rating - Citizens can rate the quality of water services in villages/wards. It helps identify problems and improve water services.

  • Full or partial payment - users have the option to make partial payment of bills

  • Common Functions

    Configure UI Screens

    Purchase Certificate

    We currently use the free Let's Encrypt SSL certificate, which is valid for 90 days and must be manually renewed afterwards. There are also several paid SSL certificate options available globally.

    Configure NalJalSeva

    Generate demands and bills
  • Create and edit consumer details

  • Access insights through rich dashboards

  • Technology

    Architecture

    Configure

    User Manual

    Demo Video

    Features & Functions

    NalJalSeva is an app-based solution designed for rural water governance and financial management. It supports local governance by providing tools to support consumer management, billing and collection added to financial reporting.

    The solution enables the governance bodies to maintain financial records following established procedures and practices.

    Key Features Of Nal Jal Seva

    The solution offers an end-to-end solution for managing rural water supply schemes, focusing on maintaining transparency and simplifying financial transactions. It enhances governance and simplifies tasks for local authorities while ensuring accountability.

    View Tabular Dashboard For Expense

    Overview

    The View Tabular Dashboard for expenses provides a view of all expenses incurred during the month.

    Design & Workflows

    Clicking on the Dashboard on the home screen navigates the user directly to the revenue dashboard of the current month. From here, the user can switch to the expenditure tab to get a view of expenses. This provides a tabular view of all expenses incurred in that month.

    Data Points

    Following are the data points/actions needed on the screen:

    Item
    Description

    The table on the screen is a horizontal scrollable one with the leftmost column fixed.

    Edit User Profile

    Overview

    Naljalseva users can edit their basic information like name, add gender, email and change the password using the hamburger menu on any screen.

    Design & Workflows

    Users can click on the hamburger menu from any screen. A slider from the left opens up.

    Users can -

    • Change Language

    • Edit profile

    • Logout

    Changing language changes localization as per standards

    Edit profile takes users to the next screen where changes can be made to the user profile

    • Name - Can be changed

    • Phone number - Cannot be changed

    • Gender - This field is not present by default. Whatever the user enters is stored and saved

    • Email ID - It is an empty field. User input is stored as the user’s email id

    Clicking on save shows a nudge to the user” Details saved successfully”. Upon closing, this user remains on the screen but the fields show as edited.

    Rollout Dashboard

    Overview

    The Rollout Dashboard option is available to all State Users.

    Design & Workflows

    This is the dashboard that gives you a view of the total connections across active users and the total demand generated across the whole state.

    Here we have options to select the date range within which you want to see the data. Further, there is a drill down where we can select districts, blocks, panchayat and schemes as well.

    Water Charges

    Overview

    Users can check the configured Water Charge details in the dashboard for the selected tenant/Scheme.

    Design & Workflow

    Users can click on the VWSC and Water Charges Info card on the home page to view the tabulated rate information details.

    Update Expense

    Overview

    The update expense feature allows users to modify and update expense details.

    Design & Workflows

    Expense modification is allowed based on the status of the payment as highlighted in the scenarios below.

    State Dashboard

    Overview

    The state dashboard option is available to State Users logged in to HRMS.

    Design & Workflows

    Create Git Account In The Client Name

    Overview

    This page provides the steps to follow to create a Git account in the client name.

    Steps

    To create a Git account in the client name, follow the steps below:

  • Register the client on a Git hosting platform such as GitHub, GitLab, or Bitbucket by providing their email address, choosing a username, and setting a secure password.

  • Once the account is set up, they can start using Git to manage their code repositories and collaborate on software development projects with ease.

  • User Management:

    • Login to the application

    • Onboard new users in bulk and manage user profiles

    • Provide walkthroughs for users and gather post-payment feedback

    Consumer and Billing Management:

    • Create, edit, and view consumer details

    • Generate bills for both metered and non-metered connections

    • Bulk demand generation for metered/non-metered connections

    • Collect offline payments and send bills/receipts as PDFsSend SMS notifications related to bills and payments

    Financial Recordkeeping:

    • Add and update expense details

    • View expense and collection data through a tabular dashboard

    • Maintain financial records in compliance with established practices

    Additional Functionalities:

    • View household registers

    • Display notifications on the homepage

    • Update expense search functionality

    • Download bills and receipts

    • Regular app updates to improve user experience

    Configure Backend Services

    Configure the backend services to expand the scope of NalJalSeva

    Village Water & Sanitation Committee (VWSC) User

    HRMS

    Change Password - This takes users to the password changing screen where the old password, new password and confirmed new password have to be entered as per given standards.

    • Dynamic password validation happens the same as in the registration flow.

    • Until all fields are entered, the primary CTA is disabled.

    • Changing the password shows a nudge to the user “Password updated successfully” and closing this nudge takes the user to the user profile screen.

    Scenario 1: When the status is “Unpaid”

    Allows users to modify all the details except the Bill id. But the user has the option to mark the Bill as “Cancelled”.

    Scenario 2: When the status is “Paid”

    Does not allow users to modify any details. But the user has the option to mark the Bill as “Cancelled”.

    Clicking on the State dashboard option displays the state dashboard in Kibana.

    The screen provides options to select the date range for which you want to see the data. Further, there is a drill down where we can select districts, blocks, panchayat and schemes as well.

    Search Expense Bills

    • Search by Bill ID or Vendor

    • The Vendor Name should be a partial match. As the user starts typing a consumer name, respective vendors get filtered in the table displayed below

    • Bill ID should be a partial match. As the user starts typing a New Bill ID, respective Bills should get filtered in the table displayed below

    Filters

    • Default is “All” View. Switching to Paid or Pending filters the table accordingly. Alongside the filter, how many Bills fall into that filter is shown in numbers

    • The table also has sort options for each column (ascending, descending)

    Columns

    • Bill ID - Vendor Name

      • Bill ID is assigned to each bill while creating an expense entry record

      • Sort happens on the Bill ID

    • Expense Type

      • Under which expense head the bill is tagged to

    • Amount

    • Bill Date

    • Paid Date

      • If Bill is not paid, this should show pending in RED

    Value Proposition

    Generate Bills For Metered Connections

    Overview

    Unlike non-metered connections with a billing cycle for demand & bills generated automatically, a metered connection needs more inputs, which helps in volumetric billing.

    Design & Workflow

    A revenue collector can see a CTA to “Generate a new Bill” on the Household details screen.

    1. Clicking “Generate a new Bill” takes users to the bill generation screen where new meter reading details are entered.

    2. The field on the bill generation screen for metered connections is displayed in the table below.

    3. Clicking on “Generate bill” takes the user to the bill generation successful screen.

    4. Logic for Bill ID number - “RB - dd/mm/yyyy-yy/running_sequence_number”.

    Input Metric
    Description
    Comments

    To find details on Demand Generation Logic refer to the Demand/Bill Generation for metered connection.

    1. All 5 digits in the meter reading must be entered. Show error message “ Old Meter Reading entered is Invalid” or “ New Meter Reading entered is invalid” respectively.

    2. The New Meter reading should be greater than the Old Meter Reading.

    3. The meter reading date is by default set to <today's date> but the user has the option to change it.

    User Manual

    A step-by-step guide to using the NalJalSeva App

    Introduction NalJalSeva

    NalJalSeva is a standalone app-based module that enables the GPWSC committee to create new consumers, generate demand, collect revenue, record expenditure transactions etc.

    NalJalSeva enables GPWSCs to maintain financial records of GPWSCs following established procedures and practices.

    Follow the step-by-step (links below) guide to use the app:

    Search Employee

    Overview

    Employee can be searched by name, employee ID and Number.

    Design & Workflows

    State User search Employee Search by name, employee ID and Number.

    Block-based search is available for state users.

    Search based on employee status

    Block User Search Employee

    Search Employee By name, employee ID and Number.

    The search screen will show the below details

    1. Employee Id

    2. Employee Name

    3. Mobile Number

    4. Type of user

    Role-based search is also available for block users -

    We have search option for inactive/ active users -

    Punjab

    The journey of PFM Mission in Punjab began in January 2021 with signing of a tri party MoU among The Department of Governance Reforms and Public Grievances (DGR & PG), the Department of Finance (FD), Punjab, and eGov Foundation to provide a systemic solution to enhance public finance management in the state.

    The pilot was agreed to be carried out in the Department of Water Supply and Sanitation (DWSS).

    Multiple learning sessions with the DWSS officials were conducted to gain in-depth knowledge on current processes and systems, pressing challenges, and how the Mission can design potential solution(s) to the identified problem/s. After these discussions, the following problem statement was identified:

    Visibility into financial sustainability of GPWSC run schemes:

    • The water charges (funds) collected by the GPWSC for their schemes and expenditures made thereof are not visible to the DWSS or the Department of Finance (FD)

    • Such transparency is necessary since DWSS funds the asset creation and provides for O&M and electricity charges shortfall of GPWSC, if any

    To solve the above problem statement, eGov Foundation in consultation with the DWSS, Government of Punjab, identified Anandpur Sahib (APS) as the pilot division to implement mGramSeva. mGramSeva, a mobile application, envisions to capture all the Revenue and Expenditure details in digitized format which will bring in accountability and transparency of GPWSC funds, as well as enable and empower frontline leaders of the Panchayats.

    The mGramSeva solution adoption highlights are given below:

    1. In APS division there are more than 76 schemes and 100 villages which are GPWSC run schemes, for which the water bills are generated manually

    2. No automated or digital system currently in place to notify the household through SMS for bills generated

    3. Manual recording all the receipts and expenses in cash book

    4. Sarpanch does not have access to real time information on collection and expenditure

    View & Edit Consumer

    View Consumer

    Users are redirected to the View Consumer screen from the home screen via

    • Collect payments → Search Screen → Consumer Details Screen

    • Download bills & receipts → Search screen → Consumer Details Screen

    • Dashboard → Collections → Click on Consumer ID

    • Household Register → Click on Consumer ID

    Enter the search parameters - Consumer Mobile Number, Name of the Consumer or New Connection ID to filter your results.

    Click on the Search button to view the consumer list.

    Click on View Consumer Details.

    Edit Consumer

    Users can edit the consumer details if any changes need to be made in the consumer record.

    Click on the Update Consumer Details card on the home page. Search and find the applicable consumer using the given search filters.

    Click the Edit Consumer Details button on the applicable consumer search record to make the necessary changes.

    Edit the required details on the screen.

    Check the option Mark this connection as Inactive to indicate that the given consumer connection is inactive.

    Click on the Submit button to save these changes.

    Install AWS

    1

    Setup AWS account

    2

    3

    4

    5

    Add Expense

    Overview

    The Add Expense feature enables users to add expense details.

    Design & Workflows

    The expense entry for the O&M is captured on this screen.

    Workflows

    Click on the links below to explore the NalJalSeva workflows:

    Update Employee

    Overview

    Employee details can be updated using the Edit employee details option.

    Design & Workflows

    State users - can edit block user details

    View Household Register

    Overview

    The View Household Register enables users to view household details.

    Design & Workflow

    Users can click on the Household Register on the home screen and navigate to this screen. This provides a single-view snapshot of all pending collections by consumers to date.

    Setup Git Repository

    Overview

    This page provides step-by-step details on setting up a git repo for code, configs, V1 MDMS, and Infra As Code.

    Steps

    Fork the following repos that contain the master data and default configurations. Customize the data (master data, ULB, Tenant details, Users, etc) as per specific implementation requirements in the respective GitHub organization accounts.

    Generate Bills

    The Administrative user for a GPWSC/Village, i.e., a Sarpanch or anyone with admin access, needs to generate a bill (i.e., generation of monthly bills) for all the consumers. This activity is to be done at the beginning of the month and must be done only once per month. Sarpanch or anyone with admin access has the option to generate the bill for all consumers at once.

    Steps

    1. Click on the Generate Bill card on the homepage to raise bills for all or selected consumer connections.

    Login & Forgot Password

    Overview

    The users receive a link via SMS. Clicking on this link redirects the users to the login page of the NalJalSeva app. The users can log in from this screen or even reset their password in case they are logging in for the first time.

    Design & Workflow

    Create User API

    This page provides a comprehensive guide on using the CreateNovaildate API to create users with specific roles based on their responsibilities within the system. Adjust the parameters and roles as needed for your specific requirements.

    Steps

    The API allows users to create a new user with specified details that include username, name, gender, mobile number, activation status, user type, tenant ID, and password. Refer to the details available below.

    Additionally, users can be assigned specific roles based on their responsibilities.

    User OTP

    User OTP service is used to generate OTP for user login, user registration and user password change.

    Pre-requisites

    • Prior Knowledge of Java/J2EE.

    Create New Tenant

    This documentation outlines the process of setting up a new tenant in MDMS (Master Data Management System). To achieve this, it involves cloning the MDMS repository locally and utilizing a Python script that interacts with an Excel file containing essential information for the new tenant setup.

    Pre-requisites

    1. Clone the repository to your local machine.

    Edit Profile & Change Password

    Users can -

    Household information records are maintained manually

    Prior Knowledge of Spring Boot.
  • Prior Knowledge of KAFKA

  • Prior Knowledge of REST APIs and related concepts like path parameters, headers, JSON, etc.

  • The following services should be up and running:

    • user

    • MDMS

    • Id-Gen

    • URL-Shortening

    • notification-sms

  • Key Functionalities

    • The user-otp service validates the user details and request type and sends OTP for a particular action.

    Deployment Details

    • Deploy the latest image of the user-otp service available.

    Configuration Details

    Property
    Value
    Description

    expiry.time.for.otp

    3000

    Expiry time of the otp

    Integration Details

    Integration Scope

    User OTP service can be integrated with any organization or system that wants OTP-based validation for user login and registration.

    Integration Benefits

    • Easy to create and simple process of generating bills from demands.

    • Easy to generate OTPs to validate mobile numbers for registration, login and password reset with simple API calls

    Integration Steps

    OTP can be generated by calling /user-otp/v1/_send

    Consumers

    Assurance of access to clean and regular water supply:

    1. Ease of payment

    2. Transparency

    3. Digital invoice

    4. Accountability

    VWSCs

    Ease of managing operations and maintenance of water supply -

    1. Updated and verified data registry

    2. Role base login

    3. Village level dashboard and reports

    4. Ease of collection

    Government

    Efficient monitoring and policy reforms -

    1. State level dashboards and reports

    2. Data verification

    3. Billing to VWSCs

    4. Ease of policy implementation

    Common Functions Guide

    1. Login to the App

    2. Edit profile & change password

    Division User

    1. Create & edit consumer

    2. Adding and updating rate master

    Village water & sanitation committee (VWSC) user

    1. Generate Bill

    2. Search consumers & generate payment

    3. Record & modify expense bill

    4. View dashboards

    State User

    Purchase Certificate
    Setup git repo for code, configs, V1 MDMS, and Infra as code
    Configure domain or subdomain registry and mapping cname
    Create a git account in the client name
    Request Parameters
    1. username (string): User's unique username.

    2. name (string): Full name of the user.

    3. gender (string): Gender of the user.

    4. mobileno (string): User's mobile number.

    5. active (boolean): User's account status (true for active, false for inactive).

    6. type (string): It will be EMPLOYEE only.

    7. tenantid (string): User's tenant ID.

    8. password (string): User's password.

    9. Roles: Roles determine the permissions and responsibilities assigned to a user.

    The available roles are as follows:

    Roles for Sarpanch

    • COLLECTION_OPERATOR

    • EXPENSE_PROCESSING

    • BULK_DEMAND_PROCESSING

    • DASHBOARD_VIEWER

    • GP_ADMIN

    Roles for Secretary

    • EXPENSE_PROCESSING

    • BULK_DEMAND_PROCESSING

    • DASHBOARD_VIEWER

    • GP_ADMIN

    • COLLECTION_OPERATOR

    Roles for Revenue Collector

    • COLLECTION_OPERATOR

    • DASHBOARD_VIEWER

    Roles for Division User

    • HRMS_ADMIN

    • DIVISION_ADMIN

    Roles for State User

    • HRMS_ADMIN

    • STATE_ADMIN

    To assign roles to a user, include the desired roles in the roles section of the request. PROFILE_UPDATE role is available for every user to update existing roles.

    CreateNovaildate
    Request Parameters

    Division User

    Have the Excel file ready for reference. The structure of the Excel file is critical, and any changes must align with the specified columns. The reference to the Excel file is given below.

    Steps

    Python Script Configuration

    1. Locate the Python script for adding a new tenant. The script can either be placed in the "tenants" folder locally or specify the full path where your "tenants.json" folder is present within the script.

    2. Open the script and edit the following lines to match your requirements:

      Replace "Book2.xlsx" with the name of your Excel file containing tenant information.

    3. Specify the sheet name in your Excel file where the required data is stored.

    Excel File Preparation

    1. Ensure your Excel file adheres to the specified format. The columns must match the template provided, and any deviation may result in script failure.

    2. Do not modify the column structure in the Excel sheet, as the script relies on a consistent format.

    Running the Script

    Execute the Python script after configuring it according to your needs. The script will process the Excel file, and upon completion, a new file named "tenants_new.json" will be generated.

    Deploying to MDMS

    • Copy the generated tenants_new.json file to the MDMS repository or select and apply the updated data within MDMS as needed.

    5KBBook2.xlsx

    3KBcreate_tenants_json_Book2.py

    After creating a tenant in the tenants.json file we need to make a separate folder in MDMS for each tenant.

    MDMS
    dataframe = openpyxl.load_workbook("Book2.xlsx")
    dataframe1 = dataframe["Sheet1"]

    There are 3 user actions on the success screen

    • Download bill - Download bill as PDF (name of PDF is always the Bill ID by default)

    • Share bill on WhatsApp - Share bill as PDF on WhatsApp

    • Collect Payment - navigates the revenue collector to the payment collection screen

  • Share on WhatsApp opens the WhatsApp share popup with the option to choose contacts/groups. The bill is shared with the below text and attached PDF details -

    Text “ Dear, water bill for 1 - 30 has been generated for consumer ID for Rs. 250. Click attached as PDF”

  • Previous Meter reading

    Only for first-time bill generation

    New meter reading

    For the first time and all consecutive bill generations

    Previous meter reading units and previous meter reading dates will be taken from the last bill for new bill generation

    Meter reading date

    The default is the current date. Revenue collectors can change it to a previous date if required.

    Designation
  • Status

  • Expense Types

    On selecting the option “Add Expense Record” from the list of tiles/cards on the home page, the user is navigated to the expense entry screen. The screen displays the following fields.

    Field Name
    Type
    Mandatory Y/N
    Description

    Vendor Name

    Text (With Suggestions dropdown)

    Y

    Name of the Vendor. The suggestion list is shown as the user entry is done for every character. The new Name will also create a Vendor Register.

    Type of Expense

    Drop Down

    Y

    Type of expense list From Master

    Amount

    Numeric

    Y

    On Submitting, the Expense entry gets created with a Bill number assigned. The Bill number generated would be based on logic defined as - “EB-<FY>-<4 digits running seq No>”

    On Successful creation of expense entry, an acknowledgement screen is shown “Expense Entry successful” along with the Bill Number.

    Block users - can edit field user details

    Search user by name (Fuzzy search) , Mobile number or Employee ID

    Block user can also search user by roles.

    Click on the user you want to edit.

    Click on take action Button to edit the user.

    The options on the action button can be used to Deactivate / Edit the employee.

    Deactivate Employee

    Fill in the required details and deactivate the user.

    Activate User

    Activate an deactivated employee.

    Edit Active User

    Note: Other than

    1. Mobile Number and

    2. Primary Scheme - the Primary tenant cannot be removed.

    Other details can be modified.

    Data Points

    Title
    Description

    Heading

    HouseHold Register

    As of Date

    As of <Todays Date>

    Search

    • Search by consumer name or connection id

    • Partial match should be allowed.

    Filters

    Default is “All” selected

    User can switch to “Pending” or “Paid” view. Based on selection, results are displayed in the table

    Download PDF

    Download PDF should download PDF format of Household Register with name of document as HH_Register_<Date>

    WhatsApp Share

    Should trigger same PDF as Whatsapp share

    View Consumer Ledger Report

    Once you click on the ledger report of the consumer it opens the below screen -

    Select the financial year and click on View to view a report of that financial year or Download to download the report of the selected year.

    Clicking on the Back button takes the user back to the home screen.

    Follow the steps given below to set the git repository,

    • ​Fork both the MDMS, and config repos into your GitHub organization account.

    • Create a GitHub user account, and generate an SSH authentication key (generate a new SSH key and add it to the above user account.

    • Enable new GitHub users to access the forked repos.

    • Add the ssh private key generated in the previous step to the egov-demo-secrets.yaml within the git-sync section.

    • Update the services in the git-sync repository by specifying the forked repository and branch in the file.

    • Update the deployment configuration details for the below as per your specifications:

      1. Number of replicas/scale of each service (depending on whether dev or prod load)

      2. You must update the SMS gateway, email gateway, and payment gateway details for the notification and payment gateway services, etc.

      3. Update the config and MDMS GitHub repos wherever marked.

      4. Update GMap key (In case you are using Google Map services in your PGR, PT, TL, etc)

      5. Create one private S3 bucket for Filestore and one public bucket for logos. Add the bucket details respectively and create an IAM user with the s3 bucket access. Add IAM user details to .

      6. URL/DNS on which DIGIT will be exposed.

      7. SSL certificate for the above URL.

      8. Any specific endpoint configurations (Internal/external).

  • Users can select the billing year and billing cycle (month) and click on the Generate Bill button.

    • Once the bill is generated, revenue can be collected from the users for the generated bill amount.

    Collect Payments

    Payments can be collected for consumers with outstanding bills. The collection module can be enabled for revenue collectors, treasurer and chairman, as per the state's requirement.

    Steps

    1. Click on the Collect Payment icon on the home page to search for a consumer record by Consumer’s Phone Number or Name of the Consumer or Old Connection ID or New Connection ID.

    2. Click on the Search button to select a particular consumer for payment collection.

    3. Click on the View Consumer Details button to perform the necessary action.

    1. If the consumer wishes to receive a soft copy of his/her bill, click on the Share Bill button to send the bill to the consumer on the registered mobile number via WhatsApp message.

    2. Click on the Collect Payment button to collect the payment via cash.

    3. Full Payment or Partial Payment to indicate whether the consumer is paying the bill amount in full or making a partial payment. Enter the Amount that is being paid by the consumer in case it is a Partial Payment.

    4. Click on the Download Receipt button to download the payment receipt. Click on the Share icon to send the receipt to the consumer via WhatsApp message.

    5. Click on the Consumer Receipt Print button to print the receipt for the consumer through a thermal Bluetooth printer

    6. Once the payment is completed an SMS is sent to the consumer to confirm the payment with a copy of the payment receipt.

    The section provides specific screen design and configuration details below.

    Language Selection

    The link in the SMS redirects users to this screen which is the first screen which is the language selection screen. The user selects the preferred language and clicks on Continue. English and Assamese are the supported languages with English as the default language. Localization in the screens is displayed based on the language selected.

    User ID and Password Entry

    On the login screen -

    1. Enter the user ID, which is the registered mobile number of the user

    2. Enter the system-generated password. Click on the Continue button to log in.

    Forgot Password

    Click on the Forgot Password link on the login screen. This navigates the user to the password reset screen.

    Enter the registered Mobile Number and the OTP received on the mobile number.

    First Time Login

    The user is redirected to the password reset screen where they enter the OTP received on the registered mobile number. The next screen prompts the user to enter a new password and then confirm the same. This is similar to the first-time login screen. Clicking on Submit displays the acknowledgement screen. Clicking on the Continue to Login button on the acknowledgement screen takes the user to the login page.

    Subsequent Login

    The user is redirected to the home page of the application which displays the menu options based on the mapped user role.

    Logout

    Change Language

    Click on the user icon on the top section of the screen. Click on the applicable Language option to localise the application. The supported languages are Assamese and English, where English is the default language.

    Edit Profile

    Click on the user icon on the top section of the screen. Click on Edit Profile to make profile changes.

    Update Name, Gender, or Email ID as required. Make note that the registered Mobile Number cannot be changed.

    Click on the Save button to save the changes.

    Change Password

    Click on the Change Password button to change the password.

    Enter the Current Password. Set a new password and confirm the new password. Follow the password hints given on the screen to set the password.

    Click on Change Password to save the new password.

    Logout

    Click on the Logout button to logout from the application.

    Change language
    Edit profile
    Change password

    Login and Forgot Password

    Role: GP Admin

    Actions:

    Role: Collection Operator

    Actions:

    Role: Revenue Bulk Demand Processing

    Actions:

    Role: Expense Processing

    Actions:

    Role: Dashboard Viewer

    Actions:

    View Consumer

    Overview

    The View Consumer screen allows users to view the consumer details and linked information.

    Design & Workflow

    Users are redirected to the View Consumer screen from the home screen via

    • Collect payments → Search Screen → Consumer Details Screen

    • Download bills & receipts → Search screen → Consumer Details Screen

    • Dashboard → Collections → Click on Consumer ID

    • Household Register → Click on Consumer ID

    The View Consumer screen contains all information related to household

    The static household card displays the following details:

    1. New Connection ID (also displayed as a heading)

    2. Consumer name

    3. Father's name

    4. Phone number

    Workflow

    1. If the bill is not generated (Post rollout until the first month), only the data card is shown, and no action is required.

    1. Once the first demand is generated, a new consumer bill/card will be generated, and the following data points and actions will be displayed.

    • Billing cycle – the latest billing cycle

      • Amount -

        • Current Amount - fixed charges applicable to the billing cycle

        • Arrears - Arrears from the first month (From next month onwards this field displays any unpaid dues)

    1. After the first payment collection is done -

    • A receipt history block is visible only after the first payment transaction is completed through mGramSeva

      • A list of all the receipts is shown under this section as cards, with different data points as actions. Order of receipts is newest → oldest from top to bottom

      • Each receipt card contains

    Collect Revenue Offline

    Overview

    Once the demand is generated for metered and non-metered connections, revenue collectors come to this screen to collect payments.

    Desgin & Workflow

    Users can see the consumer billing information on the screen.

    1. Clicking on View Details expands the card and shows more details. Clicking on the Hide Details collapses the card to show only the Connection ID, Consumer Name & Total Due Amount.

    1. Payment amount - can either pay

    • The full amount, or

    • Custom amount - Users can enter the custom amount in the input field - this cannot be zero or greater than the total due amount.

    1. Payment methods

    • Cash - select cash and proceed to payment takes the user to the successful collection screen

    • Online - The online payment option displays a Q/R code on the user screen that can be scanned by another phone to pay the due.

    • Post payment via any mode - payment success screen is shown

    • Receipt ID format - RB-dd/mm/yyyy-yy/running_sequence_number

    1. User Actions

    • Download receipt - download the PDF version of the receipt with the receipt ID as the name of the PDF while downloading.

    • Share receipt via WhatsApp - opens the Phone OS sharing options.

    • back to home - takes the user back to the home screen.

    1. SMS to Household

    • As soon as the amount is paid and the Revenue collector reaches the Payment success screen SMS is sent to Household.

      • SMS 1 - Dear ‘Username’, Paid Rs. X for water charges for bill period <Cycle>. Download receipt <link>

      • SMS 2 - Dear ‘Username’, Please leave a review on water supply at <GP> at <Link>

      • HH can leave a review for water charges. Refer

    Details on the card

    Detail
    Comments
    • When an online payment method is selected, the “Collect Payment” option is disabled. Since the household scans the QR, the Revenue collector does not have control over the online process.

    • The partial amount cannot be greater than the full amount.

    Advance Changes

    Water Connection advance changes are added to allow the customer to pay the advance amount. This amount is adjusted when a new demand is generated. We can enable or disable advance based on the configuration.

    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 the water service persister configs path added to it

    • PSQL server is running and a database is created to store water connection/application data

    • The following services should be up and running:

      • egov-persister

      • egov-mdms

      • ws-services

    Key Functionalities

    • Accepts advance amount during water connection creation and while collecting payment

    • Creates demand for consumer-type water connection-advance

    • Adjusts the new demand with existing advance with apportion service

    Deployment Details

    Deploy the latest version of ws-service, ws-calculator, billing-service, egov-apportion-service

    MDMS Configuration

    Billing service tax head configuration

    Tax-head master service configuration

    Existing Service Code Changes

    Billing Service Changes

    • Creating a new bill for the advance amount in BillServiceV2. Removing the following line while adding the bill objects to the list if (billAmount.compareTo(BigDecimal.ZERO) >= 0)

    • Passing Active status filter for demand search during apportioning in DemandService. DemandCriteria searchCriteria = DemandCriteria.builder().tenantId(tenantId) .status(Demand.StatusEnum.ACTIVE.toString()).consumerCode(Collections.singleton(consumerCode)). businessService(businessService).build();

    • New Demand audit history API in Demandcontroller. An API that returns the audit history of demandDetails. demand/_history

    Water Service Changes

    • Create water connection API: Adding a check for payment type advance. If advance, passing a boolean isAdvanceCollection to calculationRequest to water calculator service.

    • Update water connection API: Adding a check for payment type advance. If advance, passing a boolean isAdvanceCollection to calculationRequest to water calculator service. Adding a check for advance in validateUpdate method to set the current demand to CANCELLED.

    Water Calculator Service Changes

    • Calling estimation service getEstimationMap based on isAdvanceCalculation boolean. If true, reading taxAmount from criteria.getWaterConnection().getAdvance();

    • Changes in getEstimatesForTax for a new taxHeadCode ADVANCE_COLLECTION with value WS_ADVANCE_CARRYFORWARD

    • Getting the advance amount in getCalculation with taxHeadCode ADVANCE_COLLECTION

    • Calling generateDemand method based on isAdvanceCalculation. If true, create a demand object with consumerType “waterConnection-advance“.

    Setup NalJalSeva

    Follow the below steps to setup NalJalSeva.

    1

    Install AWS and Enable Permissions

    Install the AWS and enable permissions for the application.

    2

    Deploy the core, municipal and business services

    3

    Create and add users on the NalJalSeva platform post-installation

    4

    Automate user creation in NalJalSeva - manage user roles and permissions

    5

    Load consumer data into the system

    6

    Localise the Nal Jal application to local languages

    7

    Change the master rates in Nal Jal

    8

    APIs to create property and consumers

    9

    API to create users with specific roles

    10

    Register SMS templates with the template ID

    11

    Configure the master data details

    12

    Add new tenants to the system

    13

    Add workflows to the system

    UI Design

    NalJalSeva is a Hybrid Application(web + App(Android + IOS)) built utilising Open Source Framework Flutter.

    Frontend Design
    • CrossPlatform Application

    • Faster

    • Single Codebase - Easy To Maintain

    • Large Community Support

    • Open Source

    Link to Learn Flutter -​

    Flutter Version Utilised for Development

    Flutter 2.2.3

    Languages - > Dart 2.13.4

    Enable Application Permissions

    Make sure the below-mentioned permissions are allowed or accepted:

    1. Internet access

    2. FileStore read and write

    3. Bluetooth connection

    Send SMS Notifications

    Overview

    The SMS notification feature triggers messages to users for specific events and updates.

    Design & Workflow

    Various SMS notifications are sent to different users on different actions. Below is a consolidated list of all SMS notifications required.

    Load Employees For NalJalSeva

    Overview

    This page provides a clear and concise guide for automating user creation in NalJalSeva. It allows you to efficiently create users and manage their roles in the system.

    Follow the steps provided on this page to create users for NalJalSeva using a Python script. The process involves preparing an Excel sheet with user information, configuring the Python script, and executing it.

    View & Download Reports

    Overview

    The view and download reports feature enables users to generate and download different types of reports linked to consumers, vendors, expenses, collections and ledgers at various levels.

    Design & Workflows

    Apportion

    Apportion service is used to apportion the amount paid against a bill among the different tax heads based on the implemented algorithm. The default algorithm uses the order of the tax head to apportion, the tax head with the lowest order is apportioned off first while the highest-order tax head is apportioned last.

    Pre-requisites

    Before you proceed with the documentation, make sure the following pre-requisites are met -

    • Java 8

    Push Events To iFIX Adapter

    Events push is used to manually push data from the NalJalSeva Adapter to the iFIX Adapter. Make sure the existing events are cleared or deleted to ensure reliable data transfer. Refer to the documentation here to find details on how to clean up the event data - . Post events clean up the system loads the project code for all the tenants. Then it pushes the data to the iFIX adapter.

    Pre-requisites

    • Access to Kubectl of the environment targetted

    Generate Bulk Demand & Raise Bills

    Overview

    All Gram Panchayats have a monthly billing cycle for water charges. The generate bulk demand feature schedules the system to generate demand and raise bills for non-metered connections.

    Design & Workflow

    /DIGIT-DevOps/config-as-code/environments/egov-demo-secrets.yaml
    /DIGIT-DevOps/config-as-code/environments/egov-demo.yaml
    egov-demo.yaml
    <env-secrets.yaml>
    Setup core services
    Create users
    Load employees
    Load consumers
    Configure localisation
    Update master rate
    Create consumer API
    Create user API
    Configure SMS template
    Configure master data management system
    Create new tenant
    Create workflow

    Download bills & receipts

    Create Consumer
    Edit Consumer
    View Household Detail/Register
    Search consumer
    View household details/Register
    Raise bill
    Collect payment
    Generate demand
    Register/View household details
    Raise bills
    Download bills & receipts
    Enter expense details
    Update expense details
    Revenue dashboard
    Expenditure dashboard

    State User

    Flutter - Beautiful native apps in record time
    billing-service
  • ws-calculator

  • egov-apportion-service

  • Postman scripts

    The Postman script fetches the data from the existing NalJalSeva database and passes it to the NalJalSeva adapter, from where it is pushed to the iFIX adapter.

    Payments Curl

    Pass the offset and limits based on the total transactions present in the database.

    Here, TenantId is mandatory. Limit and offset can vary based on the requirement. Business service is not required.

    This fetches all payment records irrespective of tenant based on the limit and offset. The data is passed to the IFIX adapter one after the other.

    Demand / Bill Curl

    The above curl fetches the demands based on the tenant ID and business service passed. Business service can be ‘WS' or ‘EXPENSE.SALARY’ or 'EXPENSE.MISC’ or 'EXPENSE.OM’ etc. For WS it is saved as demand and for EXPENSE it is saved as bill.

    IFIX-Core Data Clean-Up v2.0
    {
          "businessService": "ws-services-calculation",
          "code": "WS",
          "collectionModesNotAllowed": [
            "DD",
            "CHEQUE",
            "CARD",
            "OFFLINE_NEFT",
            "OFFLINE_RTGS",
            "POSTAL_ORDER",
            "ONLINE"
          ],
          "partPaymentAllowed": true,
          "isAdvanceAllowed": true,
          "demandUpdateTime": 86400000,
          "isVoucherCreationEnabled": false,
          "billGineiURL" : "egov-searcher/bill-genie/waterbills/_get",
          "isBillAmendmentEnabled":true
        }
    {
          "category": "ADVANCE_COLLECTION",
          "service": "WS",
          "name": "Ws advance carry forward",
          "code": "WS_ADVANCE_CARRYFORWARD",
          "isDebit": true,
          "isActualDemand": false,
          "order": "0",
          "isRequired": true,
          "IsBillamend": false
        },
    curl --location --request POST 'http://localhost:8084/mgramseva-ifix-adapter/mGramsevaAdopter/v1/_paymentdatatransfer?tenantId=pb.massewal&businessService=WS&limit=1000&offset=0' 
    --header 'Content-Type: application/json' 
    --data-raw '{
    "RequestInfo": {
    "apiId": "Rainmaker",
    "ver": ".01",
    "ts": null,
    "action": "",
    "did": "1",
    "key": "",
    "msgId": "20170310130900|en_IN",
    "authToken": null,
    "correlationId": null,
    "userInfo": {
    "id": 1238,
    "userName": "230566|6nazOXejetsSwLcRS5aclEJD/4e7SzmimN4=",
    "name": "230566|kBzPQAXbCiQzR3NUY/cLPTzdnmw63ho=",
    "type": "SYSTEM",
    "mobileNumber": "230566|6nazOXejetsSwLcRS5aclEJD/4e7SzmimN4=",
    "emailId": null,
    "roles": [
    {
    "id": null,
    "name": "Employee",
    "code": "EMPLOYEE",
    "tenantId": "pb"
    },
    {
    "id": null,
    "name": "System user",
    "code": "SYSTEM",
    "tenantId": "pb"
    }
    ],
    "tenantId": "pb.lodhipur",
    "uuid": "47ff55dc-c9d0-4f86-8f82-b4d7a24ba59e"
    }
    }
    }'
    curl --location --request POST 'http://localhost:8084/mgramseva-ifix-adapter/mGramsevaAdopter/v1/_legacydatatransfer?businessService=WS' \
    --header 'Content-Type: application/json' \
    --data-raw '{
    "RequestInfo": {
    "apiId": "Rainmaker",
    "ver": ".01",
    "ts": null,
    "action": "",
    "did": "1",
    "key": "",
    "msgId": "20170310130900|en_IN",
    "authToken": null,
    "correlationId": null,
    "userInfo": {
    "id": 1238,
    "userName": "230566|6nazOXejetsSwLcRS5aclEJD/4e7SzmimN4=",
    "name": "230566|kBzPQAXbCiQzR3NUY/cLPTzdnmw63ho=",
    "type": "SYSTEM",
    "mobileNumber": "230566|6nazOXejetsSwLcRS5aclEJD/4e7SzmimN4=",
    "emailId": null,
    "roles": [
    {
    "id": null,
    "name": "Employee",
    "code": "EMPLOYEE",
    "tenantId": "pb"
    },
    {
    "id": null,
    "name": "System user",
    "code": "SYSTEM",
    "tenantId": "pb"
    }
    ],
    "uuid": "47ff55dc-c9d0-4f86-8f82-b4d7a24ba59e"
    }
    },
    "tenantIds": ["pb.lodhipur","pb.baruwal"]
    }'
    Old connection ID
  • Address - Door Number, Street number, Ward (attached)

  • Property type

  • Service type

    • for metered connections - the meter number is displayed

  • Total Amount - Sum of current amount and arrears

  • Action Items

    • Download or Share Bill -

      • Clicking on download bill prompts users to download the bill (Bill details are given in a separate user story)

      • Share bill (WhatsApp icon) opens sharing options to the phone OS and the user can share bills via WhatsApp.

      • Message to go in WhatsApp “Please find Bill for water charges with Connection ID WS-83121-8312 generated on dd/mm/yyyy” along with bill PDF.

      • Name of the PDF - “Bill ID”.

    • Collect Payment - The Collect Payment button takes the revenue collector to the payment collection screen.

  • Receipt ID
  • Amount Paid

  • Paid Date

  • Actions

    • Download Receipt - Download the receipt in the Revenue Collector's phone as a PDF

      • Name of PDF - “Receipt ID”

    • Share (WhatsApp)

      • Message to go in WhatsApp “Please find the receipt for water charges with Connection ID WS-83121-8312 paid on dd/mm/yyyy” along with the receipt PDF

  • Water charges

    Amount for the latest billing cycle

    For metered, calculate charges as per rate master between the latest 2 billing dates

    Arrears

    All old arrears accumulated for HH

    Expansion should breakup of arrears by individual billing cycles/bill generation dates

    Total Due amount

    Net amount consumer has to pay

    Connection ID

    New Connection ID will be displayed here

    Consumer Name

    Consumer Name (Should take updated consumer name)

    Bill ID number

    ID of the Bill

    Bill period

    For non-metered connections

    1. This is the latest billing cycle for which demand is generated

    For metered connections

    1. This is the new bill generated from the meter reading between the 2 most recent billing dates

    Format

    1. Month <space> Financial Year

    2. Previous meter reading date - New meter reading date

    Feedback - Post Payments
    Request packages
  • Query all packages

  • Code Snippet

    punjab-mgramseva/pubspec.yaml at develop · egovernments/punjab-mgramseva

    Steps To Setup The Project

    Download the Flutter sdk 2.8.1 from Flutter SDK releases

    Install Android Studio for setting the IDE.

    Open Android Studio. Open plugin preferences (File > Settings > Plugins) and select Marketplace. Select the Flutter plugin and click Install as shown in the image below. Click Yes when prompted to install the Dart plugin.

    Set the Flutter SDK path in Android Studio by navigating to (File > Settings > Plugins > Language & Frameworks >> Flutter) flutter as shown in the image below.

    Add the flutter path to the system path variable for running the flutter commands as shown in the image below.

    Open a new terminal and run the flutter doctor command. This downloads the respective Dart SDK version and runs flutter doctor--android-licenses to accept the Android licenses.

    The steps below guide us to run the project on both Web and Mobile

    1. Clone the project from the Git repo.

    2. Open the project in Android Studio by selecting (File > open), and select the flutter project (punjab-mgramseva/frontend/mgramseva) from the cloned path as shown in the image below.

    Running On an Android Emulator

    Select the AVD manager from the right-side top corner as shown in the image. Now, select any device by tapping on the play button. The Android Studio launches the emulator and the device is auto-selected. There are two modes for running the application - play and debug. Tap on any one of the modes to launch the mGramSeva application in the emulator as shown in the image.

    Running On Web

    Select the Chrome option from the device selection and tap on the play button. This launches the application on a Chrome window.

    Note: To resolve the cors error follow the steps provided in this link.

    Build Prod App Bundle - Steps

    1. key storeGoogleClone the Repo → git clone GitHub - misdwss/punjab-mgramseva

    2. Navigate to mgramseva folder → cd punjab-mgramseva/frontend/mgramseva

    3. Upgrade the version in the pubspec.yml (version: 1.0.2+3) 1.0.2 => version name (which is displayed in the playstore)

      +3 => version code (increment by +1 every time)

    4. Replace the base Url with Prod Url File → _baseUrl: window.location.origin + "/", => _baseUrl: " "

    5. Comment the below line File → export 'dart:js' show allowInterop, allowInteropCaptureThis;

    6. Execute the flutter clean command → flutter clean

    7. Execute the flutter pub get command → flutter pub get

    8. Download the key store from the below link Add this properties file to the android app folder as shown in the image below - android → key.properties

    1. Download the Google service JSON from the link below google-services.json Add this JSON file to the Android app folder as shown in the image below android → app → google-services.json

    1. Build the prod app bundle → flutter build appbundle Check the attached drive link below which includes the key-store, and version tracker. Update the version and release date in the sheet. Path → D:\mgramseva_prod\punjab-mgramseva\frontend\mgramseva\build\app\outputs\bundle\release\app-release.aab

    2. https://docs.google.com/spreadsheets/d/1aH596FxtPISIlQzxw9jO_Ex1dttpJJvweib2F9nJj9o/edit#gid=0 - Restricted link, try another account

    Steps To Run The Integration Test On Android Device

    1. Enable the USB debugging option on your Mobile Phone. (Reference Link )

    2. Connect your Phone to the system and enable File transfer.

    3. Select the AVD manager(your Phone) from the right side top corner in Android Studio

    4. Go to the frontend/mgramseva/utils/execute_integration.sh file and run it.

    5. The integration test will start on your device.

    Event Type
    Target User Type
    Message
    Comments

    On boarding - Creation login details

    EMP/GP Users

    Dear <user>, You've been invited to mGramSeva Application of Punjab. Please login using <Link>. Username: <Phone Number> Password: <Password>

    On boarding - First time login OTP

    EMP/GP Users

    OTP for resetting password on mGramSeva is <OTP>

    Forgot Password OTP

    EMP/GP Users

    OTP for resetting password on mGramSeva is <OTP>

    Pre-requisites
    1. Python script for creating users for NalJalSeva.The sample format of the Python script is attached below.

    2. Excel sheet containing user data. The sample format of the Excel sheet is attached below. Make sure to populate the data in the same format.

      • Columns: tenant name, mobile no, father name, gender, date of birth (dd/mm/yyyy), type, and ward (fixed to "ward 1").

      • Types: Sarpanch, Secretory, Revenue Collector, Division User or State User

      • Roles for Sarpanch: COLLECTION_OPERATOR, EXPENSE_PROCESSING, BULK_DEMAND_PROCESSING, DASHBOARD_VIEWER, GP_ADMIN.

      • Roles for Secretory: EXPENSE_PROCESSING, BULK_DEMAND_PROCESSING, DASHBOARD_VIEWER, GP_ADMIN, COLLECTION_OPERATOR.

      • Roles for Revenue Collector: COLLECTION_OPERATOR, DASHBOARD_VIEWER.

      • Roles for Division User: HRMS_ADMIN, DIVISION_ADMIN

      • Roles for State User: HRMS_ADMIN, STATE_ADMIN

    Steps

    1. Prepare the Excel Sheet:

      Create an Excel sheet with the following columns and data in the given format:

      • Tenant Name (in lowercase)

      For State User tenant name will be pb

      • Mobile Number

      • Father's Name (Mandatory, use "NA" if not available)

      • Gender (M/F - this data is mandatory)

      • Date of Birth (in the format dd/mm/yyyy)

      • Type (Sarpanch, Secretory, Revenue Collector, Division User or State User)

      • Roles - Based on the User Type, set corresponding roles:

        • Sarpanch: COLLECTION_OPERATOR, EXPENSE_PROCESSING, BULK_DEMAND_PROCESSING, DASHBOARD_VIEWER, GP_ADMIN

        • Secretary: EXPENSE_PROCESSING, BULK_DEMAND_PROCESSING, DASHBOARD_VIEWER, GP_ADMIN, COLLECTION_OPERATOR

        • Revenue Collector: COLLECTION_OPERATOR, DASHBOARD_VIEWER

      • The 'Boundary' should be set to "Ward 1" as per mGramSeva standards.

    2. Run the Python Script:

      • Open the Python script.

      • Provide the following information within the script:

        • Host URL: Specify the target environment (prod, qa, or uat).

    3. Post-Execution:

      • Do not open the Excel file until the script has completed its task.

      • After the script finishes, open the Excel file to review the results.

      • The Excel file will contain two columns:

    6KBupdated-user.xlsx

    10KBonBoarding.py

    Report Dashboard

    Select the Financial year for which you want to see the report.

    Billing Cycle - Select the billing cycle month for the applicable financial year.

    Select the applicable report option to view or download specific reports.

    Bill Report

    This report consolidates the details of bills consumer-wise for the selected month.

    Details

    1. Consumer Id

    2. IMIS/OLd Connection Number

    3. Name

    4. Created date 5.Penalty

    5. Advance

    6. Total Amount

    Collection Report

    Details

    1. Connection Id

    2. IMIS/OLd Connection Number

    3. Name

    4. Payment Method

    5. Amount

    Inactive Consumer Report

    Details -

    1. Connection ID

    2. Name

    3. Inactivation Date

    4. Inactivated by

    Expense Report

    Details -

    1. Connection Id

    2. Name Of payee

    3. Amount

    4. Bill Registered Date

    5. Expense From

    6. Expense To

    7. Application Status

    8. Paid Date

    9. Has Attachment

    10. Canceled time

    11. Cancelled By

    Monthly Ledger

    Details:

    1. Connection Id

    2. Sr no.

    3. Old Connection Id/IMIS no

    4. Consumer Name

    5. Consumer Entered Date

    6. Previous Outstanding last Month (If Any)

    7. Advance amount Received (if Any)

    8. Bill generated for the month

    9. Date of bill generated

    10. Total Amount

    11. Amount collected against total amount

    12. Date of Amount collected

    13. Remaining amount to be collected

    Vendor Report

    Details -

    1. Bill Id

    2. Name Of payee

    3. Mobile Number

    4. Type of Expense

    The Kafka server is up and running

  • egov-persister service is running and has an apportioned persister configuration path added to it

  • PSQL server is running and a database is created to store apportion audit data

  • Key Functionalities

    • Apportion payment in tax heads of bill

    • Apportion advance amount in tax heads of demand during demand creation

    Environment variables
    Description

    egov.apportion.default.value.order

    If set to true will apportion of negative amount first irrespective of tax head order

    Deployment Details

    1. Deploy the latest version of the egov-apportion-service service

    2. Add apportion persister yaml path in persister configuration

    Configuration Details

    There is no separate configuration required. The TaxHead master that is configured in the billing service is only used

    Integration Details

    Integration Scope

    Any payment service which wants to divide the paid amount into different tax head buckets can integrate with the apportion service.

    Integration Benefits

    • Apportions amount in tax heads

    Integration Steps

    1. To integrate, the host of egov-apportion-service should be overwritten in the helm chart

    2. /apportion-service/v2/bill/_apportion should be called to apportion the bill

    3. /apportion-service/v2/demand/_apportion should be called to apportion advance amount in demands

    Reference Docs

    Doc Links

    Title
    Link

    Collection Service

    Billing Service

    API Swagger Documentation

    API List

    Title
    Link

    /apportion-service/v2/bill/_apportion

    /apportion-service/v2/demand/_apportion

    (Note: All the APIs are in the same Postman collection therefore the same link is added in each row)

    The Scheduler automatically triggers on the “X” date of every month to generate demand and raise bills for non-metered connections.

    Metered connections do not fall under bulk demand generation -

    1. For the first month of go-live, it is only the arrears and no demand that is generated hence there is no bill to collect payments.

    2. From the second month (X date of Month 2) onwards, demand is generated.

    3. Once the demand is generated, a notification is triggered to all mGramSeva users based on the roles.

      • Details of Notification -

        • “Demand for dd/MM/YYYY - dd/MM/YYYY has been raised. X bill (s) has been raised and sent to <X/TotalConsumer>households"

      • Details of SMS Notification

        • “Dear, Demand for Billing Cycle 01/10/2024-31/10/2024 has been generated for Testing. Kindly plan for the collection of Water Charges for this period - https://naljalseva.jjm.gov.in/assam/mgramseva/home. DWSS JJM Assam

    4. Each non-metered household gets notifications -

      • SMS Notification with Bill PDF

        • 'Dear, a new water bill for Billing Cycle 1/10/2024 - 31/10/2024 has been generated for Consumer ID for Rs.30.0. Click to download the latest bill. DWSS JJM Assam.

      • SMS notification with a payment link -

    5. Revenue collectors can see a new card (Updated card from month 2 onwards) with information related to demand and payment collection on the HH Details screen.

    6. There is also a demand collection tile/card on the home screen. "Generate Bill"

      • This is used in cases when the scheduler is not run (due to technical errors) and the Gram Panchayat wants to run it manually.

    7. The system does nothing if the manual demand generation is done in the middle of the billing cycle for which demand has already been generated.

      • Manual demand generation helps only when the scheduler has not generated a demand for a billing cycle.

    To explore the Demand Generation Logic refer to Bulk Demand Generation for Non-Metered.

    In the Bulk Demand screen -

    Service Category: Defaulted to Water Charges (Module)

    Service Type: Defaulted to “Non-Metered”

    Billing Year: Dropdown with the list of the financial years from the master

    Billing Cycle: Dropdown with the list of billing cycles for the selected financial year

    Clicking on Generate Demand triggers the demand for the given billing cycle based on the logic defined above.

    Last Bill Month of demand generated - Once the demand is generated for any connection it falls under this category and it shows the number of consumers by month whose demand is generated for that month Last Bill Month of demand not generated - When we create a consumer and we have not generated even one demand that consumer will fall in this category. It will show the number of consumers month-wise for whom demand is not generated. We also provide the option to see the consumer list and edit screen from there for whom not a single demand is generated in the system.

    Successful demand generation -

    Expense amount for the Bill

    Bill Date

    Date

    Y

    Date on which the bill is to be recorded in the registers. Validation - Before Current Date and after party Bill Date.

    Party Bill Date

    Date

    N

    Date on which the Party/vendor bill was issued. Validation - Before the Bill Date.

    Bill Paid

    Radio Buttons

    N

    With option Yes/No. To update status if it is paid. If yes, “Paid Date” is captured.

    Paid Date

    Date

    N

    Date on which the bill is paid. Displayed if the Bill paid option is selected as “Yes”. Validation - After Bill date and less than current Date.

    Attach Documents

    Doc Attachments

    N

    Option to upload documents (Max of 5). Supported files - PDF, JPEG, PNG. Should show required validation for other types of files.

    Submit

    Button

    -

    On click, the consumer master gets created with the detail entered above. The new connection id also should get generated as per the configuration.

    Columns

    • Connection ID

      • New Connection ID of the consumer. If there is a metered connection, an “M” in ⭕️ is shown alongside connection ID

    • Name

      • Name of the consumer - Similar to Revenue dashboard truncate it to 20 characters and show 3 dots

    • Pending Collections

      • Total pending collections of the consumer till date.

    The table has sort options by all columns.

    The sorted and filtered table, as in the screen view, is exported into the PDF format dynamically on printing.

    Architecture

    NalJalSeva architecture details

    Service Architecture

    NalJalSeva is built on top of the DIGIT Platform. It consists of distinct layers listed below.​

    Back End - Core Services

    1. ​User Services (egov-user)

    2. (user-otp)

    3. ​ (access-control)

    4. ​

    5. (id-gen)

    6. ​ (pg-service)

    7. ​ (wf-service)

    8. ​

    9. ​

    10. ​ (data-encryption-service)

    11. ​e (localization-service)

    12. ​e (boundary-service)

    13. (location-service)

    14. ​ (url-shortening-service)

    15. ​ (pdf-generator)

    16. ​ (notification-sms)

    17. (notification-email)

    18. ​

    19. ​​

    Business Services

    1. ​

    2. ​

    3. ​

    4. ​

    Municipal Services

    1. ​ (property-services)

    2. ​ (ws-calculator)

    3. ​ (ws-service)

    4. ​ (echallan)

    NalJalSeva Architecture

    The sequence diagram below illustrates a typical interaction between the various services. Sample sequence diagram for a typical flow of DIGIT Microservices.

    Application Structure

    Update Password

    Users are redirected to the Update Password screen once they log in successfully the first time.

    Link: → {base url}/mgramseva/selectLanguage/login/updatepassword

    User Interaction On Screen

    • Enter the OTP sent on the user’s 10-digit mobile number.

    • Set the new password for logging into the application.

    • Click on Change Password to apply new password credentials for the user.

    • Users can see the allocated Gram Panchayat name and code in the table.

    Password Hint Card

    This feature helps match the user’s password and check if the password contains

    • Minimum 6 digits

    • At least one special character ( !#$%^&...)

    • At least one letter

    • At least one number

    Files Path

    Primary Files:

    Logic For Tenant Filtration

    Fetch the tenants from MDMS, based on the user roles in the user request filtering the tenants by comparing tenant IDs.

    Field Validations

    Fields
    Validations

    API Details

    End Point
    Request Method
    Request Info

    Stack

    1 → Language selection screen + Login screen + Update password + Update password success

    Pop → Login

    Widgets utilized from the library

    Widgets
    File Path
    Description

    Files Path

    View →

    Controller →

    Create Consumer API

    This page provides step-by-step instructions for creating a consumer in the mGramSeva system using two API calls. The first API call is to create a property, and the second API call is to make a connection for the consumer.

    Pre-requisites

    Before proceeding with the given tasks, ensure the following prerequisites are met:

    1. Authentication Token (authToken): Obtain a valid authentication token for the desired environment. This token is necessary to authenticate and authorize your requests.

    2. API Endpoints: Ensure you have access to both APIs required for creating a property and a consumer. Make sure you have the correct API documentation or information about the endpoints, request payloads, and any required headers.

    3. Postman: If you don't have Postman installed, download and install it. Import collection in Postman. Make sure you change the URL as per your requirements.

    Steps

    Follow the steps given below to create consumers using either Property Create API or Consumer Create API.

    Property Create API

    Here's a step-by-step guide:

    1. Locate the Property Creation API:

      • Open the Postman collection you imported.

      • Find the request corresponding to the Property Creation API. It might be named something like "Create Property" or similar.

    2. Set Request Parameters:

    Now, you have successfully created a property, and you have the propertyId copied for future use. Ensure to follow any additional instructions provided in the Postman collection or the API documentation.

    Consumer Create API

    Follow the steps below to create a consumer using the Consumer Creation API from the Postman collection:

    1. Locate the Consumer Creation API:

      • Open the Postman collection.

      • Find the request corresponding to the Consumer Creation API. It may be named "Create Consumer - Metered" for metered connections or "Create Consumer - Non-Metered" for non-metered connections.

    2. Set Request Parameters:

    By following these instructions and providing the necessary details, you should be able to successfully create a consumer with a property and connection in the NalJalSeva system. Ensure that you follow any additional guidelines or instructions provided in the Postman collection or API documentation.

    Change Password

    Users are redirected to this screen once they click on the Change Password option in the sidebar app drawer.

    Link → {base url}/mgramseva/home/changepassword

    User Interaction On Screen

    • Enter the Current Password

    iFIX Adapter

    The purpose of the NalJalSeva IFIX adapter service is to push the demand, bill, and payment events to IFIX from the NalJalSeva.

    Overview

    NalJalSeva IFIX adapter service is a wrapper for pushing data from the NalJalSeva to IFIX. When demand or payment is generated in the NalJalSeva system, the NalJalSeva IFIX adapter service listens to those topics and it calls the IFIX reference adapter service push API to publish the data to IFIX.

    <uses-permission android:name="android.permission.INTERNET"/>
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"></uses-permission>
    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"></uses-permission>
    <uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" />
    <uses-permission android:name="android.permission.QUERY_ALL_PACKAGES"/>

    Division User: HRMS_ADMIN, DIVISION_ADMIN

  • State User: HRMS_ADMIN, STATE_ADMIN

  • Username and Password: As per your host URL.

  • Path to the Excel file: Ensure the Excel file is in the same location as the script.

  • Execute the script.

  • User ID: If successful, the ID will be present.

  • Status: Will indicate either "Success" or "Failure." If failed, the reason for failure will be provided.

  • Pre-requisites

    Before you proceed with the configuration, make sure the following pre-requisites are met -

    • Java 8

    • Kafka

    • Spring boot

    Key Functionalities

    • Pushing demand, bill and payment events to the IFIX adapter

    The following topics interact with the NalJalSeva IFIX adapter service - When we create demand for ws-services, then it sends an event as demand for IFIX. If it is expense demand, it sends the event as a bill for IFIX. If it is a ws-services payment, then it sends the event as a receipt for IFIX. If it is an expense payment, it sends the payment as an event for IFIX.

    • naljalseva-create-demand

    • naljalseva-update-demand

    • egov.collection.payment-create

    Deployment Details

    Deploy the following build.

    • ifix-adapter:v1.0.0-4e24064-14

    Integration Details

    Integration Scope

    NalJalSeva IFIX adapter is integrated with the IFIX Reference adaptor service. NalJalSeva IFIX adapter Application internally invokes the IFIX Reference adaptor service to push the data.

    Integration Steps

    NalJalSeva IFIX adapter application triggers IFIX-reference-adapter/events/v1/_push to push the demand, bill, and payment events from NalJalSeva to IFIX.

    Demand (Bulk)

    EMP/GP Users

    Dear <user>, Demand for Billing Cycle <Cycle> has been generated for <GPWSC>. Kindly plan for collection of water charges for this period. <Link>

    1st of each month

    Pending Collection Reminder

    EMP/GP Users

    Dear <user>, Rs. <Amount> is pending collections against water charges at <GPWSC> as of <Date>. Click <Link> to see more details

    fortnight

    On Collection Day

    EMP/GP Users

    Dear <user>, Rs. <Amount> has been collected today <Date> against water charges from <number> consumers in Cash for <GPWSC>.

    On Collection Day

    EMP/GP Users

    Dear <user>, Rs. <Amount> has been collected today <Date> against water charges from <number> consumers Online for <GPWSC>.

    New Calendar Month

    EMP/GP Users

    Dear <user>, Rs. <Amount> has been collected in <previous month> against water charges & Rs. <Amount> has been spent as expenditure for <GPWSC>. Click <link> to see more details

    Fortnight

    EMP/GP Users

    Please enter new expenditure bills online for <GPWSC>. Click <link> to make an expense entry now

    Alternate Fortnight

    EMP/GP Users

    Expenditure bills for <GPWSC> are awaiting payment confirmation. Please click <link> and mark them as paid, if paid already

    Demand (Bulk) - (NM & M)

    Consumer

    Dear <user>, water bill for <cycle> has been generated for consumer id <new consumer id> for Rs. <Amount>. Click <link> to download latest bill.

    Dear <user>, water bill for <cycle> has been generated for consumer id <new consumer id> for Rs. <Amount>. Click <link> to download latest bill. Please make payment to your GPWSC.

    Demand (Bulk) - (NM & M)

    Consumer

    Dear <user>, pending amount for water charges for consumer id <new consumer id> is Rs. <Amount>. Click <link> to pay online.

    Bill Paid

    Consumer

    Dear <user>, Rs. <Amount> has been paid for water charges for consumer id <new consumer id>. Pending Amount is Rs. <Amount>. Click <link> to download receipt

    Feedback Collection

    Consumer

    Dear <user>, Thank you for paying water charges. Please take this short survey and help us know more about water supply at <GPWSC>

    Whatspp Message - Bill share

    Consumer

    x

    Whatsapp Message - Bill Payment

    Consumer

    Dear <user>, Rs. <Amount> has been paid for water charges for consumer id <new consumer id>. Pending Amount is Rs. <Amount>. Click <link> to download receipt

  • Review the request parameters for creating a property.

  • For metered connections, provide values for initialMeterReading, meterReading, meterId, and previousReading. Set them to null if not applicable.

  • Set ConnectionType to "Metered" for metered connections and "Non_Metered" for non-metered connections.

  • Ensure that oldConnectionNo is unique every time you create a property.

  • Execute the Request:

    • Click on the "Send" button to execute the request.

    • Review the response to confirm that the property has been created successfully.

  • Copy Property ID:

    • In the response, you should find the propertyId field. Copy the value of propertyId as this will be needed for subsequent steps.

  • Review the request parameters for creating a consumer.

  • For metered connections, provide values for initialMeterReading, meterReading, meterId, and previousReading. Set them to null if not applicable.

  • Set ConnectionType to "Metered" for metered connections and "Non_Metered" for non-metered connections.

  • Ensure that oldConnectionNo is unique every time you create a consumer.

  • Use the propertyId obtained from creating the property as instructed in the previous step.

  • Execute the Request:

    • Click on the "Send" button to execute the request.

    • Review the response to ensure that the consumer has been created successfully.

  • this
    https://digit-discuss.atlassian.net/wiki/spaces/DD/pages/1620574288
    https://digit-discuss.atlassian.net/wiki/spaces/DD/pages/1620672528
    https://www.getpostman.com/collections/142983a40e95da157b45
    https://www.getpostman.com/collections/142983a40e95da157b45
  • This is disabled as of now we can enable or disable sms in https://github.com/ddws-org/Naljal-DevOps/blob/LTS-upgrade/deploy-as-code/helm/environments/naljal-uat.yaml#L388

  • Dear “username”, A new water bill has been generated against <Connection ID>. Please pay the bill online to avoid late payment charges <link>.

  • ​Dashboard Analytics (DSS)

    ​User Events (user-event)

  • ​Vendor​

  • ​IFIX Adaptor Integration Service​

  • ​User OTP
    Access Control
    MDMS
    ​ID Generation Service
    Payment Gateway
    Workflow Service
    Persister
    Indexer
    Encryption Service
    Localization Servic
    Boundary Servic
    Location Service
    URL Shortening Service
    PDF Generation Service
    SMS Notifications
    Email Notifications
    Filestore
    API Gateway
    Billing Service​
    Collection service​
    Apportioning Service​
    Dashboard Ingest​
    Property Service
    Water Service Calculator
    Water Service
    eChallan

    Enter and Confirm a New Password to set the login credentials for the next time login

  • Click the Change Password Button. The user login password is set to the new password.

  • Password Hint Card

    This feature helps match the user password to the requirements and checks if the password contains

    • Minimum 6 digits

    • At least one special character ( !#$%^&...)

    • At least one letter

    • At least one number

    File Path

    Primary Files:

    punjab-mgramseva/Changepassword.dart at develop · egovernments/punjab-mgramseva

    Field Validations

    Fields
    Validation

    Current Password*

    No Validation

    Set a New Password*

    r'^(?=.*?[A-Za-z])(?=.*?[0-9])(?=.*?[#?!@$%^&*-]).{6,}$'

    Confirm New Password*

    Match with New Password

    API Details

    End Point
    Request Method
    Request Info

    user/password/_update

    POST

    "userName": {}, "existingPassword": {}, "newPassword": {}, "tenantId": {}, "type": {}

    Stack

    1 → Home Screen. + Change Password Screen

    Pop → Home Screen

    Widgets utilised from the Library

    Widgets
    File Path
    Description

    BuildTextField

    Text Field

    Button

    Button

    Enter the OTP sent *

    r'^[0-9]+$' , 6 digit

    Enter a New Password*

    r'^(?=.*?[A-Za-z])(?=.*?[0-9])(?=.*?[#?!@$%^&*-]).{6,}$'

    Confirm New Password

    Match with New Password

    user/password/nologin/_update

    POST

    "otpReference": {}, "userName": {}, "newPassword": {}, "tenantId": {}, "type": “Employee”

    egov-mdms-service/v1/_search

    POST

    "MdmsCriteria": { "tenantId": tenantId, "moduleDetails": [ { "moduleName": "tenant", "masterDetails": [ {"name": "tenants"} ], }, ] }

    BuildTextField

    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/TextFieldBuilder.dart

    Text Field

    BottomButtonBar

    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/BottonButtonBar.dart

    Button

    PasswordHint

    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/PasswordHint.dart

    Password Hint Card

    punjab-mgramseva/Updatepassword.dart at develop · egovernments/punjab-mgramsevaGitHub
    punjab-mgramseva/Updatepassword.dart at develop · egovernments/punjab-mgramsevaGitHub
    punjab-mgramseva/tendants_repo.dart at develop · egovernments/punjab-mgramsevaGitHub
    app.config.dart
    mgramseva
    link
    https://drive.google.com/file/d/14teTA0nqHaFLEkgg_LCHTcji5cRJDnXR/view?usp=sharing - Restricted link, try another account

    Update Consumer

    Overview

    The Update Consumer screen allows users to edit and update consumer information and details.

    Design & Workflow

    Users can search for the consumers using -

    1. Consumer mobile number

    2. Name of the consumer

    3. New connection ID

    The user details are fetched based on the input search criteria.

    Edit Screen

    • Users with permission to edit consumer records can click on the Edit Consumer info tile on the home screen. This navigates them to the consumer search screen.

    • Users can navigate to the Consumer Edit Screen from the search screen or the search results screen (Case when multiple search results are displayed).

    • On the successful load of the consumer edit screen, all data parameters of the consumer are shown (with editable and non-editable fields).

    • By Default - A new consumer ID is shown on the top of the screen and is non-editable.

    The table below lists the editable field details -

    Date Field
    Before First Demand
    After First Demand
    Comments

    Edit Options

    1. In case there are arrears, demand is generated. If there are no arrears, demand is not generated.

    2. Users can modify the arrear value. In such a case, demand is generated with the updated value.

    3. Users can add arrear to the connection, for which arrear was zero at the time of creating the connection. In such a case, new demand is generated.

    Clicking on the Submit button shows a nudge saying Details Submitted Successfully. Closing the nudge navigates the user back to the home screen.

    The CTA is activated only when any field is changed or updated. Else, it is in an inactive state.

    Search Consumer & Generate Payment

    Metered & Non-Metered Connection

    Metered Connection

    Click on the Generate Bill card on the home page to search for a consumer record once the consumer is created.

    The application enables users to search a consumer record by Consumer’s Phone Number, Name of the Consumer, Old Connection ID or New Connection ID.

    Click on the Search button to view the consumer records. Click on the View Consumer Details button to perform the necessary action.

    Users can see the relevant information of a particular consumer. Click on Generate a New Bill button to create a fresh bill. Enter the Previous Meter Reading, New Meter Reading and Meter Reading Date. Click on Generate Bill. A fresh bill is generated for the consumer.

    Once the bill is generated, the user can collect payment for the particular bill. Click on the Collect Payment button to collect the payment via cash or online payment.

    Click on the phone icon in green to share the bill with the consumer via SMS.

    Enter/Update the Payment Amount or Partial Payment to indicate whether the consumer is paying the bill amount in full or making a partial payment. Enter the Amount that is being paid by the consumer in case it is a Partial Payment.

    Select the applicable Payment Method as either Cash or Online. Users can also provide consumers with a scannable QR code to make the payment online.

    Click on the Download button to download the payment receipt.

    Click on the Share icon to send the receipt to the consumer via SMS.

    Non–Metered Connection

    Click on the Collect Payment icon on the home page to search for a consumer record by Consumer’s Phone Number or Name of the Consumer or Old Connection ID or New Connection ID.

    Click on the Search button to view the consumer records. Click on the View Consumer Details button to perform the necessary action.

    Click on the Collect Payment button to collect the payment via cash or online payment. Click on the Share Bill button to send the bill to the consumer on the registered mobile number via SMS.

    Select Full Payment or Partial Payment to indicate whether the consumer is paying the bill amount in full or making a partial payment. Enter the Amount that is being paid by the consumer in case it is a Partial Payment.

    Select the applicable Payment Method as either Cash or Online. Users can also provide consumers with a scannable QR code to make the payment online.

    Click on the Download button to download the payment receipt. Click on the Share icon to send the receipt to the consumer via SMS.

    Once the payment is completed an SMS is sent to the consumer to take the survey on the water service.

    Search Department Employee

    Across state/block

    Overview

    State/Block employees can search all employees across the state/block.

    Design & Workflows

    Edit Profile

    Users are navigated to the Edit Profile screen once they click on the option on the sidebar app drawer.

    Link - → {base url}/mgramseva/home/editProfile

    User Interaction On Screen

    • User can change their profile name, gender and email on this screen

    Home Page

    Users are redirected to the home page screen after successful login. ​ This screen consists of multiple sections and user interactions. If the user is mapped to multiple tenants then a dropdown appears. The user can select the desired tenant to proceed further. Once the user selects the tenant, the feature cards are displayed on the screen based on the roles mapped for the selected tenant.

    First Time Login

    YES → WalkThrough/User Guidance Enabled

    NO → Home Screen

    If the user logs in for the first time a system walkthrough begins automatically.

    Select Language

    Users land on the Language Selection screen.

    Link → {base url}/mgramseva/selectLanguage

    User Interaction On Screen

    • Users can switch to different languages that the application supports.

    Edit Scheme Rate Master

    Overview

    Only Block Users can update the rate master of a Scheme.

    Design & Workflows

    Make sure in the dropdown of the block, the user selects the concerned scheme to modify.

    Create Workflow

    This page provides the steps to follow to create a workflow in NalJalSeva. Here is the reference to the DIGIT .

    Follow the steps below to create a workflow in NalJalSeva.

    Steps

    Follow these steps to create a workflow in NalJalSeva:

    1. Check Existing Workflow:

  • Utilize the provided Postman collection that includes workflow creation and search APIs.

  • Use the search API to check if the workflow for the specified state already exists.

  • Workflow Creation:

    • If the workflow is not present, proceed to create it using the create API.

    • Ensure to provide the necessary details in the userInfo section and give superuser information.

    • Adjust parameters like tenantId and roles according to your specific requirements.

  • Port Forwarding:

    • Execute port forwarding to the workflow service using the following kubectl command:

      Replace <pod-name> with the appropriate pod name.

  • Create Workflow:

    • After port forwarding, initiate the workflow creation process.

  • Search Through API:

    • Use the search API to verify that the workflow has been successfully created.

    • Adjust the search parameters as needed.

  • These steps ensure a smooth workflow creation process inNalJalSeva. Make sure to follow each step in sequence for a seamless experience.

    workflow service
    kubectl port-forward <pod-name> -n mgramseva

    Father’s Name

    YES

    YES

    Phone number

    YES

    YES

    Use Cases

    1. After the phone number is changed, searching with the old/new phone number in the connection search screen leads to the same HH screen

    2. SMS notifications are sent to the new mobile number of the user from the date of the change

    Old Connection ID

    YES

    NO

    Validated for unique IDs in the system for the GPWSC

    Door Number

    YES

    YES

    Street Number / Name

    YES

    YES

    Ward Number / Name

    YES

    YES

    Gram Panchayat Name

    NO

    NO

    Property Type

    YES

    YES

    Charges applicable as per rate master. Effects take place from the next billing cycle

    Service Type

    YES

    YES

    • Effects take place from the next billing cycle

    • The last date of the current billing cycle is taken as the last meter reading date

    • Previous meter reading is captured while generating the demand

    Meter Number

    YES

    YES

    Previous meter reading Date

    YES

    NA

    This field is not shown on screen after the first demand is generated

    Previous Meter Reading

    YES

    NA

    This field is not shown on the screen after the first demand is generated

    Last Billing Cycle Billed

    YES

    NA

    This field is not shown on the screen after the first demand is generated

    Arrears as of Last Bill

    YES

    NA

    This field is not shown on the screen after the first demand is generated. When changed the arrear demand is deleted and updated accordingly based on the selected service type.

    Mark Connection as inactive

    YES

    YES

    If a connection is marked inactive, it is not considered for demand generation for future billing cycles.

    An inactive connection can be reactivated later from this screen.

    New Consumer ID

    NO

    NO

    Consumer ID is generated while user creation and is not editable

    Consumer’s Name

    YES

    YES

    bills, receipts, bill generation screens etc starts displaying the newly entered consumer name

    Gender

    YES

    YES

    State User

    State users have to select the applicable block to search for the employee in that block.

    State users can select one role or select all roles to see all users in the selected block.

    Further, the drill-down state user can select the concerned panchayat in the block along with the concerned scheme in that block. If nothing is selected it includes all panchayat and scheme within the block.

    Block User

    Block Users can search all employees under the block he/she is mapped to. To search user click on “Search Department User”.

    Once clicked -

    The block user can select the Panchayat within the block to which the employee is mapped.

    Users can further drill down to the scheme once they select a panchayat. It will display the list of schemes under the selected panchayat.

    Block users can select roles in the roles dropdown field. Users can select all or select concerned roles.

    The search result can be downloaded/viewed on the screen.

    Visible details of Employee

    1. EmployeeID

    2. Employee Name

    3. Type Of user

    4. Designation 5.Mobile Number

    5. Status

    6. Scheme

  • Click on the Save button triggers a Details Saved Successfully message on the screen and saves the changes to the profile.

  • File Path

    Primary Files:

    punjab-mgramseva/EditProfile.dart at develop · egovernments/punjab-mgramseva

    Field Validations

    Fields
    Validations

    Name

    r'^[a-zA-Z ]+$'

    Email ID

    r'^$|^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$'

    API Details

    End Point
    Request Method
    Request Info

    /user/profile/_update

    POST

    "user": { "id": {}, "userName": {}, "salutation": null, "name": {}, "gender": {}, "mobileNumber": "9191919146", "emailId": {}, "altContactNumber": null, "pan": null, "aadhaarNumber": null, "permanentAddress": null, "permanentCity": null, "permanentPinCode": null, "correspondenceAddress": null, "correspondenceCity": null, "correspondencePinCode": null, "active": true, "locale": null, "type": "EMPLOYEE", "accountLocked": false, "accountLockedDate": 0, "fatherOrHusbandName": null, "relationship": null, "signature": null, "bloodGroup": null, "photo": null, "identificationMark": null, "createdBy": {}, "lastModifiedBy": {}, "tenantId": {}, "roles": [ {} ], }

    Stack

    1 → Home Screen. + Edit Profile Screen

    Pop → Home Screen

    Widgets utilised from the Library

    Widgets
    File Path
    Description

    BuildTextField

    Text Field

    BottomButtonBar

    Button

    RadioButtonField

    Radio Buttons for options

    Otherwise, users can view walkthroughs at any time by clicking on the help icon.

    Logic Implemented For Walkthrough

    Create a global key for each card.

    Create placeholder cards, pointers and description widgets.

    On click, the position of the card is determined and the placeholder card appears on the overlay exactly.

    Files Path

    Primary Files:

    punjab-mgramseva/HomeWalkThroughContainer.dart at develop · egovernments/punjab-mgramseva,

    punjab-mgramseva/HomeWalkThroughList.dart at develop · egovernments/punjab-mgramseva

    Next → Changes the active index of the global key and repeat the same process outlined in the implementation logic skip,

    End → closes the overlay

    Home Screen - consists of multiple feature cards

    Cards are displayed based on Role Access.

    Notifications

    The home screen also consists of notifications. The notifications are customized for each user ID and user role.

    Logic Implemented For Notifications

    Individual API calls are made with the user ID and with the user role that merges both and notifications are displayed accordingly.

    Files Path

    Primary Files:

    punjab-mgramseva/Home.dart at develop · egovernments/punjab-mgramseva

  • Click on Continue to navigate to the next screen.

  • File Path

    Primary files:

    punjab-mgramseva/languageSelection.dart at develop · egovernments/punjab-mgramsevaGitHub

    Secondary files:

    punjab-mgramseva/DesktopView.dart at develop · egovernments/punjab-mgramsevaGitHub

    punjab-mgramseva/MobileView.dart at develop · egovernments/punjab-mgramsevaGitHub

    Data Storage

    LocalStorage

    Key
    Stored Data

    states_key

    State Information for From MDMS Service

    ex :pn_IN,en_IN,hi_IN

    Localization codes

    API Details

    API EndPoint
    Input Params (Modules)
    Description

    egov-mdms-service/v1/_search

    common-masters tenant

    To fetch details State info Logo background Image Languages supported

    localization/messages/v1/_search?module={}locale={}tenantId={}

    ALL the necessary Modules, with locale key and tenant Id

    To Load the Localized data

    Stack

    0 → Language selection screen

    Pop → Application closes

    Widgets utilized from library

    Widgets Library

    Button Bar

    App - initial screen

    Once clicked on “rate master” it will redirect to the rate master screen.

    A list of Rate masters can be seen in different configurations -

    1. Residential / non-metered

    2. Residential / metered

    3. Commercial / non-metered (not used in Naljal yet)

    4. Commercial / Metered (not used in Naljal yet)

    5. Public Sector / Non-metered (not used in Naljal yet)

    6. Public sector/ Metered (not used in Naljal yet)

    7. Mixed / Metered (not used in Naljal yet)

    8. Mixed / Non-metered (not used in Naljal yet)

    Edit Existing Rate Master

    Click on the rate master configuration you want to edit/disable.

    Click on edit.

    Edit Non-metered Residential Rate

    Edit Metered Connection

    Data Points

    “From” is the starting of unit “To” is end of unit “Rate” is rate defined within that slab

    For example if from is 0 and to is 5 and rate is 5 . consumer 3unit than the rate Will be 3*5= 15 rs

    Add Rate Master

    By default, state configuration is shown in the rate master if no rates are defined for a particular tenant. How to know this

    If you try to edit the rate master shown it will throw you an error.

    Building Type

    Connection Type

    Calculation Attributes

    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/TextFieldBuilder.dart
    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/Button.dart

    Configure SMS Template

    This page provides details on how to register the SMS templates with the specified TEMPLATE ID for each Localization key and append the TEMPLATE ID at the end of the message in the Localization system.

    Steps

    To register the provided SMS templates with a specific TEMPLATE ID for each Localization key and append the TEMPLATE ID at the end of the message

    The sample SMS messages in the table below have to be registered with a specific TEMPLATE ID (Eg.'100700746377980') for each Localization key.

    Append the TEMPLATE ID at the end of the message.

    Push the SMS templates in Localisation.

    Action
    Localization key
    Localization message

    Update Master Rate

    This page outlines the step-by-step process for using a Python script to change master rates for NalJalSeva in bulk. The script reads data from an Excel file, updates the master rates, and generates a new CSV file containing the modified information. Once the script is successfully executed, changes can be pushed to the local MDMS repository on GitHub.

    Pre-requisites

    • Python script

    • MDMS repository cloned on the local system

    • Excel file with tenant names, old master rates, and new master rates

    Steps

    1. Prepare Excel File:

    • Ensure the Excel file contains three columns: Tenant Name (in lowercase), Old Master Rate, and New Master Rate.

    • If the columns are not present, add them to the Excel file.

    2. Clone and Create Branch:

    • Clone the MDMS repository to your local system.

    • Create a new branch from the branch where you intend to make changes.

    3. Update Python Script:

    • Open the Python script and locate the variables:

      • updatedfile: Provide the path to your Excel sheet.

      • localFilePath: Specify the path where your MDMS repository is cloned.

    • Run the script.

    4. Script Execution:

    • Do not open the Excel file during script execution.

    • The script will generate a new file named new_updated_file4.csv containing information about whether rates were updated or not.

    5. Verification:

    • Check new_updated_file4.csv to verify if all rates were updated successfully.

    6. Push Changes to Git:

    • If all rates are updated, the local changes will affect the MDMS repository.

    • Raise a pull request and merge changes from the Git repository.

    Note:

    • It is crucial not to open the Excel file while the script is running to avoid data inconsistencies.

    • Ensure that the Python environment and dependencies are properly set up.

    Follow the above steps to update NalJalSeva master rates in bulk, and ensure precise and streamlined changes to the MDMS repository.

    Download Bills & Receipts

    Overview

    There is an option to download bills without clicking on collect payment.

    Design & Workflows

    1. Bills and Receipts can be downloaded by clicking on the card/tile named Download Bills & Receipts on the home page.

    2. Clicking on this card takes the user to the consumer search page. Searching by a phone number/ connection ID redirects to the Household Detail page.

    mGram.GPUser.CollectionReminder

    Dear {ownername}, Rs.{amount} is pending collections against Water Charges at {WIMC} as of {Date}. Click {PENDING_COL_LINK} to see more details. DWSS

    New Calendar Month

    mGram.GPUser.PreviousMonthSummary

    Dear {user}, Rs.{PREVIOUS_MONTH_COLLECTION} has been collected in {PREVIOUS_MONTH} against water charges & Rs.{PREVIOUS_MONTH_EXPENSE} has been spent as expenditure for {WIMC}. Click {LINK} to see more details. DWSS

    Fortnight

    NEW_ENPENDITURE_SMS_EN_REMINDER

    Please enter new expenditure bills online for {WIMC}. Click {NEW_EXP_LINK} to make an expense entry now. DWSS

    Alternate Fortnight

    MARK_PAID_BILL_SMS_EN_REMINDER

    Expenditure bills for {WIMC} are awaiting payment confirmation. Please click {EXP_MRK_LINK} and mark them as paid, if paid already. DWSS

    Demand (Bulk) - (NM & M)

    mGram.Consumer.NewBill

    Dear {ownername}, New water bill for Billing Cycle {Period} has been generated for Consumer Id {consumerno} for Rs.{billamount}. Click {BILL_LINK} to download latest bill. DWSS

    Demand (Bulk) - (NM & M)-1

    mGram.consumer.payment.message

    Dear {ownername}, Pending Amount for water charges for Consumer Id {connectionno} is Rs.{billamount}. Click {PAY_LINK} to pay online. DWSS

    Bill Paid

    Gram.Consumer.DownloadReceipt

    Dear {ownername}, Rs.{amountpaid} has been paid for Water Charges for Consumer Id {consumercode}. Pending Amount is Rs.{pendingamount}. Click {RECEIPT_LINK} to Download Receipt. DWSS

    Feedback Collection

    mGram.Consumer.TakeSurvey

    Dear {ownername}, Thank you for paying water charges. Please take this short survey {SURVEY_LINK} and help us know more about water supply at {WIMC}. DWSS

    First time login OTP

    RESET_PASSWORD_FIRST_TIME_OTP

    OTP to reset password on NalJal is {otp}

    Forgot Password OTP

    RESET_PASSWORD_OTP

    OTP to reset password on NalJal is {otp}

    Creation login details

    MGram.User.Invitation

    Dear {USER}, You've been invited to NalJal Application. Please login using {LINK}. Username: {PHNO} Password: {PASSWORD}

    Demand (Bulk)

    mGram.GP.MonthlyDemandGenerated

    Dear {ownername}, Demand for Billing Cycle {billingcycle} has been generated for {tenant -name}. Kindly plan for collection of Water Charges for this period. {LINK} DWSS

    Pending Collection Reminder

    Identify the columns in the Excel file where the Tenant Name, Old Master Rate, and New Master Rate are stored. Update the script accordingly:
    9KBMaster Rate Tracking.xlsx
    3KBChangeTariffOfVillage.py
    uniqueVillageName = row[2].value
    oldMasterRate = row[7].value
    newMasterRate = row[8].value
    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/TextFieldBuilder.dart
    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/BottonButtonBar.dart
    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/RadioButtonFieldBuilder.dart

    Reindexing

    We use re-indexing to transfer all data to the appropriate indexer. This process involves two steps:

    1. Run the connector from the playground.

    2. Call the legacy indexer service, which internally queries the plain search service to retrieve data and send it to the appropriate indexer.

    Pre-requisites

    • Access to kubectl of the environment targeted

    • Plain search APIs in the respective services

    NalJalSeva uses 3 main indexes for re-indexing:

    • Water-services

    • e-challan-services

    • dss-collection_v2

    Re-indexing Steps

    • ws-services re-indexing - Kafka Connector Curl to be run from playground pod

    Plain Search Call

    EChallan-Reindexing

    Kafka Connector Call to be run from Playground pod:

    Legacy Index call from postman:

    • Dss collection v2 re-indexing - Kafka Connector call to be run from playground pod

    payment re-indexing run from postman call

    Create Users

    Steps to create and add users on NalJalSeva platform post-installation

    Overview

    Follow the steps provided on this page to create and add users on the mGramSeva platform once the installation is complete.

    Pre-requisites

    Ensure the Postman utility is installed to run the following scripts. If not, on the local machine.

    Steps To Create Users

    There are two methods to create users - either through API or through port-forwarding. To create users through port-forwarding refer .

    Follow the steps given below to create different types of users through the API.

    There are primarily three different types of users as listed below:

    • Super User

    • Anonymous User

    • System User

    Super User - A superuser is a privileged user account with elevated access rights in a computer system or application. It is typically reserved for administrators or trusted personnel and grants them full control and unrestricted access to all system resources. Superusers are necessary to manage and maintain the system, perform critical tasks, and troubleshoot issues efficiently.

    A Superuser is created using the createnovaildate API. Below is the curl given for creating a superuser.

    Steps to follow:

    1. Import the curl given below in Postman.

    2. Refresh the authorisation token.

    3. Provide User data as per requirements. This API will create a Super User in production. To add users in any other environment change the URL.

    The parameters - userName, name, gender, mobileNumber, tenantId, and password can be changed as per requirements.

    Anonymous User -An anonymous user is a generic or unauthenticated user account that does not require login credentials to access certain parts of a system or website. These accounts are essential for providing basic access to public information or services without requiring user registration. They are commonly used to ensure accessibility for a wide audience and encourage user interaction while preserving user privacy. These are used when the system is accessing non-authentication links such as bills and payment receipts.

    Creating an anonymous user is the same as creating a superuser. The only difference is to change the name and code in roles. The API below is used to create an Anonymous User in production.

    System User - Creating a system user is the same as creating a superuser and anonymous user. The only difference is to change the name and code in roles.

    While creating any user make sure your roles are present in .

    Here, 'pb' is used as tenantId since we are creating users at the state-level.

    Login

    Users are redirected to this screen once they select the preferred language in the previous screen.

    Link → {base url}/mgramseva/selectLanguage/login

    User Interaction On Screen

    • Users enter the registered Phone Number and Password.

    • Click on Continue.

    • First-time login users navigate to Reset Password Page.

    Log in with the default password

    YES → ​

    NO → ​

    File Path

    Primary Files:

    ​

    Field Validations

    Fields
    Validations

    API Details

    End Point
    Request Method
    Request Info

    Stack

    1 → Language selection screen. + Login screen.

    Pop → Language selection screen.

    Widgets utilized from the library

    Widgets
    File Path
    Description

    Edit Penalty Master

    Overview

    Only Block Users can update the Penalty Master of a Scheme.

    Design & Workflows

    Ensure the user selects the correct scheme to modify from the Scheme dropdown.

    Edit Existing Penalty master

    Click on the Penalty Master configuration you want to Edit/Disable.

    Data Points:

    Rate -> In percentage 10 means 10%, 20 Means 20% of the water charge configured Type -> fixed Amount -> Not required From FY -> 2023-24 Subtype -> Current Month Minimum amount -> not required Flat amount -> not required (it is used for a flat amount of Penalty) Starting Date -> From the date the penalty ID is applicable Applicable After days -> days after demand generation the penalty is applicable

    Add Penalty Master

    Contact Us - eGov FoundationeGov Foundation

    Scheduler

    Schedulers are designed to run a particular service at a scheduled time, without triggering manually. We can have multiple schedulers for an application. It will consider the GMT format only.

    How CronJob Works

    The Python script reads the mdms-read-cronjob JSON from the MDMS service using a token from the CRONJOB user.

    Identify the APIs set up in this MDMS using the provided script argument. The script uses the config from the MDMS to call the corresponding API.

    Configure Domain Name

    Domain or subdomain registry and mapping cname

    Overview

    Follow the steps provided on this page to configure domains or subdomains registry and mapping CNAME.

    Steps

    Rollout Dashboard

    The NalJalSeva Rollout Dashboard Scripts gather data from the NalJalSeva database and services for the Metabase Rollout dashboard. This Python script transfers data daily from NalJalSeva to a database table, which is then used to create visual dashboards in Metabase.

    Pre-requisites

    Before you proceed with the configuration, make sure the following pre-requisites are met -

    • Python 3.9

    Record & Modify Expense Bill

    Expenses Bill Recording

    Users can enter the expense details as and when incurred. Click on the Add Expense icon on the home page.

    Enter expense information like Type of Expense from the drop-down list available. The type of expenses can be Electricity, O&M, Salary & MISC etc.

    Enter Vendor Name, Amount, Bill Date, and Party Bill Date. Select Yes or No to indicate if the bill is paid or not. Click on the Choose File button to attach a supporting document.

    Enter the Payment Date if the bill is already paid before recording it into the system. Click on Submit to register the expense details.

    The expenditure entry is saved successfully.

    Modify Expense Bill

    Click on the Modify Expenses icon on the home page to modify expense details. Enter the Vendor Name, Type of Expense or Bill ID details to search for the specific expense record which needs to be modified.

    The system shows the expense records filtered by the search parameter. Click on the Update Expenditure button to modify a particular bill.

    Make the necessary modifications to the bill. Update the expense type, or vendor name, amount, or bill date details as required.

    Click on Submit to save the changes. Check the Mark this Bill as Cancelled box to indicate that the bill is cancelled.

    View Dashboards

    Main Dashboard

    The Dashboard provides the stakeholders at the department level with a consolidated view of the information on Revenue and Expenditure trends month-wise.

    Revenue Dashboard

    The Sarpanch, Treasurer and Secretary at the GPWSC level can view the collection details like Demand, Pending Collection, Actual Collection, Collection from Residential, Collection from Commercial and Collection from Others. The consumer-wise collection details view is also available.

    The Sarpanch, Treasurer and Secretary at the GPWSC level can view the expenditure details like total expenditure, the amount unpaid, the amount paid, total bills, pending bills, bills paid, Electricity bills, O&M and salary. The individual expense-wise details view is also available.

    Install Postman
    here
    ACCESSCONTROL-ROLES
    curl --location --request POST 'http://kafka-connect.mgramseva:8083/connectors/' \
    --header 'Cache-Control: no-cache' \
    --header 'Content-Type: application/json' \
    --header 'Postman-Token: 419e68ba-ffb9-4da9-86e1-7ad5a4c8d0b9' \
    --data-raw '{
        "name": "water-services-enriched-es-sink",
        "config": {
            "connector.class": "io.confluent.connect.elasticsearch.ElasticsearchSinkConnector",
            "type.name": "general",
            "tasks.max": "1",
            "max.retries": "15",
            "key.ignore": "false",
            "retry.backoff.ms": "5000",
            "max.buffered.records": "25",
            "value.converter": "org.apache.kafka.connect.json.JsonConverter",
            "errors.log.enable": "true",
            "key.converter": "org.apache.kafka.connect.storage.StringConverter",
            "read.timeout.ms": "100000",
            "topics": "water-services-enriched",
            "batch.size": "25",
            "max.in.flight.requests": "2",
            "schema.ignore": "true",
            "behavior.on.malformed.documents": "warn",
            "flush.timeout.ms": "3600000",
            "errors.deadletterqueue.topic.name": "water-services-enriched-failed",
            "errors.tolerance": "all",
            "value.converter.schemas.enable": "false",
            "name": "water-services-enriched-es-sink",
            "connection.url": "http://elasticsearch-data-v1.mgramseva:9200",
            "linger.ms": "1000",
            "transforms": "TopicNameRouter",
            "transforms.TopicNameRouter.type": "org.apache.kafka.connect.transforms.RegexRouter",
            "transforms.TopicNameRouter.regex": "water-services-enriched*",
            "transforms.TopicNameRouter.replacement": "water-services-enriched"
        }
    }'
    curl --location --request POST 'http://localhost:8055/egov-indexer/index-operations/_legacyindex' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "RequestInfo": {
            "apiId": "string",
            "ver": "string",
            "ts": null,
            "action": "string",
            "did": "string",
            "key": "string",
            "msgId": "string",
            "authToken": "ca3256e3-5318-47b1-8a68-ffcf2228fe35",
            "correlationId": "e721639b-c095-40b3-86e2-acecb2cb6efb",
            "userInfo": {
                "id": 23299,
                "uuid": "e721639b-c095-40b3-86e2-acecb2cb6efb",
                "userName": "9337682030",
                "name": "Abhilash Seth",
                "type": "CITIZEN",
                "mobileNumber": "9337682030",
                "emailId": "[email protected]",
                "roles": [
                    {
                        "id": 281,
                        "name": "Citizen"
                    }
                ]
            }
        },
        "apiDetails": {
            "uri": "http://ws-services.mgramseva:8080/ws-services/wc/_plainsearch",
            "tenantIdForOpenSearch": "pb",
            "paginationDetails": {
                "offsetKey": "offset",
                "sizeKey": "limit",
                "maxPageSize": 25,
                "limit":25
            },
            "responseJsonPath": "$.WaterConnection"
        },
        "legacyIndexTopic": "ws-connection-legacyIndex",
        "tenantId": "pb"
    }'
    curl --location --request POST 'http://kafka-connect.mgramseva:8083/connectors/' \
    --header 'Cache-Control: no-cache' \
    --header 'Content-Type: application/json' \
    --header 'Postman-Token: 419e68ba-ffb9-4da9-86e1-7ad5a4c8d0b9' \
    --data-raw '{
        "name": "echallan-services-enriched-es-sink",
        "config": {
            "connector.class": "io.confluent.connect.elasticsearch.ElasticsearchSinkConnector",
            "type.name": "general",
            "tasks.max": "1",
            "max.retries": "15",
            "key.ignore": "true",
            "retry.backoff.ms": "5000",
            "max.buffered.records": "25",
            "value.converter": "org.apache.kafka.connect.json.JsonConverter",
            "errors.log.enable": "true",
            "key.converter": "org.apache.kafka.connect.storage.StringConverter",
            "read.timeout.ms": "100000",
            "topics": "echallan-services-enriched",
            "batch.size": "25",
            "max.in.flight.requests": "2",
            "schema.ignore": "true",
            "behavior.on.malformed.documents": "warn",
            "flush.timeout.ms": "3600000",
            "errors.deadletterqueue.topic.name": "echallan-services-enriched-failed",
            "errors.tolerance": "all",
            "value.converter.schemas.enable": "false",
            "name": "echallan-services-enriched-es-sink",
            "connection.url": "http://elasticsearch-data-v1.mgramseva:9200/",
            "linger.ms": "1000",
            "transforms": "TopicNameRouter",
            "transforms.TopicNameRouter.type": "org.apache.kafka.connect.transforms.RegexRouter",
            "transforms.TopicNameRouter.regex": "echallan-services-enriched*",
            "transforms.TopicNameRouter.replacement": "echallan-services-enriched"
        }
    }'
    curl --location --request POST 'http://localhost:8055/egov-indexer/index-operations/_legacyindex' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "RequestInfo": {
            "apiId": "string",
            "ver": "string",
            "ts": null,
            "action": "string",
            "did": "string",
            "key": "string",
            "msgId": "string",
            "authToken": "ca3256e3-5318-47b1-8a68-ffcf2228fe35",
            "correlationId": "e721639b-c095-40b3-86e2-acecb2cb6efb",
            "userInfo": {
                "id": 23299,
                "uuid": "e721639b-c095-40b3-86e2-acecb2cb6efb",
                "userName": "9337682030",
                "name": "Abhilash Seth",
                "type": "CITIZEN",
                "mobileNumber": "9337682030",
                "emailId": "[email protected]",
                "roles": [
                    {
                        "id": 281,
                        "name": "Citizen"
                    }
                ]
            }
        },
        "apiDetails": {
            "uri": "http://echallan-services.mgramseva:8080/echallan-services/eChallan/v1/_plainsearch",
            "tenantIdForOpenSearch": "pb",
            "paginationDetails": {
                "offsetKey": "offset",
                "sizeKey": "limit",
                "maxPageSize": 25,
                "limit":25
            },
            "responseJsonPath": "$.challans"
        },
        "legacyIndexTopic": "echallan-legacyIndex",
        "tenantId": "pb"
    }'
    curl --location --request POST 'http://kafka-connect.mgramseva:8083/connectors/' \
    --header 'Cache-Control: no-cache' \
    --header 'Content-Type: application/json' \
    --header 'Postman-Token: 419e68ba-ffb9-4da9-86e1-7ad5a4c8d0b9' \
    --data-raw '{
      "name": "cms-case-es-sink9121",
      "config": {
        "connector.class": "io.confluent.connect.elasticsearch.ElasticsearchSinkConnector",
            "connection.url": "http://elasticsearch-data-v1.mgramseva:9200",
        "type.name": "payments",
        "topics": "paymentsindex-v1-enriched",
        "key.ignore": "false",
        "schema.ignore": true,
        "value.converter.schemas.enable": false,
        "key.converter": "org.apache.kafka.connect.storage.StringConverter",
        "value.converter": "org.apache.kafka.connect.json.JsonConverter",
        "transforms": "TopicNameRouter",
        "transforms.TopicNameRouter.type": "org.apache.kafka.connect.transforms.RegexRouter",
        "transforms.TopicNameRouter.regex": ".*",
        "transforms.TopicNameRouter.replacement": "paymentsindex-v1",
        "batch.size": 10,
        "max.buffered.records": 500,
        "flush.timeout.ms": 600000,
        "retry.backoff.ms": 5000,
        "read.timout.ms": 10000,
        "linger.ms": 100,
        "max.in.flight.requests": 2,
        "errors.log.enable": true,
        "errors.deadletterqueue.topic.name": "paymentsindex-v1-es-failed",
        "tasks.max": 1
      }
    }'
    curl --location --request POST 'http://kafka-connect.mgramseva:8083/connectors/' \
    --header 'Cache-Control: no-cache' \
    --header 'Content-Type: application/json' \
    --header 'Postman-Token: 419e68ba-ffb9-4da9-86e1-7ad5a4c8d0b9' \
    --data-raw '{
        "name": "cms-case-es-sink9132",
        "config": {
            "connector.class": "io.confluent.connect.elasticsearch.ElasticsearchSinkConnector",
            "connection.url": "http://elasticsearch-data-v1.mgramseva:9200",
            "type.name": "general",
            "topics": "egov-dss-ingest-enriched",
            "key.ignore": "false",
            "schema.ignore": true,
            "value.converter.schemas.enable": false,
            "key.converter": "org.apache.kafka.connect.storage.StringConverter",
            "value.converter": "org.apache.kafka.connect.json.JsonConverter",
            "transforms": "TopicNameRouter",
            "transforms.TopicNameRouter.type": "org.apache.kafka.connect.transforms.RegexRouter",
            "transforms.TopicNameRouter.regex": ".*",
            "transforms.TopicNameRouter.replacement": "dss-collection_v2",
            "batch.size": 10,
            "max.buffered.records": 500,
            "flush.timeout.ms": 600000,
            "retry.backoff.ms": 5000,
            "read.timout.ms": 10000,
            "linger.ms": 100,
            "max.in.flight.requests": 2,
            "errors.log.enable": true,
            "errors.deadletterqueue.topic.name": "dss-collection_v2-es-failed",
            "tasks.max": 1
        }
    }'
    curl --location --request POST 'http://localhost:8055/egov-indexer/index-operations/_legacyindex' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "RequestInfo": {
            "apiId": "string",
            "ver": "string",
            "ts": null,
            "action": "string",
            "did": "string",
            "key": "string",
            "msgId": "string",
            "authToken": "b843ef27-1ac6-49b8-ab71-cd0c22f4e50e",
            "correlationId": "e721639b-c095-40b3-86e2-acecb2cb6efb",
            "userInfo": {
                "id": 23299,
                "uuid": "e721639b-c095-40b3-86e2-acecb2cb6efb",
                "userName": "9337682030",
                "name": "Abhilash Seth",
                "type": "EMPLOYEE",
                "mobileNumber": "9337682030",
                "emailId": "[email protected]",
                "roles": [
                    {
                        "id": 281,
                        "name": "Employee"
                    }
                ]
            }
        },
        "apiDetails": {
            "uri": "http://collection-services:8080/collection-services/payments/_plainsearch",
              "tenantIdForOpenSearch": "pb",
            "paginationDetails": {
                "offsetKey": "offset",
                "sizeKey": "limit",
                "maxPageSize": 50,
                "startingOffset": 150
            },
            "responseJsonPath": "$.Payments"
        },
        "legacyIndexTopic": "egov-payment-legacy-index",
        "tenantId": "pb"
    }'
    curl --location 'https://mgramseva-dwss.punjab.gov.in/user/users/_createnovalidate' \
    --header 'Content-Type: application/json' \
    --header 'Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJQQVlIQWZ1YXpiRFpadlVGdEJSdmFQOWxYaHROXzBUS2FzdUpxZWl3bW04In0.eyJleHAiOjE2NDA0MTM1MjMsImlhdCI6MTYzNzgyMTUyMywianRpIjoiZTZiNmQyNmQtY2EwYS00MDZmLTgxZGYtYTNiOTE0NGEzYTQ3IiwiaXNzIjoiaHR0cHM6Ly9pZml4LXVhdC5wc2Vncy5pbi9hdXRoL3JlYWxtcy9pZml4IiwiYXVkIjoiYWNjb3VudCIsInN1YiI6ImJhMDE1OGFiLWZlYTMtNDc5NC04ZDE3LTRiYjc4MjFhZmM2NyIsInR5cCI6IkJlYXJlciIsImF6cCI6ImlmaXgtdWF0IiwiYWNyIjoiMSIsInJlYWxtX2FjY2VzcyI6eyJyb2xlcyI6WyJvZmZsaW5lX2FjY2VzcyIsInVtYV9hdXRob3JpemF0aW9uIiwiZmlzY2FsLWV2ZW50LXByb2R1Y2VyIiwiZGVmYXVsdC1yb2xlcy1pZml4Il19LCJyZXNvdXJjZV9hY2Nlc3MiOnsiYWNjb3VudCI6eyJyb2xlcyI6WyJtYW5hZ2UtYWNjb3VudCIsIm1hbmFnZS1hY2NvdW50LWxpbmtzIiwidmlldy1wcm9maWxlIl19fSwic2NvcGUiOiJlbWFpbCBwcm9maWxlIiwiY2xpZW50SG9zdCI6IjE5Mi4xNzIuMzIuODYiLCJjbGllbnRJZCI6ImlmaXgtdWF0IiwiZW1haWxfdmVyaWZpZWQiOmZhbHNlLCJ0ZW5hbnRJZCI6InBiIiwicHJlZmVycmVkX3VzZXJuYW1lIjoic2VydmljZS1hY2NvdW50LWlmaXgtdWF0IiwiY2xpZW50QWRkcmVzcyI6IjE5Mi4xNzIuMzIuODYifQ.Wemcw5vLajX77GnHJmLq3-NhoEaBcySUyNQCpzfglBojTfF9-7xTk7ripf-VxlR3H5AsULIOsw1vRjTW255_3v-MwlYgRML4YE-d-Bt54v1SVnZ77NQsGRmmZ2UQ4wTwIhYQi2jaqzfTeAdU0fJAQTqo7POpTUcChTz_L6O7MQbVVpDJ3BRoWa5XX-BE6MYqZR1tBrLimvJEUWneohUEpPNncszmUAKEZkhEaiUhh8AzSJA3KtP18JOFC8KOCi7ErL-Vf-bJ928tpsNOMmFM2Syjxnqwu2rHE1ZPLdPUxGt6PGI9oJR7PEShakne0p9Fx-PLP8NxCPFCErq87U6zag' \
    --data-raw '{
        "RequestInfo": {
            "api_id": "1",
            "ver": "1",
            "ts": null,
            "action": "create",
            "did": "",
            "key": "",
            "msg_id": "",
            "requester_id": "",
            "authToken": "7d2b5b4f-6053-4633-941c-d30d67bc52b8",
            "token_type": "bearer"
        },
        "User": {
            "userName": "9399998206",                
            "name": "Test",
            "gender": "male",
            "mobileNumber": "9399998206",
            "active": true,
            "type": "EMPLOYEE",
            "tenantId": "pb",
            "password": "eGov@123",
            "roles": [
                {
                    "name": "Super User",
                    "code": "SUPERUSER",
                    "tenantId": "pb"
                }
            ]
        }
    }'
    curl --location 'https://mgramseva-dwss.punjab.gov.in/user/users/_createnovalidate' \
    --header 'Content-Type: application/json' \
    --header 'Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJQQVlIQWZ1YXpiRFpadlVGdEJSdmFQOWxYaHROXzBUS2FzdUpxZWl3bW04In0.eyJleHAiOjE2NDA0MTM1MjMsImlhdCI6MTYzNzgyMTUyMywianRpIjoiZTZiNmQyNmQtY2EwYS00MDZmLTgxZGYtYTNiOTE0NGEzYTQ3IiwiaXNzIjoiaHR0cHM6Ly9pZml4LXVhdC5wc2Vncy5pbi9hdXRoL3JlYWxtcy9pZml4IiwiYXVkIjoiYWNjb3VudCIsInN1YiI6ImJhMDE1OGFiLWZlYTMtNDc5NC04ZDE3LTRiYjc4MjFhZmM2NyIsInR5cCI6IkJlYXJlciIsImF6cCI6ImlmaXgtdWF0IiwiYWNyIjoiMSIsInJlYWxtX2FjY2VzcyI6eyJyb2xlcyI6WyJvZmZsaW5lX2FjY2VzcyIsInVtYV9hdXRob3JpemF0aW9uIiwiZmlzY2FsLWV2ZW50LXByb2R1Y2VyIiwiZGVmYXVsdC1yb2xlcy1pZml4Il19LCJyZXNvdXJjZV9hY2Nlc3MiOnsiYWNjb3VudCI6eyJyb2xlcyI6WyJtYW5hZ2UtYWNjb3VudCIsIm1hbmFnZS1hY2NvdW50LWxpbmtzIiwidmlldy1wcm9maWxlIl19fSwic2NvcGUiOiJlbWFpbCBwcm9maWxlIiwiY2xpZW50SG9zdCI6IjE5Mi4xNzIuMzIuODYiLCJjbGllbnRJZCI6ImlmaXgtdWF0IiwiZW1haWxfdmVyaWZpZWQiOmZhbHNlLCJ0ZW5hbnRJZCI6InBiIiwicHJlZmVycmVkX3VzZXJuYW1lIjoic2VydmljZS1hY2NvdW50LWlmaXgtdWF0IiwiY2xpZW50QWRkcmVzcyI6IjE5Mi4xNzIuMzIuODYifQ.Wemcw5vLajX77GnHJmLq3-NhoEaBcySUyNQCpzfglBojTfF9-7xTk7ripf-VxlR3H5AsULIOsw1vRjTW255_3v-MwlYgRML4YE-d-Bt54v1SVnZ77NQsGRmmZ2UQ4wTwIhYQi2jaqzfTeAdU0fJAQTqo7POpTUcChTz_L6O7MQbVVpDJ3BRoWa5XX-BE6MYqZR1tBrLimvJEUWneohUEpPNncszmUAKEZkhEaiUhh8AzSJA3KtP18JOFC8KOCi7ErL-Vf-bJ928tpsNOMmFM2Syjxnqwu2rHE1ZPLdPUxGt6PGI9oJR7PEShakne0p9Fx-PLP8NxCPFCErq87U6zag' \
    --data-raw '{
        "RequestInfo": {
            "api_id": "1",
            "ver": "1",
            "ts": null,
            "action": "create",
            "did": "",
            "key": "",
            "msg_id": "",
            "requester_id": "",
            "authToken": "7d2b5b4f-6053-4633-941c-d30d67bc52b8",
            "token_type": "bearer"
        },
        "User": {
            "userName": "9399998206",
            "name": "Test",
            "gender": "male",
            "mobileNumber": "9399998206",
            "active": true,
            "type": "EMPLOYEE",
            "tenantId": "pb",
            "password": "eGov@123",
            "roles": [
                {
                    "name": "anonymous",
                    "code": "ANONYMOUS",
                    "tenantId": "pb"
                }
            ]
        }
    }'
    NalJalSeva Schedulers

    A total of 7 schedulers are available in the NalJalSeva:

    _schedulerTodaysCollection: This scheduler will run daily to send the day collection amount to the collection employee.

    _jobscheduler/true: This is to send the notification to the ULB employee when the bulk demand auto-generation is failed.

    _schedulermarkexpensebill: This scheduler is used to mark the expense as paid for the paid expenses once every fortnight.

    _schedulernewexpenditure: This is used to send the notification once every fortnight regarding the no of expenditures created.

    _schedulermonthsummary: This is to send the monthly summary details to the ULB employee. _schedulerpendingcollection: This is to send the total pending amount details to the respective ULB employee user once every fortnight.

    _jobscheduler/false: This is used to generate the bulk demand automatically once every month.

    We have 7 different schedulers in NalJalSeva, running in 4 different time slots. We need to set them all to run the same Python scripts with different arguments, which you can find in the file under command -> args.

    Configure the scheduler's runtime under the cron -> schedule option.

    Example of failedBulkDemand scheduler:

    1. The cron schedule is set to "30 3 5 * *", which triggers the job at 3:30 AM GMT on the 5th day of every month. Converting this to IST, the job runs at 9:00 AM IST on the 5th day of each month.

    2. The command failedbulkdemand is used to instruct the Python script to invoke only the API configured as "failedbulkdemand" in the mdms-read-cronjob.mdms JSON file.

    crontab.guru - The cron schedule expression editor helps to define the pattern for the schedule cron.

    Configuration Details

    Infraops Configuration Changes

    PriorNote: In DevOps, the app name and schedule change based on the cron job file and set time. Arguments are set according to the job name in MDMS configuration.

    labels: App: monthly-cronjob Group: mdms-read-cronjob <!-- Stays the same as we use the same Python script

    cron: schedule: 30 3 4 * * // This depends on the time we need to run the scheduler

    image: repository: api-cronjob tag: v1

    command:

    • python3

    • cronJobAPIConfig.py

    args:

    • monthly // This is the job name which differs from the requirement based on the scheduler type.

    env:

    name: JOB_NAME

    valueFrom:

    fieldRef:

    fieldPath: metadata.name

    resources: |

    requests: {}

    The remaining fields will be the same for all the schedulers.

    Monthly: This will run and send the notification to the ULB employee or consumer on the 4th of every month morning at 9 am as per the scheduled time.

    Fortnightevening: This scheduler will run on the 1st and 15th of every month evening at 6 pm to send the respective notification to the Consumer.

    Failedbulkdemand: When the bulk demand generation is failed this scheduler will run and share the message to ULB employees to generate demand manually.

    Dailyevening: This scheduler will run daily and send notifications to the collection operator daily.

    Check the links below

    • Monthly

    • Failed Bulk Demand

    • Fortnight Evening

    • Daily Evening

    MDMS object details and configuration:

    {

    "jobName": "monthly", // This will change based on the job name

    "active": "true", // when the "active" param is set to true, the scheduler runs automatically. The scheduler does not run when set to false.

    "method": "POST",

    "url":http://echallan-services.mgramseva:8080/echallan-services/eChallan/v1/_schedulermonthsummary", // This is the respective service URL to call that service as per the scheduler.

    "payload": {

    "RequestInfo": "{DEFAULT_REQUESTINFO}" // this is common in all the schedulers used to send the request info.

    },

    "header": {

    "Content-Type": "application/json" // This is a common property for all schedulers.

    }

    }

    Here is the configuration for all the schedulers: Click here to see.

    Create User

    Need to create a user with CRONJOB as name and type as SYSTEM and ROLE as SYSTEM AND EMPLOYEE here is the sample curl to create the user.

    Deployment Details

    A Build ID (similar to the ID given below) is created when you build the cronjob. api-cronjob:develop-c0aa08a-2

    Take the id only from this instead of a complete name like develop-c0aa08a-2. This id will be used as the id for your respective yaml files and the same will be deployed to the required environment to test the cron job.

    For example:

    Mdms-read-cronjob:develop-c0aa08a-2,

    failedbulkdemand:develop-c0aa08a-2,

    Fortnightevening:develop-c0aa08a-2,

    monthly:develop-c0aa08a-2 Note: develop-c0aa08a-2 is the common build id for all the files which you are using.

    Run the cronjob manually - Steps

    • Delete the existing cron jobs if they already exist with the same name.

    • kubectl delete cronjob mdms-read-cronjob -n mgramseva

    • Deploy these builds in QA environments, which are related to cronjob schedulers

    • mdms-read-cronjob:develop-c0aa08a-2, failedbulkdemand:develop-c0aa08a-2, fortnightevening:develop-c0aa08a-2,monthly:develop-c0aa08a-2

    Test the cron job scheduler - Steps

    • kubectl get cronjob -n mgramseva -- to check the list of cron jobs

    • Create the job manually to test the messages. Below are the commands to create the jobs.

      • A message is received for the respective schedulers each time we run it.

      • We can increase the number to test again like failedbulkdemand-manually-1 next it will be failedbulkdemand-manually-2.

      • kubectl create job --from=cronjob/failedbulkdemand failedbulkdemand-manually-1 -n mgramseva

      • kubectl create job --from=cronjob/fortnightevening fortnightevening-manually-1 -n mgramseva

      • kubectl create job --from=cronjob/mdms-read-cronjob mdms-read-cronjob-manually-1 -n mgramseva

      • kubectl create job --from=cronjob/monthly monthly-manually-1 -n mgramseva

      • kubectl get job -n mgramseva -- to check the list of jobs

    To check the cronjob image

    kubectl describe cronjob mdms-read-cronjob -n mgramseva

    To delete specific job

    kubectl delete jobs mdms-read-cronjob-manually-1 -n mgramseva

    Create a CNAME (Canonical Name) entry in your domain's DNS settings and point it to the AWS load balancer or gateway URL. The external IP for the domain is provided by the AWS load balancer or gateway.

    The domain name is the address through which the internet users can access the website rather than entering the whole IP address in the search bar of the browser.

    This domain name is ideally chosen by the state/client since it is a product that has to be used for/by them.

    Data Table

    Following is the table through which the information can be shared.

    Sr. No.

    Domain Name

    EXTERNAL-IP

    1.

    3.108.166.195

    Note: The data given in the table is sample data.

    Process

    Since all state governments/clients prefer to host the websites on their servers, this activity is ideally done by them.

    Data Definition

    S.No.
    Column Name
    Data Type
    Data Size
    Is Mandatory?
    Description

    Domain Name

    Alphanumeric

    253

    Yes

    The name/address of the website being used to access the website/ module

    EXTERNAL-IP

    Alphanumeric

    Steps To Fill Data

    Following are the steps which are to be followed:

    1. Download the data template attached to this page.

    2. Get a good understanding of all the headers in the template sheet, their data type, size, and definitions by referring to the ‘Data Definition’ section of this document.

    3. In case of any doubt, please reach out to the person who has shared this template with you to discuss and clear your doubts.

    4. If the state agrees to host the website on their server, provide them with the 2 columns mentioned in the attached template.

    5. If the state disagrees to host on their server, then a domain name has to be purchased by any of the external vendors and the EXTERNAL-IP address has to be mapped with them.

    6. Verify the data once again by going through the checklist and making sure that each point mentioned in the checklist is covered.

    Checklist

    This checklist covers all the activities that are common across the entities.

    S.No.
    Checklist Parameter
    Example

    1

    Make sure that each and every point in this reference list has been taken care of.

    Attachments

    Following is the attached configurable data template in case the state is doing the required activities.

    1. Configurable Data Template - Domain Name Configuration - 9KBConfigurable Data Template Domain Name_V1.xlsx

    2. Sample Configurable Data - Domain Name Configuration - 9KBConfigurable Sample Data Domain Name_V1.xlsx

    NalJalSeva DB

  • NalJalseva user details who has access to MDMS service API

  • NalJalSeva MDMS service access

  • Key Functionalities

    Collects data on specific points and inserts it into the rollout dashboard table in the database. User Story details:

    IFIX-485: [1.0.1] Rollout Dashboards on MetabaseQA SIGNOFF

    Deployment Details

    Deploy the following build -

    • rollout-dashboard-cronjob:develop-2a8d6a44-3

    Integration Details

    Integration Scope

    NalJalSeva Rollout Dashboard is not directly integrated with any of the services except this scripts fetch the data from the MDMS service and NalJalSeva DB

    Configure the username, tenantId, and password of the user for which mdms service access is available in the environment-specific yaml file in DevOps. Refer to the example below -

    iFix-DevOps/mgramseva-qa.yaml at e471be940b88ccd8811b2dfb7a0e4187b0ec39cd · misdwss/iFix-DevOps

    Steps to run locally

    Follow the steps below to run this in the local environment.

    punjab-mgramseva/LOCALSETUP.md at master · misdwss/punjab-mgramseva

    Loading to Metabase

    The Python script inserts the data into the table “roll_out_dashboard“ in NalJalSevaDb for every run, it cleans the old data and creates new data.

    This table has to be loaded into the metabase by adding NalJalSeva DB to the metabase.

    Phone Number*

    r'^[0-9]+$'

    Password*

    r'^(?=.*?[A-Za-z])(?=.*?[0-9])(?=.*?[#?!@$%^&*-]).{6,}$'

    /user/oauth/token

    POST

    username: {} password:{} scope: read grant_type: password tenantId: {} userType: EMPLOYEE

    BuildTextField

    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/TextFieldBuilder.dart

    Text Field

    Button

    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/Button.dart

    Button

    Reset Password/ Update Password Screen
    Home Screen
    punjab-mgramseva/Login.dart at develop · egovernments/punjab-mgramseva

    Get Started With DIGIT

    Overview

    To enable any municipal service in a fresh environment and for the first time, we require a basic idea of what DIGIT does and the generic services required to set it up.

    DIGIT is an open-source, customizable platform that lends itself to extensibility. New modules can be built on top of the platform to suit new use-cases or existing modules can be modified or replaced. To enable this, in addition to deploying DIGIT, a CD/CI pipeline has to be set up. CD/CI pipelines enable the end users to automate & simplify the build/deploy process.

    Find more details on DIGIT and platform deployment here.

    Core Services

    DIGIT platform comprises several core services that serve as the platform backbone. Some of the key core services are listed below:

    Each microservice has a distinct function explained in the provided documentation links.

    Developers can activate specific municipal services easily once the platform and its terminologies are well understood.

    NOTE - NalJalSeva uses DIGIT core services and additional code is available in and .

    eChallan

    eChallan system enables employees to generate the challans for Adhoc services so that the payment can be recorded into the system along with service-specific details.

    It also enables citizens to make payments online based on challan numbers.

    Pre-requisites

    Before you proceed with the documentation, make sure the following pre-requisites are met -

    • Java 8

    Rate Dashboard

    Overview

    State Users logged into HRMS have the option to view the Rate Dashboard.

    Design & Workflows

    Here we can see the rate dashboard which shows the rate configured for each scheme.

    {
    
          "jobName": "monthly",
    
          "active": "true",
    
          "method": "POST",
    
          "url": "http://ws-calculator.mgramseva:8080/ws-calculator/waterCalculator/_jobscheduler/false",
    
          "payload": {
    
            "RequestInfo": "{DEFAULT_REQUESTINFO}"
    
          },
    
          "header": {
    
            "Content-Type": "application/json"
    
          }
    
        },
    
        {
    
          "jobName": "fortnightevening",
    
          "active": "true",
    
          "method": "POST",
    
          "url": "http://ws-services.mgramseva:8080/ws-services/wc/_schedulerpendingcollection",
    
          "payload": {
    
            "RequestInfo": "{DEFAULT_REQUESTINFO}"
    
          },
    
          "header": {
    
            "Content-Type": "application/json"
    
          }
    
        },
    
        {
    
          "jobName": "monthly",
    
          "active": "true",
    
          "method": "POST",
    
          "url": "http://echallan-services.mgramseva:8080/echallan-services/eChallan/v1/_schedulermonthsummary",
    
          "payload": {
    
            "RequestInfo": "{DEFAULT_REQUESTINFO}"
    
          },
    
          "header": {
    
            "Content-Type": "application/json"
    
          }
    
        },
    
        {
    
          "jobName": "fortnightevening",
    
          "active": "true",
    
          "method": "POST",
    
          "url": "http://echallan-services.mgramseva:8080/echallan-services/eChallan/v1/_schedulernewexpenditure",
    
          "payload": {
    
            "RequestInfo": "{DEFAULT_REQUESTINFO}"
    
          },
    
          "header": {
    
            "Content-Type": "application/json"
    
          }
    
        },
    
        {
    
          "jobName": "fortnightevening",
    
          "active": "true",
    
          "method": "POST",
    
          "url": "http://echallan-services.mgramseva:8080/echallan-services/eChallan/v1/_schedulermarkexpensebill",
    
          "payload": {
    
            "RequestInfo": "{DEFAULT_REQUESTINFO}"
    
          },
    
          "header": {
    
            "Content-Type": "application/json"
    
          }
    
        },
    
        {
    
          "jobName": "failedbulkdemand",
    
          "active": "true",
    
          "method": "POST",
    
          "url": "http://ws-calculator.mgramseva:8080/ws-calculator/waterCalculator/_jobscheduler/true",
    
          "payload": {
    
            "RequestInfo": "{DEFAULT_REQUESTINFO}"
    
          },
    
          "header": {
    
            "Content-Type": "application/json"
    
          }
    
        },
    
        {
    
          "jobName": "dailyevening",
    
          "active": "true",
    
          "method": "POST",
    
          "url": "http://ws-services.mgramseva:8080/ws-services/wc/_schedulerTodaysCollection",
    
          "payload": {
    
            "RequestInfo": "{DEFAULT_REQUESTINFO}"
    
          },
    
          "header": {
    
            "Content-Type": "application/json"
    
          }
    
        }
    
    curl --location --request POST 'http://localhost:8090/user/users/_createnovalidate'
    
    --header 'Content-Type: application/json'
    
    --data-raw '{
      "RequestInfo": {
        "api_id": "1",
        "ver": "1",
        "ts": null,
        "action": "create",
        "did": "",
        "key": "",
        "msg_id": "",
        "requester_id": "",
        "userInfo": {
          "userName": "XXYY",
          "name": "NAME",
          "gender": "male",
          "mobileNumber": "XXYY",
          "active": true,
          "type": "EMPLOYEE",
          "tenantId": "pb",
          "password": "eGov@123",
          "roles": [
            {
              "code": "SUPERUSER",
              "tenantId": "pb"
            }
          ]
        }
      },
      "User": {
        "userName": "CRONJOB",
        "name": "CRONJOB",
        "gender": "male",
        "mobileNumber": "XXXXXX",
        "active": true,
        "type": "SYSTEM",
        "tenantId": "pb",
        "password": "eGov@123",
        "roles": [
          {
            "code": "SYSTEM",
            "tenantId": "pb"
          }
        ]
      }
    }'
    PDF Service
  • Payment Service

  • MDMS Service

  • Indexer Service

  • Persister Service

  • ..among multiple others

  • Workflow Service
    Location Service
    User Service
    Access Control Service
    municipal-services
    business-services

    32

    Yes

    It is the IP address that has to be mapped to the domain name

    mgramseva-dwss.punjab.gov.in/
    Checklist
    Logo
  • The Kafka server is up and running

  • egov-persister service is running and has an eChallan persister config path added to it

  • PSQL server is running and a database is created to store eChallan data

  • Key Functionalities

    • Allow employees to capture service details for miscellaneous services and collect payment

    • Allow employees to update/cancel challan

    • Search, download, and print echallan / bill for miscellaneous service

    • Generate and view echallan / bill pdf for all miscellaneous and ad-hoc services

    • Send an SMS and an email bill notification to the citizen with a payment link and bill link

    Environment variables
    Description

    egov.user.event.notification.enabled

    This variable is to check the event Notification enabled or not.

    egov.challan.default.limit

    This variable is to get the default limit value

    egov.challan.max.limit

    This variable to check the max limit value.

    create.ws.workflow.name

    This variable will give the business service name while creating the workflow.

    notification.sms.enabled

    This variable is to check the SMS notifications are enabled or not.

    egov.localization.statelevel

    This variable is used to check the localizations are state level or not.

    Interaction Diagram

    Configuration Details

    Actions & Role Action Mapping

    Actions

    Role Action Mapping

    Roles available:

    Localization:

    Deployment Details

    1. Add MDMS configurations required for eChallan Service and calculator and restart the MDMS service.

    2. Deploy the latest version of eChallan Service and calculator.

    3. Add eChallan Service persister yaml path in persister configuration and restart persister service.

    4. Add role-action mapping for APIs.

    5. Add pdf configuration file for challan and bill.

    Integration Details

    Integration Scope

    The eChallan service is used to generate e-challans / bills for all miscellaneous/ad-hoc services which citizens avail from ULBs.

    Integration Benefits

    • Can perform service-specific business logic without impacting the other module.

    • Allows capturing the unique identifier of the entity for which the challan is generated.

    • In the future, if we decide to make the application accessible to citizens, it can be done effortlessly.

    • Workflow or service-specific workflow can be enabled at the challan service level at any time, without the need for any design changes.

    • Allow employees to update/cancel challan.

    Integration Steps

    1. To integrate, overwrite the host of the echallan-services module in the Helm chart.

    2. Add the echallan-services/eChallan/v1/_create as the create endpoint for creating eChallan in the system.

    3. Add the echallan-services/eChallan/v1/_search as the search endpoint. This method handles all requests to search existing records depending on different search criteria.

    4. Add echallan-services/eChallan/v1/_update as the update endpoint. This method is used to update fields in existing records or to update the status of applications based on workflow.

    5. /echallan-services/eChallan/v1/_expenseDashboard Is added in echallan-service to show the data of expenses in matrix format.

    6. /echallan-services/eChallan/v1/_chalanCollectionData it is added to get the main monthly dashboard data for the expense.

    Reference Docs

    Docs
    APIs

    (Note: All the APIs are in the same Postman collection therefore the same link is added in each row).

    Forgot Password

    Users are redirected to this screen once they click on the Forgot Password link on the home screen.

    OTP Request

    This feature allows users to request OTP by entering a valid (registered) mobile number.

    Follow the steps below to set a new password -

    • Click on the Forgot Password link visible on the login screen

    • Enter the registered mobile number

    The remaining steps are explained in the section.

    Files Path

    Primary Files:

    Field Validation

    API Details

    End Point
    Request Method
    Request Info

    Stack

    2 → Language Selection Screen. + Login Screen + ForgotPassword

    Pop → Login Screen Screen

    Widgets utilised from the Library

    Widgets
    File Path
    Description

    Reset Password

    Users are redirected to this screen once they click on the Continue button on the Forgot Password screen.

    Link - → {base url}/mgramseva/selectLanguage/login/forgotPassword/resetPassword

    User Interaction On Screen

    • Enter the OTP sent on the user’s 10-digit mobile number.

    • Set the new password for logging into the application.

    • Click on Change Password to apply new password credentials for the user.

    Password Hint Card

    This feature helps to provide the users with a clear indication of what the password should contain. Acceptable passwords must contain -

    • Minimum 6 digits

    • At least one special character ( !#$%^&...)

    • At least one letter

    • At least one number

    Files Path

    Primary Files:

    Field Validations

    Fields
    Validations

    API Details

    End Point
    Request Method
    Request Info

    Stack

    1 → Language Selection Screen. + Login Screen + Forgot Password + Reset Password.

    Pop → Forgot Password Screen.

    Widgets utilised from the Library

    Widgets
    File Path
    Description

    Configure Module Localisation

    Overview

    Localization is the process of adapting a software application, website, or content to different languages and regions, making it accessible and user-friendly for diverse audiences. It involves translating text, adapting graphics, and configuring settings to suit a specific locale's cultural and linguistic preferences.

    Search API For Localization In NalJalSeva

    To retrieve localization messages in NalJalSeva, use the Search API given below. This API allows you to search for messages based on parameters like locale, tenantId, and apiId. Here is an example using cURL:

    To search for messages in different languages and environments, you can customize the parameters such as locale (en_IN, hi_IN, pn_IN) and tenantId. Change the URL to search in any other environment. The current API is specific to the UAT environment.

    Upsert API For Localization In NalJalSeva

    The Upsert API allows users to update or insert new localization messages into NalJalSeva. This involves refreshing the authentication token and providing details like code, message, module, and locale. Here is an example using cURL:

    In this example, you can customize the "code," "message," "module," and "locale" parameters to specify the localization details you want to upsert. Make sure to update the authentication token for security purposes.

    Note: The provided APIs are for the UAT environment, and you may need to modify the URLs accordingly for other environments.

    [
       {
          "id": {{PLACEHOLDER1}},
          "name": "Expense Create",
          "url": "/echallan-services/eChallan/v1/_create",
          "parentModule": "",
          "displayName": "EChallan Create",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "echallan-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER2}},
          "name": "Expense Search",
          "url": "/echallan-services/eChallan/v1/_search",
          "parentModule": "",
          "displayName": "EChallan Create",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "echallan-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER3}},
          "name": "Expense Update",
          "url": "/echallan-services/eChallan/v1/_update",
          "parentModule": "",
          "displayName": "EChallan Create",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "echallan-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER4}},
          "name": "Vendor Create",
          "url": "/vedor/v1/_create",
          "parentModule": "",
          "displayName": "Vendor Create",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "vendor",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER5}},
          "name": "Vendor Search",
          "url": "/vendor/v1/_search",
          "parentModule": "",
          "displayName": "Vendor Create",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "vendor",
          "code": "null",
          "path": ""
        },
         {
          "id": 2007,
          "name": "Update Password",
          "url": "/user/password/_update",
          "parentModule": "",
          "displayName": "Password Update",
          "orderNumber": 4,
          "enabled": false,
          "serviceCode": "ADMIN",
          "code": "null",
          "path": ""
        },
    ]
    [
      {
          "rolecode": "EXPENSE_PROCESSING",
          "actionid": {{PLACEHOLDER1}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "EXPENSE_PROCESSING",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "DASHBOARD_VIEWER",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "EXPENSE_PROCESSING",
          "actionid": {{PLACEHOLDER3}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "SUPERUSER",
          "actionid": {{PLACEHOLDER4}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "EXPENSE_PROCESSING",
          "actionid": {{PLACEHOLDER4}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "EXPENSE_PROCESSING",
          "actionid": {{PLACEHOLDER5}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "SUPERUSER",
          "actionid": {{PLACEHOLDER5}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "SUPERUSER",
          "actionid": {{PLACEHOLDER6}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER6}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "COLLECTION_OPERATOR",
          "actionid": {{PLACEHOLDER6}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "BULK_DEMAND_PROCESSING",
          "actionid": {{PLACEHOLDER6}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "EXPENSE_PROCESSING",
          "actionid": {{PLACEHOLDER6}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "DASHBOARD_VIEWER",
          "actionid": {{PLACEHOLDER6}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "PROFILE_UPDATE",
          "actionid": {{PLACEHOLDER6}},
          "actioncode": "",
          "tenantId": "pb"
        },
    ]
    
    		{
          "code": "GP_ADMIN",
          "name": "GP Admin",
          "description": "Who has a access to ws-services"
        },
    		{
          "code": "COLLECTION_OPERATOR",
          "name": "Collection Operator",
          "description": "Who has a access to ws-services,demand, bill and payment"
        },
    		{
          "code": "BULK_DEMAND_PROCESSING",
          "name": "Bulk Demand Processing",
          "description": "Who has a access to bulk demand generation,raise bill, downloa bill and receipts"
        },
    		{
          "code": "EXPENSE_PROCESSING",
          "name": "Expense Processing",
          "description": "Who has a access to create and update expenses"
        },
    		{
          "code": "DASHBOARD_VIEWER",
          "name": "Dashbaord Viewer",
          "description": "Who has a access to dashboard of revenue and expenditure"
        }
    {
      "messages": [
            {
                "code": "echallan.cancel.sms",
                "message": "Challan No: <challanno> for <service> has been cancelled.",
                "module": "rainmaker-uc",
                "locale": "en_IN"
            },
            {
                "code": "echallan.create.sms",
                "message": "Challan No: <challanno> for <service> INR <amount> generated. Pay @ <Link> .",
                "module": "rainmaker-uc",
                "locale": "en_IN"
            },
            {
                "code": "echallan.update.sms",
                "message": "Challan No: <challanno> updated for <service>. Amount INR <amount>. Pay @ <Link> .",
                "module": "rainmaker-uc",
                "locale": "en_IN"
            }
      ]
    }

    egov.pending.collection.link

    variable for collection list screen link for notifications

    egov.monthly.summary.link

    variable for monthly summary screen link for notifications

    egov.new.Expenditure.link

    variable for new expenditure screen link

    egov.mark.paid.Expenditure.link

    variable for paid expenditure screen link

    egov.bilk.demand.failed.link

    variable for mnaul bulk demand generation screen link

    egov.today.collection.link

    variable for today’s collection screen link

    API Swagger Documentation
    echallan-services/eChallan/v1/_create
    echallan-services/eChallan/v1/_update
    echallan-services/eChallan/v1/_search
    echallan-services/eChallan/v1/_count
    Logo
    Logo
    Logo
    curl --location 'https://mgramseva-uat.psegs.in/localization/messages/v1/_search?locale=en_IN&tenantId=pb' \
    --header 'authority: mgramseva-dwss.punjab.gov.in' \
    --header 'accept: */*' \
    --header 'accept-language: en-GB,en;q=0.9' \
    --header 'content-type: application/json; charset=utf-8' \
    --header 'cookie: _ga=GA1.1.748766720.1676369982; _ga_DDHVQCKC6W=GS1.1.1676369981.1.0.1676369984.0.0.0' \
    --header 'origin: https://mgramseva-dwss.punjab.gov.in' \
    --header 'referer: https://mgramseva-dwss.punjab.gov.in/mgramseva/selectLanguage' \
    --header 'sec-ch-ua: "Not_A Brand";v="99", "Google Chrome";v="109", "Chromium";v="109"' \
    --header 'sec-ch-ua-mobile: ?1' \
    --header 'sec-ch-ua-platform: "Android"' \
    --header 'sec-fetch-dest: empty' \
    --header 'sec-fetch-mode: cors' \
    --header 'sec-fetch-site: same-origin' \
    --header 'user-agent: Mozilla/5.0 (Linux; Android 10; SM-G981B) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.162 Mobile Safari/537.36' \
    --data '{
        "apiId": "mgramseva",
        "ver": 1,
        "ts": "",
        "action": "_search",
        "did": 1,
        "key": "",
        "msgId": "20170310130900|en_IN",
        "authToken": "",
        "userInfo": null
    }'
    curl --location 'https://mgramseva-uat.psegs.in/localization/messages/v1/_upsert' \
    --header 'Content-Type: application/json' \
    --data '{
        "RequestInfo": {
            "apiId": "Mihy",
            "ver": "1.0",
            "ts": "",
            "action": "create",
            "did": "1",
            "key": "abcdkey",
            "msgId": "20170310130900",
            "requesterId": "",
            "authToken": "7d569ce1-4b5c-4f4c-be93-4af7265890f3"
        },
        "tenantId": "pb",
        "messages": [
             {
                "code": "CORE_DOWNLOAD",
                "message": "Download",
                "module": "mgramseva-common",
                "locale": "en_IN"
            }
        ]
    }'

    Fields

    Validation

    Phone Number*

    r'^[0-9]+$'

    user-otp/v1/_send

    POST

    "otp": { "mobileNumber": {}, "tenantId": {}, "type": "passwordreset", "userType": "Employee" }

    BuildTextField

    ​​punjab-mgramseva/TextFieldBuilder.dart at develop · egovernments/punjab-mgramseva​

    Text Field

    Button

    ​​punjab-mgramseva/Button.dart at develop · egovernments/punjab-mgramseva​

    Button

    Enter the OTP sent *

    r'^[0-9]+$' , 6 digit

    Enter a New Password*

    r'^(?=.*?[A-Za-z])(?=.*?[0-9])(?=.*?[#?!@$%^&*-]).{6,}$'

    Confirm New Password

    Match with New Password

    user/password/nologin/_update

    POST

    "otpReference": {}, "userName": {}, "newPassword": {}, "tenantId": {}, "type": “Employee”

    BuildTextField

    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/TextFieldBuilder.dart

    Text Field

    BottomButtonBar

    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/BottonButtonBar.dart

    Button

    PasswordHint

    https://github.com/egovernments/punjab-mgramseva/blob/develop/frontend/mgramseva/lib/widgets/PasswordHint.dart

    Password Hint Card

    Reset Password
    punjab-mgramseva/ForgotPassword.dart at develop · egovernments/punjab-mgramseva
    punjab-mgramseva/Resetpassword.dart at develop · egovernments/punjab-mgramseva

    Penalty Changes

    Water Connection Penalty changes are added to get the penalty amount after the due date. The due date is configurable and penalty enable and disable are also configurable. If we want to have the penalty we can enable or we can disable it through configuration.

    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 the water service persister configs path added to it

    • PSQL server is running and a database is created to store water connection/application data

    • The following services should be up and running:

      • egov-persister

      • egov-mdms

      • ws-services

    Key Functionalities

    • Calculate water charges and taxes based on the billing slab.

    • Calculate meter reading charge for water connection

    • Generate demand for penalty feature

    • Scheduler for generating the demand(for non-metered connection)

    Deployment Details

    1. Deploy the latest version of ws-service and ws-calculator

    2. Add water-persist.yml & water-meter.yml file in the config folder in git and add that path in persister. (The file path is to be added in the environment yaml file in a param called persist-yml-path )

    Configuration Details

    MDMS Configuration

    Billing service tax head configuration

    ws-calculator penalty configuration:

    Use case 1: Fixed percentage on outstanding without penalty

    Use case 2: Fixed percentage on the current month

    Use case 3: Fixed percentage on outstanding including penalty

    Note: All the above are applied to the running month only.

    Use case 4: Fixed percentage on outstanding applied for every month on the outstanding amount respectively (not implemented)

    Tech configuration

    Use case 1: "type": "Fixed", "subType": "outstandingWithoutPenalty"

    Use case 2: "type": "Fixed", "subType": "currentMonth",

    Use Case 3: "type": "Fixed", "subType": "outstanding", We have Total 4 types of penalty in the system:

    Fixed - Current month: This type of penalty is applied to the current month's amount based on the rate (%) given in the configuration.

    Fixed - outstanding: This is the penalty applied on the total outstanding amount including previously applied penalties based on the rate (%) given in the configuration.

    Fixed - outstandingWithoutPenalty: This is the penalty applied on the total outstanding amount excluding previously applied penalties based on the rate (%) given in the configuration.

    Flat - Current month: This type of penalty is applied to the current month's amount based on the amount given in the configuration.

    Flat - outstanding: This type of penalty is applied to the total pending amount till the current month's amount based on the amount given in the configuration.

    Curl to create:

    Technology

    Tools and technologies used to setup, build and deploy NalJalSeva stack

    DIGIT being an open-source platform, all the tools and tech stack used to build, deploy and operate DIGIT - are also open-sourced and community edition. The tools used to set up, develop and deploy the NalJalSeva stack are listed below with the specific versions used and short descriptions.

    Platform Tools
    Latest Version
    Used Version
    Description
    License Type
    ​

    ​​

    6.2.0

    5.4.1

    Create Employee

    Overview

    The Create Employee feature in the HRMS application enables users to add employee details.

    Design & Workflows

    State User Creation

    State user is created the very first time with the desired Role as STATE_ADMIN, HRMS_ADMIN, MDMS_ADMIN Using API of create Employee in Egov-hrms.

    Create Block Users

    Click on “Create Block user” and add the employee details.

    Field Name
    Type
    Mandatory Y/N
    Description

    Once created the Employee Creation Successful Screen is deployed it generates a unique Employee Code.

    The employee gets a message to log in with one-time login credentials.

    “Dear, You've been invited to mGramSeva Application of Assam. Please login using https://naljalseva.jjm.gov.in/uat/mgramseva/login. Username: Password:”

    Block users can log into HRMS and Create Other field Users, namely Revenue Collector, Chairmen or Secretary.

    Create Field Users

    Homepage of Block Users - Block users can select the scheme from the dropdown list and add field users to the selected scheme.

    Click on Create Employee to create the field Employee.

    By default, the selected scheme in the dropdown will be preselected in the jurisdiction details. This is the primary scheme meaning you cannot remove this scheme from the user once it is created Block User can add other schemes to the same Employee by clicking on Add Jurisdiction.

    Field Name
    Type
    Mandatory Y/N
    Description

    The below screen is displayed upon successful creation of user -

    A message will trigger to the employee with a one-time login credentials -

    “Dear , You've been invited to mGramSeva Application of Assam. Please login using https://naljalseva.jjm.gov.in/uat/mgramseva/login. Username: Password:”

    Login, Reset & Forgot Password

    Overview

    The login, reset and forgot password feature enables users to access the HRMS application.

    Design & Workflows

    On successful User/employee Creation, the users receive a link via SMS. Clicking on this link redirects the users to the login page of the HRMS app. The users can log in from this screen or even reset their password in case they are logging in for the first time.We also Provide Forget password option in this screen.

    Language Selection

    The link in the SMS redirects users to this screen which is the first screen which is the language selection screen. The user selects the preferred language and clicks on Continue. English and Assamese are the supported languages with English as the default language. Localization in the screens is displayed based on the language selected.

    User ID & Password Entry

    The user enters the User ID, which is the registered mobile number of the user, and the system-generated password. Clicking on the Continue button logs in the user.

    First Time Login

    The user is redirected to the password reset screen where they enter the OTP received on the registered mobile number. The next screen prompts the user to enter a new password and then confirm the same. This is similar to the first-time login screen. Clicking on Submit displays the acknowledgement screen. Clicking on the Continue to Login button on the acknowledgement screen takes the user to the login page.

    Subsequent Login

    The user is redirected to the home page of the application which displays the menu options based on the mapped user role

    State Admin

    Block Admin

    Upon selection of the scheme the user is mapped to -

    Forgot Password

    The Forgot Password link navigates the user to the password reset screen.

    Configure Master Data Management System

    NalJalSeva's Master Data Management System () is organized into several folders, each containing essential JSON files that define various aspects of the application's configuration. This documentation provides an overview of the key folders and their respective files, along with a description of the data contained within each file.

    Steps

    1.

    This folder contains the actions-test.json file, which defines various API endpoints along with their configurations.

    Load Consumers For NalJalSeva

    Overview

    This page provides step-by-step instructions for using a Python script to create consumers for NalJalSeva. Follow these guidelines to load consumer data into the system using the Python script provided.

    Steps

    Step 1: Prepare Excel Sheet

    Before running the script, ensure you have a properly formatted Excel sheet. The sheet should include the following columns:

    • Consumer Name (Mandatory, use "NA" if not available)

    • Gender (Male/Female)

    • Father Name (Mandatory, use "NA" if not available)

    • Mobile Number (Mandatory)

    • Old Connection Number

    • Property Type

    • Service Type (till now we have Non-metered only for data loading)

    • Ward (Always set to "Ward 1")

    • Meter Reading (If available, use the provided date; otherwise, default to "12/01/2022")

    • GPWSC Name

    • Arrears

    • Previous Reading ((if arrears and previous reading are not given, write '0')

    Ensure the format of the meter reading matches the provided sample format given in the Excel file below, as incorrect formatting may lead to loading failures.

    Step 2: Python Script Configuration

    Edit the Python script with the following details:

    • Set the host URL based on whether it's for production, QA, or UAT.

    • Provide the username and password corresponding to your host URL.

    • Specify the path where your Excel file is stored. It is recommended to store the Excel file in the same location as your Python script.

    Step 3: Running the Script

    Execute the Python script after configuring the host URL, username, password, and file path. The script will load data into mGramSeva based on the information provided in the Excel sheet.

    Step 4: Post-Execution Steps

    Do not open the Excel file until the script completes its task. After completion, open the Excel file to check the status. The status will indicate whether the operation was successful or if there was a failure. If there's a failure, refer to the reason for further investigation and resolution.

    6KBConsumers.xlsx

    13KBloadConsumer-uat.py

    Apache Kafka is an open-sourced and community distributed event streaming platform capable of handling trillions of events a day.

    ​Community License ​

    ​

    ​Zookeeper​

    6.2.0

    5.4.1

    ZooKeeper is an open-source Apache project that provides a centralized service for providing configuration information, naming, synchronization and group services over large clusters in distributed systems. When working with Apache Kafka, ZooKeeper is primarily used to track the status of nodes in the Kafka cluster and maintain a list of Kafka topics and messages.

    ​

    ​

    ​Zuul​

    ​2.3.0​

    2.2.2

    Zuul is an open-sourced edge service that proxies requests to multiple backing services. It provides a unified “front door” to your system, which allows a browser, mobile app, or other user interfaces to consume services from multiple hosts without managing cross-origin resource sharing (CORS) and authentication for each one.

    ​Apache License 2.0​

    ​

    ​Elasticsearch​

    ​8.0.0​

    6.6.2

    Elasticsearch is a distributed, free and open search and analytics engine for all types of data, including textual, numerical, geospatial, structured and unstructured.

    ​Elastic License 2.0​

    ​

    ​Kibana​

    ​8.0.0​

    6.6.2

    Kibana is a free and open frontend application that sits on top of the Elastic Stack, providing search and data visualization capabilities for data indexed in Elasticsearch.

    ​Elastic License 2.0​

    ​

    ​fluentbit​

    ​1.8.3​

    1.0.6

    Fluent Bit is an open-source and multi-platform Log Processor and Forwarder which allows you to collect data/logs from different sources, unify and send them to multiple destinations. It's fully compatible with Docker and Kubernetes environments.

    ​Apache License 2.​

    ​

    ​Postgresql​

    13.4

    9.6 and 10.6

    PostgreSQL is a powerful, open-source object-relational database system with over 30 years of active development that has earned it a strong reputation for reliability, feature robustness, and performance

    ​PostGres License​

    ​

    ​redis​

    ​6.2.5​

    3.2.6

    Redis is an open-source (BSD licensed), in-memory data structure store, used as a database, cache, and message broker. Redis provides data structures such as strings, hashes, lists, sets, sorted sets with range queries, bitmaps, hyper logs, geospatial indexes, and streams.

    ​BSD License​

    ​

    ​Jaeger​

    ​1.25.0​

    1.18

    Jaeger is open-source software for tracing transactions between distributed services. It's used for monitoring and troubleshooting complex microservices environments.

    ​Apache Lice​

    ​

    Dev Stack

    Latest Version

    ​

    ​

    Used Version

    ​

    Description

    License

    Type

    ​

    ​OpenJDK​

    JDK11

    8u212

    OpenJDK is completely open-source and can be used freely

    ​GPL-2​

    ​

    ​SpringBoot​

    2.6.0​

    2.2.6

    Spring Boot is an open-source micro-framework maintained by a company called Pivotal. It provides Java developers with a platform to get started with an auto configurable production-grade Spring application.

    ​Apache License 2.0​

    ​

    ​React​

    ​17.0.2​

    16.7.0

    React is one of Facebook's first open-source projects that is both under very active development and is also being used to ship code to everybody on facebook.com.

    ​MIT​

    ​

    ​Material-UI-React​

    ​

    16.8.0

    Material-UI CE (Community Edition) has been 100% open-source (MIT) since the very beginning, and always will be. Developers can ensure Material-UI is the right choice for their React applications through Material-UI's community maintenance strategy.

    ​MIT​

    ​

    ​NodeJS​

    14.0

    8.4.0

    Node. js is an open-source, cross-platform, JavaScript runtime environment. It executes JavaScript code outside of a browser.

    ​MIT​

    ​

    DevOps Stack

    ​

    ​

    ​

    Latest Version

    ​

    Used Version

    Description

    License Type

    ​

    Kubernetes

    1.22

    1.18.x

    Kubernetes, also known as K8s, is an open-source system for automating deployment, scaling, and management of containerized applications.

    ​Apache License 2.0​

    ​

    Docker

    19.03.14

    19.x

    Docker, a subset of the Moby project, is a software framework for building, running, and managing containers on servers and the cloud.

    ​Apache License 2.0​

    ​

    Helm

    3.6.3

    3.x.x

    Helm helps you manage Kubernetes applications — Helm Charts help you define, install, and upgrade even the most complex Kubernetes.

    ​Apache License 2.0​

    ​

    ​Terraform​

    1.1.0

    v0.14.10

    Terraform allows infrastructure to be expressed as code in a simple, human-readable language called HCL (HashiCorp Configuration Language).

    ​Mozilla Public License 2.0​

    ​

    Jenkins

    2.306

    2.289

    Jenkins – an open-source automation server that enables developers around the world to reliably build, test, and deploy their software.

    ​MIT​

    ​

    Go Lang

    1.16.7

    1.13.3

    Go is an open-source programming language that makes it easy to build simple, reliable, and efficient software.

    ​3-clause BSD + patent grant​

    ​

    Groovy

    ​3.0.8​

    3.0

    Apache Groovy is a powerful, optionally typed and dynamic language, with static-​typing and static compilation capabilities, for the Java platform aimed at improving developer productivity thanks to a concise, familiar and easy to learn syntax.

    ​Apache License 2.0​

    ​

    Python

    ​3.9.6​

    ​v3.9.6​

    Python software and documentation are licensed under the PSF License Agreement. Starting with Python 3.8.6,

    PSF

    ​

    ​Sops​

    ​v3.7.1​

    ​v3.7.1​

    sops is an editor of encrypted files that supports YAML, JSON, ENV, INI and BINARY formats and encrypts with AWS KMS, GCP KMS, Azure Key Vault, age, and PGP.

    ​Mozilla Public License 2.0​

    ​

    Ansible

    ​2.11.3​

    v2.9.23

    Ansible is an open-source community project sponsored by Red Hat, it's the simplest way to automate IT.

    GNU General Public License

    ​

    ​yaml​

    1.2

    1.2

    YAML is a human-readable data serialization standard that can be used in conjunction with all programming languages and is often used to write configuration files.

    ​License​

    ​

    Confluent Kafka
    billing-service

    id: Unique identifier for the API endpoint. Increase id with respect to id present in action-test.json file.

  • name: Name of the endpoint.

  • url: URL of the API endpoint.

  • Other things : As per your specific requirements.

  • 2. ACCESSCONTROL-ROLEACTIONS

    This folder contains the roleactions.json file, which associates roles with action IDs.

    • rolecode: Code representing the role

    • actionid: Action ID associated with the role, linking to entries in actions-test.json

    • actioncode: Additional code for the action if needed

    • tenantId: Tenant ID associated with the role

    3. ACCESSCONTROL-ROLES

    This folder contains the roles.json file, defining roles in the system.

    • code: Code representing the role

    • name: Name of the role

    • description: Description of the role

    4. BillingService

    This folder contains various JSON files related to billing services.

    4.1 BusinessService.json

    Defines business services, such as expenses like electricity bills and salaries.

    • businessService: Identifier for the business service.

    • code: Code representing the business service.

    • collectionModesNotAllowed: Collection modes not allowed for the service.

    • partPaymentAllowed: Indicates whether part payment is allowed.

    • isAdvanceAllowed: Indicates whether advance payment is allowed.

    • isVoucherCreationEnabled: Indicates whether voucher creation is enabled.

    • isActive: Indicates whether the service is active.

    • type: Type of the service.

    4.2 PaymentService.json

    This file, located in the billingservice folder provides configurations for payment services within the Billing Service module.

    • tenantId: The identifier for the tenant associated with the configuration.

    • moduleName: The name of the module, in this case, "BillingService."

    • PaymentService: An array containing configurations for different payment services.

    Payment Service Configuration:

    • businessService: Identifier for the business service.

    • code: Code representing the payment service.

    • collectionModesNotAllowed: Array specifying modes of payment not allowed for this service.

      • "DD": Demand Draft

      • "CHEQUE": Cheque

      • "CARD": Card

      • "OFFLINE_NEFT": Offline NEFT

      • "OFFLINE_RTGS": Offline RTGS

      • "POSTAL_ORDER": Postal Order

      • "ONLINE": Online

    • partPaymentAllowed: Indicates whether part payment is allowed for this service.

    • isAdvanceAllowed: Indicates whether advance payment is allowed for this service.

    • demandUpdateTime: Time interval (in milliseconds) for updating demands.

    • isVoucherCreationEnabled: Indicates whether voucher creation is enabled for this service.

    • billGineiURL: URL for generating bills using Bill Genie.

    • isBillAmendmentEnabled: Indicates whether bill amendment is enabled for this service.

    This configuration specifies the payment modes not allowed for the "ws-services-calculation" business service, whether part payment and advance payment are allowed, the demand update time, voucher creation status, Bill Genie URL, and bill amendment status.

    4.3 TaxHeadMaster.json

    This file is responsible for defining the various charges and taxes which are going to be configured in the application.

    4.4 TaxPeriod.json

    This file is used to define the number of financial years which are supported in each tax head.

    ws-services-masters

    This folder contains various JSON files related to ws-services-masters.

    ws-services-calculation This folder contains various JSON files related to ws-services-calculations.

    PropertyTax

    This folder contains various JSON files related to property tax.

    ExpenseType

    This folder contains expense type in JSON format.

    All (1 to 8 points) are state-level changes.

    Tenant Folder (City level changes for every city there is one folder in MDMS)

    For each tenant, there is a unique folder containing three subfolders, each with its specific configuration files.

    1. businessservice.json - Billing Service Configuration

    This file, located in the billing service folder, provides tenant-specific configurations for the Billing Service module. It is similar to the global BusinessService.json configuration but is specific to the tenant.

    2. boundary-data.json - Location Boundary Data Configuration

    This file, located in the egov-location folder contains boundary data specific to the tenant.

    Details of the structure and content of this file would be specific to the actual data in the system. Please refer to the specific boundary-data.json file for detailed information.

    3. WCBillingSlab.json - Water Connection Billing Slab Configuration

    This file, found in the ws-services-calculation folder defines billing slabs for water connection based on building type and connection type.

    • id: Unique identifier for the billing slab.

    • buildingType: Type of the building (e.g., RESIDENTIAL).

    • connectionType: Type of connection (e.g., Metered).

    • calculationAttribute: Attribute used for calculation (e.g., Water consumption).

    • minimumCharge: Minimum charge for the billing slab.

    • slabs: Array defining the billing slabs, including from, to, charge, and meterCharge.

    This configuration is used to determine rates for water consumption based on the specified billing slab criteria.

    There is a tenant folder in the MDMS which contains all tenants in tenants.json file.

    MDMS
    ACCESSCONTROL-ACTIONS-TEST
     {
          "category": "PENALTY",
          "service": "WS",
          "name": "Penalty",
          "code": "10201",
          "isDebit": false,
          "isActualDemand": true,
          "order": "3",
          "isRequired": false,
          "IsBillamend": true
        },
         {
          "category": "TAX",
          "service": "WS",
          "name": "Water adhoc penalty",
          "code": "WS_TIME_ADHOC_PENALTY",
          "isDebit": false,
          "isActualDemand": true,
          "order": "6",
          "isRequired": false,
          "IsBillamend": false
        },
    {
      "tenantId": "pb",
      "moduleName": "ws-services-calculation",
      "Penalty": [
        {
          "type": "FIXED",
          "subType": "currentMonth",
          "rate": 10,
          "amount":null,
          "minAmount": null,
          "applicableAfterDays": 10,
          "flatAmount": null,
          "fromFY": "2022-23",
          "startingDay": "1/01/2022"
        }
      ]
    }
    {
      "tenantId": "pb",
      "moduleName": "ws-services-calculation",
      "Penalty": [
        {
          "type": "FIXED",
          "subType": "outstanding",
          "rate": 10,
          "amount":null,
          "minAmount": null,
          "applicableAfterDays": 10,
          "flatAmount": null,
          "fromFY": "2022-23",
          "startingDay": "1/01/2022"
        }
      ]
    }
    {
      "tenantId": "pb",
      "moduleName": "ws-services-calculation",
      "Penalty": [
        {
          "type": "FIXED",
          "subType": "outstandingWithoutPenalty",
          "rate": 10,
          "amount":null,
          "minAmount": null,
          "applicableAfterDays": 10,
          "flatAmount": null,
          "fromFY": "2022-23",
          "startingDay": "1/01/2022"
        }
      ]
    {
      "tenantId": "pb",
      "moduleName": "ws-services-calculation",
      "Penalty": [
        {
          "type": "FLAT",
          "subType": "currentMonth",
          "rate": null,
          "amount": 15,
          "minAmount": null,
          "applicableAfterDays": 10,
          "flatAmount": null,
          "fromFY": "2022-23",
          "startingDay": "1/01/2022"
        }
      ]
    }
    {
      "tenantId": "pb",
      "moduleName": "ws-services-calculation",
      "Penalty": [
        {
          "type": "FLAT",
          "subType": "outstanding",
          "rate": null,
          "amount": 15,
          "minAmount": null,
          "applicableAfterDays": 10,
          "flatAmount": null,
          "fromFY": "2022-23",
          "startingDay": "1/01/2022"
        }
      ]
    }
    curl --location --request POST 'http://localhost:8090/ws-services/wc/_create' \
    --header 'authority: mgramseva-qa.egov.org.in' \
    --header 'accept: */*' \
    --header 'accept-language: en-GB,en-US;q=0.9,en;q=0.8' \
    --header 'content-type: application/json; charset=utf-8' \
    --header 'cookie: _ga_MY9HZBBBC8=GS1.1.1646915127.24.1.1646915152.0; _ga=GA1.1.1108799280.1643257024; _ga_8H6W5DYGX0=GS1.1.1655294682.124.0.1655294682.0' \
    --header 'origin: https://mgramseva-qa.egov.org.in' \
    --header 'referer: https://mgramseva-qa.egov.org.in/mgramseva/home/consumercreate' \
    --header 'sec-ch-ua: " Not A;Brand";v="99", "Chromium";v="102", "Google Chrome";v="102"' \
    --header 'sec-ch-ua-mobile: ?0' \
    --header 'sec-ch-ua-platform: "Linux"' \
    --header 'sec-fetch-dest: empty' \
    --header 'sec-fetch-mode: cors' \
    --header 'sec-fetch-site: same-origin' \
    --header 'user-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/102.0.5005.61 Safari/537.36' \
    --data-raw '{
        "RequestInfo": {
            "apiId": "mgramseva",
            "ver": 1,
            "ts": "",
            "action": "_create",
            "did": 1,
            "key": "",
            "msgId": "20170310130900|en_IN",
            "authToken": "cded20ed-d1f7-40ca-bd8e-978e319fdcea",
            "userInfo": {
                "id": 705,
                "uuid": "36b747f4-bd94-4be7-b0cc-e59af2ff970b",
                "userName": "8122091926",
                "name": "Vasanthi",
                "mobileNumber": "8122091926",
                "emailId": "[email protected]",
                "locale": null,
                "type": "EMPLOYEE",
                "roles": [
                    {
                        "name": "GP Admin",
                        "code": "GP_ADMIN",
                        "tenantId": "pb.lodhipur"
                    },
                    {
                        "name": "Bulk Demand Processing",
                        "code": "BULK_DEMAND_PROCESSING",
                        "tenantId": "pb.dabourupper"
                    },
                    {
                        "name": "Super User",
                        "code": "SUPERUSER",
                        "tenantId": "pb.dabourupper"
                    },
                    {
                        "name": "Profile update",
                        "code": "PROFILE_UPDATE",
                        "tenantId": "pb.lalpur"
                    },
                    {
                        "name": "Dashbaord Viewer",
                        "code": "DASHBOARD_VIEWER",
                        "tenantId": "pb.dabourupper"
                    },
                    {
                        "name": "Expense Processing",
                        "code": "EXPENSE_PROCESSING",
                        "tenantId": "pb.dabourupper"
                    },
                    {
                        "name": "Dashbaord Viewer",
                        "code": "DASHBOARD_VIEWER",
                        "tenantId": "pb.lodhipur"
                    },
                    {
                        "name": "Expense Processing",
                        "code": "EXPENSE_PROCESSING",
                        "tenantId": "pb.lodhipur"
                    },
                    {
                        "name": "GP Admin",
                        "code": "GP_ADMIN",
                        "tenantId": "pb.lalpur"
                    },
                    {
                        "name": "GP Admin",
                        "code": "GP_ADMIN",
                        "tenantId": "pb.dabourlower"
                    },
                    {
                        "name": "Profile update",
                        "code": "PROFILE_UPDATE",
                        "tenantId": "pb.massewal"
                    },
                    {
                        "name": "Bulk Demand Processing",
                        "code": "BULK_DEMAND_PROCESSING",
                        "tenantId": "pb.lodhipur"
                    },
                    {
                        "name": "Profile update",
                        "code": "PROFILE_UPDATE",
                        "tenantId": "pb.dabourupper"
                    },
                    {
                        "name": "Profile update",
                        "code": "PROFILE_UPDATE",
                        "tenantId": "pb.lodhipur"
                    },
                    {
                        "name": "Employee",
                        "code": "EMPLOYEE",
                        "tenantId": "pb.dabourupper"
                    },
                    {
                        "name": "Employee",
                        "code": "EMPLOYEE",
                        "tenantId": "pb.lodhipur"
                    },
                    {
                        "name": "Collection Operator",
                        "code": "COLLECTION_OPERATOR",
                        "tenantId": "pb.dabourlower"
                    },
                    {
                        "name": "Employee",
                        "code": "EMPLOYEE",
                        "tenantId": "pb.massewal"
                    },
                    {
                        "name": "Bulk Demand Processing",
                        "code": "BULK_DEMAND_PROCESSING",
                        "tenantId": "pb.dabourlower"
                    },
                    {
                        "name": "Bulk Demand Processing",
                        "code": "BULK_DEMAND_PROCESSING",
                        "tenantId": "pb.lalpur"
                    },
                    {
                        "name": "Collection Operator",
                        "code": "COLLECTION_OPERATOR",
                        "tenantId": "pb.lalpur"
                    },
                    {
                        "name": "Employee",
                        "code": "EMPLOYEE",
                        "tenantId": "pb.lalpur"
                    },
                    {
                        "name": "Dashbaord Viewer",
                        "code": "DASHBOARD_VIEWER",
                        "tenantId": "pb.lalpur"
                    },
                    {
                        "name": "Super User",
                        "code": "SUPERUSER",
                        "tenantId": "pb.dabourlower"
                    },
                    {
                        "name": "Dashbaord Viewer",
                        "code": "DASHBOARD_VIEWER",
                        "tenantId": "pb.massewal"
                    },
                    {
                        "name": "Expense Processing",
                        "code": "EXPENSE_PROCESSING",
                        "tenantId": "pb.dabourlower"
                    },
                    {
                        "name": "Expense Processing",
                        "code": "EXPENSE_PROCESSING",
                        "tenantId": "pb.massewal"
                    },
                    {
                        "name": "Dashbaord Viewer",
                        "code": "DASHBOARD_VIEWER",
                        "tenantId": "pb.dabourlower"
                    },
                    {
                        "name": "Bulk Demand Processing",
                        "code": "BULK_DEMAND_PROCESSING",
                        "tenantId": "pb.massewal"
                    },
                    {
                        "name": "GP Admin",
                        "code": "GP_ADMIN",
                        "tenantId": "pb.dabourupper"
                    },
                    {
                        "name": "Super User",
                        "code": "SUPERUSER",
                        "tenantId": "pb.lodhipur"
                    },
                    {
                        "name": "GP Admin",
                        "code": "GP_ADMIN",
                        "tenantId": "pb.massewal"
                    },
                    {
                        "name": "Expense Processing",
                        "code": "EXPENSE_PROCESSING",
                        "tenantId": "pb.lalpur"
                    },
                    {
                        "name": "Collection Operator",
                        "code": "COLLECTION_OPERATOR",
                        "tenantId": "pb.massewal"
                    },
                    {
                        "name": "Profile update",
                        "code": "PROFILE_UPDATE",
                        "tenantId": "pb.dabourlower"
                    },
                    {
                        "name": "Super User",
                        "code": "SUPERUSER",
                        "tenantId": "pb.massewal"
                    },
                    {
                        "name": "Employee",
                        "code": "EMPLOYEE",
                        "tenantId": "pb.dabourlower"
                    },
                    {
                        "name": "Super User",
                        "code": "SUPERUSER",
                        "tenantId": "pb.lalpur"
                    },
                    {
                        "name": "Collection Operator",
                        "code": "COLLECTION_OPERATOR",
                        "tenantId": "pb.dabourupper"
                    },
                    {
                        "name": "Collection Operator",
                        "code": "COLLECTION_OPERATOR",
                        "tenantId": "pb.lodhipur"
                    }
                ],
                "active": true,
                "tenantId": "pb",
                "permanentCity": null
            }
        },
        "WaterConnection": {
            "id": null,
            "connectionNo": null,
            "propertyId": "PB-PT-2022-06-15-1722",
            "applicationNo": null,
            "tenantId": "pb.lodhipur",
            "action": "SUBMIT",
            "status": null,
            "meterInstallationDate": 1651343400000,
            "documents": null,
            "proposedTaps": 1,
            "noOfTaps": 1,
            "paymentType":"arrears",
            "arrears": 112,
            "penalty":50,
            "connectionType": "Metered",
            "oldConnectionNo": "",
            "meterId": "121212",
            "propertyType": "RESIDENTIAL",
            "previousReadingDate": 1651343400000,
            "previousReading": 56,
            "proposedPipeSize": 10,
            "connectionHolders": [
                {
                    "id": null,
                    "uuid": null,
                    "userName": null,
                    "password": null,
                    "aadhaarNumber": null,
                    "permanentAddress": null,
                    "permanentCity": null,
                    "permanentPinCode": null,
                    "correspondenceCity": null,
                    "correspondencePinCode": null,
                    "correspondenceAddress": null,
                    "pwdExpiryDate": null,
                    "accountLocked": null,
                    "active": null,
                    "type": null,
                    "tenantId": null,
                    "altContactNumber": null,
                    "ownerInfoUuid": null,
                    "isPrimaryOwner": null,
                    "ownerShipPercentage": null,
                    "institutionId": null,
                    "designation": null,
                    "emailId": null,
                    "isCorrespondenceAddress": null,
                    "mobileNumber": "9182541372",
                    "fatherOrHusbandName": "Sravan",
                    "name": "Sravani",
                    "status": null,
                    "gender": "FEMALE",
                    "ownerType": "NONE",
                    "documents": null,
                    "roles": null
                }
            ],
            "additionalDetails": {
                "initialMeterReading": 56,
                "meterReading": 56,
                "locality": "WARD1",
                "category": null,
                "subCategory": null,
                "aadharNumber": null,
                "propertyType": "RESIDENTIAL",
                "street": "",
                "doorNo": "",
                "collectionAmount": null,
                "collectionPendingAmount": null,
                "action": null
            },
            "processInstance": {
                "action": "SUBMIT"
            }
        }
    }'
    {
      "id": 11,
      "name": "Employee Count",
      "url": "/egov-hrms/employees/_count",
      "parentModule": "egov-hrms",
      "displayName": "Employee Count",
      "orderNumber": 0,
      "enabled": false,
      "serviceCode": "egov-hrms",
      "code": "null",
      "path": ""
    }
    {
      "rolecode": "HRMS_ADMIN",
      "actionid": 11,
      "actioncode": "",
      "tenantId": "pb"
    }
    {
      "code": "ANONYMOUS",
      "name": "anonymous",
      "description": "anonymous user"
    }
    {
      "businessService": "EXPENSE.ELECTRICITY_BILL",
      "code": "EXPENSE.ELECTRICITY_BILL",
      "collectionModesNotAllowed": [
        "DD"
      ],
      "partPaymentAllowed": true,
      "isAdvanceAllowed": false,
      "isVoucherCreationEnabled": true,
      "isActive": true,
      "type": "Adhoc"
    }
    {
      "tenantId": "pb",
      "moduleName": "BillingService",
      "PaymentService": [
        {
          "businessService": "ws-services-calculation",
          "code": "WS",
          "collectionModesNotAllowed": [
            "DD",
            "CHEQUE",
            "CARD",
            "OFFLINE_NEFT",
            "OFFLINE_RTGS",
            "POSTAL_ORDER",
            "ONLINE"
          ],
          "partPaymentAllowed": true,
          "isAdvanceAllowed": true,
          "demandUpdateTime": 86400000,
          "isVoucherCreationEnabled": false,
          "billGineiURL": "egov-searcher/bill-genie/waterbills/_get",
          "isBillAmendmentEnabled": true
        }
      ]
    }
    {
      "id": "1",
      "buildingType": "RESIDENTIAL",
      "connectionType": "Metered",
      "calculationAttribute": "Water consumption",
      "minimumCharge": 100,
      "slabs": [
        {
          "from": 0,
          "to": 1000000,
          "charge": 2,
          "meterCharge": 50
        }
      ]
    }

    Y

    Employee mobile number

    Email ID

    Alpha Numeric

    Y

    Email ID of employee

    Block List

    Dropdown

    -

    List of Block Configured in MDMS tenant file

    Scheme List

    Dropdown

    Y

    List of Scheme under selected Block

    Y

    Employee mobile number

    Email ID

    Alpha Numeric

    Y

    Email ID of employee

    Type of User

    Dropdown

    Y

    Type of user (DWSS)

    Designation

    Dropdown

    Y

    List of designations for the selected user type

    Boundary

    Dropdown

    Y

    List of boundary/scheme mapped to the logged in block user

    Roles

    Dropdown

    Y

    List of available roles - 1. Revenue collector 2. Chairmen 3. Secretary

    Employee Name

    Text

    Y

    Name of the employee

    Gender

    Radio

    Y

    Male, Female, Transgender

    Mobile Number

    Employee Name

    Text

    Y

    Name of the employee

    Gender

    Radio

    Y

    Male, Female, Transgender

    Mobile Number

    Numeric

    Numeric

    Login To App

    Click on the preferred language button. The app functions and screens will be available in the selected language.

    Enter the registered mobile number. Enter the system-generated password. Click on the Continue button to log in.

    Forgot Password

    Click on the Forgot Password link on the login screen. This navigates the user to the password reset screen.

    Enter the registered Mobile Number and the OTP received on the mobile number.

    Enter the new password and confirm the new password. Click on the Change Password button to change the password. Follow the Password Hint details given on the screen to structure the password.

    This redirects the user to the home page containing the cards to relevant NalJalSeva functionalities available for the mapped user role.

    Logo
    Logo
    Logo

    User

    User service is responsible for user data management and providing functionality to log in and log out of the DIGIT system.

    Pre-requisites

    Before you proceed with the configuration, make sure the following pre-requisites are met -

    • Java 8

    • Kafka server is up and running

    • Encryption and MDMS services are running

    • PSQL server is running and the database

    • Redis is running

    Key Functionalities

    • Store, update and search user data

    • Provide authentication

    • Provide login and logout functionality to the NalJalSeva platform

    • Store user data PIIs in encrypted form

    Interaction Diagram

    Deployment Details

    1. Setup latest version of egov-enc-service and egov-mdms- service

    2. Deploy the latest version of the egov-user service

    3. Add Role-Action mapping for APIs

    Configuration Details

    The following properties in the application.properties file in user service are configurable.

    Property
    Value
    Description

    Integration Details

    Integration Scope

    User data management and functionality to log in and log out into the DIGIT system using OTP and password.

    Integration Benefits

    Providing the following functionality to citizen and employee-type users

    • Employee:

      • User registration

      • Search user

      • Update user details

    Integration Steps

    • To integrate, the host of egov-user should be overwritten in the helm chart.

    • Use /citizen/_create endpoint for creating users into the system. This endpoint requires the user to validate his mobile Number using OTP. The first OTP will be sent to his mobile number and then that OTP will be sent as otpReference in the request body

    • Use /v1/_search and /_search endpoints to search users in the system depending on various search parameters

    If an employee has a role with a state-level tenantId he can perform actions corresponding to that role across all tenants

    • Refresh Token: Whenever the /user/oauth/token is called to generate the access_token , along with the access_token one more token is generated called refresh_token . The refresh token is used to generate new access_token whenever the existing one expires. Till the time the refresh token is valid the user won’t have to log in even if his access_token get’s expired, as it will be generated using refresh_token. The validity time of the refresh token is configurable and can be configured using the property: refresh.token.validity.in.minutes

    Reference Docs

    Docs
    APIs

    (Note: All the APIs are in the same Postman collection therefore the same link is added in each row)

    citizen.login.password.otp.fixed.enabled

    false

    allow fixed otp for citizen

    otp.validation.register.mandatory

    true

    whether otp compulsory for registration

    access.token.validity.in.minutes

    10080

    validity time of access token

    refresh.token.validity.in.minutes

    20160

    validity time of refresh token

    default.password.expiry.in.days

    90

    expiry date of a password

    account.unlock.cool.down.period.minutes

    60

    unlock time

    max.invalid.login.attempts.period.minutes

    30

    window size for counting attempts for lock

    max.invalid.login.attempts

    5

    max failed login attempts before account is locked

    egov.state.level.tenant.id

    pb

    Forgot password

  • Change password

  • User role mapping (Single ULB to multiple roles)

  • Enable employees to login into the DIGIT system based on the password.

  • Citizen:

    • Create user

    • Update user

    • Search user

    • User registration using OTP

    • OTP based login

  • Use /profile/_update for updating the user profile. The user will be validated (either by OTP-based validation or password validation) when this API is called

  • /users/_createnovalidate and /users/_updatenovalidate are endpoints to create user data into the system without any validations (no OTP or password required). They should be strictly used only for creating/updating users internally and should not be exposed outside

  • Forgot password: In case the user forgets the password it can be reset by first calling /user-otp/v1/_send which will generate and send OTP on the employee’s mobile number, the password can then be updated using this OTP by calling the API /password/nologin/_update in which a new password along with the OTP has to be sent.

  • Use /password/_update to update the existing password by logging in. In the request body, both old and new password has to be sent. Details of the API can be found in the attached Swagger documentation

  • Use /user/oauth/token for generating tokens, /_logoutfor logout and /_details for getting user information from his token

  • Multi-Tenant User: The multi-tenant user functionality allows a user to perform actions across multiple ULBs. For example, an employee belonging to Amritsar can perform the role of Trade License Approver for Jalandhar by assigning a tenant-level role of tenantId pb.jalandhar to him. Following is an example of such a user:

  • egov.user.search.default.size

    10

    default search record number limit

    citizen.login.password.otp.enabled

    true

    whether citizen login otp based

    employee.login.password.otp.enabled

    false

    whether employee login otp based

    citizen.login.password.otp.fixed.value

    123456

    fixed otp for citizen

    Encryption Service

    /citizen/_create

    /users/_createnovalidate

    /_search

    /v1/_search

    /_details

    /users/_updatenovalidate

     {
            "id": 24226,
            "uuid": "11t0e02b-0145-4de2-bc42-c97b96264807",
            "userName": "xyz",
            "name": "abc",
            "mobileNumber": "9999999999",
            "emailId": "[email protected]",
            "locale": null,
            "type": "EMPLOYEE",
            "roles": [
                {
                    "name": "GP Admin",
                    "code": "GP_ADMIN",
                    "tenantId": "pb.massewal"
                },
                {
                    "name": "Collector",
                    "code": "COLLECTION_OPERATOR",
                    "tenantId": "pb.lodhipur"
                }
            ],
            "active": true,
            "tenantId": "pb"
        }
    /profile/_update
    /password/_update
    /password/nologin/_update
    /_logout
    /user/oauth/token

    User Events

    eGov-User-Events service provides a common point to manage all the events generated for the user in the system. Events include updates from multiple applications like PT, PGR, TL etc, events created by the employee addressing the citizen etc. This service provides APIs to create, update and search such events for the user.

    Pre-requisites

    Before you proceed with the documentation, make sure the following pre-requisites are met -

    • Java 8

    • The Kafka server is up and running

    • egov-persister service is running and has egov-user-events persister config path added to it

    • PSQL server is running and the database is created

    Key Functionalities

    • Provide a common platform to create, manage and notify events.

    • Events can be created either through an API call or by pushing records to the Kafka queue.

    Deployment Details

    1. Add mdms configs required for egov-user-events.

    2. Add Role-Action mapping for API’s.

    3. Deploy the latest version of egov-user-events

    4. Add egov-user-events file in config folder in git and add that path in persister. (The file path is to be added in environment yaml file in a param called persist-yml-path )

    Configuration Details

    Add master data in the MDMS service with the module name as mseva. Following is some sample master data for the service:

    Event Categories

    Event Types:

    Using /localization/messages/v1/_upsert , add localisation (templates) for notification messages to be sent. Following are the product notification templates:

    Copy

    Configurable Properties

    Following are the properties in the application.properties file in the egov-user-events service which is configurable.

    Property
    Value
    Remarks

    Entities:

    Events: Model to capture the events information. This object captures all the details of an event which is either being created or updated.

    EventDetails: Captures details of the event such as organiser, location, time etc are captured here. This is the child object to the Events object. This has significance only because the type of the event is ‘EVENTSONGROUND’.

    Action: This captures the user actions involved in the event. Say the pay now option, reopen option, download certificate option etc.

    Recipient: Every event is addressed to a crowd to which a notification of the same is sent. This model captures information about the recipients of the notification of this event or can also be framed as details of the address of the event.

    Event Type: Events are divided into multiple types as follows:

    1. BROADCAST - These are messages broadcasted addressing a group of people. For instance, “There’s road blockage near the bus stand, please use a different route”

    2. EVENTSONGROUND - These are events organised by a group of people addressing another group of people usually it is the ULB organising events for the citizens. It can be any activity like a 10K Marathon, Polio Drive, Property Tax collection drive etc.

    3. SYSTEMGENERATED - These events are generated by different systems on the egov platform like PT, TL, PGR etc addressing a group of people. For instance, “Dear Citizen, Your TL has been approved please proceed to Pay here <PAY_NOW>”

    These are configured in MDMS.

    Event Category: Events are categorised into the following:

    1. PUBLICHEALTH - Events related to public health.

    2. CULTURAL - Cultural events

    3. WARDCOMMITEEMEETING - Events for recurring meetings of the ward committee.

    These event categories are mapped to event types internally. The categories mentioned here are for EVENTSONGROUND type. These are configured in MDMS.

    How does it work?

    This service manages user events on the egov-platform, which means all the events about which the user (essentially citizen) has to be notified are stored and retrieved through this service. Events can be created either by an API call or by pushing records to the Kafka queue.

    Every event should contain information about the event type, event category, event name, description, recipient, actions, event details etc. Based on the type of the event, the list of mandatory fields varies. MDMS configurations required for this service to work can be found here:

    Once the event is sent for creation, the service validates all the required fields and assigns a recipient list to that event. An event can be addressed to a particular person, group of people, user type and also roles. Events like updates on the TL application are addressed to the owner of the TL only, Events like Polio Drive are addressed to the entire ULB, and Events like mass Bill generation are addressed only to those who are required to pay those bills. Similarly, a recipient list is generated based on the request and stored in the system.

    When an event is updated a counter event is generated, Counter events are of 2 types: Counter event on Delete and Counter event on Update. When an event in ACTIVE status is made INACTIVE or CANCELLED, a counter-event on delete is generated. When details of an event are updated irrespective of the status a counter event on update is generated. These counter-events are stored along with the actual event in the system. However, when a counter-event on delete is generated, its corresponding actual event is marked INACTIVE.

    One of the important aspects of this service is the search API. Searching for the events stored in the user-events system is different for different roles. When CITIZEN searches, all the events addressed to that citizen are retrieved, the events that contain corresponding counter-events are deduplicated and only the latest ACTIVE events are returned.

    We have a use-case where past events have to be marked INACTIVE, this applies to all the BROADCAST and EVENTSONGROUND types of events which are time-capped. If a BROADCAST event is active from 1/Jan to 10/Jan, it’ll be marked inactive post 10/Jan, after which the CITIZEN stops receiving any updates to that event. This changing of the status of the events is achieved by a lazy-update technique instead of a cron job. Due to this, the search API not only returns the events but also updates the status of events before returning them to the user based on whether it has expired.

    When an EMPLOYEE searches, all the EVENTSONGROUND posted in his particular ULB are returned by default irrespective of the status. He/She can perform actions on those events, which if active, are notified to the CITIZEN.

    An EMPLOYEE can search event based on the date the range, whatever the event created or last modified in that range, will appear in the search response. So, to get the details about an event in a particular date range pass the value in the fromDate and toDate fields of search criteria.

    fromDate and toDate fields accept epoch values only.

    And to get details about the Delete event, pass Status as CANCELLED and to get details about the Broadcast event pass eventType as BROADCAST.

    Review the code and descriptions of every method to understand the use cases and flow of logic in a better way.

    Integration Details

    Integration Scope

    eGov-user-events can be integrated with any organisation or system which wants to send the events generated for the user in the system

    Integration Benefits

    • Easy manages user events on the system, which means all the events about which the user (essentially citizen) has to be notified are stored and retrieved through this service.

    Integration Steps

    1. An employee can create events in the system using /egov-user-event/v1/events/_create endpoint

    2. Employees can update events in the system using /egov-user-event/v1/events/_update endpoint

    3. Events are searched in the system using /egov-user-event/v1/events/_search endpoint

    4. /egov-user-event/v1/events/notifications/_count API is used to fetch the count of total, unread, and read notifications.

    Reference Docs

    Doc Links

    API Docs

    API List

    APIs

    (Note: All the APIs are in the same Postman collection therefore same link is added in each row).

    kafka.topics.update.events

    update-user-events-async

    Topic to which the user-events consumer is subscribed. Producers willing to update events must push records to this topic

    mseva.notif.search.offset

    0

    Default pagination offset.

    mseva.notif.search.limit

    200

    Default pagination limit.

    OTHERS - Events that don’t belong to the types mentioned above.

    /egov-user-event/v1/events/lat/_update API is use to update the last-login-time of the user. We store the last login time of the user through this API thereby deciding which notifications have been read.

    kafka.topics.persister.save.events

    save-user-events

    This is the persister topic onto which user-events pushes records for persistence. This is for creating events.

    kafka.topics.persister.update.events

    update-user-events

    This is the persister topic onto which user-events pushes records for persistence. This is for updating events.

    kafka.topics.lat.details

    user-events-lat

    This is the persister topic onto which user-events pushes records for persistence. This is for storing last-access-time / last-login-time of the user.

    kafka.topics.save.events

    persist-user-events-async

    Topic to which the user-events consumer is subscribed. Producers willing to create events must push records to this topic.

    API Swagger Documentation

    /egov-user-event/v1/events/_create

    /egov-user-event/v1/events/_update

    /egov-user-event/v1/events/_search

    /egov-user-event/v1/events/notifications/_count

    /egov-user-event/v1/events/lat/_update

    https://github.com/egovernments/egov-mdms-data/tree/master/data/pb/mseva
    {
      "tenantId": "pb",
      "moduleName": "mseva",
      "EventCategories": [
        {
          "code": "PUBLICHEALTH",
          "eventType":"EVENTSONGROUND",
          "active": true
        },
        {
          "code": "CULTURAL",
          "eventType":"EVENTSONGROUND",
          "active": true
        },
        {
          "code": "WARDCOMMITTEEMEETING",
          "eventType":"EVENTSONGROUND",
          "active": true
        }
      ]
    }
    {
      "tenantId": "pb",
      "moduleName": "mseva",
      "EventTypes": [
        {
          "code": "BROADCAST",
          "active": true
        },
        {
          "code": "EVENTSONGROUND",
          "active": true
        },
        {
          "code": "SYSTEMGENERATED",
          "active": true
        },
        {
          "code": "OTHERS",
          "active": true
        }
      ]
    }
    {
      "messages": [
        {
          "code": "egovuserevents.notification.counterevent.ondelete",
          "message": "<event_name> has been deleted. Please remove from your calendar.",
          "module": "egov-user-events",
          "locale": "en_IN"
        },
        {
          "code": "egovuserevents.notification.counterevent.onupdate",
          "message": "Details of <event_name> have been updated.",
          "module": "egov-user-events",
          "locale": "en_IN"
        }
      ]
    }

    Property

    One of the major applications of the eGov stack is that it helps municipalities and citizens handle property tax payments and other related functions on the property such as assessments, mutation, and so on.

    Pre-requisites

    1. Prior knowledge of Java/J2EE

    2. Prior knowledge of Spring Boot

    3. Prior knowledge of REST APIs and related concepts like path parameters, headers, JSON etc.

    4. Prior knowledge of Git

    5. Prior knowledge of the demand-based systems

    6. The following services should be up and running:

      • user

      • MDMS

      • Persister

    Key Functionalities

    The Property Service provides multiple functionalities starting from serving as a central repository where property information is registered for reference of citizens and other municipality-provided services such as water connection and sewerage management. An assessment can be done to calculate and pay tax on the property. The different services provided by the property services are -

    • Property Registry

    • Assessment

    • Mutation

    • Bifurcation

    Registry Explanation

    • The registry flow helps the citizen/Employee to create a property in the system with the minimal information required.

    • Other workflows such as assessment or mutation can be triggered on the existing ACTIVE Property in the registry.

    • The property can be created, updated, cancelled, and searched followed by the process of Mutation and Assessment.

    • The same entry in the registry can be referred to by other modules for various business purposes (Water charges).

    Configuration Details

    MDMS CONFIG:

    Persister File Configuration

    The persister file configuration for property services can be found in the Config repo of eGov Git, which needs to be added in the persister service -

    Workflow Configurations

    Each flow in the property has a workflow associated with it, which can be controlled by following configurations.

    The Boolean field can enable/disable Workflow - the same field controls the update and creates the workflow.

    name
    value
    description

    Workflow configuration for a property is created if the source is from the WATER CONNECTION module.

    For the creation of property from the water and sewerage module, as per the use case mentioned in this , a different workflow configuration is used. For each use case, to identify which workflow to use can be identified from this .

    Use Case 1, which involves property creation from the Water and Sewerage module, necessitates a single-step workflow. In the MDMS file mentioned above, ensure that the businessService with PT.CREATEWITHWNS object is enabled, allowing the field to be set as true. Property creation from the Water and Sewerage module will feature a one-step workflow, for properties in an ACTIVE state.

    Fields in the above MDMS file:

    MDMS Fields
    Description

    Note: Each object mentioned above represents a specific use case outlined in this ticket. Therefore, only one object (use case) enable field should be set to true at any given time.

    Sample workflow config for use case 1 where property creation is from water and sewerage module with one-step workflow.

    Sample workflow config - (The same PT.CREATE can be used for update workflow also since both involve the same functionality)

    PT.LEGACY workflow config

    Notifications:

    To enable or disable notifications notif.sms.enabled=true

    #notif urls - makes use of the UI app host in notification service egov.notif.commonpay = citizen/egov-common/pay?consumerCode={CONSUMERCODE}&tenantId={TENANTID} egov.notif.view.property = citizen/property-tax/my-properties/property/{PROPERTYID}/{TENANTID} egov.notif.view.mutation = citizen/pt-mutation/search-preview?applicationNumber={APPID}&tenantId={TENANTID}

    The current localization messages for notification -

    Configs in App.props

    name
    value

    Integration Details

    Integration Scope

    Property service can be integrated with any organization or system that wants to maintain a record of the property and collect taxes with ease.

    Integration Benefits

    • Easy to create and simple process of self-assessment to avoid the hassle.

    • Helps maintain property data which can be used in the integration of other essential services like asset management, water connection and so on.

    • provides additional functionalities like mutation and assessment of properties.

    Integration Steps

    1. Customers can create a property using the /property/_create

    2. Search the property using /property/_searchendpoint

    3. /property/_update endpoint to update the property demand as needed.

    4. Mutation can be carried out with the help of /property/_update itself, no extra API is required.

    Reference Docs

    Doc Links

    Title
    Link

    API LIST

    Title
    Link

    Water Calculator

    Water Calculator Service is used to create meter readings, search meter readings, update existing meter readings, calculate water charges, generate demand, notify ULB officials using SMS & email on-demand generation and estimation of water charges (one-time cost) which involves costs like road-cutting charge, form fee, scrutiny fee, etc.

    Pre-requisites

    Before you proceed with the documentation, make sure the following pre-requisites are met -

    1. Java 8

    2. The Kafka server is up and running

    3. egov-persister service is running and has the water service persister configs path added to it

    4. PSQL server is running and a database is created to store water connection/application data

    5. The following services should be up and running:

      • egov-persister

      • egov-mdms

      • ws-services

    Key Functionalities

    • Calculate water charges and taxes based on the billing slab

    • Calculate meter reading charge for water connection

    • Generate demand

    • Scheduler for generating the demand (for non-metered connection)

    Environment variables
    Description

    Deployment Details

    1. Deploy the latest version of ws-service and ws-calculator

    2. Add the water-persist.yml and water-meter.yml files to the config folder in git. Update the environment YAML file by adding a parameter called persist-yml-path with the path to these files.

    Configuration Details

    MDMS Configuration

    Master Config:

    Billing Slabs:

    Criteria -

    1. connection type

    2. building type

    3. calculation attribute

    4. property usage type

    The above combination is used to define the billing slab. Billing Slab is defined in MDMS under the ws-services-calculation folder with the . Find below a sample slab.

    The calculation applies the specified slab based on the water connection criteria.

    Estimation:

    Water charge and tax

    The water charge is based on the billing slab, and the water application charge will be based on the slab and tax based on the master configuration.

    Actions & Role Action Mapping

    Actions

    Role Action Mapping

    Add New BillingSlab/RateMaster

    The charge for the given connection for a given billing cycle will be defined/identified by the system with the help of the CalculationAtrribute MDMS and WCBillngSlab MDMS.

    CalcualtionAttribute helps to identify the type of calculation for the given ConnectionType below MDMS of

    1. Metered Connection water consumption is the attribute used for the calculation of charge for the billing cycle i.e Based on the units consumed for a given billing cycle for a given connection would identify the actual charge from the WCBIllingSlab MDMS based on the propertyType, calcautionAttribute derived for a connection and ConnectionType.

    2. Non-Metered Connection Flat is the attribute used for the calculation of the charge for a given billing cycle, i.e. for a Non-Metered connection, there would be a flat charge for the given billing cycle. The amount can be derived from the WCBillingSlab MDMS based on the propertyType, calcautionAttribute derived for a connection and ConnectionType.

    Demand Generation

    Once water is sent to the calculator, its tax estimates are calculated. Using these tax head estimates, demand details are created. For every tax head, the estimated demand generates a corresponding demand detail.

    When the _calculate API is called, demand is first searched based on the connection number or application number and the demand period. If demand already exists, it is updated with the new information. Otherwise, a new demand is generated for the financial year period.

    During an update, if the tax head estimates change, the difference in amount for that tax head is added as a new demand detail. For example, if the initial demand has one demand detail with WATER_CHARGE equal to 120.

    After updating if the WATER_CHARGE increases to 150 we add one more demand detail to account for the increased amount. The demand detail will be updated to:

    Round-off in the bill is based on the total amount, ensuring that the payable amount is a whole number. Each WS_ROUNDOFF in the demand detail can be greater than 0.5, but the sum of all WS_ROUNDOFF values is always less than 0.5.

    Demand Generation Scheduler (For Non-metered Connection)

    Description

    To generate demand for non-metered connections, we have a feature for batch demand generation. The scheduler is responsible for generating demand based on the tenant.

    • The scheduler can be triggered using the scheduler API, scheduled as a cron job, or configured in Kubectl to hit the scheduler based on the configuration.

    • After the scheduler is triggered, we can search for the list of tenants (cities) in the database.

    • After obtaining the list of tenants, iterate through the list and generate the demand for specific tenants.

    • Load the consumer codes for the tenant and push the calculation criteria to Kafka. The calculation criteria contain minimal information, including the consumer code and one boolean variable.

    Use cases

    If the same job triggers multiple times what will happen?

    If the same job triggers multiple times the system processes it again as mentioned above but at the demand level, it checks the demand based on consumer code and billing period. In case the demand already exists then it updates the demand or else creates the demand.

    Are we maintaining success or failure status anywhere?

    Currently, we are maintaining the status of failed records in Kafka.

    Configuration

    We need to configure the batch size for Kafka consumers. This configuration determines how much data is processed at a time.

    Integration Details

    Integration Scope

    The ws-calculator is integrated with ws-service. ws-services internally invoke the ws-calculator service to calculate and generate demand for the charges.

    Integration Benefits

    WS calculator application is used to calculate the water application one-time fees and meter reading charges based on the different billing slabs. That's why the calculation and demand generation logic is separated from the WS service. So in future, if calculation logic requires modification the changes can be carried out for each implementation without modifying the WS service.

    Integration Steps

    1. Once the water connection is activated for the metered connection, the employee can add meter reading details using the API - /ws-calculator/meterConnection/_create. This generates the demand. The scheduler APIs should be called periodically for non-metered connections to generate the demand.

    2. For the metered connection service, the /meterConnection/_search API is used to get the previous meter reading,

    3. To generate the demand for metered or non-metered water connection /waterCalculator/_calculate API is used.

    4. Users can pay partial/full/advance amounts for the metered or non-metered connection bill. The billing service would call back /waterCalculator/_updateDemandAPI to update the demand-generated details in such cases.

    Reference Docs

    Docs
    APIs

    (Note: All the APIs are in the same Postman collection therefore the same link is added in each row).

    Location
  • Localization

  • Id-Gen

  • Billing-service

  • URL-shortener

  • Consolidation

    Localization

    Id-Gen service

    is.workflow.enabled

    true/false

    enable disbale workflow

    property.workflow.name

    PT.CREATE

    the name should match the config name in the workflow businessservice JSON

    property.legacy.entry.workflow.name

    PT.LEGACY

    property.update.workflow.name

    PT.UPDATE

    businessService

    Name of workflow config

    initialAction

    Indicate the start(initial) action of the particular workflow mention in businessService.

    inWorkflowStatusAllowed

    This field indicate whether the property with application status as “inWorkflow” can be use with water and sewerage connection creation. If this field is true then for that particular use case, the property with “inWorkflow” status can be use with water and sewerage connection creation and vice versa

    enable

    If this filed is set as true, then the other fields associate with the particular object is use for property creation.

    egov.idgen.ack.format

    PB-AC-[cy:yyyy-MM-dd]-[SEQ_EG_PT_ACK]

    egov.idgen.mutation.format

    PB-MT-[CITY]-[SEQ_EG_PT_MUTATION]

    egov.idgen.assm.format

    PB-AS-[cy:yyyy-MM-dd]-[SEQ_EG_PT_ASSM]

    egov.idgen.ptid.format

    PB-PT-[cy:yyyy-MM-dd]-[SEQ_EG_PT_PTID]

    citizen.allowed.search.params

    accountId,ids,propertyDetailids,mobileNumber,oldpropertyids

    employee.allowed.search.params

    accountId,ids,propertyDetailids,mobileNumber,oldpropertyids

    USER Service

    https://digit-discuss.atlassian.net/wiki/spaces/DD/pages/669450371

    url-shortening

    https://digit-discuss.atlassian.net/wiki/spaces/DD/pages/896892936

    MDMS

    https://digit-discuss.atlassian.net/wiki/spaces/DD/pages/723189807

    Billing-service

    https://digit-discuss.atlassian.net/wiki/spaces/DD/pages/1620672528

    Location

    https://digit-discuss.atlassian.net/wiki/spaces/DD/pages/664338482

    Workflow

    https://digit-discuss.atlassian.net/wiki/spaces/DD/pages/664174657

    /Property/_create

    https://www.getpostman.com/collections/02d01e7b46c79c140863

    /Property/_update

    https://www.getpostman.com/collections/02d01e7b46c79c140863

    /property/_search

    https://www.getpostman.com/collections/02d01e7b46c79c140863

    https://github.com/egovernments/egov-mdms-data/tree/DEV/data/pb/PropertyTax
    property-services-registry.yml
    ticket
    mdms file

    Persister

    billing-service

    After pushing the data into Kafka, the system consumes the records based on the batch configuration. For example, if the batch configuration is set to 50, the system will consume 50 calculation criteria at a time.

  • After consuming the records (calculation criteria), the system processes the batch to generate the demand. If the batch processing is successful, the processed consumer codes are logged.

  • If some records fail in the batch, the system pushes the batch into the dead letter batch topic. From there, the batch is processed one record at a time.

  • If the record is successful, the system logs the consumer code. If the record fails, the data is pushed into a dead-letter single topic.

  • Dead letter single topic contains information about failure records in Kafka.

  • /waterCalculator/_jobscheduler API is used to generate demand for non-metered connections. This API can be called periodically.

  • notification.sms.enabled

    This variable is to check the SMS notifications are enabled or not.

    notification.email.enabled

    This variable is to check the email notifications are enabled or not.

    download.bill.link.path

    This variable is for download bill reciept path

    egov.demand.gp.user.link

    This variable is to get the common link to the home page

    API Swagger Contract

    /ws-calculator/meterConnection/_create

    Water Service Document

    /ws-calculator/meterConnection/_search

    /waterCalculator/_estimate

    /waterCalculator/_calculate

    /waterCalculator/_updateDemand

    /waterCalculator/_jobscheduler

    WCBillingSlab
    {
     "tenantId": "pb",
     "moduleName": "PropertyTax",
     "PTWorkflow":[
         {
             "businessService":"PT.CREATEWITHWNS",
             "initialAction":"OPEN",
             "inWorkflowStatusAllowed":false,
             "enable":false
         },
         {
          "businessService":"PT.CREATE",
          "initialAction":"open",
          "inWorkflowStatusAllowed":true,
          "enable":true
      }
         
     ]
    }
    {
        "BusinessServices": [
          {
            "tenantId": "pb",
            "businessService": "PT.CREATEWITHWNS",
            "business": "PT",
            "businessServiceSla": null,
            "states": [
              {
                "sla": null,
                "state": null,
                "applicationStatus": "INWORKFLOW",
                "docUploadRequired": false,
                "isStartState": true,
                "isTerminateState": false,
                "isStateUpdatable": false,
                "actions": [
                  {
                    "action": "OPEN",
                    "nextState": "INITIATED",
                    "roles": [
                      "CITIZEN",
                      "WS_CEMP",
                      "SW_CEMP"
                    ]
                  }
                ]
              },
              {
                "sla": null,
                "state": "INITIATED",
                "applicationStatus": "INWORKFLOW",
                "docUploadRequired": false,
                "isStartState": true,
                "isTerminateState": false,
                "isStateUpdatable": true,
                "actions": [
                  {
                    "action": "SUBMIT",
                    "nextState": "APPROVED",
                    "roles": [
                      "EMPLOYEE",
                      "CITIZEN",
                      "SW_CEMP",
                      "WS_CEMP"
                    ]
                  },
                  {
                    "action": "BACK",
                    "nextState": "INWORKFLOW",
                    "roles": [
                      "EMPLOYEE",
                      "CITIZEN",
                      "SW_CEMP",
                      "WS_CEMP"
                    ]
                  }
                ]
              },
              {
                "sla": null,
                "state": "INWORKFLOW",
                "applicationStatus": "INWORKFLOW",
                "docUploadRequired": false,
                "isStartState": true,
                "isTerminateState": false,
                "isStateUpdatable": true,
                "actions": [
                  {
                    "action": "SUBMIT",
                    "nextState": "APPROVED",
                    "roles": [
                      "EMPLOYEE",
                      "CITIZEN",
                      "SW_CEMP",
                      "WS_CEMP"
                    ]
                  }
                ]
              },
              {
                "sla": null,
                "state": "APPROVED",
                "applicationStatus": "ACTIVE",
                "docUploadRequired": false,
                "isStartState": false,
                "isTerminateState": true,
                "isStateUpdatable": false,
                "actions": null
              }
            ]
          }
        ]
      }
     {
      "RequestInfo": {
        "apiId": "Rainmaker",
        "action": "",
        "did": 1,
        "key": "",
        "msgId": "20170310130900|en_IN",
        "requesterId": "",
        "ts": 1513579888683,
        "ver": ".01",
        "authToken": "b39181b1-5c6b-484a-b825-6be2f62012b8"
      },
     "BusinessServices": [
      {
        "tenantId": "pb",
        "businessService": "PT.CREATE",
        "business": "PT",
        "businessServiceSla": null,
        "states": [
            {
                "tenantId": "pb",
                "sla": null,
                "state": null,
                "applicationStatus": "INWORKFLOW",
                "docUploadRequired": false,
                "isStartState": true,
                "isTerminateState": false,
                "actions": [
                    {
                        "tenantId": "pb",
                        "action": "OPEN",
                        "nextState": "OPEN",
                        "roles": [
                            "CITIZEN",
                            "EMPLOYEE"
                        ]
                    }
                ]
            },
            {
                "tenantId": "pb",
                "sla": null,
                "state": "OPEN",
                "applicationStatus": "INWORKFLOW",
                "docUploadRequired": false,
                "isStartState": true,
                "isTerminateState": false,
                "actions": [
                    {
                        "tenantId": "pb",
                        "action": "VERIFY",
                        "nextState": "DOCVERIFIED",
                        "roles": [
                            "PT_DOC_VERIFIER"
                        ]
                    },
                    {
                      "tenantId": "pb",
                      "action": "REJECT",
                      "nextState": "REJECTED",
                      "roles": [
                          "PT_DOC_VERIFIER"
                      ]
                  },
                  {
                    "tenantId": "pb",
                    "action": "SENDBACKTOCITIZEN",
                    "nextState": "CORRECTIONPENDING",
                    "roles": [
                        "PT_DOC_VERIFIER"
                    ]
                }
                ]
            },
            {
                "tenantId": "pb",
                "sla": null,
                "state": "DOCVERIFIED",
                "applicationStatus": "INWORKFLOW",
                "docUploadRequired": false,
                "isStartState": false,
                "isTerminateState": false,
                "actions": [
                    {
                        "tenantId": "pb",
                        "action": "FORWARD",
                        "nextState": "FIELDVERIFIED",
                        "roles": [
                            "PT_FIELD_INSPECTOR"
                        ]
                    }
                ]
            },
            {
                "tenantId": "pb",
                "sla": null,
                "state": "FIELDVERIFIED",
                "applicationStatus": "INWORKFLOW",
                "docUploadRequired": false,
                "isStartState": false,
                "isTerminateState": false,
                "actions": [
                    {
                        "tenantId": "pb",
                        "action": "APPROVE",
                        "nextState": "APPROVED",
                        "roles": [
                            "PT_APPROVER"
                        ]
                    },
                    {
                        "tenantId": "pb",
                        "action": "REJECT",
                        "nextState": "REJECTED",
                        "roles": [
                            "PT_APPROVER"
                        ]
                    }
                ]
            },
            {
                "tenantId": "pb",
                "sla": null,
                "state": "REJECTED",
                "applicationStatus": "INACTIVE",
                "docUploadRequired": false,
                "isStartState": false,
                "isTerminateState": true,
                "actions": null
            },
            {
                "tenantId": "pb",
                "sla": null,
                "state": "APPROVED",
                "applicationStatus": "ACTIVE",
                "docUploadRequired": false,
                "isStartState": false,
                "isTerminateState": true,
                "actions": null
            },
            {
              "tenantId": "pb",
              "sla": null,
              "state": "CORRECTIONPENDING",
              "applicationStatus": "INWORKFLOW",
              "docUploadRequired": false,
              "isStartState": false,
              "isTerminateState": false,
              "isStateUpdatable": true,
              "actions": [
                  {
                      "tenantId": "pb",
                      "action": "REOPEN",
                      "nextState": "OPEN",
                      "roles": [
                        "CITIZEN",
                        "PT_CEMP"
                      ]
                  },
                  {
                      "tenantId": "pb",
                      "action": "REJECT",
                      "nextState": "REJECTED",
                      "roles": [
                        "CITIZEN",
                        "PT_CEMP"
                      ]
                  }
              ]
          }
        ]
    }
      ]
    }	
    {
        "RequestInfo": {
          "apiId": "Rainmaker",
          "action": "",
          "did": 1,
          "key": "",
          "msgId": "20170310130900|en_IN",
          "requesterId": "",
          "ts": 1513579888683,
          "ver": ".01",
          "authToken": "{{authToken_amritsar}}"
        },
        "BusinessServices": [
          {
            "tenantId": "pb",
            "businessService": "PT.LEGACY",
            "business": "PT",
            "businessServiceSla": null,
            "states": [
              {
                "tenantId": "pb",
                "sla": null,
                "state": null,
                "applicationStatus": "INWORKFLOW",
                "docUploadRequired": false,
                "isStartState": true,
                "isTerminateState": false,
                "actions": [
                  {
                    "tenantId": "pb",
                    "action": "OPEN",
                    "nextState": "APPROVALPENDING",
                    "roles": [
                      "CITIZEN",
                      "EMPLOYEE"
                    ]
                  }
                ]
              },
              {
                "tenantId": "pb",
                "sla": null,
                "state": "APPROVALPENDING",
                "applicationStatus": "INWORKFLOW",
                "docUploadRequired": false,
                "isStartState": true,
                "isTerminateState": false,
                "actions": [
                  {
                    "tenantId": "pb",
                    "action": "APPROVE",
                    "nextState": "APPROVED",
                    "roles": [
                      "EMPLOYEE"
                    ]
                  },
                  {
                    "tenantId": "pb",
                    "action": "REJECT",
                    "nextState": "REJECTED",
                    "roles": [
                      "EMPLOYEE"
                    ]
                  }
                ]
              },
              {
                "tenantId": "pb",
                "sla": null,
                "state": "REJECTED",
                "applicationStatus": "INACTIVE",
                "docUploadRequired": false,
                "isStartState": false,
                "isTerminateState": true,
                "actions": null
              },
              {
                "tenantId": "pb",
                "sla": null,
                "state": "APPROVED",
                "applicationStatus": "INACTIVE",
                "docUploadRequired": false,
                "isStartState": false,
                "isTerminateState": true,
                "actions": null
              }
            ]
          }
        ]
      }
    [
            {
                "code": "PT_NOTIF_WF_STATE_LOCALE_OPEN",
                "message": "Open",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_STATE_LOCALE_DOCVERIFIED",
                "message": "Document Verified",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_STATE_LOCALE_FIELDVERIFIED",
                "message": "Field verified",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_STATE_LOCALE_APPROVED",
                "message": "Approved",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_STATE_LOCALE_REJECTED",
                "message": "Rejected",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_STATE_LOCALE_PAID",
                "message": "Paid",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_MT_OPEN",
                "message": "Dear {OWNER_NAME}, Your application to edit ownership details of property ID {PROPERTYID} has been submitted successfully. Your application no. for future reference is {APPID}. You can track your application on the link given below - {MTURL} Thank you",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_MT_STATE_CHANGE",
                "message": "Dear {OWNER_NAME}, Status for your application no. {APPID} for property {PROPERTYID} to edit ownership has been changed to {STATUS}. You can track your application on the link given below - {MTURL} Thank you",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_MT_PAYMENT_PENDING",
                "message": "Dear {OWNER_NAME}, Payment is pending for your application no. {APPID} for property ID {PROPERTYID} to edit ownership. You can pay your mutation fee on the below link - {PAYLINK} or visit your ULB to pay your dues. Thank you",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_MT_PAID",
                "message": "Dear {OWNER_NAME}, You’ve successfully paid mutation fee - INR {AMOUNT} for application no. {APPID} for property ID {PROPERTYID}. You can download your receipt on the below link - {MTURL} Thank you ",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_MT_APPROVED",
                "message": "Dear {OWNER_NAME}, Your property ownership has been changed as per the application no. {APPID} for property {PROPERTYID}. You can download your mutation certificate on the below link - {MTURL} Thank you",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_MT_NONE",
                "message": "Dear {OWNER_NAME}, Your property with property-id {PROPERTYID} has been mutated. You can view your property on the link given below - {MTURL} Thank you",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_OPEN",
                "message": "Dear {OWNER_NAME}, Your application to {updated/created} property with Id {PROPERTYID} has been submitted successfully. Your application no. for future reference is {APPID}. You can track your application on the link given below - {PTURL} Thank you",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_STATUS_CHANGE",
                "message": "Dear {OWNER_NAME}, Status for your application no. {APPID} for property {PROPERTYID} to {updated/created} property has been changed to {STATUS}. You can track your application on the link given below - {PTURL} Thank you",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_APPROVED",
                "message": "Dear {OWNER_NAME}, Your property has been {updated/created} as per the application no. {APPID} for property {PROPERTYID}. You can view your property on the link given below - {PTURL} Thank you",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            },
            {
                "code": "PT_NOTIF_WF_UPDATE_NONE",
                "message": "Dear {OWNER_NAME}, Your property with property-id {PROPERTYID} has been {updated/created}. You can view your property on the link given below - {PTURL} Thank you",
                "module": "rainmaker-pt",
                "locale": "en_IN"
            }
        ]
    "ws-services-calculation": {
        
        "WCBillingSlab": {
          "masterName": "WCBillingSlab",
          "isStateLevel": true,
          "uniqueKeys": []
        },
       
        "CalculationAttribute": {
          "masterName": "CalculationAttribute",
          "isStateLevel": true,
          "uniqueKeys": []
        }
      }
      {
          "id": "1",
          "buildingType": "RESIDENTIAL",
          "connectionType": "Metered",
          "calculationAttribute": "Water consumption",
          "minimumCharge": 100,
          
          "slabs": [
            {
              "from": 0,
              "to": 10,
              "charge": 2,
              "meterCharge": 50
            },
            {
              "from": 10,
              "to": 20,
              "charge": 2.5,
              "meterCharge": 50
            },
            {
              "from": 20,
              "to": 30,
              "charge": 8,
              "meterCharge": 150
            },
            {
              "from": 30,
              "to": 40,
              "charge": 12,
              "meterCharge": 150
            },
            {
              "from": 40,
              "to": 1000000000,
              "charge": 15,
              "meterCharge": 150
            }
          ]
        },
        {
          "id": "5",
          "buildingType": "RESIDENTIAL",
          "calculationAttribute": "No. of taps",
          "connectionType": "Non Metered",
          
          "minimumCharge": 100,
          "slabs": [
            {
              "from": 0,
              "to": 1000000000,
              "charge": 100
            }
          ]
        },
    {
      "tenantId": "pb.massewal",
      "moduleName": "ws-services-calculation",
      "WCBillingSlab": [
        {
          "id": "1",
          "buildingType": "RESIDENTIAL",
          "connectionType": "Metered",
          "calculationAttribute": "Water consumption",
          "minimumCharge": 100,
          
          "slabs": [
            {
              "from": 0,
              "to": 1000000,
              "charge": 2,
              "meterCharge": 50
            }
          ]
        },
        {
          "id": 2,
          "buildingType": "COMMERCIAL",
          "calculationAttribute": "Water consumption",
          "connectionType": "Metered",
          
          "minimumCharge": 200,
          "slabs": [
            {
              "from": 0,
              "to": 1000000,
              "charge": 13.31,
              "meterCharge": 532.4
              
            }
          ]
        },
        {
          "id": 3,
          "buildingType": "MIXED",
          "calculationAttribute": "Water consumption",
          "connectionType": "Metered",
          
          "minimumCharge": 200,
          "slabs": [
            {
              "from": 0,
              "to": 1000000,
              "charge": 13.31,
              "meterCharge": 532.4
              
            }
          ]
        },
        {
          "id": "4",
          "buildingType": "PUBLICSECTOR",
          "calculationAttribute": "Water consumption",
          "connectionType": "Metered",
          "minimumCharge": 150,
          
          "slabs": [
            {
              "from": 0,
              "to": 1000000,
              "charge": 8,
              "meterCharge": 250
            }
          ]
        },
        {
          "id": "5",
          "buildingType": "RESIDENTIAL",
          "calculationAttribute": "Flat",
          "connectionType": "Non_Metered",
          
          "minimumCharge": 150
        },
        {
          "id": "6",
          "buildingType": "COMMERCIAL",
          "calculationAttribute": "Flat",
          "connectionType": "Non_Metered",
          
          "minimumCharge": 150
        },
        {
          "id": "7",
          "buildingType": "MIXED",
          "calculationAttribute": "Flat",
          "connectionType": "Non_Metered",
          
          "minimumCharge": 150
        },
           {
          "id": "8",
          "buildingType": "PUBLICSECTOR",
          "calculationAttribute": "Flat",
          "connectionType": "Non_Metered",
          
          "minimumCharge": 150
        }
      ]
    }
    [
      {
          "id": {{PLACEHOLDER1}},
          "name": "Bulk Demand Generation",
          "url": "/ws-calculator/waterCalculator/_bulkDemand",
          "parentModule": "",
          "displayName":"Bulk Demand Generation",
          "orderNumber": 1,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER2}},
          "name": "Demand Calculation",
          "url": "/ws-calculator/waterCalculator/_calculate",
          "parentModule": "",
          "displayName": "Demand Calculation",
          "orderNumber": 2,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER3}},
          "name": "Meter Demand Calculation",
          "url": "/ws-calculator/meterConnection/_create",
          "parentModule": "",
          "displayName": "Meter Demand Calculation",
          "orderNumber": 3,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER4}},
          "name": "Meter Demand search",
          "url": "/ws-calculator/meterConnection/_search",
          "parentModule": "",
          "displayName": "Meter Demand search",
          "orderNumber": 3,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER5}},
          "name": "Demand Estimate",
          "url": "/ws-calculator/waterCalculator/_estimate",
          "parentModule": "",
          "displayName": "Demand Estimate",
          "orderNumber": 2,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        }
    ]
    [
        {
          "rolecode": "BULK_DEMAND_PROCESSING",
          "actionid": {{PLACEHOLDER1}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "BULK_DEMAND_PROCESSING",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "BULK_DEMAND_PROCESSING",
          "actionid": {{PLACEHOLDER3}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "BULK_DEMAND_PROCESSING",
          "actionid": {{PLACEHOLDER4}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "COLLECTION_OPERATOR",
          "actionid": {{PLACEHOLDER4}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER4}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER5}},
          "actioncode": "",
          "tenantId": "pb"
        }
    ]
    "demandDetails": [
                    {
                        "id": "77ba1e93-a535-409c-b9d1-a312c409bd45",
                        "demandId": "687c3176-305b-461d-9cec-2fa26a30c88f",
                        "taxHeadMasterCode": "WATER_CHARGE",
                        "taxAmount": 120,
                        "collectionAmount": 120,
                        "additionalDetails": null,
                        "auditDetails": {
                            "createdBy": "04956309-87cd-4526-b4e6-48123abd4f3d",
                            "lastModifiedBy": "04956309-87cd-4526-b4e6-48123abd4f3d",
                            "createdTime": 1583675275873,
                            "lastModifiedTime": 1583675298705
                        },
                        "tenantId": "pb.amritsar"
                    }
                ],
    "demandDetails": [
                    {
                        "id": "77ba1e93-a535-409c-b9d1-a312c409bd45",
                        "demandId": "687c3176-305b-461d-9cec-2fa26a30c88f",
                        "taxHeadMasterCode": "WATER_CHARGE",
                        "taxAmount": 120,
                        "collectionAmount": 0,
                        "additionalDetails": null,
                        "auditDetails": {
                            "createdBy": "04956309-87cd-4526-b4e6-48123abd4f3d",
                            "lastModifiedBy": "04956309-87cd-4526-b4e6-48123abd4f3d",
                            "createdTime": 1583675275873,
                            "lastModifiedTime": 1583675298705
                        },
                        "tenantId": "pb.amritsar"
                    },
                    {
                        "id": "0d83f4b0-6442-11ea-bc55-0242ac130003 ",
                        "demandId": "687c3176-305b-461d-9cec-2fa26a30c88f",
                        "taxHeadMasterCode": "WATER_CHARGE",
                        "taxAmount": 30,
                        "collectionAmount": 0,
                        "additionalDetails": null,
                        "auditDetails": {
                            "createdBy": "04956309-87cd-4526-b4e6-48123abd4f3d",
                            "lastModifiedBy": "04956309-87cd-4526-b4e6-48123abd4f3d",
                            "createdTime": 1583675275873,
                            "lastModifiedTime": 1583675298705
                        },
                        "tenantId": "pb.amritsar"
                    }
                ],
    ws.demand.based.batch.size=10

    Dashboard

    DSS has two sides to it. One is, the process in which the Data is pooled to ElasticSearch and the other is the way it is fetched, aggregated, computed, transformed and sent across.

    As this revolves around a variety of Data Sets, there is a need for making this configurable. So that, tomorrow, given a new scenario is introduced, then it is just a configuration away from getting the newly introduced scenario involved in this process flow.

    This document explains the steps on how to define the configurations for the Analytics Side Of DSS for NalJalSeva.

    What is analytics?

    Analytics: Micro Service which is responsible for building, fetching, aggregating and computing the Data on ElasticSearch to a consumable Data Response. Which shall be later used for visualizations and graphical representations.

    Analytics Configurations: Analytics contains multiple configurations. we need to add the changes related to NalJalseva in this dashboard-analytics.

    Dashboard analytics link -

    Below is a list of configurations that need to be changed to run NalJalSeva successfully.

    Chart API Configuration

    Each Visualization has its properties. Each Visualization comes from different data sources (Sometimes it is a combination of different data sources).

    In order to configure each visualization and its properties, we have a Chart API Configuration Document.

    In this, Visualization Code, which happens to be the key, will be having its properties configured as a part of the configuration and are easily changeable.

    Here is the sample ChartApiConfiguration.json data for the NalJalSeva.

    .

    Master Dashboard Configuration

    Master Dashboard Configuration is the main configuration that defines the Dashboards to be painted on the screen.

    It includes all the Visualizations, their groups, the charts which come within them and even their dimensions as what should be their height and width.

    Role Dashboard Mappings Configuration

    Master Dashboard Configuration which was explained earlier holds the list of Dashboards that are available.

    Given the instance where Role Action Mapping is not maintained in the Application Service, this configuration will act as Role - Dashboard Mapping Configuration.

    In this, each role is mapped against the dashboard which they are authorized to see.

    This was used earlier when the Role Action Mapping of eGov was not integrated.

    Later, when the Role Action Mapping started controlling the Dashboards to be seen on the client side, this configuration was just used to enable the Dashboards for viewing.

    • Transform collection schema for V2

      • This transform collection v1 configuration file is used to map the incoming data. This mapped data will go inside the data object in the DSS collection v2 index.

    • Here: $i, the variable value that gets incremented for the number of records of paymentDetails $j, the variable value that gets incremented for the number of records of billDetails.

    • This configuration defines and directs the Enrichment Process which the data goes through.

    • For example, if the incoming data belongs to a Collection Module, then the Collection Domain Config is picked. Based on the Business Type specified in the data, the right config is picked.

    Enrichment Domain Configuration

    1. Domain configuration

    2. Topic context configuration

    3. transform_expense.electricity_bill_v1 configuration

    4. transform_expense.om_v1 configuration

    Below is the list of configurations made changes or added newly for NalJalSeva.

    Topic Context Configuration

    • Topic Context Configuration is an outline to define which data is received on which Kafka Topic.

    • Indexer Service and many other services are sending out data on different Kafka Topics. If the Ingest Service is asked to receive those data and pass it through the pipeline, the context and the version of the data being received has to be set. This configuration is used to identify as in which Kafka topic consumed the data and what is the mapping for that.

    Based on expense and water-service business service we added transform configurations as per below.

    transform_expense.electricity_bill_v1 configuration:

    transform_expense.om_v1 configuration:

    transform_expense.salary_v1 configuration:

    transform_ws_v1 configuration:

    Note: For Kafka connect to work, Ingest pipeline application properties or in environments direct push must be disabled.

    • es.push.direct=false

    • If DSS collection index data is indexing directly ( without Kafka connector) to ES through the ingest pipeline then, make the application properties or in environments, direct push must be enabled.

    • es.push.direct=true

    Creating Kafka Sync Connector - push the data to the Elasticsearch

    • Configure the Kafka topics in the environments or Ingest pipeline application properties as shown below.

    For details on services such as re-indexing and Kafka connection, refer to the document.

    Dashboard Service Changes

    Main-Monthly Dashboard

    For the main monthly dashboard, we are using the service API to fetch the data and show it in the main monthly dashboard table.

    Ws-services:

    /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.

    eChallan-Service:

    /echallan-services/eChallan/v1/_chalanCollectionData it is added to get the main monthly dashboard data for the expense.

    Dashboard-Metrics:

    To show the data in metrics format in a specific month dashboard we are using service API which will fetch the data based on dashboard type.

    Ws-services:

    /ws-services/wc/_revenueDashboard Should be added to get the revenue dashboard metrix data. It will show the data of revenue collection information

    eChallan-Service:

    /echallan-services/eChallan/v1/_expenseDashboard Is added in echallan-service to show the data of expenses in matrix format.

    MDMS- changes for the dashboard:

    Actions & Role Action Mapping

    Actions:

    Role Action Mapping:

    Available Roles:

    Postman collection for dashboards

    Postman links
    To enhance the data Collection, the domain index specified in the configuration is queried with the right arguments and the response data is obtained, transformed and set.
    transform_expense.salary_v1 configuration
  • transform_ws_v1 configuration

  • echallan-services/eChallan/v1/_chalanCollectionData

    echallan-services/eChallan/v1/_chalanCollectionData

    /ws-services/wc/_revenueDashboard

    /ws-services/wc/_revenueCollectionData

    /dashboard-analytics/dashboard/getChartV2

    https://github.com/misdwss/config-mgramseva/tree/QA/egov-dss-dashboards/dashboard-analytics
    Chart API Configuration
    Master Dashboard Configuration
    Click here to check the complete configuration
    Click here to check the complete configuration.
    Click here to check the complete configuration.
    Click here for an example configuration
    Click here to see the complete configuration
    Click here to see the complete configuration
    https://github.com/misdwss/config-mgramseva/blob/QA/egov-dss-dashboards/dashboard-ingest/transform_expense.electricity_bill_v1.json
    https://github.com/misdwss/config-mgramseva/blob/QA/egov-dss-dashboards/dashboard-ingest/transform_expense.om_v1.json
    https://github.com/misdwss/config-mgramseva/blob/QA/egov-dss-dashboards/dashboard-ingest/transform_expense.salary_v1.json
    https://github.com/misdwss/config-mgramseva/blob/QA/egov-dss-dashboards/dashboard-ingest/transform_ws_v1.json
    Services Re-indexing

    Billing

    The main objective of the billing module is to serve the Bill for all revenue Business services. To serve the Bill, Billing-Service requires demand. Demands will be prepared by Revenue modules and stored by billing based on which it will generate the Bill.

    Pre-requisites

    1. Prior knowledge of Java/J2EE.

    2. Prior knowledge of Spring Boot.

    3. Prior knowledge of KAFKA

    4. Prior knowledge of REST APIs and related concepts like path parameters, headers, JSON, etc.

    5. Prior knowledge of the demand-based systems.

    6. The following services should be up and running:

      • user

      • MDMS

      • Id-Gen

    Key Functionalities

    • eGov billing service creates and maintains demands.

    • Generates bills based on demands.

    • Updates the demands from payment when the collection service takes a payment.

    Deployment Details

    • Deploy the latest image of the billing service available.

    Configuration Details

    In the MDMS data configuration, the following master data is needed for the functionality of billing

    MDMS Configuration

    Business Service JSON

    TAX-Head JSON

    Tax-Period JSON

    param
    value
    description

    Integration Details

    Integration Scope

    Billing service can be integrated with any organization or system that wants a demand-based payment system.

    Integration Benefits

    • Easy to create and simple process of generating bills from demands

    • The amalgamation of bills period-wise for a single entity like PT or Water connection.

    • Amendment of bills in case of legal requirements.

    Integration Steps

    1. Customers can create a demand using the /demand/_create

    2. Organizations or systems can search the demand using /demand/_searchendpoint

    3. Once the demand is raised the system can call /demand/_update endpoint to update the demand as per need.

    4. Bills can be generated using, which is a self-managing API that generates a new bill only when the old one expires /bill/_fetchbill.

    Interaction Diagram

    Reference Docs

    Doc Links

    Title
    Link

    API List

    Title
    Link

    Apportioning

    What is apportioning?

    Adjusting the receivable amount with the individual tax head.

    Types of apportioning V1.1:

    Default order-based apportioning(Based on apportioning order adjust the received amount with each tax head).V1.1

    Types of apportioning V1.2:

    • Proportionate-based apportioning (Adjust total receivable with all the tax heads equally)

    • Order & Percentage-based apportioning(Adjust total receivable based on order and the percentage which is defined for each tax head).

    Principle of apportioning:

    The basic principle of apportioning is, that if the full amount is paid for any bill then each tax head should get nullified with their corresponding adjusted amount.

    Example: Case 1: When there are no arrears all tax heads belong to their current purpose:

    TaxHead
    Amount
    Order
    FullPayment(2000)
    PartialPayment1(1500)
    PartialPayment2(750)
    PartialPayment2withrebate(500)

    Case 2: Apportioning with two years of arrear: If the current financial year is 2014-15. Below are the demands

    TaxHead
    Amount
    TaxPeriodFrom
    TaxPeriodTo
    Order
    Purpose

    If any payment is not done, and we generate demand in 2015-16 then the demand structure will be as follows:

    TaxHead
    Amount
    TaxPeriodFrom
    TaxPeriodTo
    Order
    Purpose

    "revenueAndExpenditureTrendTwo": {
        "chartName": "DSS_MGRAMSEVA_COLLECTIONS_DATA_TWO",
        "queries": [
          {
            "module": "WS",
            "dateRefField": "dataObject.paymentDetails.receiptDate",
            "requestQueryMap": "{\"wardId\" : \"domainObject.ward.name.keyword\",\"module\" : \"dataObject.Bill.billDetails.businessService.keyword\", \"tenantId\" : \"dataObject.tenantId\", \"district\" : \"dataObject.tenantData.cityDistrictCode\"}",
            "indexName": "dss-collection_v2",
            "aggrQuery": "{\"aggs\":{\"AGGR\":{\"filter\":{\"bool\":{\"must_not\":[{\"term\":{\"dataObject.tenantId.keyword\":\"pb.testing\"}},{\"terms\":{\"dataObject.paymentDetails.bill.status.keyword\":[\"Cancelled\"]}}]}},\"aggs\":{\"Water_Service\":{\"filter\":{\"bool\":{\"must\":[{\"terms\":{\"dataObject.paymentDetails.bill.businessService.keyword\":[\"WS\"]}}]}},\"aggs\":{\"WaterService\":{\"date_histogram\":{\"field\":\"dataObject.paymentDetails.receiptDate\",\"interval\":\"month\"},\"aggs\":{\"Count\":{\"sum\":{\"field\":\"dataObject.paymentDetails.bill.billDetails.amountPaid\"}}}}}},\"Expense_Service\":{\"filter\":{\"bool\":{\"must\":[{\"terms\":{\"dataObject.paymentDetails.bill.businessService.keyword\":[\"EXPENSE.SALARY\",\"EXPENSE.OM\",\"EXPENSE.ELECTRICITY_BILL\"]}}]}},\"aggs\":{\"ExpenseService\":{\"date_histogram\":{\"field\":\"dataObject.paymentDetails.receiptDate\",\"interval\":\"month\"},\"aggs\":{\"Count\":{\"sum\":{\"field\":\"dataObject.paymentDetails.bill.billDetails.amountPaid\"}}}}}}}}}}"
          }
        ],
        "chartType": "line",
        "valueType": "number",
        "action": "",
        "drillChart": "none",
        "documentType": "_doc",
        "aggregationPaths": [
          "WaterService",
          "ExpenseService"
        ],
        "isCumulative": false,
        "interval": "month",
        "insight": {},
        "_comment": " "
      },
    {
          "name": "DSS_MGRAMSEVA_DASHBOARD",
          "id": "mgramseva-wc",
          "isActive": "",
          "style": "linear",
          "visualizations": [
            {
              "row": 1,
              "name": "DSS_REVENUE",
              "vizArray": [
                {
                  "id": 431,
                  "name": "DSS_MGRAMSEVA_WC",
                  "dimensions": {
                    "height": 350,
                    "width": 12
                  },
                  "vizType": "chart",
                  "label": "",
                  "noUnit": true,
                  "isCollapsible": false,
                  "charts": [
                    {
                      "id": "revenueAndExpenditureTrendOne",
                      "name": "DSS_MGRAMSEVA_COLLECTIONS_DATA_ONE",
                      "code": "",
                      "chartType": "bar",
                      "filter": "",
                      "headers": [],
                      "tabName": "Graphical"
                    },
                    {
                      "id": "revenueAndExpenditureTrendTwo",
                      "name": "DSS_MGRAMSEVA_COLLECTIONS_DATA_TWO",
                      "code": "",
                      "chartType": "line",
                      "filter": "",
                      "headers": [],
                      "tabName": "Expenditure"
                    }
                  ]
                }
              ]
            }
          ]
        }
     {
                "id": "4",
                "domain": "WS",
                "indexName": "water-services",
                "documentType": "",
                "query": "{\"query\":{\"bool\":{\"must\":[{\"match_phrase\":{\"Data.connectionNo\":\"value\"}}]}}}",
                "targetReferences": [
                    {
                        "fieldName": "connectionNo",
                        "argument": "Data.connectionNo",
                        "dataType": "String",
                        "value": "$value",
                        "seperator": " ",
                        "expression": "connectionNo"
                    }
                ],
                "sourceReferences": [
                    {
                        "fieldName": "consumerCode",
                        "argument": "Data.connectionNo",
                        "value": "$value",
                        "seperator": " ",
                        "expression": "connectionNo"
                    }
                ]
            },
            {
                "id": "5",
                "domain": "EXPENSE.SALARY",
                "indexName": "echallan-services",
                "documentType": "",
                "query": "{\"query\":{\"bool\":{\"must\":[{\"match_phrase\":{\"Data.challanNo\":\"value\"}}]}}}",
                "targetReferences": [
                    {
                        "fieldName": "challanNo",
                        "argument": "Data.challanNo",
                        "dataType": "String",
                        "value": "$value",
                        "seperator": " ",
                        "expression": "challanNo"
                    }
                ],
                "sourceReferences": [
                    {
                        "fieldName": "consumerCode",
                        "argument": "Data.challanNo",
                        "value": "$value",
                        "seperator": " ",
                        "expression": "challanNo"
                    }
                ]
            },
            {
                "id": "6",
                "domain": "EXPENSE.ELECTRICITY_BILL",
                "indexName": "echallan-services",
                "documentType": "",
                "query": "{\"query\":{\"bool\":{\"must\":[{\"match_phrase\":{\"Data.challanNo\":\"value\"}}]}}}",
                "targetReferences": [
                    {
                        "fieldName": "challanNo",
                        "argument": "Data.challanNo",
                        "dataType": "String",
                        "value": "$value",
                        "seperator": " ",
                        "expression": "challanNo"
                    }
                ],
                "sourceReferences": [
                    {
                        "fieldName": "consumerCode",
                        "argument": "Data.challanNo",
                        "value": "$value",
                        "seperator": " ",
                        "expression": "challanNo"
                    }
                ]
            },
            {
                "id": "7",
                "domain": "EXPENSE.OM",
                "indexName": "echallan-services",
                "documentType": "",
                "query": "{\"query\":{\"bool\":{\"must\":[{\"match_phrase\":{\"Data.challanNo\":\"value\"}}]}}}",
                "targetReferences": [
                    {
                        "fieldName": "challanNo",
                        "argument": "Data.challanNo",
                        "dataType": "String",
                        "value": "$value",
                        "seperator": " ",
                        "expression": "challanNo"
                    }
                ],
                "sourceReferences": [
                    {
                        "fieldName": "consumerCode",
                        "argument": "Data.challanNo",
                        "value": "$value",
                        "seperator": " ",
                        "expression": "challanNo"
                    }
                ]
            }
     "topicContextConfigurations": [
        {
          "topic": "dss-collection-update",
          "dataContext": "collection",
          "dataContextVersion": "v2"
        },
        {
          "topic": "topicTwo",
          "dataContext": "billing",
          "dataContextVersion": "v1"
        }
      ]
    [
     {
          "id": {{PLACEHOLDER1}},
          "name": " feedback search",
          "url": "/ws-services/wc/_revenueDashboard",
          "parentModule": "",
          "displayName": "get Revenue Dashboard Data",
          "orderNumber": 2,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER2}},
          "name": " feedback search",
          "url": "/ws-services/wc/_revenueCollectionData",
          "parentModule": "",
          "displayName": "get Revenue Dashboard Data",
          "orderNumber": 2,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER3}},
          "name": "Expense Update",
          "url": "/echallan-services/eChallan/v1/_expenseDashboard",
          "parentModule": "",
          "displayName": "get Expense Dashboard",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "echallan-services",
          "code": "null",
          "path": ""
        },
     {
          "id": {{PLACEHOLDER4}},
          "name": "Expense Update",
          "url": "/echallan-services/eChallan/v1/_chalanCollectionData",
          "parentModule": "",
          "displayName": "get Expense Dashboard",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "echallan-services",
          "code": "null",
          "path": ""
        },
          {
          "id": {{PLACEHOLDER5}},
          "name": "DSS Dashboard Charts",
          "url": "/dashboard-analytics/dashboard/getChartV2",
          "parentModule": "",
          "displayName": "DSS",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "DSS",
          "code": "null",
          "path": ""
         },
    ]
    
    
    [
     
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER1}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER3}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER4}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER5}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "DASHBOARD_VIEWER",
          "actionid": {{PLACEHOLDER5}},
          "actioncode": "",
          "tenantId": "pb"
        }
    ]
    
    
    
    		{
          "code": "GP_ADMIN",
          "name": "GP Admin",
          "description": "Who has a access to ws-services"
        },
    		{
          "code": "COLLECTION_OPERATOR",
          "name": "Collection Operator",
          "description": "Who has a access to ws-services,demand, bill and payment"
        },
    		{
          "code": "BULK_DEMAND_PROCESSING",
          "name": "Bulk Demand Processing",
          "description": "Who has a access to bulk demand generation,raise bill, downloa bill and receipts"
        },
    		{
          "code": "EXPENSE_PROCESSING",
          "name": "Expense Processing",
          "description": "Who has a access to create and update expenses"
        },
    		{
          "code": "DASHBOARD_VIEWER",
          "name": "Dashbaord Viewer",
          "description": "Who has a access to dashboard of revenue and expenditure"
        }
    URL-Shortening
  • notification-sms

  • Bills can be searched using /bill/_search.

  • Amendment facility can be used in case of a legal issue to add values to existing demands using /amendment/_create and /amendment/_update can used to cancel the created ones or update workflow if configured.

  • 1000

    -250

    -750

    -750

    RemainingAMTfromPayableAMT

    0

    0

    0

    0

    Penality

    500

    5

    500

    500

    AdjustedAmt

    500

    -500

    RemainingAMTfromPayableAMT

    1000

    250

    Interest

    500

    4

    500

    500

    AdjustedAmt

    500

    -500

    RemainingAMTfromPayableAMT

    1500

    750

    Cess

    500

    3

    500

    500

    AdjustedAmt

    500

    -500

    RemainingAMTfromPayableAMT

    2000

    1250

    Exm

    -250

    1

    -250

    -250

    AdjustedAmt

    -250

    250

    RemainingAMTfromPayableAMT

    2250

    1750

    Rebate

    -250

    2

    -250

    -250

    AdjustedAmt

    -250

    250

    RemainingAMTfromPayableAMT

    2500

    750

    Penality

    500

    2014

    2015

    5

    Current

    AdjustedAmt

    0

    Interest

    500

    2014

    2015

    4

    Current

    AdjustedAmt

    0

    Cess

    500

    2014

    2015

    3

    Current

    AdjustedAmt

    0

    Exm

    -250

    2014

    2015

    1

    Current

    AdjustedAmt

    0

    6

    Arrear

    AdjustedAmt

    0

    Pt_tax

    1500

    2015

    2016

    6

    Current

    AdjustedAmt

    0

    Penalty

    600

    2014

    2015

    5

    Arrear

    AdjustedAmt

    0

    Penalty

    500

    2015

    2016

    5

    Current

    AdjustedAmt

    0

    Interest

    500

    2014

    4

    Arrear

    AdjustedAmt

    0

    Cess

    500

    2014

    3

    Arrear

    AdjustedAmt

    0

    Exm

    -250

    2014

    1

    Arrear

    AdjustedAmt

    0

    bs.businesscode.demand.updateurl

    {

    "PT":"http://pt-calculator-v2:8080/pt-calculator-v2/propertytax/_updatedemand",

    "TL":""

    }

    Each module’s application calculator should provide its updated URL. if not present then a new bill will be generated without making any changes to the demand.

    bs.bill.billnumber.format

    BILLNO-{module}-[SEQ_egbs_billnumber{tenantid}]

    IdGen format for bill number

    bs.amendment.idbs.bill.billnumber.format

    BILLNO-{module}-[SEQ_egbs_billnumber{tenantid}]

    is.amendment.workflow.enabled

    true/false

    enable disable workflow of bill amendment

    Id-Gen service

    url-shortening

    MDMS

    /demand/_create, _update, _search

    https://www.getpostman.com/collections/900d99a85d083fb2d377

    /bill/_fetchbill, _search

    https://www.getpostman.com/collections/900d99a85d083fb2d377

    /amendment/_create, _update

    https://www.getpostman.com/collections/b195d3b1d354c767b6bd

    Pt_tax

    1000

    6

    1000

    1000

    750

    750

    Pt_tax

    1000

    2014

    2015

    6

    Current

    AdjustedAmt

    0

    Pt_tax

    1000

    2014

    Interaction diagram v1.1

    AdjustedAmt

    2015

    {
      "tenantId": "pb",
      "moduleName": "BillingService",
      "BusinessService": [
        {
          "businessService": "PropertyTax",
          "code": "PT",
          "isBillAmendmentEnabled":"true",
          "collectionModesNotAllowed": [
            "DD","OFFLINE_NEFT","OFFLINE_RTGS","POSTAL_ORDER"
          ],
          "partPaymentAllowed": true,
          "minAmountPayable":100,
          "isAdvanceAllowed": false,
          "demandUpdateTime": 86400000,
          "isVoucherCreationEnabled": true,
          "billGineiURL" : "egov-searcher/bill-genie/billswithaddranduser/_get"
        },
        {
          "businessService": "WaterCharges",
          "code": "WC",
          "isBillAmendmentEnabled":"true",
          "collectionModesNotAllowed": [
            "DD","OFFLINE_NEFT","OFFLINE_RTGS","POSTAL_ORDER"
          ],
          "partPaymentAllowed": false,
          "isAdvanceAllowed": true,
          "demandUpdateTime": 86400000,
          "isVoucherCreationEnabled": false
        },
        {
          "businessService": "TradeLicense",
          "code": "TL",
          "collectionModesNotAllowed": [
            "DD","OFFLINE_NEFT","OFFLINE_RTGS","POSTAL_ORDER"
          ],
          "partPaymentAllowed": false,
          "isAdvanceAllowed": false,
          "demandUpdateTime": 604800000,
          "isVoucherCreationEnabled": true
        }
      ]
    }
    {
      "tenantId": "pb",
      "moduleName": "BillingService",
      "TaxHeadMaster": [
        {
          "category": "ADVANCE_COLLECTION",
          "service": "PT",
          "name": "Pt advance carry forward",
          "code": "PT_ADVANCE_CARRYFORWARD",
          "isDebit": true,
          "isActualDemand": false,
          "order": "0",
          "isRequired": false
        },
        {
          "category": "TAX",
          "service": "PT",
          "name": "Pt owner exemption",
          "code": "PT_OWNER_EXEMPTION",
          "isDebit": true,
          "isActualDemand": true,
          "order": "5",
          "isRequired": false
        },
        {
          "category": "TAX",
          "service": "PT",
          "name": "Pt time rebate",
          "code": "PT_TIME_REBATE",
          "isDebit": true,
          "isActualDemand": true,
          "order": "2",
          "isRequired": false
        },
        {
          "category": "TAX",
          "service": "PT",
          "name": "Pt unit usage excemption",
          "code": "PT_UNIT_USAGE_EXEMPTION",
          "isDebit": true,
          "isActualDemand": true,
          "order": "6",
          "isRequired": false
        },
        {
          "category": "TAX",
          "service": "PT",
          "name": "Pt adhoc penalty",
          "code": "PT_ADHOC_PENALTY",
          "isDebit": false,
          "isActualDemand": false,
          "order": "1",
          "isRequired": false
        },
        {
          "category": "TAX",
          "service": "PT",
          "name": "propertytax",
          "code": "PT_TAX",
          "isDebit": false,
          "isActualDemand": true,
          "order": "0",
          "isRequired": false
        },
        {
          "category": "TAX",
          "service": "PT",
          "name": "Pt fire cess",
          "code": "PT_FIRE_CESS",
          "isDebit": false,
          "isActualDemand": true,
          "order": "7",
          "isRequired": false
        }
      ]
    }
    {
      "tenantId": "pb",
      "moduleName": "BillingService",
      "TaxPeriod": [
        {
          "fromDate": 1554076799000,
          "toDate": 1585679399000,
          "periodCycle": "ANNUAL",
          "service": "PT",
          "code": "PTAN2019",
          "financialYear": "2019-20"
        },
        {
          "fromDate": 1522540800000,
          "toDate": 1554076799000,
          "periodCycle": "ANNUAL",
          "service": "PT",
          "code": "PTAN2018",
          "financialYear": "2018-19"
        },
        {
          "fromDate": 1491004800000,
          "toDate": 1522540798000,
          "periodCycle": "ANNUAL",
          "service": "PT",
          "code": "PTAN2017",
          "financialYear": "2017-18"
        },
        {
          "fromDate": 1459468800000,
          "toDate": 1491004799000,
          "periodCycle": "ANNUAL",
          "service": "PT",
          "code": "PTAN2016",
          "financialYear": "2016-17"
        },
        {
          "fromDate": 1522540800000,
          "toDate": 1554076799000,
          "periodCycle": "ANNUAL",
          "service": "TL",
          "code": "TLAN2018",
          "financialYear": "2018-19"
        }
      ]
    }

    Vendor Registry

    Vendor Registry is a system that enables ULB employees to create and search vendors i.e. Desludging Operator (DSO) and driver entities with appropriate vehicle Entities for FSM Applications. This document contains details on how to set up the Vendor and describes the functionalities provided.

    Pre-requisites

    Before you proceed with the configuration, make sure the following pre-requisites are met -

    • Java 8

    The Kafka server is up and running

  • egov-persister service is running and has a vendor-persister config path added to it

  • PSQL server is running and a database is created to store FSM Application data

  • The following services should be up and running:

    • egov-mdms-service

    • egov-user-service

    • boundary-service

    • vehicle

  • Key Functionalities

    1. Added payment payment preference and agency attributes for DSO

    2. Added gender attribute in the create and update APIs for Vendor

    3. Updated the Vendor search API to add vehicleCapacity in the search parameter to search all vendors matching the vehicle capacity specified in the search parameter.

    Deployment Details

    1. Deploy the latest version of the vendor

    2. Add vendor-persister.yml file in the config folder in git and add that path in persister. (The file path is to be added in the environment yaml file in a param called persist-yml-path ) and restart egov-persister-service.

    3. Integrate the below changes in vendor-persister.yml - https://github.com/egovernments/configs/commit/95dd26f926ec44d07448926ee4b6b7e031847a57

    4. https://github.com/egovernments/configs/pull/2237/files

    Configuration Details

    Actions & Role Action Mapping

    After adding Actions and role-action mappings, restart the egov-mdms-service.

    Actions

    Role Action Mapping

    Infra Ops Configuration

    Configurations we can manage through values.yml of the vendor in the infra ops repo are as follows: values.yml for a vehicle can be found.

    Description
    name in values.yml
    Current Value

    Kafka Consumer Group

    SPRING_KAFKA_CONSUMER_GROUP_ID

    egov-vendor-services

    kafka topic to which service push data to save new Vendor

    PERSISTER_SAVE_VENDOR_TOPIC

    save-vendor-application

    mdms service host

    EGOV_MDMS_HOST

    egov-mdms-service from egov-service-host

    Vehicle Service host

    EGOV_VEHICLE_HOST

    Configurations sample in Values.yml

    Data Setup

    DSO for FSM System is a vendor, For every city/ULB DSO should be created with the Representative details as owner, associated vehicles and drivers.

    Sample Curl

    Integration Details

    Integration Scope

    Any system or DIGIT module can integrated with Vendor Service, which helps to manage the Vendor with the vehicles, drivers and owner for the representative and login for the representative/owner to log into the system to carry our role-specific operations

    Integration Benefits

    • Validation of DSO/Vendor availability

    • Fetch the vehicle assigned to the DSO

    • Fetch the Drivers assigned to the DSO

    Integration Steps

    • FSM to call vendor/v1/_search to fetch the DSOs

    • FSM can call vendor/v1/_search to fetch the DSOs and the respective vehicles and drivers

    Reference Docs

    API List

    API

    {
          "id": {{PLACEHOLDER1}},
          "name": "Create Vendor/DSO",
          "url": "/vendor/v1/_create",
          "displayName": "Create Vehicle",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "vendor",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER1}},
          "name": "Search Vendor/DSO",
          "url": "/vendor/v1/_search",
          "displayName": "Search  Vendor",
          "orderNumber": 1,
          "enabled": false,
          "serviceCode": "vendor",
          "code": "null",
          "path": ""
        },
    [
      {
        "rolecode": "FSM_ADMIN",
        "actionid": "{{PLACEHOLDER1}}",
        "actioncode": "",
        "tenantId": "pb"
      },
      {
        "rolecode": "FSM_ADMIN",
        "actionid": "{{PLACEHOLDER2}}",
        "actioncode": "",
        "tenantId": "pb"
      },
      {
        "rolecode": "FSM_DSO",
        "actionid": "{{PLACEHOLDER2}}",
        "actioncode": "",
        "tenantId": "pb"
      },
      {
        "rolecode": "FSM_EDITOR_EMP",
        "actionid": "{{PLACEHOLDER2}}",
        "actioncode": "",
        "tenantId": "pb"
      },
      {
        "rolecode": "FSM_VIEW_EMP",
        "actionid": "{{PLACEHOLDER2}}",
        "actioncode": "",
        "tenantId": "pb"
      },
      {
        "rolecode": "FSM_EMP_FSTPO",
        "actionid": "{{PLACEHOLDER2}}",
        "actioncode": "",
        "tenantId": "pb"
      },
      {
        "rolecode": "CITIZEN",
        "actionid": "{{PLACEHOLDER2}}",
        "actioncode": "",
        "tenantId": "pb"
      }
    ]
    # Common Labels
    labels:
      app: "vendor"
      group: "rainmaker"
    
    # Ingress Configs
    ingress:
      enabled: true
      zuul: true
      context: "vendor"
    
    # Init Containers Configs
    initContainers:
      dbMigration:
        enabled: true
        schemaTable: "vendor_schema"
        image:
          repository: "vendor-db"
    
    # Container Configs
    image:
      repository: "vendor"
    replicas: "1"
    healthChecks:
      enabled: true
      livenessProbePath: "/vendor/health"
      readinessProbePath: "/vendor/health"
    appType: "java-spring"
    tracing-enabled: true
    heap: "-Xmx256m -Xms256m"
    java-args: "-Dspring.profiles.active=monitoring"
    
    # Additional Container Envs
    env: |
      - name: EGOV_VEHICLE_HOST
        valueFrom:
          configMapKeyRef:
            name: egov-service-host
            key: vehicle
      - name: EGOV_MDMS_HOST
        valueFrom:
          configMapKeyRef:
            name: egov-service-host
            key: egov-mdms-service
      - name: EGOV_USER_HOST
        valueFrom:
          configMapKeyRef:
            name: egov-service-host
            key: egov-user
      - name: EGOV_LOCATION_HOST
        valueFrom:
          configMapKeyRef:
            name: egov-service-host
            key: egov-location
      - name: EGOV_HRMS_HOST
        valueFrom:
          configMapKeyRef:
            name: egov-service-host
            key: egov-hrms
      - name: SPRING_KAFKA_CONSUMER_GROUP_ID
        value: egov-vendor-services
      - name: PERSISTER_SAVE_VENDOR_TOPIC
        value: save-vendor-application
      - name: PERSISTER_UPDATE_VENDOR_TOPIC
        value: update-vendor-application
      - name: SPRING_KAFKA_PRODUCER_KEY_SERIALIZER
        value: org.apache.kafka.common.serialization.StringSerializer
      - name: SPRING_KAFKA_PRODUCER_VALUE_SERIALIZER
        value: org.springframework.kafka.support.serializer.JsonSerializer
      - name: JAVA_OPTS
        value: {{ index .Values "heap" | quote }}
      - name: JAVA_ARGS
        value: {{ index .Values "java-args" | quote }}
      - name: SERVER_PORT
        value: "8080"
      - name: SECURITY_BASIC_ENABLED
        value: "false"  
      - name: MANAGEMENT_SECURITY_ENABLED
        value: "false"
      {{- if index .Values "tracing-enabled" }}
      - name: TRACER_OPENTRACING_ENABLED
        value: "true" 
      {{- end }}
     
    curl --location --request POST 'https://dev.digit.org/vendor/v1/_create' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "RequestInfo": {
            "apiInfo": {
                "id": "string",
                "version": "string",
                "path": "string"
            },
            "deviceDetail": {
                "id": "string",
                "signature": "string"
            },
            "ts": 0,
            "action": "string",
            "key": "string",
            "msgId": "string",
            "requesterId": "string",
            "authToken": "a35b5ba7-2d5f-4272-8a67-0303cfab2c9f"
        },
        "vendor": {
            "tenantId": "pb.amritsar",
            "name": "DSO TATA1",
            "address": { 
                "tenantId": "pb.amritsar",
                "doorNo": "my door",
                "plotNo": "my plot",
                "landmark": "my landmark",
                "city": "amritsar",
                "district": "amritsar",
                "region": "amritsar",
                "state": "punjab",
                "country": "in",
                "pincode": "143001",
                "additionDetails": null,
                "buildingName": "my building",
                "street": "my streat",
                "locality": {
                    "code": "SUN178",
                    "name": "Mohalla Singh kia - Area2",
                    "label": "Locality",
                    "latitude": null,
                    "longitude": null,
                    "area": "Area2",
                    "pincode": null,
                    "boundaryNum": 1,
                    "children": []
                },
                "geoLocation": {
                    "latitude": 0,
                    "longitude": 0,
                    "additionalDetails": {}
                }
            },
            "owner": {
    
                "tenantId": "pb.amritsar",
                "name": "DSOc4",
                "fatherOrHusbandName": "Phani",
                "relationship": "FATHER",
                "gender": "MALE",
                "dob": 550261800000,
                "emailId": "[email protected]",
                "correspondenceAddress": "KPHB",
                "mobileNumber": 8919146603
            },
            "vehicles": [{
            "tenantId": "pb.amritsar",
            "registrationNumber": "TS 09 PA 3586",
            "model":"1998",
            "type":"TATA.407",
            "tankCapacity":"2000",
            "suctionType":"SEWER_SUCTION_MACHINE",
            "pollutionCertiValidTill":1611584416772,
            "InsuranceCertValidTill":1611584416772,
            "fitnessValidTill":1611584416772,
            "roadTaxPaidTill":1611584416772,
            "gpsEnabled":true,
            "source":"Municipal records",
            "owner": {
    
                "tenantId": "pb.amritsar",
                "name": "DSOc4",
                "fatherOrHusbandName": "Phani",
                "relationship": "FATHER",
                "gender": "MALE",
                "dob": 550261800000,
                "emailId": "[email protected]",
                "correspondenceAddress": "KPHB",
                "mobileNumber": 8919146617
            }
        },{
            "tenantId": "pb.amritsar",
            "registrationNumber": "TS 09 PA 2584",
            "model":"1998",
            "type":"MAHINDRA.BOLERO_PICKUP",
            "tankCapacity":"2000",
            "suctionType":"SEWER_SUCTION_MACHINE",
            "pollutionCertiValidTill":1611584416772,
            "InsuranceCertValidTill":1611584416772,
            "fitnessValidTill":1611584416772,
            "roadTaxPaidTill":1611584416772,
            "gpsEnabled":true,
            "source":"Municipal records",
            "owner": {
    
                "tenantId": "pb.amritsar",
                "name": "DSOc3",
                "fatherOrHusbandName": "Phani",
                "relationship": "FATHER",
                "gender": "MALE",
                "dob": 550261800000,
                "emailId": "[email protected]",
                "correspondenceAddress": "KPHB",
                "mobileNumber": 8919146617
            }
        }],
            "drivers": [{
    
                "tenantId": "pb.amritsar",
                "name": "DriverDSO4",
                "fatherOrHusbandName": "Phani",
                "relationship": "FATHER",
                "gender": "MALE",
                "dob": 550261800000,
                "emailId": "[email protected]",
                "correspondenceAddress": "KPHB",
                "mobileNumber": 8919146216
            },{
    
                "tenantId": "pb.amritsar",
                "name": "DriverDSO3",
                "fatherOrHusbandName": "Phani",
                "relationship": "FATHER",
                "gender": "MALE",
                "dob": 550261800000,
                "emailId": "[email protected]",
                "correspondenceAddress": "KPHB",
                "mobileNumber": 8919146216
            }],
            "source": "WhatsApp"
        }
    }'

    vehicle from egov-service-host

    User service host

    EGOV_USER_HOST

    egov-user-service from egov-service-host

    Location Service Host

    EGOV_LOCATION_HOST

    egov-location from egov-service-host

    /vendor/v1/_create
    /vendor/v1/_search
    /vendor/v1/_plainsearch

    Water

    Water service is a DIGIT application that helps and gives flexibility to municipalities and citizens to manage water service requirements like applying for a water connection or searching for water connections. The application goes through various steps as defined by the states. The application is passed through different users who verify and inspect the application details before moving it to the next stage. Based on the state, citizens get notifications (SMS and in-app ). Citizens can also pay 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 a water service persister config path added to it

    • PSQL server is running and a 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/without arrears

    • Create a new Water Connection

    • Searching for water connections

    • Notification based on the application state

    Environment variables
    Description

    Interaction Diagram

    Configuration Details

    MDMS configuration:

    master-config.json for water service

    ConnectionType:

    Two connection types supported Metered and Non metered.

    CheckList:

    A checklist is used to define the Q&A for the feedback form and its validation.

    Category:

    A predefined list of categories is allowed.

    SubCategory:

    A pre-defined list of subcategories is allowed.

    Property creation through WNS module

    Persister configuration:

    Actions & Role Action Mapping

    Actions:

    Role Action Mapping:

    Roles 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.

    Setup

    1. Write the configuration for the water service.

    2. 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.

    3. Put the indexer config file into the config repo under egov-indexer folder.( )

    4. 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 based on different application states.

    Capturing Connection Holders

    We can add connection holders to the water connection which will be the owner of the connection. We can fill in the connection holders' details or we can just make the property owner to the connection holder.

    The connection holder will get a notification based on a different state of the application. We are pushing the data of the connection holders in the user service too.

    Multiple Road Type Support

    We can add road-cutting details of multiple roads to the water connection. For each road that goes undercutting process, we have to fill in the road type and the cutting area details. Based on this information, the application one-time fee estimate is calculated.

    Deployment Details

    1. Add mdms configs required for water connection registration and restart mdms service.

    2. Deploy the latest version of the ws-services service.

    3. Add water-service and water-services-meter persister yaml path in persister configuration and restart persister service.

    4. Add Role-Action mapping for API’s.

    Integration Details

    Integration Scope

    This ws-service module is used to manage water service connections against a property in the system.

    Integration Benefits

    • Provide backend support for the different water connection registration processes.

    • Mseva and SMS notifications on application status changes.

    • The elastic search index for creating visualizations and Dashboards.

    • Supports configurable workflows.

    Integration Steps

    1. To integrate, the host of the ws-service module should be overwritten in the helm chart.

    2. /ws-services/wc/_create should be added as the endpoint for creating water applications/connections in the system.

    3. /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.

    Reference Docs

    Doc Links

    Title
    Link

    API List

    Title
    Link

    (Note: All the APIs are in the same Postman collection therefore the same link is added in each row)

    egov.idgen.wcid.format

    This variable contains the idgen format for water connection ex:- WS_AP/[CITY.CODE]/[fy:yyyy-yy]/[SEQ_EGOV_COMMON]

    Create businessService (workflow configuration) according to trade water connection, modify water connection

  • Add ws-service indexer yaml path in indexer service configuration and restart indexer service.

  • /ws-services/wc/_update should be added as the update endpoint. This method is used to update fields in existing records or to update the status of the application based on workflow.

    egov.waterservice.createwaterconnection

    This variable contains the kafka topic name which is used to create new water connection application in the system.

    egov.waterservice.updatewaterconnection

    This variable contains the kafka topic name which is used to update the existing water connection application in the system.

    egov.waterservice.updatewaterconnection.workflow.topic

    This variable contains the kafka topic name which is used to update the process instance of the water connection application.

    egov.idgen.wcapid.name

    This variable contains the idgen format name for water application

    egov.idgen.wcapid.format

    This variable contains the idgen format for water application ex:- WS/[CITY.CODE]/[fy:yyyy-yy]/[SEQ_EGOV_COMMON]

    egov.idgen.wcid.name

    This variable contains the idgen format name for water connection

    API Swagger Documentation

    Swagger Documentation

    Water Calculator Service

    Water-Service Calculator

    /ws-services/wc/_create

    https://www.getpostman.com/collections/b7f8f02e80eec21f926d

    /ws-services/wc/_update

    https://www.getpostman.com/collections/b7f8f02e80eec21f926d

    /ws-services/wc/_search

    https://www.getpostman.com/collections/b7f8f02e80eec21f926d

    /ws-services/wc/_submitfeedback

    https://www.getpostman.com/collections/b7f8f02e80eec21f926d

    /ws-services/wc/_getfeedback

    https://www.getpostman.com/collections/b7f8f02e80eec21f926d

    /ws-services/wc/_revenueDashboard

    https://www.getpostman.com/collections/d79438f50b433917269d

    mdms-mgramseva/data at DEV · egovernments/egov-mdms-data
    mdms-mgramseva/PTWorkflow.json at DEV · egovernments/egov-mdms-data
    config-mgramseva/water-persist.yml at DEV · egovernments/configs
    configs/water-meter.yml at master · egovernments/configs
    config-mgramseva/water-service.yml at DEV · egovernments/config-mgramseva
    config-mgramseva/water-service.yml at DEV · egovernments/config-mgramseva
    GitHub - egovernments/configs at master

    /ws-services/wc/_revenueCollectionData

    "ws-services-masters": {
        "connectionCategory": {
          "masterName": "connectionCategory",
          "isStateLevel": true,
          "uniqueKeys": [
            "$.code"
          ]
        },
        "connectionType": {
          "masterName": "connectionType",
          "isStateLevel": true,
          "uniqueKeys": [
            "$.code"
          ]
        },
        "waterSource": {
          "masterName": "waterSource",
          "isStateLevel": true,
          "uniqueKeys": [
            "$.code"
          ]
        },
        "billingPeriod": {
          "masterName": "billingPeriod",
          "isStateLevel": true,
          "uniqueKeys": [
            "$.billingCycle"
          ]
        },
        "waterSourceWithSubSource": {
          "masterName": "waterSourceWithSubSource",
          "isStateLevel": true,
          "uniqueKeys": []
        }
      },
      "ws-services-calculation": {
        "WaterCess": {
          "masterName": "WaterCess",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "Interest": {
          "masterName": "Interest",
          "isStateLevel": true,
          "uniqueKeys": [
            "$.fromFY"
          ]
        },
        "Rebate": {
          "masterName": "Rebate",
          "isStateLevel": true,
          "uniqueKeys": [
            "$.fromFY"
          ]
        },
        "Penalty": {
          "masterName": "Penalty",
          "isStateLevel": true,
          "uniqueKeys": [
            "$.fromFY"
          ]
        },
        "WCBillingSlab": {
          "masterName": "WCBillingSlab",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "WS_CHARGE": {
          "masterName": "WS_CHARGE",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "WS_TIME_PENALTY": {
          "masterName": "WS_TIME_PENALTY",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "WS_WATER_CESS": {
          "masterName": "WS_WATER_CESS",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "MeterStatus": {
          "masterName": "MeterStatus",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "WS_Round_Off": {
          "masterName": "WS_Round_Off",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "PlotSizeSlab": {
          "masterName": "PlotSizeSlab",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "PropertyUsageType": {
          "masterName": "PropertyUsageType",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "FeeSlab": {
          "masterName": "FeeSlab",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "RoadType": {
          "masterName": "RoadType",
          "isStateLevel": true,
          "uniqueKeys": []
        },
        "CalculationAttribute": {
          "masterName": "CalculationAttribute",
          "isStateLevel": true,
          "uniqueKeys": []
        }
      }
    {
      "tenantId": "pb",
      "moduleName": "ws-services-masters",
      "connectionType": [
        {
          "name": "Metered",
          "code": "Metered",
          "active": true
        },
        {
          "name": "Non Metered",
          "code": "Non_Metered",
          "active": true
        }
      ]
    }
    {
    	"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"
    			]
    		}
    	]
    }
    {
      "tenantId": "pb",
      "moduleName": "ws-services-masters",
      "Category": [
        {
          "code": "APL",
          "name": "APL"
        },
        {
          "code": "BPL",
          "name": "BPL"
        }
      ]
    }
    {
      "tenantId": "pb",
      "moduleName": "ws-services-masters",
      "SubCategory": [
        {
          "code": "SC",
          "name": "SC"
        },
         {
          "code": "ST",
          "name": "ST"
        },
        {
          "code": "GENERAL",
          "name": "General"
        }
      ]
    }
    [
      {
          "id": {{PLACEHOLDER1}},
          "name": "Create Water Connection",
          "url": "/ws-services/wc/_create",
          "displayName": "Create Water COnnection",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER2}},
          "name": "Search Water Connection",
          "url": "/ws-services/wc/_search",
          "displayName": "Search Water COnnection",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
        {
          "id": {{PLACEHOLDER3}},
          "name": "Update Water Connection",
          "url": "/ws-services/wc/_update",
          "displayName": "Update Water COnnection",
          "orderNumber": 0,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
       {
          "id": {{PLACEHOLDER4}},
          "name": " feedback create",
          "url": "/ws-services/wc/_submitfeedback",
          "parentModule": "",
          "displayName": "create feedback",
          "orderNumber": 2,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        },
    	{
          "id": {{PLACEHOLDER5}},
          "name": " feedback search",
          "url": "/ws-services/wc/_getfeedback",
          "parentModule": "",
          "displayName": "get feedback",
          "orderNumber": 2,
          "enabled": false,
          "serviceCode": "ws-services",
          "code": "null",
          "path": ""
        }
    ]
    
    [
     
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER1}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "SUPERUSER",
          "actionid": {{PLACEHOLDER1}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER1}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "SUPERUSER",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "COLLECTION_OPERATOR",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "BULK_DEMAND_PROCESSING",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "EXPENSE_PROCESSING",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "DASHBOARD_VIEWER",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        }, 
        {
          "rolecode": "EMPLOYEE",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "COLLECTION_OPERATOR",
          "actionid": {{PLACEHOLDER2}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "EMPLOYEE",
          "actionid": {{PLACEHOLDER3}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER3}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "SUPERUSER",
          "actionid": {{PLACEHOLDER3}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER3}},
          "actioncode": "",
          "tenantId": "pb"
        },
        {
          "rolecode": "GP_ADMIN",
          "actionid": {{PLACEHOLDER5}},
          "actioncode": "",
          "tenantId": "pb"
        }
    ]
    
    
    		{
          "code": "GP_ADMIN",
          "name": "GP Admin",
          "description": "Who has a access to ws-services"
        },
    		{
          "code": "COLLECTION_OPERATOR",
          "name": "Collection Operator",
          "description": "Who has a access to ws-services,demand, bill and payment"
        },
    		{
          "code": "BULK_DEMAND_PROCESSING",
          "name": "Bulk Demand Processing",
          "description": "Who has a access to bulk demand generation,raise bill, downloa bill and receipts"
        },
    		{
          "code": "EXPENSE_PROCESSING",
          "name": "Expense Processing",
          "description": "Who has a access to create and update expenses"
        },
    		{
          "code": "DASHBOARD_VIEWER",
          "name": "Dashbaord Viewer",
          "description": "Who has a access to dashboard of revenue and expenditure"
        }
    {
      "RequestInfo": {
        "apiId": "Rainmaker",
        "action": "",
        "did": 1,
        "key": "",
        "msgId": "20170310130900|en_IN",
        "requesterId": "",
        "ts": 1513579888683,
        "ver": ".01",
        "authToken": "{{Auth_Token}}"
      },
      "BusinessServices": [
        {
          "tenantId": "pb",
          "businessService": "NewWS1",
          "business": "WS",
          "businessServiceSla": 0,
          "states": [
            {
              "tenantId": "pb",
              "sla": null,
              "state": null,
              "applicationStatus": "DRAFT",
              "docUploadRequired": false,
              "isStartState": true,
              "isTerminateState": false,
              "isStateUpdatable": false,
              "actions": [
                {
                  "tenantId": "pb",
                  "action": "SUBMIT",
                  "nextState": "APPROVE",
                  "roles": [
                    "GP_ADMIN"
                  ],
                  "active": true
                }
              ]
            },
            {
              "tenantId": "pb",
              "sla": null,
              "state": "APPROVED",
              "applicationStatus": "ACTIVE",
              "docUploadRequired": false,
              "isStartState": false,
              "isTerminateState": true,
              "isStateUpdatable": true,
              "actions": null
            }
          ]
        }
      ]
    }
    https://www.getpostman.com/collections/d79438f50b433917269d