diff --git a/gcc_officer_portal/src/main/java/in/gov/chennaicorporation/gccoffice/callcenterqaqc/controller/SocialMediaApiController.java b/gcc_officer_portal/src/main/java/in/gov/chennaicorporation/gccoffice/callcenterqaqc/controller/SocialMediaApiController.java index bb3244d0..79dd3795 100644 --- a/gcc_officer_portal/src/main/java/in/gov/chennaicorporation/gccoffice/callcenterqaqc/controller/SocialMediaApiController.java +++ b/gcc_officer_portal/src/main/java/in/gov/chennaicorporation/gccoffice/callcenterqaqc/controller/SocialMediaApiController.java @@ -274,7 +274,7 @@ public class SocialMediaApiController { String url="https://erp.chennaicorporation.gov.in/pgr/newmobileservice?serviceId=ms_dashboard_details&From_date="+formattedFromDate+"&To_date="+formattedToDate+"&jsonResp=Yes&Status="+status+"&isQcuser=Yes"+"&ComplaintType="+type+"&ComplaintGroupId="+group+"&compmode="+mode+"&Zoneid="+zone+"&RegionId="+region; - System.out.println("url==="+url); + //System.out.println("url==="+url); RestTemplate restTemplate = new RestTemplate(); @@ -291,7 +291,7 @@ public class SocialMediaApiController { Map responseMap = objectMapper.readValue(rawResponse, Map.class); List> details; details = (List>) responseMap.get("Details"); - System.out.println("details="+details); + //System.out.println("details="+details); if (details != null) { diff --git a/gcc_officer_portal/src/main/java/in/gov/chennaicorporation/gccoffice/callcenterqaqc/service/SocialMediaService.java b/gcc_officer_portal/src/main/java/in/gov/chennaicorporation/gccoffice/callcenterqaqc/service/SocialMediaService.java index 9e4b2fd7..325b41f8 100644 --- a/gcc_officer_portal/src/main/java/in/gov/chennaicorporation/gccoffice/callcenterqaqc/service/SocialMediaService.java +++ b/gcc_officer_portal/src/main/java/in/gov/chennaicorporation/gccoffice/callcenterqaqc/service/SocialMediaService.java @@ -524,7 +524,8 @@ public class SocialMediaService { //System.out.println("currentStatus==="+currentStatus); - if ("REGISTERED".equalsIgnoreCase(currentStatus)) { + if ("REGISTERED".equalsIgnoreCase(currentStatus) + || "FORWARDED".equalsIgnoreCase(currentStatus)) { Map resultRow = new HashMap<>(); diff --git a/gcc_officer_portal/src/main/resources/templates/modules/callcenterqaqc/socialmediacomplaints.html b/gcc_officer_portal/src/main/resources/templates/modules/callcenterqaqc/socialmediacomplaints.html index 4d42974a..8812db6c 100644 --- a/gcc_officer_portal/src/main/resources/templates/modules/callcenterqaqc/socialmediacomplaints.html +++ b/gcc_officer_portal/src/main/resources/templates/modules/callcenterqaqc/socialmediacomplaints.html @@ -883,7 +883,7 @@ // Update modal content document.getElementById('modalBody').innerHTML = detailsHtml; - // Check Registered Complaint Closing Section + // // Show only for REGISTERED or FORWARDED complaints loadRegCompSection(data.complaintid, data.currentStatus); }, error: function () { @@ -897,7 +897,7 @@ }); } - function submitRegClosingComplaint(complaintNumber) { + function submitRegClosingComplaint(complaintNumber,currentStatus) { const reg_remarks = $('#closingRemarks').val().trim(); const fileInput = $('#resolvedImage')[0]; @@ -1000,7 +1000,7 @@ text: response.message }).then(() => { - loadRegCompSection(complaintNumber, 'REGISTERED'); + loadRegCompSection(complaintNumber, currentStatus); }); @@ -1037,10 +1037,12 @@ // Hide by default $('#regCompHtml').html(''); - // Show only for REGISTERED complaints - if (currentStatus !== 'REGISTERED') { - return; - } + // // Show only for REGISTERED or FORWARDED complaints + const allowedStatuses = ['REGISTERED', 'FORWARDED']; + + if (!allowedStatuses.includes(currentStatus)) { + return; + } $.ajax({ url: '/gcc/api/callcenterqaqc/socialmedia/checkregisteredcomplaint', @@ -1076,7 +1078,7 @@