Objective:- To provide employees(Admin) with the functionality to change the property details or to change the demand.

  1. only user with the PTADMIN role has the right to change the property

  2. the Property should be in active state

Change the property details

  1. login with Admin employee

  2. goto property details page if role is “PTADMIN“ and property is active you will get two action button “EDIT PROPERTY” and “EDIT DEMAND”

  3. click on the “EDIT PROPERTY” and update the property details.

Change the demand

  1. login with Admin employee

  2. goto property details page if role is “PTADMIN“ and property is active you will get two action button “EDIT PROPERTY” and “EDIT DEMAND”

  3. click on the “EDIT DEMAND” and update the property demand.

Technical Implementation Details:

Update property and edit demand button can be found in the link given below:

DIGIT-UKD/index.js

here the main changes are ifUserRoleExists("PTADMIN") then show the button visibility and on click redirect to specific page and add the assessment as true as shown below.

1if (ifUserRoleExists("PTCEMP")) { 2 redirectTo = redirectTo + "&assessment=true"; 3 }

if click on the “EDIT PROPERTY“ will redirect to

https://github.com/eNagarsewaU/DIGIT-UKD/blob/bdd6617e235013725189c0565e358870cdbbfd2e/frontend/mono-ui/web/rainmaker/dev-packages/pt-employee-dev/src/Screens/FormWizard/index.js

It works same as update property

if click on the “EDIT DEMAND“ will redirect to

https://github.com/eNagarsewaU/DIGIT-UKD/blob/b18975b569441c8b838a142373eaa1f6aa1f57ff/frontend/mono-ui/web/rainmaker/dev-packages/pt-employee-dev/src/Screens/DCB/index.js

here if the assessment is true then we can only change the property tax, swachata tax and interest only

we cannot decrease the all three fields on decreasing it will pop the alert. and validation are added when we click on update for same

dev-packages/egov-ui-kit-dev/src/common/propertyTax/DemandCollection/index.js

1 if(isAssesment){ 2 if ( 3 (taxData.code === "PT_TAX") && 4 get(preparedFinalObject, `DemandPropertiesResponse.Demands[${index}].demandDetails[0].taxAmount`) > 5 e.target.value 6 ) { 7 alert("Tax value cannot be decrease"); 8 } 9 }


dev-packages/pt-employee-dev/src/Screens/DCB/index.js

1 if (isAssesment) { 2 errorCode = "FINE"; 3 let demandResponse = DemandPropertiesResponse.Demands 4 demand.map((item,index)=>{ 5 let data = item.demand[Object.keys(item.demand)] 6 data.map((ele,i)=>{ 7 if(ele.PT_TAXHEAD === "PT_TAX" || ele.PT_TAXHEAD ==="SWATCHATHA_TAX" || ele.PT_TAXHEAD === "PT_TIME_INTEREST"){ 8 9 try{ 10 if(i < demandResponse[index].demandDetails.length && ele.PT_DEMAND < demandResponse[index].demandDetails[i].taxAmount){ 11 errorCode = "ERR09_DEMAND_ENTER_THE_DATA"; 12 } 13 }catch(e){ 14 errorCode = "ERR09_DEMAND_ENTER_THE_DATA"; 15 } 16 17 } 18 }) 19 }) 20 }