TL Service Renewal Upgradation Keypoint
Things to be taken care-of while upgrading TL service
MDMS Entries
In renewal process, the financial year for the application is change to next financial year,So the new financial year valid-from and valid-to value which is getting from this mdms file https://github.com/egovernments/egov-mdms-data/blob/master/data/pb/BillingService/TaxPeriod.json must be grater than previous financial year valid from and valid to value.
Example:-
Year | Valid From | Valid To |
2019 - 20 | 1554076799000 | 1585679399000 |
2020 - 21 | 1590969600000 | 1617172199000 |
For the corresponding financial year, valid-from value must be smaller than the valid-to value.The next financial year valid-from value must be greater than previous financial year valid-to value. And also make sure that this following mdms file are updated with proper entries https://github.com/egovernments/egov-mdms-data/blob/master/data/pb/TradeLicense/TradeType.json https://github.com/egovernments/egov-mdms-data/blob/master/data/pb/TradeLicense/AccessoriesCategory.json
For other mdms changes refer this confluence document
TL Renewal Technical Documentation
Notification
Before upgrading TL service make sure that Notification is disable to avoid unnecessary notification to user and also make sure that there is no data in the kafka topic egov.collection.payment-create
Business service value in table
After upgrading the TL service, businesservice column is added into eg_tl_tradelicense table. By Default its value is null and it can be change to value “TL” if required by running the SQL update query.
Report and Indexer changes
If TL Service and BPA Service both deploy in Punjab environment then for tl-service, in report config condition of businesservice =’TL’ has to add in sql query and in indexer config business service filter has to add. For the BPA service made the same changes mentioned above with proper businesservice value.
Change in value of column ‘applicationtype’ of 'eg_tl_tradelicense' table
In eg_tl_tradelicensedetail table, for the application whose value in additional details json is set as APPLICATIONTYPE.RENEWAL under the key applicationType.
For those application, set the column value of applicationtype in eg_tl_tradelicense table as RENEWAL
SQL query to carry out the above mentioned task:-
UPDATE public.eg_tl_tradelicense SET applicationtype= 'RENEWAL'
WHERE id in (select tradelicenseid from public.eg_tl_tradelicensedetail
where additionaldetail->>'applicationType' = 'APPLICATIONTYPE.RENEWAL');
Change in value of column ‘status’ of ‘egbs_demand_v1' table
In egbs_demand_v1 table for businessservice = 'TL' demand status is empty, for those application their corresponding recent demand should have the status as ACTIVE.
SQL query to carry out the above mentioned task:-
UPDATE egbs_demand_v1 SET status = 'ACTIVE' FROM (SELECT consumercode,
taxperiodfrom,taxperiodto, MAX(lastmodifiedtime) AS MAXTIME FROM egbs_demand_v1
GROUP BY consumercode,taxperiodfrom,taxperiodto) AS demand WHERE egbs_demand_v1.taxperiodfrom = demand.taxperiodfrom
AND egbs_demand_v1.taxperiodto = demand.taxperiodto AND egbs_demand_v1.lastmodifiedtime >= demand.MAXTIME AND
egbs_demand_v1.consumercode = demand.consumercode AND egbs_demand_v1.businessservice = 'TL';