Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Current »

Overview

Water Connection Penalty changes are added to get the penalty amount after due date. The due date is configurable and penalty enable and disable is 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 water service persister configs path added in it

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

  • Following services should be up and running:

    • egov-perister

    • egov-mdms

    • ws-services

    • billing-service

Key Functionalities

  • Calculate water charge and taxes based on 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 config folder in git and add that path in persister . (The file path is to be added in environment yaml file in param called persist-yml-path )

Configuration Details

MDMS Configuration

Billing Service tax head configuration

 

 {
      "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
    },

ws Calculator penalty configuration:

We have Total 4 types of penalty:

Fixed - Current month: This is the penalty will be applied on the current month amount based on the rate (%) given in the configuration.

{
  "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"
    }
  ]
}

Fixed - outstanding: This is the penalty applied on the total pending amount till the current month amount based on the rate (%) given in the configuration.

{
  "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"
    }
  ]
}

Flat - Current month: This is the penalty will be applied on the current month amount based on the amount given in the configuration.

{
  "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"
    }
  ]
}

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

{
  "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 to create:

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": "vasanth.arun.95@gmail.com",
            "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"
        }
    }
}'

  • No labels

0 Comments

You are not logged in. Any changes you make will be marked as anonymous. You may want to Log In if you already have an account.