| @ -0,0 +1,339 @@ | |||
| package jumapacelaya.gob.mx.appots.controlador; | |||
| import jumapacelaya.gob.mx.appots.dto.dictamenDTO; | |||
| import jumapacelaya.gob.mx.appots.dto.empleadoOrigenDTO; | |||
| import jumapacelaya.gob.mx.appots.dto.fotoOTDTO; | |||
| import jumapacelaya.gob.mx.appots.dto.motivoPreguntaDTO; | |||
| import jumapacelaya.gob.mx.appots.dto.noCommMensajeDTO; | |||
| import jumapacelaya.gob.mx.appots.dto.origenDTO; | |||
| import jumapacelaya.gob.mx.appots.dto.otDTO; | |||
| import jumapacelaya.gob.mx.appots.dto.preguntaDTO; | |||
| import jumapacelaya.gob.mx.appots.dto.respuestaOTDTO; | |||
| import jumapacelaya.gob.mx.appots.dto.transaccionDTO; | |||
| import jumapacelaya.gob.mx.appots.servicio.AppOtsServicio; | |||
| import java.net.URI; | |||
| import java.util.Collections; | |||
| import java.util.List; | |||
| import java.util.Map; | |||
| import java.util.Optional; | |||
| import io.micronaut.http.HttpResponse; | |||
| import io.micronaut.http.HttpStatus; | |||
| import io.micronaut.http.MediaType; | |||
| import io.micronaut.http.annotation.Body; | |||
| import io.micronaut.http.annotation.Controller; | |||
| import io.micronaut.http.annotation.Get; | |||
| import io.micronaut.http.annotation.PathVariable; | |||
| import io.micronaut.http.annotation.Put; | |||
| import io.micronaut.http.exceptions.HttpStatusException; | |||
| import jakarta.inject.Inject; | |||
| import jumapacelaya.gob.mx.predios.dto.PredioDTO; | |||
| import jumapacelaya.gob.mx.predios.servicio.PredioServicio; | |||
| @Controller("/appots") | |||
| public class AppOtsControlador { | |||
| private final AppOtsServicio servicio; | |||
| private final PredioServicio pServicio; | |||
| @Inject | |||
| public AppOtsControlador(AppOtsServicio servicio, PredioServicio pServicio) { | |||
| this.servicio = servicio; | |||
| this.pServicio = pServicio; | |||
| } | |||
| @Get("/infopredioappots/{vPredContrRefer}") | |||
| public HttpResponse<PredioDTO> obtenerPredioAppOts(@PathVariable String vPredContrRefer) { | |||
| PredioDTO dto = pServicio.obtenerPredioAppOts(vPredContrRefer); | |||
| if (dto == null) { | |||
| return HttpResponse.notFound(); | |||
| } | |||
| return HttpResponse.ok(dto); | |||
| } | |||
| @Get("/infopredio/{predioid}") | |||
| public HttpResponse<?> redirigirAConsultaPredio(@PathVariable Long predioid) { | |||
| String redirPath = "/predios/appots/{id}" + predioid; | |||
| return HttpResponse.redirect(URI.create(redirPath)); | |||
| } | |||
| @Get("/ots/predio/{predioid}") | |||
| public HttpResponse<List<otDTO>> obtenerOTsPorPredio(@PathVariable Long predioid) { | |||
| List<otDTO> lista = servicio.obtenerOTsPorPredio(predioid); | |||
| return HttpResponse.ok(lista); | |||
| } | |||
| //Consulta OTs Pendientes ↓ | |||
| @Get("/todo/ot/{otid}") | |||
| public otDTO obtenerOT(@PathVariable Long otid) { | |||
| List<otDTO> lista = servicio.obtenerInfoGralOT(otid); | |||
| if (lista != null && !lista.isEmpty()) { | |||
| return lista.get(0); // ✅ Solo devolvemos el primer resultado | |||
| } else { | |||
| throw new HttpStatusException(HttpStatus.NOT_FOUND, "No se encontró la OT con ID " + otid); | |||
| } | |||
| } | |||
| //Consulta OTs ↓ | |||
| @Get("/todo/prog/cuadrilla/{cuadrillaId}/{motivoId}") | |||
| public HttpResponse<List<otDTO>> obtenerOtsPorCuadrillaYMotivo(@PathVariable String cuadrillaId, | |||
| @PathVariable String motivoId) { | |||
| List<otDTO> resultado = servicio.obtenerOtsProgramadasPorCuadrillaYMotivo(cuadrillaId, motivoId); | |||
| if (resultado.isEmpty()) { | |||
| throw new HttpStatusException(HttpStatus.NOT_FOUND, "No se encontraron OTs para los filtros dados."); | |||
| } | |||
| return HttpResponse.ok(resultado); | |||
| } | |||
| @Get("/todo/prog/motivo/{origenid}/{motivoid}") | |||
| public HttpResponse<?> obtenerOtsPorOrigenYMotivo(@PathVariable String origenid, | |||
| @PathVariable String motivoid) { | |||
| try { | |||
| List<otDTO> resultado = servicio.obtenerOtsProgramadasPorOrigenYMotivo(origenid, motivoid); | |||
| if (resultado.isEmpty()) { | |||
| return HttpResponse.notFound( | |||
| Collections.singletonMap("message", "No se encontraron OTs programadas para los parámetros dados") | |||
| ); | |||
| } | |||
| return HttpResponse.ok(resultado); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError( | |||
| Collections.singletonMap("message", "Error al obtener OTs programadas: " + e.getMessage()) | |||
| ); | |||
| } | |||
| } | |||
| @Get("/todo/prog/areaorigenmotivo/{areaid}/{origenid}/{motivoid}") | |||
| public HttpResponse<?> obtenerOtsProgramadasPorAreaOrigenMotivo(@PathVariable String areaid, | |||
| @PathVariable String origenid, | |||
| @PathVariable String motivoid) { | |||
| try { | |||
| List<otDTO> resultado = servicio.obtenerOtsProgramadasPorAreaOrigenMotivo(areaid, origenid, motivoid); | |||
| if (resultado.isEmpty()) { | |||
| return HttpResponse.notFound(Collections.singletonMap("message", "No se encontraron OTs programadas con los parámetros proporcionados")); | |||
| } | |||
| return HttpResponse.ok(resultado); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError( | |||
| Collections.singletonMap("message", "Error al obtener OTs programadas por área, origen y motivo: " + e.getMessage()) | |||
| ); | |||
| } | |||
| } | |||
| //Consulta OTs ↑ | |||
| //Consulta OTs Pendientes ↑ | |||
| //Consulta Catalogos ↓ | |||
| @Get("/catalogos/origenes/{origenid}") | |||
| public HttpResponse<?> obtenerOrigenes(@PathVariable String origenid) { | |||
| List<origenDTO> origenes = servicio.obtenerOrigenes(origenid); | |||
| return HttpResponse.ok(origenes); | |||
| } | |||
| @Get("/catalogos/motivos/{motivoid}") | |||
| public HttpResponse<?> obtenerMotivos(@PathVariable String motivoid) { | |||
| try { | |||
| List<Map<String, Object>> resultado = servicio.obtenerMotivos(motivoid); | |||
| return HttpResponse.ok(resultado); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError( | |||
| Collections.singletonMap("message", "Error interno: " + e.getMessage()) | |||
| ); | |||
| } | |||
| } | |||
| @Get("/catalogos/motivosarea/{areaid}/{motivoid}") | |||
| public HttpResponse<?> obtenerMotivosPorAreaYMotivo(@PathVariable String areaid, | |||
| @PathVariable String motivoid) { | |||
| try { | |||
| List<Map<String, Object>> resultado = servicio.obtenerMotivosPorAreaYMotivo(areaid, motivoid); | |||
| return HttpResponse.ok(resultado); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError(Collections.singletonMap("error", e.getMessage())); | |||
| } | |||
| } | |||
| @Get("/catalogos/motivossuspen/{motsusid}") | |||
| public HttpResponse<?> obtenerMotivoSusp(@PathVariable String motsusid) { | |||
| try { | |||
| Integer id = "all".equalsIgnoreCase(motsusid) ? null : Integer.valueOf(motsusid); | |||
| List<Map<String, Object>> resultado = servicio.obtenerMotivoSusp(id); | |||
| return HttpResponse.ok(resultado); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError( | |||
| Collections.singletonMap("error", "Error al consultar motivos de suspensión: " + e.getMessage()) | |||
| ); | |||
| } | |||
| } | |||
| @Get("/catalogos/preguntas/{preguntaid}/{dato}") | |||
| public HttpResponse<?> obtenerPreguntas(@PathVariable String preguntaid, | |||
| @PathVariable Optional<String> dato) { | |||
| try { | |||
| List<preguntaDTO> resultado = servicio.obtenerPreguntas(preguntaid, dato.orElse("")); | |||
| return HttpResponse.ok(resultado); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError(Collections.singletonMap("error", e.getMessage())); | |||
| } | |||
| } | |||
| @Get("/catalogos/unimed/{umid}") | |||
| public HttpResponse<?> obtenerUnidadMedida(@PathVariable String umid) { | |||
| try { | |||
| List<Map<String, Object>> resultado = servicio.obtenerUnidadesMedida(umid); | |||
| return HttpResponse.ok(resultado); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError( | |||
| Map.of("message", "Internal Server Error", | |||
| "_embedded", Map.of("errors", List.of(Map.of("message", "Error al obtener unidad de medida: " + e.getMessage()))) | |||
| ) | |||
| ); | |||
| } | |||
| } | |||
| @Get("/catalogos/motpreg/{motivoid}/{preguntaid}") | |||
| public HttpResponse<?> obtenerMotivoPreguntas(@PathVariable String motivoid, | |||
| @PathVariable String preguntaid) { | |||
| try { | |||
| List<motivoPreguntaDTO> resultado = servicio.obtenerMotivoPreguntas(motivoid, preguntaid); | |||
| return HttpResponse.ok(resultado.isEmpty() | |||
| ? Collections.singletonMap("message", "No se encontraron resultados") | |||
| : resultado); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError(Collections.singletonMap("message", | |||
| "Error al consultar motivo-pregunta: " + e.getMessage())); | |||
| } | |||
| } | |||
| @Get("/catalogos/dictamenes/{motivoid}/{dictamenid}") | |||
| public HttpResponse<?> obtenerDictamenes(@PathVariable String motivoid, @PathVariable String dictamenid) { | |||
| try { | |||
| List<dictamenDTO> data = servicio.obtenerDictamenesPorMotivoYDictamen(motivoid, dictamenid); | |||
| return HttpResponse.ok(Collections.singletonMap("data", data)); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError(Collections.singletonMap("message", "Error interno: " + e.getMessage())); | |||
| } | |||
| } | |||
| @Get("/catalogos/cortesfisicos/{motivoid}") | |||
| public HttpResponse<List<Map<String, Object>>> obtenerCortesFisicos(@PathVariable String motivoid) { | |||
| List<Map<String, Object>> data = servicio.obtenerCortesFisicos(motivoid); | |||
| return HttpResponse.ok(data); | |||
| } | |||
| @Get(uri = "/catalogos/empleadosorigen/{origenid}{/usuarioid}", produces = MediaType.APPLICATION_JSON) | |||
| public List<empleadoOrigenDTO> obtenerEmpleadosPorOrigenYUsuario(@PathVariable String origenid, | |||
| @PathVariable(name = "usuarioid") String usuarioid) { | |||
| return servicio.obtenerEmpleadosPorOrigenYUsuario(origenid, usuarioid); | |||
| } | |||
| //Consulta Catalogos ↑ | |||
| //Status OTs ↓ | |||
| @Get("/status/enruta/{otid}") | |||
| public HttpResponse<?> marcarEnRuta(@PathVariable Long otid) { | |||
| return manejarActualizacion(otid, "R"); | |||
| } | |||
| @Get("/status/ensitio/{otid}") | |||
| public HttpResponse<?> marcarEnSitio(@PathVariable Long otid) { | |||
| return manejarActualizacion(otid, "S"); | |||
| } | |||
| @Get("/status/comenzada/{otid}") | |||
| public HttpResponse<?> marcarComenzada(@PathVariable Long otid) { | |||
| return manejarActualizacion(otid, "C"); | |||
| } | |||
| @Get("/status/terminada/{otid}") | |||
| public HttpResponse<?> marcarTerminada(@PathVariable Long otid) { | |||
| return manejarActualizacion(otid, "T"); | |||
| } | |||
| @Get("/status/reprogramada/{otid}") | |||
| public HttpResponse<?> marcarReprogramada(@PathVariable Long otid) { | |||
| return manejarActualizacion(otid, "D"); | |||
| } | |||
| private HttpResponse<?> manejarActualizacion(Long otid, String situacion) { | |||
| try { | |||
| Map<String, Object> result = servicio.actualizarSituacionOT(otid, situacion); | |||
| if ("200".equals(result.get("status"))) { | |||
| return HttpResponse.ok(result); | |||
| } else { | |||
| return HttpResponse.serverError(result); | |||
| } | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError(Map.of( | |||
| "status", "500", | |||
| "message", "Error: " + e.getMessage(), | |||
| "data", Map.of("OTID", otid) | |||
| )); | |||
| } | |||
| } | |||
| //Status OTs ↑ | |||
| @Put("/nocomm/ot/{otid}") | |||
| public HttpResponse<?> registrarNoComm(@PathVariable Long otid, @Body List<noCommMensajeDTO> mensajes) { | |||
| Map<String, Object> result = servicio.registrarAvisoNoComm(otid, mensajes); | |||
| if ("200".equals(result.get("status"))) { | |||
| return HttpResponse.ok(result); | |||
| } else if ("404".equals(result.get("status"))) { | |||
| return HttpResponse.notFound(result); | |||
| } else { | |||
| return HttpResponse.serverError(result); | |||
| } | |||
| } | |||
| //Guardar información ↓ | |||
| @Put("/guardaresp/ot/{otid}") | |||
| public HttpResponse<?> guardarRespuestas(@PathVariable Long otid, @Body List<respuestaOTDTO> otList) { | |||
| try { | |||
| servicio.guardarRespuestas(otList); | |||
| return HttpResponse.ok(new RespuestaOKDTO( | |||
| 200, | |||
| "Respuestas guardadas exitosamente.", | |||
| otid | |||
| )); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError(new RespuestaErrorDTO( | |||
| 500, | |||
| "Error al guardar respuestas: " + e.getMessage(), | |||
| otid | |||
| )); | |||
| } | |||
| } | |||
| public record RespuestaOKDTO(int status, String message, Long otid) {} | |||
| public record RespuestaErrorDTO(int status, String message, Long otid) {} | |||
| @Put("/guardaresp/fotos/{otid}") | |||
| public HttpResponse<?> guardarFotos(@PathVariable Integer otid, | |||
| @Body List<fotoOTDTO> fotosOT) { | |||
| try { | |||
| servicio.guardarFotosOT(otid, fotosOT); | |||
| return HttpResponse.ok(Map.of( | |||
| "status", "200", | |||
| "message", "Fotos guardadas exitosamente", | |||
| "data", Map.of("OTID", otid) | |||
| )); | |||
| } catch (Exception e) { | |||
| return HttpResponse.serverError(Map.of( | |||
| "status", "500", | |||
| "message", "Error al guardar las fotos", | |||
| "error", e.getMessage() | |||
| )); | |||
| } | |||
| } | |||
| @Get("/guardaresp/comprueba/{transaccid}") | |||
| public List<transaccionDTO> obtenerPorTransaccionId(@PathVariable String transaccid) { | |||
| return servicio.obtenerPorTransaccionId(transaccid); | |||
| } | |||
| //Guardar información ↑ | |||
| } | |||
| @ -0,0 +1,9 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| public class FotoBase64DTO { | |||
| private String base64; | |||
| public String getBase64() { return base64; } | |||
| public void setBase64(String base64) { this.base64 = base64; } | |||
| } | |||
| @ -0,0 +1,23 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| public class OTHijaDTO { | |||
| private String motivoid; | |||
| private String descripcion; | |||
| private String motsusid; | |||
| // Getters y Setters | |||
| public String getMotivoId() { return motivoid; } | |||
| public void setMotivoId(String motivoid) { | |||
| this.motivoid = motivoid; | |||
| } | |||
| public String getDescripcion() { return descripcion; } | |||
| public void setDescripcion(String descripcion) { | |||
| this.descripcion = descripcion; | |||
| } | |||
| public String getMotSusId() { return motsusid; } | |||
| public void setMotSusId(String motsusid) { | |||
| this.motsusid = motsusid; | |||
| } | |||
| } | |||
| @ -0,0 +1,46 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| import io.micronaut.core.annotation.Introspected; | |||
| @Introspected | |||
| public class dictamenDTO { | |||
| private String dictamenid; | |||
| private String descripcion; | |||
| private String activo; | |||
| private String norealizacion; | |||
| private String motivoid; | |||
| private String activoMotivo; | |||
| // Getters y setters | |||
| public String getDictamenid() { return dictamenid; } | |||
| public void setDictamenid(String dictamenid) { | |||
| this.dictamenid = dictamenid; | |||
| } | |||
| public String getDescripcion() { return descripcion; } | |||
| public void setDescripcion(String descripcion) { | |||
| this.descripcion = descripcion; | |||
| } | |||
| public String getActivo() { return activo; } | |||
| public void setActivo(String activo) { | |||
| this.activo = activo; | |||
| } | |||
| public String getNorealizacion() { return norealizacion; } | |||
| public void setNorealizacion(String norealizacion) { | |||
| this.norealizacion = norealizacion; | |||
| } | |||
| public String getMotivoid() { return motivoid; } | |||
| public void setMotivoid(String motivoid) { | |||
| this.motivoid = motivoid; | |||
| } | |||
| public String getActivoMotivo() { return activoMotivo; } | |||
| public void setActivoMotivo(String activoMotivo) { | |||
| this.activoMotivo = activoMotivo; | |||
| } | |||
| } | |||
| @ -0,0 +1,102 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| import io.micronaut.core.annotation.Introspected; | |||
| @Introspected | |||
| public class empleadoOrigenDTO { | |||
| private String empleadoid; | |||
| private String usuarioid; | |||
| private String nombrecompleto; | |||
| private String titulo; | |||
| private String fechaalt; | |||
| private String fechabaj; | |||
| private String lector; | |||
| private String inspector; | |||
| private String cambio; | |||
| private String corte; | |||
| private String reconexion; | |||
| private String cobro; | |||
| private String ordtrab; | |||
| private String fotos; | |||
| private String serv_catastro; | |||
| private String sobrante; | |||
| private String dictamenot; | |||
| private String prorrogas; | |||
| private String anularconv; | |||
| private String ordenarpreg; | |||
| private String jefeid; | |||
| private String uniorgid; | |||
| private String uniorg; | |||
| // Getters y setters | |||
| public String getEmpleadoid() { return empleadoid; } | |||
| public void setEmpleadoid(String empleadoid) { this.empleadoid = empleadoid; } | |||
| public String getUsuarioid() { return usuarioid; } | |||
| public void setUsuarioid(String usuarioid) { this.usuarioid = usuarioid; } | |||
| public String getNombrecompleto() { return nombrecompleto; } | |||
| public void setNombrecompleto(String nombrecompleto) { this.nombrecompleto = nombrecompleto; } | |||
| public String getTitulo() { return titulo; } | |||
| public void setTitulo(String titulo) { this.titulo = titulo; } | |||
| public String getFechaalt() { return fechaalt; } | |||
| public void setFechaalt(String fechaalt) { this.fechaalt = fechaalt; } | |||
| public String getFechabaj() { return fechabaj; } | |||
| public void setFechabaj(String fechabaj) { this.fechabaj = fechabaj; } | |||
| public String getLector() { return lector; } | |||
| public void setLector(String lector) { this.lector = lector; } | |||
| public String getInspector() { return inspector; } | |||
| public void setInspector(String inspector) { this.inspector = inspector; } | |||
| public String getCambio() { return cambio; } | |||
| public void setCambio(String cambio) { this.cambio = cambio; } | |||
| public String getCorte() { return corte; } | |||
| public void setCorte(String corte) { this.corte = corte; } | |||
| public String getReconexion() { return reconexion; } | |||
| public void setReconexion(String reconexion) { this.reconexion = reconexion; } | |||
| public String getCobro() { return cobro; } | |||
| public void setCobro(String cobro) { this.cobro = cobro; } | |||
| public String getOrdtrab() { return ordtrab; } | |||
| public void setOrdtrab(String ordtrab) { this.ordtrab = ordtrab; } | |||
| public String getFotos() { return fotos; } | |||
| public void setFotos(String fotos) { this.fotos = fotos; } | |||
| public String getServ_catastro() { return serv_catastro; } | |||
| public void setServ_catastro(String serv_catastro) { this.serv_catastro = serv_catastro; } | |||
| public String getSobrante() { return sobrante; } | |||
| public void setSobrante(String sobrante) { this.sobrante = sobrante; } | |||
| public String getDictamenot() { return dictamenot; } | |||
| public void setDictamenot(String dictamenot) { this.dictamenot = dictamenot; } | |||
| public String getProrrogas() { return prorrogas; } | |||
| public void setProrrogas(String prorrogas) { this.prorrogas = prorrogas; } | |||
| public String getAnularconv() { return anularconv; } | |||
| public void setAnularconv(String anularconv) { this.anularconv = anularconv; } | |||
| public String getOrdenarpreg() { return ordenarpreg; } | |||
| public void setOrdenarpreg(String ordenarpreg) { this.ordenarpreg = ordenarpreg; } | |||
| public String getJefeid() { return jefeid; } | |||
| public void setJefeid(String jefeid) { this.jefeid = jefeid; } | |||
| public String getUniorgid() { return uniorgid; } | |||
| public void setUniorgid(String uniorgid) { this.uniorgid = uniorgid; } | |||
| public String getUniorg() { return uniorg; } | |||
| public void setUniorg(String uniorg) { this.uniorg = uniorg; } | |||
| } | |||
| @ -0,0 +1,33 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| import java.util.List; | |||
| public class fotoOTDTO { | |||
| private Integer OTID; | |||
| private List<FotoDTO> FOTOS; | |||
| public Integer getOTID() { return OTID; } | |||
| public void setOTID(Integer OTID) { | |||
| this.OTID = OTID; | |||
| } | |||
| public List<FotoDTO> getFOTOS() { return FOTOS; } | |||
| public void setFOTOS(List<FotoDTO> FOTOS) { | |||
| this.FOTOS = FOTOS; | |||
| } | |||
| public static class FotoDTO { | |||
| private String base64; | |||
| private String nomfoto; | |||
| public String getBase64() { return base64; } | |||
| public void setBase64(String base64) { | |||
| this.base64 = base64; | |||
| } | |||
| public String getNomfoto() { return nomfoto; } | |||
| public void setNomfoto(String nomfoto) { | |||
| this.nomfoto = nomfoto; | |||
| } | |||
| } | |||
| } | |||
| @ -0,0 +1,19 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| import io.micronaut.core.annotation.Introspected; | |||
| @Introspected | |||
| public class motivoPreguntaDTO { | |||
| private Integer motivoid; | |||
| private Integer preguntaid; | |||
| private Integer ordenmot; | |||
| public Integer getMotivoid() { return motivoid; } | |||
| public void setMotivoid(Integer motivoid) { this.motivoid = motivoid; } | |||
| public Integer getPreguntaid() { return preguntaid; } | |||
| public void setPreguntaid(Integer preguntaid) { this.preguntaid = preguntaid; } | |||
| public Integer getOrdenmot() { return ordenmot; } | |||
| public void setOrdenmot(Integer ordenmot) { this.ordenmot = ordenmot; } | |||
| } | |||
| @ -0,0 +1,16 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| public class noCommMensajeDTO { | |||
| private Long OTID; | |||
| private String MENSAJE; | |||
| public Long getOTID() { return OTID; } | |||
| public void setOTID(Long OTID) { | |||
| this.OTID = OTID; | |||
| } | |||
| public String getMENSAJE() { return MENSAJE; } | |||
| public void setMENSAJE(String MENSAJE) { | |||
| this.MENSAJE = MENSAJE; | |||
| } | |||
| } | |||
| @ -0,0 +1,20 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| import io.micronaut.core.annotation.Introspected; | |||
| @Introspected | |||
| public class origenDTO { | |||
| private Integer origenid; | |||
| private String descripcion; | |||
| public Integer getOrigenid() { return origenid; } | |||
| public void setOrigenid(Integer origenid) { | |||
| this.origenid = origenid; | |||
| } | |||
| public String getDescripcion() { return descripcion; } | |||
| public void setDescripcion(String descripcion) { | |||
| this.descripcion = descripcion; | |||
| } | |||
| } | |||
| @ -0,0 +1,147 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| import io.micronaut.core.annotation.Introspected; | |||
| import java.math.BigDecimal; | |||
| @Introspected | |||
| public class otDTO { | |||
| private Long otid; | |||
| private Long predioid; | |||
| private Long clienteid; | |||
| private String fecha; | |||
| private String fechamax; | |||
| private String fechaprecierre; | |||
| private String fechacierre; | |||
| private String fechaanulacion; | |||
| private Integer motivoid; | |||
| private String motivo; | |||
| private Integer origenid; | |||
| private String usuarioalta; | |||
| private String usuarioprecierre; | |||
| private String usuariocierre; | |||
| private String usuarioanulacion; | |||
| private String descripcion; | |||
| private String observacion; | |||
| private String horainicio; | |||
| private String horaftermino; | |||
| private Long otpadre; | |||
| private String fechareporte; | |||
| private Integer numreportes; | |||
| private String fechaasignacion; | |||
| private String cuadrillaasignada; | |||
| private String fechaprog; | |||
| private String nombsuperv; | |||
| private String nombintegra; | |||
| private String motivoanulacion; | |||
| private Integer motsusid; | |||
| private String usudictamen; | |||
| private String obsdictamen; | |||
| private String direccionot; | |||
| private BigDecimal coordx; | |||
| private BigDecimal coordy; | |||
| // Getters y setters | |||
| public Long getOtid() { return otid; } | |||
| public void setOtid(Long otid) { this.otid = otid; } | |||
| public Long getPredioid() { return predioid; } | |||
| public void setPredioid(Long predioid) { this.predioid = predioid; } | |||
| public Long getClienteid() { return clienteid; } | |||
| public void setClienteid(Long clienteid) { this.clienteid = clienteid; } | |||
| public String getFecha() { return fecha; } | |||
| public void setFecha(String fecha) { this.fecha = fecha; } | |||
| public String getFechamax() { return fechamax; } | |||
| public void setFechamax(String fechamax) { this.fechamax = fechamax; } | |||
| public String getFechaprecierre() { return fechaprecierre; } | |||
| public void setFechaprecierre(String fechaprecierre) { this.fechaprecierre = fechaprecierre; } | |||
| public String getFechacierre() { return fechacierre; } | |||
| public void setFechacierre(String fechacierre) { this.fechacierre = fechacierre; } | |||
| public String getFechaanulacion() { return fechaanulacion; } | |||
| public void setFechaanulacion(String fechaanulacion) { this.fechaanulacion = fechaanulacion; } | |||
| public Integer getMotivoid() { return motivoid; } | |||
| public void setMotivoid(Integer motivoid) { this.motivoid = motivoid; } | |||
| public String getMotivo() { return motivo; } | |||
| public void setMotivo(String motivo) { this.motivo = motivo; } | |||
| public Integer getOrigenid() { return origenid; } | |||
| public void setOrigenid(Integer origenid) { this.origenid = origenid; } | |||
| public String getUsuarioalta() { return usuarioalta; } | |||
| public void setUsuarioalta(String usuarioalta) { this.usuarioalta = usuarioalta; } | |||
| public String getUsuarioprecierre() { return usuarioprecierre; } | |||
| public void setUsuarioprecierre(String usuarioprecierre) { this.usuarioprecierre = usuarioprecierre; } | |||
| public String getUsuariocierre() { return usuariocierre; } | |||
| public void setUsuariocierre(String usuariocierre) { this.usuariocierre = usuariocierre; } | |||
| public String getUsuarioanulacion() { return usuarioanulacion; } | |||
| public void setUsuarioanulacion(String usuarioanulacion) { this.usuarioanulacion = usuarioanulacion; } | |||
| public String getDescripcion() { return descripcion; } | |||
| public void setDescripcion(String descripcion) { this.descripcion = descripcion; } | |||
| public String getObservacion() { return observacion; } | |||
| public void setObservacion(String observacion) { this.observacion = observacion; } | |||
| public String getHorainicio() { return horainicio; } | |||
| public void setHorainicio(String horainicio) { this.horainicio = horainicio; } | |||
| public String getHoraftermino() { return horaftermino; } | |||
| public void setHoraftermino(String horaftermino) { this.horaftermino = horaftermino; } | |||
| public Long getOtpadre() { return otpadre; } | |||
| public void setOtpadre(Long otpadre) { this.otpadre = otpadre; } | |||
| public String getFechareporte() { return fechareporte; } | |||
| public void setFechareporte(String fechareporte) { this.fechareporte = fechareporte; } | |||
| public Integer getNumreportes() { return numreportes; } | |||
| public void setNumreportes(Integer numreportes) { this.numreportes = numreportes; } | |||
| public String getFechaasignacion() { return fechaasignacion; } | |||
| public void setFechaasignacion(String fechaasignacion) { this.fechaasignacion = fechaasignacion; } | |||
| public String getCuadrillaasignada() { return cuadrillaasignada; } | |||
| public void setCuadrillaasignada(String cuadrillaasignada) { this.cuadrillaasignada = cuadrillaasignada; } | |||
| public String getFechaprog() { return fechaprog; } | |||
| public void setFechaprog(String fechaprog) { this.fechaprog = fechaprog; } | |||
| public String getNombsuperv() { return nombsuperv; } | |||
| public void setNombsuperv(String nombsuperv) { this.nombsuperv = nombsuperv; } | |||
| public String getNombintegra() { return nombintegra; } | |||
| public void setNombintegra(String nombintegra) { this.nombintegra = nombintegra; } | |||
| public String getMotivoanulacion() { return motivoanulacion; } | |||
| public void setMotivoanulacion(String motivoanulacion) { this.motivoanulacion = motivoanulacion; } | |||
| public Integer getMotsusid() { return motsusid; } | |||
| public void setMotsusid(Integer motsusid) { this.motsusid = motsusid; } | |||
| public String getUsudictamen() { return usudictamen; } | |||
| public void setUsudictamen(String usudictamen) { this.usudictamen = usudictamen; } | |||
| public String getObsdictamen() { return obsdictamen; } | |||
| public void setObsdictamen(String obsdictamen) { this.obsdictamen = obsdictamen; } | |||
| public String getDireccionot() { return direccionot; } | |||
| public void setDireccionot(String direccionot) { this.direccionot = direccionot; } | |||
| public BigDecimal getCoordx() { return coordx; } | |||
| public void setCoordx(BigDecimal coordx) { this.coordx = coordx; } | |||
| public BigDecimal getCoordy() { return coordy; } | |||
| public void setCoordy(BigDecimal coordy) { this.coordy = coordy; } | |||
| } | |||
| @ -0,0 +1,44 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| import java.util.List; | |||
| import java.util.Map; | |||
| public class preguntaDTO { | |||
| private Integer preguntaid; | |||
| private String descripcion; | |||
| private String sentenciasql; | |||
| private String unimed; | |||
| private List<Map<String, Object>> sentenciasqlData; | |||
| private List<Map<String, Object>> unimedData; | |||
| public Integer getPreguntaid() { return preguntaid; } | |||
| public void setPreguntaid(Integer preguntaid) { | |||
| this.preguntaid = preguntaid; | |||
| } | |||
| public String getDescripcion() { return descripcion; } | |||
| public void setDescripcion(String descripcion) { | |||
| this.descripcion = descripcion; | |||
| } | |||
| public String getSentenciaSQL() { return sentenciasql; } | |||
| public void setSentenciaSQL(String sentenciasql) { | |||
| this.sentenciasql = sentenciasql; | |||
| } | |||
| public String getUnimed() { return unimed; } | |||
| public void setUnimed(String unimed) { | |||
| this.unimed = unimed; | |||
| } | |||
| public List<Map<String, Object>> getSentenciaSQLData() { return sentenciasqlData; } | |||
| public void setSentenciaSQLData(List<Map<String, Object>> sentenciasqlData) { | |||
| this.sentenciasqlData = sentenciasqlData; | |||
| } | |||
| public List<Map<String, Object>> getUnimedData() { return unimedData; } | |||
| public void setUnimedData(List<Map<String, Object>> unimedData) { | |||
| this.unimedData = unimedData; | |||
| } | |||
| } | |||
| @ -0,0 +1,102 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| import java.util.List; | |||
| public class respuestaOTDTO { | |||
| private Long otid; | |||
| private String fechaprecierre; | |||
| private String usuarioprecierre; | |||
| private String horainicio; | |||
| private String horatermino; | |||
| private String observacion; | |||
| private String nombsuperv; | |||
| private String nombintegra; | |||
| private String dictamenid; | |||
| private String obsdictamen; | |||
| private String usuariocierree; | |||
| private String transaccid; | |||
| private List<respuestaPreguntaDTO> resppreg; | |||
| private List<FotoBase64DTO> fotos; | |||
| private List<OTHijaDTO> othijas; | |||
| // Getters y Setters | |||
| public Long getOTid() { return otid; } | |||
| public void setOtid(Long otid) { | |||
| this.otid = otid; | |||
| } | |||
| public String getFechaPreCierre() { return fechaprecierre; } | |||
| public void setFechaPreCierre(String fechaprecierre) { | |||
| this.fechaprecierre = fechaprecierre; | |||
| } | |||
| public String getUsuarioPreCierre() { return usuarioprecierre; } | |||
| public void setUsuarioPreCierre(String usuarioprecierre) { | |||
| this.usuarioprecierre = usuarioprecierre; | |||
| } | |||
| public String getHoraInicio() { return horainicio; } | |||
| public void setHoraInicio(String horainicio) { | |||
| this.horainicio = horainicio; | |||
| } | |||
| public String getHoraTermino() { return horatermino; } | |||
| public void set(String horatermino) { | |||
| this.horatermino = horatermino; | |||
| } | |||
| public String getObservacion() { return observacion; } | |||
| public void setObservacion(String observacion) { | |||
| this.observacion = observacion; | |||
| } | |||
| public String getNombSuperv() { return nombsuperv; } | |||
| public void setNombSuperv(String nombsuprev) { | |||
| this.nombsuperv = nombsuprev; | |||
| } | |||
| public String getNombIntegra() { return nombintegra; } | |||
| public void setNombIntegra(String nombintegra) { | |||
| this.nombintegra = nombintegra; | |||
| } | |||
| public String getDictamenId() { return dictamenid; } | |||
| public void setDictamenId(String dictamenid) { | |||
| this.dictamenid = dictamenid; | |||
| } | |||
| public String getObsDictamen() { return obsdictamen; } | |||
| public void setObsDictamen(String obsdictamen) { | |||
| this.obsdictamen = obsdictamen; | |||
| } | |||
| public String getUsuarioCierre() { return usuariocierree; } | |||
| public void setUsuarioCierre(String usuariocierree) { | |||
| this.usuariocierree = usuariocierree; | |||
| } | |||
| public String getTransaccId() { return transaccid; } | |||
| public void setTransaccId(String transaccid) { | |||
| this.transaccid = transaccid; | |||
| } | |||
| public List<respuestaPreguntaDTO> getResppreg() { return resppreg; } | |||
| public void setResppreg(List<respuestaPreguntaDTO> resppreg) { | |||
| this.resppreg = resppreg; | |||
| } | |||
| public List<FotoBase64DTO> getFoto() { return fotos; } | |||
| public void setFoto(List<FotoBase64DTO> fotos) { | |||
| this.fotos = fotos; | |||
| } | |||
| public List<OTHijaDTO> getOThijas() { return othijas; } | |||
| public void setOThijas(List<OTHijaDTO> othijas) { | |||
| this.othijas = othijas; | |||
| } | |||
| /*public String get() { return ; } | |||
| public void set(String ) { | |||
| this. = ; | |||
| }*/ | |||
| } | |||
| @ -0,0 +1,23 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| public class respuestaPreguntaDTO { | |||
| private String preguntaid; | |||
| private String respuesta; | |||
| private String umid; | |||
| // Getters y Setters | |||
| public String getPreguntaId() { return preguntaid; } | |||
| public void setPreguntaId(String preguntaid) { | |||
| this.preguntaid = preguntaid; | |||
| } | |||
| public String getRespuesta() { return respuesta; } | |||
| public void setRespuesta(String respuesta) { | |||
| this.respuesta = respuesta; | |||
| } | |||
| public String getUmId() { return umid; } | |||
| public void setUmId(String umid) { | |||
| this.umid = umid; | |||
| } | |||
| } | |||
| @ -0,0 +1,19 @@ | |||
| package jumapacelaya.gob.mx.appots.dto; | |||
| import java.time.LocalDateTime; | |||
| public class transaccionDTO { | |||
| private Long otid; | |||
| private LocalDateTime transaccdt; | |||
| // Getters y setters | |||
| public Long getOtid() { return otid; } | |||
| public void setOtid(Long otid) { | |||
| this.otid = otid; | |||
| } | |||
| public LocalDateTime getTransaccdt() { return transaccdt; } | |||
| public void setTransaccdt(LocalDateTime transaccdt) { | |||
| this.transaccdt = transaccdt; | |||
| } | |||
| } | |||