commit
9eaaaa8b07
63 changed files with 9094 additions and 0 deletions
-
13src/main/java/com/gcc/commissionerreview/DashboardserviceApplication.java
-
83src/main/java/com/gcc/commissionerreview/configuration/DataSourceConfig.java
-
38src/main/java/com/gcc/commissionerreview/configuration/PrimaryDataSourceConfig.java
-
31src/main/java/com/gcc/commissionerreview/configuration/SecondaryDataSourceConfig.java
-
26src/main/java/com/gcc/commissionerreview/controller/CompoundWallController.java
-
54src/main/java/com/gcc/commissionerreview/controller/EnforcementApiController.java
-
152src/main/java/com/gcc/commissionerreview/controller/MainController.java
-
31src/main/java/com/gcc/commissionerreview/controller/ParksApiController.java
-
31src/main/java/com/gcc/commissionerreview/controller/PlayFieldController.java
-
41src/main/java/com/gcc/commissionerreview/controller/SofaBedCollectionApiController.java
-
29src/main/java/com/gcc/commissionerreview/controller/ToiletController.java
-
29src/main/java/com/gcc/commissionerreview/controller/UphcReportController.java
-
73src/main/java/com/gcc/commissionerreview/controller/VeterinaryPetClinicApiController.java
-
50src/main/java/com/gcc/commissionerreview/controller/makkaludanMudalvarController.java
-
36src/main/java/com/gcc/commissionerreview/controller/mobileDiagonosticController.java
-
50src/main/java/com/gcc/commissionerreview/controller/mudhalvarinMugavariController.java
-
53src/main/java/com/gcc/commissionerreview/controller/urbangreenController.java
-
61src/main/java/com/gcc/commissionerreview/service/CompoundWallService.java
-
300src/main/java/com/gcc/commissionerreview/service/EnforcementService.java
-
65src/main/java/com/gcc/commissionerreview/service/ParksService.java
-
56src/main/java/com/gcc/commissionerreview/service/PlayFieldService.java
-
395src/main/java/com/gcc/commissionerreview/service/SofaBedCollectionService.java
-
142src/main/java/com/gcc/commissionerreview/service/ToiletService.java
-
54src/main/java/com/gcc/commissionerreview/service/UphcReportService.java
-
267src/main/java/com/gcc/commissionerreview/service/VeterinaryPetClinicService.java
-
46src/main/java/com/gcc/commissionerreview/service/makkaludanMudalvarService.java
-
75src/main/java/com/gcc/commissionerreview/service/mobileDiagonosticService.java
-
44src/main/java/com/gcc/commissionerreview/service/mudhalvarinMugavariService.java
-
39src/main/java/com/gcc/commissionerreview/service/urbangreenService.java
-
18src/main/resources/application-dev.properties
-
36src/main/resources/application-prod.properties
-
36src/main/resources/application-test.properties
-
1src/main/resources/application.properties
-
35src/main/resources/templates/fragments/script.html
-
91src/main/resources/templates/modules/C&DWasteProcessing.html
-
113src/main/resources/templates/modules/GardenandTenderCoconutWaste.html
-
82src/main/resources/templates/modules/ReviewofBioCNGPlants.html
-
209src/main/resources/templates/modules/combined_bio_mining_report.html
-
143src/main/resources/templates/modules/compoundwall.html
-
759src/main/resources/templates/modules/enforcement/Zonewise.html
-
108src/main/resources/templates/modules/landacquisitionprogress.html
-
274src/main/resources/templates/modules/makkaludanmudhalvar.html
-
184src/main/resources/templates/modules/micro_compost_centre.html
-
224src/main/resources/templates/modules/mobileDiagonosticreports.html
-
228src/main/resources/templates/modules/mudhalvarinmugavari.html
-
215src/main/resources/templates/modules/parks.html
-
229src/main/resources/templates/modules/perungudibiomining.html
-
154src/main/resources/templates/modules/playfield.html
-
119src/main/resources/templates/modules/slaughterhouse.html
-
662src/main/resources/templates/modules/sofa_bed/zonewise.html
-
687src/main/resources/templates/modules/sofa_bed/zonewise1.html
-
281src/main/resources/templates/modules/solidwastemanagement.html
-
114src/main/resources/templates/modules/srgmprojectsprogress.html
-
310src/main/resources/templates/modules/streetnameprogress.html
-
197src/main/resources/templates/modules/toilet.html
-
158src/main/resources/templates/modules/trafficsystems.html
-
300src/main/resources/templates/modules/uphcreport.html
-
203src/main/resources/templates/modules/urbangreenreport.html
-
93src/main/resources/templates/modules/veterinary/abccenters.html
-
196src/main/resources/templates/modules/veterinary/cattlecatch.html
-
132src/main/resources/templates/modules/veterinary/meatraidreport.html
-
126src/main/resources/templates/modules/veterinary/petclinic.html
-
13src/test/java/com/gcc/commissionerreview/DashboardserviceApplicationTests.java
@ -0,0 +1,13 @@ |
|||||
|
package com.gcc.commissionerreview; |
||||
|
|
||||
|
import org.springframework.boot.SpringApplication; |
||||
|
import org.springframework.boot.autoconfigure.SpringBootApplication; |
||||
|
|
||||
|
@SpringBootApplication |
||||
|
public class DashboardserviceApplication { |
||||
|
|
||||
|
public static void main(String[] args) { |
||||
|
SpringApplication.run(DashboardserviceApplication.class, args); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,83 @@ |
|||||
|
package com.gcc.commissionerreview.configuration; |
||||
|
|
||||
|
|
||||
|
import com.zaxxer.hikari.HikariConfig; |
||||
|
import com.zaxxer.hikari.HikariDataSource; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.beans.factory.annotation.Value; |
||||
|
import org.springframework.context.annotation.Bean; |
||||
|
import org.springframework.context.annotation.Configuration; |
||||
|
import org.springframework.context.annotation.Primary; |
||||
|
import org.springframework.jdbc.datasource.DataSourceTransactionManager; |
||||
|
import org.springframework.jdbc.datasource.DriverManagerDataSource; |
||||
|
import org.springframework.transaction.PlatformTransactionManager; |
||||
|
import org.springframework.transaction.annotation.EnableTransactionManagement; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
@Configuration |
||||
|
@EnableTransactionManagement |
||||
|
public class DataSourceConfig { |
||||
|
|
||||
|
|
||||
|
private static String host = "localhost:3306"; |
||||
|
private static String dbpassword = "root"; |
||||
|
|
||||
|
|
||||
|
// private static String host = "gcc-facial-db-instance-1.cf48eqcciziq.ap-south-1.rds.amazonaws.com:3306"; |
||||
|
// private static String dbpassword = "gcc-facial-password"; |
||||
|
|
||||
|
|
||||
|
public static class MyDataSourceConfig { |
||||
|
@Primary |
||||
|
@Bean(name = "mydatasource") |
||||
|
public DataSource MyDataSource() { |
||||
|
// DriverManagerDataSource dataSource = new DriverManagerDataSource(); |
||||
|
// dataSource.setDriverClassName("com.mysql.cj.jdbc.Driver"); |
||||
|
// dataSource.setUrl("jdbc:mysql://"+host+"/dashboard_service"); |
||||
|
// dataSource.setUsername("root"); |
||||
|
// dataSource.setPassword("root"); |
||||
|
// return dataSource; |
||||
|
|
||||
|
DriverManagerDataSource dataSource = new DriverManagerDataSource(); |
||||
|
dataSource.setUrl("jdbc:mysql://"+host+"/commissioner_review"); |
||||
|
dataSource.setUsername("root"); |
||||
|
dataSource.setPassword(dbpassword); |
||||
|
dataSource.setDriverClassName("com.mysql.cj.jdbc.Driver"); |
||||
|
return dataSource; |
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
@Primary |
||||
|
@Bean(name = "myTransactionManager") |
||||
|
public PlatformTransactionManager myTransactionManager(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
return new DataSourceTransactionManager(dataSource); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
////////////////////////////// Domestic Waste Management //////////////////////// |
||||
|
@Bean(name = "mysqlSofaBedCollectionDataSource") |
||||
|
public DataSource mysqlSofaBedCollectionDataSource() { |
||||
|
DriverManagerDataSource dataSource = new DriverManagerDataSource(); |
||||
|
dataSource.setDriverClassName("com.mysql.cj.jdbc.Driver"); |
||||
|
dataSource.setUrl("jdbc:mysql://"+host+"/domestic_waste_management"); |
||||
|
dataSource.setUsername("root"); |
||||
|
dataSource.setPassword(dbpassword); |
||||
|
return dataSource; |
||||
|
} |
||||
|
|
||||
|
|
||||
|
//////////////////////////////ORACLE //////////////////////// |
||||
|
@Bean(name = "oracleDataSource") |
||||
|
public DataSource oracleDataSource() { |
||||
|
DriverManagerDataSource dataSource = new DriverManagerDataSource(); |
||||
|
dataSource.setDriverClassName("oracle.jdbc.OracleDriver"); |
||||
|
dataSource.setUrl("jdbc:oracle:thin:@10.1.0.14:1521:chncorp"); |
||||
|
dataSource.setUsername("FAS"); |
||||
|
dataSource.setPassword("FAS"); |
||||
|
return dataSource; |
||||
|
} |
||||
|
} |
||||
|
|
||||
@ -0,0 +1,38 @@ |
|||||
|
package com.gcc.commissionerreview.configuration; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.boot.context.properties.ConfigurationProperties; |
||||
|
import org.springframework.boot.jdbc.DataSourceBuilder; |
||||
|
import org.springframework.context.annotation.Bean; |
||||
|
import org.springframework.context.annotation.Configuration; |
||||
|
import org.springframework.context.annotation.Primary; |
||||
|
import org.springframework.data.jdbc.repository.config.EnableJdbcRepositories; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.transaction.annotation.EnableTransactionManagement; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
|
||||
|
@Configuration |
||||
|
@EnableTransactionManagement |
||||
|
// @EnableJdbcRepositories( |
||||
|
// basePackages = "com.gcc.commissionerreview.configuration", |
||||
|
// jdbcOperationsRef = "primaryJdbcTemplate" |
||||
|
// ) |
||||
|
public class PrimaryDataSourceConfig { |
||||
|
|
||||
|
@Primary |
||||
|
@Bean(name = "primaryDataSource") |
||||
|
@ConfigurationProperties(prefix = "spring.datasource") |
||||
|
public DataSource primaryDataSource() { |
||||
|
return DataSourceBuilder.create().build(); |
||||
|
} |
||||
|
|
||||
|
@Primary |
||||
|
@Bean(name = "primaryJdbcTemplate") |
||||
|
public JdbcTemplate primaryJdbcTemplate(@Qualifier("primaryDataSource") DataSource ds) { |
||||
|
return new JdbcTemplate(ds); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
|
||||
@ -0,0 +1,31 @@ |
|||||
|
package com.gcc.commissionerreview.configuration; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.boot.context.properties.ConfigurationProperties; |
||||
|
import org.springframework.boot.jdbc.DataSourceBuilder; |
||||
|
import org.springframework.context.annotation.Bean; |
||||
|
import org.springframework.context.annotation.Configuration; |
||||
|
import org.springframework.data.jdbc.repository.config.EnableJdbcRepositories; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
@Configuration |
||||
|
//@EnableJdbcRepositories( |
||||
|
// basePackages = "com.gcc.commissionerreview.configuration", |
||||
|
// jdbcOperationsRef = "secondaryJdbcTemplate" |
||||
|
//) |
||||
|
public class SecondaryDataSourceConfig { |
||||
|
|
||||
|
@Bean(name = "secondaryDataSource") |
||||
|
@ConfigurationProperties(prefix = "secondary.datasource") |
||||
|
public DataSource secondaryDataSource() { |
||||
|
return DataSourceBuilder.create().build(); |
||||
|
} |
||||
|
|
||||
|
@Bean(name = "secondaryJdbcTemplate") |
||||
|
public JdbcTemplate secondaryJdbcTemplate(@Qualifier("secondaryDataSource") DataSource ds) { |
||||
|
return new JdbcTemplate(ds); |
||||
|
} |
||||
|
} |
||||
|
|
||||
@ -0,0 +1,26 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.CompoundWallService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/api/compoundwall") |
||||
|
public class CompoundWallController { |
||||
|
|
||||
|
@Autowired |
||||
|
private CompoundWallService compoundWallService; |
||||
|
|
||||
|
@GetMapping("/getCompoundWall") |
||||
|
public List<Map<String, Object>> getCompoundWall() { |
||||
|
return compoundWallService.getCompoundWallSummaryByZone(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/issues/{zone}") |
||||
|
public List<Map<String, Object>> getCompoundWallIssuesByZone(@PathVariable int zone) { |
||||
|
return compoundWallService.getPlayfieldsWithCompoundWallIssuesByZone(zone); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,54 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.EnforcementService; |
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/api/enforcement") |
||||
|
public class EnforcementApiController { |
||||
|
|
||||
|
@Autowired |
||||
|
private EnforcementService enforcementService; |
||||
|
|
||||
|
|
||||
|
@GetMapping("/getZoneWiseDetails") |
||||
|
public List<Map<String, Object>> getZonewisedetails() |
||||
|
{ |
||||
|
return enforcementService.getzonewisedetails(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/getWardWiseDetails") |
||||
|
public List<Map<String, Object>> getWardwisedetails(@RequestParam String zone) |
||||
|
{ |
||||
|
return enforcementService.getwardwisedetails(zone); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/getFormDetails") |
||||
|
public List<Map<String, Object>> getFormdetails(@RequestParam String ward,@RequestParam String zone,@RequestParam String formtype,@RequestParam String status) |
||||
|
{ |
||||
|
return enforcementService.getformdetailswithzone(zone,ward,formtype,status); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/getFormDetailsWithoutWard") |
||||
|
public List<Map<String, Object>> getFormdetailsWithoutWard(@RequestParam String zone,@RequestParam String formtype,@RequestParam String status) |
||||
|
{ |
||||
|
return enforcementService.getformdetailswithoutward(zone,formtype,status); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
@GetMapping("/getFormId") |
||||
|
public List<Map<String, Object>> getFormIddetails(@RequestParam String formid) |
||||
|
{ |
||||
|
return enforcementService.getformiddetails(formid); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,152 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import org.springframework.ui.Model; |
||||
|
import org.springframework.stereotype.Controller; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
|
||||
|
@Controller |
||||
|
@RequestMapping(value = {"/commissionerreview"}) |
||||
|
public class MainController { |
||||
|
|
||||
|
@GetMapping("/uphcreport") |
||||
|
public String uphcreport(Model model) { |
||||
|
return "modules/uphcreport"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/perungudibiomining") |
||||
|
public String perungudibiomining(Model model) { |
||||
|
return "modules/perungudibiomining"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/streetnameprogress") |
||||
|
public String streetnameprogress(Model model) { |
||||
|
return "modules/streetnameprogress"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/mobileDiagonostic") |
||||
|
public String mobileDiagonostic(Model model) { |
||||
|
return "modules/mobileDiagonosticreports"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/cattlecatch") |
||||
|
public String viewcattlecatchpage(Model model) { |
||||
|
return "modules/veterinary/cattlecatch"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/petclinic") |
||||
|
public String veterinarypetclinic(Model model) { |
||||
|
return "modules/veterinary/petclinic"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/abccenters") |
||||
|
public String veterinaryabccenters(Model model) { |
||||
|
return "modules/veterinary/abccenters"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/makkaludanmudhalvar") |
||||
|
public String viewmakkaludanmudhalvar(Model model) { |
||||
|
return "modules/makkaludanmudhalvar"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/mudhalvarinmugavari") |
||||
|
public String viewmudhalvarinmugavari(Model model) { |
||||
|
return "modules/mudhalvarinmugavari"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/combinedbiomining") |
||||
|
public String viewcombinedbiomining(Model model) { |
||||
|
return "modules/combined_bio_mining_report"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/microcompostcentre") |
||||
|
public String viewmicrocompostcentre(Model model) { |
||||
|
return "modules/micro_compost_centre"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/srgmprojectsprogress") |
||||
|
public String srgmprojectsprogress(Model model) { |
||||
|
return "modules/srgmprojectsprogress"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/landacquisitionprogress") |
||||
|
public String landacquisitionprogress(Model model) { |
||||
|
return "modules/landacquisitionprogress"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/CDWasteProcessing") |
||||
|
public String cdWasteProcessing(Model model) { |
||||
|
return "modules/C&DWasteProcessing"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/GardenandTenderCoconutWaste") |
||||
|
public String GardenandTenderCoconutWaste(Model model) { |
||||
|
return "modules/GardenandTenderCoconutWaste"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/ReviewofBioCNGPlants") |
||||
|
public String ReviewofBioCNGPlants(Model model) { |
||||
|
return "modules/ReviewofBioCNGPlants"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/trafficsystems") |
||||
|
public String trafficsystems(Model model) { |
||||
|
return "modules/trafficsystems"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/slaughterhouse") |
||||
|
public String slaughterhouse(Model model) { |
||||
|
return "modules/slaughterhouse"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/meatraid") |
||||
|
public String viewmeatraid(Model model) { |
||||
|
return "modules/veterinary/meatraidreport"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/solidwastemanagement") |
||||
|
public String viewswdpage(Model model) { |
||||
|
return "modules/solidwastemanagement"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/toilet") |
||||
|
public String toilet(Model model) { |
||||
|
return "modules/toilet"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/playfield") |
||||
|
public String playfield(Model model) { |
||||
|
return "modules/playfield"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/urbangreen") |
||||
|
public String viewurbangreen(Model model) { |
||||
|
return "modules/urbangreenreport"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/compoundwall") |
||||
|
public String compoundwall(Model model) { |
||||
|
return "modules/compoundwall"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/parks") |
||||
|
public String viewparkspage(Model model) { |
||||
|
return "modules/parks"; |
||||
|
} |
||||
|
|
||||
|
|
||||
|
//////////////////////////////////// |
||||
|
|
||||
|
|
||||
|
@GetMapping("/enforcement") |
||||
|
public String viewenforcementpage(Model model) { |
||||
|
return "modules/enforcement/Zonewise"; |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/sofacollection") |
||||
|
public String sofaZoneReport(Model model) { |
||||
|
return "modules/sofa_bed/zonewise1"; |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,31 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.ParksService; |
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/api/parks") |
||||
|
public class ParksApiController { |
||||
|
|
||||
|
@Autowired |
||||
|
public ParksService parksService; |
||||
|
|
||||
|
@GetMapping("/getParkData") |
||||
|
public List<Map<String,Object>> getParkData(){ |
||||
|
return parksService.getParkData(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/getParkDataByZone") |
||||
|
public List<Map<String,Object>> getParkDataByZone(@RequestParam String zone, @RequestParam String type){ |
||||
|
return parksService.getParkDataByZone(zone, type); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,31 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.PlayFieldService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.stereotype.Controller; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.PathVariable; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/api/playfield") |
||||
|
public class PlayFieldController { |
||||
|
@Autowired |
||||
|
private PlayFieldService playFieldService; |
||||
|
|
||||
|
@GetMapping("/count-by-zone") |
||||
|
public List<Map<String, Object>> getPlayFieldCountsByZone() { |
||||
|
return playFieldService.getPlayFieldCountsByZone(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/without-guards/{zone}") |
||||
|
public List<Map<String, Object>> getPlayFieldsWithoutGuardsByZone(@PathVariable int zone) { |
||||
|
return playFieldService.getPlayFieldsWithoutGuards(zone); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,41 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.SofaBedCollectionService; |
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/api/sofabedcollection") |
||||
|
public class SofaBedCollectionApiController { |
||||
|
|
||||
|
|
||||
|
@Autowired |
||||
|
private SofaBedCollectionService sofaBedCollectionService; |
||||
|
|
||||
|
@GetMapping("/getZoneReport") |
||||
|
public List<Map<String, Object>> getZoneReport() |
||||
|
{ |
||||
|
return sofaBedCollectionService.getZoneReport(); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
@GetMapping("/getWardReport") |
||||
|
public List<Map<String, Object>> getWardReport(@RequestParam String zone) |
||||
|
{ |
||||
|
return sofaBedCollectionService.getWardReport(zone); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
@GetMapping("/getWardStatusReport") |
||||
|
public List<Map<String, Object>> getWardStatusDetail(@RequestParam String ward,@RequestParam String status) |
||||
|
{ |
||||
|
return sofaBedCollectionService.getWardStatusDetails(ward,status); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,29 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.ToiletService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.http.ResponseEntity; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/toilet/api") |
||||
|
public class ToiletController { |
||||
|
|
||||
|
@Autowired |
||||
|
ToiletService toileService; |
||||
|
|
||||
|
@GetMapping("/getSFDData") |
||||
|
public Map<String, Object> getSFDData(){ |
||||
|
return toileService.getSFDData(); |
||||
|
} |
||||
|
@GetMapping("/getSFDPack1") |
||||
|
public List<Map<String, Object>> getSFDPack1(@RequestParam String pack){ |
||||
|
return toileService.getSFDPack1(pack); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,29 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
|
||||
|
import com.gcc.commissionerreview.service.UphcReportService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/uphc/usercontroller") |
||||
|
public class UphcReportController { |
||||
|
|
||||
|
@Autowired |
||||
|
private UphcReportService uphcReportService; |
||||
|
|
||||
|
@GetMapping("/zone-wise-op-summary") |
||||
|
public List<Map<String, Object>> getZoneWiseOpSummary() { |
||||
|
return uphcReportService.getZoneWiseOpSummary(); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
@GetMapping("/uphc-details/{zone}") |
||||
|
public List<Map<String, Object>> getUphcDetails(@PathVariable String zone) { |
||||
|
return uphcReportService.getUphcDetailsByZone(zone); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,73 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import java.util.Collections; |
||||
|
import java.util.HashMap; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.VeterinaryPetClinicService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.http.HttpStatus; |
||||
|
import org.springframework.http.ResponseEntity; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/api/veterinarypetclinic") |
||||
|
public class VeterinaryPetClinicApiController { |
||||
|
|
||||
|
@Autowired |
||||
|
private VeterinaryPetClinicService veterinaryPetClinicService; |
||||
|
|
||||
|
|
||||
|
@GetMapping("/petclinicsummary") |
||||
|
public List<Map<String, Object>> getPetClinicSummary() { |
||||
|
return veterinaryPetClinicService.getPetClinicSummary(); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
@GetMapping("/months") |
||||
|
public List<String> getMonths() { |
||||
|
return veterinaryPetClinicService.getDistinctMonths(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/monthly-summary") |
||||
|
public ResponseEntity<List<Map<String, Object>>> getMonthlySummary() { |
||||
|
List<Map<String, Object>> summary = veterinaryPetClinicService.fetchYearlySummary(); |
||||
|
return ResponseEntity.ok(summary); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
@GetMapping("/abcsummary") |
||||
|
public ResponseEntity<List<Map<String, Object>>> getAbcSummary() { |
||||
|
List<Map<String, Object>> summary = veterinaryPetClinicService.AbcReportSummary(); |
||||
|
return ResponseEntity.ok(summary); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/overallcattledata") |
||||
|
public ResponseEntity<?> getOverallData() { |
||||
|
return veterinaryPetClinicService.getZoneWiseCattleData(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/slaughterdata") |
||||
|
public List<Map<String, Object>> getSlaughterData() { |
||||
|
return veterinaryPetClinicService.getData(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/meatraid-report") |
||||
|
public ResponseEntity<List<Map<String, Object>>> getMeatReport() { |
||||
|
try { |
||||
|
List<Map<String, Object>> result = veterinaryPetClinicService.ViewMeatRaidReport(); |
||||
|
return ResponseEntity.ok(result); |
||||
|
} catch (Exception e) { |
||||
|
Map<String, Object> error = new HashMap<>(); |
||||
|
error.put("error", "Unable to fetch progress report"); |
||||
|
error.put("details", e.getMessage()); |
||||
|
return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR) |
||||
|
.body(Collections.singletonList(error)); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,50 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import java.util.Collections; |
||||
|
import java.util.HashMap; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.http.HttpStatus; |
||||
|
import org.springframework.http.ResponseEntity; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.makkaludanMudalvarService; |
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/makkaludanMudalvar/api") |
||||
|
public class makkaludanMudalvarController { |
||||
|
|
||||
|
@Autowired |
||||
|
private makkaludanMudalvarService makkaludanmudalvarservice; |
||||
|
|
||||
|
@GetMapping("/progress-report") |
||||
|
public ResponseEntity<List<Map<String, Object>>> getProgressReport() { |
||||
|
try { |
||||
|
List<Map<String, Object>> result = makkaludanmudalvarservice.ViewProgressReport(); |
||||
|
return ResponseEntity.ok(result); |
||||
|
} catch (Exception e) { |
||||
|
Map<String, Object> error = new HashMap<>(); |
||||
|
error.put("error", "Unable to fetch progress report"); |
||||
|
error.put("details", e.getMessage()); |
||||
|
return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR) |
||||
|
.body(Collections.singletonList(error)); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/progress-report-list") |
||||
|
public ResponseEntity<List<Map<String, Object>>> getPendencyReport( |
||||
|
@RequestParam String ticket_owner_name, |
||||
|
@RequestParam String status_display) { |
||||
|
|
||||
|
List<Map<String, Object>> reportList = makkaludanmudalvarservice.viewProgressReportList(ticket_owner_name, status_display); |
||||
|
return new ResponseEntity<>(reportList, HttpStatus.OK); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,36 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.mobileDiagonosticService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.PathVariable; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/mobileDiagonostic/api/reports") |
||||
|
|
||||
|
public class mobileDiagonosticController { |
||||
|
@Autowired |
||||
|
private mobileDiagonosticService mobileDiagonosticService; |
||||
|
|
||||
|
@GetMapping("getzonedata") |
||||
|
public List<Map<String, Object>> getMonthlyCampData() { |
||||
|
return mobileDiagonosticService.fetchMonthlyCampData(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/getZoneDetailData/{zone}") |
||||
|
public List<Map<String, Object>> getZoneDetailData(@PathVariable("zone") String zone) { |
||||
|
System.out.println("zone: " + zone); |
||||
|
return mobileDiagonosticService.fetchZoneDetails(zone); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
@ -0,0 +1,50 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import java.util.Collections; |
||||
|
import java.util.HashMap; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.http.HttpStatus; |
||||
|
import org.springframework.http.ResponseEntity; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.mudhalvarinMugavariService; |
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/mudhalvarinMugavari/api") |
||||
|
public class mudhalvarinMugavariController { |
||||
|
|
||||
|
@Autowired |
||||
|
private mudhalvarinMugavariService mudhalvarinmugavariservice; |
||||
|
|
||||
|
@GetMapping("/pendency-report") |
||||
|
public ResponseEntity<List<Map<String, Object>>> getProgressReport() { |
||||
|
try { |
||||
|
List<Map<String, Object>> result = mudhalvarinmugavariservice.ViewPendencyReport(); |
||||
|
return ResponseEntity.ok(result); |
||||
|
} catch (Exception e) { |
||||
|
Map<String, Object> error = new HashMap<>(); |
||||
|
error.put("error", "Unable to fetch progress report"); |
||||
|
error.put("details", e.getMessage()); |
||||
|
return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR) |
||||
|
.body(Collections.singletonList(error)); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/pendency-report-list") |
||||
|
public ResponseEntity<List<Map<String, Object>>> getPendencyReport( |
||||
|
@RequestParam String ticket_owner_name, |
||||
|
@RequestParam String status_display) { |
||||
|
|
||||
|
List<Map<String, Object>> reportList = mudhalvarinmugavariservice.viewPendencyReportList(ticket_owner_name, status_display); |
||||
|
return new ResponseEntity<>(reportList, HttpStatus.OK); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,53 @@ |
|||||
|
package com.gcc.commissionerreview.controller; |
||||
|
|
||||
|
import java.util.Collections; |
||||
|
import java.util.HashMap; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.http.HttpStatus; |
||||
|
import org.springframework.http.ResponseEntity; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestParam; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
import com.gcc.commissionerreview.service.urbangreenService; |
||||
|
|
||||
|
@RestController |
||||
|
@RequestMapping("/commissionerreview/urbangreen/api") |
||||
|
public class urbangreenController { |
||||
|
|
||||
|
@Autowired |
||||
|
private urbangreenService urbangreenservice; |
||||
|
|
||||
|
@GetMapping("/urbangreen-report") |
||||
|
public ResponseEntity<List<Map<String, Object>>> getUrbanGreenReport() { |
||||
|
try { |
||||
|
List<Map<String, Object>> result = urbangreenservice.ViewUrbanGreenReport(); |
||||
|
return ResponseEntity.ok(result); |
||||
|
} catch (Exception e) { |
||||
|
Map<String, Object> error = new HashMap<>(); |
||||
|
error.put("error", "Unable to fetch progress report"); |
||||
|
error.put("details", e.getMessage()); |
||||
|
return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR) |
||||
|
.body(Collections.singletonList(error)); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/urbangreen-report-list") |
||||
|
public ResponseEntity<?> getUrbanGreenReportList(@RequestParam String zone, String phase) { |
||||
|
try { |
||||
|
List<Map<String, Object>> result = urbangreenservice.ViewUrbanGreenReportList(zone, phase); |
||||
|
return ResponseEntity.ok(result); |
||||
|
} catch (Exception e) { |
||||
|
Map<String, Object> error = new HashMap<>(); |
||||
|
error.put("error", "Unable to fetch progress report"); |
||||
|
error.put("details", e.getMessage()); |
||||
|
return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body(error); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,61 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
@Service |
||||
|
public class CompoundWallService { |
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getCompoundWallSummaryByZone() { |
||||
|
String sql = """ |
||||
|
SELECT |
||||
|
zone, |
||||
|
COUNT(*) AS total_playfields, |
||||
|
SUM(CASE |
||||
|
WHEN LOWER(COALESCE(compound_wall, '')) <> 'good' THEN 1 |
||||
|
ELSE 0 |
||||
|
END) AS with_issue |
||||
|
FROM ( |
||||
|
SELECT *, |
||||
|
ROW_NUMBER() OVER (PARTITION BY zone, playfield_name ORDER BY id) AS rn |
||||
|
FROM playfield |
||||
|
) t |
||||
|
WHERE t.rn = 1 |
||||
|
GROUP BY zone |
||||
|
ORDER BY CAST(zone AS UNSIGNED) |
||||
|
"""; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getPlayfieldsWithCompoundWallIssuesByZone(int zone) { |
||||
|
String sql = """ |
||||
|
SELECT |
||||
|
id, zone, division, playfield_name, maintained_by, playfield_condition, compound_wall |
||||
|
FROM ( |
||||
|
SELECT *, |
||||
|
ROW_NUMBER() OVER (PARTITION BY playfield_name ORDER BY id) AS rn |
||||
|
FROM playfield |
||||
|
WHERE zone = ? |
||||
|
AND LOWER(COALESCE(compound_wall, '')) <> 'good' |
||||
|
) t |
||||
|
WHERE t.rn = 1 |
||||
|
"""; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql, zone); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,300 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import java.util.ArrayList; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.http.ResponseEntity; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
@Service |
||||
|
public class EnforcementService { |
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("oracleDataSource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getzonewisedetails() |
||||
|
{ |
||||
|
|
||||
|
String sql="select zone.name zone,\r\n" |
||||
|
+ "sum(case when formtype='Form 1' then 1 else 0 end) form1_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 1' and b.value!='END' then 1 else 0 end) form1_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 1' and b.value='END' then 1 else 0 end) form1_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 2' then 1 else 0 end) form2_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 2' and b.value!='END' then 1 else 0 end) form2_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 2' and b.value='END' then 1 else 0 end) form2_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 3' then 1 else 0 end) form3_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 3' and b.value!='END' then 1 else 0 end) form3_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 3' and b.value='END' then 1 else 0 end) form3_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 4' then 1 else 0 end) form4_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 4' and b.value!='END' then 1 else 0 end) form4_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 4' and b.value='END' then 1 else 0 end) form4_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 5' then 1 else 0 end) form5_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 5' and b.value!='END' then 1 else 0 end) form5_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 5' and b.value='END' then 1 else 0 end) form5_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 6' then 1 else 0 end) form6_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 6' and b.value!='END' then 1 else 0 end) form6_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 6' and b.value='END' then 1 else 0 end) form6_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 7' then 1 else 0 end) form7_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 7' and b.value!='END' then 1 else 0 end) form7_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 7' and b.value='END' then 1 else 0 end) form7_completed\r\n" |
||||
|
+ "from EGBPA_FORM_RULES@erp a,eg_wf_states@erp b,eg_boundary@erp zone\r\n" |
||||
|
+ "where a.state_id=b.id and zone.id_bndry=a.zoneid and\r\n" |
||||
|
+ " a.id = (SELECT MAX(id) FROM EGBPA_FORM_RULES@erp WHERE form_parentid = a.form_parentid)\r\n" |
||||
|
+ "group by zone.name order by name"; |
||||
|
|
||||
|
|
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<Map<String, Object>> getwardwisedetails(String zone) |
||||
|
{ |
||||
|
String sql="select zone.name zone,ward.name ward,\r\n" |
||||
|
+ "sum(case when formtype='Form 1' then 1 else 0 end) form1_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 1' and b.value!='END' then 1 else 0 end) form1_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 1' and b.value='END' then 1 else 0 end) form1_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 2' then 1 else 0 end) form2_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 2' and b.value!='END' then 1 else 0 end) form2_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 2' and b.value='END' then 1 else 0 end) form2_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 3' then 1 else 0 end) form3_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 3' and b.value!='END' then 1 else 0 end) form3_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 3' and b.value='END' then 1 else 0 end) form3_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 4' then 1 else 0 end) form4_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 4' and b.value!='END' then 1 else 0 end) form4_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 4' and b.value='END' then 1 else 0 end) form4_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 5' then 1 else 0 end) form5_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 5' and b.value!='END' then 1 else 0 end) form5_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 5' and b.value='END' then 1 else 0 end) form5_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 6' then 1 else 0 end) form6_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 6' and b.value!='END' then 1 else 0 end) form6_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 6' and b.value='END' then 1 else 0 end) form6_completed,\r\n" |
||||
|
+ "sum(case when formtype='Form 7' then 1 else 0 end) form7_recieved,\r\n" |
||||
|
+ "sum(case when formtype='Form 7' and b.value!='END' then 1 else 0 end) form7_inprogress,\r\n" |
||||
|
+ "sum(case when formtype='Form 7' and b.value='END' then 1 else 0 end) form7_completed\r\n" |
||||
|
+ "from EGBPA_FORM_RULES@erp a,eg_wf_states@erp b,eg_boundary@erp zone,eg_boundary@erp ward\r\n" |
||||
|
+ "where a.state_id=b.id and zone.id_bndry=a.zoneid and ward.id_bndry=a.wardid and\r\n" |
||||
|
+ " a.id = (SELECT MAX(id) FROM EGBPA_FORM_RULES@erp WHERE form_parentid = a.form_parentid) and zone.name=? \r\n" |
||||
|
+ "group by zone.name,ward.name order by zone.name,ward.name"; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql,zone); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getformdetailswithzone(String zone, String ward, String formtype, String status) { |
||||
|
|
||||
|
String sql=""; |
||||
|
List<Map<String, Object>> result = new ArrayList<>();; |
||||
|
|
||||
|
if("Received".equalsIgnoreCase(status)) { |
||||
|
sql="SELECT " |
||||
|
+ " zone.name zone,ward.name ward," |
||||
|
+ " addr.applicant_name," |
||||
|
+ " addr.formid," |
||||
|
+ " addr.area," |
||||
|
+ " addr.address," |
||||
|
+ " addr.pincode " |
||||
|
+ "FROM" |
||||
|
+ " EGBPA_FORM_RULES@erp a" |
||||
|
+ " JOIN eg_wf_states@erp b ON a.state_id = b.id" |
||||
|
+ " JOIN eg_boundary@erp zone ON zone.id_bndry = a.zoneid" |
||||
|
+ " JOIN eg_boundary@erp ward ON ward.id_bndry = a.wardid" |
||||
|
+ " LEFT JOIN EGBPA_ENF_APP_ADDRESS@erp addr ON addr.formid = a.form_parentid " |
||||
|
+ "WHERE" |
||||
|
+ " a.id = (" |
||||
|
+ " SELECT MAX(id)" |
||||
|
+ " FROM EGBPA_FORM_RULES@erp" |
||||
|
+ " WHERE form_parentid = a.form_parentid" |
||||
|
+ " )" |
||||
|
+ " AND a.formtype = ? " |
||||
|
+ " AND zone.name = ? " |
||||
|
+ " AND ward.name = ? "; |
||||
|
|
||||
|
result = jdbcTemplate.queryForList(sql, formtype, zone, ward); |
||||
|
} |
||||
|
|
||||
|
if("Inprogress".equalsIgnoreCase(status)) { |
||||
|
|
||||
|
sql="SELECT" |
||||
|
+ " zone.name zone,ward.name ward," |
||||
|
+ " addr.applicant_name," |
||||
|
+ " addr.formid," |
||||
|
+ " addr.area," |
||||
|
+ " addr.address," |
||||
|
+ " addr.pincode " |
||||
|
+ "FROM" |
||||
|
+ " EGBPA_FORM_RULES@erp a" |
||||
|
+ " JOIN eg_wf_states@erp b ON a.state_id = b.id" |
||||
|
+ " JOIN eg_boundary@erp zone ON zone.id_bndry = a.zoneid" |
||||
|
+ " JOIN eg_boundary@erp ward ON ward.id_bndry = a.wardid" |
||||
|
+ " LEFT JOIN EGBPA_ENF_APP_ADDRESS@erp addr ON addr.formid = a.form_parentid" |
||||
|
+ " WHERE" |
||||
|
+ " a.id = (" |
||||
|
+ " SELECT MAX(id)" |
||||
|
+ " FROM EGBPA_FORM_RULES@erp" |
||||
|
+ " WHERE form_parentid = a.form_parentid" |
||||
|
+ " )" |
||||
|
+ " AND a.formtype = ?" |
||||
|
+ " AND zone.name = ?" |
||||
|
+ " AND ward.name = ?" |
||||
|
+ " and formtype=? and b.value!='END'"; |
||||
|
|
||||
|
result=jdbcTemplate.queryForList(sql,formtype,zone,ward,formtype); |
||||
|
} |
||||
|
|
||||
|
if("Completed".equalsIgnoreCase(status)) { |
||||
|
|
||||
|
sql="SELECT" |
||||
|
+ " zone.name zone,ward.name ward," |
||||
|
+ " addr.applicant_name," |
||||
|
+ " addr.formid," |
||||
|
+ " addr.area," |
||||
|
+ " addr.address," |
||||
|
+ " addr.pincode " |
||||
|
+ "FROM " |
||||
|
+ " EGBPA_FORM_RULES@erp a" |
||||
|
+ " JOIN eg_wf_states@erp b ON a.state_id = b.id" |
||||
|
+ " JOIN eg_boundary@erp zone ON zone.id_bndry = a.zoneid" |
||||
|
+ " JOIN eg_boundary@erp ward ON ward.id_bndry = a.wardid" |
||||
|
+ " LEFT JOIN EGBPA_ENF_APP_ADDRESS@erp addr ON addr.formid = a.form_parentid " |
||||
|
+ "WHERE" |
||||
|
+ " a.id = (" |
||||
|
+ " SELECT MAX(id)" |
||||
|
+ " FROM EGBPA_FORM_RULES@erp" |
||||
|
+ " WHERE form_parentid = a.form_parentid" |
||||
|
+ " )" |
||||
|
+ " AND a.formtype = ? " |
||||
|
+ " AND zone.name = ? " |
||||
|
+ " AND ward.name = ? " |
||||
|
+ " and formtype=? and b.value='END'"; |
||||
|
|
||||
|
result=jdbcTemplate.queryForList(sql,formtype,zone,ward,formtype); |
||||
|
} |
||||
|
|
||||
|
return result; |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getformiddetails(String formid) { |
||||
|
|
||||
|
String sql="SELECT" |
||||
|
+ " m.ENCLOSEMENTNAME," |
||||
|
+ " TO_CHAR(f.CREATEDDATE, 'YYYY/MM/DD HH24:MI') || ' 00:00:00.0' AS cdate," |
||||
|
+ " 'https://erp.chennaicorporation.gov.in/bpa/search/registrationForm!viewFile.action?formParentId=' || d.FORMID ||" |
||||
|
+ " CHR(38) || 'fileName=' || d.DOCNAME ||" |
||||
|
+ " CHR(38) || 'contentType=' || d.DOCTYPE ||" |
||||
|
+ " CHR(38) || 'fileCreatedDate=' || TO_CHAR(f.CREATEDDATE, 'YYYY-MM-DD') || ' 00:00:00.0' AS fileUrl" |
||||
|
+ " FROM" |
||||
|
+ " EGBPA_FORM_ENCLOSEMENT_DET@erp d " |
||||
|
+ "INNER JOIN " |
||||
|
+ " EGBPA_FORM_ENCLOSEMENT@erp m ON d.TYPEID = m.ID " |
||||
|
+ "INNER JOIN" |
||||
|
+ " EGBPA_FORM_RULES@erp f ON f.ID = d.APPID " |
||||
|
+ "WHERE" |
||||
|
+ " d.FORMID = ? " |
||||
|
+ "ORDER BY" |
||||
|
+ " m.FORMTYPE DESC"; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql,formid); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getformdetailswithoutward(String zone, String formtype, String status) { |
||||
|
String sql=""; |
||||
|
List<Map<String, Object>> result = new ArrayList<>();; |
||||
|
|
||||
|
if("Received".equalsIgnoreCase(status)) { |
||||
|
sql="SELECT " |
||||
|
+ " zone.name zone,ward.name ward," |
||||
|
+ " addr.applicant_name," |
||||
|
+ " addr.formid," |
||||
|
+ " addr.area," |
||||
|
+ " addr.address," |
||||
|
+ " addr.pincode " |
||||
|
+ "FROM" |
||||
|
+ " EGBPA_FORM_RULES@erp a" |
||||
|
+ " JOIN eg_wf_states@erp b ON a.state_id = b.id" |
||||
|
+ " JOIN eg_boundary@erp zone ON zone.id_bndry = a.zoneid" |
||||
|
+ " JOIN eg_boundary@erp ward ON ward.id_bndry = a.wardid" |
||||
|
+ " LEFT JOIN EGBPA_ENF_APP_ADDRESS@erp addr ON addr.formid = a.form_parentid " |
||||
|
+ "WHERE" |
||||
|
+ " a.id = (" |
||||
|
+ " SELECT MAX(id)" |
||||
|
+ " FROM EGBPA_FORM_RULES@erp" |
||||
|
+ " WHERE form_parentid = a.form_parentid" |
||||
|
+ " )" |
||||
|
+ " AND a.formtype = ? " |
||||
|
+ " AND zone.name = ? "; |
||||
|
|
||||
|
result = jdbcTemplate.queryForList(sql, formtype, zone); |
||||
|
} |
||||
|
|
||||
|
if("Inprogress".equalsIgnoreCase(status)) { |
||||
|
|
||||
|
sql="SELECT" |
||||
|
+ " zone.name zone,ward.name ward," |
||||
|
+ " addr.applicant_name," |
||||
|
+ " addr.formid," |
||||
|
+ " addr.area," |
||||
|
+ " addr.address," |
||||
|
+ " addr.pincode " |
||||
|
+ "FROM" |
||||
|
+ " EGBPA_FORM_RULES@erp a" |
||||
|
+ " JOIN eg_wf_states@erp b ON a.state_id = b.id" |
||||
|
+ " JOIN eg_boundary@erp zone ON zone.id_bndry = a.zoneid" |
||||
|
+ " JOIN eg_boundary@erp ward ON ward.id_bndry = a.wardid" |
||||
|
+ " LEFT JOIN EGBPA_ENF_APP_ADDRESS@erp addr ON addr.formid = a.form_parentid" |
||||
|
+ " WHERE" |
||||
|
+ " a.id = (" |
||||
|
+ " SELECT MAX(id)" |
||||
|
+ " FROM EGBPA_FORM_RULES@erp" |
||||
|
+ " WHERE form_parentid = a.form_parentid" |
||||
|
+ " )" |
||||
|
+ " AND a.formtype = ?" |
||||
|
+ " AND zone.name = ?" |
||||
|
+ " and formtype=? and b.value!='END'"; |
||||
|
|
||||
|
result=jdbcTemplate.queryForList(sql,formtype,zone,formtype); |
||||
|
} |
||||
|
|
||||
|
if("Completed".equalsIgnoreCase(status)) { |
||||
|
|
||||
|
sql="SELECT" |
||||
|
+ " zone.name zone,ward.name ward," |
||||
|
+ " addr.applicant_name," |
||||
|
+ " addr.formid," |
||||
|
+ " addr.area," |
||||
|
+ " addr.address," |
||||
|
+ " addr.pincode " |
||||
|
+ "FROM " |
||||
|
+ " EGBPA_FORM_RULES@erp a" |
||||
|
+ " JOIN eg_wf_states@erp b ON a.state_id = b.id" |
||||
|
+ " JOIN eg_boundary@erp zone ON zone.id_bndry = a.zoneid" |
||||
|
+ " JOIN eg_boundary@erp ward ON ward.id_bndry = a.wardid" |
||||
|
+ " LEFT JOIN EGBPA_ENF_APP_ADDRESS@erp addr ON addr.formid = a.form_parentid " |
||||
|
+ "WHERE" |
||||
|
+ " a.id = (" |
||||
|
+ " SELECT MAX(id)" |
||||
|
+ " FROM EGBPA_FORM_RULES@erp" |
||||
|
+ " WHERE form_parentid = a.form_parentid" |
||||
|
+ " )" |
||||
|
+ " AND a.formtype = ? " |
||||
|
+ " AND zone.name = ? " |
||||
|
+ " and formtype=? and b.value='END'"; |
||||
|
|
||||
|
result=jdbcTemplate.queryForList(sql,formtype,zone,formtype); |
||||
|
} |
||||
|
|
||||
|
return result; |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,65 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
@Service |
||||
|
public class ParksService { |
||||
|
|
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getParkData() { |
||||
|
String sql = "SELECT zone,count(*) as parks_count, " |
||||
|
+ " SUM(CASE WHEN maintained_by = 'GCC' THEN 1 ELSE 0 END) AS parksby_gcc, " |
||||
|
+ " SUM(CASE WHEN maintained_by = 'Outsourced Parks' THEN 1 ELSE 0 END) AS parksby_out, " |
||||
|
+ " SUM(CASE WHEN maintained_by = 'Adoption' THEN 1 ELSE 0 END) AS parksby_adoption, " |
||||
|
+ " SUM(CASE WHEN maintained_by = 'SHG' THEN 1 ELSE 0 END) AS parksby_shg, " |
||||
|
+ " SUM(CASE WHEN maintained_by = 'CMRL' THEN 1 ELSE 0 END) AS parksby_cmrl, " |
||||
|
+ " SUM(CASE WHEN repair_work = 'Yes' THEN 1 ELSE 0 END) AS repair_needed, " |
||||
|
+ " SUM(labours_allocated) as labours_appointed FROM parks group by zone"; |
||||
|
try { |
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
|
||||
|
} catch (Exception e) { |
||||
|
e.printStackTrace(); |
||||
|
return List.of(); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getParkDataByZone(String zone, String type) { |
||||
|
String sql = ""; |
||||
|
if(type.equalsIgnoreCase("GCC")) { |
||||
|
sql="select park_name, maintained_by, labours_allocated, park_condition from parks where maintained_by = 'GCC' and zone=? "; |
||||
|
} else if(type.equalsIgnoreCase("Outsourced Parks")) { |
||||
|
sql="select park_name, maintained_by, labours_allocated, park_condition from parks where maintained_by = 'Outsourced Parks' and zone=? "; |
||||
|
} else if(type.equalsIgnoreCase("Adoption")) { |
||||
|
sql="select park_name, maintained_by, labours_allocated, park_condition from parks where maintained_by = 'Adoption' and zone=? "; |
||||
|
} else if(type.equalsIgnoreCase("SHG")) { |
||||
|
sql="select park_name, maintained_by, labours_allocated, park_condition from parks where maintained_by = 'SHG' and zone=? "; |
||||
|
} else if(type.equalsIgnoreCase("Repair Needed")) { |
||||
|
sql="select park_name from parks where repair_work = 'Yes' and zone=? "; |
||||
|
} |
||||
|
try { |
||||
|
return jdbcTemplate.queryForList(sql, zone); |
||||
|
|
||||
|
} catch (Exception e) { |
||||
|
e.printStackTrace(); |
||||
|
return List.of(); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,56 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
@Service |
||||
|
public class PlayFieldService { |
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getPlayFieldCountsByZone() { |
||||
|
String sql = "SELECT \n" + |
||||
|
" zone,\n" + |
||||
|
" COUNT(*) AS total_playfields,\n" + |
||||
|
" SUM(CASE WHEN LOWER(security_guard) = 'no' THEN 1 ELSE 0 END) AS without_security\n" + |
||||
|
" FROM (\n" + |
||||
|
" SELECT \n" + |
||||
|
" *,\n" + |
||||
|
" ROW_NUMBER() OVER (PARTITION BY zone, playfield_name ORDER BY id) AS rn\n" + |
||||
|
" FROM playfield\n" + |
||||
|
" ) t\n" + |
||||
|
" WHERE t.rn = 1\n" + |
||||
|
" GROUP BY zone\n" + |
||||
|
" ORDER BY CAST(zone AS UNSIGNED)"; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<Map<String, Object>> getPlayFieldsWithoutGuards(int zone) { |
||||
|
String sql = "SELECT *\n" + |
||||
|
" FROM (\n" + |
||||
|
" SELECT \n" + |
||||
|
" id, zone, division, playfield_name, maintained_by, playfield_condition, security_guard, compound_wall,\n" + |
||||
|
" ROW_NUMBER() OVER (PARTITION BY playfield_name ORDER BY id) AS rn\n" + |
||||
|
" FROM playfield\n" + |
||||
|
" WHERE LOWER(security_guard) = 'no' AND zone = ?\n" + |
||||
|
" ) t\n" + |
||||
|
" WHERE t.rn = 1"; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql, zone); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,395 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import java.util.ArrayList; |
||||
|
import java.util.Collections; |
||||
|
import java.util.LinkedHashMap; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
import org.springframework.transaction.annotation.Transactional; |
||||
|
|
||||
|
@Service |
||||
|
public class SofaBedCollectionService { |
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcDomesticWasteTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDatasource(@Qualifier("mysqlSofaBedCollectionDataSource") DataSource datasource) { |
||||
|
this.jdbcDomesticWasteTemplate=new JdbcTemplate(datasource); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
@Transactional(readOnly = true) |
||||
|
public List<Map<String, Object>> getZoneReport() { |
||||
|
|
||||
|
String sql = """ |
||||
|
WITH date_limits AS ( |
||||
|
SELECT |
||||
|
DATE_SUB(CURDATE(), INTERVAL (DAYOFWEEK(CURDATE()) - 1) DAY) AS week_start, |
||||
|
DATE_ADD(DATE_SUB(CURDATE(), INTERVAL (DAYOFWEEK(CURDATE()) - 1) DAY), INTERVAL 7 DAY) AS week_end |
||||
|
) |
||||
|
SELECT |
||||
|
COALESCE(ur.zone, 'TOTAL') AS zone, |
||||
|
COUNT(*) AS total_request, |
||||
|
|
||||
|
-- Requests created this week |
||||
|
SUM(CASE WHEN ur.cdate >= d.week_start AND ur.cdate < d.week_end THEN 1 ELSE 0 END) AS this_week_requests, |
||||
|
|
||||
|
-- Older requests |
||||
|
SUM(CASE WHEN ur.cdate < d.week_start THEN 1 ELSE 0 END) AS older_requests, |
||||
|
|
||||
|
-- Status-based counts |
||||
|
SUM(CASE WHEN ur.status = 2 THEN 1 ELSE 0 END) AS completed, |
||||
|
SUM(CASE WHEN ur.status = 4 THEN 1 ELSE 0 END) AS user_cancel, |
||||
|
SUM(CASE WHEN ur.status = 5 THEN 1 ELSE 0 END) AS officer_cancel, |
||||
|
|
||||
|
-- Pending = older_requests - (completed + cancels) |
||||
|
( |
||||
|
SUM(CASE WHEN ur.cdate < d.week_start THEN 1 ELSE 0 END) |
||||
|
- SUM(CASE WHEN ur.status IN (2,4,5) THEN 1 ELSE 0 END) |
||||
|
) AS pending |
||||
|
|
||||
|
FROM |
||||
|
user_request_table ur |
||||
|
CROSS JOIN date_limits d |
||||
|
WHERE |
||||
|
ur.is_active = 1 |
||||
|
AND ur.is_delete = 0 |
||||
|
GROUP BY |
||||
|
ur.zone WITH ROLLUP |
||||
|
ORDER BY |
||||
|
CASE WHEN ur.zone IS NULL THEN 999 ELSE ur.zone END; |
||||
|
"""; |
||||
|
|
||||
|
List<Map<String, Object>> reportList = jdbcDomesticWasteTemplate.queryForList(sql); |
||||
|
|
||||
|
Map<String, Object> response = new LinkedHashMap<>(); |
||||
|
response.put("status", "Success"); |
||||
|
response.put("message", "Zone-wise Report (All Dates)"); |
||||
|
response.put("data", reportList); |
||||
|
|
||||
|
return Collections.singletonList(response); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
// @Transactional |
||||
|
// public List<Map<String, Object>> getZoneReport(String fromDate, String toDate) { |
||||
|
|
||||
|
// String sql = """ |
||||
|
// WITH date_limits AS ( |
||||
|
// SELECT |
||||
|
// STR_TO_DATE(?, '%d-%m-%Y') AS start_date, |
||||
|
// STR_TO_DATE(?, '%d-%m-%Y') AS end_date, |
||||
|
// DATE_SUB(CURDATE(), INTERVAL (DAYOFWEEK(CURDATE()) - 1) DAY) AS week_start, |
||||
|
// DATE_ADD(DATE_SUB(CURDATE(), INTERVAL (DAYOFWEEK(CURDATE()) - 1) DAY), INTERVAL 7 DAY) AS week_end |
||||
|
// ) |
||||
|
// SELECT |
||||
|
// COALESCE(ur.zone, 'TOTAL') AS zone, |
||||
|
// COUNT(*) AS total_request, |
||||
|
|
||||
|
// -- Requests created this week |
||||
|
// SUM(CASE WHEN ur.cdate >= d.week_start AND ur.cdate < d.week_end THEN 1 ELSE 0 END) AS this_week_requests, |
||||
|
|
||||
|
// -- Older requests |
||||
|
// SUM(CASE WHEN ur.cdate < d.week_start THEN 1 ELSE 0 END) AS older_requests, |
||||
|
|
||||
|
// -- Status-based counts |
||||
|
// SUM(CASE WHEN ur.status = 2 THEN 1 ELSE 0 END) AS completed, |
||||
|
// SUM(CASE WHEN ur.status = 4 THEN 1 ELSE 0 END) AS user_cancel, |
||||
|
// SUM(CASE WHEN ur.status = 5 THEN 1 ELSE 0 END) AS officer_cancel, |
||||
|
|
||||
|
// -- Pending = older_requests - (completed + cancels) |
||||
|
// ( |
||||
|
// SUM(CASE WHEN ur.cdate < d.week_start THEN 1 ELSE 0 END) |
||||
|
// - SUM(CASE WHEN ur.status IN (2,4,5) THEN 1 ELSE 0 END) |
||||
|
// ) AS pending |
||||
|
|
||||
|
// FROM |
||||
|
// user_request_table ur |
||||
|
// CROSS JOIN date_limits d |
||||
|
// WHERE |
||||
|
// ur.is_active = 1 |
||||
|
// AND ur.is_delete = 0 |
||||
|
// AND ur.cdate BETWEEN d.start_date AND d.end_date |
||||
|
// GROUP BY |
||||
|
// ur.zone WITH ROLLUP |
||||
|
// ORDER BY |
||||
|
// CASE WHEN ur.zone IS NULL THEN 999 ELSE ur.zone END; |
||||
|
// """; |
||||
|
|
||||
|
// List<Map<String, Object>> reportList = jdbcDomesticWasteTemplate.queryForList(sql, fromDate, toDate); |
||||
|
|
||||
|
// Map<String, Object> response = new LinkedHashMap<>(); |
||||
|
// response.put("status", "Success"); |
||||
|
// response.put("message", "Zone-wise Report"); |
||||
|
// response.put("data", reportList); |
||||
|
|
||||
|
// return Collections.singletonList(response); |
||||
|
// } |
||||
|
|
||||
|
|
||||
|
|
||||
|
// @Transactional(readOnly = true) |
||||
|
// public List<Map<String, Object>> getWardReport(String fromDate, String toDate, String zone) { |
||||
|
// String sql = |
||||
|
// "(" |
||||
|
// + " SELECT " |
||||
|
// + " ur.division AS division, " |
||||
|
// + " COUNT(*) AS total_request, " |
||||
|
// + " SUM(CASE WHEN ur.status = 1 THEN 1 ELSE 0 END) AS open, " |
||||
|
// + " SUM(CASE WHEN ur.status = 2 THEN 1 ELSE 0 END) AS completed, " |
||||
|
// + " SUM(CASE WHEN ur.status = 3 THEN 1 ELSE 0 END) AS pending, " |
||||
|
// + " SUM(CASE WHEN ur.status = 4 THEN 1 ELSE 0 END) AS user_cancel, " |
||||
|
// + " SUM(CASE WHEN ur.status = 5 THEN 1 ELSE 0 END) AS officer_cancel " |
||||
|
// + " FROM user_request_table ur " |
||||
|
// + " WHERE ur.is_active = 1 AND ur.is_delete = 0 AND ur.zone = ? " |
||||
|
// + " GROUP BY ur.division " |
||||
|
// + ") " |
||||
|
// + "UNION ALL " |
||||
|
// + "(" |
||||
|
// + " SELECT " |
||||
|
// + " 'TOTAL' AS division, " |
||||
|
// + " COUNT(*) AS total_request, " |
||||
|
// + " SUM(CASE WHEN ur.status = 1 THEN 1 ELSE 0 END) AS open, " |
||||
|
// + " SUM(CASE WHEN ur.status = 2 THEN 1 ELSE 0 END) AS completed, " |
||||
|
// + " SUM(CASE WHEN ur.status = 3 THEN 1 ELSE 0 END) AS pending, " |
||||
|
// + " SUM(CASE WHEN ur.status = 4 THEN 1 ELSE 0 END) AS user_cancel, " |
||||
|
// + " SUM(CASE WHEN ur.status = 5 THEN 1 ELSE 0 END) AS officer_cancel " |
||||
|
// + " FROM user_request_table ur " |
||||
|
// + " WHERE ur.is_active = 1 AND ur.is_delete = 0 AND ur.zone = ? " |
||||
|
// + ") " |
||||
|
// + "ORDER BY " |
||||
|
// + " CASE WHEN division = 'TOTAL' THEN 999 ELSE CAST(division AS UNSIGNED) END"; |
||||
|
|
||||
|
// List<Map<String, Object>> reportList = jdbcDomesticWasteTemplate.queryForList(sql, zone, zone); |
||||
|
|
||||
|
// Map<String, Object> response = new LinkedHashMap<>(); |
||||
|
// response.put("status", "Success"); |
||||
|
// response.put("message", "Ward-wise Report"); |
||||
|
// response.put("data", reportList); |
||||
|
|
||||
|
// return Collections.singletonList(response); |
||||
|
// } |
||||
|
|
||||
|
|
||||
|
|
||||
|
@Transactional(readOnly = true) |
||||
|
public List<Map<String, Object>> getWardReport(String zone) { |
||||
|
|
||||
|
String sql = """ |
||||
|
WITH date_limits AS ( |
||||
|
SELECT |
||||
|
DATE_SUB(CURDATE(), INTERVAL (DAYOFWEEK(CURDATE()) - 1) DAY) AS week_start, |
||||
|
DATE_ADD(DATE_SUB(CURDATE(), INTERVAL (DAYOFWEEK(CURDATE()) - 1) DAY), INTERVAL 7 DAY) AS week_end |
||||
|
) |
||||
|
SELECT |
||||
|
COALESCE(ur.division, 'TOTAL') AS division, |
||||
|
COUNT(*) AS total_request, |
||||
|
|
||||
|
-- Requests created this week |
||||
|
SUM(CASE WHEN ur.cdate >= d.week_start AND ur.cdate < d.week_end THEN 1 ELSE 0 END) AS this_week_requests, |
||||
|
|
||||
|
-- Older requests |
||||
|
SUM(CASE WHEN ur.cdate < d.week_start THEN 1 ELSE 0 END) AS older_requests, |
||||
|
|
||||
|
-- Status-based counts |
||||
|
SUM(CASE WHEN ur.status = 2 THEN 1 ELSE 0 END) AS completed, |
||||
|
SUM(CASE WHEN ur.status = 4 THEN 1 ELSE 0 END) AS user_cancel, |
||||
|
SUM(CASE WHEN ur.status = 5 THEN 1 ELSE 0 END) AS officer_cancel, |
||||
|
|
||||
|
-- Pending = older_requests - (completed + cancels) |
||||
|
( |
||||
|
SUM(CASE WHEN ur.cdate < d.week_start THEN 1 ELSE 0 END) |
||||
|
- SUM(CASE WHEN ur.status IN (2,4,5) THEN 1 ELSE 0 END) |
||||
|
) AS pending |
||||
|
|
||||
|
FROM |
||||
|
user_request_table ur |
||||
|
CROSS JOIN date_limits d |
||||
|
WHERE |
||||
|
ur.is_active = 1 |
||||
|
AND ur.is_delete = 0 |
||||
|
AND ur.zone = ? |
||||
|
GROUP BY |
||||
|
ur.division WITH ROLLUP |
||||
|
ORDER BY |
||||
|
CASE WHEN ur.division IS NULL THEN 999 ELSE CAST(ur.division AS UNSIGNED) END; |
||||
|
"""; |
||||
|
|
||||
|
List<Map<String, Object>> reportList = jdbcDomesticWasteTemplate.queryForList(sql, zone); |
||||
|
|
||||
|
Map<String, Object> response = new LinkedHashMap<>(); |
||||
|
response.put("status", "Success"); |
||||
|
response.put("message", "Ward-wise Report with Weekly and Pending Breakdown"); |
||||
|
response.put("data", reportList); |
||||
|
|
||||
|
return Collections.singletonList(response); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
// @Transactional(readOnly = true) |
||||
|
// public List<Map<String, Object>> getWardStatusDetails( |
||||
|
// String fromDate, String toDate, |
||||
|
// String ward, String status) { |
||||
|
|
||||
|
// // ✅ Base URL for images |
||||
|
// String fileBaseUrl = "https://gccservices.in"; // or your configured value |
||||
|
|
||||
|
// // ✅ SQL query with ward + status filters |
||||
|
// String sql = |
||||
|
// "SELECT " + |
||||
|
// " u.id, u.request_id, u.user_name, u.mobile, u.address, " + |
||||
|
// " u.latitude, u.longitude, u.zone, u.division, u.street_name, " + |
||||
|
// " u.quantity AS main_quantity, u.remarks, " + |
||||
|
// " CONCAT('" + fileBaseUrl + "/gccofficialapp/files', u.image_url) AS image_url, " + |
||||
|
// " DATE_FORMAT(u.cdate, '%d-%m-%Y') AS cdate, " + |
||||
|
// " sm.status_master AS status, " + |
||||
|
// " DATE_FORMAT(u.close_date, '%d-%m-%Y') AS close_date, " + |
||||
|
// " CONCAT('" + fileBaseUrl + "/gccofficialapp/files', u.officer_upload_url) AS officer_upload_url, " + |
||||
|
// " im.item_name, itm.quantity " + |
||||
|
// "FROM user_request_table u " + |
||||
|
// "LEFT JOIN items itm ON u.id = itm.req_table_id " + |
||||
|
// "LEFT JOIN item_master im ON itm.iteam_id = im.id AND im.is_active = 1 " + |
||||
|
// "LEFT JOIN status_master sm ON sm.id = u.status AND sm.is_active = 1 AND sm.is_delete = 0 " + |
||||
|
// "WHERE u.is_active = 1 AND u.is_delete = 0 " + |
||||
|
// " AND u.division = ? " + |
||||
|
// " AND u.status = ? " + |
||||
|
// "ORDER BY u.cdate DESC"; |
||||
|
|
||||
|
// // ✅ Execute query |
||||
|
// List<Map<String, Object>> reportList = jdbcDomesticWasteTemplate.queryForList(sql, ward, status); |
||||
|
|
||||
|
|
||||
|
// Map<String, Object> response = new LinkedHashMap<>(); |
||||
|
// response.put("status", "Success"); |
||||
|
// response.put("message", "Ward-status-wise - Report"); |
||||
|
// response.put("data", reportList); |
||||
|
|
||||
|
// return Collections.singletonList(response); |
||||
|
|
||||
|
// //return groupRequestsWithItems(reportList); |
||||
|
|
||||
|
// } |
||||
|
|
||||
|
|
||||
|
|
||||
|
@Transactional(readOnly = true) |
||||
|
public List<Map<String, Object>> getWardStatusDetails(String ward, String status) { |
||||
|
|
||||
|
// ✅ Base URL for images (you can move to application.properties later) |
||||
|
String fileBaseUrl = "https://gccservices.in"; |
||||
|
|
||||
|
// ✅ SQL query using only ward + status |
||||
|
String sql = """ |
||||
|
SELECT |
||||
|
u.id, |
||||
|
u.request_id, |
||||
|
u.user_name, |
||||
|
u.mobile, |
||||
|
u.address, |
||||
|
u.latitude, |
||||
|
u.longitude, |
||||
|
u.zone, |
||||
|
u.division, |
||||
|
u.street_name, |
||||
|
u.quantity AS main_quantity, |
||||
|
u.remarks, |
||||
|
CONCAT(?, u.image_url) AS image_url, |
||||
|
DATE_FORMAT(u.cdate, '%d-%m-%Y') AS cdate, |
||||
|
sm.status_master AS status, |
||||
|
DATE_FORMAT(u.close_date, '%d-%m-%Y') AS close_date, |
||||
|
CONCAT(?, u.officer_upload_url) AS officer_upload_url, |
||||
|
itm.iteam_id, |
||||
|
im.item_name, |
||||
|
itm.quantity |
||||
|
FROM user_request_table u |
||||
|
LEFT JOIN items itm ON u.id = itm.req_table_id |
||||
|
LEFT JOIN item_master im ON itm.iteam_id = im.id AND im.is_active = 1 |
||||
|
LEFT JOIN status_master sm ON sm.id = u.status AND sm.is_active = 1 AND sm.is_delete = 0 |
||||
|
WHERE |
||||
|
u.is_active = 1 |
||||
|
AND u.is_delete = 0 |
||||
|
AND u.division = ? |
||||
|
AND u.status = ? |
||||
|
ORDER BY u.cdate DESC |
||||
|
"""; |
||||
|
|
||||
|
// ✅ Execute query |
||||
|
List<Map<String, Object>> reportList = jdbcDomesticWasteTemplate.queryForList( |
||||
|
sql, |
||||
|
fileBaseUrl + "/gccofficialapp/files", |
||||
|
fileBaseUrl + "/gccofficialapp/files", |
||||
|
ward, |
||||
|
status |
||||
|
); |
||||
|
|
||||
|
Map<Integer, Map<String, Object>> groupedMap = new LinkedHashMap<>(); |
||||
|
|
||||
|
for (Map<String, Object> row : reportList) { |
||||
|
Integer id = (Integer) row.get("id"); |
||||
|
|
||||
|
Map<String, Object> item = null; |
||||
|
if (row.get("item_name") != null) { |
||||
|
item = new LinkedHashMap<>(); |
||||
|
item.put("item_name", row.get("item_name")); |
||||
|
item.put("quantity", row.get("quantity")); |
||||
|
} |
||||
|
|
||||
|
if (groupedMap.containsKey(id)) { |
||||
|
if (item != null) { |
||||
|
((List<Map<String, Object>>) groupedMap.get(id).get("items")).add(item); |
||||
|
} |
||||
|
} else { |
||||
|
Map<String, Object> newEntry = new LinkedHashMap<>(); |
||||
|
newEntry.put("id", id); |
||||
|
newEntry.put("request_id", row.get("request_id")); |
||||
|
newEntry.put("user_name", row.get("user_name")); |
||||
|
newEntry.put("mobile", row.get("mobile")); |
||||
|
newEntry.put("address", row.get("address")); |
||||
|
newEntry.put("latitude", row.get("latitude")); |
||||
|
newEntry.put("longitude", row.get("longitude")); |
||||
|
newEntry.put("zone", row.get("zone")); |
||||
|
newEntry.put("division", row.get("division")); |
||||
|
newEntry.put("street_name", row.get("street_name")); |
||||
|
newEntry.put("main_quantity", row.get("main_quantity")); |
||||
|
newEntry.put("remarks", row.get("remarks")); |
||||
|
newEntry.put("image_url", row.get("image_url")); |
||||
|
newEntry.put("cdate", row.get("cdate")); |
||||
|
newEntry.put("is_active", row.get("is_active")); |
||||
|
newEntry.put("is_delete", row.get("is_delete")); |
||||
|
newEntry.put("street_id", row.get("street_id")); |
||||
|
newEntry.put("status", row.get("status")); // Now this is human-readable |
||||
|
newEntry.put("is_app", row.get("is_app")); |
||||
|
newEntry.put("close_date", row.get("close_date")); |
||||
|
newEntry.put("officer_upload_url", row.get("officer_upload_url")); |
||||
|
|
||||
|
List<Map<String, Object>> items = new ArrayList<>(); |
||||
|
if (item != null) { |
||||
|
items.add(item); |
||||
|
} |
||||
|
newEntry.put("items", items); |
||||
|
|
||||
|
groupedMap.put(id, newEntry); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
|
||||
|
// ✅ Wrap response |
||||
|
Map<String, Object> response = new LinkedHashMap<>(); |
||||
|
response.put("status", "Success"); |
||||
|
response.put("message", "Ward-status-wise Report"); |
||||
|
response.put("data", groupedMap.values()); |
||||
|
|
||||
|
return Collections.singletonList(response); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,142 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.http.ResponseEntity; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
import java.util.ArrayList; |
||||
|
import java.util.HashMap; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
@Service |
||||
|
public class ToiletService { |
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
public Map<String, Object> getPack1Summary() { |
||||
|
String sql = "SELECT count(toilet_location) as pack1_toilet_location, " + |
||||
|
"sum(total_seats) as pack1_total_seat, " + |
||||
|
"SUM(CASE WHEN category = 'Major' THEN 1 ELSE 0 END) AS pack1_major_count, " + |
||||
|
"SUM(CASE WHEN category = 'Minor' THEN 1 ELSE 0 END) AS pack1_minor_count, " + |
||||
|
"SUM(CASE WHEN category = 'New' THEN 1 ELSE 0 END) AS pack1_new_count " + |
||||
|
"FROM spd_pack_1"; |
||||
|
|
||||
|
return jdbcTemplate.queryForMap(sql); |
||||
|
} |
||||
|
|
||||
|
public Map<String, Object> getSFDData() { |
||||
|
Map<String, Object> response = new HashMap<>(); |
||||
|
|
||||
|
List<Map<String,Object>> data = new ArrayList<Map<String,Object>>(); |
||||
|
Map<String, Object> pack1 = getPack1(); |
||||
|
data.add(pack1); |
||||
|
Map<String, Object> pack2 = getPack2(); |
||||
|
data.add(pack2); |
||||
|
Map<String, Object> pack3 = getPack3(); |
||||
|
data.add(pack3); |
||||
|
Map<String, Object> pack4 = getPack4(); |
||||
|
data.add(pack4); |
||||
|
response.put("Message", "Sucess"); |
||||
|
response.put("data", data); |
||||
|
return response; |
||||
|
} |
||||
|
|
||||
|
|
||||
|
private Map<String, Object> getPack4() { |
||||
|
String sql = "SELECT count(toilet_location) as pack4_toilet_location, sum(total_seats) as pack4_total_seat, " |
||||
|
+ " SUM(CASE WHEN toilet_status = 'Major' THEN 1 ELSE 0 END) AS pack4_major_count, " |
||||
|
+ " SUM(CASE WHEN toilet_status = 'Minor' THEN 1 ELSE 0 END) AS pack4_minor_count, " |
||||
|
+ " SUM(CASE WHEN toilet_status = 'New' THEN 1 ELSE 0 END) AS pack4_new_count " |
||||
|
+ " FROM " |
||||
|
+ " spd_pack_4 "; |
||||
|
try { |
||||
|
return jdbcTemplate.queryForMap(sql); |
||||
|
|
||||
|
} catch (Exception e) { |
||||
|
e.printStackTrace(); |
||||
|
return Map.of(); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
|
||||
|
private Map<String, Object> getPack3() { |
||||
|
String sql = "SELECT count(toilet_location) as pack3_toilet_location, sum(total_seats) as pack3_total_seat, " |
||||
|
+ " SUM(CASE WHEN toilet_status = 'Major' THEN 1 ELSE 0 END) AS pack3_major_count, " |
||||
|
+ " SUM(CASE WHEN toilet_status = 'Minor' THEN 1 ELSE 0 END) AS pack3_minor_count, " |
||||
|
+ " SUM(CASE WHEN toilet_status = 'New' THEN 1 ELSE 0 END) AS pack3_new_count " |
||||
|
+ " FROM " |
||||
|
+ " spd_pack_3 "; |
||||
|
try { |
||||
|
return jdbcTemplate.queryForMap(sql); |
||||
|
|
||||
|
} catch (Exception e) { |
||||
|
e.printStackTrace(); |
||||
|
return Map.of(); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
|
||||
|
private Map<String, Object> getPack2() { |
||||
|
String sql = "SELECT count(toilet_location) as pack2_toilet_location, sum(total_seats) as pack2_total_seat, " |
||||
|
+ " SUM(CASE WHEN toilet_status = 'Major' THEN 1 ELSE 0 END) AS pack2_major_count, " |
||||
|
+ " SUM(CASE WHEN toilet_status = 'Minor' THEN 1 ELSE 0 END) AS pack2_minor_count, " |
||||
|
+ " SUM(CASE WHEN toilet_status = 'New' THEN 1 ELSE 0 END) AS pack2_new_count " |
||||
|
+ " FROM " |
||||
|
+ " spd_pack_2 "; |
||||
|
try { |
||||
|
return jdbcTemplate.queryForMap(sql); |
||||
|
|
||||
|
} catch (Exception e) { |
||||
|
e.printStackTrace(); |
||||
|
return Map.of(); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
|
||||
|
private Map<String, Object> getPack1() { |
||||
|
String sql = "SELECT count(toilet_location) as pack1_toilet_location, sum(total_seats) as pack1_total_seat, " |
||||
|
+ " SUM(CASE WHEN category = 'Major' THEN 1 ELSE 0 END) AS pack1_major_count, " |
||||
|
+ " SUM(CASE WHEN category = 'Minor' THEN 1 ELSE 0 END) AS pack1_minor_count, " |
||||
|
+ " SUM(CASE WHEN category = 'New' THEN 1 ELSE 0 END) AS pack1_new_count " |
||||
|
+ " FROM " |
||||
|
+ " spd_pack_1 "; |
||||
|
try { |
||||
|
return jdbcTemplate.queryForMap(sql); |
||||
|
|
||||
|
} catch (Exception e) { |
||||
|
e.printStackTrace(); |
||||
|
return Map.of(); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
public List<Map<String,Object>> getSFDPack1(String pack) { |
||||
|
String sql = ""; |
||||
|
if(pack.equalsIgnoreCase("pack1")) { |
||||
|
sql="SELECT * FROM spd_pack_1"; |
||||
|
} else if(pack.equalsIgnoreCase("pack2")) { |
||||
|
sql="SELECT * FROM spd_pack_2"; |
||||
|
} else if(pack.equalsIgnoreCase("pack3")) { |
||||
|
sql="SELECT * FROM spd_pack_3"; |
||||
|
} else if(pack.equalsIgnoreCase("pack4")) { |
||||
|
sql="SELECT * FROM spd_pack_4"; |
||||
|
} |
||||
|
try { |
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
|
||||
|
} catch (Exception e) { |
||||
|
e.printStackTrace(); |
||||
|
return List.of(); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,54 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
@Service |
||||
|
public class UphcReportService { |
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<Map<String, Object>> getZoneWiseOpSummary() { |
||||
|
String sql = "SELECT " + |
||||
|
" zone, " + |
||||
|
" COUNT(DISTINCT phc) AS no_of_uphcs, " + |
||||
|
" SUM(jan_2025) AS jan_total_op, " + |
||||
|
" ROUND(SUM(jan_2025)/26, 2) AS jan_avg_op_day, " + |
||||
|
" SUM(feb_2025) AS feb_total_op, " + |
||||
|
" ROUND(SUM(feb_2025)/24, 2) AS feb_avg_op_day, " + |
||||
|
" SUM(mar_2025) AS mar_total_op, " + |
||||
|
" ROUND(SUM(mar_2025)/26, 2) AS mar_avg_op_day, " + |
||||
|
" SUM(apr_2025) AS apr_total_op, " + |
||||
|
" ROUND(SUM(apr_2025)/25, 2) AS apr_avg_op_day " + |
||||
|
" FROM uphc_performance " + |
||||
|
" GROUP BY zone " + |
||||
|
" ORDER BY CAST(zone AS UNSIGNED)"; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<Map<String, Object>> getUphcDetailsByZone(String zone) { |
||||
|
String sql = "SELECT phc, jan_2025, feb_2025, mar_2025, apr_2025 " + |
||||
|
" FROM uphc_performance " + |
||||
|
" WHERE zone = ? " + |
||||
|
" ORDER BY phc"; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql, zone); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,267 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import java.util.ArrayList; |
||||
|
import java.util.HashMap; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.boot.web.client.RestTemplateBuilder; |
||||
|
import org.springframework.dao.DataAccessException; |
||||
|
import org.springframework.http.HttpStatus; |
||||
|
import org.springframework.http.ResponseEntity; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
import org.springframework.web.client.RestTemplate; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
@Service |
||||
|
public class VeterinaryPetClinicService { |
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<Map<String, Object>> getPetClinicSummary() throws DataAccessException { |
||||
|
String sql = """ |
||||
|
SELECT |
||||
|
date, |
||||
|
day, |
||||
|
center_name, |
||||
|
SUM(cases_treated) AS cases_treated, |
||||
|
SUM(arv) AS arv |
||||
|
FROM |
||||
|
veterinary_petclinic |
||||
|
WHERE |
||||
|
MONTH(STR_TO_DATE(date, '%d-%m-%Y')) = 2 |
||||
|
AND YEAR(STR_TO_DATE(date, '%d-%m-%Y')) = 2025 |
||||
|
GROUP BY |
||||
|
date, day, center_name |
||||
|
ORDER BY |
||||
|
STR_TO_DATE(date, '%d-%m-%Y'), center_name |
||||
|
"""; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<String> getDistinctMonths() { |
||||
|
String sql = "SELECT DISTINCT(month) FROM veterinary_petclinic"; |
||||
|
return jdbcTemplate.queryForList(sql, String.class); |
||||
|
} |
||||
|
|
||||
|
public List<String> getDistinctCenters() { |
||||
|
String sql = "SELECT DISTINCT(center_name) FROM veterinary_petclinic"; |
||||
|
return jdbcTemplate.queryForList(sql, String.class); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getFilteredReport(String month, String centerName) { |
||||
|
String sql = "SELECT * FROM veterinary_petclinic WHERE 1=1"; |
||||
|
|
||||
|
List<Object> params = new ArrayList(); |
||||
|
if (month != null && !month.isEmpty()) { |
||||
|
sql += " AND month = ?"; |
||||
|
params.add(month); |
||||
|
} |
||||
|
if (centerName != null && !centerName.isEmpty()) { |
||||
|
sql += " AND center_name = ?"; |
||||
|
params.add(centerName); |
||||
|
} |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql, params.toArray()); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<Map<String, Object>> fetchYearlySummary() { |
||||
|
String sql = """ |
||||
|
SELECT |
||||
|
center_name, |
||||
|
|
||||
|
-- November 2024 |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '11-2024' THEN cases_treated ELSE 0 END) AS `Nov-24 Treated`, |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '11-2024' THEN arv ELSE 0 END) AS `Nov-24 ARV`, |
||||
|
|
||||
|
-- December 2024 |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '12-2024' THEN cases_treated ELSE 0 END) AS `Dec-24 Treated`, |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '12-2024' THEN arv ELSE 0 END) AS `Dec-24 ARV`, |
||||
|
|
||||
|
-- January 2025 |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '01-2025' THEN cases_treated ELSE 0 END) AS `Jan-25 Treated`, |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '01-2025' THEN arv ELSE 0 END) AS `Jan-25 ARV`, |
||||
|
|
||||
|
-- February 2025 |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '02-2025' THEN cases_treated ELSE 0 END) AS `Feb-25 Treated`, |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '02-2025' THEN arv ELSE 0 END) AS `Feb-25 ARV`, |
||||
|
|
||||
|
-- March 2025 |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '03-2025' THEN cases_treated ELSE 0 END) AS `Mar-25 Treated`, |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '03-2025' THEN arv ELSE 0 END) AS `Mar-25 ARV`, |
||||
|
|
||||
|
-- April 2025 |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '04-2025' THEN cases_treated ELSE 0 END) AS `Apr-25 Treated`, |
||||
|
SUM(CASE WHEN RIGHT(date, 7) = '04-2025' THEN arv ELSE 0 END) AS `Apr-25 ARV` |
||||
|
|
||||
|
FROM veterinary_petclinic |
||||
|
WHERE is_active = 1 AND is_delete = 0 |
||||
|
GROUP BY center_name |
||||
|
ORDER BY center_name; |
||||
|
|
||||
|
"""; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<Map<String, Object>> AbcReportSummary() { |
||||
|
String sql = """ |
||||
|
SELECT |
||||
|
month, |
||||
|
|
||||
|
SUM(pulianthope) AS 'Pulianthope Sterilized', |
||||
|
SUM(llyods_colony) AS 'Llyods Colony Sterilized', |
||||
|
SUM(kannammapet) AS 'Kannammapet Sterilized', |
||||
|
SUM(meenambakkam) AS 'Meenambakkam Sterilized', |
||||
|
SUM(sholinganallur) AS 'Sholinganallur Sterilized', |
||||
|
SUM(total) AS 'Total Sterilized' |
||||
|
|
||||
|
FROM veterinary_abc |
||||
|
WHERE is_active = 1 AND is_delete = 0 |
||||
|
GROUP BY month |
||||
|
ORDER BY FIELD(month, 'Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'); |
||||
|
"""; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<Map<String, Object>> getPetClinicConsolidatedReport() { |
||||
|
String sql = "SELECT date AS reportdate, center_name, cases_treated, arv FROM veterinary_petclinic"; |
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public ResponseEntity<?> getZoneWiseCattleData() { |
||||
|
|
||||
|
Map<String, Object> response = new HashMap<>(); |
||||
|
|
||||
|
try { |
||||
|
String[] zoneColumns = new String[15]; |
||||
|
String[] zoneNames = new String[15]; |
||||
|
|
||||
|
int[] totalvalue = new int[8]; |
||||
|
for (int i = 0; i < 15; i++) { |
||||
|
zoneColumns[i] = "zone_" + (i + 1); |
||||
|
zoneNames[i] = "Zone " + (i + 1); |
||||
|
} |
||||
|
|
||||
|
List<Map<String, Object>> resultList = new ArrayList<>(); |
||||
|
List<Map<String, Object>> totalresult = new ArrayList<>(); |
||||
|
|
||||
|
for (int i = 0; i < 15; i++) { |
||||
|
String zoneCol = zoneColumns[i]; |
||||
|
String displayName = zoneNames[i]; |
||||
|
|
||||
|
String sql = "SELECT " + |
||||
|
"SUM(CASE WHEN month = 'Nov-24' THEN CAST(" + zoneCol + " AS UNSIGNED) ELSE 0 END) AS Nov2024, " + |
||||
|
"SUM(CASE WHEN month = 'Dec-24' THEN CAST(" + zoneCol + " AS UNSIGNED) ELSE 0 END) AS Dec2024, " + |
||||
|
"SUM(CASE WHEN month = 'Jan-25' THEN CAST(" + zoneCol + " AS UNSIGNED) ELSE 0 END) AS Jan2025, " + |
||||
|
"SUM(CASE WHEN month = 'Feb-25' THEN CAST(" + zoneCol + " AS UNSIGNED) ELSE 0 END) AS Feb2025, " + |
||||
|
"SUM(CASE WHEN month = 'Mar-25' THEN CAST(" + zoneCol + " AS UNSIGNED) ELSE 0 END) AS Mar2025, " + |
||||
|
"SUM(CASE WHEN month = 'Apr-25' THEN CAST(" + zoneCol + " AS UNSIGNED) ELSE 0 END) AS Apr2025 " + |
||||
|
"FROM veterinary_cattle"; |
||||
|
|
||||
|
Map<String, Object> row = jdbcTemplate.queryForMap(sql); |
||||
|
row.put("zone", displayName); |
||||
|
row.put("zoneIndex", i + 1); |
||||
|
|
||||
|
resultList.add(row); |
||||
|
} |
||||
|
|
||||
|
String tsql = "SELECT " |
||||
|
+ " month," |
||||
|
+ " SUM(zone_1) + SUM(zone_2) + SUM(zone_3) + SUM(zone_4) + SUM(zone_5) + " |
||||
|
+ " SUM(zone_6) + SUM(zone_7) + SUM(zone_8) + SUM(zone_9) + SUM(zone_10) + " |
||||
|
+ " SUM(zone_11) + SUM(zone_12) + SUM(zone_13) + SUM(zone_14) + SUM(zone_15) AS total_zone_sum " |
||||
|
+ "FROM veterinary_cattle " |
||||
|
+ "WHERE month IN ('Nov-24', 'Dec-24', 'Jan-25', 'Feb-25', 'Mar-25', 'Apr-25') " |
||||
|
+ "GROUP BY month " |
||||
|
+ "ORDER BY FIELD(month, 'totalNov', 'totalDec', 'totalJan', 'totalFeb', 'totalMar', 'totalApr')"; |
||||
|
|
||||
|
// Execute the total sum query and get the results as a list of maps |
||||
|
totalresult = jdbcTemplate.queryForList(tsql); |
||||
|
|
||||
|
if (resultList.isEmpty()) { |
||||
|
response.put("status", "nodata"); |
||||
|
response.put("message", "No data found"); |
||||
|
response.put("data", "No Data"); |
||||
|
} else { |
||||
|
response.put("status", "success"); |
||||
|
response.put("message", "Data retrieved successfully"); |
||||
|
response.put("data", resultList); |
||||
|
response.put("total", totalresult); |
||||
|
} |
||||
|
|
||||
|
return ResponseEntity.ok(response); |
||||
|
|
||||
|
} catch (Exception e) { |
||||
|
response.put("status", "error"); |
||||
|
response.put("message", "Backend error: " + e.getMessage()); |
||||
|
response.put("data", null); |
||||
|
return ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR).body(response); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> getData() { |
||||
|
String sql = """ |
||||
|
( |
||||
|
SELECT |
||||
|
month, |
||||
|
perambur, |
||||
|
villivakkam, |
||||
|
kallikuppam, |
||||
|
saidapet, |
||||
|
(COALESCE(perambur,0) + COALESCE(villivakkam,0) + COALESCE(kallikuppam,0) + COALESCE(saidapet,0)) AS total |
||||
|
FROM veterinary_slaughter |
||||
|
WHERE year > 2024 |
||||
|
) |
||||
|
UNION ALL |
||||
|
( |
||||
|
SELECT |
||||
|
'Total' AS month, |
||||
|
SUM(perambur) AS perambur, |
||||
|
SUM(villivakkam) AS villivakkam, |
||||
|
SUM(kallikuppam) AS kallikuppam, |
||||
|
SUM(saidapet) AS saidapet, |
||||
|
SUM(COALESCE(perambur,0) + COALESCE(villivakkam,0) + COALESCE(kallikuppam,0) + COALESCE(saidapet,0)) AS total |
||||
|
FROM veterinary_slaughter |
||||
|
WHERE year > 2024 |
||||
|
) |
||||
|
"""; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> ViewMeatRaidReport() { |
||||
|
String sql = "SELECT zone, " + |
||||
|
"MAX(CASE WHEN month = 'January' THEN visited_2025 END) AS jan_visited, " + |
||||
|
"MAX(CASE WHEN month = 'January' THEN seized_2025 END) AS jan_seized, " + |
||||
|
"MAX(CASE WHEN month = 'February' THEN visited_2025 END) AS feb_visited, " + |
||||
|
"MAX(CASE WHEN month = 'February' THEN seized_2025 END) AS feb_seized, " + |
||||
|
"MAX(CASE WHEN month = 'March' THEN visited_2025 END) AS mar_visited, " + |
||||
|
"MAX(CASE WHEN month = 'March' THEN seized_2025 END) AS mar_seized, " + |
||||
|
"MAX(CASE WHEN month = 'April' THEN visited_2025 END) AS apr_visited, " + |
||||
|
"MAX(CASE WHEN month = 'April' THEN seized_2025 END) AS apr_seized " + |
||||
|
"FROM meat_raid " + |
||||
|
"WHERE month IN ('January', 'February', 'March', 'April') " + |
||||
|
"GROUP BY zone "; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,46 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
@Service |
||||
|
public class makkaludanMudalvarService { |
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> ViewProgressReport() { |
||||
|
String sql = "SELECT ticket_owner_name,\r\n" |
||||
|
+ "COUNT(CASE WHEN status_display = 'Accepted' THEN 1 END) AS Accepted,\r\n" |
||||
|
+ "COUNT(CASE WHEN status_display = 'Accepted and Waitlisted' THEN 1 END) AS Accepted_Waitlisted,\r\n" |
||||
|
+ "COUNT(CASE WHEN status_display = 'Pending Action' THEN 1 END) AS Pending_Action,\r\n" |
||||
|
+ "COUNT(CASE WHEN status_display = 'Received' THEN 1 END) AS Received,\r\n" |
||||
|
+ "COUNT(CASE WHEN status_display = 'Rejected' THEN 1 END) AS Rejected,\r\n" |
||||
|
+ "COUNT(*) AS grand_total\r\n" |
||||
|
+ "FROM grievance_details\r\n" |
||||
|
+ "GROUP BY ticket_owner_name\r\n" |
||||
|
+ "ORDER BY ticket_owner_name;"; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> viewProgressReportList(String ticketOwnerName, String statusDisplay) { |
||||
|
String sql = "SELECT petitioner,ticket_owner_name,status_display,grievance_subtype,petition_details,ticket_age,close_days,status_1 " |
||||
|
+ "FROM grievance_details " |
||||
|
+ "WHERE ticket_owner_name = ? AND status_display = ?"; |
||||
|
return jdbcTemplate.queryForList(sql, ticketOwnerName, statusDisplay); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,75 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
|
||||
|
@Service |
||||
|
public class mobileDiagonosticService { |
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> fetchMonthlyCampData() { |
||||
|
String sql = """ |
||||
|
SELECT |
||||
|
zone, |
||||
|
|
||||
|
SUM(CASE WHEN month = 'Jan-25' THEN camps_conducted ELSE 0 END) AS jan_camps, |
||||
|
SUM(CASE WHEN month = 'Jan-25' THEN target_population ELSE 0 END) AS jan_target, |
||||
|
SUM(CASE WHEN month = 'Jan-25' THEN screened ELSE 0 END) AS jan_screened, |
||||
|
|
||||
|
SUM(CASE WHEN month = 'Feb-25' THEN camps_conducted ELSE 0 END) AS feb_camps, |
||||
|
SUM(CASE WHEN month = 'Feb-25' THEN target_population ELSE 0 END) AS feb_target, |
||||
|
SUM(CASE WHEN month = 'Feb-25' THEN screened ELSE 0 END) AS feb_screened, |
||||
|
|
||||
|
SUM(CASE WHEN month = 'Mar-25' THEN camps_conducted ELSE 0 END) AS mar_camps, |
||||
|
SUM(CASE WHEN month = 'Mar-25' THEN target_population ELSE 0 END) AS mar_target, |
||||
|
SUM(CASE WHEN month = 'Mar-25' THEN screened ELSE 0 END) AS mar_screened, |
||||
|
|
||||
|
SUM(CASE WHEN month = 'Apr-25' THEN camps_conducted ELSE 0 END) AS apr_camps, |
||||
|
SUM(CASE WHEN month = 'Apr-25' THEN target_population ELSE 0 END) AS apr_target, |
||||
|
SUM(CASE WHEN month = 'Apr-25' THEN screened ELSE 0 END) AS apr_screened |
||||
|
|
||||
|
FROM mobile_diagonostic |
||||
|
GROUP BY zone |
||||
|
ORDER BY zone |
||||
|
"""; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> fetchZoneDetails(String zone) { |
||||
|
String sql = """ |
||||
|
SELECT |
||||
|
zone, |
||||
|
month, |
||||
|
target_population, |
||||
|
screened AS no_screened, |
||||
|
presumptive_identified, |
||||
|
x_rays_taken, |
||||
|
normal_x_rays, |
||||
|
abnormal_x_rays, |
||||
|
sputum_collected, |
||||
|
sputum_positive, |
||||
|
mc_tb, |
||||
|
cd_tb, |
||||
|
total_positive |
||||
|
FROM mobile_diagonostic |
||||
|
WHERE zone = ? """; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql, zone); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,44 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
@Service |
||||
|
public class mudhalvarinMugavariService { |
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> ViewPendencyReport() { |
||||
|
String sql = "SELECT ticket_owner_name,\r\n" |
||||
|
+ "COUNT(CASE WHEN status_display = 'In Process' THEN 1 END) AS In_Process, \r\n" |
||||
|
+ "COUNT(CASE WHEN status_display = 'Pending Action' THEN 1 END) AS Pending_Action,\r\n" |
||||
|
+ "COUNT(CASE WHEN status_display = 'Received' THEN 1 END) AS Received,\r\n" |
||||
|
+ "COUNT(*) AS grand_total\r\n" |
||||
|
+ "FROM mudhalvarin_mugavari\r\n" |
||||
|
+ "GROUP BY ticket_owner_name\r\n" |
||||
|
+ "ORDER BY ticket_owner_name;"; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> viewPendencyReportList(String ticketOwnerName, String statusDisplay) { |
||||
|
String sql = "SELECT petitioner, ticket_owner_name, status_display, grievance_subtype, ticket_age " + |
||||
|
"FROM mudhalvarin_mugavari " + |
||||
|
"WHERE ticket_owner_name = ? AND status_display = ?"; |
||||
|
return jdbcTemplate.queryForList(sql, ticketOwnerName, statusDisplay); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,39 @@ |
|||||
|
package com.gcc.commissionerreview.service; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
import javax.sql.DataSource; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Qualifier; |
||||
|
import org.springframework.jdbc.core.JdbcTemplate; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
@Service |
||||
|
public class urbangreenService { |
||||
|
|
||||
|
@Autowired |
||||
|
private JdbcTemplate jdbcTemplate; |
||||
|
|
||||
|
@Autowired |
||||
|
public void setDataSource(@Qualifier("mydatasource") DataSource dataSource) { |
||||
|
this.jdbcTemplate = new JdbcTemplate(dataSource); |
||||
|
} |
||||
|
|
||||
|
public List<Map<String, Object>> ViewUrbanGreenReport() { |
||||
|
String sql = "SELECT zone, phase, sum(saplings_planted) as saplings_planted, " |
||||
|
+ "sum(saplings_survived) as saplings_survived " |
||||
|
+ "FROM urbangreen group by zone, phase order by CAST(zone AS UNSIGNED) ASC;\r\n"; |
||||
|
|
||||
|
return jdbcTemplate.queryForList(sql); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public List<Map<String, Object>> ViewUrbanGreenReportList(String zone, String phase) { |
||||
|
String sql = "SELECT zone, phase, location, saplings_planted, saplings_survived " |
||||
|
+ "FROM urbangreen where zone=? and phase=?;"; |
||||
|
return jdbcTemplate.queryForList(sql, zone, phase); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,18 @@ |
|||||
|
spring.application.name=commissionerreview |
||||
|
|
||||
|
|
||||
|
#spring.datasource.url=jdbc:mysql://localhost:3306/commssioner_review |
||||
|
#spring.datasource.username=root |
||||
|
#spring.datasource.password=root |
||||
|
#spring.jpa.show-sql=true |
||||
|
#spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver |
||||
|
server.port=8078 |
||||
|
|
||||
|
# === Secondary Database === |
||||
|
#secondary.datasource.url=jdbc:oracle:thin:@10.1.0.14:1521:chncorp |
||||
|
#secondary.datasource.username=FAS |
||||
|
#secondary.datasource.password=FAS |
||||
|
#secondary.datasource.driver-class-name=oracle.jdbc.OracleDriver |
||||
|
|
||||
|
|
||||
|
|
||||
@ -0,0 +1,36 @@ |
|||||
|
spring.application.name=commissionerreview |
||||
|
|
||||
|
|
||||
|
#spring.datasource.url=jdbc:mysql://gcc-facial-db-instance-1.cf48eqcciziq.ap-south-1.rds.amazonaws.com:3306/commissioner_review |
||||
|
#spring.datasource.username=root |
||||
|
#spring.datasource.password=gcc-facial-password |
||||
|
#spring.jpa.show-sql=true |
||||
|
#spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver |
||||
|
|
||||
|
server.port=8078 |
||||
|
|
||||
|
|
||||
|
# JDBC URL |
||||
|
spring.datasource.url=jdbc:mysql://gcc-facial-db-instance-1.cf48eqcciziq.ap-south-1.rds.amazonaws.com:3306/commissioner_review |
||||
|
|
||||
|
# Database username |
||||
|
spring.datasource.username=root |
||||
|
|
||||
|
# Database password |
||||
|
spring.datasource.password=gcc-facial-password |
||||
|
|
||||
|
# HikariCP settings (optional but recommended) |
||||
|
spring.datasource.hikari.maximum-pool-size=10 |
||||
|
spring.datasource.hikari.minimum-idle=5 |
||||
|
spring.datasource.hikari.idle-timeout=30000 |
||||
|
spring.datasource.hikari.connection-timeout=30000 |
||||
|
spring.datasource.hikari.max-lifetime=1800000 |
||||
|
|
||||
|
# JDBC driver class name |
||||
|
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver |
||||
|
|
||||
|
# Log level for root (everything) |
||||
|
#logging.level.root= |
||||
|
|
||||
|
# OR for detailed debugging: |
||||
|
logging.level.root=DEBUG |
||||
@ -0,0 +1,36 @@ |
|||||
|
spring.application.name=commissionerreview |
||||
|
|
||||
|
|
||||
|
#spring.datasource.url=jdbc:mysql://gcc-facial-db-instance-1.cf48eqcciziq.ap-south-1.rds.amazonaws.com:3306/commissioner_review |
||||
|
#spring.datasource.username=root |
||||
|
#spring.datasource.password=gcc-facial-password |
||||
|
#spring.jpa.show-sql=true |
||||
|
#spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver |
||||
|
|
||||
|
server.port=8080 |
||||
|
|
||||
|
|
||||
|
# JDBC URL |
||||
|
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/commissioner_review |
||||
|
|
||||
|
# Database username |
||||
|
spring.datasource.username=root |
||||
|
|
||||
|
# Database password |
||||
|
spring.datasource.password=Bonton#2K24 |
||||
|
|
||||
|
# HikariCP settings (optional but recommended) |
||||
|
spring.datasource.hikari.maximum-pool-size=10 |
||||
|
spring.datasource.hikari.minimum-idle=5 |
||||
|
spring.datasource.hikari.idle-timeout=30000 |
||||
|
spring.datasource.hikari.connection-timeout=30000 |
||||
|
spring.datasource.hikari.max-lifetime=1800000 |
||||
|
|
||||
|
# JDBC driver class name |
||||
|
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver |
||||
|
|
||||
|
# Log level for root (everything) |
||||
|
logging.level.root=ERROR |
||||
|
|
||||
|
# OR for detailed debugging: |
||||
|
# logging.level.root=DEBUG |
||||
@ -0,0 +1 @@ |
|||||
|
spring.profiles.active=dev |
||||
@ -0,0 +1,35 @@ |
|||||
|
<script src="node_modules/datatable/jQuery-3.7.0/jquery-3.7.0.min.js"></script> |
||||
|
|
||||
|
<script src="node_modules/popper.js/dist/umd/popper.min.js"></script> |
||||
|
<script src="node_modules/bootstrap/dist/js/bootstrap.min.js"></script> |
||||
|
<script src="node_modules/perfect-scrollbar/dist/perfect-scrollbar.min.js"></script> |
||||
|
<script src="node_modules/select2/dist/js/select2.min.js"></script> |
||||
|
<script src="node_modules/screenfull/dist/screenfull.js"></script> |
||||
|
<script src="node_modules/moment/moment.js"></script> |
||||
|
<script src="node_modules/sweetalert2/sweetalert2.min.js"></script> |
||||
|
|
||||
|
<script src="node_modules/datatable/JSZip-3.10.1/jszip.min.js"></script> |
||||
|
<script src="node_modules/datatable/pdfmake-0.2.7/pdfmake.min.js"></script> |
||||
|
<script src="node_modules/datatable/pdfmake-0.2.7/vfs_fonts.js"></script> |
||||
|
<script src="node_modules/datatable/DataTables-1.13.6/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="node_modules/datatable/AutoFill-2.6.0/js/dataTables.autoFill.min.js"></script> |
||||
|
<script src="node_modules/datatable/Buttons-2.4.1/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="node_modules/datatable/Buttons-2.4.1/js/buttons.bootstrap4.min.js"></script> |
||||
|
<script src="node_modules/datatable/Buttons-2.4.1/js/buttons.colVis.min.js"></script> |
||||
|
<script src="node_modules/datatable/Buttons-2.4.1/js/buttons.html5.min.js"></script> |
||||
|
<script src="node_modules/datatable/Buttons-2.4.1/js/buttons.print.min.js"></script> |
||||
|
<script src="node_modules/datatable/ColReorder-1.7.0/js/dataTables.colReorder.min.js"></script> |
||||
|
<script src="node_modules/datatable/DateTime-1.5.1/js/dataTables.dateTime.min.js"></script> |
||||
|
<script src="node_modules/datatable/FixedColumns-4.3.0/js/dataTables.fixedColumns.min.js"></script> |
||||
|
<script src="node_modules/datatable/FixedHeader-3.4.0/js/dataTables.fixedHeader.min.js"></script> |
||||
|
<script src="node_modules/datatable/KeyTable-2.10.0/js/dataTables.keyTable.min.js"></script> |
||||
|
<script src="node_modules/datatable/Responsive-2.5.0/js/dataTables.responsive.min.js"></script> |
||||
|
<script src="node_modules/datatable/RowGroup-1.4.0/js/dataTables.rowGroup.min.js"></script> |
||||
|
<script src="node_modules/datatable/RowReorder-1.4.1/js/dataTables.rowReorder.min.js"></script> |
||||
|
<script src="node_modules/datatable/Scroller-2.2.0/js/dataTables.scroller.min.js"></script> |
||||
|
<script src="node_modules/datatable/SearchBuilder-1.5.0/js/dataTables.searchBuilder.min.js"></script> |
||||
|
<script src="node_modules/datatable/SearchPanes-2.2.0/js/dataTables.searchPanes.min.js"></script> |
||||
|
<script src="node_modules/datatable/Select-1.7.0/js/dataTables.select.min.js"></script> |
||||
|
<script src="node_modules/datatable/StateRestore-1.3.0/js/dataTables.stateRestore.min.js"></script> |
||||
|
|
||||
|
<script src="dist/js/theme.js"></script> |
||||
@ -0,0 +1,91 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Construction and Demolition Waste Report</title> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<style> |
||||
|
body { |
||||
|
padding: 40px; |
||||
|
font-family: Arial, sans-serif; |
||||
|
} |
||||
|
|
||||
|
h2 { |
||||
|
/*background-color: #b3e5fc;*/ |
||||
|
padding: 15px; |
||||
|
text-align: center; |
||||
|
font-weight: bold; |
||||
|
} |
||||
|
|
||||
|
table { |
||||
|
width: 100%; |
||||
|
border-collapse: collapse; |
||||
|
margin-top: 20px; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
text-align: center; |
||||
|
padding: 10px; |
||||
|
border: 1px solid #000; |
||||
|
} |
||||
|
|
||||
|
td { |
||||
|
text-align: center; |
||||
|
padding: 10px; |
||||
|
border: 1px solid #000; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
<h2>Construction and Demolition waste Processing (01.05.2025 to 15.05.2025) - Conditional COD 20.04.2022</h2> |
||||
|
<table> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>S.No.</th> |
||||
|
<th>Location</th> |
||||
|
<th>Inward quantity in MT</th> |
||||
|
<th>Processed quantity in MT</th> |
||||
|
<th>Performance %</th> |
||||
|
<th>Dispatched Quantity (MT)</th> |
||||
|
<th>Backlog quantity (MT) as on 15.05.2025</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr> |
||||
|
<td>1</td> |
||||
|
<td>KDG</td> |
||||
|
<td>7291.79</td> |
||||
|
<td>12975</td> |
||||
|
<td>178%</td> |
||||
|
<td>4095</td> |
||||
|
<td>15127</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>2</td> |
||||
|
<td>PDG</td> |
||||
|
<td>7197.44</td> |
||||
|
<td>13816</td> |
||||
|
<td>192%</td> |
||||
|
<td>2986</td> |
||||
|
<td>28403</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td><strong>TOTAL</strong></td> |
||||
|
<td></td> |
||||
|
<td><strong>14489</strong></td> |
||||
|
<td><strong>26791</strong></td> |
||||
|
<td></td> |
||||
|
<td><strong>7081</strong></td> |
||||
|
<td><strong>43530</strong></td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,113 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Garden Waste & Tender Coconut Report</title> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<style> |
||||
|
body { |
||||
|
padding: 40px; |
||||
|
font-family: Arial, sans-serif; |
||||
|
} |
||||
|
|
||||
|
h2 { |
||||
|
/*background-color: #b3e5fc;*/ |
||||
|
padding: 15px; |
||||
|
text-align: center; |
||||
|
font-weight: bold; |
||||
|
} |
||||
|
|
||||
|
table { |
||||
|
width: 100%; |
||||
|
border-collapse: collapse; |
||||
|
margin-top: 20px; |
||||
|
} |
||||
|
|
||||
|
th, td { |
||||
|
border: 1px solid #000; |
||||
|
text-align: center; |
||||
|
padding: 8px; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
<h2>Garden Waste and Tender Coconut Processing (01.05.2025 to 15.05.2025) - COD 23.12.2021</h2> |
||||
|
<table> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th rowspan="2">S.No</th> |
||||
|
<th rowspan="2">Location</th> |
||||
|
<th colspan="3">Inward in MT</th> |
||||
|
<th colspan="3">Processed in MT</th> |
||||
|
<th rowspan="2">Performance %</th> |
||||
|
<th colspan="3">Backlog quantity (MT) as on 15.05.2025</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Garden waste</th> |
||||
|
<th>Tender Coconut</th> |
||||
|
<th>Total</th> |
||||
|
<th>Garden waste</th> |
||||
|
<th>Tender Coconut</th> |
||||
|
<th>Total</th> |
||||
|
<th>Garden waste</th> |
||||
|
<th>Tender Coconut</th> |
||||
|
<th>Total</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr> |
||||
|
<td>1</td> |
||||
|
<td>KDG</td> |
||||
|
<td>157</td> |
||||
|
<td>202</td> |
||||
|
<td>359</td> |
||||
|
<td>214</td> |
||||
|
<td>140</td> |
||||
|
<td>354</td> |
||||
|
<td>99%</td> |
||||
|
<td>3799</td> |
||||
|
<td>9241</td> |
||||
|
<td>13040</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>2</td> |
||||
|
<td>PDG</td> |
||||
|
<td>384</td> |
||||
|
<td>679</td> |
||||
|
<td>1063</td> |
||||
|
<td>283</td> |
||||
|
<td>723</td> |
||||
|
<td>1006</td> |
||||
|
<td>95%</td> |
||||
|
<td>8632</td> |
||||
|
<td>10261</td> |
||||
|
<td>18893</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td><strong>Total</strong></td> |
||||
|
<td></td> |
||||
|
<td><strong>541</strong></td> |
||||
|
<td><strong>881</strong></td> |
||||
|
<td><strong>1422</strong></td> |
||||
|
<td><strong>497</strong></td> |
||||
|
<td><strong>863</strong></td> |
||||
|
<td><strong>1360</strong></td> |
||||
|
<td><strong>96%</strong></td> |
||||
|
<td><strong>12431</strong></td> |
||||
|
<td><strong>19502</strong></td> |
||||
|
<td><strong>31933</strong></td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,82 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Bio-CNG Chetpet Report</title> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<style> |
||||
|
body { |
||||
|
padding: 40px; |
||||
|
font-family: Arial, sans-serif; |
||||
|
} |
||||
|
|
||||
|
h2 { |
||||
|
background-color: #f5f8fa; |
||||
|
padding: 15px; |
||||
|
text-align: center; |
||||
|
font-weight: bold; |
||||
|
} |
||||
|
|
||||
|
table { |
||||
|
width: 100%; |
||||
|
border-collapse: collapse; |
||||
|
margin-top: 20px; |
||||
|
} |
||||
|
|
||||
|
th, td { |
||||
|
border: 1px solid #000; |
||||
|
text-align: center; |
||||
|
padding: 8px; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
<h2>Bio-CNG Chetpet (01.05.2025 to 15.05.2025) - COD 15.11.2021</h2> |
||||
|
<table> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>S.No</th> |
||||
|
<th>Location</th> |
||||
|
<th>Inward in MT</th> |
||||
|
<th>Rejects in MT</th> |
||||
|
<th>Processed in MT</th> |
||||
|
<th>Gas produced in MT</th> |
||||
|
<th>% of pure gas produced</th> |
||||
|
<th>Dispatched Quantity (MT)</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr> |
||||
|
<td>1</td> |
||||
|
<td>Chetpet</td> |
||||
|
<td>2248.53</td> |
||||
|
<td>114.25</td> |
||||
|
<td>2134.28</td> |
||||
|
<td>36</td> |
||||
|
<td>1.70%</td> |
||||
|
<td>32</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>2</td> |
||||
|
<td>Madhavaram</td> |
||||
|
<td>281.83</td> |
||||
|
<td>12.46</td> |
||||
|
<td>269.37</td> |
||||
|
<td>0</td> |
||||
|
<td>0%</td> |
||||
|
<td>0</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,209 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Combined Bio-Mining Project Report</title> |
||||
|
<style> |
||||
|
body { |
||||
|
font-family: Arial, sans-serif; |
||||
|
padding: 20px; |
||||
|
font-size: 14px; |
||||
|
} |
||||
|
|
||||
|
h2 { |
||||
|
padding: 10px; |
||||
|
} |
||||
|
|
||||
|
table { |
||||
|
width: 100%; |
||||
|
border-collapse: collapse; |
||||
|
margin-top: 10px; |
||||
|
} |
||||
|
|
||||
|
th, td { |
||||
|
border: 1px solid #000; |
||||
|
padding: 6px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<h2>Perungudi Bio-mining Project (as on 12.05.2025)</h2> |
||||
|
<table> |
||||
|
<tr> |
||||
|
<th>Package</th> |
||||
|
<th>Name of the Contractor</th> |
||||
|
<th>Volume of Legacy waste to be processed in Cu.m</th> |
||||
|
<th>Volume of Legacy waste processed in Cu.m</th> |
||||
|
<th>% of completion</th> |
||||
|
<th>Total volume disposed till 12-05-2025 (m3)</th> |
||||
|
<th>% of volume Disposed in the revised volume</th> |
||||
|
<th>Remarks</th> |
||||
|
<th>Payment Released as on date in Crores.</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package I</td> |
||||
|
<td>Westart</td> |
||||
|
<td>3,74,236</td> |
||||
|
<td>2,78,643</td> |
||||
|
<td>74%</td> |
||||
|
<td>157618</td> |
||||
|
<td>43%</td> |
||||
|
<td>Pre termination Notice issued. Under Arbitration</td> |
||||
|
<td>21.8 (-54.23%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package II</td> |
||||
|
<td>Westart</td> |
||||
|
<td>4,24,015</td> |
||||
|
<td>3,07,562</td> |
||||
|
<td>73%</td> |
||||
|
<td>205930</td> |
||||
|
<td>50%</td> |
||||
|
<td>Pre termination Notice issued. Under Arbitration</td> |
||||
|
<td>24.2 (-53.04%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package III</td> |
||||
|
<td>Zigma</td> |
||||
|
<td>5,91,133</td> |
||||
|
<td>5,91,133</td> |
||||
|
<td>100%</td> |
||||
|
<td>591133</td> |
||||
|
<td>100%</td> |
||||
|
<td>completed</td> |
||||
|
<td>62.88 (-100%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package IV</td> |
||||
|
<td>Zigma</td> |
||||
|
<td>5,52,321</td> |
||||
|
<td>5,52,321</td> |
||||
|
<td>100%</td> |
||||
|
<td>672873</td> |
||||
|
<td>100%</td> |
||||
|
<td>completed</td> |
||||
|
<td>58.8 (-100%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package V</td> |
||||
|
<td>Zigma</td> |
||||
|
<td>5,87,130</td> |
||||
|
<td>5,87,130</td> |
||||
|
<td>100%</td> |
||||
|
<td>627332</td> |
||||
|
<td>100%</td> |
||||
|
<td>completed</td> |
||||
|
<td>62.49 (-100%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package VI</td> |
||||
|
<td>Westart</td> |
||||
|
<td>5,32,750</td> |
||||
|
<td>1,88,938</td> |
||||
|
<td>35%</td> |
||||
|
<td>89953</td> |
||||
|
<td>17%</td> |
||||
|
<td>Termination notice issued Under Arbitration</td> |
||||
|
<td>14.22 (-33%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th colspan="2">TOTAL</th> |
||||
|
<th>30,61,585</th> |
||||
|
<th>25,05,727</th> |
||||
|
<th>82%</th> |
||||
|
<th>23,55,104</th> |
||||
|
<th>77%</th> |
||||
|
<th></th> |
||||
|
<th>244.39 (-74%)</th> |
||||
|
</tr> |
||||
|
</table> |
||||
|
|
||||
|
<h2>Bio Mining - Kodungaiyur (as on 16.05.2025)</h2> |
||||
|
<table> |
||||
|
<tr> |
||||
|
<th>Package</th> |
||||
|
<th>Name of the Contractor</th> |
||||
|
<th>Volume of Legacy waste to be processed in MT</th> |
||||
|
<th>Volume of Legacy waste processed in MT</th> |
||||
|
<th>% of completion</th> |
||||
|
<th>Disposal in MT</th> |
||||
|
<th>Payment Released as on date in Crores.</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package I</td> |
||||
|
<td>Zigma Global Environ Solutions</td> |
||||
|
<td>21,20,090.76</td> |
||||
|
<td>4,90,747.28</td> |
||||
|
<td>23.14%</td> |
||||
|
<td>2,77,802.33 (-13.10%)</td> |
||||
|
<td>18.61 (-9.11%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package II</td> |
||||
|
<td>Ramky Infrastructure Limited</td> |
||||
|
<td>4,14,213.08</td> |
||||
|
<td>42,592.91</td> |
||||
|
<td>10.28%</td> |
||||
|
<td>15,950.17 (-3.85%)</td> |
||||
|
<td>-</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package III</td> |
||||
|
<td>Ascent E digit Solution Pvt. Ltd</td> |
||||
|
<td>11,35,376.55</td> |
||||
|
<td>2,51,103.02</td> |
||||
|
<td>22.11%</td> |
||||
|
<td>98,945.65 (-8.71%)</td> |
||||
|
<td>8.02 (-7.33%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package IV</td> |
||||
|
<td>Zigma Global Environ Solutions</td> |
||||
|
<td>4,41,202.95</td> |
||||
|
<td>1,27,342.19</td> |
||||
|
<td>28.88%</td> |
||||
|
<td>65,661.94 (-14.88%)</td> |
||||
|
<td>2.94 (-6.97%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package V</td> |
||||
|
<td>Ramky Infrastructure Limited</td> |
||||
|
<td>18,35,204.18</td> |
||||
|
<td>12,295.11</td> |
||||
|
<td>0.66%</td> |
||||
|
<td>1855.29 (-0.1%)</td> |
||||
|
<td>-</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package VI</td> |
||||
|
<td>Zigma Global Environ Solutions</td> |
||||
|
<td>7,06,418.15</td> |
||||
|
<td>2,19,070.44</td> |
||||
|
<td>31.01%</td> |
||||
|
<td>94,891.36 (-13.43%)</td> |
||||
|
<td>6.08 (-8.93%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th colspan="2">TOTAL</th> |
||||
|
<th>66,52,505</th> |
||||
|
<th>11,43,150.95</th> |
||||
|
<th>19.34%</th> |
||||
|
<th>5,55,106.74 (-9.01%)</th> |
||||
|
<th>25.65 (-5.39%)</th> |
||||
|
</tr> |
||||
|
</table> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,143 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Compound Wall for Playfields</title> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<style> |
||||
|
body { |
||||
|
font-family: Arial, sans-serif; |
||||
|
padding: 30px; |
||||
|
background-color: #f8f9fa; |
||||
|
} |
||||
|
h4 { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
padding: 10px; |
||||
|
text-align: center; |
||||
|
font-weight: bold; |
||||
|
} |
||||
|
.table th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
text-align: center; |
||||
|
} |
||||
|
.table td { |
||||
|
text-align: center; |
||||
|
} |
||||
|
.clickable-cell { |
||||
|
color: blue; |
||||
|
text-decoration: underline; |
||||
|
cursor: pointer; |
||||
|
} |
||||
|
.modal-header { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<h4>Compound wall for playfield</h4> |
||||
|
<div class="table-responsive"> |
||||
|
<table id="compoundWallTable" class="table table-bordered"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>Zone No.</th> |
||||
|
<th>No. of playfields</th> |
||||
|
<th>No. of playfields with damaged or repaired compound wall</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody></tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Modal for breakdown --> |
||||
|
<div class="modal fade" id="compoundWallModal" tabindex="-1" aria-labelledby="compoundWallModalLabel" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-lg modal-dialog-scrollable"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="compoundWallModalLabel">List of playfields with compound wall issues</h5> |
||||
|
<button type="button" class="btn-close bg-light" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
<table class="table table-bordered"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>S.No.</th> |
||||
|
<th>Playfield Name</th> |
||||
|
<th>Division</th> |
||||
|
<th>Maintained By</th> |
||||
|
<th>Condition</th> |
||||
|
<th>Compound Wall</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="compoundWallDetails"> |
||||
|
<tr><td colspan="6">No data loaded</td></tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
<script> |
||||
|
fetch('/commissionerreview/api/compoundwall/getCompoundWall') |
||||
|
.then(res => res.json()) |
||||
|
.then(data => { |
||||
|
const tbody = document.querySelector('#compoundWallTable tbody'); |
||||
|
tbody.innerHTML = ''; |
||||
|
|
||||
|
data.forEach(row => { |
||||
|
const zone = row.zone; |
||||
|
const total = row.total_playfields || 0; |
||||
|
const issues = row.with_issue || 0; |
||||
|
|
||||
|
const issueCell = issues > 0 |
||||
|
? `<span class="clickable-cell" data-bs-toggle="modal" data-bs-target="#compoundWallModal" onclick="loadCompoundWallDetails(${zone})">${issues}</span>` |
||||
|
: '0'; |
||||
|
|
||||
|
tbody.innerHTML += ` |
||||
|
<tr> |
||||
|
<td>${zone}</td> |
||||
|
<td>${total}</td> |
||||
|
<td>${issueCell}</td> |
||||
|
</tr>`; |
||||
|
}); |
||||
|
}); |
||||
|
|
||||
|
function loadCompoundWallDetails(zone) { |
||||
|
const tbody = document.getElementById('compoundWallDetails'); |
||||
|
tbody.innerHTML = `<tr><td colspan="6">Loading...</td></tr>`; |
||||
|
|
||||
|
fetch('/commissionerreview/api/compoundwall/issues/' + zone) |
||||
|
.then(res => res.json()) |
||||
|
.then(data => { |
||||
|
if (!data || data.length === 0) { |
||||
|
tbody.innerHTML = `<tr><td colspan="6">No playfields found for zone ${zone}</td></tr>`; |
||||
|
return; |
||||
|
} |
||||
|
|
||||
|
tbody.innerHTML = ''; |
||||
|
data.forEach((field, index) => { |
||||
|
tbody.innerHTML += ` |
||||
|
<tr> |
||||
|
<td>${index + 1}</td> |
||||
|
<td>${field.playfield_name || 'N/A'}</td> |
||||
|
<td>${field.division || ''}</td> |
||||
|
<td>${field.maintained_by || ''}</td> |
||||
|
<td>${field.playfield_condition || ''}</td> |
||||
|
<td>${field.compound_wall || ''}</td> |
||||
|
</tr>`; |
||||
|
}); |
||||
|
}) |
||||
|
.catch(error => { |
||||
|
console.error('Error fetching data:', error); |
||||
|
tbody.innerHTML = `<tr><td colspan="6">Error loading data</td></tr>`; |
||||
|
}); |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,759 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Enforcement Zonwise Report Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap 5 CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
table.dataTable th, table.dataTable td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000; |
||||
|
} |
||||
|
|
||||
|
table.dataTable th{ |
||||
|
background-color: #003366 !important; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
.dataTables_filter { |
||||
|
margin-bottom: 25px; /* adjust as needed */ |
||||
|
} |
||||
|
|
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
#zoneDetailsTable_wrapper .dataTables_scrollBody { |
||||
|
border: none !important; |
||||
|
} |
||||
|
|
||||
|
#zoneDetailsTable td, #zoneDetailsTable th { |
||||
|
vertical-align: middle; |
||||
|
text-align: center; |
||||
|
white-space: nowrap; |
||||
|
} |
||||
|
|
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="page-header-title"> |
||||
|
<h4>Enforcement - Zonewise Report</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div id="opSummaryTable" style="display: block;" class="container"> |
||||
|
<table id="ZoneOpDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th rowspan="2" class="text-center">ZONE</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 1</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 2</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 3</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 4</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 5</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 6</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 7</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
<div class="modal fade" id="zoneDetailsModal" tabindex="-1" aria-labelledby="zoneDetailsLabel" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-xl"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="zoneModalTitle">Zone Details</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
|
||||
|
<table id="WardDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th rowspan="2" class="text-center">WARD</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 1</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 2</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 3</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 4</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 5</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 6</th> |
||||
|
<th colspan="3" class="text-center">NOTICE 7</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
<th class="text-center">Received </th> |
||||
|
<th class="text-center">Inprogess</th> |
||||
|
<th class="text-center">Completed </th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<div class="modal fade" id="DetailsModal" tabindex="-1" aria-labelledby="DetailsLabel" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-xl"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="DeatilsModalTitle">Details</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
|
||||
|
<table id="DetailsDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th class="text-center">ZONE</th> |
||||
|
<th class="text-center">WARD</th> |
||||
|
<th class="text-center">APPLICANT NAME</th> |
||||
|
<th class="text-center">AREA</th> |
||||
|
<th class="text-center">ADDRESS</th> |
||||
|
<th class="text-center">PINCODE</th> |
||||
|
|
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<div class="modal fade" id="ApplicantDetailsModal" tabindex="-1" aria-labelledby="ApplicantDetailsLabel" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-xl"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title">Enforcement Details</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
|
||||
|
<table id="FormDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th class="text-center">ENCLOSEMENT NAME</th> |
||||
|
<th class="text-center">DATE</th> |
||||
|
<th class="text-center">FILE URL</th> |
||||
|
|
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<div id="pageLoader" style="display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(255, 255, 255, 0.8); z-index: 9999; text-align: center;"> |
||||
|
<div style="position: relative; top: 50%; transform: translateY(-50%);"> |
||||
|
<div class="spinner-border text-primary" role="status" style="width: 3rem; height: 3rem;"> |
||||
|
<span class="sr-only"></span> |
||||
|
</div> |
||||
|
<!-- Add the 'Please wait' text below the spinner --> |
||||
|
<p style="margin-top: 1rem; font-size: 1.2rem; color: #007bff;">Please wait...</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables JS --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
$('#pageLoader').show(); |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/enforcement/getZoneWiseDetails', |
||||
|
method: 'GET', |
||||
|
success: function(response) { |
||||
|
$('#pageLoader').hide(); |
||||
|
if (Array.isArray(response) && response.length > 0){ |
||||
|
console.log("Details Array:", response); |
||||
|
|
||||
|
|
||||
|
let table = $('#ZoneOpDatatable').DataTable({ |
||||
|
destroy: true, |
||||
|
autoWidth: true, |
||||
|
info: true, |
||||
|
data: response, // using response directly |
||||
|
columns: [ |
||||
|
{ |
||||
|
data: 'ZONE', |
||||
|
title: 'Zone', |
||||
|
render: function (data, type, row, meta) { |
||||
|
const serial = meta.row + 1; |
||||
|
return `<a href="#" onclick="openZoneModal('${data}')" style="text-decoration: underline;">${serial}</a>`; |
||||
|
} |
||||
|
}, |
||||
|
{ data: 'FORM1_RECIEVED' }, |
||||
|
{ data: 'FORM1_INPROGRESS' }, |
||||
|
{ data: 'FORM1_COMPLETED' }, |
||||
|
{ data: 'FORM2_RECIEVED' }, |
||||
|
{ data: 'FORM2_INPROGRESS' }, |
||||
|
{ data: 'FORM2_COMPLETED' }, |
||||
|
{ data: 'FORM3_RECIEVED' }, |
||||
|
{ data: 'FORM3_INPROGRESS' }, |
||||
|
{ data: 'FORM3_COMPLETED' }, |
||||
|
{ data: 'FORM4_RECIEVED' }, |
||||
|
{ data: 'FORM4_INPROGRESS' }, |
||||
|
{ data: 'FORM4_COMPLETED' }, |
||||
|
{ data: 'FORM5_RECIEVED' }, |
||||
|
{ data: 'FORM5_INPROGRESS' }, |
||||
|
{ data: 'FORM5_COMPLETED' }, |
||||
|
{ data: 'FORM6_RECIEVED' }, |
||||
|
{ data: 'FORM6_INPROGRESS' }, |
||||
|
{ data: 'FORM6_COMPLETED' }, |
||||
|
{ data: 'FORM7_RECIEVED' }, |
||||
|
{ data: 'FORM7_INPROGRESS' }, |
||||
|
{ data: 'FORM7_COMPLETED' } |
||||
|
], |
||||
|
dom: 'frtip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: '400px', |
||||
|
scrollX: true, |
||||
|
responsive: false, |
||||
|
searching: false, |
||||
|
ordering: false |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
else if (Array.isArray(response) && response.length === 0) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}, |
||||
|
error: function(xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
// alert("Request failed: " + error); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
$('#DetailsDatatable tbody').off('click').on('click', '.applicant-name', function () { |
||||
|
const formId = $(this).data('formid'); |
||||
|
|
||||
|
openApplicantModal(formId); |
||||
|
|
||||
|
|
||||
|
}); |
||||
|
|
||||
|
|
||||
|
}); |
||||
|
|
||||
|
function openZoneModal(zoneCode) { |
||||
|
console.log("Opening modal for zone:", zoneCode); |
||||
|
|
||||
|
$('#pageLoader').show(); |
||||
|
|
||||
|
// Set data in modal (example) |
||||
|
$('#zoneModalTitle').text('Zone ' + zoneCode.replace("N", "") + ' Enforcement Details'); |
||||
|
|
||||
|
|
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/enforcement/getWardWiseDetails', |
||||
|
method: 'GET', |
||||
|
data:{zone:zoneCode}, |
||||
|
success: function(response) { |
||||
|
$('#pageLoader').hide(); |
||||
|
if (Array.isArray(response) && response.length > 0){ |
||||
|
console.log("Details Array:", response); |
||||
|
|
||||
|
|
||||
|
let table = $('#WardDatatable').DataTable({ |
||||
|
destroy: true, |
||||
|
autoWidth: true, |
||||
|
info: true, |
||||
|
data: response, // using response directly |
||||
|
columns: [ |
||||
|
{ |
||||
|
data: 'WARD', |
||||
|
render: function (data, type, row) { |
||||
|
return data ? data.replace("N", "") : ''; |
||||
|
} |
||||
|
}, |
||||
|
...[ |
||||
|
'FORM1_RECIEVED', 'FORM1_INPROGRESS', 'FORM1_COMPLETED', |
||||
|
'FORM2_RECIEVED', 'FORM2_INPROGRESS', 'FORM2_COMPLETED', |
||||
|
'FORM3_RECIEVED', 'FORM3_INPROGRESS', 'FORM3_COMPLETED', |
||||
|
'FORM4_RECIEVED', 'FORM4_INPROGRESS', 'FORM4_COMPLETED', |
||||
|
'FORM5_RECIEVED', 'FORM5_INPROGRESS', 'FORM5_COMPLETED', |
||||
|
'FORM6_RECIEVED', 'FORM6_INPROGRESS', 'FORM6_COMPLETED', |
||||
|
'FORM7_RECIEVED', 'FORM7_INPROGRESS', 'FORM7_COMPLETED' |
||||
|
].map(field => ({ |
||||
|
data: field, |
||||
|
createdCell: function (td, cellData) { |
||||
|
if (parseInt(cellData) > 0) { |
||||
|
$(td).css({ |
||||
|
color: 'blue', |
||||
|
textDecoration: 'underline', |
||||
|
cursor: 'pointer' |
||||
|
}); |
||||
|
} |
||||
|
} |
||||
|
})) |
||||
|
], |
||||
|
dom: 'frtip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: '400px', |
||||
|
scrollX: true, |
||||
|
responsive: false, |
||||
|
searching: false, |
||||
|
ordering: false |
||||
|
}); |
||||
|
$('#zoneDetailsModal').modal('show'); |
||||
|
} |
||||
|
else if (Array.isArray(response) && response.length === 0) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}, |
||||
|
error: function(xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Request failed: " + error); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
const formTypeMap = { |
||||
|
1: "Form 1", 2: "Form 1", 3: "Form 1", |
||||
|
4: "Form 2", 5: "Form 2", 6: "Form 2", |
||||
|
7: "Form 3", 8: "Form 3", 9: "Form 3", |
||||
|
10: "Form 4",11: "Form 4",12: "Form 4", |
||||
|
13: "Form 5",14: "Form 5",15: "Form 5", |
||||
|
16: "Form 6",17: "Form 6",18: "Form 6", |
||||
|
19: "Form 7",20: "Form 7",21: "Form 7" |
||||
|
}; |
||||
|
|
||||
|
const statusMap = { |
||||
|
0: "Received", 1: "Inprogress", 2: "Completed" |
||||
|
}; |
||||
|
|
||||
|
// Add click listener on table body cells |
||||
|
$('#WardDatatable tbody').off('click').on('click', 'td', function () { |
||||
|
|
||||
|
$('#pageLoader').show(); |
||||
|
|
||||
|
const table = $('#WardDatatable').DataTable(); |
||||
|
const cellIndex = table.cell(this).index(); // { row: x, column: y } |
||||
|
const columnIndex = cellIndex.column; |
||||
|
|
||||
|
// Ignore clicks on the first column (WARD) |
||||
|
if (columnIndex === 0) return; |
||||
|
|
||||
|
const rowData = table.row(cellIndex.row).data(); |
||||
|
const ward = rowData['WARD']; |
||||
|
const zone = zoneCode; |
||||
|
|
||||
|
// Calculate form type and status |
||||
|
const formType = formTypeMap[columnIndex]; |
||||
|
const positionInSet = (columnIndex - 1) % 3; // 0,1,2 for each formtype |
||||
|
const status = statusMap[positionInSet]; |
||||
|
|
||||
|
console.log("Clicked on -> Ward:", ward, "| Zone:", zone, "| FormType:", formType, "| Status:", status); |
||||
|
|
||||
|
openWardDetails(ward,zone,formType,status); |
||||
|
|
||||
|
}); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
function openWardDetails(ward,zone,formType,status){ |
||||
|
// Optional: show in a modal or send AJAX |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/enforcement/getFormDetails', |
||||
|
method: 'GET', |
||||
|
data: { |
||||
|
ward: ward, |
||||
|
zone: zone, |
||||
|
formtype: formType, |
||||
|
status: status |
||||
|
}, |
||||
|
success: function (response) { |
||||
|
|
||||
|
$('#pageLoader').hide(); |
||||
|
console.log("Details:", response); |
||||
|
if (Array.isArray(response) && response.length > 0){ |
||||
|
|
||||
|
|
||||
|
let table = $('#DetailsDatatable').DataTable({ |
||||
|
destroy: true, |
||||
|
autoWidth: true, |
||||
|
info: true, |
||||
|
data: response, // using response directly |
||||
|
columns: [ |
||||
|
{ data: 'ZONE', |
||||
|
render: function (data, type, row) { |
||||
|
return data ? data.replace("N", "") : ''; |
||||
|
} |
||||
|
}, |
||||
|
{ data: 'WARD', |
||||
|
render: function (data, type, row) { |
||||
|
return data ? data.replace("N", "") : ''; |
||||
|
} |
||||
|
}, |
||||
|
{ |
||||
|
data: 'APPLICANT_NAME', |
||||
|
render: function (data, type, row) { |
||||
|
return `<span class="applicant-name" data-formid="${row.FORMID}" style="color: blue; text-decoration: underline; cursor: pointer;">${data}</span>`; |
||||
|
} |
||||
|
}, |
||||
|
{ data: 'AREA' }, |
||||
|
{ data: 'ADDRESS' }, |
||||
|
{ data: 'PINCODE' }, |
||||
|
|
||||
|
], |
||||
|
dom: 'frtip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: '400px', |
||||
|
scrollX: true, |
||||
|
responsive: true, |
||||
|
searching: false, |
||||
|
ordering: false |
||||
|
}); |
||||
|
|
||||
|
$('#DeatilsModalTitle').text('Enforcement '+status +' Details'); |
||||
|
$('#DetailsModal').modal('show'); |
||||
|
$('#DetailsModal').on('shown.bs.modal', function () { |
||||
|
$.fn.dataTable.tables({ visible: true, api: true }).columns.adjust(); |
||||
|
}); |
||||
|
} |
||||
|
else if (response.length === 0) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
}, |
||||
|
error: function (xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Request failed: " + error); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
function openApplicantModal(formId) { |
||||
|
console.log("Opening modal for FORMID:", formId); |
||||
|
|
||||
|
|
||||
|
$('#pageLoader').show(); |
||||
|
|
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/enforcement/getFormId', |
||||
|
method: 'GET', |
||||
|
data:{formid:formId}, |
||||
|
success: function(response) { |
||||
|
$('#pageLoader').hide(); |
||||
|
if (Array.isArray(response) && response.length > 0){ |
||||
|
console.log("Details Array:", response); |
||||
|
|
||||
|
|
||||
|
let table = $('#FormDatatable').DataTable({ |
||||
|
destroy: true, |
||||
|
autoWidth: true, |
||||
|
info: true, |
||||
|
data: response, // using response directly |
||||
|
columns: [ |
||||
|
{ data: 'ENCLOSEMENTNAME' }, |
||||
|
{ |
||||
|
data: 'CDATE', |
||||
|
render: function (data, type, row) { |
||||
|
if (!data) return ''; |
||||
|
let parts = data.split(' ')[0].split('/'); // ["2025", "05", "27"] |
||||
|
if (parts.length === 3) { |
||||
|
return `${parts[2]}/${parts[1]}/${parts[0]}`; // 27/05/2025 |
||||
|
} |
||||
|
return data; // fallback |
||||
|
} |
||||
|
}, |
||||
|
{ |
||||
|
data: 'FILEURL', |
||||
|
render: function (data, type, row) { |
||||
|
return `<button class="btn btn-primary btn-sm btn-view" data-url="${data}">View</button>`; |
||||
|
}, |
||||
|
className: 'text-center' |
||||
|
}, |
||||
|
], |
||||
|
dom: 'frtip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: '400px', |
||||
|
scrollX: true, |
||||
|
responsive: false, |
||||
|
searching: false, |
||||
|
ordering: false |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
$('#FormDatatable').off('click').on('click', '.btn-view', function () { |
||||
|
var fileUrl = $(this).data('url'); |
||||
|
if (fileUrl) { |
||||
|
window.open(fileUrl, '_blank'); // Open in new tab |
||||
|
} else { |
||||
|
Swal.fire({ |
||||
|
icon: 'warning', |
||||
|
title: 'Missing File URL', |
||||
|
text: 'No file URL provided.', |
||||
|
showConfirmButton: true |
||||
|
}); |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
$('#ApplicantDetailsModal').modal('show'); |
||||
|
$('#ApplicantDetailsModal').on('shown.bs.modal', function () { |
||||
|
$.fn.dataTable.tables({ visible: true, api: true }).columns.adjust(); |
||||
|
}); |
||||
|
} |
||||
|
else if (response.length === 0) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}, |
||||
|
error: function(xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Request failed: " + error); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,108 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Land Acquisition Progress</title> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<style> |
||||
|
body { |
||||
|
padding: 40px; |
||||
|
font-family: Arial, sans-serif; |
||||
|
} |
||||
|
|
||||
|
h1 { |
||||
|
margin-bottom: 20px; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
<h1>Land Acquisition Progress</h1> |
||||
|
<table border="1" class="dataframe table table-striped"> |
||||
|
<thead> |
||||
|
<tr style="text-align: center;"> |
||||
|
<th>Zone No.</th> |
||||
|
<th>Name of the Project</th> |
||||
|
<th>Extent of Private Land to be Acquired (sqm)</th> |
||||
|
<th>Status</th> |
||||
|
<th>Status of Acquisition</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr> |
||||
|
<td>1</td> |
||||
|
<td>ROB over the existing subway at Ganesapuram @ km 4/1-3 near Vyasarpadi Jeeva Railway Station</td> |
||||
|
<td>2437</td> |
||||
|
<td>Yet to be Acquired</td> |
||||
|
<td>11 (1) preliminary notification published by the Chennai Collectorate 29.12.2024. Gazette published in news |
||||
|
paper on 8.1.2025. 15(2) enquiry conducted on 10.03.2025. out of 37 land owners, 32 land owners given |
||||
|
consent for private negotiation, remaining one land owner given objection and 4 land owners dispute. Addl. |
||||
|
AS Proposal Sent to CLA on 24.04.2025. Rehabilitation and resettlement Nil report received from ICO file |
||||
|
under circulation. |
||||
|
</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>2</td> |
||||
|
<td>High level bridge across Coovum river at Chinna Nolambur connecting Poonamallee High Road and Union Road in |
||||
|
dn.143 & 144, Zone-11 |
||||
|
</td> |
||||
|
<td>4396</td> |
||||
|
<td>Yet to be Acquired</td> |
||||
|
<td>Land acquisition is being dealt by Highways Department. Land acquisition G.O obtained vide G.O. (Ms) No. 113 |
||||
|
dated 24.08.2023. Revised Land acquisition G.O obtained vide G.O. (Ms) No. 41 dated 28.02.2025. Maduravoyal |
||||
|
-II Final Award passed for extent of 491 sq.m and CCD completed. Maduravoyal -I : Draft Award for an extent |
||||
|
of 3905 sq.m under preparation. The compensation amount to be disbursed by the Highways Department. |
||||
|
</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>3</td> |
||||
|
<td>High Level bridge across Coovum River at Sannathi 1st Cross Street connecting Poonamallee High Road to Union |
||||
|
Road in dn.143 & 144, Zone-11 |
||||
|
</td> |
||||
|
<td>1532</td> |
||||
|
<td>Yet to be Acquired</td> |
||||
|
<td>About 1532 sq.m of land required for this project. Private land - 392 sq.m. ULC land -922 sq.m and |
||||
|
Government land -218 sq.m. G.O. has been obtained from the Government vide G.O.Ms.No.05 dated 09.09.2024. |
||||
|
Letter sent to the Government on 31.12.2024 for obtaining revised A.S due to revision in LA. Action to be |
||||
|
initiated by LAO/Spl.DRO(LA), Highways to publish 11(1) preliminary notification. |
||||
|
</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>4</td> |
||||
|
<td>Construction of Bridge across Puzhal Surplus Water canal at Vadaperumbakkam in Dn-17, Zone-II</td> |
||||
|
<td>1228</td> |
||||
|
<td>Yet to be Acquired</td> |
||||
|
<td>11 (1) notification published on 18.10.2024. Objections 15(2) have been enquired on 18.12.2024 by LAO. out |
||||
|
of 13 land owners, 8 land owners given consent for private negotiation, remaining 5 land owners yet to be |
||||
|
give. Rehabilitation and resettlement Nil report received from RDO(North) and sent to CLA for approval on |
||||
|
04.04.2025. approval awaited from CLA. |
||||
|
</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>5</td> |
||||
|
<td>Flyover at Valluvar Kottam junction in Dn 110 & 113, Zone-IX</td> |
||||
|
<td>10879</td> |
||||
|
<td>Yet to be Acquired</td> |
||||
|
<td>About 10879 sq.m of land required for this project. Private land - 2860 sq.m and Government land -8019 sq.m. |
||||
|
Public hearing on SIA report has been conducted on 26.2.2024 The objection raised in the public hearing and |
||||
|
the reply for the objections received from the requisition boy and sent to District Collector, vide this |
||||
|
office Lr No. 390/2023/A1, dated. 15.3.2024 Expert Committee Report received on 19.03.2025 & Report |
||||
|
published on 09.04.205. Expert Committee published report awaited from GCC, RDO's(Central & South), Spl. |
||||
|
DRO, (H) & Tahsildar of Egmore, Mylapore& Guindy Taluks Collector Proceedings for LAO has initiate |
||||
|
the land acquisition process is under Circulation. |
||||
|
</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,274 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Makkaludan Mudhalvar Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap 5 CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
table.dataTable th, table.dataTable td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000 !important; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
.clickable-number { |
||||
|
cursor: pointer; |
||||
|
color: blue; |
||||
|
text-decoration: underline; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="page-header-title"> |
||||
|
<h4>Makkaludan Mudhalvar Progress Summary</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div id="procresstable" class="container"> |
||||
|
<table id="ProgressDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th class="text-center">S.No</th> |
||||
|
<th class="text-center">Ticket Owner Name</th> |
||||
|
<th class="text-center">Accepted</th> |
||||
|
<th class="text-center">Accepted and Waitlisted</th> |
||||
|
<th class="text-center">Pending Action</th> |
||||
|
<th class="text-center">Received</th> |
||||
|
<th class="text-center">Rejected</th> |
||||
|
<th class="text-center">Grand Total</th> <!-- 8th column --> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<!-- Modal with DataTable --> |
||||
|
<div class="modal fade" id="detailModal" tabindex="-1" aria-labelledby="detailModalLabel" aria-hidden="true" |
||||
|
data-bs-backdrop="static" data-bs-keyboard="false"> |
||||
|
<div class="modal-dialog modal-xl modal-dialog-centered"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="detailModalLabel">Details View</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
<table id="modalDataTable" class="table table-bordered table-striped w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th class="text-center">Sl.No</th> |
||||
|
<th class="text-center">Petitioner</th> |
||||
|
<th class="text-center">Ticket Owner Name</th> |
||||
|
<th class="text-center">Status Display</th> |
||||
|
<th class="text-center">Grievance Subtype</th> |
||||
|
<th class="text-center">Petition Details</th> |
||||
|
<th class="text-center">Ticket Age</th> |
||||
|
<th class="text-center">Close Days</th> |
||||
|
<th class="text-center">Status</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="modalTableBody"> |
||||
|
<!-- JS will populate rows here --> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables JS --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
var table = $('#ProgressDatatable').DataTable({ |
||||
|
dom: 'lftip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', '500 rows', 'Show all'] |
||||
|
], |
||||
|
|
||||
|
fixedHeader: false, |
||||
|
autoWidth: false, |
||||
|
responsive: false, |
||||
|
searching: true, |
||||
|
paging: true, |
||||
|
info: true, |
||||
|
ordering: false |
||||
|
}); |
||||
|
|
||||
|
// Load Main Table |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/makkaludanMudalvar/api/progress-report', |
||||
|
method: 'GET', |
||||
|
success: function (data) { |
||||
|
let serial = 1; |
||||
|
data.forEach(function (row) { |
||||
|
const ticketOwnerName = row.ticket_owner_name; |
||||
|
|
||||
|
// Create clickable cells with data attributes |
||||
|
const xAxisCell = ` |
||||
|
<div style="text-align: left;"> |
||||
|
<a href="#" class="x-axis-click" data-ticket-owner="${ticketOwnerName}" style="color: black; text-decoration: none;"> |
||||
|
${ticketOwnerName} |
||||
|
</a> |
||||
|
</div>`; |
||||
|
|
||||
|
const yAxisCellAccepeted = `<a href="#" class="y-axis-click" data-status="Accepted" data-ticket-owner="${ticketOwnerName}">${row.Accepted}</a>`; |
||||
|
const yAxisCellAccepetedandWaitlist = `<a href="#" class="y-axis-click" data-status="Accepted and Waitlisted" data-ticket-owner="${ticketOwnerName}">${row.Accepted_Waitlisted}</a>`; |
||||
|
const yAxisCellPending = `<a href="#" class="y-axis-click" data-status="Pending Action" data-ticket-owner="${ticketOwnerName}">${row.Pending_Action}</a>`; |
||||
|
const yAxisCellReceived = `<a href="#" class="y-axis-click" data-status="Received" data-ticket-owner="${ticketOwnerName}">${row.Received}</a>`; |
||||
|
const yAxisCellRejected = `<a href="#" class="y-axis-click" data-status="Rejected" data-ticket-owner="${ticketOwnerName}">${row.Rejected}</a>`; |
||||
|
|
||||
|
table.row.add([ |
||||
|
serial++, |
||||
|
xAxisCell, |
||||
|
yAxisCellAccepeted, |
||||
|
yAxisCellAccepetedandWaitlist, |
||||
|
yAxisCellPending, |
||||
|
yAxisCellReceived, |
||||
|
yAxisCellRejected, |
||||
|
row.grand_total, |
||||
|
|
||||
|
]).draw(false); |
||||
|
}); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load zone-wise report data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
// Delegate click event for dynamic content |
||||
|
$('#ProgressDatatable tbody').on('click', '.x-axis-click, .y-axis-click', function (e) { |
||||
|
e.preventDefault(); |
||||
|
|
||||
|
const ticketOwner = $(this).data('ticket-owner'); |
||||
|
const status = $(this).data('status'); |
||||
|
|
||||
|
if (!ticketOwner || !status) { |
||||
|
return; |
||||
|
} |
||||
|
|
||||
|
// Call the detail API |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/makkaludanMudalvar/api/progress-report-list', |
||||
|
method: 'GET', |
||||
|
data: { |
||||
|
ticket_owner_name: ticketOwner, |
||||
|
status_display: status |
||||
|
}, |
||||
|
success: function (data) { |
||||
|
let modalBody = ''; |
||||
|
let count = 1; |
||||
|
data.forEach(function (item) { |
||||
|
modalBody += ` |
||||
|
<tr> |
||||
|
<td>${count++}</td> |
||||
|
<td>${item.petitioner}</td> |
||||
|
<td>${item.ticket_owner_name}</td> |
||||
|
<td>${item.status_display}</td> |
||||
|
<td>${item.grievance_subtype}</td> |
||||
|
<td>${item.petition_details}</td> |
||||
|
<td>${item.ticket_age}</td> |
||||
|
<td>${item.close_days}</td> |
||||
|
<td>${item.status_1}</td> |
||||
|
</tr> |
||||
|
`; |
||||
|
}); |
||||
|
$('#modalTableBody').html(modalBody); |
||||
|
$('#detailModal').modal('show'); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load detail data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
}); |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
/* |
||||
|
$(document).ready(function () { |
||||
|
var table = $('#ProgressDatatable').DataTable({ |
||||
|
dom: 'lftip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', '500 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: '50vh', |
||||
|
fixedHeader: false, |
||||
|
autoWidth: false, |
||||
|
responsive: false, |
||||
|
searching: true, |
||||
|
paging: true, |
||||
|
info: true, |
||||
|
ordering: false // you can change to true if you want sorting |
||||
|
}); |
||||
|
|
||||
|
$.ajax({ |
||||
|
url: '/makkaludanMudalvar/api/progress-report', |
||||
|
method: 'GET', |
||||
|
success: function (data) { |
||||
|
console.log(data); |
||||
|
let serial = 1; |
||||
|
data.forEach(function (row) { |
||||
|
table.row.add([ |
||||
|
serial++, // S.No |
||||
|
row.ticket_owner_name, |
||||
|
row.Accepted, |
||||
|
row.Accepted_Waitlisted, |
||||
|
row.Pending_Action, |
||||
|
row.Received, |
||||
|
row.Rejected, |
||||
|
row.grand_total |
||||
|
]).draw(false); |
||||
|
}); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load zone-wise report data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
}); */ |
||||
|
|
||||
|
|
||||
|
document.querySelector(".btn-close").addEventListener("click", function () { |
||||
|
window.location.href = window.location.href; |
||||
|
}); |
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,184 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>MCC Status Report</title> |
||||
|
<style> |
||||
|
body { |
||||
|
font-family: Arial, sans-serif; |
||||
|
padding: 20px; |
||||
|
font-size: 14px; |
||||
|
} |
||||
|
|
||||
|
table { |
||||
|
width: 100%; |
||||
|
border-collapse: collapse; |
||||
|
margin-top: 20px; |
||||
|
} |
||||
|
|
||||
|
th, td { |
||||
|
border: 1px solid #000; |
||||
|
padding: 6px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<h2>Micro Compost Centre</h2> |
||||
|
<h3>MCC Status (Before 07.01.2025 and Presently Working)</h3> |
||||
|
<table> |
||||
|
<tr> |
||||
|
<th rowspan="2">S.No</th> |
||||
|
<th rowspan="2">Zone</th> |
||||
|
<th colspan="2">MCC (Before 07.01.2025)</th> |
||||
|
<th colspan="2">Presently working MCCs</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>No of MCC</th> |
||||
|
<th>Design Capacity in MT</th> |
||||
|
<th>No of MCC</th> |
||||
|
<th>Design Capacity in MT</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>1</td> |
||||
|
<td>1</td> |
||||
|
<td>5</td> |
||||
|
<td>33.23</td> |
||||
|
<td>1</td> |
||||
|
<td>28.26</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>2</td> |
||||
|
<td>2</td> |
||||
|
<td>4</td> |
||||
|
<td>22.48</td> |
||||
|
<td>2</td> |
||||
|
<td>8.5</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>3</td> |
||||
|
<td>3</td> |
||||
|
<td>4</td> |
||||
|
<td>17.24</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>4</td> |
||||
|
<td>4</td> |
||||
|
<td>30</td> |
||||
|
<td>64.69</td> |
||||
|
<td>2</td> |
||||
|
<td>6.34</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>5</td> |
||||
|
<td>5</td> |
||||
|
<td>9</td> |
||||
|
<td>57.73</td> |
||||
|
<td>2</td> |
||||
|
<td>19.38</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>6</td> |
||||
|
<td>6</td> |
||||
|
<td>28</td> |
||||
|
<td>27.44</td> |
||||
|
<td>3</td> |
||||
|
<td>3.01</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>7</td> |
||||
|
<td>7</td> |
||||
|
<td>22</td> |
||||
|
<td>42.07</td> |
||||
|
<td>2</td> |
||||
|
<td>3.58</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>8</td> |
||||
|
<td>8</td> |
||||
|
<td>39</td> |
||||
|
<td>60.39</td> |
||||
|
<td>2</td> |
||||
|
<td>4.95</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>9</td> |
||||
|
<td>9</td> |
||||
|
<td>12</td> |
||||
|
<td>24.63</td> |
||||
|
<td>2</td> |
||||
|
<td>5.23</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>10</td> |
||||
|
<td>10</td> |
||||
|
<td>7</td> |
||||
|
<td>18.4</td> |
||||
|
<td>1</td> |
||||
|
<td>1.94</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>11</td> |
||||
|
<td>11</td> |
||||
|
<td>4</td> |
||||
|
<td>13.05</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>12</td> |
||||
|
<td>12</td> |
||||
|
<td>9</td> |
||||
|
<td>31.69</td> |
||||
|
<td>2</td> |
||||
|
<td>6.94</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>13</td> |
||||
|
<td>13</td> |
||||
|
<td>6</td> |
||||
|
<td>27.21</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>14</td> |
||||
|
<td>14</td> |
||||
|
<td>6</td> |
||||
|
<td>63.7</td> |
||||
|
<td>2</td> |
||||
|
<td>23.8</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>15</td> |
||||
|
<td>15</td> |
||||
|
<td>5</td> |
||||
|
<td>27.8</td> |
||||
|
<td>1</td> |
||||
|
<td>3.85</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>TOTAL</td> |
||||
|
<td></td> |
||||
|
<td>190</td> |
||||
|
<td>531.75</td> |
||||
|
<td>22</td> |
||||
|
<td>115.77</td> |
||||
|
</tr> |
||||
|
|
||||
|
</table> |
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,224 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Audit Report Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap 5 CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
table.dataTable th { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000 !important; |
||||
|
background-color: #003366; |
||||
|
} |
||||
|
|
||||
|
table.dataTable td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000 !important; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
.cursor-pointer { |
||||
|
cursor: pointer !important; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="page-header-title"> |
||||
|
<h4>Mobile Diagnostics Unit-Zone wise Report</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div id="campTable" style="display: block;" class="container"> |
||||
|
<table id="CampDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th rowspan="2" class="text-center">Zone</th> |
||||
|
<th colspan="3" class="text-center">Jan, 2025</th> |
||||
|
<th colspan="3" class="text-center">Feb, 2025</th> |
||||
|
<th colspan="3" class="text-center">Mar, 2025</th> |
||||
|
|
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>No. of Camps Conducted</th> |
||||
|
<th>Target Population</th> |
||||
|
<th>No. Screened</th> |
||||
|
<th>No. of Camps Conducted</th> |
||||
|
<th>Target Population</th> |
||||
|
<th>No. Screened</th> |
||||
|
<th>No. of Camps Conducted</th> |
||||
|
<th>Target Population</th> |
||||
|
<th>No. Screened</th> |
||||
|
|
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="campDataBody"> |
||||
|
<!-- JS will inject rows here --> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
<div class="modal fade" id="zoneDetailsModal" tabindex="-1" aria-labelledby="zoneDetailsLabel" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-xl"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="zoneDetailsLabel">Zone Details</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
<table class="table table-bordered table-striped w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>S. No</th> |
||||
|
<th>Zone</th> |
||||
|
<th>Camp Date</th> |
||||
|
<th>Target Population</th> |
||||
|
<th>No. Screened</th> |
||||
|
<th>Presumptive Identified</th> |
||||
|
<th>No. of X-rays Taken</th> |
||||
|
<th>Normal X-rays</th> |
||||
|
<th>Abnormal X-rays</th> |
||||
|
<th>Sputum Collected</th> |
||||
|
<th>Sputum Positive</th> |
||||
|
<th>MC TB</th> |
||||
|
<th>CD TB</th> |
||||
|
<th>Total Positive</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="zoneDetailsBody"> |
||||
|
<!-- Filled via JS --> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables JS --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
var table = $('#CampDatatable').DataTable({ |
||||
|
// Optional: your DataTable options here |
||||
|
responsive: true, |
||||
|
paging: true, |
||||
|
searching: true, |
||||
|
ordering: true, |
||||
|
pageLength: 50, |
||||
|
// Add more options if needed |
||||
|
}); |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/mobileDiagonostic/api/reports/getzonedata', |
||||
|
method: 'GET', |
||||
|
success: function (data) { |
||||
|
console.log(data); |
||||
|
data.forEach(function (row) { |
||||
|
table.row.add([ |
||||
|
"<span class='text-primary fw-bold cursor-pointer' onclick=\"loadZoneDetails('" + row.zone + "')\">" + row.zone + "</span>", // zone |
||||
|
row.jan_camps, // Jan - No. of Camps Conducted |
||||
|
row.jan_target, // Jan - Target Population |
||||
|
row.jan_screened, // Jan - No. Screened |
||||
|
row.feb_camps, // Feb - No. of Camps Conducted |
||||
|
row.feb_target, // Feb - Target Population |
||||
|
row.feb_screened, // Feb - No. Screened |
||||
|
row.mar_camps, // Mar - No. of Camps Conducted |
||||
|
row.mar_target, // Mar - Target Population |
||||
|
row.mar_screened, // Mar - No. Screened |
||||
|
row.apr_camps, // Apr - No. of Camps Conducted |
||||
|
row.apr_target, // Apr - Target Population |
||||
|
row.apr_screened // Apr - No. Screened |
||||
|
]).draw(false); |
||||
|
}); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load zone-wise report data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
}); |
||||
|
|
||||
|
function loadZoneDetails(zone) { |
||||
|
$('#zoneDetailsLabel').text(`Zone - ${zone}Details`); |
||||
|
// Show modal |
||||
|
var detailModal = new bootstrap.Modal(document.getElementById('zoneDetailsModal'), { |
||||
|
backdrop: 'static', |
||||
|
keyboard: false |
||||
|
}); |
||||
|
detailModal.show(); |
||||
|
|
||||
|
// Clear old data |
||||
|
$('#zoneDetailsBody').empty(); |
||||
|
|
||||
|
// Fetch zone details |
||||
|
$.ajax({ |
||||
|
url: `/commissionerreview/mobileDiagonostic/api/reports/getZoneDetailData/${zone}`, |
||||
|
|
||||
|
method: 'GET', |
||||
|
success: function (rows) { |
||||
|
rows.forEach((row, i) => { |
||||
|
$('#zoneDetailsBody').append(` |
||||
|
<tr> |
||||
|
<td>${i + 1}</td> |
||||
|
<td>${row.zone}</td> |
||||
|
<td>${row.month}</td> |
||||
|
<td>${row.target_population}</td> |
||||
|
<td>${row.no_screened}</td> |
||||
|
<td>${row.presumptive_identified}</td> |
||||
|
<td>${row.x_rays_taken}</td> |
||||
|
<td>${row.normal_x_rays}</td> |
||||
|
<td>${row.abnormal_x_rays}</td> |
||||
|
<td>${row.sputum_collected}</td> |
||||
|
<td>${row.sputum_positive}</td> |
||||
|
<td>${row.mc_tb}</td> |
||||
|
<td>${row.cd_tb}</td> |
||||
|
<td>${row.total_positive}</td> |
||||
|
</tr> |
||||
|
`); |
||||
|
}); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load zone detail data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,228 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Mudhalvarin Mugavari Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap 5 CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
table.dataTable th { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000 !important; |
||||
|
background-color: #003366; |
||||
|
} |
||||
|
|
||||
|
table.dataTable td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000 !important; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
.clickable-number { |
||||
|
cursor: pointer; |
||||
|
color: blue; |
||||
|
text-decoration: underline; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="page-header-title"> |
||||
|
<h4>Mudhalvarin Mugavari Pendency Summary</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div id="pendencytable" class="container"> |
||||
|
<table id="PendencyDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th class="text-center">S.No</th> |
||||
|
<th class="text-center">Ticket Owner Name</th> |
||||
|
<th class="text-center">In Process</th> |
||||
|
<th class="text-center">Pending Action</th> |
||||
|
<th class="text-center">Received</th> |
||||
|
<th class="text-center">Grand Total</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<!-- Modal with DataTable --> |
||||
|
<div class="modal fade" id="detailModal" tabindex="-1" aria-labelledby="detailModalLabel" aria-hidden="true" |
||||
|
data-bs-backdrop="static" data-bs-keyboard="false"> |
||||
|
<div class="modal-dialog modal-xl modal-dialog-centered"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="detailModalLabel">Details View</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
<table id="modalDataTable" class="table table-bordered table-striped w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th class="text-center">Sl.No</th> |
||||
|
<th class="text-center">Petitioner</th> |
||||
|
<th class="text-center">Ticket Owner Name</th> |
||||
|
<th class="text-center">Status</th> |
||||
|
<th class="text-center">Grievance Subtype</th> |
||||
|
<th class="text-center">Ticket Age</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="modalTableBody"> |
||||
|
<!-- JS will populate rows here --> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables JS --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
|
||||
|
|
||||
|
$(document).ready(function () { |
||||
|
var table = $('#PendencyDatatable').DataTable({ |
||||
|
dom: 'lftip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', '500 rows', 'Show all'] |
||||
|
], |
||||
|
|
||||
|
fixedHeader: false, |
||||
|
autoWidth: false, |
||||
|
responsive: false, |
||||
|
searching: true, |
||||
|
paging: true, |
||||
|
info: true, |
||||
|
ordering: false |
||||
|
}); |
||||
|
|
||||
|
// Load Main Table |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/mudhalvarinMugavari/api/pendency-report', |
||||
|
method: 'GET', |
||||
|
success: function (data) { |
||||
|
let serial = 1; |
||||
|
data.forEach(function (row) { |
||||
|
const ticketOwnerName = row.ticket_owner_name; |
||||
|
|
||||
|
// Create clickable cells with data attributes |
||||
|
const xAxisCell = ` |
||||
|
<div style="text-align: left;"> |
||||
|
<a href="#" class="x-axis-click" data-ticket-owner="${ticketOwnerName}" style="color: black; text-decoration: none;"> |
||||
|
${ticketOwnerName} |
||||
|
</a> |
||||
|
</div>`; |
||||
|
|
||||
|
const yAxisCellInProcess = `<a href="#" class="y-axis-click" data-status="In Process" data-ticket-owner="${ticketOwnerName}">${row.In_Process}</a>`; |
||||
|
const yAxisCellPending = `<a href="#" class="y-axis-click" data-status="Pending Action" data-ticket-owner="${ticketOwnerName}">${row.Pending_Action}</a>`; |
||||
|
const yAxisCellReceived = `<a href="#" class="y-axis-click" data-status="Received" data-ticket-owner="${ticketOwnerName}">${row.Received}</a>`; |
||||
|
|
||||
|
table.row.add([ |
||||
|
serial++, |
||||
|
xAxisCell, |
||||
|
yAxisCellInProcess, |
||||
|
yAxisCellPending, |
||||
|
yAxisCellReceived, |
||||
|
row.grand_total |
||||
|
]).draw(false); |
||||
|
}); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load zone-wise report data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
// Delegate click event for dynamic content |
||||
|
$('#PendencyDatatable tbody').on('click', '.x-axis-click, .y-axis-click', function (e) { |
||||
|
e.preventDefault(); |
||||
|
|
||||
|
const ticketOwner = $(this).data('ticket-owner'); |
||||
|
const status = $(this).data('status'); |
||||
|
|
||||
|
if (!ticketOwner || !status) { |
||||
|
return; |
||||
|
} |
||||
|
|
||||
|
// Call the detail API |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/mudhalvarinMugavari/api/pendency-report-list', |
||||
|
method: 'GET', |
||||
|
data: { |
||||
|
ticket_owner_name: ticketOwner, |
||||
|
status_display: status |
||||
|
}, |
||||
|
success: function (data) { |
||||
|
let modalBody = ''; |
||||
|
let count = 1; |
||||
|
data.forEach(function (item) { |
||||
|
modalBody += ` |
||||
|
<tr> |
||||
|
<td>${count++}</td> |
||||
|
<td>${item.petitioner}</td> |
||||
|
<td>${item.ticket_owner_name}</td> |
||||
|
<td>${item.status_display}</td> |
||||
|
<td>${item.grievance_subtype}</td> |
||||
|
<td>${item.ticket_age}</td> |
||||
|
</tr> |
||||
|
`; |
||||
|
}); |
||||
|
$('#modalTableBody').html(modalBody); |
||||
|
$('#detailModal').modal('show'); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load detail data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
}); |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
document.querySelector(".btn-close").addEventListener("click", function () { |
||||
|
window.location.href = window.location.href; |
||||
|
}); |
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,215 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Parks Report</title> |
||||
|
|
||||
|
<!-- Bootstrap & DataTables --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
.table thead th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
text-align: center !important; |
||||
|
white-space: normal; |
||||
|
font-size: 16px; |
||||
|
} |
||||
|
.table th, .table td { |
||||
|
white-space: normal; |
||||
|
|
||||
|
padding: 6px 8px; |
||||
|
font-size: 16px; |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
} |
||||
|
.link{ |
||||
|
cursor: pointer; |
||||
|
text-decoration: underline; |
||||
|
color: blue !important; |
||||
|
|
||||
|
} |
||||
|
.modal-header { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
.clickable-cell { |
||||
|
cursor: pointer; |
||||
|
color: #0d6efd; |
||||
|
text-decoration: underline; |
||||
|
} |
||||
|
.clickable-cell:hover { |
||||
|
opacity: 0.8; |
||||
|
} |
||||
|
#dbfotTable, #dbfotTable th, #dbfotTable td { |
||||
|
border: 1px solid #000 !important; |
||||
|
} |
||||
|
.modal-body table, .modal-body th, .modal-body td { |
||||
|
border: 1px solid #000 !important; |
||||
|
} |
||||
|
|
||||
|
</style> |
||||
|
</head> |
||||
|
<body class="p-4"> |
||||
|
|
||||
|
<div class="page-header-title text-center mb-4"> |
||||
|
<h4>Cleaning of Parks & Playfields - Parks</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div class="table-responsive"> |
||||
|
<table id="dbfotTable" class="table table-bordered w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>Zone</th> |
||||
|
<th>No. of Parks</th> |
||||
|
<th>No. of Parks maintained by GCC</th> |
||||
|
<th>No. of Parks outsourced for maintenance</th> |
||||
|
<th>No. of Parks maintained by adoption</th> |
||||
|
<th>No. of Parks maintained by SHGs</th> |
||||
|
<th>No. of parks needing repair</th> |
||||
|
<th>No. of labourers appointed</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody></tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Modal --> |
||||
|
<div class="modal fade" id="packageModal" tabindex="-1" aria-labelledby="package1ModalLabel" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-xl modal-dialog-scrollable"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="packageModalLabel"></h5> |
||||
|
<button type="button" class="btn-close bg-light" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
<table class="table table-bordered"> |
||||
|
<thead style="background-color: #003366; color: white;"> |
||||
|
<tr> |
||||
|
<th>S.No</th> |
||||
|
<th>Location/ Park Name</th> |
||||
|
<th>Condition of park</th> |
||||
|
<th>No. of Labourers appointed</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody></tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://code.jquery.com/jquery-3.7.0.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
$('#dbfotTable').DataTable({ |
||||
|
paging: false, |
||||
|
searching: false, |
||||
|
ordering: false, |
||||
|
info: false |
||||
|
}); |
||||
|
|
||||
|
fetch('/commissionerreview/api/parks/getParkData') |
||||
|
.then(res => res.json()) |
||||
|
.then(result => { |
||||
|
const tbody = $('#dbfotTable tbody'); |
||||
|
tbody.empty(); |
||||
|
|
||||
|
|
||||
|
result.forEach(item => { |
||||
|
|
||||
|
const getLinkCell = (value, zone, label) => { |
||||
|
return value > 0 |
||||
|
? `<td class="link" data-zone="${zone}" data-type="${label}">${value}</td>` |
||||
|
: `<td>${value}</td>`; |
||||
|
}; |
||||
|
|
||||
|
|
||||
|
const rowHtml = ` |
||||
|
<tr> |
||||
|
<td>${item.zone}</td> |
||||
|
<td>${item.parks_count}</td> |
||||
|
${getLinkCell(item.parksby_gcc, item.zone, 'GCC')} |
||||
|
${getLinkCell(item.parksby_out, item.zone, 'Outsourced Parks')} |
||||
|
${getLinkCell(item.parksby_adoption, item.zone, 'Adoption')} |
||||
|
${getLinkCell(item.parksby_shg, item.zone, 'SHG')} |
||||
|
${getLinkCell(item.repair_needed, item.zone, 'Repair Needed')} |
||||
|
<td>${item.labours_appointed}</td> |
||||
|
</tr> |
||||
|
`; |
||||
|
tbody.append(rowHtml); |
||||
|
}); |
||||
|
|
||||
|
}) |
||||
|
.catch(error => { |
||||
|
console.error('Error loading data:', error); |
||||
|
}); |
||||
|
|
||||
|
$('#dbfotTable').on('click', '.link', function () { |
||||
|
const zone = $(this).data('zone'); |
||||
|
const type = $(this).data('type'); |
||||
|
|
||||
|
// Set modal title |
||||
|
$('#packageModalLabel').text(`Zone ${zone} - ${type}`); |
||||
|
|
||||
|
// Clear previous data |
||||
|
$('#packageModal tbody').empty(); |
||||
|
|
||||
|
// Show or hide specific headers based on type |
||||
|
if (type === 'Repair Needed') { |
||||
|
$('#packageModal thead th:nth-child(3), #packageModal thead th:nth-child(4)').hide(); |
||||
|
} else { |
||||
|
$('#packageModal thead th:nth-child(3), #packageModal thead th:nth-child(4)').show(); |
||||
|
} |
||||
|
|
||||
|
// Fetch data for modal |
||||
|
fetch(`/commissionerreview/api/parks/getParkDataByZone?zone=${zone}&type=${encodeURIComponent(type)}`) |
||||
|
.then(res => res.json()) |
||||
|
.then(data => { |
||||
|
if (data.length === 0) { |
||||
|
$('#packageModal tbody').append(`<tr><td colspan="4" class="text-center">No data available</td></tr>`); |
||||
|
} else { |
||||
|
data.forEach((item, index) => { |
||||
|
const condition = item.park_condition && item.park_condition.trim() !== '' ? item.park_condition : 'N/A'; |
||||
|
|
||||
|
let row = ` |
||||
|
<tr> |
||||
|
<td>${index + 1}</td> |
||||
|
<td style="text-align:left;">${item.park_name || ''}</td> |
||||
|
`; |
||||
|
|
||||
|
if (type !== 'Repair Needed') { |
||||
|
row += ` |
||||
|
<td>${condition}</td> |
||||
|
<td>${item.labours_allocated || 0}</td> |
||||
|
`; |
||||
|
} |
||||
|
|
||||
|
row += `</tr>`; |
||||
|
$('#packageModal tbody').append(row); |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
// Show the modal |
||||
|
$('#packageModal').modal('show'); |
||||
|
}) |
||||
|
.catch(err => { |
||||
|
console.error('Error fetching modal data:', err); |
||||
|
$('#packageModal tbody').append(`<tr><td colspan="4" class="text-center text-danger">Error loading data</td></tr>`); |
||||
|
$('#packageModal').modal('show'); |
||||
|
}); |
||||
|
}); |
||||
|
|
||||
|
}); |
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,229 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Perungudi Bio-mining Project</title> |
||||
|
<style> |
||||
|
body { |
||||
|
font-family: Arial, sans-serif; |
||||
|
padding: 20px; |
||||
|
} |
||||
|
|
||||
|
/*h1 { background-color: lightgreen; padding: 10px; font-size: 24px; }*/ |
||||
|
table { |
||||
|
width: 100%; |
||||
|
border-collapse: collapse; |
||||
|
margin-top: 20px; |
||||
|
} |
||||
|
|
||||
|
th, td { |
||||
|
border: 1px solid #000; |
||||
|
padding: 8px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
/*tr:nth-child(even) { background-color: #f5f5f6; }*/ |
||||
|
/*tr:nth-child(odd) { background-color: #f1f9c4; }*/ |
||||
|
|
||||
|
body { |
||||
|
font-family: Arial, sans-serif; |
||||
|
padding: 20px; |
||||
|
} |
||||
|
|
||||
|
/*h1 { background-color: lightgreen; padding: 10px; font-size: 24px; }*/ |
||||
|
table { |
||||
|
width: 100%; |
||||
|
border-collapse: collapse; |
||||
|
margin-top: 20px; |
||||
|
} |
||||
|
|
||||
|
th, td { |
||||
|
border: 1px solid #000; |
||||
|
padding: 8px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
|
||||
|
/*th { background-color: #003366; color: white; }*/ |
||||
|
/*tr:nth-child(even) { background-color: #d3f4ff; }*/ |
||||
|
/*tr:nth-child(odd) { background-color: #f1f9c4; }*/ |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
<h1>Perungudi Bio-mining Project (Ongoing) under SBM 1.0 – Rs.350 crores – as on 12.05.2025</h1> |
||||
|
<table> |
||||
|
<tr> |
||||
|
<th>Package</th> |
||||
|
<th>Name of the Contractor</th> |
||||
|
<th>Volume of Legacy waste to be processed in Cu.m</th> |
||||
|
<th>Volume of Legacy waste processed in Cu.m</th> |
||||
|
<th>% of completion</th> |
||||
|
<th>Total volume disposed till 12-05-2025 (m3)</th> |
||||
|
<th>% of volume Disposed in the revised volume</th> |
||||
|
<th>Remarks</th> |
||||
|
<th>Payment Released as on date in Crores</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package I</td> |
||||
|
<td>Westart</td> |
||||
|
<td>3,74,236</td> |
||||
|
<td>2,78,643</td> |
||||
|
<td>74%</td> |
||||
|
<td>157618</td> |
||||
|
<td>43%</td> |
||||
|
<td>Pre termination Notice issued. Under Arbitration</td> |
||||
|
<td>21.80 (54.23%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package II</td> |
||||
|
<td>Westart</td> |
||||
|
<td>4,24,015</td> |
||||
|
<td>3,07,562</td> |
||||
|
<td>73%</td> |
||||
|
<td>205930</td> |
||||
|
<td>50%</td> |
||||
|
<td>Pre termination Notice issued. Under Arbitration</td> |
||||
|
<td>24.20 (53.04%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package III</td> |
||||
|
<td>Zigma</td> |
||||
|
<td>5,91,133</td> |
||||
|
<td>5,91,133</td> |
||||
|
<td>100%</td> |
||||
|
<td>591133</td> |
||||
|
<td>100%</td> |
||||
|
<td>completed</td> |
||||
|
<td>62.88 (100%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package IV</td> |
||||
|
<td>Zigma</td> |
||||
|
<td>5,52,321</td> |
||||
|
<td>5,52,321</td> |
||||
|
<td>100%</td> |
||||
|
<td>672873</td> |
||||
|
<td>100%</td> |
||||
|
<td>completed</td> |
||||
|
<td>58.80 (100%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package V</td> |
||||
|
<td>Zigma</td> |
||||
|
<td>5,87,130</td> |
||||
|
<td>5,87,130</td> |
||||
|
<td>100%</td> |
||||
|
<td>627332</td> |
||||
|
<td>100%</td> |
||||
|
<td>completed</td> |
||||
|
<td>62.49 (100%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package VI</td> |
||||
|
<td>Westart</td> |
||||
|
<td>5,32,750</td> |
||||
|
<td>1,88,938</td> |
||||
|
<td>35%</td> |
||||
|
<td>89953</td> |
||||
|
<td>17%</td> |
||||
|
<td>Termination notice issued Under Arbitration</td> |
||||
|
<td>14.22 (33%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th colspan="2">TOTAL</th> |
||||
|
<th>30,61,585</th> |
||||
|
<th>25,05,727</th> |
||||
|
<th>82%</th> |
||||
|
<th>23,55,104</th> |
||||
|
<th>77%</th> |
||||
|
<th></th> |
||||
|
<th>244.39 (74%)</th> |
||||
|
</tr> |
||||
|
|
||||
|
|
||||
|
</table> |
||||
|
<h1>Kodungaiyur Bio-Mining Project under SBM (U) 2.0 Rs.640.83 Crores</h1> |
||||
|
<table> |
||||
|
<tr> |
||||
|
<th>Package</th> |
||||
|
<th>Name of the Contractor</th> |
||||
|
<th>Volume of Legacy waste to be processed in MT</th> |
||||
|
<th>Volume of Legacy waste processed in MT as on 16.05.2025</th> |
||||
|
<th>% of completion</th> |
||||
|
<th>Disposal in MT as on 16.05.2025</th> |
||||
|
<th>Payment Released as on date in Crores</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package I</td> |
||||
|
<td>Zigma Global Environ Solutions</td> |
||||
|
<td>21,20,090.76</td> |
||||
|
<td>4,90,747.28</td> |
||||
|
<td>23.14%</td> |
||||
|
<td>2,77,802.33 (13.10%)</td> |
||||
|
<td>18.61 (9.11%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package II</td> |
||||
|
<td>Ramky Infrastructure Limited</td> |
||||
|
<td>4,14,213.08</td> |
||||
|
<td>42,592.91</td> |
||||
|
<td>10.28%</td> |
||||
|
<td>15,950.17 (3.85%)</td> |
||||
|
<td>-</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package III</td> |
||||
|
<td>Ascent E digit Solution Pvt. Ltd</td> |
||||
|
<td>11,35,376.55</td> |
||||
|
<td>2,51,103.02</td> |
||||
|
<td>22.11%</td> |
||||
|
<td>98,945.65 (8.71%)</td> |
||||
|
<td>8.02 (7.33%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package IV</td> |
||||
|
<td>Zigma Global Environ Solutions</td> |
||||
|
<td>4,41,202.95</td> |
||||
|
<td>1,27,342.19</td> |
||||
|
<td>28.88%</td> |
||||
|
<td>65,661.94 (14.88%)</td> |
||||
|
<td>2.94 (6.97%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package V</td> |
||||
|
<td>Ramky Infrastructure Limited</td> |
||||
|
<td>18,35,204.18</td> |
||||
|
<td>12,295.11</td> |
||||
|
<td>0.66%</td> |
||||
|
<td>1,855.29 (0.10%)</td> |
||||
|
<td>-</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Package VI</td> |
||||
|
<td>Zigma Global Environ Solutions</td> |
||||
|
<td>7,06,418.15</td> |
||||
|
<td>2,19,070.44</td> |
||||
|
<td>31.01%</td> |
||||
|
<td>94,891.36 (13.43%)</td> |
||||
|
<td>6.08 (8.93%)</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th colspan="2">TOTAL</th> |
||||
|
<th>66,52,505</th> |
||||
|
<th>11,43,150.95</th> |
||||
|
<th>19.34%</th> |
||||
|
<th>5,55,106.74 (9.01%)</th> |
||||
|
<th>25.65 (5.39%)</th> |
||||
|
</tr> |
||||
|
</table> |
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,154 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Security Guards for Playgrounds</title> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<style> |
||||
|
body { |
||||
|
font-family: Arial, sans-serif; |
||||
|
padding: 30px; |
||||
|
background-color: #f8f9fa; |
||||
|
} |
||||
|
h4 { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
padding: 10px; |
||||
|
text-align: center; |
||||
|
font-weight: bold; |
||||
|
} |
||||
|
.table th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
text-align: center; |
||||
|
} |
||||
|
.table td { |
||||
|
text-align: center; |
||||
|
} |
||||
|
.clickable-cell { |
||||
|
color: blue; |
||||
|
text-decoration: underline; |
||||
|
cursor: pointer; |
||||
|
} |
||||
|
.modal-header { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<!-- Main Summary --> |
||||
|
<h4>Security Guards to be appointed for Playgrounds</h4> |
||||
|
<div class="table-responsive"> |
||||
|
<table id="summaryTable" class="table table-bordered"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>Zone No.</th> |
||||
|
<th>No. of playfields</th> |
||||
|
<th>No. of playfields without security guards</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody></tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Detail Modal --> |
||||
|
<div class="modal fade" id="playfieldModal" tabindex="-1" aria-labelledby="playfieldModalLabel" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-xl modal-dialog-scrollable"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="playfieldModalLabel">Playfields without security guards</h5> |
||||
|
<button type="button" class="btn-close bg-light" data-bs-dismiss="modal"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
<table class="table table-bordered"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th style="width: 60px;">S.No.</th> |
||||
|
<th>Division</th> |
||||
|
<th>Playfield Name</th> |
||||
|
<th>Maintained By</th> |
||||
|
<th>Condition</th> |
||||
|
<th>Compound Wall</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="playfieldDetails"> |
||||
|
<tr><td colspan="6">No data loaded</td></tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Bootstrap JS + our script --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
<script> |
||||
|
// 1) Load the summary on page load |
||||
|
fetch('/commissionerreview/api/playfield/count-by-zone') |
||||
|
.then(r => r.json()) |
||||
|
.then(data => { |
||||
|
const tbody = document.querySelector('#summaryTable tbody'); |
||||
|
tbody.innerHTML = ''; |
||||
|
data.forEach(row => { |
||||
|
const zone = row.zone; |
||||
|
const total = row.total_playfields || 0; |
||||
|
const without = row.without_security || 0; |
||||
|
// if `without` > 0 make it clickable, else just show 0 |
||||
|
const cell = without > 0 |
||||
|
? `<span class="clickable-cell" data-zone="${zone}" |
||||
|
data-bs-toggle="modal" |
||||
|
data-bs-target="#playfieldModal" |
||||
|
onclick="loadPlayfields(${zone})"> |
||||
|
${without} |
||||
|
</span>` |
||||
|
: '0'; |
||||
|
tbody.innerHTML += ` |
||||
|
<tr> |
||||
|
<td>${zone}</td> |
||||
|
<td>${total}</td> |
||||
|
<td>${cell}</td> |
||||
|
</tr>`; |
||||
|
}); |
||||
|
}) |
||||
|
.catch(err => console.error('Error loading summary:', err)); |
||||
|
|
||||
|
|
||||
|
// 2) When a zone count is clicked, fetch & render the detail list |
||||
|
function loadPlayfields(zone) { |
||||
|
// update modal title |
||||
|
document.getElementById('playfieldModalLabel').textContent = |
||||
|
`Playfields without security guards (Zone ${zone})`; |
||||
|
|
||||
|
const tbody = document.getElementById('playfieldDetails'); |
||||
|
tbody.innerHTML = `<tr><td colspan="6">Loading...</td></tr>`; |
||||
|
|
||||
|
fetch(`/commissionerreview/api/playfield/without-guards/${zone}`) |
||||
|
.then(r => r.json()) |
||||
|
.then(data => { |
||||
|
tbody.innerHTML = ''; |
||||
|
if (!Array.isArray(data) || data.length === 0) { |
||||
|
tbody.innerHTML = `<tr><td colspan="6">No playfields found for zone ${zone}</td></tr>`; |
||||
|
return; |
||||
|
} |
||||
|
data.forEach((pf, i) => { |
||||
|
tbody.innerHTML += ` |
||||
|
<tr> |
||||
|
<td>${i+1}</td> |
||||
|
<td>${pf.division || ''}</td> |
||||
|
<td>${pf.playfield_name || ''}</td> |
||||
|
<td>${pf.maintained_by || ''}</td> |
||||
|
<td>${pf.playfield_condition || ''}</td> |
||||
|
<td>${pf.compound_wall || ''}</td> |
||||
|
</tr>`; |
||||
|
}); |
||||
|
}) |
||||
|
.catch(err => { |
||||
|
console.error('Error loading details:', err); |
||||
|
tbody.innerHTML = `<tr><td colspan="6">Error loading data</td></tr>`; |
||||
|
}); |
||||
|
} |
||||
|
</script> |
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,119 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Audit Report Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap 5 CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
table.dataTable th { |
||||
|
background-color: #003366; |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000 !important; |
||||
|
|
||||
|
} |
||||
|
|
||||
|
table.dataTable td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000 !important; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="page-header-title"> |
||||
|
<h4>Slaughter House Summary</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div class="container"> |
||||
|
<table id="CattleDataTable" class="table table-striped table-bordered display nowrap w-100 text-center"> |
||||
|
<thead class="table-dark "> |
||||
|
|
||||
|
<tr> |
||||
|
<th>Month</th> |
||||
|
<th>perambur</th> |
||||
|
<th>Villivakkam</th> |
||||
|
<th>Kallikuppam</th> |
||||
|
<th>Saidapet</th> |
||||
|
|
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="cattleTableBody"> |
||||
|
<!-- Dynamic rows will be injected here --> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables JS --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/veterinarypetclinic/slaughterdata', // Your endpoint |
||||
|
method: 'GET', |
||||
|
success: function (data) { |
||||
|
const tbody = $('#cattleTableBody'); |
||||
|
tbody.empty(); |
||||
|
|
||||
|
data.forEach(row => { |
||||
|
const isTotal = row.month === "Total"; |
||||
|
|
||||
|
tbody.append(` |
||||
|
<tr ${isTotal ? 'style="font-weight:bold; background-color:#f0f0f0;"' : ''}> |
||||
|
<td>${row.month}</td> |
||||
|
<td>${row.perambur || ''}</td> |
||||
|
<td>${row.villivakkam || ''}</td> |
||||
|
<td>${row.kallikuppam || ''}</td> |
||||
|
<td>${row.saidapet || ''}</td> |
||||
|
</tr> |
||||
|
`); |
||||
|
}); |
||||
|
|
||||
|
}, |
||||
|
error: function (err) { |
||||
|
console.error("Error fetching data:", err); |
||||
|
} |
||||
|
}); |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,662 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Sofa Bed collection Zonewise Report Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap 5 CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
table.dataTable th, table.dataTable td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000; |
||||
|
} |
||||
|
|
||||
|
table.dataTable th{ |
||||
|
background-color: #003366 !important; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
.dataTables_filter { |
||||
|
margin-bottom: 25px; /* adjust as needed */ |
||||
|
} |
||||
|
|
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
#zoneDetailsTable_wrapper .dataTables_scrollBody { |
||||
|
border: none !important; |
||||
|
} |
||||
|
|
||||
|
#zoneDetailsTable td, #zoneDetailsTable th { |
||||
|
vertical-align: middle; |
||||
|
text-align: center; |
||||
|
white-space: nowrap; |
||||
|
} |
||||
|
#DetailsModal .modal-body{ |
||||
|
max-height: 70vh; |
||||
|
overflow-y: auto; |
||||
|
} |
||||
|
|
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="page-header-title"> |
||||
|
<h4>Sofa and Bed Collection - Zonewise Report</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div id="opSummaryTable" style="display: block;" class="container"> |
||||
|
<table id="ZoneOpDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th class="text-center">Zone</th> |
||||
|
<th class="text-center">Total Request</th> |
||||
|
<th class="text-center">This week</th> |
||||
|
|
||||
|
<th class="text-center">Completed</th> |
||||
|
<th class="text-center">User Cancelled </th> |
||||
|
<th class="text-center">Officer Cancelled</th> |
||||
|
<th class="text-center">Over The week</th> |
||||
|
|
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
<div class="modal fade" id="zoneDetailsModal" tabindex="-1" aria-labelledby="zoneDetailsLabel" aria-hidden="true" data-bs-keyboard="false" data-bs-backdrop="static"> |
||||
|
<div class="modal-dialog modal-xl"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="zoneModalTitle">Zone Details</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
|
||||
|
<table id="WardDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th class="text-center">Ward </th> |
||||
|
<th class="text-center">Total Request</th> |
||||
|
<th class="text-center">This week</th> |
||||
|
<th class="text-center">Completed</th> |
||||
|
<th class="text-center">User Cancelled </th> |
||||
|
<th class="text-center">Officer Cancelled</th> |
||||
|
<th class="text-center">Over The week</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<div class="modal fade" id="DetailsModal" tabindex="-1" aria-labelledby="DetailsLabel" aria-hidden="true" data-bs-keyboard="false" data-bs-backdrop="static"> |
||||
|
<div class="modal-dialog modal-xl"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="DeatilsModalTitle">Details</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body" id="detailscontent"> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
|
||||
|
<!-- Image Modal --> |
||||
|
<div class="modal fade" id="imageModal" tabindex="-1" role="dialog" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-dialog-centered modal-lg" role="document"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-body text-center p-0"> |
||||
|
<img id="modalImage" src="" class="img-fluid" alt="Preview" style="max-height: 80vh;"/> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<div id="pageLoader" style="display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(255, 255, 255, 0.8); z-index: 9999; text-align: center;"> |
||||
|
<div style="position: relative; top: 50%; transform: translateY(-50%);"> |
||||
|
<div class="spinner-border text-primary" role="status" style="width: 3rem; height: 3rem;"> |
||||
|
<span class="sr-only"></span> |
||||
|
</div> |
||||
|
<!-- Add the 'Please wait' text below the spinner --> |
||||
|
<p style="margin-top: 1rem; font-size: 1.2rem; color: #007bff;">Please wait...</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables JS --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
|
||||
|
$(document).on('click', '.preview-img', function() { |
||||
|
const src = $(this).attr('src'); |
||||
|
$('#modalImage').attr('src', src); |
||||
|
$('#imageModal').modal('show'); |
||||
|
}); |
||||
|
|
||||
|
$(document).ready(function () { |
||||
|
$('#pageLoader').show(); |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/sofabedcollection/getZoneWiseDetails', |
||||
|
method: 'GET', |
||||
|
success: function(response) { |
||||
|
$('#pageLoader').hide(); |
||||
|
|
||||
|
if (response.status === "success") { |
||||
|
|
||||
|
if (Array.isArray(response.data) && response.data.length > 0) { |
||||
|
console.log("Details Array:", response); |
||||
|
|
||||
|
let table = $('#ZoneOpDatatable').DataTable({ |
||||
|
destroy: true, |
||||
|
autoWidth: true, |
||||
|
info: true, |
||||
|
data: response.data, // using response directly |
||||
|
columns: [ |
||||
|
{ |
||||
|
data: 'zone', |
||||
|
render: function (data, type, row) { |
||||
|
// Skip last row |
||||
|
if (row === response.data[response.data.length - 1]) { |
||||
|
return data; // just plain text |
||||
|
} else { |
||||
|
return `<a href="#" onclick="openZoneModal('${data}')" style="text-decoration: underline;">${data}</a>`; |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
{ data: 'total_request', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'open', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'completed', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'user_cancel', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'officer_cancel', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'pending', defaultContent: '-', className: 'text-center' } |
||||
|
], |
||||
|
dom: 'frtip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: 'auto', |
||||
|
scrollX: true, |
||||
|
responsive: false, |
||||
|
searching: false, |
||||
|
ordering: false |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
else if(Array.isArray(response.data) && response.data.length === 0) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: 'Error', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
} |
||||
|
|
||||
|
else if(response.status === "nodata") { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}, |
||||
|
error: function(xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
// alert("Request failed: " + error); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
$('#zoneDetailsModal').on('shown.bs.modal', function () { |
||||
|
if ($.fn.DataTable.isDataTable('#WardDatatable')) { |
||||
|
let questionDatatable = $('#WardDatatable').DataTable(); |
||||
|
questionDatatable.columns.adjust().draw(); |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
}); |
||||
|
|
||||
|
|
||||
|
function openZoneModal(zoneCode) { |
||||
|
console.log("Opening modal for zone:", zoneCode); |
||||
|
|
||||
|
$('#pageLoader').show(); |
||||
|
|
||||
|
// Set data in modal (example) |
||||
|
$('#zoneModalTitle').text('Zone ' + zoneCode + ' Details'); |
||||
|
|
||||
|
|
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/sofabedcollection/getWardDetails', |
||||
|
method: 'GET', |
||||
|
data:{zone:zoneCode}, |
||||
|
success: function(response) { |
||||
|
$('#pageLoader').hide(); |
||||
|
|
||||
|
if (response.status === "success") { |
||||
|
|
||||
|
if (Array.isArray(response.data) && response.data.length > 0){ |
||||
|
console.log("Details Array:", response); |
||||
|
|
||||
|
|
||||
|
let table = $('#WardDatatable').DataTable({ |
||||
|
destroy: true, |
||||
|
autoWidth: true, |
||||
|
info: true, |
||||
|
data: response.data, // using response directly |
||||
|
columns: [ |
||||
|
{ data: 'division', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'total_request', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'open', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'completed', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'user_cancel', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'officer_cancel', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'pending', defaultContent: '-', className: 'text-center' } |
||||
|
], |
||||
|
dom: 'frtip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: '400px', |
||||
|
scrollX: true, |
||||
|
responsive: false, |
||||
|
searching: false, |
||||
|
ordering: false, |
||||
|
createdRow: function (row, data, dataIndex) { |
||||
|
// Skip last row |
||||
|
if (dataIndex === response.data.length - 1) { |
||||
|
return; |
||||
|
} |
||||
|
|
||||
|
const clickableCols = ['open', 'completed', 'user_cancel', 'officer_cancel', 'pending']; |
||||
|
|
||||
|
clickableCols.forEach((col, index) => { |
||||
|
const value = parseInt(data[col]); |
||||
|
if (!isNaN(value) && value > 0) { |
||||
|
$('td:eq(' + (index + 2) + ')', row).css({ |
||||
|
'color': '#007bff', |
||||
|
'text-decoration': 'underline', |
||||
|
'cursor': 'pointer' |
||||
|
}); |
||||
|
} |
||||
|
}); |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
$('#zoneDetailsModal').modal('show'); |
||||
|
} |
||||
|
else if (Array.isArray(response.data) && response.data.length === 0){ |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
else{ |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
} |
||||
|
else if (response.status === "nodata") { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
// Attach click handler after DataTable initialization |
||||
|
$('#WardDatatable tbody').off('click').on('click', 'td', function () { |
||||
|
let table = $('#WardDatatable').DataTable(); |
||||
|
let rowData = table.row($(this).closest('tr')).data(); |
||||
|
let columnIndex = table.cell(this).index().column; |
||||
|
|
||||
|
// Define column-to-status mapping (based on your requirement) |
||||
|
const columnMap = { |
||||
|
2: 1, // open |
||||
|
3: 2, // completed |
||||
|
6: 3, // pending |
||||
|
4: 4, // user_cancel |
||||
|
5: 5 // officer_cancel |
||||
|
}; |
||||
|
|
||||
|
// Get column name using column index |
||||
|
let columnName = table.column(columnIndex).dataSrc(); |
||||
|
|
||||
|
// If clicked column is one of the target columns |
||||
|
if (columnMap[columnIndex]) { |
||||
|
let status = columnMap[columnIndex]; |
||||
|
let value = rowData[columnName]; |
||||
|
let division = rowData['division']; |
||||
|
|
||||
|
// Proceed only if value > 0 |
||||
|
if (parseInt(value) > 0) { |
||||
|
openWardDetails(division, status); |
||||
|
} |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
}, |
||||
|
error: function(xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Request failed: " + error); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
function openWardDetails(division, status){ |
||||
|
console.log("division:",division," status:",status); |
||||
|
// Optional: show in a modal or send AJAX |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/sofabedcollection/getWardStatusDetails', |
||||
|
method: 'GET', |
||||
|
data: { |
||||
|
ward: division, |
||||
|
status: status |
||||
|
}, |
||||
|
success: function (response) { |
||||
|
|
||||
|
$('#pageLoader').hide(); |
||||
|
console.log("Details:", response); |
||||
|
if(response.status === "success"){ |
||||
|
|
||||
|
let modalBody = $("#detailscontent"); |
||||
|
modalBody.empty(); // Clear previous content |
||||
|
|
||||
|
if (Array.isArray(response.data) && response.data.length > 0){ |
||||
|
|
||||
|
response.data.forEach(item => { |
||||
|
// Create a container div for each record |
||||
|
let streetDiv = $('<div class="mb-4 p-3 border rounded shadow-sm bg-light"></div>'); |
||||
|
|
||||
|
// Info section (2 columns layout) |
||||
|
let infoHtml = ` |
||||
|
<div class="container-fluid"> |
||||
|
<div class="row mb-2"> |
||||
|
<div class="col-md-4"><strong>Zone:</strong> ${item.zone || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Ward:</strong> ${item.division || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Request ID:</strong> ${item.request_id || '-'}</div> |
||||
|
</div> |
||||
|
<div class="row mb-2"> |
||||
|
<div class="col-md-4"><strong>User Name:</strong> ${item.user_name || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Status:</strong> ${item.status || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Mobile Number:</strong> ${item.mobile || '-'}</div> |
||||
|
</div> |
||||
|
<div class="row mb-2"> |
||||
|
<div class="col-md-8"><strong>Address:</strong> ${item.address || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Created Date:</strong> ${item.cdate || '-'}</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
`; |
||||
|
streetDiv.append(infoHtml); |
||||
|
|
||||
|
|
||||
|
// 🧾 Items section (as divs) |
||||
|
let itemsHtml = ` |
||||
|
<div class="mt-3"> |
||||
|
<p><strong>Items:</strong></p> |
||||
|
${ |
||||
|
Array.isArray(item.items) && item.items.length > 0 |
||||
|
? item.items.map((it, idx) => ` |
||||
|
<div class="d-flex flex-wrap border rounded p-2 mb-2 "> |
||||
|
<div class="flex-fill"><strong>Item ${idx + 1}:</strong> ${it.item_name || '-'}</div> |
||||
|
<div class="flex-fill"><strong>Quantity:</strong> ${it.quantity ?? '-'}</div> |
||||
|
</div> |
||||
|
`).join("") |
||||
|
: `<p class="text-muted">No items available.</p>` |
||||
|
} |
||||
|
</div> |
||||
|
`; |
||||
|
streetDiv.append(itemsHtml); |
||||
|
|
||||
|
|
||||
|
// Image section |
||||
|
let imagesHtml = ` |
||||
|
<hr> |
||||
|
<div class="mt-2" style="text-align:center;"> |
||||
|
<p><strong>Image:</strong></p> |
||||
|
${ |
||||
|
item.image_url |
||||
|
? (() => { |
||||
|
// Handle multiple comma-separated images |
||||
|
return item.image_url.split(",").map(img => { |
||||
|
let trimmed = img.trim(); |
||||
|
return ` |
||||
|
<img src="${trimmed}" |
||||
|
alt="Image" |
||||
|
class="img-thumbnail me-2 mb-2 preview-img" |
||||
|
style="width: 250px; height: 200px; object-fit: contain; cursor: pointer;" |
||||
|
data-bs-toggle="modal" |
||||
|
data-bs-target="#imageModal" |
||||
|
/> |
||||
|
`; |
||||
|
}).join(""); |
||||
|
})() |
||||
|
: `<p class="text-muted">No images available.</p>` |
||||
|
} |
||||
|
</div> |
||||
|
`; |
||||
|
streetDiv.append(imagesHtml); |
||||
|
|
||||
|
modalBody.append(streetDiv); |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
$('#DeatilsModalTitle').text('Division '+division +' Details'); |
||||
|
$('#DetailsModal').modal('show'); |
||||
|
} |
||||
|
|
||||
|
else if (Array.isArray(response.data) && response.data.length === 0){ |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
else{ |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
else if (response.status === "nodata") { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
}, |
||||
|
error: function (xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Request failed: " + error); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,687 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Sofa Bed collection Zonewise Report Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap 5 CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
table.dataTable th, table.dataTable td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000; |
||||
|
} |
||||
|
|
||||
|
table.dataTable th{ |
||||
|
background-color: #003366 !important; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
.dataTables_filter { |
||||
|
margin-bottom: 25px; /* adjust as needed */ |
||||
|
} |
||||
|
|
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
#zoneDetailsTable_wrapper .dataTables_scrollBody { |
||||
|
border: none !important; |
||||
|
} |
||||
|
|
||||
|
#zoneDetailsTable td, #zoneDetailsTable th { |
||||
|
vertical-align: middle; |
||||
|
text-align: center; |
||||
|
white-space: nowrap; |
||||
|
} |
||||
|
#DetailsModal .modal-body{ |
||||
|
max-height: 70vh; |
||||
|
overflow-y: auto; |
||||
|
} |
||||
|
|
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="page-header-title"> |
||||
|
<h4>Sofa and Bed Collection - Zonewise Report</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div id="opSummaryTable" style="display: block;" class="container"> |
||||
|
<table id="ZoneOpDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th class="text-center">Zone</th> |
||||
|
<th class="text-center">Total Request</th> |
||||
|
<th class="text-center">This week Requests</th> |
||||
|
<th class="text-center">Older Requests</th> |
||||
|
<th class="text-center">Completed</th> |
||||
|
<th class="text-center">User Cancelled </th> |
||||
|
<th class="text-center">Officer Cancelled</th> |
||||
|
<th class="text-center">Pending</th> |
||||
|
|
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
<div class="modal fade" id="zoneDetailsModal" tabindex="-1" aria-labelledby="zoneDetailsLabel" aria-hidden="true" data-bs-keyboard="false" data-bs-backdrop="static"> |
||||
|
<div class="modal-dialog modal-xl"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="zoneModalTitle">Zone Details</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
|
||||
|
<table id="WardDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th class="text-center">Ward </th> |
||||
|
<th class="text-center">Total Request</th> |
||||
|
<th class="text-center">This Week Request</th> |
||||
|
<th class="text-center">Older Requests</th> |
||||
|
<th class="text-center">Completed</th> |
||||
|
<th class="text-center">User Cancelled </th> |
||||
|
<th class="text-center">Officer Cancelled</th> |
||||
|
<th class="text-center">Pending</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<div class="modal fade" id="DetailsModal" tabindex="-1" aria-labelledby="DetailsLabel" aria-hidden="true" data-bs-keyboard="false" data-bs-backdrop="static"> |
||||
|
<div class="modal-dialog modal-xl"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="DeatilsModalTitle">Details</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body" id="detailscontent"> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
|
||||
|
<!-- Image Modal --> |
||||
|
<div class="modal fade" id="imageModal" tabindex="-1" role="dialog" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-dialog-centered modal-lg" role="document"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-body text-center p-0"> |
||||
|
<img id="modalImage" src="" class="img-fluid" alt="Preview" style="max-height: 80vh;"/> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<div id="pageLoader" style="display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(255, 255, 255, 0.8); z-index: 9999; text-align: center;"> |
||||
|
<div style="position: relative; top: 50%; transform: translateY(-50%);"> |
||||
|
<div class="spinner-border text-primary" role="status" style="width: 3rem; height: 3rem;"> |
||||
|
<span class="sr-only"></span> |
||||
|
</div> |
||||
|
<!-- Add the 'Please wait' text below the spinner --> |
||||
|
<p style="margin-top: 1rem; font-size: 1.2rem; color: #007bff;">Please wait...</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables JS --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
|
||||
|
$(document).on('click', '.preview-img', function() { |
||||
|
const src = $(this).attr('src'); |
||||
|
$('#modalImage').attr('src', src); |
||||
|
$('#imageModal').modal('show'); |
||||
|
}); |
||||
|
|
||||
|
$(document).ready(function () { |
||||
|
|
||||
|
$('#pageLoader').show(); |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/sofabedcollection/getZoneReport', |
||||
|
method: 'GET', |
||||
|
success: function(response) { |
||||
|
|
||||
|
// Safely extract data whether it's an array or an object |
||||
|
var res = Array.isArray(response) ? response[0] : response; |
||||
|
console.log("Response:", res); |
||||
|
|
||||
|
$('#pageLoader').hide(); |
||||
|
|
||||
|
if (res.status === "Success") { |
||||
|
|
||||
|
if (Array.isArray(res.data) && res.data.length > 0) { |
||||
|
console.log("Details Array:", response); |
||||
|
|
||||
|
let table = $('#ZoneOpDatatable').DataTable({ |
||||
|
destroy: true, |
||||
|
autoWidth: true, |
||||
|
info: true, |
||||
|
data: res.data, // using response directly |
||||
|
columns: [ |
||||
|
{ |
||||
|
data: 'zone', |
||||
|
render: function (data, type, row) { |
||||
|
// Skip last row |
||||
|
if (row === res.data[res.data.length - 1]) { |
||||
|
return data; // just plain text |
||||
|
} else { |
||||
|
return `<a href="#" onclick="openZoneModal('${data}')" style="text-decoration: underline;">${data}</a>`; |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
{ data: 'total_request', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'this_week_requests', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'older_requests', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'completed', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'user_cancel', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'officer_cancel', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'pending', defaultContent: '-', className: 'text-center' } |
||||
|
], |
||||
|
dom: 'frtip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: 'auto', |
||||
|
scrollX: true, |
||||
|
responsive: false, |
||||
|
searching: false, |
||||
|
ordering: false |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
else if(Array.isArray(res.data) && res.data.length === 0) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: 'Error', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
} |
||||
|
|
||||
|
else if(res.status === "nodata") { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: res.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}, |
||||
|
error: function(xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
// alert("Request failed: " + error); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
$('#zoneDetailsModal').on('shown.bs.modal', function () { |
||||
|
if ($.fn.DataTable.isDataTable('#WardDatatable')) { |
||||
|
let questionDatatable = $('#WardDatatable').DataTable(); |
||||
|
questionDatatable.columns.adjust().draw(); |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
}); |
||||
|
|
||||
|
|
||||
|
function openZoneModal(zoneCode) { |
||||
|
console.log("Opening modal for zone:", zoneCode); |
||||
|
|
||||
|
$('#pageLoader').show(); |
||||
|
|
||||
|
// Set data in modal (example) |
||||
|
$('#zoneModalTitle').text('Zone ' + zoneCode + ' Details'); |
||||
|
|
||||
|
|
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/sofabedcollection/getWardReport', |
||||
|
method: 'GET', |
||||
|
data:{zone:zoneCode}, |
||||
|
success: function(response) { |
||||
|
|
||||
|
var res = Array.isArray(response) ? response[0] : response; |
||||
|
console.log("Response:", res); |
||||
|
|
||||
|
$('#pageLoader').hide(); |
||||
|
|
||||
|
if (res.status === "Success") { |
||||
|
|
||||
|
if (Array.isArray(res.data) && res.data.length > 0){ |
||||
|
console.log("Details Array:", response); |
||||
|
|
||||
|
|
||||
|
let table = $('#WardDatatable').DataTable({ |
||||
|
destroy: true, |
||||
|
autoWidth: true, |
||||
|
info: true, |
||||
|
data: res.data, // using response directly |
||||
|
columns: [ |
||||
|
{ data: 'division', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'total_request', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'this_week_requests', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'older_requests', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'completed', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'user_cancel', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'officer_cancel', defaultContent: '-', className: 'text-center' }, |
||||
|
{ data: 'pending', defaultContent: '-', className: 'text-center' } |
||||
|
], |
||||
|
dom: 'frtip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: '400px', |
||||
|
scrollX: true, |
||||
|
responsive: false, |
||||
|
searching: false, |
||||
|
ordering: false, |
||||
|
createdRow: function (row, data, dataIndex) { |
||||
|
if (dataIndex === res.data.length - 1) return; |
||||
|
|
||||
|
const clickableCols = ['this_week_requests', 'completed', 'user_cancel', 'officer_cancel']; |
||||
|
|
||||
|
clickableCols.forEach((col) => { |
||||
|
const value = parseInt(data[col]); |
||||
|
if (!isNaN(value) && value > 0) { |
||||
|
const colIndex = { |
||||
|
this_week_requests: 2, |
||||
|
completed: 4, |
||||
|
user_cancel: 5, |
||||
|
officer_cancel: 6 |
||||
|
}[col]; |
||||
|
|
||||
|
$('td:eq(' + colIndex + ')', row).css({ |
||||
|
'color': '#007bff', |
||||
|
'text-decoration': 'underline', |
||||
|
'cursor': 'pointer' |
||||
|
}); |
||||
|
} |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
$('#zoneDetailsModal').modal('show'); |
||||
|
} |
||||
|
else if (Array.isArray(res.data) && res.data.length === 0){ |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
else{ |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: res.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
} |
||||
|
else if (res.status === "nodata") { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: res.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
// Attach click handler after DataTable initialization |
||||
|
$('#WardDatatable tbody').off('click').on('click', 'td', function () { |
||||
|
let table = $('#WardDatatable').DataTable(); |
||||
|
let rowData = table.row($(this).closest('tr')).data(); |
||||
|
let columnIndex = table.cell(this).index().column; |
||||
|
|
||||
|
// Define column-to-status mapping (based on your requirement) |
||||
|
const columnMap = { |
||||
|
2: 1, // open |
||||
|
4: 2, // completed |
||||
|
5: 4, // user_cancel |
||||
|
6: 5 // officer_cancel |
||||
|
}; |
||||
|
|
||||
|
// Get column name using column index |
||||
|
let columnName = table.column(columnIndex).dataSrc(); |
||||
|
|
||||
|
// If clicked column is one of the target columns |
||||
|
if (columnMap[columnIndex]) { |
||||
|
let status = columnMap[columnIndex]; |
||||
|
let value = rowData[columnName]; |
||||
|
let division = rowData['division']; |
||||
|
|
||||
|
// Proceed only if value > 0 |
||||
|
if (parseInt(value) > 0) { |
||||
|
openWardDetails(division, status); |
||||
|
} |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
}, |
||||
|
error: function(xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Request failed: " + error); |
||||
|
|
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
function openWardDetails(division, status){ |
||||
|
console.log("division:",division," status:",status); |
||||
|
// Optional: show in a modal or send AJAX |
||||
|
|
||||
|
$('#pageLoader').show(); |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/sofabedcollection/getWardStatusReport', |
||||
|
method: 'GET', |
||||
|
data: { |
||||
|
ward: division, |
||||
|
status: status |
||||
|
}, |
||||
|
success: function (response) { |
||||
|
$('#pageLoader').hide(); |
||||
|
var res = Array.isArray(response) ? response[0] : response; |
||||
|
//console.log("Response:", res); |
||||
|
|
||||
|
$('#pageLoader').hide(); |
||||
|
console.log("Details:", res); |
||||
|
if(res.status === "Success"){ |
||||
|
|
||||
|
let modalBody = $("#detailscontent"); |
||||
|
modalBody.empty(); // Clear previous content |
||||
|
|
||||
|
|
||||
|
|
||||
|
if (Array.isArray(res.data) && res.data.length > 0){ |
||||
|
|
||||
|
res.data.forEach(item => { |
||||
|
// Create a container div for each record |
||||
|
let streetDiv = $('<div class="mb-4 p-3 border rounded shadow-sm bg-light"></div>'); |
||||
|
|
||||
|
// Info section (2 columns layout) |
||||
|
let infoHtml = ` |
||||
|
<div class="container-fluid"> |
||||
|
<div class="row mb-2"> |
||||
|
<div class="col-md-4"><strong>Zone:</strong> ${item.zone || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Ward:</strong> ${item.division || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Request ID:</strong> ${item.request_id || '-'}</div> |
||||
|
</div> |
||||
|
<div class="row mb-2"> |
||||
|
<div class="col-md-4"><strong>User Name:</strong> ${item.user_name || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Status:</strong> ${item.status || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Mobile Number:</strong> ${item.mobile || '-'}</div> |
||||
|
</div> |
||||
|
<div class="row mb-2"> |
||||
|
<div class="col-md-8"><strong>Address:</strong> ${item.address || '-'}</div> |
||||
|
<div class="col-md-4"><strong>Created Date:</strong> ${item.cdate || '-'}</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
`; |
||||
|
streetDiv.append(infoHtml); |
||||
|
|
||||
|
|
||||
|
// 🧾 Items section (as divs) |
||||
|
let itemsHtml = ` |
||||
|
<div class="mt-3"> |
||||
|
<p><strong>Items:</strong></p> |
||||
|
${ |
||||
|
Array.isArray(item.items) && item.items.length > 0 |
||||
|
? item.items.map((it, idx) => ` |
||||
|
<div class="d-flex flex-wrap border rounded p-2 mb-2 "> |
||||
|
<div class="flex-fill"><strong>Item ${idx + 1}:</strong> ${it.item_name || '-'}</div> |
||||
|
<div class="flex-fill"><strong>Quantity:</strong> ${it.quantity ?? '-'}</div> |
||||
|
</div> |
||||
|
`).join("") |
||||
|
: `<p class="text-muted">No items available.</p>` |
||||
|
} |
||||
|
</div> |
||||
|
`; |
||||
|
streetDiv.append(itemsHtml); |
||||
|
|
||||
|
|
||||
|
// Image section |
||||
|
let imagesHtml = ` |
||||
|
<hr> |
||||
|
<div class="mt-2" style="text-align:center;"> |
||||
|
<p><strong>Image:</strong></p> |
||||
|
${ |
||||
|
item.image_url |
||||
|
? (() => { |
||||
|
// Handle multiple comma-separated images |
||||
|
return item.image_url.split(",").map(img => { |
||||
|
let trimmed = img.trim(); |
||||
|
return ` |
||||
|
<img src="${trimmed}" |
||||
|
alt="Image" |
||||
|
class="img-thumbnail me-2 mb-2 preview-img" |
||||
|
style="width: 250px; height: 200px; object-fit: contain; cursor: pointer;" |
||||
|
data-bs-toggle="modal" |
||||
|
data-bs-target="#imageModal" |
||||
|
/> |
||||
|
`; |
||||
|
}).join(""); |
||||
|
})() |
||||
|
: `<p class="text-muted">No images available.</p>` |
||||
|
} |
||||
|
</div> |
||||
|
`; |
||||
|
streetDiv.append(imagesHtml); |
||||
|
|
||||
|
modalBody.append(streetDiv); |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
$('#DeatilsModalTitle').text('Division '+division +' Details'); |
||||
|
$('#DetailsModal').modal('show'); |
||||
|
} |
||||
|
|
||||
|
else if (Array.isArray(res.data) && res.data.length === 0){ |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
else{ |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: response.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
else if (res.status === "nodata") { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("No data available."); |
||||
|
Swal.fire({ |
||||
|
icon: 'info', |
||||
|
title: 'No Data', |
||||
|
text: 'No data available.', |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
else { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Error: " + response.message); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: res.message, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
}, |
||||
|
error: function (xhr, status, error) { |
||||
|
$('#pageLoader').hide(); |
||||
|
//alert("Request failed: " + error); |
||||
|
Swal.fire({ |
||||
|
icon: 'error', |
||||
|
title: 'Error', |
||||
|
text: error, |
||||
|
showConfirmButton: true, |
||||
|
timer: 3000 |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,281 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Solid Waste Management</title> |
||||
|
<style> |
||||
|
body { |
||||
|
font-family: Arial, sans-serif; |
||||
|
padding: 20px; |
||||
|
} |
||||
|
|
||||
|
h3 { |
||||
|
text-align: center; |
||||
|
padding: 10px; |
||||
|
|
||||
|
} |
||||
|
|
||||
|
table { |
||||
|
width: 100%; |
||||
|
border-collapse: collapse; |
||||
|
margin-top: 20px; |
||||
|
} |
||||
|
|
||||
|
th, td { |
||||
|
border: 1px solid #000; |
||||
|
padding: 8px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
.total{ |
||||
|
font-weight:bold; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<h3>DETAILS OF WET WASTE AND DRY WASTE PROCESSING AGAINST DESIGN CAPACITY (MT) <br> |
||||
|
(01.05.2025 to 14.05.2025) (AVERAGE)</h3> |
||||
|
|
||||
|
<table> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th rowspan="2">Zone</th> |
||||
|
<th colspan="5">TOTAL WET WASTE (MT)</th> |
||||
|
<th colspan="5">TOTAL DRY WASTE (MT)</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Design Capacity (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last Fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This Fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Target (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last Fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This Fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr><td>1</td><td>78.23</td><td>51.68</td><td>66</td><td>51.31</td><td>66</td><td>9.97</td><td>3.51</td><td>35</td><td>2.83</td><td>28</td></tr> |
||||
|
<tr><td>2</td><td>40.48</td><td>26.32</td><td>65</td><td>25.72</td><td>64</td><td>16.98</td><td>1.42</td><td>8</td><td>1.36</td><td>8</td></tr> |
||||
|
<tr><td>3</td><td>74.08</td><td>39.58</td><td>53</td><td>37.16</td><td>50</td><td>29.24</td><td>5.85</td><td>20</td><td>4.71</td><td>16</td></tr> |
||||
|
<tr><td>4</td><td>126.09</td><td>41.79</td><td>33</td><td>37.59</td><td>30</td><td>93.35</td><td>5.58</td><td>6</td><td>5.14</td><td>6</td></tr> |
||||
|
<tr><td>5</td><td>130.23</td><td>15.44</td><td>12</td><td>12.9</td><td>10</td><td>83.35</td><td>8.58</td><td>10</td><td>6.1</td><td>7</td></tr> |
||||
|
<tr><td>6</td><td>48.94</td><td>8.04</td><td>16</td><td>7.62</td><td>16</td><td>24.43</td><td>0.81</td><td>3</td><td>0.98</td><td>4</td></tr> |
||||
|
<tr><td>7</td><td>57.47</td><td>24.47</td><td>43</td><td>22.53</td><td>39</td><td>38.49</td><td>2.11</td><td>5</td><td>1.67</td><td>4</td></tr> |
||||
|
<tr><td>8</td><td>47.55</td><td>11.11</td><td>23</td><td>10.56</td><td>22</td><td>25.46</td><td>4.82</td><td>19</td><td>5.84</td><td>23</td></tr> |
||||
|
<tr><td>9</td><td>57.63</td><td>50.38</td><td>87</td><td>46.21</td><td>80</td><td>36.4</td><td>36.45</td><td>100</td><td>33.19</td><td>91</td></tr> |
||||
|
<tr><td>10</td><td>43</td><td>14.64</td><td>34</td><td>19.37</td><td>45</td><td>25.46</td><td>4.19</td><td>16</td><td>9.02</td><td>35</td></tr> |
||||
|
<tr><td>11</td><td>31</td><td>20.17</td><td>65</td><td>18.16</td><td>59</td><td>21</td><td>11.01</td><td>52</td><td>9.65</td><td>46</td></tr> |
||||
|
<tr><td>12</td><td>50.44</td><td>24.92</td><td>49</td><td>23.39</td><td>46</td><td>32.75</td><td>10</td><td>31</td><td>9.24</td><td>28</td></tr> |
||||
|
<tr><td>13</td><td>46.29</td><td>17.44</td><td>38</td><td>15.29</td><td>33</td><td>31.21</td><td>7.57</td><td>24</td><td>6.41</td><td>21</td></tr> |
||||
|
<tr><td>14</td><td>55.8</td><td>18.28</td><td>33</td><td>17.49</td><td>31</td><td>22</td><td>9.12</td><td>41</td><td>7.99</td><td>36</td></tr> |
||||
|
<tr><td>15</td><td>13.85</td><td>16.62</td><td>100</td><td>16.24</td><td>100</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr class="total"><td>Total</td><td>901.08</td><td>380.89</td><td>42</td><td>361.54</td><td>40</td><td>490.1</td><td>132.87</td><td>27</td><td>104.11</td><td>21</td></tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
<h3>WET WASTE PROCESSING REPORT (MCC & BIO-CNG)</h3> |
||||
|
|
||||
|
<table> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th rowspan="2">Zone</th> |
||||
|
<th colspan="5">MCC (MT)</th> |
||||
|
<th colspan="5">BIO-CNG (MT)</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Design Capacity (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Target (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr><td>1</td><td>28.26</td><td>19.97</td><td>71</td><td>19.81</td><td>70</td><td>9.97</td><td>3.51</td><td>35</td><td>2.83</td><td>28</td></tr> |
||||
|
<tr><td>2</td><td>8.5</td><td>8.76</td><td>100</td><td>8.73</td><td>100</td><td>16.98</td><td>1.42</td><td>8</td><td>1.36</td><td>8</td></tr> |
||||
|
<tr><td>3</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>29.24</td><td>5.85</td><td>20</td><td>4.71</td><td>16</td></tr> |
||||
|
<tr><td>4</td><td>6.34</td><td>11.6</td><td>100</td><td>8.65</td><td>100</td><td>93.35</td><td>5.58</td><td>6</td><td>5.14</td><td>6</td></tr> |
||||
|
<tr><td>5</td><td>19.38</td><td>3.83</td><td>20</td><td>4.31</td><td>22</td><td>83.35</td><td>8.58</td><td>10</td><td>6.1</td><td>7</td></tr> |
||||
|
<tr><td>6</td><td>3.01</td><td>2.89</td><td>96</td><td>2.45</td><td>82</td><td>24.43</td><td>0.81</td><td>3</td><td>0.98</td><td>4</td></tr> |
||||
|
<tr><td>7</td><td>3.58</td><td>3.57</td><td>100</td><td>3.58</td><td>100</td><td>38.49</td><td>2.11</td><td>5</td><td>1.67</td><td>4</td></tr> |
||||
|
<tr><td>8</td><td>4.95</td><td>2.01</td><td>41</td><td>0.85</td><td>17</td><td>25.46</td><td>4.82</td><td>19</td><td>5.84</td><td>23</td></tr> |
||||
|
<tr><td>9</td><td>5.23</td><td>3.04</td><td>58</td><td>2.82</td><td>54</td><td>36.4</td><td>36.45</td><td>100</td><td>33.19</td><td>91</td></tr> |
||||
|
<tr><td>10</td><td>1.94</td><td>0</td><td>0</td><td>0</td><td>0</td><td>25.46</td><td>4.19</td><td>16</td><td>9.02</td><td>35</td></tr> |
||||
|
<tr><td>11</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>21</td><td>11.01</td><td>52</td><td>9.65</td><td>46</td></tr> |
||||
|
<tr><td>12</td><td>6.94</td><td>6.72</td><td>97</td><td>6.54</td><td>94</td><td>32.75</td><td>10</td><td>31</td><td>9.24</td><td>28</td></tr> |
||||
|
<tr><td>13</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>31.21</td><td>7.57</td><td>24</td><td>6.41</td><td>21</td></tr> |
||||
|
<tr><td>14</td><td>23.8</td><td>0</td><td>0</td><td>0</td><td>0</td><td>22</td><td>9.12</td><td>41</td><td>7.99</td><td>36</td></tr> |
||||
|
<tr><td>15</td><td>3.85</td><td>3.97</td><td>100</td><td>4.13</td><td>100</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr class="total"> |
||||
|
<td>Total</td> |
||||
|
<td>115.77</td><td>66.37</td><td>57</td><td>61.87</td><td>53</td> |
||||
|
<td>490.1</td><td>132.87</td><td>27</td><td>104.11</td><td>21</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
|
||||
|
|
||||
|
<h3>WET WASTE – BIO GAS & BIO-METHANATION</h3> |
||||
|
|
||||
|
<table> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th rowspan="2">Zone</th> |
||||
|
<th colspan="5">BIO GAS (MT)</th> |
||||
|
<th colspan="5">BIO-METHANATION (MT)</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Design Capacity (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Target (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr><td>1</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>2</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>3</td><td>0.1</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>4</td><td>1.4</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>5</td><td>0.5</td><td>0</td><td>0</td><td>0</td><td>2</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>6</td><td>1.5</td><td>0</td><td>0</td><td>0</td><td>10</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>7</td><td>2.4</td><td>0.5</td><td>21</td><td>0.5</td><td>21</td><td>3</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>8</td><td>1.14</td><td>0</td><td>0</td><td>0</td><td>0</td><td>6</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>9</td><td>1</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>10</td><td>0.6</td><td>0</td><td>0</td><td>0.04</td><td>7</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>11</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>12</td><td>0.75</td><td>0.99</td><td>100</td><td>1</td><td>100</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>13</td><td>0.08</td><td>0.02</td><td>25</td><td>0.02</td><td>23</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>14</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>15</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td></tr> |
||||
|
<tr class="total"> |
||||
|
<td >Total</td> |
||||
|
<td>9.47</td><td>1.51</td><td>16</td><td>1.56</td><td>17</td> |
||||
|
<td>21</td><td>0</td><td>0</td><td>0</td><td>0</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
|
||||
|
|
||||
|
<h3>WET WASTE – WINDROW & HORTICULTURAL WASTE</h3> |
||||
|
|
||||
|
<table> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th rowspan="2">Zone</th> |
||||
|
<th colspan="5">WINDROW (MT)</th> |
||||
|
<th colspan="5">HORTICULTURAL WASTE (MT)</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Design Capacity (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Target (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr><td>1</td><td>30</td><td>25.04</td><td>83</td><td>25.65</td><td>86</td><td>10</td><td>3.16</td><td>32</td><td>3.01</td><td>30</td></tr> |
||||
|
<tr><td>2</td><td>10</td><td>14.9</td><td>100</td><td>15.14</td><td>100</td><td>5</td><td>1.24</td><td>25</td><td>0.5</td><td>10</td></tr> |
||||
|
<tr><td>3</td><td>34.74</td><td>29.94</td><td>86</td><td>29.81</td><td>86</td><td>10</td><td>3.78</td><td>38</td><td>2.65</td><td>27</td></tr> |
||||
|
<tr><td>4</td><td>15</td><td>22.21</td><td>100</td><td>21.68</td><td>100</td><td>10</td><td>2.4</td><td>24</td><td>2.13</td><td>21</td></tr> |
||||
|
<tr><td>5</td><td>15</td><td>1.02</td><td>7</td><td>0.61</td><td>4</td><td>10</td><td>2.01</td><td>20</td><td>1.89</td><td>19</td></tr> |
||||
|
<tr><td>6</td><td>0</td><td>1.33</td><td>100</td><td>1.48</td><td>100</td><td>10</td><td>3.01</td><td>30</td><td>2.7</td><td>27</td></tr> |
||||
|
<tr><td>7</td><td>0</td><td>11.92</td><td>100</td><td>11.52</td><td>100</td><td>10</td><td>6.37</td><td>64</td><td>5.26</td><td>53</td></tr> |
||||
|
<tr><td>8</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>10</td><td>4.28</td><td>43</td><td>3.88</td><td>39</td></tr> |
||||
|
<tr><td>9</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>15</td><td>10.88</td><td>73</td><td>10.2</td><td>68</td></tr> |
||||
|
<tr><td>10</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>15</td><td>10.45</td><td>70</td><td>10.31</td><td>69</td></tr> |
||||
|
<tr><td>11</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>10</td><td>9.17</td><td>92</td><td>8.51</td><td>85</td></tr> |
||||
|
<tr><td>12</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>10</td><td>7.21</td><td>72</td><td>6.6</td><td>66</td></tr> |
||||
|
<tr><td>13</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>15</td><td>9.85</td><td>66</td><td>8.86</td><td>59</td></tr> |
||||
|
<tr><td>14</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>10</td><td>9.16</td><td>92</td><td>9.5</td><td>95</td></tr> |
||||
|
<tr><td>15</td><td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>10</td><td>12.65</td><td>100</td><td>12.11</td><td>100</td></tr> |
||||
|
<tr class="total"> |
||||
|
<td>Total</td> |
||||
|
<td>104.74</td><td>79.78</td><td>76</td><td>105.88</td><td>101</td> |
||||
|
<td>160</td><td>92.06</td><td>58</td><td>88.12</td><td>55</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
<h3>DRY WASTE – PLASTIC BALING CENTER & INCINERATOR</h3> |
||||
|
|
||||
|
<table> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th rowspan="2">Zone</th> |
||||
|
<th colspan="5">Plastic waste sent to Baling Center (MT)</th> |
||||
|
<th colspan="5">Incinerator (MT)</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Design Capacity (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Target (MT)</th> |
||||
|
<th>Processing (TPD)<br>Last fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
<th>Processing (TPD)<br>This fortnight</th> |
||||
|
<th>Percentage %</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr><td>1</td><td>4</td><td>0</td><td>0</td><td>0</td><td>0</td><td>2</td><td>3.71</td><td>186</td><td>11.79</td><td>100</td></tr> |
||||
|
<tr><td>2</td><td>4</td><td>0</td><td>0</td><td>0</td><td>0</td><td>1</td><td>2.22</td><td>222</td><td>5.83</td><td>100</td></tr> |
||||
|
<tr><td>3</td><td>4</td><td>0</td><td>0</td><td>0</td><td>0</td><td>2</td><td>0.73</td><td>36</td><td>4.57</td><td>100</td></tr> |
||||
|
<tr><td>4</td><td>3</td><td>0</td><td>0</td><td>0</td><td>0</td><td>6</td><td>2.24</td><td>37</td><td>2.34</td><td>39</td></tr> |
||||
|
<tr><td>5</td><td>4</td><td>0</td><td>0</td><td>0</td><td>0</td><td>6</td><td>0.2</td><td>3</td><td>0</td><td>0</td></tr> |
||||
|
<tr><td>6</td><td>4</td><td>0</td><td>0</td><td>0</td><td>0</td><td>5</td><td>0.95</td><td>19</td><td>1.3</td><td>26</td></tr> |
||||
|
<tr><td>7</td><td>4</td><td>0.43</td><td>11</td><td>1.29</td><td>32</td><td>5</td><td>0.97</td><td>19</td><td>3.02</td><td>60</td></tr> |
||||
|
<tr><td>8</td><td>4</td><td>0.11</td><td>3</td><td>0.12</td><td>3</td><td>6</td><td>0.17</td><td>3</td><td>0.09</td><td>1</td></tr> |
||||
|
<tr><td>9</td><td>4</td><td>0</td><td>0</td><td>0</td><td>0</td><td>6</td><td>2.45</td><td>41</td><td>2.38</td><td>40</td></tr> |
||||
|
<tr><td>10</td><td>4</td><td>0</td><td>0</td><td>0</td><td>0</td><td>5.5</td><td>1.82</td><td>33</td><td>0.81</td><td>15</td></tr> |
||||
|
<tr><td>11</td><td>3</td><td>0</td><td>0</td><td>0</td><td>0</td><td>3</td><td>1.58</td><td>53</td><td>2.67</td><td>89</td></tr> |
||||
|
<tr><td>12</td><td>3</td><td>0</td><td>0</td><td>0</td><td>0</td><td>2</td><td>0.92</td><td>46</td><td>0.78</td><td>39</td></tr> |
||||
|
<tr><td>13</td><td>4</td><td>0</td><td>0</td><td>0</td><td>0</td><td>5</td><td>1.09</td><td>22</td><td>1.03</td><td>21</td></tr> |
||||
|
<tr><td>14</td><td>3</td><td>0</td><td>0</td><td>0</td><td>0</td><td>3</td><td>0.22</td><td>7</td><td>0.69</td><td>23</td></tr> |
||||
|
<tr><td>15</td><td>3</td><td>0</td><td>0</td><td>0</td><td>0</td><td>2.5</td><td>1.13</td><td>45</td><td>0.88</td><td>35</td></tr> |
||||
|
<tr class="total"> |
||||
|
<td>Total</td> |
||||
|
<td>55</td><td>0.54</td><td>1</td><td>1.41</td><td>3</td> |
||||
|
<td>60</td><td>20.42</td><td>34</td><td>38.18</td><td>64</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,114 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>SR GM Projects Progress</title> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<style> |
||||
|
body { |
||||
|
padding: 40px; |
||||
|
font-family: Arial, sans-serif; |
||||
|
} |
||||
|
|
||||
|
h1 { |
||||
|
margin-bottom: 20px; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
<h1>SR GM Projects Progress</h1> |
||||
|
<table border="1" class="dataframe table table-striped"> |
||||
|
<thead> |
||||
|
<tr style="text-align: center;"> |
||||
|
<th>S.No</th> |
||||
|
<th>Zone No.</th> |
||||
|
<th>Name of the Project</th> |
||||
|
<th>Issues</th> |
||||
|
<th>Current Status</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr> |
||||
|
<td>1</td> |
||||
|
<td>4</td> |
||||
|
<td>LC-2B - Manali ROB (Honarable Minister Announcement 2022-23)</td> |
||||
|
<td>Railway portion of work to be expedited fastly.</td> |
||||
|
<td>90% of GCC portion has been completed. Railway portion of work to be expedited fastly.</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>2</td> |
||||
|
<td>4</td> |
||||
|
<td>LC-2A - Ennore High road (Honarable Minister Announcement 2024-25)</td> |
||||
|
<td>GAD to be approved by SR.</td> |
||||
|
<td>Tender to be called by the Railways for the Railway portion. GCC called tender and work order to be |
||||
|
issued. |
||||
|
</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>3</td> |
||||
|
<td>4</td> |
||||
|
<td>Ganesapuram ROB (Honarable Minister Announcement 2021-22)</td> |
||||
|
<td>To depute an official for Railway portion of work.</td> |
||||
|
<td>Railway portion of ROB: 32/36 Pile, 1/4 Pile cap and 0/4 Pier. Pile work is in progress.</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>4</td> |
||||
|
<td>4</td> |
||||
|
<td>Ganesapuram ROB Push through Culvert</td> |
||||
|
<td>To issue Caution Order permission to carry out the Cluster work.</td> |
||||
|
<td>As requested by the Railways Rs. 1,06,84,410/- has been remitted to Railways towards Departmental and Way |
||||
|
leave charges on 19.06.2024 & 17.08.2024 respectively. It was requested the Railways on 08.08.2024 to |
||||
|
provide rails of 1600m for the cluster work and to accord permission for the line block. 4th unit casted on |
||||
|
21.08.2024. Letter has been sent to the Railways on 28.01.2025 to accord Caution Order permission. Cluster |
||||
|
work will be commenced immediately after the obtaining Caution Order permission from the Railways |
||||
|
</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>5</td> |
||||
|
<td>7</td> |
||||
|
<td>Ambattur LC6 Subway</td> |
||||
|
<td>Railways to deposit the balance amount of Rs.5,39,90,520/- to GCC.</td> |
||||
|
<td>Letter sent to Railways on 19.06.2024 to remit the amount Rs.5,39,90,520/- to GCC.</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>6</td> |
||||
|
<td>12</td> |
||||
|
<td>LC-14- FOB</td> |
||||
|
<td>Clarification requested from the Railways. Earlier Railways informed this project will be taken up by their |
||||
|
own fund (100% by Railways) except the Lift cost. Now Railways requested for 50:50 cost sharing basis. |
||||
|
</td> |
||||
|
<td>GCC has given the approval for the Revised GAD on 19.08.2024.</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>7</td> |
||||
|
<td>5</td> |
||||
|
<td>LC11A- Bojaraja Nagar Subway</td> |
||||
|
<td>Utilization Certificate to be issued by the Railways.</td> |
||||
|
<td>Letter sent to the SR to accord permission to demolish Railway's Compound wall on 23.09.2024. Requested |
||||
|
the Railways to issue Utilisation Certificate, the Sr.DEN/Co-ordination, Southern Railway has requested the |
||||
|
GCC to deposit the balance amount of Rs.8,05,844 to Railways. The balance amount has been remitted to |
||||
|
Railways on 30.09.2024 . Utilization Certificate yet to issue by the Railways. |
||||
|
</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>8</td> |
||||
|
<td>4</td> |
||||
|
<td>LC-2 ROB- Korukkupet (Honarable Minister Announcement 2025-26)</td> |
||||
|
<td>Railways to approve the GAD</td> |
||||
|
<td>Alignment drawing has been sent to the Railways on 22.10.2024.</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,310 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Facia Replacement Progress Report</title> |
||||
|
<style> |
||||
|
body { |
||||
|
font-family: Arial, sans-serif; |
||||
|
padding: 20px; |
||||
|
} |
||||
|
|
||||
|
h1 { |
||||
|
background-color: lightgreen; |
||||
|
padding: 10px; |
||||
|
font-size: 22px; |
||||
|
} |
||||
|
|
||||
|
table { |
||||
|
width: 100%; |
||||
|
border-collapse: collapse; |
||||
|
margin-top: 20px; |
||||
|
font-size: 14px; |
||||
|
} |
||||
|
|
||||
|
th, td { |
||||
|
border: 1px solid #000; |
||||
|
padding: 6px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
tr:nth-child(even) { |
||||
|
background-color: #f1f1f1; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
<h1>Facia Replacement Progress Report</h1> |
||||
|
<table> |
||||
|
<tr> |
||||
|
<th rowspan="2">S.No</th> |
||||
|
<th rowspan="2">Pack No</th> |
||||
|
<th rowspan="2">Zone</th> |
||||
|
<th colspan="2">Replacing Facia</th> |
||||
|
<th rowspan="2">Est. Amt (Rs. in Lakhs)</th> |
||||
|
<th colspan="2">Completed</th> |
||||
|
<th colspan="2">Progress</th> |
||||
|
<th colspan="2">To be taken</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Single Arrow</th> |
||||
|
<th>Double Arrow</th> |
||||
|
<th>Single Arrow</th> |
||||
|
<th>Double Arrow</th> |
||||
|
<th>Single Arrow</th> |
||||
|
<th>Double Arrow</th> |
||||
|
<th>Single Arrow</th> |
||||
|
<th>Double Arrow</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>1</td> |
||||
|
<td>1</td> |
||||
|
<td>I</td> |
||||
|
<td>238</td> |
||||
|
<td>25</td> |
||||
|
<td>49.31</td> |
||||
|
<td>48</td> |
||||
|
<td>0</td> |
||||
|
<td>162</td> |
||||
|
<td>0</td> |
||||
|
<td>28</td> |
||||
|
<td>25</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>2</td> |
||||
|
<td></td> |
||||
|
<td>II</td> |
||||
|
<td>172</td> |
||||
|
<td>1</td> |
||||
|
<td>31.89</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>172</td> |
||||
|
<td>1</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>3</td> |
||||
|
<td></td> |
||||
|
<td>III</td> |
||||
|
<td>644</td> |
||||
|
<td>33</td> |
||||
|
<td>124.89</td> |
||||
|
<td>17</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>627</td> |
||||
|
<td>33</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>4</td> |
||||
|
<td></td> |
||||
|
<td>IV</td> |
||||
|
<td>1250</td> |
||||
|
<td>72</td> |
||||
|
<td>245.96</td> |
||||
|
<td>266</td> |
||||
|
<td>15</td> |
||||
|
<td>653</td> |
||||
|
<td>0</td> |
||||
|
<td>331</td> |
||||
|
<td>57</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>5</td> |
||||
|
<td></td> |
||||
|
<td>V</td> |
||||
|
<td>196</td> |
||||
|
<td>0</td> |
||||
|
<td>36.09</td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>6</td> |
||||
|
<td></td> |
||||
|
<td>VI</td> |
||||
|
<td>605</td> |
||||
|
<td>82</td> |
||||
|
<td>129.41</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>2</td> |
||||
|
<td>0</td> |
||||
|
<td>603</td> |
||||
|
<td>82</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>7</td> |
||||
|
<td></td> |
||||
|
<td>VII</td> |
||||
|
<td>113</td> |
||||
|
<td>3</td> |
||||
|
<td>21.46</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>113</td> |
||||
|
<td>3</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>8</td> |
||||
|
<td></td> |
||||
|
<td>VIII</td> |
||||
|
<td>777</td> |
||||
|
<td>34</td> |
||||
|
<td>149.32</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>777</td> |
||||
|
<td>34</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>9</td> |
||||
|
<td>2</td> |
||||
|
<td>IX</td> |
||||
|
<td>302</td> |
||||
|
<td>44</td> |
||||
|
<td>65.27</td> |
||||
|
<td>129</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>173</td> |
||||
|
<td>44</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>10</td> |
||||
|
<td></td> |
||||
|
<td>X</td> |
||||
|
<td>216</td> |
||||
|
<td>12</td> |
||||
|
<td>42.4</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>216</td> |
||||
|
<td>12</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>11</td> |
||||
|
<td></td> |
||||
|
<td>XI</td> |
||||
|
<td>276</td> |
||||
|
<td>15</td> |
||||
|
<td>54.11</td> |
||||
|
<td>80</td> |
||||
|
<td>10</td> |
||||
|
<td>25</td> |
||||
|
<td>5</td> |
||||
|
<td>171</td> |
||||
|
<td>0</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>12</td> |
||||
|
<td></td> |
||||
|
<td>XII</td> |
||||
|
<td>399</td> |
||||
|
<td>0</td> |
||||
|
<td>73.46</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>399</td> |
||||
|
<td>0</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>13</td> |
||||
|
<td></td> |
||||
|
<td>XIII</td> |
||||
|
<td>1598</td> |
||||
|
<td>76</td> |
||||
|
<td>359.3</td> |
||||
|
<td>11</td> |
||||
|
<td>1</td> |
||||
|
<td>1</td> |
||||
|
<td>0</td> |
||||
|
<td>1586</td> |
||||
|
<td>75</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>14</td> |
||||
|
<td></td> |
||||
|
<td>XIV</td> |
||||
|
<td>174</td> |
||||
|
<td>19</td> |
||||
|
<td>36.21</td> |
||||
|
<td>5</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>169</td> |
||||
|
<td>19</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>15</td> |
||||
|
<td></td> |
||||
|
<td>XV</td> |
||||
|
<td>454</td> |
||||
|
<td>7</td> |
||||
|
<td>85.12</td> |
||||
|
<td>259</td> |
||||
|
<td>0</td> |
||||
|
<td>10</td> |
||||
|
<td>0</td> |
||||
|
<td>185</td> |
||||
|
<td>7</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>16</td> |
||||
|
<td></td> |
||||
|
<td>BRR</td> |
||||
|
<td>184</td> |
||||
|
<td>50</td> |
||||
|
<td>44.87</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>0</td> |
||||
|
<td>184</td> |
||||
|
<td>50</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
<td>TOTAL</td> |
||||
|
<td>7830</td> |
||||
|
<td>510</td> |
||||
|
<td>1549.07</td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
<td></td> |
||||
|
</tr> |
||||
|
|
||||
|
</table> |
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,197 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>DBFOT of Public Toilets</title> |
||||
|
|
||||
|
<!-- Bootstrap & DataTables --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
.table thead th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
text-align: center; |
||||
|
white-space: normal; |
||||
|
font-size: 16px; |
||||
|
} |
||||
|
.table th, .table td { |
||||
|
white-space: normal; |
||||
|
word-break: break-word; |
||||
|
padding: 6px 8px; |
||||
|
font-size: 16px; |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
} |
||||
|
.modal-header { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
.clickable-cell { |
||||
|
cursor: pointer; |
||||
|
color: #0d6efd; |
||||
|
text-decoration: underline; |
||||
|
} |
||||
|
.clickable-cell:hover { |
||||
|
opacity: 0.8; |
||||
|
} |
||||
|
#dbfotTable, #dbfotTable th, #dbfotTable td { |
||||
|
border: 1px solid #000 !important; |
||||
|
} |
||||
|
.modal-body table, .modal-body th, .modal-body td { |
||||
|
border: 1px solid #000 !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body class="p-4"> |
||||
|
|
||||
|
<div class="table-responsive"> |
||||
|
<table id="dbfotTable" class="table table-bordered w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th colspan="8" style="text-align: center;"><strong>DBFOT of Public Toilets</strong></th> |
||||
|
|
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Package No.</th> |
||||
|
<th>Target No. of Locations</th> |
||||
|
<th>Target No. of Seats</th> |
||||
|
<th>No. of locations Construction completed</th> |
||||
|
<th>No. of seats completed</th> |
||||
|
<th>No. of New Toilets</th> |
||||
|
<th>No. of Minor Repairs</th> |
||||
|
<th>No. of Major Repairs</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody></tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Modal --> |
||||
|
<div class="modal fade" id="package1Modal" tabindex="-1" aria-labelledby="package1ModalLabel" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-xl modal-dialog-scrollable"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="package1ModalLabel"> List of Locations</h5> |
||||
|
<button type="button" class="btn-close bg-light" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
<table class="table table-bordered"> |
||||
|
<thead style="background-color: #003366; color: white;"> |
||||
|
<tr> |
||||
|
<th>S.No</th> |
||||
|
<th>Zone No.</th> |
||||
|
<th>Location Name</th> |
||||
|
<th>Total No. of Seats</th> |
||||
|
<th>Toilet Status</th> |
||||
|
<th>Toilet Type</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody></tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://code.jquery.com/jquery-3.7.0.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
$('#dbfotTable').DataTable({ |
||||
|
paging: false, |
||||
|
searching: false, |
||||
|
ordering: false, |
||||
|
info: false |
||||
|
}); |
||||
|
|
||||
|
fetch('/commissionerreview/toilet/api/getSFDData') |
||||
|
.then(res => res.json()) |
||||
|
.then(result => { |
||||
|
const tbody = $('#dbfotTable tbody'); |
||||
|
tbody.empty(); |
||||
|
|
||||
|
result.data.forEach((pack, index) => { |
||||
|
const pkgNo = index + 1; |
||||
|
const packKey = `pack${pkgNo}`; |
||||
|
const loc = pack[`${packKey}_toilet_location`] || 0; |
||||
|
const seats = pack[`${packKey}_total_seat`] || 0; |
||||
|
const newC = pack[`${packKey}_new_count`] || 0; |
||||
|
const minor = pack[`${packKey}_minor_count`] || 0; |
||||
|
const major = pack[`${packKey}_major_count`] || 0; |
||||
|
|
||||
|
// 👇 Define specific pairs to override |
||||
|
const overridePairs = [ |
||||
|
{ loc: 285, seats: 2301 }, |
||||
|
{ loc: 381, seats: 2662 }, |
||||
|
{ loc: 304, seats: 1990 } |
||||
|
]; |
||||
|
|
||||
|
// 👇 Check if current pair matches any of the overrides |
||||
|
const isOverride = overridePairs.some(pair => pair.loc === loc && pair.seats === seats); |
||||
|
|
||||
|
const locationsCompleted = isOverride ? 0 : loc; |
||||
|
const seatsCompleted = isOverride ? 0 : seats; |
||||
|
|
||||
|
const rowHtml = ` |
||||
|
<tr> |
||||
|
<td>${pkgNo}</td> |
||||
|
<td><span class="clickable-cell" data-pack="${packKey}" data-bs-toggle="modal" data-bs-target="#package1Modal">${loc}</span></td> |
||||
|
<td>${seats}</td> |
||||
|
<td>${locationsCompleted}</td> |
||||
|
<td>${seatsCompleted}</td> |
||||
|
<td>${newC}</td> |
||||
|
<td>${minor}</td> |
||||
|
<td>${major}</td> |
||||
|
</tr> |
||||
|
`; |
||||
|
tbody.append(rowHtml); |
||||
|
}); |
||||
|
}) |
||||
|
.catch(error => { |
||||
|
console.error('Error loading data:', error); |
||||
|
}); |
||||
|
|
||||
|
// Modal load |
||||
|
$(document).on('click', '.clickable-cell', function () { |
||||
|
const packName = $(this).data('pack'); |
||||
|
const modalTitle = $('#package1ModalLabel'); |
||||
|
const modalBody = $('#package1Modal .modal-body tbody'); |
||||
|
|
||||
|
modalTitle.text(` List of Locations in ${packName.toUpperCase()}`); |
||||
|
modalBody.html('<tr><td colspan="6">Loading...</td></tr>'); |
||||
|
|
||||
|
fetch(`/commissionerreview/toilet/api/getSFDPack1?pack=${packName}`) |
||||
|
.then(res => res.json()) |
||||
|
.then(data => { |
||||
|
modalBody.empty(); |
||||
|
if (Array.isArray(data) && data.length > 0) { |
||||
|
data.forEach((item, i) => { |
||||
|
const row = ` |
||||
|
<tr> |
||||
|
<td>${i + 1}</td> |
||||
|
<td>${item.zone || ''}</td> |
||||
|
<td style="text-align: left">${item.toilet_location || ''}</td> |
||||
|
<td>${item.total_seats || ''}</td> |
||||
|
<td>${item.toilet_status || item.category || ''}</td> |
||||
|
<td>${item.toilet_type || 'N/A'}</td> |
||||
|
</tr>`; |
||||
|
modalBody.append(row); |
||||
|
}); |
||||
|
} else { |
||||
|
modalBody.html('<tr><td colspan="6">No data found.</td></tr>'); |
||||
|
} |
||||
|
}) |
||||
|
.catch(() => { |
||||
|
modalBody.html('<tr><td colspan="6">Error loading data.</td></tr>'); |
||||
|
}); |
||||
|
}); |
||||
|
}); |
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,158 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Smart Traffic Project Status</title> |
||||
|
|
||||
|
<!-- Bootstrap CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<style> |
||||
|
th, td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
white-space: nowrap; |
||||
|
border: 1px solid #dee2e6 !important; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #81007f; |
||||
|
color: white; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .row:nth-child(1) { |
||||
|
margin-bottom: 0 !important; |
||||
|
} |
||||
|
|
||||
|
td.preformatted { |
||||
|
white-space: pre-wrap; |
||||
|
text-align: left; |
||||
|
} |
||||
|
|
||||
|
table.dataTable tbody td { |
||||
|
border: 1px solid #dee2e6; |
||||
|
} |
||||
|
|
||||
|
table.dataTable thead th { |
||||
|
border: 1px solid #dee2e6; |
||||
|
} |
||||
|
|
||||
|
table.dataTable th { |
||||
|
background-color: #003366; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="container mt-5"> |
||||
|
<h4 class="text-center mb-4">Intelligent Traffic System - Summary</h4> |
||||
|
<div class="table-responsive"> |
||||
|
<table id="trafficStatusTable" class="table table-bordered nowrap" style="width:100%"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th class="text-center text-white">System</th> |
||||
|
<th class="text-center text-white">Total Locations</th> |
||||
|
<th class="text-center text-white">Pilot Completed</th> |
||||
|
<th class="text-center text-white">Plan Till May’ 25</th> |
||||
|
<th class="text-center text-white">Current Status</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
<tr> |
||||
|
<td>Adaptive Traffic Signal System (ATCS)</td> |
||||
|
<td>165</td> |
||||
|
<td>5</td> |
||||
|
<td>97 Junctions</td> |
||||
|
<td class="preformatted">54 junction major works completed & 31 location installation work in progress |
||||
|
</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Traffic Incident Detection System (TIDS)</td> |
||||
|
<td>58</td> |
||||
|
<td>1</td> |
||||
|
<td>45 Locations</td> |
||||
|
<td class="preformatted">34 Locations major works completed & 9 Location work in progress</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Automatic Traffic Counter and Classifier (ATCC)</td> |
||||
|
<td>115</td> |
||||
|
<td>1</td> |
||||
|
<td>40 Locations</td> |
||||
|
<td class="preformatted">30 Location major works completed & 5 Locations work is in progress</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Red Light Violation Detection System (RLVD)</td> |
||||
|
<td>50</td> |
||||
|
<td>1</td> |
||||
|
<td>32 Junctions</td> |
||||
|
<td class="preformatted">29 Junction Work is in Progress</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Speed Limit Violation System (SLVD)</td> |
||||
|
<td>10</td> |
||||
|
<td>1</td> |
||||
|
<td>6 Locations</td> |
||||
|
<td class="preformatted">3 Location in progress</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Variable Message Sign (VMS)</td> |
||||
|
<td>13</td> |
||||
|
<td>-</td> |
||||
|
<td>6 Locations</td> |
||||
|
<td class="preformatted">3 Location in Progress</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>On Board Bus Unit (OBU)</td> |
||||
|
<td>2600</td> |
||||
|
<td>50</td> |
||||
|
<td>2600 Nos</td> |
||||
|
<td class="preformatted">OBU Installation completed in 2600 Buses</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Passenger Information System (PIS)</td> |
||||
|
<td>616</td> |
||||
|
<td>8</td> |
||||
|
<td>608 Nos</td> |
||||
|
<td class="preformatted">2-Line - 211 Locations Work in Progress |
||||
|
4-Line - 23 Locations work in Progress |
||||
|
10-Line - 3 Location work in Progress |
||||
|
</td> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<td>Depot Management System (DMS)</td> |
||||
|
<td>32</td> |
||||
|
<td>3</td> |
||||
|
<td>25 Nos</td> |
||||
|
<td class="preformatted">28 Depot Configuration completed</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
$('#trafficStatusTable').DataTable({ |
||||
|
scrollX: true, |
||||
|
paging: false, |
||||
|
ordering: true, |
||||
|
searching: true, |
||||
|
autoWidth: false |
||||
|
}); |
||||
|
}); |
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,300 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Audit Report Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap 5 CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
|
||||
|
.modal-body { |
||||
|
max-height: 70vh; |
||||
|
overflow-y: auto; |
||||
|
} |
||||
|
|
||||
|
.modal-body table { |
||||
|
width: 100%; |
||||
|
table-layout: auto; |
||||
|
} |
||||
|
|
||||
|
/* General Table Styling */ |
||||
|
table { |
||||
|
border: 1px solid #dee2e6 !important; |
||||
|
} |
||||
|
|
||||
|
/* Table Headers */ |
||||
|
table thead th { |
||||
|
background-color: #003366 !important; /* Dark Gray */ |
||||
|
color: #ffffff !important; /* White Text */ |
||||
|
text-align: center !important; |
||||
|
vertical-align: middle !important; |
||||
|
border: 1px solid #dee2e6 !important; |
||||
|
} |
||||
|
|
||||
|
/* Specific: center both levels of <thead> in DataTables */ |
||||
|
table thead tr:nth-child(1) th, |
||||
|
table thead tr:nth-child(2) th { |
||||
|
text-align: center !important; |
||||
|
vertical-align: middle !important; |
||||
|
} |
||||
|
|
||||
|
/* Table Body */ |
||||
|
table td { |
||||
|
background-color: #ffffff !important; |
||||
|
color: #212529 !important; |
||||
|
text-align: center !important; |
||||
|
vertical-align: middle !important; |
||||
|
border: 1px solid #dee2e6 !important; |
||||
|
} |
||||
|
|
||||
|
/* Optional: Zebra striping for visibility */ |
||||
|
table tbody tr:nth-child(even) { |
||||
|
background-color: #f8f9fa !important; |
||||
|
} |
||||
|
|
||||
|
/* Fix sort icon positioning */ |
||||
|
table.dataTable thead .sorting:before, |
||||
|
table.dataTable thead .sorting:after, |
||||
|
table.dataTable thead .sorting_asc:before, |
||||
|
table.dataTable thead .sorting_asc:after, |
||||
|
table.dataTable thead .sorting_desc:before, |
||||
|
table.dataTable thead .sorting_desc:after { |
||||
|
bottom: 0.6em !important; |
||||
|
} |
||||
|
|
||||
|
/* Padding for better spacing */ |
||||
|
table th, table td { |
||||
|
padding-left: 0.5rem !important; |
||||
|
padding-right: 0.5rem !important; |
||||
|
} |
||||
|
|
||||
|
/* DataTables Button Area */ |
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
/* Space between Search and Table */ |
||||
|
.dataTables_filter { |
||||
|
margin-bottom: 25px; |
||||
|
} |
||||
|
|
||||
|
/* Page Header */ |
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
/* Modal Table Specific Horizontal Scroll Fix */ |
||||
|
#zoneDetailsTable_wrapper .dataTables_scrollBody { |
||||
|
border: none !important; |
||||
|
} |
||||
|
|
||||
|
/* Prevent wrapping inside modal table */ |
||||
|
#zoneDetailsTable td, |
||||
|
#zoneDetailsTable th { |
||||
|
white-space: nowrap !important; |
||||
|
} |
||||
|
|
||||
|
.cursor-pointer:hover { |
||||
|
text-decoration: underline; |
||||
|
} |
||||
|
|
||||
|
.cursor-pointer { |
||||
|
cursor: pointer !important; |
||||
|
} |
||||
|
|
||||
|
</style> |
||||
|
|
||||
|
|
||||
|
|
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="page-header-title"> |
||||
|
<h4>UPHC-Zone-wise Report</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div id="opSummaryTable" style="display: block;" class="container"> |
||||
|
<table id="ZoneOpDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th rowspan="2">Zone</th> |
||||
|
<th rowspan="2">No. of UPHCs</th> |
||||
|
<th colspan="2">Jan, 2025</th> |
||||
|
<th colspan="2">Feb, 2025</th> |
||||
|
<th colspan="2">Mar, 2025</th> |
||||
|
<th colspan="2">Apr, 2025</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Total OP</th> |
||||
|
<th>Avg. OP/Day</th> |
||||
|
<th>Total OP</th> |
||||
|
<th>Avg. OP/Day</th> |
||||
|
<th>Total OP</th> |
||||
|
<th>Avg. OP/Day</th> |
||||
|
<th>Total OP</th> |
||||
|
<th>Avg. OP/Day</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
<!-- Add more rows as needed --> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Modal --> |
||||
|
<div class="modal fade" id="zoneDetailsModal" tabindex="-1" aria-labelledby="zoneDetailsLabel" aria-hidden="true"> |
||||
|
<div class="modal-dialog modal-xl"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="zoneDetailsLabel">Zone Details</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
<table id="zoneDetailsTable" class="display nowrap w-100"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th rowspan="2">S. No</th> |
||||
|
<th rowspan="2">PHC Name</th> |
||||
|
<th colspan="2">Jan, 2025</th> |
||||
|
<th colspan="2">Feb, 2025</th> |
||||
|
<th colspan="2">Mar, 2025</th> |
||||
|
<th colspan="2">Apr, 2025</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Total OP</th> |
||||
|
<th>Avg. OP/Day</th> |
||||
|
<th>Total OP</th> |
||||
|
<th>Avg. OP/Day</th> |
||||
|
<th>Total OP</th> |
||||
|
<th>Avg. OP/Day</th> |
||||
|
<th>Total OP</th> |
||||
|
<th>Avg. OP/Day</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="zoneDetailsBody"> |
||||
|
<!-- Filled via JS --> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables JS --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
const table = $('#ZoneOpDatatable').DataTable({ |
||||
|
dom: 'lftip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', '500 rows', 'Show all'] |
||||
|
], |
||||
|
scrollX: true, |
||||
|
scrollY: '50vh', |
||||
|
fixedHeader: true, |
||||
|
autoWidth: true, |
||||
|
responsive: true, |
||||
|
searching: true, |
||||
|
paging: true, |
||||
|
info: true, |
||||
|
ordering: false |
||||
|
}); |
||||
|
|
||||
|
// Fetch data from backend |
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/uphc/usercontroller/zone-wise-op-summary', |
||||
|
method: 'GET', |
||||
|
success: function (data) { |
||||
|
data.forEach(function (row) { |
||||
|
const zone = row.zone; |
||||
|
const noOfUphcs = row.no_of_uphcs; |
||||
|
|
||||
|
table.row.add([ |
||||
|
`<span class='text-primary fw-bold cursor-pointer' onclick="loadZoneDetails('${zone}')">${zone}</span>`, |
||||
|
`<span class='text-primary fw-bold cursor-pointer' onclick="loadZoneDetails('${zone}')">${noOfUphcs}</span>`, |
||||
|
row.jan_total_op, |
||||
|
row.jan_avg_op_day, |
||||
|
row.feb_total_op, |
||||
|
row.feb_avg_op_day, |
||||
|
row.mar_total_op, |
||||
|
row.mar_avg_op_day, |
||||
|
row.apr_total_op, |
||||
|
row.apr_avg_op_day |
||||
|
]).draw(false); |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load zone-wise report data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
}); |
||||
|
|
||||
|
function loadZoneDetails(zone) { |
||||
|
$('#zoneDetailsLabel').text(`Zone ${zone} - UPHC Details`); |
||||
|
$('#zoneDetailsBody').empty(); |
||||
|
|
||||
|
$.ajax({ |
||||
|
url: `/commissionerreview/uphc/usercontroller/uphc-details/${zone}`, |
||||
|
method: 'GET', |
||||
|
success: function (rows) { |
||||
|
rows.forEach((u, i) => { |
||||
|
$('#zoneDetailsBody').append(` |
||||
|
<tr> |
||||
|
<td>${i + 1}</td> |
||||
|
<td>${u.phc}</td> |
||||
|
<td>${u.jan_2025}</td> |
||||
|
<td>${(u.jan_2025 / 26).toFixed(2)}</td> |
||||
|
<td>${u.feb_2025}</td> |
||||
|
<td>${(u.feb_2025 / 24).toFixed(2)}</td> |
||||
|
<td>${u.mar_2025}</td> |
||||
|
<td>${(u.mar_2025 / 26).toFixed(2)}</td> |
||||
|
<td>${u.apr_2025}</td> |
||||
|
<td>${(u.apr_2025 / 25).toFixed(2)}</td> |
||||
|
</tr> |
||||
|
`); |
||||
|
}); |
||||
|
|
||||
|
new bootstrap.Modal(document.getElementById('zoneDetailsModal')).show(); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Could not load PHC data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,203 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Urban Green Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
.table-container { |
||||
|
overflow-x: auto; |
||||
|
} |
||||
|
|
||||
|
table.dataTable th, |
||||
|
table.dataTable td { |
||||
|
text-align: center !important; |
||||
|
vertical-align: middle !important; |
||||
|
white-space: nowrap; |
||||
|
border: 1px solid #000 !important; |
||||
|
|
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
|
||||
|
table.dataTable th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="container mt-4"> |
||||
|
<div class="page-header-title text-center"> |
||||
|
<h4>Urban Green Summary</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div class="table-container"> |
||||
|
<table id="UrbanGreenDatatable" class="table table-striped table-bordered nowrap w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th>Sl.No</th> |
||||
|
<th>Zone No</th> |
||||
|
<th>Phase No</th> |
||||
|
<th>No of saplings planted</th> |
||||
|
<th>No of survived</th> |
||||
|
|
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody></tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Modal with DataTable --> |
||||
|
<div class="modal fade" id="detailModal" tabindex="-1" aria-labelledby="detailModalLabel" aria-hidden="true" data-bs-backdrop="static" data-bs-keyboard="false"> |
||||
|
<div class="modal-dialog modal-xl modal-dialog-centered"> |
||||
|
<div class="modal-content"> |
||||
|
<div class="modal-header"> |
||||
|
<h5 class="modal-title" id="detailModalLabel">Details View</h5> |
||||
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> |
||||
|
</div> |
||||
|
<div class="modal-body"> |
||||
|
<table id="modalDataTable" class="table table-bordered table-striped w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th>Sl.No</th> |
||||
|
<th>Phase No</th> |
||||
|
<th>Location</th> |
||||
|
<th>No of saplings planted</th> |
||||
|
<th>No of survived</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="modalTableBody"> |
||||
|
<!-- JS will populate rows here --> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
|
||||
|
$(document).ready(function () { |
||||
|
var table = $('#UrbanGreenDatatable').DataTable({ |
||||
|
dom: 'lftip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', '500 rows', 'Show all'] |
||||
|
], |
||||
|
|
||||
|
fixedHeader: false, |
||||
|
autoWidth: false, |
||||
|
responsive: false, |
||||
|
searching: false, |
||||
|
paging: false, |
||||
|
info: false, |
||||
|
ordering: false |
||||
|
}); |
||||
|
|
||||
|
// Store all data globally for reuse |
||||
|
let allUrbanGreenData = []; |
||||
|
|
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/urbangreen/api/urbangreen-report', |
||||
|
method: 'GET', |
||||
|
success: function (data) { |
||||
|
allUrbanGreenData = data; // Save data globally |
||||
|
let serial = 1; |
||||
|
data.forEach(function (row) { |
||||
|
table.row.add([ |
||||
|
serial++, |
||||
|
`<span class="clickable-zone text-primary" style="cursor:pointer;" data-zone="${row.zone}">${row.zone}</span>`, |
||||
|
row.phase, |
||||
|
row.saplings_planted, |
||||
|
row.saplings_survived |
||||
|
]).draw(false); |
||||
|
}); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load zone-wise report data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
// Click event for zone |
||||
|
// Click event for zone - triggers modal data load via AJAX |
||||
|
$('#UrbanGreenDatatable tbody').on('click', '.clickable-zone', function () { |
||||
|
const zone = $(this).data('zone'); |
||||
|
|
||||
|
// Get the corresponding phase from the same row |
||||
|
const phase = $(this).closest('tr').find('td:eq(2)').text().trim(); |
||||
|
|
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/urbangreen/api/urbangreen-report-list', |
||||
|
method: 'GET', |
||||
|
data: { zone: zone, phase: phase }, |
||||
|
success: function (data) { |
||||
|
let modalBody = ''; |
||||
|
let count = 1; |
||||
|
|
||||
|
data.forEach(item => { |
||||
|
modalBody += ` |
||||
|
<tr> |
||||
|
<td>${count++}</td> |
||||
|
<td>${item.phase}</td> |
||||
|
<td>${item.location}</td> |
||||
|
<td>${item.saplings_planted}</td> |
||||
|
<td>${item.saplings_survived}</td> |
||||
|
</tr> |
||||
|
`; |
||||
|
}); |
||||
|
|
||||
|
$('#modalTableBody').html(modalBody); |
||||
|
$('#detailModal').modal('show'); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load detail data for Zone ' + zone, 'error'); |
||||
|
} |
||||
|
}); |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
}); |
||||
|
|
||||
|
|
||||
|
|
||||
|
document.querySelector(".btn-close").addEventListener("click", function () { |
||||
|
window.location.href = window.location.href; |
||||
|
}); |
||||
|
|
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,93 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Veterinary ABC Monthly Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<style> |
||||
|
th, td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #dee2e6; |
||||
|
white-space: nowrap; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="container mt-4"> |
||||
|
<h4 class="text-center mb-4"> ABC Centres - Sterilization Summary</h4> |
||||
|
<table class="table table-bordered display nowrap" id="abcSummaryTable"> |
||||
|
<thead class="text-center"> |
||||
|
<tr> |
||||
|
<th>Month</th> |
||||
|
<th>Pulianthope</th> |
||||
|
<th>Llyods Colony</th> |
||||
|
<th>Kannammapet</th> |
||||
|
<th>Meenambakkam</th> |
||||
|
<th>Sholinganallur</th> |
||||
|
<th>Total</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="abcSummaryBody"> |
||||
|
<!-- Dynamic content --> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
<!-- jQuery and DataTables Scripts --> |
||||
|
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
$.get("/commissionerreview/api/veterinarypetclinic/abcsummary", function (data) { |
||||
|
data.forEach((row, index) => { |
||||
|
const html = ` |
||||
|
<tr> |
||||
|
<td>${row.month}</td> |
||||
|
<td>${row['Pulianthope Sterilized']}</td> |
||||
|
<td>${row['Llyods Colony Sterilized']}</td> |
||||
|
<td>${row['Kannammapet Sterilized']}</td> |
||||
|
<td>${row['Meenambakkam Sterilized']}</td> |
||||
|
<td>${row['Sholinganallur Sterilized']}</td> |
||||
|
<td><strong>${row['Total Sterilized']}</strong></td> |
||||
|
</tr>`; |
||||
|
$('#abcSummaryBody').append(html); |
||||
|
}); |
||||
|
|
||||
|
$('#abcSummaryTable').DataTable({ |
||||
|
paging: true, |
||||
|
searching: true, |
||||
|
ordering: false, |
||||
|
responsive: true, |
||||
|
|
||||
|
}); |
||||
|
}); |
||||
|
}); |
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,196 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Veterinary Cattle Catch Report Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap 5 CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
table.dataTable th, table.dataTable td { |
||||
|
text-align: center; |
||||
|
vertical-align: middle; |
||||
|
border: 1px solid #000 !important; |
||||
|
} |
||||
|
|
||||
|
table.dataTable th{ |
||||
|
background-color: #003366; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
.dataTables_filter { |
||||
|
margin-bottom: 25px; /* adjust as needed */ |
||||
|
} |
||||
|
|
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
#zoneDetailsTable_wrapper .dataTables_scrollBody { |
||||
|
border: none !important; |
||||
|
} |
||||
|
|
||||
|
#zoneDetailsTable td, #zoneDetailsTable th { |
||||
|
vertical-align: middle; |
||||
|
text-align: center; |
||||
|
white-space: nowrap; |
||||
|
} |
||||
|
|
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="page-header-title"> |
||||
|
<h4>Cattle Catch - Zonewise Report</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div id="opSummaryTable" style="display: block;" class="container"> |
||||
|
<table id="ZoneOpDatatable" class="table table-striped table-bordered display nowrap w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th rowspan="2" class="text-center">Zone</th> |
||||
|
<th colspan="1" class="text-center">Nov, 2024</th> |
||||
|
<th colspan="1" class="text-center">Dec, 2024</th> |
||||
|
<th colspan="1" class="text-center">Jan, 2025</th> |
||||
|
<th colspan="1" class="text-center">Feb, 2025</th> |
||||
|
<th colspan="1" class="text-center">Mar, 2025</th> |
||||
|
<th colspan="1" class="text-center">Apr, 2025</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th class="text-center">Cattle Caught </th> |
||||
|
<th class="text-center">Cattle Caught </th> |
||||
|
<th class="text-center">Cattle Caught </th> |
||||
|
<th class="text-center">Cattle Caught </th> |
||||
|
<th class="text-center">Cattle Caught </th> |
||||
|
<th class="text-center">Cattle Caught </th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
|
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables JS --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
|
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/veterinarypetclinic/overallcattledata', |
||||
|
method: 'GET', |
||||
|
success: function(response) { |
||||
|
if (response.status === 'success') { |
||||
|
console.log("Details Array:", response.data); |
||||
|
// Ensure details is an array and has at least one entry |
||||
|
if (Array.isArray(response.data) && response.data.length > 0) { |
||||
|
|
||||
|
let scrollHeight = response.data.length <= 50 ? 'auto' : '80vh'; |
||||
|
|
||||
|
const tableData = response.data; |
||||
|
const totals = response.total; |
||||
|
|
||||
|
// Prepare "Total" row object |
||||
|
const totalRow = { |
||||
|
zone: 'Total', |
||||
|
Nov2024: 0, |
||||
|
Dec2024: 0, |
||||
|
Jan2025: 0, |
||||
|
Feb2025: 0, |
||||
|
Mar2025: 0, |
||||
|
Apr2025: 0, |
||||
|
zoneIndex: 0 // hide this anyway |
||||
|
}; |
||||
|
|
||||
|
// Populate values from totals array |
||||
|
totals.forEach(month => { |
||||
|
if (month.month === 'Nov-24') totalRow.Nov2024 = month.total_zone_sum; |
||||
|
if (month.month === 'Dec-24') totalRow.Dec2024 = month.total_zone_sum; |
||||
|
if (month.month === 'Jan-25') totalRow.Jan2025 = month.total_zone_sum; |
||||
|
if (month.month === 'Feb-25') totalRow.Feb2025 = month.total_zone_sum; |
||||
|
if (month.month === 'Mar-25') totalRow.Mar2025 = month.total_zone_sum; |
||||
|
if (month.month === 'Apr-25') totalRow.Apr2025 = month.total_zone_sum; |
||||
|
}); |
||||
|
|
||||
|
// Add Total row to the data |
||||
|
tableData.push(totalRow); |
||||
|
|
||||
|
let table = $('#ZoneOpDatatable').DataTable({ |
||||
|
destroy: true, |
||||
|
autoWidth: true, |
||||
|
info: true, |
||||
|
data: tableData, |
||||
|
columns: [ |
||||
|
{ data: 'zone' }, |
||||
|
{ data: 'Nov2024' }, |
||||
|
{ data: 'Dec2024' }, |
||||
|
{ data: 'Jan2025' }, |
||||
|
{ data: 'Feb2025' }, |
||||
|
{ data: 'Mar2025' }, |
||||
|
{ data: 'Apr2025' }, |
||||
|
{ data: 'zoneIndex', visible: false } |
||||
|
|
||||
|
], |
||||
|
|
||||
|
dom: 'frtip', |
||||
|
lengthMenu: [ |
||||
|
[50, 100, 200, 500, -1], |
||||
|
['50 rows', '100 rows', '200 rows', 'Show all'] |
||||
|
], |
||||
|
scrollY: scrollHeight, |
||||
|
scrollX: true, |
||||
|
responsive: false, |
||||
|
searching: false, |
||||
|
ordering:false, |
||||
|
createdRow: function(row, data, dataIndex) { |
||||
|
if (data.zone === 'Total') { |
||||
|
$(row).css({ |
||||
|
'font-weight': 'bold' |
||||
|
|
||||
|
}); |
||||
|
} |
||||
|
} |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
} else if (response.status === 'nodata') { |
||||
|
alert("No data available."); |
||||
|
} else { |
||||
|
alert("Error: " + response.message); |
||||
|
} |
||||
|
}, |
||||
|
error: function(xhr, status, error) { |
||||
|
alert("Request failed: " + error); |
||||
|
} |
||||
|
}); |
||||
|
|
||||
|
}); |
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,132 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en" xmlns:th="http://www.thymeleaf.org"> |
||||
|
<head> |
||||
|
<title>Meat Raid Summary</title> |
||||
|
|
||||
|
<!-- Bootstrap CSS --> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<!-- DataTables CSS --> |
||||
|
<link href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" rel="stylesheet"/> |
||||
|
<link href="https://cdn.datatables.net/buttons/2.3.6/css/buttons.dataTables.min.css" rel="stylesheet"/> |
||||
|
|
||||
|
<style> |
||||
|
.page-header-title h4 { |
||||
|
margin: 20px 0; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
.table-container { |
||||
|
overflow-x: auto; |
||||
|
} |
||||
|
|
||||
|
table.dataTable th, |
||||
|
table.dataTable td { |
||||
|
text-align: center !important; |
||||
|
vertical-align: middle !important; |
||||
|
white-space: nowrap; |
||||
|
border: 1px solid #000 !important; |
||||
|
|
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .dt-buttons { |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
table.dataTable th { |
||||
|
background-color: #003366; |
||||
|
color: white; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="container mt-4"> |
||||
|
<div class="page-header-title text-center"> |
||||
|
<h4>Meat Raid Summary</h4> |
||||
|
</div> |
||||
|
|
||||
|
<div class="table-container"> |
||||
|
<table id="MeatraidDatatable" class="table table-striped table-bordered nowrap w-100"> |
||||
|
<thead class="table-dark"> |
||||
|
<tr> |
||||
|
<th rowspan="2">Sl.No</th> |
||||
|
<th rowspan="2">Zone</th> |
||||
|
<th colspan="2">Jan 2025</th> |
||||
|
<th colspan="2">Feb 2025</th> |
||||
|
<th colspan="2">Mar 2025</th> |
||||
|
<th colspan="2">Apr 2025</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Inspected</th> |
||||
|
<th>Seized (KG)</th> |
||||
|
<th>Inspected</th> |
||||
|
<th>Seized (KG)</th> |
||||
|
<th>Inspected</th> |
||||
|
<th>Seized (KG)</th> |
||||
|
<th>Inspected</th> |
||||
|
<th>Seized (KG)</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody></tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script> |
||||
|
|
||||
|
<!-- DataTables --> |
||||
|
<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/dataTables.buttons.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.html5.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/buttons/2.3.6/js/buttons.print.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/pdfmake.min.js"></script> |
||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.36/vfs_fonts.js"></script> |
||||
|
|
||||
|
<!-- SweetAlert --> |
||||
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
const table = $('#MeatraidDatatable').DataTable({ |
||||
|
dom: 'lftip', |
||||
|
|
||||
|
responsive: true, |
||||
|
searching: false, |
||||
|
paging: false, |
||||
|
info: false, |
||||
|
ordering: false, |
||||
|
scrollX: true |
||||
|
}); |
||||
|
|
||||
|
$.ajax({ |
||||
|
url: '/commissionerreview/api/veterinarypetclinic/meatraid-report', |
||||
|
method: 'GET', |
||||
|
success: function (data) { |
||||
|
let serial = 1; |
||||
|
data.forEach(function (row) { |
||||
|
table.row.add([ |
||||
|
serial++, |
||||
|
row.zone, |
||||
|
row.jan_visited || 0, |
||||
|
row.jan_seized || 0, |
||||
|
row.feb_visited || 0, |
||||
|
row.feb_seized || 0, |
||||
|
row.mar_visited || 0, |
||||
|
row.mar_seized || 0, |
||||
|
row.apr_visited || 0, |
||||
|
row.apr_seized || 0 |
||||
|
]).draw(false); |
||||
|
}); |
||||
|
}, |
||||
|
error: function () { |
||||
|
Swal.fire('Error', 'Failed to load zone-wise report data.', 'error'); |
||||
|
} |
||||
|
}); |
||||
|
}); |
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,126 @@ |
|||||
|
<!DOCTYPE html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8"> |
||||
|
<title>Pet Clinic Summary</title> |
||||
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> |
||||
|
<link href="https://cdn.datatables.net/1.13.6/css/dataTables.bootstrap5.min.css" rel="stylesheet"> |
||||
|
|
||||
|
<style> |
||||
|
th, td { |
||||
|
text-align: center !important; |
||||
|
vertical-align: middle !important; |
||||
|
border: 1px solid #dee2e6 !important; |
||||
|
} |
||||
|
|
||||
|
table { |
||||
|
width: 100% !important; |
||||
|
border-collapse: collapse !important; |
||||
|
} |
||||
|
|
||||
|
thead th { |
||||
|
background-color: #003366 !important; |
||||
|
color: white !important; |
||||
|
} |
||||
|
|
||||
|
/* Remove extra spacing above search/filter box */ |
||||
|
div.dataTables_filter { |
||||
|
margin-bottom: 0 !important; |
||||
|
} |
||||
|
|
||||
|
.dataTables_wrapper .row:nth-child(1) { |
||||
|
margin-bottom: 0 !important; |
||||
|
} |
||||
|
</style> |
||||
|
</head> |
||||
|
<body> |
||||
|
|
||||
|
<div class="container mt-4"> |
||||
|
<h4 class="text-center mb-4">Pet Clinics Summary</h4> |
||||
|
|
||||
|
<div class="table-responsive"> |
||||
|
<table class="table table-bordered" id="summaryTable"> |
||||
|
<thead class="text-center"> |
||||
|
<tr> |
||||
|
<th rowspan="2">Centre</th> |
||||
|
<th colspan="2">Nov 2024</th> |
||||
|
<th colspan="2">Dec 2024</th> |
||||
|
<th colspan="2">Jan 2025</th> |
||||
|
<th colspan="2">Feb 2025</th> |
||||
|
<th colspan="2">Mar 2025</th> |
||||
|
<th colspan="2">Apr 2025</th> |
||||
|
</tr> |
||||
|
<tr> |
||||
|
<th>Treated</th><th>ARV</th> |
||||
|
<th>Treated</th><th>ARV</th> |
||||
|
<th>Treated</th><th>ARV</th> |
||||
|
<th>Treated</th><th>ARV</th> |
||||
|
<th>Treated</th><th>ARV</th> |
||||
|
<th>Treated</th><th>ARV</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody id="summaryBody" class="text-center"> |
||||
|
<!-- Dynamic Rows --> |
||||
|
</tbody> |
||||
|
<tfoot class="text-center"> |
||||
|
<!-- Will contain Total Row --> |
||||
|
</tfoot> |
||||
|
</table> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- Scripts --> |
||||
|
<script src="https://code.jquery.com/jquery-3.6.4.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/1.13.6/js/jquery.dataTables.min.js"></script> |
||||
|
<script src="https://cdn.datatables.net/1.13.6/js/dataTables.bootstrap5.min.js"></script> |
||||
|
|
||||
|
<script> |
||||
|
$(document).ready(function () { |
||||
|
const months = [ |
||||
|
['Nov-24 Treated', 'Nov-24 ARV'], |
||||
|
['Dec-24 Treated', 'Dec-24 ARV'], |
||||
|
['Jan-25 Treated', 'Jan-25 ARV'], |
||||
|
['Feb-25 Treated', 'Feb-25 ARV'], |
||||
|
['Mar-25 Treated', 'Mar-25 ARV'], |
||||
|
['Apr-25 Treated', 'Apr-25 ARV'] |
||||
|
]; |
||||
|
|
||||
|
let totals = new Array(months.length).fill(null).map(() => ({ treated: 0, arv: 0 })); |
||||
|
|
||||
|
$.get("/commissionerreview/api/veterinarypetclinic/monthly-summary", function (data) { |
||||
|
data.forEach(row => { |
||||
|
let html = `<tr><td>${row.center_name}</td>`; |
||||
|
months.forEach((keys, i) => { |
||||
|
const treated = row[keys[0]] || 0; |
||||
|
const arv = row[keys[1]] || 0; |
||||
|
html += `<td>${treated}</td><td>${arv}</td>`; |
||||
|
totals[i].treated += treated; |
||||
|
totals[i].arv += arv; |
||||
|
}); |
||||
|
html += `</tr>`; |
||||
|
$('#summaryBody').append(html); |
||||
|
}); |
||||
|
|
||||
|
// Footer totals |
||||
|
let totalRow = `<tr><th>Total</th>`; |
||||
|
totals.forEach(t => { |
||||
|
totalRow += `<th>${t.treated}</th><th>${t.arv}</th>`; |
||||
|
}); |
||||
|
totalRow += `</tr>`; |
||||
|
$('#summaryTable tfoot').append(totalRow); |
||||
|
|
||||
|
// Initialize DataTable |
||||
|
$('#summaryTable').DataTable({ |
||||
|
paging: false, |
||||
|
searching: true, |
||||
|
ordering: true, |
||||
|
info: false, |
||||
|
scrollX: true, |
||||
|
autoWidth: false |
||||
|
}); |
||||
|
}); |
||||
|
}); |
||||
|
</script> |
||||
|
|
||||
|
</body> |
||||
|
</html> |
||||
@ -0,0 +1,13 @@ |
|||||
|
package com.gcc.commissionerreview; |
||||
|
|
||||
|
import org.junit.jupiter.api.Test; |
||||
|
import org.springframework.boot.test.context.SpringBootTest; |
||||
|
|
||||
|
@SpringBootTest |
||||
|
class DashboardserviceApplicationTests { |
||||
|
|
||||
|
@Test |
||||
|
void contextLoads() { |
||||
|
} |
||||
|
|
||||
|
} |
||||
Write
Preview
Loading…
Cancel
Save
Reference in new issue