Compare commits
14 Commits
e8160eefba
...
develop
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
50f1ced127 | ||
|
|
72d0e6a589 | ||
|
|
58954219c8 | ||
|
|
0776ed8c59 | ||
|
|
d2b7b982f3 | ||
|
|
c2f249c937 | ||
|
|
b7c80baadc | ||
|
|
a2bde9e920 | ||
|
|
78a6666e5a | ||
|
|
2f52c96067 | ||
|
|
24bcb27d07 | ||
|
|
16d509cf06 | ||
|
|
1daf15d92f | ||
|
|
329b8b70d4 |
1
.gitignore
vendored
@@ -76,3 +76,4 @@ coverage/
|
||||
*.secrets.json
|
||||
Web.local.config
|
||||
appsettings.local.json
|
||||
/SIG.Web/Documentos/**
|
||||
|
||||
@@ -135,3 +135,7 @@ Do not add the following until the user explicitly asks:
|
||||
The starter must stay small and focused: commands, master page, login, contracts, dummy user session, bundle structure, copied assets, and centralized SQL foundation.
|
||||
|
||||
---
|
||||
|
||||
|
||||
|
||||
REGLA OBLIGATORIA: Nunca usar args.get_panelsUpdated() ni get_panelsUpdated() en JavaScript de WebForms/UpdatePanel de este proyecto; esa llamada rompe repetidamente el entorno. Para reinicializar después de postbacks parciales usar PageRequestManager.add_endRequest(function () { ... }) sin depender de args, o eventos delegados cuando corresponda.
|
||||
@@ -1,4 +1,4 @@
|
||||
# AGENTS_MANTENIMIENTO_PROYECTO.md
|
||||
# AGENTS_MANTENIMIENTO_PROYECTO.md
|
||||
|
||||
These rules complement `AGENTS.md` and are mandatory whenever the task involves commands, security, error handling, user feedback, grids, PDF migration, file delivery, verification, or project evolution.
|
||||
|
||||
@@ -74,6 +74,8 @@ Controlled outcomes and technical failures must use different logs.
|
||||
|
||||
## Grid display rules
|
||||
|
||||
- Los valores numéricos de negocio (hectáreas, superficies, avances, porcentajes, cantidades, importes y saldos) deben alinearse a la derecha tanto en los campos de captura como en las celdas y resúmenes donde se muestran. Usar las clases visuales existentes o la alineación del control; esta regla no convierte claves, folios ni códigos en cantidades.
|
||||
|
||||
- Every new or modified `asp:GridView` must declare `GridLines="None"`.
|
||||
- Its `CssClass` must include the exact utility class `Widthall` so the grid uses the full available width.
|
||||
- Do not add `table-bordered` to a GridView. Existing visual classes such as `table`, `table-striped`, and `table-hover` may be retained when appropriate.
|
||||
|
||||
649
Convenios_Etapa_TipoTramite_20261002.sql
Normal file
@@ -0,0 +1,649 @@
|
||||
/*
|
||||
Preparado a partir de las definiciones instaladas; no ejecutado.
|
||||
Instalar junto con la aplicación. No modifica conceptos, recibos ni pagos.
|
||||
CveSolicitud se conserva únicamente como referencia histórica.
|
||||
Los convenios históricos sin una solicitud conservan CveTipoTramite NULL:
|
||||
su asignación requiere una decisión de negocio; no se elige un trámite arbitrario.
|
||||
*/
|
||||
SET NOCOUNT ON;
|
||||
|
||||
IF COL_LENGTH('dbo.Convenios', 'CveTipoTramite') IS NULL
|
||||
ALTER TABLE dbo.Convenios ADD CveTipoTramite int NULL;
|
||||
GO
|
||||
|
||||
UPDATE C
|
||||
SET CveTipoTramite = S.CveTipoTramite
|
||||
FROM dbo.Convenios AS C
|
||||
INNER JOIN dbo.Tra_Solicitudes AS S ON S.CveSolicitud = C.CveSolicitud
|
||||
WHERE C.CveTipoTramite IS NULL;
|
||||
|
||||
IF NOT EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM sys.foreign_keys
|
||||
WHERE name = 'FK_Convenios_TipoTramite'
|
||||
)
|
||||
ALTER TABLE dbo.Convenios WITH CHECK
|
||||
ADD CONSTRAINT FK_Convenios_TipoTramite
|
||||
FOREIGN KEY (CveTipoTramite)
|
||||
REFERENCES dbo.Tra_TiposTramite (CveTipoTramite);
|
||||
|
||||
IF NOT EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Convenios')
|
||||
AND name = 'IX_Convenios_Etapa_TipoTramite'
|
||||
)
|
||||
CREATE INDEX IX_Convenios_Etapa_TipoTramite
|
||||
ON dbo.Convenios (CveFraccionamientoEtapa, CveTipoTramite);
|
||||
|
||||
DECLARE @QuitarRelacion nvarchar(max) = N'';
|
||||
SELECT @QuitarRelacion = @QuitarRelacion
|
||||
+ N'ALTER TABLE dbo.Convenios DROP CONSTRAINT ' + QUOTENAME(F.name) + N';'
|
||||
FROM sys.foreign_keys AS F
|
||||
WHERE F.parent_object_id = OBJECT_ID('dbo.Convenios')
|
||||
AND F.referenced_object_id = OBJECT_ID('dbo.Tra_Solicitudes');
|
||||
IF @QuitarRelacion <> N''
|
||||
EXEC sys.sp_executesql @QuitarRelacion;
|
||||
|
||||
-- Resultado de diagnóstico; no cambia la clasificación de estos convenios.
|
||||
SELECT CveConvenio, NumeroConvenio, CveFraccionamientoEtapa
|
||||
FROM dbo.Convenios
|
||||
WHERE CveTipoTramite IS NULL;
|
||||
GO
|
||||
|
||||
CREATE OR ALTER PROCEDURE dbo.PA_Tra_ConvenioAdd
|
||||
@CveCliente int,
|
||||
@CveFraccionamientoEtapa int,
|
||||
@CveTipoTramite int,
|
||||
@NumeroConvenio varchar(100),
|
||||
@NumeroOficio varchar(100) = NULL,
|
||||
@ViviendasAutorizadas int = NULL,
|
||||
@ViviendasEnConvenio int,
|
||||
@ViviendasPendientes int = NULL,
|
||||
@ViviendasContratadas int = NULL,
|
||||
@FechaConvenio date,
|
||||
@Observaciones varchar(1000) = NULL,
|
||||
@ConceptosXml xml,
|
||||
@CveUsuarioEjecuta int,
|
||||
@ErrorMostrar varchar(max) OUTPUT,
|
||||
@ErrorTipo int OUTPUT,
|
||||
@Return bit OUTPUT
|
||||
AS
|
||||
BEGIN
|
||||
SET NOCOUNT ON;
|
||||
|
||||
SELECT
|
||||
@ErrorMostrar = NULL,
|
||||
@ErrorTipo = 0,
|
||||
@Return = 0;
|
||||
|
||||
BEGIN TRY
|
||||
SET @NumeroConvenio = NULLIF(LTRIM(RTRIM(@NumeroConvenio)), '');
|
||||
SET @NumeroOficio = NULLIF(LTRIM(RTRIM(@NumeroOficio)), '');
|
||||
SET @Observaciones = NULLIF(LTRIM(RTRIM(@Observaciones)), '');
|
||||
|
||||
IF @CveCliente <= 0
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'Seleccione el desarrollador del convenio.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
IF @CveFraccionamientoEtapa <= 0
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'Seleccione el fraccionamiento y etapa del convenio.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
IF ISNULL(@CveTipoTramite, 0) <= 0
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'Seleccione el tipo de trámite del convenio.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
IF @NumeroConvenio IS NULL
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'Capture el número de convenio.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
IF @ViviendasEnConvenio < 0
|
||||
OR ISNULL(@ViviendasAutorizadas, 0) < 0
|
||||
OR ISNULL(@ViviendasPendientes, 0) < 0
|
||||
OR ISNULL(@ViviendasContratadas, 0) < 0
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'Las cantidades de viviendas no son válidas.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
IF NOT EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM dbo.FraccionamientosEtapas AS E
|
||||
INNER JOIN dbo.Fraccionamientos AS F ON F.CveFraccionamiento = E.CveFraccionamiento
|
||||
WHERE E.CveFraccionamientoEtapa = @CveFraccionamientoEtapa
|
||||
AND F.CveCliente = @CveCliente
|
||||
)
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'La etapa seleccionada no pertenece al desarrollador indicado.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM dbo.Convenios AS C
|
||||
WHERE C.NumeroConvenio = @NumeroConvenio
|
||||
)
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'Ya existe un convenio con ese número.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
DECLARE @Conceptos TABLE
|
||||
(
|
||||
Orden int NOT NULL PRIMARY KEY,
|
||||
CveConvenioConcepto int NOT NULL,
|
||||
Importe decimal(18,6) NOT NULL,
|
||||
Tipo varchar(20) NOT NULL,
|
||||
NumeroPagos int NOT NULL
|
||||
);
|
||||
|
||||
DECLARE @Recibos TABLE
|
||||
(
|
||||
OrdenConcepto int NOT NULL,
|
||||
Orden int NOT NULL,
|
||||
Importe decimal(18,6) NOT NULL,
|
||||
FechaVencimiento date NOT NULL,
|
||||
Estatus varchar(30) NOT NULL,
|
||||
PRIMARY KEY (OrdenConcepto, Orden)
|
||||
);
|
||||
|
||||
IF @ConceptosXml IS NOT NULL
|
||||
BEGIN
|
||||
INSERT INTO @Conceptos
|
||||
(
|
||||
Orden,
|
||||
CveConvenioConcepto,
|
||||
Importe,
|
||||
Tipo,
|
||||
NumeroPagos
|
||||
)
|
||||
SELECT
|
||||
C.value('@Orden', 'int'),
|
||||
C.value('@CveConvenioConcepto', 'int'),
|
||||
C.value('@Importe', 'decimal(18,6)'),
|
||||
C.value('@Tipo', 'varchar(20)'),
|
||||
C.value('@NumeroPagos', 'int')
|
||||
FROM @ConceptosXml.nodes('/Conceptos/Concepto') AS X(C);
|
||||
|
||||
INSERT INTO @Recibos
|
||||
(
|
||||
OrdenConcepto,
|
||||
Orden,
|
||||
Importe,
|
||||
FechaVencimiento,
|
||||
Estatus
|
||||
)
|
||||
SELECT
|
||||
C.value('@Orden', 'int'),
|
||||
R.value('@Orden', 'int'),
|
||||
R.value('@Importe', 'decimal(18,6)'),
|
||||
R.value('@FechaVencimiento', 'date'),
|
||||
COALESCE(
|
||||
NULLIF(R.value('@Estatus', 'varchar(30)'), ''),
|
||||
'PENDIENTE'
|
||||
)
|
||||
FROM @ConceptosXml.nodes('/Conceptos/Concepto') AS CX(C)
|
||||
CROSS APPLY C.nodes('Recibos/Recibo') AS RX(R);
|
||||
END;
|
||||
|
||||
IF NOT EXISTS (SELECT 1 FROM @Conceptos)
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'Agregue al menos un concepto al convenio.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM @Conceptos AS C
|
||||
LEFT JOIN dbo.ConveniosConceptos AS CC ON CC.CveConvenioConcepto = C.CveConvenioConcepto
|
||||
AND CC.EsActivo = 1
|
||||
WHERE CC.CveConvenioConcepto IS NULL
|
||||
OR C.Importe <= 0
|
||||
OR NULLIF(LTRIM(RTRIM(C.Tipo)), '') IS NULL
|
||||
OR C.NumeroPagos NOT BETWEEN 1 AND 12
|
||||
)
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'Uno de los conceptos del convenio no es válido.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM @Recibos AS R
|
||||
WHERE R.Importe <= 0
|
||||
OR R.FechaVencimiento IS NULL
|
||||
)
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'Todas las parcialidades deben tener importe y vencimiento válidos.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM @Conceptos AS C
|
||||
OUTER APPLY
|
||||
(
|
||||
SELECT
|
||||
COUNT(*) AS NumeroRecibos,
|
||||
SUM(R.Importe) AS ImporteRecibos
|
||||
FROM @Recibos AS R
|
||||
WHERE R.OrdenConcepto = C.Orden
|
||||
) AS R
|
||||
WHERE ISNULL(R.NumeroRecibos, 0) <> C.NumeroPagos
|
||||
OR ISNULL(R.ImporteRecibos, 0) <> C.Importe
|
||||
)
|
||||
BEGIN
|
||||
SET @ErrorMostrar =
|
||||
'La cantidad y suma de las parcialidades debe coincidir con cada concepto.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
INSERT INTO dbo.Convenios
|
||||
(
|
||||
CveCliente,
|
||||
NumeroConvenio,
|
||||
NumeroOficio,
|
||||
CveFraccionamientoEtapa,
|
||||
CveTipoTramite,
|
||||
ViviendasAutorizadas,
|
||||
ViviendasEnConvenio,
|
||||
ViviendasPendientes,
|
||||
ViviendasContratadas,
|
||||
FechaConvenio,
|
||||
Observaciones,
|
||||
Estatus,
|
||||
CveConvenioOrigen,
|
||||
CveUsuario
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
@CveCliente,
|
||||
@NumeroConvenio,
|
||||
@NumeroOficio,
|
||||
@CveFraccionamientoEtapa,
|
||||
@CveTipoTramite,
|
||||
@ViviendasAutorizadas,
|
||||
@ViviendasEnConvenio,
|
||||
@ViviendasPendientes,
|
||||
@ViviendasContratadas,
|
||||
@FechaConvenio,
|
||||
@Observaciones,
|
||||
'ACTIVO',
|
||||
NULL,
|
||||
@CveUsuarioEjecuta
|
||||
);
|
||||
|
||||
DECLARE @CveConvenio int = CONVERT(int, SCOPE_IDENTITY());
|
||||
DECLARE @OrdenConcepto int = 0;
|
||||
DECLARE @CveConvenioConcepto int;
|
||||
DECLARE @ImporteConcepto decimal(18,6);
|
||||
DECLARE @Tipo varchar(20);
|
||||
DECLARE @NumeroPagos int;
|
||||
DECLARE @CveConvenioDetalle int;
|
||||
|
||||
WHILE EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM @Conceptos
|
||||
WHERE Orden > @OrdenConcepto
|
||||
)
|
||||
BEGIN
|
||||
SELECT TOP (1)
|
||||
@OrdenConcepto = C.Orden,
|
||||
@CveConvenioConcepto = C.CveConvenioConcepto,
|
||||
@ImporteConcepto = C.Importe,
|
||||
@Tipo = C.Tipo,
|
||||
@NumeroPagos = C.NumeroPagos
|
||||
FROM @Conceptos AS C
|
||||
WHERE C.Orden > @OrdenConcepto
|
||||
ORDER BY C.Orden;
|
||||
|
||||
INSERT INTO dbo.ConveniosDetalle
|
||||
(
|
||||
CveConvenio,
|
||||
CveConvenioConcepto,
|
||||
Importe,
|
||||
Tipo,
|
||||
NumeroPagos,
|
||||
Observaciones
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
@CveConvenio,
|
||||
@CveConvenioConcepto,
|
||||
@ImporteConcepto,
|
||||
@Tipo,
|
||||
@NumeroPagos,
|
||||
NULL
|
||||
);
|
||||
|
||||
SET @CveConvenioDetalle = CONVERT(int, SCOPE_IDENTITY());
|
||||
|
||||
INSERT INTO dbo.ConveniosRecibos
|
||||
(
|
||||
CveConvenioDetalle,
|
||||
NumeroRecibo,
|
||||
Importe,
|
||||
FechaVencimiento,
|
||||
Estatus
|
||||
)
|
||||
SELECT
|
||||
@CveConvenioDetalle,
|
||||
CONCAT(
|
||||
'RD',
|
||||
CONVERT(char(8), GETDATE(), 112),
|
||||
@CveConvenio,
|
||||
'-',
|
||||
RIGHT('000' + CONVERT(varchar(3), @OrdenConcepto), 3),
|
||||
'-',
|
||||
RIGHT('000' + CONVERT(varchar(3), R.Orden), 3)
|
||||
),
|
||||
R.Importe,
|
||||
R.FechaVencimiento,
|
||||
R.Estatus
|
||||
FROM @Recibos AS R
|
||||
WHERE R.OrdenConcepto = @OrdenConcepto
|
||||
ORDER BY R.Orden;
|
||||
END;
|
||||
|
||||
SELECT @CveConvenio AS CveConvenio;
|
||||
SET @Return = 1;
|
||||
END TRY
|
||||
BEGIN CATCH
|
||||
SET @ErrorMostrar =
|
||||
'Ocurrió un error al guardar el convenio; favor de contactar a Sistemas.';
|
||||
SET @ErrorTipo = 1;
|
||||
SET @Return = 0;
|
||||
|
||||
DECLARE @ErrorTecnico nvarchar(2048) = CONCAT(
|
||||
'Número: ', ERROR_NUMBER(),
|
||||
'; Procedimiento: ', COALESCE(
|
||||
ERROR_PROCEDURE(),
|
||||
'PA_Tra_ConvenioAdd'
|
||||
),
|
||||
'; Línea: ', ERROR_LINE(),
|
||||
'; Detalle: ', ERROR_MESSAGE()
|
||||
);
|
||||
|
||||
RAISERROR(N'%s', 10, 1, @ErrorTecnico);
|
||||
END CATCH;
|
||||
END;
|
||||
|
||||
GO
|
||||
|
||||
/*
|
||||
Se vuelven a definir List/Get únicamente para alinear la salida
|
||||
con Clientes.Nombre y devolver el encabezado completo del modal.
|
||||
*/
|
||||
CREATE OR ALTER PROCEDURE dbo.PA_Tra_ConvenioList
|
||||
@CveTipoTramite int = NULL,
|
||||
@CveCliente int = NULL,
|
||||
@CveFraccionamiento int = NULL,
|
||||
@CveFraccionamientoEtapa int = NULL,
|
||||
@Estatus varchar(30) = NULL,
|
||||
@ConSaldoPendiente bit = NULL,
|
||||
@CveUsuarioEjecuta int,
|
||||
@ErrorMostrar varchar(max) OUTPUT,
|
||||
@ErrorTipo int OUTPUT,
|
||||
@Return bit OUTPUT
|
||||
AS
|
||||
BEGIN
|
||||
SET NOCOUNT ON;
|
||||
|
||||
SELECT
|
||||
@ErrorMostrar = NULL,
|
||||
@ErrorTipo = 0,
|
||||
@Return = 0;
|
||||
|
||||
BEGIN TRY
|
||||
;WITH PagadoRecibo AS
|
||||
(
|
||||
SELECT
|
||||
PR.CveConvenioRecibo,
|
||||
SUM(PR.ImporteAplicado) AS ImportePagado
|
||||
FROM dbo.ConveniosPagosRecibos AS PR
|
||||
GROUP BY PR.CveConvenioRecibo
|
||||
),
|
||||
Totales AS
|
||||
(
|
||||
SELECT
|
||||
D.CveConvenio,
|
||||
SUM(R.Importe) AS ImporteConvenio,
|
||||
SUM(ISNULL(P.ImportePagado, 0)) AS ImportePagado,
|
||||
SUM(R.Importe - ISNULL(P.ImportePagado, 0)) AS SaldoPendiente,
|
||||
MAX(CASE WHEN P.CveConvenioRecibo IS NULL THEN 0 ELSE 1 END) AS TienePagos
|
||||
FROM dbo.ConveniosDetalle AS D
|
||||
LEFT JOIN dbo.ConveniosRecibos AS R ON R.CveConvenioDetalle = D.CveConvenioDetalle
|
||||
LEFT JOIN PagadoRecibo AS P ON P.CveConvenioRecibo = R.CveConvenioRecibo
|
||||
GROUP BY D.CveConvenio
|
||||
)
|
||||
SELECT
|
||||
C.CveConvenio,
|
||||
C.CveTipoTramite,
|
||||
TT.TipoTramite,
|
||||
C.CveCliente,
|
||||
CL.Nombre AS Cliente,
|
||||
F.CveFraccionamiento,
|
||||
F.Fraccionamiento,
|
||||
FE.CveFraccionamientoEtapa,
|
||||
FE.Etapa,
|
||||
C.NumeroConvenio,
|
||||
C.NumeroOficio,
|
||||
C.Estatus,
|
||||
C.FechaConvenio,
|
||||
ISNULL(T.ImporteConvenio, 0) AS ImporteConvenio,
|
||||
ISNULL(T.ImportePagado, 0) AS ImportePagado,
|
||||
ISNULL(T.SaldoPendiente, 0) AS SaldoPendiente,
|
||||
CONVERT(bit, ISNULL(T.TienePagos, 0)) AS TienePagos
|
||||
FROM dbo.Convenios AS C
|
||||
LEFT JOIN dbo.Tra_TiposTramite AS TT ON TT.CveTipoTramite = C.CveTipoTramite
|
||||
INNER JOIN dbo.FraccionamientosEtapas AS FE ON FE.CveFraccionamientoEtapa = C.CveFraccionamientoEtapa
|
||||
INNER JOIN dbo.Fraccionamientos AS F ON F.CveFraccionamiento = FE.CveFraccionamiento
|
||||
INNER JOIN dbo.Clientes AS CL ON CL.CveCliente = C.CveCliente
|
||||
LEFT JOIN Totales AS T ON T.CveConvenio = C.CveConvenio
|
||||
WHERE (@CveCliente IS NULL OR C.CveCliente = @CveCliente)
|
||||
AND (@CveTipoTramite IS NULL OR C.CveTipoTramite = @CveTipoTramite)
|
||||
AND (@CveFraccionamiento IS NULL OR F.CveFraccionamiento = @CveFraccionamiento)
|
||||
AND (@CveFraccionamientoEtapa IS NULL OR C.CveFraccionamientoEtapa = @CveFraccionamientoEtapa)
|
||||
AND (NULLIF(@Estatus, '') IS NULL OR C.Estatus = @Estatus)
|
||||
AND
|
||||
(
|
||||
@ConSaldoPendiente IS NULL
|
||||
OR @ConSaldoPendiente = CASE
|
||||
WHEN ISNULL(T.SaldoPendiente, 0) > 0 THEN 1
|
||||
ELSE 0
|
||||
END
|
||||
)
|
||||
ORDER BY
|
||||
C.FechaConvenio DESC,
|
||||
C.CveConvenio DESC;
|
||||
|
||||
SET @Return = 1;
|
||||
END TRY
|
||||
BEGIN CATCH
|
||||
SET @ErrorMostrar =
|
||||
'Ocurrió un error al consultar los convenios; favor de contactar a Sistemas.';
|
||||
SET @ErrorTipo = 1;
|
||||
SET @Return = 0;
|
||||
|
||||
DECLARE @ErrorTecnico nvarchar(2048) = CONCAT(
|
||||
'Número: ', ERROR_NUMBER(),
|
||||
'; Procedimiento: ', COALESCE(
|
||||
ERROR_PROCEDURE(),
|
||||
'PA_Tra_ConvenioList'
|
||||
),
|
||||
'; Línea: ', ERROR_LINE(),
|
||||
'; Detalle: ', ERROR_MESSAGE()
|
||||
);
|
||||
|
||||
RAISERROR(N'%s', 10, 1, @ErrorTecnico);
|
||||
END CATCH;
|
||||
END;
|
||||
|
||||
GO
|
||||
|
||||
CREATE OR ALTER PROCEDURE dbo.PA_Tra_ConvenioGet
|
||||
@CveConvenio int,
|
||||
@CveUsuarioEjecuta int,
|
||||
@ErrorMostrar varchar(max) OUTPUT,
|
||||
@ErrorTipo int OUTPUT,
|
||||
@Return bit OUTPUT
|
||||
AS
|
||||
BEGIN
|
||||
SET NOCOUNT ON;
|
||||
|
||||
SELECT
|
||||
@ErrorMostrar = NULL,
|
||||
@ErrorTipo = 0,
|
||||
@Return = 0;
|
||||
|
||||
BEGIN TRY
|
||||
IF NOT EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM dbo.Convenios
|
||||
WHERE CveConvenio = @CveConvenio
|
||||
)
|
||||
BEGIN
|
||||
SET @ErrorMostrar = 'No se encontró el convenio solicitado.';
|
||||
SET @ErrorTipo = 2;
|
||||
RETURN;
|
||||
END;
|
||||
|
||||
;WITH PagadoRecibo AS
|
||||
(
|
||||
SELECT
|
||||
PR.CveConvenioRecibo,
|
||||
SUM(PR.ImporteAplicado) AS ImportePagado
|
||||
FROM dbo.ConveniosPagosRecibos AS PR
|
||||
GROUP BY PR.CveConvenioRecibo
|
||||
),
|
||||
Totales AS
|
||||
(
|
||||
SELECT
|
||||
D.CveConvenio,
|
||||
SUM(R.Importe) AS ImporteConvenio,
|
||||
SUM(ISNULL(P.ImportePagado, 0)) AS ImportePagado,
|
||||
SUM(R.Importe - ISNULL(P.ImportePagado, 0)) AS SaldoPendiente
|
||||
FROM dbo.ConveniosDetalle AS D
|
||||
LEFT JOIN dbo.ConveniosRecibos AS R ON R.CveConvenioDetalle = D.CveConvenioDetalle
|
||||
LEFT JOIN PagadoRecibo AS P ON P.CveConvenioRecibo = R.CveConvenioRecibo
|
||||
GROUP BY D.CveConvenio
|
||||
)
|
||||
SELECT
|
||||
C.CveConvenio,
|
||||
C.CveTipoTramite,
|
||||
TT.TipoTramite,
|
||||
C.CveCliente,
|
||||
C.CveFraccionamientoEtapa,
|
||||
C.NumeroConvenio,
|
||||
C.NumeroOficio,
|
||||
CL.Nombre AS Cliente,
|
||||
F.Fraccionamiento,
|
||||
FE.Etapa,
|
||||
C.Estatus,
|
||||
C.FechaConvenio,
|
||||
C.ViviendasAutorizadas,
|
||||
C.ViviendasEnConvenio,
|
||||
C.ViviendasPendientes,
|
||||
C.ViviendasContratadas,
|
||||
C.Observaciones,
|
||||
ISNULL(T.ImporteConvenio, 0) AS ImporteConvenio,
|
||||
ISNULL(T.ImportePagado, 0) AS ImportePagado,
|
||||
ISNULL(T.SaldoPendiente, 0) AS SaldoPendiente
|
||||
FROM dbo.Convenios AS C
|
||||
LEFT JOIN dbo.Tra_TiposTramite AS TT ON TT.CveTipoTramite = C.CveTipoTramite
|
||||
INNER JOIN dbo.FraccionamientosEtapas AS FE ON FE.CveFraccionamientoEtapa = C.CveFraccionamientoEtapa
|
||||
INNER JOIN dbo.Fraccionamientos AS F ON F.CveFraccionamiento = FE.CveFraccionamiento
|
||||
INNER JOIN dbo.Clientes AS CL ON CL.CveCliente = C.CveCliente
|
||||
LEFT JOIN Totales AS T ON T.CveConvenio = C.CveConvenio
|
||||
WHERE C.CveConvenio = @CveConvenio;
|
||||
|
||||
SELECT
|
||||
D.CveConvenioDetalle,
|
||||
D.CveConvenioConcepto,
|
||||
CC.Concepto,
|
||||
D.Importe,
|
||||
D.Tipo,
|
||||
D.NumeroPagos
|
||||
FROM dbo.ConveniosDetalle AS D
|
||||
INNER JOIN dbo.ConveniosConceptos AS CC ON CC.CveConvenioConcepto = D.CveConvenioConcepto
|
||||
WHERE D.CveConvenio = @CveConvenio
|
||||
ORDER BY D.CveConvenioDetalle;
|
||||
|
||||
;WITH Pagado AS
|
||||
(
|
||||
SELECT
|
||||
PR.CveConvenioRecibo,
|
||||
SUM(PR.ImporteAplicado) AS ImportePagado
|
||||
FROM dbo.ConveniosPagosRecibos AS PR
|
||||
GROUP BY PR.CveConvenioRecibo
|
||||
)
|
||||
SELECT
|
||||
R.CveConvenioRecibo,
|
||||
R.CveConvenioDetalle,
|
||||
R.NumeroRecibo,
|
||||
R.Importe,
|
||||
ISNULL(P.ImportePagado, 0) AS ImportePagado,
|
||||
R.Importe - ISNULL(P.ImportePagado, 0) AS SaldoPendiente,
|
||||
R.FechaVencimiento,
|
||||
R.Estatus
|
||||
FROM dbo.ConveniosRecibos AS R
|
||||
INNER JOIN dbo.ConveniosDetalle AS D ON D.CveConvenioDetalle = R.CveConvenioDetalle
|
||||
LEFT JOIN Pagado AS P ON P.CveConvenioRecibo = R.CveConvenioRecibo
|
||||
WHERE D.CveConvenio = @CveConvenio
|
||||
ORDER BY
|
||||
R.CveConvenioDetalle,
|
||||
R.FechaVencimiento,
|
||||
R.CveConvenioRecibo;
|
||||
|
||||
SET @Return = 1;
|
||||
END TRY
|
||||
BEGIN CATCH
|
||||
SET @ErrorMostrar =
|
||||
'Ocurrió un error al consultar el detalle del convenio; favor de contactar a Sistemas.';
|
||||
SET @ErrorTipo = 1;
|
||||
SET @Return = 0;
|
||||
|
||||
DECLARE @ErrorTecnico nvarchar(2048) = CONCAT(
|
||||
'Número: ', ERROR_NUMBER(),
|
||||
'; Procedimiento: ', COALESCE(
|
||||
ERROR_PROCEDURE(),
|
||||
'PA_Tra_ConvenioGet'
|
||||
),
|
||||
'; Línea: ', ERROR_LINE(),
|
||||
'; Detalle: ', ERROR_MESSAGE()
|
||||
);
|
||||
|
||||
RAISERROR(N'%s', 10, 1, @ErrorTecnico);
|
||||
END CATCH;
|
||||
END;
|
||||
|
||||
GO
|
||||
146
Documentos_Compartidos_Etapa_Estructura_20261002.sql
Normal file
@@ -0,0 +1,146 @@
|
||||
/*
|
||||
Consolidación de documentos compartidos por etapa y tipo de documento.
|
||||
Preparado para revisión; no ejecutado.
|
||||
Requiere la migración Etapa_TipoTramite_20261002 ya instalada.
|
||||
Ejecutar estructura y procedimientos en la misma transacción de instalación,
|
||||
detenerse ante errores y confirmar sólo tras verificar los resultados.
|
||||
No borra archivos ni filas históricas de documentos.
|
||||
Las copias idénticas quedan como versiones históricas; se conserva una vigente.
|
||||
Las configuraciones particulares idénticas se consolidan en una por etapa.
|
||||
Si hubo ediciones diferentes por trámite, se detiene para no elegir una
|
||||
aprobación, nota o marca de requerido arbitraria.
|
||||
Convenios no se modifican.
|
||||
*/
|
||||
SET NOCOUNT ON;
|
||||
|
||||
IF @@TRANCOUNT = 0
|
||||
THROW 51000, 'Abrir una transacción de instalación antes de ejecutar y revertirla ante cualquier error.', 1;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM dbo.Tra_DocumentosSolicitud AS D
|
||||
INNER JOIN dbo.Tra_DocumentosSolicitud AS O ON O.CveFraccionamientoEtapa = D.CveFraccionamientoEtapa
|
||||
AND O.CveTipoDocumento = D.CveTipoDocumento
|
||||
AND O.CveDocumentoSolicitud < D.CveDocumentoSolicitud
|
||||
WHERE D.EsActivo = 1
|
||||
AND O.EsActivo = 1
|
||||
AND EXISTS
|
||||
(
|
||||
SELECT D.NombreArchivo, D.NombreArchivoFisico, D.RutaArchivo,
|
||||
D.ContentType, D.TamanoBytes, D.ComentarioCliente,
|
||||
D.ComentarioAdministrativo, D.EsAprobado, D.CveUsuarioCarga,
|
||||
D.CveUsuarioRevisa, D.FechaRevision, D.FechaAlta, D.UltimaNota,
|
||||
D.FechaDocumento, D.FechaVencimiento, D.Vencido
|
||||
EXCEPT
|
||||
SELECT O.NombreArchivo, O.NombreArchivoFisico, O.RutaArchivo,
|
||||
O.ContentType, O.TamanoBytes, O.ComentarioCliente,
|
||||
O.ComentarioAdministrativo, O.EsAprobado, O.CveUsuarioCarga,
|
||||
O.CveUsuarioRevisa, O.FechaRevision, O.FechaAlta, O.UltimaNota,
|
||||
O.FechaDocumento, O.FechaVencimiento, O.Vencido
|
||||
)
|
||||
)
|
||||
THROW 51000, 'Hay versiones vigentes con datos distintos por trámite. Revisarlas antes de consolidar; no se eliminaron documentos.', 1;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM dbo.Tra_SolicitudDocumentoConfiguracion
|
||||
GROUP BY CveFraccionamientoEtapa, CveTipoDocumento
|
||||
HAVING MIN(CONVERT(int, EsRequerido)) <> MAX(CONVERT(int, EsRequerido))
|
||||
OR MIN(CONVERT(int, EsCliente)) <> MAX(CONVERT(int, EsCliente))
|
||||
OR MIN(CONVERT(int, TieneVigencia)) <> MAX(CONVERT(int, TieneVigencia))
|
||||
OR MIN(CONVERT(int, EsActivo)) <> MAX(CONVERT(int, EsActivo))
|
||||
OR MIN(Orden) <> MAX(Orden)
|
||||
)
|
||||
THROW 51000, 'Hay configuraciones manuales distintas por trámite. Resolverlas antes de consolidar la marca de la etapa.', 1;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1 FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Tra_DocumentosSolicitud')
|
||||
AND name = 'UX_Tra_DocumentosSolicitud_Etapa_Tramite_Documento'
|
||||
)
|
||||
DROP INDEX UX_Tra_DocumentosSolicitud_Etapa_Tramite_Documento
|
||||
ON dbo.Tra_DocumentosSolicitud;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1 FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Tra_SolicitudDocumentoConfiguracion')
|
||||
AND name = 'UX_Tra_ConfiguracionDocumento_Etapa_Tramite_Documento'
|
||||
)
|
||||
DROP INDEX UX_Tra_ConfiguracionDocumento_Etapa_Tramite_Documento
|
||||
ON dbo.Tra_SolicitudDocumentoConfiguracion;
|
||||
|
||||
-- Las columnas se conservan por compatibilidad de esquema; ya no son propietarias.
|
||||
ALTER TABLE dbo.Tra_DocumentosSolicitud ALTER COLUMN CveTipoTramite int NULL;
|
||||
ALTER TABLE dbo.Tra_SolicitudDocumentoConfiguracion ALTER COLUMN CveTipoTramite int NULL;
|
||||
|
||||
;WITH Versiones AS
|
||||
(
|
||||
SELECT
|
||||
CveDocumentoSolicitud,
|
||||
ROW_NUMBER() OVER
|
||||
(
|
||||
PARTITION BY CveFraccionamientoEtapa, CveTipoDocumento
|
||||
ORDER BY CveDocumentoSolicitud
|
||||
) AS NumeroVersion
|
||||
FROM dbo.Tra_DocumentosSolicitud
|
||||
WHERE EsActivo = 1
|
||||
)
|
||||
UPDATE D
|
||||
SET EsActivo = 0
|
||||
FROM dbo.Tra_DocumentosSolicitud AS D
|
||||
INNER JOIN Versiones AS V ON V.CveDocumentoSolicitud = D.CveDocumentoSolicitud
|
||||
WHERE V.NumeroVersion > 1;
|
||||
|
||||
-- Sólo se retiran copias de configuración cuyos valores son idénticos.
|
||||
;WITH Configuraciones AS
|
||||
(
|
||||
SELECT
|
||||
CveConfiguracionDocumento,
|
||||
ROW_NUMBER() OVER
|
||||
(
|
||||
PARTITION BY CveFraccionamientoEtapa, CveTipoDocumento
|
||||
ORDER BY CveConfiguracionDocumento
|
||||
) AS NumeroConfiguracion
|
||||
FROM dbo.Tra_SolicitudDocumentoConfiguracion
|
||||
)
|
||||
DELETE C
|
||||
FROM dbo.Tra_SolicitudDocumentoConfiguracion AS C
|
||||
INNER JOIN Configuraciones AS O ON O.CveConfiguracionDocumento = C.CveConfiguracionDocumento
|
||||
WHERE O.NumeroConfiguracion > 1;
|
||||
|
||||
UPDATE dbo.Tra_DocumentosSolicitud
|
||||
SET CveTipoTramite = NULL
|
||||
WHERE CveTipoTramite IS NOT NULL;
|
||||
|
||||
UPDATE dbo.Tra_SolicitudDocumentoConfiguracion
|
||||
SET CveTipoTramite = NULL
|
||||
WHERE CveTipoTramite IS NOT NULL;
|
||||
|
||||
IF NOT EXISTS
|
||||
(
|
||||
SELECT 1 FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Tra_DocumentosSolicitud')
|
||||
AND name = 'UX_Tra_DocumentosSolicitud_Etapa_TipoDocumento'
|
||||
)
|
||||
CREATE UNIQUE INDEX UX_Tra_DocumentosSolicitud_Etapa_TipoDocumento
|
||||
ON dbo.Tra_DocumentosSolicitud (CveFraccionamientoEtapa, CveTipoDocumento)
|
||||
WHERE EsActivo = 1;
|
||||
|
||||
IF NOT EXISTS
|
||||
(
|
||||
SELECT 1 FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Tra_SolicitudDocumentoConfiguracion')
|
||||
AND name = 'UX_Tra_ConfiguracionDocumento_Etapa_Documento'
|
||||
)
|
||||
CREATE UNIQUE INDEX UX_Tra_ConfiguracionDocumento_Etapa_Documento
|
||||
ON dbo.Tra_SolicitudDocumentoConfiguracion (CveFraccionamientoEtapa, CveTipoDocumento);
|
||||
|
||||
IF EXISTS (SELECT 1 FROM sys.foreign_keys WHERE name = 'FK_Tra_DocumentosSolicitud_TipoTramite')
|
||||
ALTER TABLE dbo.Tra_DocumentosSolicitud DROP CONSTRAINT FK_Tra_DocumentosSolicitud_TipoTramite;
|
||||
|
||||
IF EXISTS (SELECT 1 FROM sys.foreign_keys WHERE name = 'FK_Tra_ConfiguracionDocumento_TipoTramite')
|
||||
ALTER TABLE dbo.Tra_SolicitudDocumentoConfiguracion DROP CONSTRAINT FK_Tra_ConfiguracionDocumento_TipoTramite;
|
||||
2276
Documentos_Compartidos_Etapa_Procedimientos_20261002.sql
Normal file
340
Documentos_Etapa_TipoTramite_Estructura_20261002.sql
Normal file
@@ -0,0 +1,340 @@
|
||||
/*
|
||||
Preparación únicamente; no ejecutado.
|
||||
Requiere Documentos_Etapa_Estructura_20260927.sql ya instalado.
|
||||
Instalar estructura, procedimientos y aplicación en una ventana coordinada.
|
||||
El ejecutor debe abrir una transacción, detenerse y revertir ante cualquier
|
||||
error, y confirmar sólo después de instalar y verificar todos los scripts.
|
||||
Los registros sin solicitud se conservan en todos los tipos activos aplicables.
|
||||
Se duplica únicamente la metadata: archivos, fechas, revisiones y versiones
|
||||
conservan su contenido. El identificador original queda en el menor tipo;
|
||||
no significa que ese tipo tenga prioridad funcional.
|
||||
GIS histórico 2 se normaliza al documento configurado 1016 / trámite 12.
|
||||
Las asignaciones directas existentes no vuelven a expandirse al reinstalar.
|
||||
*/
|
||||
SET NOCOUNT ON;
|
||||
|
||||
IF @@TRANCOUNT = 0
|
||||
THROW 51000, 'Abrir una transacción de instalación antes de ejecutar este script y revertirla ante cualquier error.', 1;
|
||||
|
||||
SELECT
|
||||
D.CveDocumentoSolicitud,
|
||||
D.CveFraccionamientoEtapa,
|
||||
CASE WHEN D.CveTipoDocumento = 2 THEN 1016 ELSE D.CveTipoDocumento END AS CveTipoDocumento,
|
||||
S.CveTipoTramite AS TipoSolicitud,
|
||||
CONVERT(int, NULL) AS TipoDirecto
|
||||
INTO #OrigenDocumentos
|
||||
FROM dbo.Tra_DocumentosSolicitud AS D
|
||||
LEFT JOIN dbo.Tra_Solicitudes AS S ON S.CveSolicitud = D.CveSolicitud;
|
||||
|
||||
IF COL_LENGTH('dbo.Tra_DocumentosSolicitud', 'CveTipoTramite') IS NOT NULL
|
||||
EXEC sys.sp_executesql N'
|
||||
UPDATE O
|
||||
SET TipoDirecto = D.CveTipoTramite,
|
||||
CveTipoDocumento = D.CveTipoDocumento
|
||||
FROM #OrigenDocumentos AS O
|
||||
INNER JOIN dbo.Tra_DocumentosSolicitud AS D ON D.CveDocumentoSolicitud = O.CveDocumentoSolicitud
|
||||
WHERE D.CveTipoTramite IS NOT NULL;';
|
||||
|
||||
SELECT DISTINCT
|
||||
O.CveDocumentoSolicitud,
|
||||
O.CveFraccionamientoEtapa,
|
||||
O.CveTipoDocumento,
|
||||
COALESCE(O.TipoDirecto, O.TipoSolicitud, T.CveTipoTramite) AS CveTipoTramite
|
||||
INTO #TiposDocumentos
|
||||
FROM #OrigenDocumentos AS O
|
||||
LEFT JOIN dbo.Tra_TiposTramiteDocumento AS T ON T.CveTipoDocumento = O.CveTipoDocumento
|
||||
AND T.EsActivo = 1
|
||||
AND O.TipoDirecto IS NULL
|
||||
AND O.TipoSolicitud IS NULL;
|
||||
|
||||
IF EXISTS (SELECT 1 FROM #TiposDocumentos WHERE CveTipoTramite IS NULL)
|
||||
BEGIN
|
||||
SELECT *
|
||||
FROM #TiposDocumentos
|
||||
WHERE CveTipoTramite IS NULL;
|
||||
THROW 51000, 'Hay documentos sin tipo de trámite aplicable. Resolver su correspondencia y revertir la instalación.', 1;
|
||||
END;
|
||||
|
||||
SELECT
|
||||
D.CveConfiguracionDocumento,
|
||||
D.CveFraccionamientoEtapa,
|
||||
CASE WHEN D.CveTipoDocumento = 2 THEN 1016 ELSE D.CveTipoDocumento END AS CveTipoDocumento,
|
||||
S.CveTipoTramite AS TipoSolicitud,
|
||||
CONVERT(int, NULL) AS TipoDirecto
|
||||
INTO #OrigenConfiguraciones
|
||||
FROM dbo.Tra_SolicitudDocumentoConfiguracion AS D
|
||||
LEFT JOIN dbo.Tra_Solicitudes AS S ON S.CveSolicitud = D.CveSolicitud;
|
||||
|
||||
IF COL_LENGTH('dbo.Tra_SolicitudDocumentoConfiguracion', 'CveTipoTramite') IS NOT NULL
|
||||
EXEC sys.sp_executesql N'
|
||||
UPDATE O
|
||||
SET TipoDirecto = D.CveTipoTramite,
|
||||
CveTipoDocumento = D.CveTipoDocumento
|
||||
FROM #OrigenConfiguraciones AS O
|
||||
INNER JOIN dbo.Tra_SolicitudDocumentoConfiguracion AS D ON D.CveConfiguracionDocumento = O.CveConfiguracionDocumento
|
||||
WHERE D.CveTipoTramite IS NOT NULL;';
|
||||
|
||||
SELECT DISTINCT
|
||||
O.CveConfiguracionDocumento,
|
||||
O.CveFraccionamientoEtapa,
|
||||
O.CveTipoDocumento,
|
||||
COALESCE(O.TipoDirecto, O.TipoSolicitud, T.CveTipoTramite) AS CveTipoTramite
|
||||
INTO #TiposConfiguraciones
|
||||
FROM #OrigenConfiguraciones AS O
|
||||
LEFT JOIN dbo.Tra_TiposTramiteDocumento AS T ON T.CveTipoDocumento = O.CveTipoDocumento
|
||||
AND T.EsActivo = 1
|
||||
AND O.TipoDirecto IS NULL
|
||||
AND O.TipoSolicitud IS NULL;
|
||||
|
||||
IF EXISTS (SELECT 1 FROM #TiposConfiguraciones WHERE CveTipoTramite IS NULL)
|
||||
BEGIN
|
||||
SELECT *
|
||||
FROM #TiposConfiguraciones
|
||||
WHERE CveTipoTramite IS NULL;
|
||||
THROW 51000, 'Hay configuraciones sin tipo de trámite aplicable. Resolver su correspondencia y revertir la instalación.', 1;
|
||||
END;
|
||||
|
||||
-- Nunca reemplazar una configuración específica con otra compartida.
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM #TiposConfiguraciones
|
||||
GROUP BY CveFraccionamientoEtapa, CveTipoTramite, CveTipoDocumento
|
||||
HAVING COUNT(*) > 1
|
||||
)
|
||||
BEGIN
|
||||
SELECT CveFraccionamientoEtapa, CveTipoTramite, CveTipoDocumento
|
||||
FROM #TiposConfiguraciones
|
||||
GROUP BY CveFraccionamientoEtapa, CveTipoTramite, CveTipoDocumento
|
||||
HAVING COUNT(*) > 1;
|
||||
THROW 51000, 'Hay configuraciones que convergen al mismo destino. Resolverlas conservando sus valores antes de instalar.', 1;
|
||||
END;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM #TiposDocumentos AS T
|
||||
INNER JOIN dbo.Tra_DocumentosSolicitud AS D ON D.CveDocumentoSolicitud = T.CveDocumentoSolicitud
|
||||
WHERE D.EsActivo = 1
|
||||
GROUP BY T.CveFraccionamientoEtapa, T.CveTipoTramite, T.CveTipoDocumento
|
||||
HAVING COUNT(*) > 1
|
||||
)
|
||||
THROW 51000, 'Hay versiones vigentes que convergen al mismo destino. Resolver su vigencia antes de instalar.', 1;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Tra_DocumentosSolicitud')
|
||||
AND name = 'UX_Tra_DocumentosSolicitud_Etapa_TipoDocumento'
|
||||
)
|
||||
DROP INDEX UX_Tra_DocumentosSolicitud_Etapa_TipoDocumento ON dbo.Tra_DocumentosSolicitud;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Tra_SolicitudDocumentoConfiguracion')
|
||||
AND name = 'UX_Tra_ConfiguracionDocumento_Solicitud'
|
||||
)
|
||||
DROP INDEX UX_Tra_ConfiguracionDocumento_Solicitud ON dbo.Tra_SolicitudDocumentoConfiguracion;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Tra_SolicitudDocumentoConfiguracion')
|
||||
AND name = 'UX_Tra_ConfiguracionDocumento_Etapa'
|
||||
)
|
||||
DROP INDEX UX_Tra_ConfiguracionDocumento_Etapa ON dbo.Tra_SolicitudDocumentoConfiguracion;
|
||||
|
||||
IF COL_LENGTH('dbo.Tra_DocumentosSolicitud', 'CveTipoTramite') IS NULL
|
||||
ALTER TABLE dbo.Tra_DocumentosSolicitud ADD CveTipoTramite int NULL;
|
||||
|
||||
-- El SQL dinámico compila después de agregar la columna.
|
||||
EXEC sys.sp_executesql N'
|
||||
;WITH DestinoOriginal AS
|
||||
(
|
||||
SELECT CveDocumentoSolicitud, MIN(CveTipoTramite) AS CveTipoTramite
|
||||
FROM #TiposDocumentos
|
||||
GROUP BY CveDocumentoSolicitud
|
||||
)
|
||||
UPDATE D
|
||||
SET CveTipoTramite = T.CveTipoTramite,
|
||||
CveTipoDocumento = T.CveTipoDocumento
|
||||
FROM dbo.Tra_DocumentosSolicitud AS D
|
||||
INNER JOIN DestinoOriginal AS O ON O.CveDocumentoSolicitud = D.CveDocumentoSolicitud
|
||||
INNER JOIN #TiposDocumentos AS T ON T.CveDocumentoSolicitud = O.CveDocumentoSolicitud
|
||||
AND T.CveTipoTramite = O.CveTipoTramite;
|
||||
|
||||
INSERT INTO dbo.Tra_DocumentosSolicitud
|
||||
(
|
||||
CveFraccionamientoEtapa,
|
||||
CveTipoDocumento,
|
||||
CveTipoTramite,
|
||||
CveSolicitud,
|
||||
NombreArchivo,
|
||||
NombreArchivoFisico,
|
||||
RutaArchivo,
|
||||
ContentType,
|
||||
TamanoBytes,
|
||||
ComentarioCliente,
|
||||
ComentarioAdministrativo,
|
||||
EsAprobado,
|
||||
CveUsuarioCarga,
|
||||
CveUsuarioRevisa,
|
||||
FechaRevision,
|
||||
FechaAlta,
|
||||
UltimaNota,
|
||||
FechaDocumento,
|
||||
FechaVencimiento,
|
||||
EsActivo,
|
||||
Vencido
|
||||
)
|
||||
SELECT
|
||||
T.CveFraccionamientoEtapa,
|
||||
T.CveTipoDocumento,
|
||||
T.CveTipoTramite,
|
||||
D.CveSolicitud,
|
||||
D.NombreArchivo,
|
||||
D.NombreArchivoFisico,
|
||||
D.RutaArchivo,
|
||||
D.ContentType,
|
||||
D.TamanoBytes,
|
||||
D.ComentarioCliente,
|
||||
D.ComentarioAdministrativo,
|
||||
D.EsAprobado,
|
||||
D.CveUsuarioCarga,
|
||||
D.CveUsuarioRevisa,
|
||||
D.FechaRevision,
|
||||
D.FechaAlta,
|
||||
D.UltimaNota,
|
||||
D.FechaDocumento,
|
||||
D.FechaVencimiento,
|
||||
D.EsActivo,
|
||||
D.Vencido
|
||||
FROM dbo.Tra_DocumentosSolicitud AS D
|
||||
INNER JOIN #TiposDocumentos AS T ON T.CveDocumentoSolicitud = D.CveDocumentoSolicitud
|
||||
WHERE T.CveTipoTramite <> D.CveTipoTramite;
|
||||
|
||||
ALTER TABLE dbo.Tra_DocumentosSolicitud ALTER COLUMN CveTipoTramite int NOT NULL;';
|
||||
|
||||
IF COL_LENGTH('dbo.Tra_SolicitudDocumentoConfiguracion', 'CveTipoTramite') IS NULL
|
||||
ALTER TABLE dbo.Tra_SolicitudDocumentoConfiguracion ADD CveTipoTramite int NULL;
|
||||
|
||||
-- El SQL dinámico compila después de agregar la columna.
|
||||
EXEC sys.sp_executesql N'
|
||||
;WITH DestinoOriginal AS
|
||||
(
|
||||
SELECT CveConfiguracionDocumento, MIN(CveTipoTramite) AS CveTipoTramite
|
||||
FROM #TiposConfiguraciones
|
||||
GROUP BY CveConfiguracionDocumento
|
||||
)
|
||||
UPDATE D
|
||||
SET CveTipoTramite = T.CveTipoTramite,
|
||||
CveTipoDocumento = T.CveTipoDocumento
|
||||
FROM dbo.Tra_SolicitudDocumentoConfiguracion AS D
|
||||
INNER JOIN DestinoOriginal AS O ON O.CveConfiguracionDocumento = D.CveConfiguracionDocumento
|
||||
INNER JOIN #TiposConfiguraciones AS T ON T.CveConfiguracionDocumento = O.CveConfiguracionDocumento
|
||||
AND T.CveTipoTramite = O.CveTipoTramite;
|
||||
|
||||
INSERT INTO dbo.Tra_SolicitudDocumentoConfiguracion
|
||||
(
|
||||
CveFraccionamientoEtapa,
|
||||
CveTipoDocumento,
|
||||
CveTipoTramite,
|
||||
CveSolicitud,
|
||||
EsRequerido,
|
||||
EsCliente,
|
||||
TieneVigencia,
|
||||
Orden,
|
||||
EsActivo
|
||||
)
|
||||
SELECT
|
||||
T.CveFraccionamientoEtapa,
|
||||
T.CveTipoDocumento,
|
||||
T.CveTipoTramite,
|
||||
D.CveSolicitud,
|
||||
D.EsRequerido,
|
||||
D.EsCliente,
|
||||
D.TieneVigencia,
|
||||
D.Orden,
|
||||
D.EsActivo
|
||||
FROM dbo.Tra_SolicitudDocumentoConfiguracion AS D
|
||||
INNER JOIN #TiposConfiguraciones AS T ON T.CveConfiguracionDocumento = D.CveConfiguracionDocumento
|
||||
WHERE T.CveTipoTramite <> D.CveTipoTramite;
|
||||
|
||||
ALTER TABLE dbo.Tra_SolicitudDocumentoConfiguracion ALTER COLUMN CveTipoTramite int NOT NULL;';
|
||||
|
||||
IF NOT EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Tra_DocumentosSolicitud')
|
||||
AND name = 'UX_Tra_DocumentosSolicitud_Etapa_Tramite_Documento'
|
||||
)
|
||||
EXEC sys.sp_executesql N'
|
||||
CREATE UNIQUE INDEX UX_Tra_DocumentosSolicitud_Etapa_Tramite_Documento
|
||||
ON dbo.Tra_DocumentosSolicitud (CveFraccionamientoEtapa, CveTipoTramite, CveTipoDocumento)
|
||||
WHERE EsActivo = 1;';
|
||||
|
||||
IF NOT EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM sys.indexes
|
||||
WHERE object_id = OBJECT_ID('dbo.Tra_SolicitudDocumentoConfiguracion')
|
||||
AND name = 'UX_Tra_ConfiguracionDocumento_Etapa_Tramite_Documento'
|
||||
)
|
||||
EXEC sys.sp_executesql N'
|
||||
CREATE UNIQUE INDEX UX_Tra_ConfiguracionDocumento_Etapa_Tramite_Documento
|
||||
ON dbo.Tra_SolicitudDocumentoConfiguracion
|
||||
(CveFraccionamientoEtapa, CveTipoTramite, CveTipoDocumento);';
|
||||
|
||||
IF NOT EXISTS (SELECT 1 FROM sys.foreign_keys WHERE name = 'FK_Tra_DocumentosSolicitud_TipoTramite')
|
||||
EXEC sys.sp_executesql N'
|
||||
ALTER TABLE dbo.Tra_DocumentosSolicitud WITH CHECK
|
||||
ADD CONSTRAINT FK_Tra_DocumentosSolicitud_TipoTramite
|
||||
FOREIGN KEY (CveTipoTramite) REFERENCES dbo.Tra_TiposTramite (CveTipoTramite);';
|
||||
|
||||
IF NOT EXISTS (SELECT 1 FROM sys.foreign_keys WHERE name = 'FK_Tra_ConfiguracionDocumento_TipoTramite')
|
||||
EXEC sys.sp_executesql N'
|
||||
ALTER TABLE dbo.Tra_SolicitudDocumentoConfiguracion WITH CHECK
|
||||
ADD CONSTRAINT FK_Tra_ConfiguracionDocumento_TipoTramite
|
||||
FOREIGN KEY (CveTipoTramite) REFERENCES dbo.Tra_TiposTramite (CveTipoTramite);';
|
||||
|
||||
-- CveSolicitud se conserva sólo como referencia histórica, sin dependencia relacional.
|
||||
DECLARE @QuitarRelaciones nvarchar(max) = N'';
|
||||
SELECT @QuitarRelaciones = @QuitarRelaciones
|
||||
+ N'ALTER TABLE ' + QUOTENAME(OBJECT_SCHEMA_NAME(F.parent_object_id))
|
||||
+ N'.' + QUOTENAME(OBJECT_NAME(F.parent_object_id))
|
||||
+ N' DROP CONSTRAINT ' + QUOTENAME(F.name) + N';'
|
||||
FROM sys.foreign_keys AS F
|
||||
WHERE F.parent_object_id IN
|
||||
(OBJECT_ID('dbo.Tra_DocumentosSolicitud'), OBJECT_ID('dbo.Tra_SolicitudDocumentoConfiguracion'))
|
||||
AND F.referenced_object_id = OBJECT_ID('dbo.Tra_Solicitudes');
|
||||
IF @QuitarRelaciones <> N''
|
||||
EXEC sys.sp_executesql @QuitarRelaciones;
|
||||
|
||||
INSERT INTO dbo.Bit_Campos
|
||||
(CveTabla, NombreCampoSQL, NombreMostrar, MostrarEnBitacora, TipoDatoSQL, Activo)
|
||||
SELECT
|
||||
T.CveTabla,
|
||||
'CveTipoTramite',
|
||||
'Tipo de trámite',
|
||||
1,
|
||||
'int',
|
||||
1
|
||||
FROM dbo.Bit_Tablas AS T
|
||||
WHERE T.NombreTablaSQL IN ('Tra_DocumentosSolicitud', 'Tra_SolicitudDocumentoConfiguracion')
|
||||
AND NOT EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM dbo.Bit_Campos AS C
|
||||
WHERE C.CveTabla = T.CveTabla
|
||||
AND C.NombreCampoSQL = 'CveTipoTramite'
|
||||
);
|
||||
|
||||
DROP TABLE #TiposDocumentos;
|
||||
DROP TABLE #OrigenDocumentos;
|
||||
DROP TABLE #TiposConfiguraciones;
|
||||
DROP TABLE #OrigenConfiguraciones;
|
||||
2018
Documentos_Etapa_TipoTramite_Procedimientos_20261002.sql
Normal file
110
GIS_Capas_Configuracion_20261002.sql
Normal file
@@ -0,0 +1,110 @@
|
||||
-- Preparado para revisión. La instalación requiere autorización independiente.
|
||||
-- La configuración se conserva por etapa y nombre de capa del archivo original.
|
||||
IF OBJECT_ID(N'dbo.FraccionamientosEtapasGISCapas', N'U') IS NULL
|
||||
BEGIN
|
||||
CREATE TABLE dbo.FraccionamientosEtapasGISCapas
|
||||
(
|
||||
CveFraccionamientoEtapa int NOT NULL,
|
||||
NombreCapa nvarchar(250) COLLATE Modern_Spanish_CS_AS NOT NULL,
|
||||
TipoCapa nvarchar(20) COLLATE Modern_Spanish_CS_AS NOT NULL,
|
||||
Color nvarchar(7) COLLATE Modern_Spanish_CS_AS NOT NULL,
|
||||
EsVisible bit NOT NULL,
|
||||
CveUsuarioModifica int NOT NULL,
|
||||
FechaModificacion datetime2 NOT NULL,
|
||||
CONSTRAINT PK_FraccionamientosEtapasGISCapas
|
||||
PRIMARY KEY (CveFraccionamientoEtapa, NombreCapa),
|
||||
CONSTRAINT FK_FraccionamientosEtapasGISCapas_Etapa
|
||||
FOREIGN KEY (CveFraccionamientoEtapa)
|
||||
REFERENCES dbo.FraccionamientosEtapas (CveFraccionamientoEtapa),
|
||||
CONSTRAINT CK_FraccionamientosEtapasGISCapas_Tipo
|
||||
CHECK (TipoCapa IN (N'Agua', N'Drenaje', N'Lotificacion', N'Pozos', N'Otros')),
|
||||
CONSTRAINT CK_FraccionamientosEtapasGISCapas_Color
|
||||
CHECK (LEN(Color) = 7 AND Color COLLATE Latin1_General_BIN2
|
||||
LIKE N'#[0-9A-Fa-f][0-9A-Fa-f][0-9A-Fa-f][0-9A-Fa-f][0-9A-Fa-f][0-9A-Fa-f]')
|
||||
);
|
||||
END;
|
||||
GO
|
||||
|
||||
CREATE OR ALTER PROCEDURE dbo.PA_Fraccionamientos_EtapaGISCapasList
|
||||
@CveFraccionamientoEtapa int,
|
||||
@CveUsuarioEjecuta int,
|
||||
@ErrorMostrar varchar(max) OUTPUT,
|
||||
@ErrorTipo int OUTPUT,
|
||||
@Return bit OUTPUT
|
||||
AS
|
||||
BEGIN
|
||||
SET NOCOUNT ON;
|
||||
SELECT @ErrorMostrar = NULL, @ErrorTipo = 0, @Return = 0;
|
||||
BEGIN TRY
|
||||
SELECT NombreCapa, TipoCapa, Color, EsVisible
|
||||
FROM dbo.FraccionamientosEtapasGISCapas
|
||||
WHERE CveFraccionamientoEtapa = @CveFraccionamientoEtapa;
|
||||
|
||||
SET @Return = 1;
|
||||
END TRY
|
||||
BEGIN CATCH
|
||||
SELECT
|
||||
@ErrorMostrar = 'No fue posible consultar la configuración de capas GIS.',
|
||||
@ErrorTipo = 1,
|
||||
@Return = 0;
|
||||
DECLARE @ErrorTecnico nvarchar(2048) = CONCAT(
|
||||
'Número: ', ERROR_NUMBER(), '; Procedimiento: ', ERROR_PROCEDURE(),
|
||||
'; Línea: ', ERROR_LINE(), '; Detalle: ', ERROR_MESSAGE());
|
||||
RAISERROR(N'%s', 10, 1, @ErrorTecnico);
|
||||
END CATCH;
|
||||
END;
|
||||
GO
|
||||
|
||||
CREATE OR ALTER PROCEDURE dbo.PA_Fraccionamientos_EtapaGISCapasSave
|
||||
@CveFraccionamientoEtapa int,
|
||||
@NombreCapa nvarchar(250),
|
||||
@TipoCapa nvarchar(20),
|
||||
@Color nvarchar(7),
|
||||
@EsVisible bit,
|
||||
@CveUsuarioEjecuta int,
|
||||
@ErrorMostrar varchar(max) OUTPUT,
|
||||
@ErrorTipo int OUTPUT,
|
||||
@Return bit OUTPUT
|
||||
AS
|
||||
BEGIN
|
||||
SET NOCOUNT ON;
|
||||
SELECT @ErrorMostrar = NULL, @ErrorTipo = 0, @Return = 0;
|
||||
BEGIN TRY
|
||||
-- El servicio mantiene la transacción ambiental para proteger este upsert.
|
||||
UPDATE dbo.FraccionamientosEtapasGISCapas WITH (UPDLOCK, HOLDLOCK)
|
||||
SET TipoCapa = @TipoCapa,
|
||||
Color = @Color,
|
||||
EsVisible = @EsVisible,
|
||||
CveUsuarioModifica = @CveUsuarioEjecuta,
|
||||
FechaModificacion = SYSDATETIME()
|
||||
WHERE CveFraccionamientoEtapa = @CveFraccionamientoEtapa
|
||||
AND NombreCapa = @NombreCapa;
|
||||
|
||||
IF @@ROWCOUNT = 0
|
||||
BEGIN
|
||||
INSERT INTO dbo.FraccionamientosEtapasGISCapas
|
||||
(
|
||||
CveFraccionamientoEtapa, NombreCapa, TipoCapa, Color,
|
||||
EsVisible, CveUsuarioModifica, FechaModificacion
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
@CveFraccionamientoEtapa, @NombreCapa, @TipoCapa, @Color,
|
||||
@EsVisible, @CveUsuarioEjecuta, SYSDATETIME()
|
||||
);
|
||||
END;
|
||||
|
||||
SET @Return = 1;
|
||||
END TRY
|
||||
BEGIN CATCH
|
||||
SELECT
|
||||
@ErrorMostrar = 'No fue posible guardar la configuración de la capa GIS.',
|
||||
@ErrorTipo = 1,
|
||||
@Return = 0;
|
||||
DECLARE @ErrorTecnico nvarchar(2048) = CONCAT(
|
||||
'Número: ', ERROR_NUMBER(), '; Procedimiento: ', ERROR_PROCEDURE(),
|
||||
'; Línea: ', ERROR_LINE(), '; Detalle: ', ERROR_MESSAGE());
|
||||
RAISERROR(N'%s', 10, 1, @ErrorTecnico);
|
||||
END CATCH;
|
||||
END;
|
||||
GO
|
||||
142
Migracion_NombresDocumentos_20261003.csv
Normal file
@@ -0,0 +1,142 @@
|
||||
"CveDocumentoSolicitud","CveFraccionamientoEtapa","CveTipoDocumento","EsActivo","NombreArchivo","NombreAnterior","RutaAnterior","NombreNuevo","RutaNueva","TamanoBytes","SHA256"
|
||||
"3","1022","1040","True","VL103M user manual 20230921.pdf","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","1146632","3C097C53A81FE7E60ECFB07A9FBD2163E8DB5DE7444050E0EC20ADAFCB7FBA3F"
|
||||
"4","1022","1045","True","BORRADOR EDISA.docx","doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb.bin","Clientes/1006/Etapas/1022/doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb.bin","doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb-BORRADOR EDISA.docx","Clientes/1006/Etapas/1022/doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb-BORRADOR EDISA.docx","16889","3074B0379B55A18B47EB06A4BAE47985B155CAC0583DE78B651988C7599A3C77"
|
||||
"5","1022","1046","True","ACTIVIDADES LETYYYY.docx","doc-1022-1046-c3b1e27e553449a7b5a4545222b63b0b.bin","Clientes/1006/Etapas/1022/doc-1022-1046-c3b1e27e553449a7b5a4545222b63b0b.bin","doc-1022-1046-c3b1e27e553449a7b5a4545222b63b0b-ACTIVIDADES LETYYYY.docx","Clientes/1006/Etapas/1022/doc-1022-1046-c3b1e27e553449a7b5a4545222b63b0b-ACTIVIDADES LETYYYY.docx","19908","8A139074FE52426D3FE0DCE395CCEDB031A03FB33462E2C989F695F14481C11D"
|
||||
"6","1022","1051","True","Recibo-Ago (1).pdf","doc-1022-1051-b0ea49a4b15241e5a6010a8b890b9791.bin","Clientes/1006/Etapas/1022/doc-1022-1051-b0ea49a4b15241e5a6010a8b890b9791.bin","doc-1022-1051-b0ea49a4b15241e5a6010a8b890b9791-Recibo-Ago (1).pdf","Clientes/1006/Etapas/1022/doc-1022-1051-b0ea49a4b15241e5a6010a8b890b9791-Recibo-Ago (1).pdf","814619","86017314865C2064DDBA15CBC1318643BC2F2E0C254A3D274CEE3C17B81E9094"
|
||||
"7","1022","1057","True","65007.jpeg","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","128129","0F80A31813107978A32D13201884611FB35347E738BFDC4538D1ECE97FAD2081"
|
||||
"8","1022","1053","True","Etapa1_10_lotes.gis","doc-1022-1053-53864978166e40c2b3c7e06dd7c6333c.bin","Clientes/1006/Etapas/1022/doc-1022-1053-53864978166e40c2b3c7e06dd7c6333c.bin","doc-1022-1053-53864978166e40c2b3c7e06dd7c6333c-Etapa1_10_lotes.gis","Clientes/1006/Etapas/1022/doc-1022-1053-53864978166e40c2b3c7e06dd7c6333c-Etapa1_10_lotes.gis","8256","5271A9F0C57CF648101CFCDC4CB6635CB28FA2C637DECD4C60195751E8959EEF"
|
||||
"9","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"10","1024","1053","False","02_Copia_escrituras.pdf","doc-1024-1053-4026eac60fde4d57aca2ed30325c7aa7.bin","Clientes/4/Etapas/1024/doc-1024-1053-4026eac60fde4d57aca2ed30325c7aa7.bin","doc-1024-1053-4026eac60fde4d57aca2ed30325c7aa7-02_Copia_escrituras.pdf","Clientes/4/Etapas/1024/doc-1024-1053-4026eac60fde4d57aca2ed30325c7aa7-02_Copia_escrituras.pdf","44497","DE63A4F755D5199D1EB98A024C03627B1AB698403481CE8C6BC5D92E7E8746CC"
|
||||
"11","1024","1046","False","04_Dictamen_uso_suelo.pdf","doc-1024-1046-168182c76cb843cbb3a2aff986bff057.bin","Clientes/4/Etapas/1024/doc-1024-1046-168182c76cb843cbb3a2aff986bff057.bin","doc-1024-1046-168182c76cb843cbb3a2aff986bff057-04_Dictamen_uso_suelo.pdf","Clientes/4/Etapas/1024/doc-1024-1046-168182c76cb843cbb3a2aff986bff057-04_Dictamen_uso_suelo.pdf","44359","AE0069AEC8DDBE09071581126BEA3272BC37A4D758A764BF8A05D58755F4BC28"
|
||||
"12","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"13","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"14","1024","1079","False","08_Constancia_no_adeudo_Agua_Hermosillo.pdf","doc-1024-1079-b838d1c6a81948a0ad275d93dca3b0f5.bin","Clientes/4/Etapas/1024/doc-1024-1079-b838d1c6a81948a0ad275d93dca3b0f5.bin","doc-1024-1079-b838d1c6a81948a0ad275d93dca3b0f5-08_Constancia_no_adeudo_Agua_Hermosillo.pdf","Clientes/4/Etapas/1024/doc-1024-1079-b838d1c6a81948a0ad275d93dca3b0f5-08_Constancia_no_adeudo_Agua_Hermosillo.pdf","44351","04CD6B0F2739837F7BD711819D031FB73BACD7675B752906EFE283F46A7C3006"
|
||||
"15","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"16","1024","1037","False","10_Comprobante_domicilio.pdf","doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"17","1024","1053","True","02_Copia_escrituras.pdf","doc-1024-1053-393eb44b58d24c128d4b5cc5090cc117.bin","Clientes/4/Etapas/1024/doc-1024-1053-393eb44b58d24c128d4b5cc5090cc117.bin","doc-1024-1053-393eb44b58d24c128d4b5cc5090cc117-02_Copia_escrituras.pdf","Clientes/4/Etapas/1024/doc-1024-1053-393eb44b58d24c128d4b5cc5090cc117-02_Copia_escrituras.pdf","44497","DE63A4F755D5199D1EB98A024C03627B1AB698403481CE8C6BC5D92E7E8746CC"
|
||||
"18","1024","1046","True","04_Dictamen_uso_suelo.pdf","doc-1024-1046-746dbd30e6f343338537a9e5e0b3ee59.bin","Clientes/4/Etapas/1024/doc-1024-1046-746dbd30e6f343338537a9e5e0b3ee59.bin","doc-1024-1046-746dbd30e6f343338537a9e5e0b3ee59-04_Dictamen_uso_suelo.pdf","Clientes/4/Etapas/1024/doc-1024-1046-746dbd30e6f343338537a9e5e0b3ee59-04_Dictamen_uso_suelo.pdf","44359","AE0069AEC8DDBE09071581126BEA3272BC37A4D758A764BF8A05D58755F4BC28"
|
||||
"19","1024","1069","True","05_Carta_poder_representante_legal.pdf","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"20","1024","1040","True","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"21","1024","1079","True","08_Constancia_no_adeudo_Agua_Hermosillo.pdf","doc-1024-1079-b25d1e7c30b0443cb66423c56c45c46c.bin","Clientes/4/Etapas/1024/doc-1024-1079-b25d1e7c30b0443cb66423c56c45c46c.bin","doc-1024-1079-b25d1e7c30b0443cb66423c56c45c46c-08_Constancia_no_adeudo_Agua_Hermosillo.pdf","Clientes/4/Etapas/1024/doc-1024-1079-b25d1e7c30b0443cb66423c56c45c46c-08_Constancia_no_adeudo_Agua_Hermosillo.pdf","44351","04CD6B0F2739837F7BD711819D031FB73BACD7675B752906EFE283F46A7C3006"
|
||||
"22","1024","1034","True","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"23","1024","1037","True","10_Comprobante_domicilio.pdf","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"24","1024","1082","False","11_Cedula_RFC.pdf","doc-1024-1082-02f16c7d84fb4781ae5f7e5280422788.bin","Clientes/4/Etapas/1024/doc-1024-1082-02f16c7d84fb4781ae5f7e5280422788.bin","doc-1024-1082-02f16c7d84fb4781ae5f7e5280422788-11_Cedula_RFC.pdf","Clientes/4/Etapas/1024/doc-1024-1082-02f16c7d84fb4781ae5f7e5280422788-11_Cedula_RFC.pdf","44347","75D97258546FDD49567B605CA676CD5DF97F539A7134F9A977BE14D9FA48F912"
|
||||
"25","1024","1080","False","12_Autorizaciones_CIDUE.pdf","doc-1024-1080-2337d1e8ab91435891a9332b5fd58262.bin","Clientes/4/Etapas/1024/doc-1024-1080-2337d1e8ab91435891a9332b5fd58262.bin","doc-1024-1080-2337d1e8ab91435891a9332b5fd58262-12_Autorizaciones_CIDUE.pdf","Clientes/4/Etapas/1024/doc-1024-1080-2337d1e8ab91435891a9332b5fd58262-12_Autorizaciones_CIDUE.pdf","44232","B68667D2A258EC28F3445017A42014A1CDEC4AD6686AE5FB4AD15B275B1D4E7E"
|
||||
"26","1024","1045","False","Croquis.png","doc-1024-1045-d447e83e74d14977957ca05ed2465c28.bin","Clientes/4/Etapas/1024/doc-1024-1045-d447e83e74d14977957ca05ed2465c28.bin","doc-1024-1045-d447e83e74d14977957ca05ed2465c28-Croquis.png","Clientes/4/Etapas/1024/doc-1024-1045-d447e83e74d14977957ca05ed2465c28-Croquis.png","984403","3A507595006CDBB8A59830E0B9634D11DCB85A4CBED1F2A5F35023043947E632"
|
||||
"27","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"28","1024","1082","True","11_Cedula_RFC.pdf","doc-1024-1082-d9c8ba3f888249ae918d7dffbbf6764c.bin","Clientes/4/Etapas/1024/doc-1024-1082-d9c8ba3f888249ae918d7dffbbf6764c.bin","doc-1024-1082-d9c8ba3f888249ae918d7dffbbf6764c-11_Cedula_RFC.pdf","Clientes/4/Etapas/1024/doc-1024-1082-d9c8ba3f888249ae918d7dffbbf6764c-11_Cedula_RFC.pdf","44347","75D97258546FDD49567B605CA676CD5DF97F539A7134F9A977BE14D9FA48F912"
|
||||
"29","1024","1080","True","12_Autorizaciones_CIDUE.pdf","doc-1024-1080-f691bac55afb4c6084d21a7d2ab8f3a2.bin","Clientes/4/Etapas/1024/doc-1024-1080-f691bac55afb4c6084d21a7d2ab8f3a2.bin","doc-1024-1080-f691bac55afb4c6084d21a7d2ab8f3a2-12_Autorizaciones_CIDUE.pdf","Clientes/4/Etapas/1024/doc-1024-1080-f691bac55afb4c6084d21a7d2ab8f3a2-12_Autorizaciones_CIDUE.pdf","44232","B68667D2A258EC28F3445017A42014A1CDEC4AD6686AE5FB4AD15B275B1D4E7E"
|
||||
"30","1024","1045","True","Croquis.png","doc-1024-1045-61379c693d6241898e7cf30cffd8658a.bin","Clientes/4/Etapas/1024/doc-1024-1045-61379c693d6241898e7cf30cffd8658a.bin","doc-1024-1045-61379c693d6241898e7cf30cffd8658a-Croquis.png","Clientes/4/Etapas/1024/doc-1024-1045-61379c693d6241898e7cf30cffd8658a-Croquis.png","984403","3A507595006CDBB8A59830E0B9634D11DCB85A4CBED1F2A5F35023043947E632"
|
||||
"31","1024","1057","True","Identificación Oficial.jpg","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"32","1024","1051","True","01_Oficio_solicitud_obras_necesarias.pdf","doc-1024-1051-4037762f536045d59be5d818e2de6481.bin","Clientes/4/Etapas/1024/doc-1024-1051-4037762f536045d59be5d818e2de6481.bin","doc-1024-1051-4037762f536045d59be5d818e2de6481-01_Oficio_solicitud_obras_necesarias.pdf","Clientes/4/Etapas/1024/doc-1024-1051-4037762f536045d59be5d818e2de6481-01_Oficio_solicitud_obras_necesarias.pdf","44555","DDBDF6829D3A8F8587E42A768C32EF08AEE89848001C4E9B19EEE24480B75AB8"
|
||||
"33","1028","1053","True","02_Copia_escrituras.pdf","doc-1028-1053-c2b0275d99924d3784d7aec44c0b8beb.bin","Clientes/4/Etapas/1028/doc-1028-1053-c2b0275d99924d3784d7aec44c0b8beb.bin","doc-1028-1053-c2b0275d99924d3784d7aec44c0b8beb-02_Copia_escrituras.pdf","Clientes/4/Etapas/1028/doc-1028-1053-c2b0275d99924d3784d7aec44c0b8beb-02_Copia_escrituras.pdf","44497","DE63A4F755D5199D1EB98A024C03627B1AB698403481CE8C6BC5D92E7E8746CC"
|
||||
"34","1028","1046","True","04_Dictamen_uso_suelo.pdf","doc-1028-1046-c98e40e90f3b41cdb810222241f3fc9a.bin","Clientes/4/Etapas/1028/doc-1028-1046-c98e40e90f3b41cdb810222241f3fc9a.bin","doc-1028-1046-c98e40e90f3b41cdb810222241f3fc9a-04_Dictamen_uso_suelo.pdf","Clientes/4/Etapas/1028/doc-1028-1046-c98e40e90f3b41cdb810222241f3fc9a-04_Dictamen_uso_suelo.pdf","44359","AE0069AEC8DDBE09071581126BEA3272BC37A4D758A764BF8A05D58755F4BC28"
|
||||
"35","1028","1069","True","05_Carta_poder_representante_legal.pdf","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"36","1028","1040","True","06_Constancia_no_adeudo_tesoreria.pdf","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"37","1028","1079","True","08_Constancia_no_adeudo_Agua_Hermosillo.pdf","doc-1028-1079-9be2156047bc4828b3e43b67fe3f6733.bin","Clientes/4/Etapas/1028/doc-1028-1079-9be2156047bc4828b3e43b67fe3f6733.bin","doc-1028-1079-9be2156047bc4828b3e43b67fe3f6733-08_Constancia_no_adeudo_Agua_Hermosillo.pdf","Clientes/4/Etapas/1028/doc-1028-1079-9be2156047bc4828b3e43b67fe3f6733-08_Constancia_no_adeudo_Agua_Hermosillo.pdf","44351","04CD6B0F2739837F7BD711819D031FB73BACD7675B752906EFE283F46A7C3006"
|
||||
"38","1028","1034","True","09_Acta_Constitutiva_empresa.pdf","doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"39","1028","1037","True","10_Comprobante_domicilio.pdf","doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"40","1028","1082","True","11_Cedula_RFC.pdf","doc-1028-1082-a21ee3513b5a4fe3b1f5f8f237ddc338.bin","Clientes/4/Etapas/1028/doc-1028-1082-a21ee3513b5a4fe3b1f5f8f237ddc338.bin","doc-1028-1082-a21ee3513b5a4fe3b1f5f8f237ddc338-11_Cedula_RFC.pdf","Clientes/4/Etapas/1028/doc-1028-1082-a21ee3513b5a4fe3b1f5f8f237ddc338-11_Cedula_RFC.pdf","44347","75D97258546FDD49567B605CA676CD5DF97F539A7134F9A977BE14D9FA48F912"
|
||||
"41","1028","1080","True","12_Autorizaciones_CIDUE.pdf","doc-1028-1080-2fb84cc84de24223a9fcdeaf1fcd2470.bin","Clientes/4/Etapas/1028/doc-1028-1080-2fb84cc84de24223a9fcdeaf1fcd2470.bin","doc-1028-1080-2fb84cc84de24223a9fcdeaf1fcd2470-12_Autorizaciones_CIDUE.pdf","Clientes/4/Etapas/1028/doc-1028-1080-2fb84cc84de24223a9fcdeaf1fcd2470-12_Autorizaciones_CIDUE.pdf","44232","B68667D2A258EC28F3445017A42014A1CDEC4AD6686AE5FB4AD15B275B1D4E7E"
|
||||
"42","1028","1045","True","Croquis.png","doc-1028-1045-7f4784759eaf43f09e2a6433309008df.bin","Clientes/4/Etapas/1028/doc-1028-1045-7f4784759eaf43f09e2a6433309008df.bin","doc-1028-1045-7f4784759eaf43f09e2a6433309008df-Croquis.png","Clientes/4/Etapas/1028/doc-1028-1045-7f4784759eaf43f09e2a6433309008df-Croquis.png","984403","3A507595006CDBB8A59830E0B9634D11DCB85A4CBED1F2A5F35023043947E632"
|
||||
"43","1028","1057","True","Identificación Oficial.jpg","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"44","1028","1051","True","01_Oficio_solicitud_obras_necesarias.pdf","doc-1028-1051-90d0c12832f9428abb0ac645be0c7156.bin","Clientes/4/Etapas/1028/doc-1028-1051-90d0c12832f9428abb0ac645be0c7156.bin","doc-1028-1051-90d0c12832f9428abb0ac645be0c7156-01_Oficio_solicitud_obras_necesarias.pdf","Clientes/4/Etapas/1028/doc-1028-1051-90d0c12832f9428abb0ac645be0c7156-01_Oficio_solicitud_obras_necesarias.pdf","44555","DDBDF6829D3A8F8587E42A768C32EF08AEE89848001C4E9B19EEE24480B75AB8"
|
||||
"45","1022","1040","False","VL103M user manual 20230921.pdf","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","1146632","3C097C53A81FE7E60ECFB07A9FBD2163E8DB5DE7444050E0EC20ADAFCB7FBA3F"
|
||||
"46","1022","1040","False","VL103M user manual 20230921.pdf","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","1146632","3C097C53A81FE7E60ECFB07A9FBD2163E8DB5DE7444050E0EC20ADAFCB7FBA3F"
|
||||
"47","1022","1040","False","VL103M user manual 20230921.pdf","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","1146632","3C097C53A81FE7E60ECFB07A9FBD2163E8DB5DE7444050E0EC20ADAFCB7FBA3F"
|
||||
"48","1022","1040","False","VL103M user manual 20230921.pdf","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","1146632","3C097C53A81FE7E60ECFB07A9FBD2163E8DB5DE7444050E0EC20ADAFCB7FBA3F"
|
||||
"49","1022","1040","False","VL103M user manual 20230921.pdf","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","1146632","3C097C53A81FE7E60ECFB07A9FBD2163E8DB5DE7444050E0EC20ADAFCB7FBA3F"
|
||||
"50","1022","1040","False","VL103M user manual 20230921.pdf","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin","doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf","1146632","3C097C53A81FE7E60ECFB07A9FBD2163E8DB5DE7444050E0EC20ADAFCB7FBA3F"
|
||||
"51","1022","1045","False","BORRADOR EDISA.docx","doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb.bin","Clientes/1006/Etapas/1022/doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb.bin","doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb-BORRADOR EDISA.docx","Clientes/1006/Etapas/1022/doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb-BORRADOR EDISA.docx","16889","3074B0379B55A18B47EB06A4BAE47985B155CAC0583DE78B651988C7599A3C77"
|
||||
"52","1022","1057","False","65007.jpeg","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","128129","0F80A31813107978A32D13201884611FB35347E738BFDC4538D1ECE97FAD2081"
|
||||
"53","1022","1057","False","65007.jpeg","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","128129","0F80A31813107978A32D13201884611FB35347E738BFDC4538D1ECE97FAD2081"
|
||||
"54","1022","1057","False","65007.jpeg","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","128129","0F80A31813107978A32D13201884611FB35347E738BFDC4538D1ECE97FAD2081"
|
||||
"55","1022","1057","False","65007.jpeg","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","128129","0F80A31813107978A32D13201884611FB35347E738BFDC4538D1ECE97FAD2081"
|
||||
"56","1022","1057","False","65007.jpeg","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","128129","0F80A31813107978A32D13201884611FB35347E738BFDC4538D1ECE97FAD2081"
|
||||
"57","1022","1057","False","65007.jpeg","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","128129","0F80A31813107978A32D13201884611FB35347E738BFDC4538D1ECE97FAD2081"
|
||||
"58","1022","1057","False","65007.jpeg","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin","doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg","128129","0F80A31813107978A32D13201884611FB35347E738BFDC4538D1ECE97FAD2081"
|
||||
"59","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"60","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"61","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"62","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin","doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"63","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"64","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"65","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"66","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"67","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin","doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"68","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"69","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"70","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"71","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"72","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"73","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin","doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"74","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"75","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"76","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"77","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin","doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"78","1024","1037","False","10_Comprobante_domicilio.pdf","doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"79","1024","1037","False","10_Comprobante_domicilio.pdf","doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"80","1024","1037","False","10_Comprobante_domicilio.pdf","doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"81","1024","1037","False","10_Comprobante_domicilio.pdf","doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin","doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"82","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"83","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"84","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"85","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"86","1024","1069","False","05_Carta_poder_representante_legal.pdf","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin","doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"87","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"88","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"89","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"90","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"91","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"92","1024","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin","doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"93","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"94","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"95","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"96","1024","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin","doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"97","1024","1037","False","10_Comprobante_domicilio.pdf","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"98","1024","1037","False","10_Comprobante_domicilio.pdf","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"99","1024","1037","False","10_Comprobante_domicilio.pdf","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"100","1024","1037","False","10_Comprobante_domicilio.pdf","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin","doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"101","1024","1045","False","Croquis.png","doc-1024-1045-d447e83e74d14977957ca05ed2465c28.bin","Clientes/4/Etapas/1024/doc-1024-1045-d447e83e74d14977957ca05ed2465c28.bin","doc-1024-1045-d447e83e74d14977957ca05ed2465c28-Croquis.png","Clientes/4/Etapas/1024/doc-1024-1045-d447e83e74d14977957ca05ed2465c28-Croquis.png","984403","3A507595006CDBB8A59830E0B9634D11DCB85A4CBED1F2A5F35023043947E632"
|
||||
"102","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"103","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"104","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"105","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"106","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"107","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"108","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin","doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"109","1024","1045","False","Croquis.png","doc-1024-1045-61379c693d6241898e7cf30cffd8658a.bin","Clientes/4/Etapas/1024/doc-1024-1045-61379c693d6241898e7cf30cffd8658a.bin","doc-1024-1045-61379c693d6241898e7cf30cffd8658a-Croquis.png","Clientes/4/Etapas/1024/doc-1024-1045-61379c693d6241898e7cf30cffd8658a-Croquis.png","984403","3A507595006CDBB8A59830E0B9634D11DCB85A4CBED1F2A5F35023043947E632"
|
||||
"110","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"111","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"112","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"113","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"114","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"115","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"116","1024","1057","False","Identificación Oficial.jpg","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin","doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"117","1028","1069","False","05_Carta_poder_representante_legal.pdf","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"118","1028","1069","False","05_Carta_poder_representante_legal.pdf","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"119","1028","1069","False","05_Carta_poder_representante_legal.pdf","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"120","1028","1069","False","05_Carta_poder_representante_legal.pdf","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"121","1028","1069","False","05_Carta_poder_representante_legal.pdf","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin","doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf","44650","A40E9C9A5FBA9E40B133993051C39288D8A498CC71EBCFB354C2C9D73FA064F1"
|
||||
"122","1028","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"123","1028","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"124","1028","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"125","1028","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"126","1028","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"127","1028","1040","False","06_Constancia_no_adeudo_tesoreria.pdf","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin","doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf","44515","4E2ADB80E976362F5A48D6D75FB421F193E2FB30AEE76F46132DB26BAD5CBF0F"
|
||||
"128","1028","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"129","1028","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"130","1028","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"131","1028","1034","False","09_Acta_Constitutiva_empresa.pdf","doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin","doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf","44281","4461F94E3DCBE9BCF0FB45C099E3F87B969AC59BAB62E6CD7EA97133A5CD33A3"
|
||||
"132","1028","1037","False","10_Comprobante_domicilio.pdf","doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"133","1028","1037","False","10_Comprobante_domicilio.pdf","doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"134","1028","1037","False","10_Comprobante_domicilio.pdf","doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"135","1028","1037","False","10_Comprobante_domicilio.pdf","doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin","doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf","44184","0222D8B303F2C0DA21863CA16BC160F2564963C14238009847C52C10526917D0"
|
||||
"136","1028","1045","False","Croquis.png","doc-1028-1045-7f4784759eaf43f09e2a6433309008df.bin","Clientes/4/Etapas/1028/doc-1028-1045-7f4784759eaf43f09e2a6433309008df.bin","doc-1028-1045-7f4784759eaf43f09e2a6433309008df-Croquis.png","Clientes/4/Etapas/1028/doc-1028-1045-7f4784759eaf43f09e2a6433309008df-Croquis.png","984403","3A507595006CDBB8A59830E0B9634D11DCB85A4CBED1F2A5F35023043947E632"
|
||||
"137","1028","1057","False","Identificación Oficial.jpg","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"138","1028","1057","False","Identificación Oficial.jpg","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"139","1028","1057","False","Identificación Oficial.jpg","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"140","1028","1057","False","Identificación Oficial.jpg","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"141","1028","1057","False","Identificación Oficial.jpg","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"142","1028","1057","False","Identificación Oficial.jpg","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
"143","1028","1057","False","Identificación Oficial.jpg","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin","doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg","55724","A5915340A4600EE8988CEDF4080E6828ED42FCD2DE432788102A328977A83076"
|
||||
|
243
Migracion_NombresDocumentos_20261003.sql
Normal file
@@ -0,0 +1,243 @@
|
||||
-- Migración de nombres físicos autorizada el 2026-10-03.
|
||||
-- Requiere copias verificadas con el inventario CSV antes de ejecutarse.
|
||||
-- Respaldo: Respaldo_NombresDocumentos_20261003.
|
||||
SET NOCOUNT ON;
|
||||
SET XACT_ABORT ON;
|
||||
|
||||
DECLARE @Mapeo TABLE
|
||||
(
|
||||
CveDocumentoSolicitud int PRIMARY KEY,
|
||||
NombreAnterior varchar(255) COLLATE Modern_Spanish_CS_AS NOT NULL,
|
||||
RutaAnterior varchar(1000) COLLATE Modern_Spanish_CS_AS NOT NULL,
|
||||
NombreNuevo varchar(255) COLLATE Modern_Spanish_CS_AS NOT NULL,
|
||||
RutaNueva varchar(1000) COLLATE Modern_Spanish_CS_AS NOT NULL
|
||||
);
|
||||
|
||||
INSERT INTO @Mapeo
|
||||
(CveDocumentoSolicitud, NombreAnterior, RutaAnterior, NombreNuevo, RutaNueva)
|
||||
VALUES
|
||||
(3, N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf'),
|
||||
(4, N'doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb.bin', N'Clientes/1006/Etapas/1022/doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb.bin', N'doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb-BORRADOR EDISA.docx', N'Clientes/1006/Etapas/1022/doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb-BORRADOR EDISA.docx'),
|
||||
(5, N'doc-1022-1046-c3b1e27e553449a7b5a4545222b63b0b.bin', N'Clientes/1006/Etapas/1022/doc-1022-1046-c3b1e27e553449a7b5a4545222b63b0b.bin', N'doc-1022-1046-c3b1e27e553449a7b5a4545222b63b0b-ACTIVIDADES LETYYYY.docx', N'Clientes/1006/Etapas/1022/doc-1022-1046-c3b1e27e553449a7b5a4545222b63b0b-ACTIVIDADES LETYYYY.docx'),
|
||||
(6, N'doc-1022-1051-b0ea49a4b15241e5a6010a8b890b9791.bin', N'Clientes/1006/Etapas/1022/doc-1022-1051-b0ea49a4b15241e5a6010a8b890b9791.bin', N'doc-1022-1051-b0ea49a4b15241e5a6010a8b890b9791-Recibo-Ago (1).pdf', N'Clientes/1006/Etapas/1022/doc-1022-1051-b0ea49a4b15241e5a6010a8b890b9791-Recibo-Ago (1).pdf'),
|
||||
(7, N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg'),
|
||||
(8, N'doc-1022-1053-53864978166e40c2b3c7e06dd7c6333c.bin', N'Clientes/1006/Etapas/1022/doc-1022-1053-53864978166e40c2b3c7e06dd7c6333c.bin', N'doc-1022-1053-53864978166e40c2b3c7e06dd7c6333c-Etapa1_10_lotes.gis', N'Clientes/1006/Etapas/1022/doc-1022-1053-53864978166e40c2b3c7e06dd7c6333c-Etapa1_10_lotes.gis'),
|
||||
(9, N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(10, N'doc-1024-1053-4026eac60fde4d57aca2ed30325c7aa7.bin', N'Clientes/4/Etapas/1024/doc-1024-1053-4026eac60fde4d57aca2ed30325c7aa7.bin', N'doc-1024-1053-4026eac60fde4d57aca2ed30325c7aa7-02_Copia_escrituras.pdf', N'Clientes/4/Etapas/1024/doc-1024-1053-4026eac60fde4d57aca2ed30325c7aa7-02_Copia_escrituras.pdf'),
|
||||
(11, N'doc-1024-1046-168182c76cb843cbb3a2aff986bff057.bin', N'Clientes/4/Etapas/1024/doc-1024-1046-168182c76cb843cbb3a2aff986bff057.bin', N'doc-1024-1046-168182c76cb843cbb3a2aff986bff057-04_Dictamen_uso_suelo.pdf', N'Clientes/4/Etapas/1024/doc-1024-1046-168182c76cb843cbb3a2aff986bff057-04_Dictamen_uso_suelo.pdf'),
|
||||
(12, N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf'),
|
||||
(13, N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(14, N'doc-1024-1079-b838d1c6a81948a0ad275d93dca3b0f5.bin', N'Clientes/4/Etapas/1024/doc-1024-1079-b838d1c6a81948a0ad275d93dca3b0f5.bin', N'doc-1024-1079-b838d1c6a81948a0ad275d93dca3b0f5-08_Constancia_no_adeudo_Agua_Hermosillo.pdf', N'Clientes/4/Etapas/1024/doc-1024-1079-b838d1c6a81948a0ad275d93dca3b0f5-08_Constancia_no_adeudo_Agua_Hermosillo.pdf'),
|
||||
(15, N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(16, N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf'),
|
||||
(17, N'doc-1024-1053-393eb44b58d24c128d4b5cc5090cc117.bin', N'Clientes/4/Etapas/1024/doc-1024-1053-393eb44b58d24c128d4b5cc5090cc117.bin', N'doc-1024-1053-393eb44b58d24c128d4b5cc5090cc117-02_Copia_escrituras.pdf', N'Clientes/4/Etapas/1024/doc-1024-1053-393eb44b58d24c128d4b5cc5090cc117-02_Copia_escrituras.pdf'),
|
||||
(18, N'doc-1024-1046-746dbd30e6f343338537a9e5e0b3ee59.bin', N'Clientes/4/Etapas/1024/doc-1024-1046-746dbd30e6f343338537a9e5e0b3ee59.bin', N'doc-1024-1046-746dbd30e6f343338537a9e5e0b3ee59-04_Dictamen_uso_suelo.pdf', N'Clientes/4/Etapas/1024/doc-1024-1046-746dbd30e6f343338537a9e5e0b3ee59-04_Dictamen_uso_suelo.pdf'),
|
||||
(19, N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf'),
|
||||
(20, N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(21, N'doc-1024-1079-b25d1e7c30b0443cb66423c56c45c46c.bin', N'Clientes/4/Etapas/1024/doc-1024-1079-b25d1e7c30b0443cb66423c56c45c46c.bin', N'doc-1024-1079-b25d1e7c30b0443cb66423c56c45c46c-08_Constancia_no_adeudo_Agua_Hermosillo.pdf', N'Clientes/4/Etapas/1024/doc-1024-1079-b25d1e7c30b0443cb66423c56c45c46c-08_Constancia_no_adeudo_Agua_Hermosillo.pdf'),
|
||||
(22, N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(23, N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf'),
|
||||
(24, N'doc-1024-1082-02f16c7d84fb4781ae5f7e5280422788.bin', N'Clientes/4/Etapas/1024/doc-1024-1082-02f16c7d84fb4781ae5f7e5280422788.bin', N'doc-1024-1082-02f16c7d84fb4781ae5f7e5280422788-11_Cedula_RFC.pdf', N'Clientes/4/Etapas/1024/doc-1024-1082-02f16c7d84fb4781ae5f7e5280422788-11_Cedula_RFC.pdf'),
|
||||
(25, N'doc-1024-1080-2337d1e8ab91435891a9332b5fd58262.bin', N'Clientes/4/Etapas/1024/doc-1024-1080-2337d1e8ab91435891a9332b5fd58262.bin', N'doc-1024-1080-2337d1e8ab91435891a9332b5fd58262-12_Autorizaciones_CIDUE.pdf', N'Clientes/4/Etapas/1024/doc-1024-1080-2337d1e8ab91435891a9332b5fd58262-12_Autorizaciones_CIDUE.pdf'),
|
||||
(26, N'doc-1024-1045-d447e83e74d14977957ca05ed2465c28.bin', N'Clientes/4/Etapas/1024/doc-1024-1045-d447e83e74d14977957ca05ed2465c28.bin', N'doc-1024-1045-d447e83e74d14977957ca05ed2465c28-Croquis.png', N'Clientes/4/Etapas/1024/doc-1024-1045-d447e83e74d14977957ca05ed2465c28-Croquis.png'),
|
||||
(27, N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg'),
|
||||
(28, N'doc-1024-1082-d9c8ba3f888249ae918d7dffbbf6764c.bin', N'Clientes/4/Etapas/1024/doc-1024-1082-d9c8ba3f888249ae918d7dffbbf6764c.bin', N'doc-1024-1082-d9c8ba3f888249ae918d7dffbbf6764c-11_Cedula_RFC.pdf', N'Clientes/4/Etapas/1024/doc-1024-1082-d9c8ba3f888249ae918d7dffbbf6764c-11_Cedula_RFC.pdf'),
|
||||
(29, N'doc-1024-1080-f691bac55afb4c6084d21a7d2ab8f3a2.bin', N'Clientes/4/Etapas/1024/doc-1024-1080-f691bac55afb4c6084d21a7d2ab8f3a2.bin', N'doc-1024-1080-f691bac55afb4c6084d21a7d2ab8f3a2-12_Autorizaciones_CIDUE.pdf', N'Clientes/4/Etapas/1024/doc-1024-1080-f691bac55afb4c6084d21a7d2ab8f3a2-12_Autorizaciones_CIDUE.pdf'),
|
||||
(30, N'doc-1024-1045-61379c693d6241898e7cf30cffd8658a.bin', N'Clientes/4/Etapas/1024/doc-1024-1045-61379c693d6241898e7cf30cffd8658a.bin', N'doc-1024-1045-61379c693d6241898e7cf30cffd8658a-Croquis.png', N'Clientes/4/Etapas/1024/doc-1024-1045-61379c693d6241898e7cf30cffd8658a-Croquis.png'),
|
||||
(31, N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg'),
|
||||
(32, N'doc-1024-1051-4037762f536045d59be5d818e2de6481.bin', N'Clientes/4/Etapas/1024/doc-1024-1051-4037762f536045d59be5d818e2de6481.bin', N'doc-1024-1051-4037762f536045d59be5d818e2de6481-01_Oficio_solicitud_obras_necesarias.pdf', N'Clientes/4/Etapas/1024/doc-1024-1051-4037762f536045d59be5d818e2de6481-01_Oficio_solicitud_obras_necesarias.pdf'),
|
||||
(33, N'doc-1028-1053-c2b0275d99924d3784d7aec44c0b8beb.bin', N'Clientes/4/Etapas/1028/doc-1028-1053-c2b0275d99924d3784d7aec44c0b8beb.bin', N'doc-1028-1053-c2b0275d99924d3784d7aec44c0b8beb-02_Copia_escrituras.pdf', N'Clientes/4/Etapas/1028/doc-1028-1053-c2b0275d99924d3784d7aec44c0b8beb-02_Copia_escrituras.pdf'),
|
||||
(34, N'doc-1028-1046-c98e40e90f3b41cdb810222241f3fc9a.bin', N'Clientes/4/Etapas/1028/doc-1028-1046-c98e40e90f3b41cdb810222241f3fc9a.bin', N'doc-1028-1046-c98e40e90f3b41cdb810222241f3fc9a-04_Dictamen_uso_suelo.pdf', N'Clientes/4/Etapas/1028/doc-1028-1046-c98e40e90f3b41cdb810222241f3fc9a-04_Dictamen_uso_suelo.pdf'),
|
||||
(35, N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf'),
|
||||
(36, N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(37, N'doc-1028-1079-9be2156047bc4828b3e43b67fe3f6733.bin', N'Clientes/4/Etapas/1028/doc-1028-1079-9be2156047bc4828b3e43b67fe3f6733.bin', N'doc-1028-1079-9be2156047bc4828b3e43b67fe3f6733-08_Constancia_no_adeudo_Agua_Hermosillo.pdf', N'Clientes/4/Etapas/1028/doc-1028-1079-9be2156047bc4828b3e43b67fe3f6733-08_Constancia_no_adeudo_Agua_Hermosillo.pdf'),
|
||||
(38, N'doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(39, N'doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf'),
|
||||
(40, N'doc-1028-1082-a21ee3513b5a4fe3b1f5f8f237ddc338.bin', N'Clientes/4/Etapas/1028/doc-1028-1082-a21ee3513b5a4fe3b1f5f8f237ddc338.bin', N'doc-1028-1082-a21ee3513b5a4fe3b1f5f8f237ddc338-11_Cedula_RFC.pdf', N'Clientes/4/Etapas/1028/doc-1028-1082-a21ee3513b5a4fe3b1f5f8f237ddc338-11_Cedula_RFC.pdf'),
|
||||
(41, N'doc-1028-1080-2fb84cc84de24223a9fcdeaf1fcd2470.bin', N'Clientes/4/Etapas/1028/doc-1028-1080-2fb84cc84de24223a9fcdeaf1fcd2470.bin', N'doc-1028-1080-2fb84cc84de24223a9fcdeaf1fcd2470-12_Autorizaciones_CIDUE.pdf', N'Clientes/4/Etapas/1028/doc-1028-1080-2fb84cc84de24223a9fcdeaf1fcd2470-12_Autorizaciones_CIDUE.pdf'),
|
||||
(42, N'doc-1028-1045-7f4784759eaf43f09e2a6433309008df.bin', N'Clientes/4/Etapas/1028/doc-1028-1045-7f4784759eaf43f09e2a6433309008df.bin', N'doc-1028-1045-7f4784759eaf43f09e2a6433309008df-Croquis.png', N'Clientes/4/Etapas/1028/doc-1028-1045-7f4784759eaf43f09e2a6433309008df-Croquis.png'),
|
||||
(43, N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg'),
|
||||
(44, N'doc-1028-1051-90d0c12832f9428abb0ac645be0c7156.bin', N'Clientes/4/Etapas/1028/doc-1028-1051-90d0c12832f9428abb0ac645be0c7156.bin', N'doc-1028-1051-90d0c12832f9428abb0ac645be0c7156-01_Oficio_solicitud_obras_necesarias.pdf', N'Clientes/4/Etapas/1028/doc-1028-1051-90d0c12832f9428abb0ac645be0c7156-01_Oficio_solicitud_obras_necesarias.pdf'),
|
||||
(45, N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf'),
|
||||
(46, N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf'),
|
||||
(47, N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf'),
|
||||
(48, N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf'),
|
||||
(49, N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf'),
|
||||
(50, N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd.bin', N'doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf', N'Clientes/1006/Etapas/1022/doc-1022-1040-b6e404e6e7dc4597860185076b3289dd-VL103M user manual 20230921.pdf'),
|
||||
(51, N'doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb.bin', N'Clientes/1006/Etapas/1022/doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb.bin', N'doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb-BORRADOR EDISA.docx', N'Clientes/1006/Etapas/1022/doc-1022-1045-b8d0648d970b4cababc65f30c58b1ccb-BORRADOR EDISA.docx'),
|
||||
(52, N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg'),
|
||||
(53, N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg'),
|
||||
(54, N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg'),
|
||||
(55, N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg'),
|
||||
(56, N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg'),
|
||||
(57, N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg'),
|
||||
(58, N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422.bin', N'doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg', N'Clientes/1006/Etapas/1022/doc-1022-1057-626fd5ba8cc747fcae64ad2c8466f422-65007.jpeg'),
|
||||
(59, N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(60, N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(61, N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(62, N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42.bin', N'doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-3212891ee8f847aba1e83b01fc27ef42-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(63, N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf'),
|
||||
(64, N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf'),
|
||||
(65, N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf'),
|
||||
(66, N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf'),
|
||||
(67, N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8.bin', N'doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-1c7a3c7eb01f44acac908819648f3ca8-05_Carta_poder_representante_legal.pdf'),
|
||||
(68, N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(69, N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(70, N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(71, N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(72, N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(73, N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971.bin', N'doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-cfb6478de0c64aa8933fa2df00de1971-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(74, N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(75, N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(76, N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(77, N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba.bin', N'doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-703001ed04cd4768805ea52d87c496ba-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(78, N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf'),
|
||||
(79, N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf'),
|
||||
(80, N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf'),
|
||||
(81, N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096.bin', N'doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-251daa4398b44a56bb95dcd11326c096-10_Comprobante_domicilio.pdf'),
|
||||
(82, N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf'),
|
||||
(83, N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf'),
|
||||
(84, N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf'),
|
||||
(85, N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf'),
|
||||
(86, N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77.bin', N'doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1024/doc-1024-1069-a126b490c1e24edbab7b044bf0549e77-05_Carta_poder_representante_legal.pdf'),
|
||||
(87, N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(88, N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(89, N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(90, N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(91, N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(92, N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d.bin', N'doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1024/doc-1024-1040-52f4c0205ee1446b884f6c64f20e505d-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(93, N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(94, N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(95, N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(96, N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5.bin', N'doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1024/doc-1024-1034-1f93d872f1c549988ab7b6f3f9b574f5-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(97, N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf'),
|
||||
(98, N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf'),
|
||||
(99, N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf'),
|
||||
(100, N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f.bin', N'doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1024/doc-1024-1037-8ab956638dc442e49632d23459f4cb2f-10_Comprobante_domicilio.pdf'),
|
||||
(101, N'doc-1024-1045-d447e83e74d14977957ca05ed2465c28.bin', N'Clientes/4/Etapas/1024/doc-1024-1045-d447e83e74d14977957ca05ed2465c28.bin', N'doc-1024-1045-d447e83e74d14977957ca05ed2465c28-Croquis.png', N'Clientes/4/Etapas/1024/doc-1024-1045-d447e83e74d14977957ca05ed2465c28-Croquis.png'),
|
||||
(102, N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg'),
|
||||
(103, N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg'),
|
||||
(104, N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg'),
|
||||
(105, N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg'),
|
||||
(106, N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg'),
|
||||
(107, N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg'),
|
||||
(108, N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e.bin', N'doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-a00c7eb989a64e47baec43163755e90e-Identificación Oficial.jpg'),
|
||||
(109, N'doc-1024-1045-61379c693d6241898e7cf30cffd8658a.bin', N'Clientes/4/Etapas/1024/doc-1024-1045-61379c693d6241898e7cf30cffd8658a.bin', N'doc-1024-1045-61379c693d6241898e7cf30cffd8658a-Croquis.png', N'Clientes/4/Etapas/1024/doc-1024-1045-61379c693d6241898e7cf30cffd8658a-Croquis.png'),
|
||||
(110, N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg'),
|
||||
(111, N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg'),
|
||||
(112, N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg'),
|
||||
(113, N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg'),
|
||||
(114, N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg'),
|
||||
(115, N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg'),
|
||||
(116, N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3.bin', N'doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg', N'Clientes/4/Etapas/1024/doc-1024-1057-6f6f616d9d894e549d344781acf4b1f3-Identificación Oficial.jpg'),
|
||||
(117, N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf'),
|
||||
(118, N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf'),
|
||||
(119, N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf'),
|
||||
(120, N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf'),
|
||||
(121, N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713.bin', N'doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf', N'Clientes/4/Etapas/1028/doc-1028-1069-320a3b0bf9294a92be5ebf802fcd4713-05_Carta_poder_representante_legal.pdf'),
|
||||
(122, N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(123, N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(124, N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(125, N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(126, N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(127, N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072.bin', N'doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf', N'Clientes/4/Etapas/1028/doc-1028-1040-9bc673275f414c8d8d320e9bbf698072-06_Constancia_no_adeudo_tesoreria.pdf'),
|
||||
(128, N'doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(129, N'doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(130, N'doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(131, N'doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495.bin', N'doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf', N'Clientes/4/Etapas/1028/doc-1028-1034-583b7009cab246ed8287200ce7082495-09_Acta_Constitutiva_empresa.pdf'),
|
||||
(132, N'doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf'),
|
||||
(133, N'doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf'),
|
||||
(134, N'doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf'),
|
||||
(135, N'doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915.bin', N'doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf', N'Clientes/4/Etapas/1028/doc-1028-1037-06adb9de68924cebafe0052e68b83915-10_Comprobante_domicilio.pdf'),
|
||||
(136, N'doc-1028-1045-7f4784759eaf43f09e2a6433309008df.bin', N'Clientes/4/Etapas/1028/doc-1028-1045-7f4784759eaf43f09e2a6433309008df.bin', N'doc-1028-1045-7f4784759eaf43f09e2a6433309008df-Croquis.png', N'Clientes/4/Etapas/1028/doc-1028-1045-7f4784759eaf43f09e2a6433309008df-Croquis.png'),
|
||||
(137, N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg'),
|
||||
(138, N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg'),
|
||||
(139, N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg'),
|
||||
(140, N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg'),
|
||||
(141, N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg'),
|
||||
(142, N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg'),
|
||||
(143, N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c.bin', N'doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg', N'Clientes/4/Etapas/1028/doc-1028-1057-657aeb02d955432c8a9f4a1a12042c1c-Identificación Oficial.jpg');
|
||||
|
||||
BEGIN TRY
|
||||
BEGIN TRANSACTION;
|
||||
|
||||
SELECT documento.*
|
||||
INTO #Antes
|
||||
FROM dbo.Tra_DocumentosSolicitud AS documento WITH (TABLOCKX, HOLDLOCK);
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM @Mapeo AS mapeo
|
||||
LEFT JOIN #Antes AS documento ON documento.CveDocumentoSolicitud = mapeo.CveDocumentoSolicitud
|
||||
WHERE documento.CveDocumentoSolicitud IS NULL
|
||||
OR documento.NombreArchivoFisico IS NULL
|
||||
OR documento.RutaArchivo IS NULL
|
||||
OR NOT
|
||||
(
|
||||
(documento.NombreArchivoFisico = mapeo.NombreAnterior AND documento.RutaArchivo = mapeo.RutaAnterior)
|
||||
OR (documento.NombreArchivoFisico = mapeo.NombreNuevo AND documento.RutaArchivo = mapeo.RutaNueva)
|
||||
)
|
||||
)
|
||||
THROW 51000, 'El inventario cambió. Revisar antes de migrar.', 1;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM #Antes AS documento
|
||||
INNER JOIN @Mapeo AS mapeo ON documento.RutaArchivo = mapeo.RutaAnterior
|
||||
WHERE NOT EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM @Mapeo AS conocido
|
||||
WHERE conocido.CveDocumentoSolicitud = documento.CveDocumentoSolicitud
|
||||
)
|
||||
)
|
||||
THROW 51001, 'Existen nuevas referencias a los archivos anteriores.', 1;
|
||||
|
||||
UPDATE documento
|
||||
SET NombreArchivoFisico = mapeo.NombreNuevo,
|
||||
RutaArchivo = mapeo.RutaNueva
|
||||
FROM dbo.Tra_DocumentosSolicitud AS documento
|
||||
INNER JOIN @Mapeo AS mapeo ON documento.CveDocumentoSolicitud = mapeo.CveDocumentoSolicitud
|
||||
WHERE documento.NombreArchivoFisico = mapeo.NombreAnterior
|
||||
AND documento.RutaArchivo = mapeo.RutaAnterior;
|
||||
|
||||
DECLARE @Actualizados int = @@ROWCOUNT;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT [CveDocumentoSolicitud], [CveSolicitud], [CveTipoDocumento], [NombreArchivo], [ContentType], [TamanoBytes], [ComentarioCliente], [ComentarioAdministrativo], [EsAprobado], [CveUsuarioCarga], [CveUsuarioRevisa], [FechaRevision], [FechaAlta], [UltimaNota], [FechaDocumento], [FechaVencimiento], [EsActivo], [CveFraccionamientoEtapa], [Vencido], [CveTipoTramite]
|
||||
FROM #Antes
|
||||
EXCEPT
|
||||
SELECT [CveDocumentoSolicitud], [CveSolicitud], [CveTipoDocumento], [NombreArchivo], [ContentType], [TamanoBytes], [ComentarioCliente], [ComentarioAdministrativo], [EsAprobado], [CveUsuarioCarga], [CveUsuarioRevisa], [FechaRevision], [FechaAlta], [UltimaNota], [FechaDocumento], [FechaVencimiento], [EsActivo], [CveFraccionamientoEtapa], [Vencido], [CveTipoTramite]
|
||||
FROM dbo.Tra_DocumentosSolicitud
|
||||
)
|
||||
OR EXISTS
|
||||
(
|
||||
SELECT [CveDocumentoSolicitud], [CveSolicitud], [CveTipoDocumento], [NombreArchivo], [ContentType], [TamanoBytes], [ComentarioCliente], [ComentarioAdministrativo], [EsAprobado], [CveUsuarioCarga], [CveUsuarioRevisa], [FechaRevision], [FechaAlta], [UltimaNota], [FechaDocumento], [FechaVencimiento], [EsActivo], [CveFraccionamientoEtapa], [Vencido], [CveTipoTramite]
|
||||
FROM dbo.Tra_DocumentosSolicitud
|
||||
EXCEPT
|
||||
SELECT [CveDocumentoSolicitud], [CveSolicitud], [CveTipoDocumento], [NombreArchivo], [ContentType], [TamanoBytes], [ComentarioCliente], [ComentarioAdministrativo], [EsAprobado], [CveUsuarioCarga], [CveUsuarioRevisa], [FechaRevision], [FechaAlta], [UltimaNota], [FechaDocumento], [FechaVencimiento], [EsActivo], [CveFraccionamientoEtapa], [Vencido], [CveTipoTramite]
|
||||
FROM #Antes
|
||||
)
|
||||
THROW 51002, 'Se detectó un cambio ajeno a las rutas.', 1;
|
||||
|
||||
IF EXISTS
|
||||
(
|
||||
SELECT 1
|
||||
FROM @Mapeo AS mapeo
|
||||
INNER JOIN dbo.Tra_DocumentosSolicitud AS documento ON documento.CveDocumentoSolicitud = mapeo.CveDocumentoSolicitud
|
||||
WHERE documento.NombreArchivoFisico <> mapeo.NombreNuevo
|
||||
OR documento.RutaArchivo <> mapeo.RutaNueva
|
||||
)
|
||||
THROW 51003, 'No se actualizaron todas las referencias.', 1;
|
||||
|
||||
COMMIT TRANSACTION;
|
||||
SELECT @Actualizados AS ReferenciasActualizadas;
|
||||
END TRY
|
||||
BEGIN CATCH
|
||||
IF XACT_STATE() <> 0
|
||||
ROLLBACK TRANSACTION;
|
||||
THROW;
|
||||
END CATCH;
|
||||
@@ -0,0 +1,412 @@
|
||||
{
|
||||
"type": "FeatureCollection",
|
||||
"name": "Etapa1_10_lotes",
|
||||
"crs": {
|
||||
"type": "name",
|
||||
"properties": {
|
||||
"name": "EPSG:4326"
|
||||
}
|
||||
},
|
||||
"features": [
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-1",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 1",
|
||||
"Catastro": "CAT-001",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9555,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95532,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95532,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9555,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9555,
|
||||
29.09
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-2",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 1",
|
||||
"Catastro": "CAT-002",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9553,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95512,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95512,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9553,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9553,
|
||||
29.09
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-3",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 1",
|
||||
"Catastro": "CAT-003",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9551,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95492,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95492,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9551,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9551,
|
||||
29.09
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-4",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 1",
|
||||
"Catastro": "CAT-004",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9549,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95472,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95472,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9549,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9549,
|
||||
29.09
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-5",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 1",
|
||||
"Catastro": "CAT-005",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9547,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95452,
|
||||
29.09
|
||||
],
|
||||
[
|
||||
-110.95452,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9547,
|
||||
29.090139999999998
|
||||
],
|
||||
[
|
||||
-110.9547,
|
||||
29.09
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-6",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 2",
|
||||
"Catastro": "CAT-006",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9555,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95532,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95532,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9555,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9555,
|
||||
29.09016
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-7",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 2",
|
||||
"Catastro": "CAT-007",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9553,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95512,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95512,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9553,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9553,
|
||||
29.09016
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-8",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 2",
|
||||
"Catastro": "CAT-008",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9551,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95492,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95492,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9551,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9551,
|
||||
29.09016
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-9",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 2",
|
||||
"Catastro": "CAT-009",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9549,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95472,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95472,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9549,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9549,
|
||||
29.09016
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "Feature",
|
||||
"properties": {
|
||||
"Etapa": "Etapa 1",
|
||||
"Nombre": "Umbrella-10",
|
||||
"Tipo": "Lote",
|
||||
"Calle": "Calle Demo 2",
|
||||
"Catastro": "CAT-010",
|
||||
"MetrosCuadrados": 200.0,
|
||||
"Duplicador": 1,
|
||||
"Estatus": "Activa"
|
||||
},
|
||||
"geometry": {
|
||||
"type": "Polygon",
|
||||
"coordinates": [
|
||||
[
|
||||
[
|
||||
-110.9547,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95452,
|
||||
29.09016
|
||||
],
|
||||
[
|
||||
-110.95452,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9547,
|
||||
29.0903
|
||||
],
|
||||
[
|
||||
-110.9547,
|
||||
29.09016
|
||||
]
|
||||
]
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
After Width: | Height: | Size: 125 KiB |
|
After Width: | Height: | Size: 961 KiB |
|
After Width: | Height: | Size: 961 KiB |
|
After Width: | Height: | Size: 54 KiB |
|
After Width: | Height: | Size: 54 KiB |
|
After Width: | Height: | Size: 961 KiB |
|
After Width: | Height: | Size: 54 KiB |
2602
Respaldo_NombresDocumentos_20261003/MetadatosAntes.xml
Normal file
@@ -1,8 +1,11 @@
|
||||
using System;
|
||||
using System.Configuration;
|
||||
using SIG.Web.AppCode.Contracts.Clientes;
|
||||
using SIG.Web.AppCode.Contracts.Convenios;
|
||||
using SIG.Web.AppCode.Repositories.Clientes;
|
||||
using SIG.Web.AppCode.Repositories.Convenios;
|
||||
using SIG.Web.AppCode.Services.Clientes;
|
||||
using SIG.Web.AppCode.Services.Convenios;
|
||||
using SIG.Web.AppCode.Contracts.Bitacora;
|
||||
using SIG.Web.AppCode.Contracts.Database;
|
||||
using SIG.Web.AppCode.Contracts.Documentos;
|
||||
@@ -15,6 +18,7 @@ using SIG.Web.AppCode.Contracts.Security;
|
||||
using SIG.Web.AppCode.Contracts.Tramites;
|
||||
using SIG.Web.AppCode.Contracts.Ventas;
|
||||
using SIG.Web.AppCode.Notifications.Contracts;
|
||||
using SIG.Web.AppCode.Notifications.Repositories;
|
||||
using SIG.Web.AppCode.Notifications.Services;
|
||||
using SIG.Web.AppCode.Repositories.Bitacora;
|
||||
using SIG.Web.AppCode.Repositories.Database;
|
||||
@@ -47,6 +51,7 @@ namespace SIG.Web.AppCode.Configuration
|
||||
public static IBitacoraService BitacoraService { get; private set; }
|
||||
public static IPasswordHasher PasswordHasher { get; private set; }
|
||||
public static IServicioDesarrolladores ServicioDesarrolladores { get; private set; }
|
||||
public static IServicioPortalCliente ServicioPortalCliente { get; private set; }
|
||||
public static ICaptchaService CaptchaService { get; private set; }
|
||||
public static IUserRepository UserRepository { get; private set; }
|
||||
private static IUserAdministrationRepository UserAdministrationRepository { get; set; }
|
||||
@@ -61,11 +66,13 @@ namespace SIG.Web.AppCode.Configuration
|
||||
public static IClienteDocumentoService ClienteDocumentoService { get; private set; }
|
||||
public static ITramiteDocumentoService TramiteDocumentoService { get; private set; }
|
||||
public static IServicioFraccionamiento ServicioFraccionamiento { get; private set; }
|
||||
public static IServicioLotesEtapa ServicioLotesEtapa { get; private set; }
|
||||
public static IServicioGisFraccionamiento ServicioGisFraccionamiento { get; private set; }
|
||||
public static ITramiteCatalogService TramiteCatalogService { get; private set; }
|
||||
public static ITramiteSolicitudService TramiteSolicitudService { get; private set; }
|
||||
public static IServicioVentaTramite ServicioVentaTramite { get; private set; }
|
||||
public static IServicioPagosConvenios ServicioPagosConvenios { get; private set; }
|
||||
public static IServicioConvenios ServicioConvenios { get; private set; }
|
||||
public static IServicioTimbradoCfdi ServicioTimbradoCfdi { get; private set; }
|
||||
public static IPublicRegistrationService PublicRegistrationService { get; private set; }
|
||||
public static ILoginAttemptRepository LoginAttemptRepository { get; private set; }
|
||||
@@ -75,6 +82,8 @@ namespace SIG.Web.AppCode.Configuration
|
||||
public static IPermissionService PermissionService { get; private set; }
|
||||
public static IMenuProvider MenuProvider { get; private set; }
|
||||
public static INotificationCenter NotificationCenter { get; private set; }
|
||||
public static INotificacionService NotificacionService { get; private set; }
|
||||
public static INotificacionConfiguracionService NotificacionConfiguracionService { get; private set; }
|
||||
public static IBuscadorCatalogoDataProvider SearchProvider { get; private set; }
|
||||
|
||||
public static void Configure()
|
||||
@@ -134,6 +143,14 @@ namespace SIG.Web.AppCode.Configuration
|
||||
|
||||
ITramiteSolicitudRepository tramiteSolicitudRepository =
|
||||
new TramiteSolicitudRepository(DbExecutor);
|
||||
INotificacionRepository notificacionRepository =
|
||||
new NotificacionRepository(DbExecutor);
|
||||
NotificacionService = new NotificacionService(
|
||||
notificacionRepository,
|
||||
new SmtpEmailSender());
|
||||
NotificacionConfiguracionService = new NotificacionConfiguracionService(
|
||||
notificacionRepository,
|
||||
NotificacionService);
|
||||
ITramiteDocumentoRepository tramiteDocumentoRepository =
|
||||
new TramiteDocumentoRepository(DbExecutor);
|
||||
ITramiteDocumentoFileStore tramiteDocumentoFileStore =
|
||||
@@ -143,7 +160,8 @@ namespace SIG.Web.AppCode.Configuration
|
||||
tramiteDocumentoFileStore,
|
||||
BitacoraService,
|
||||
UserContext,
|
||||
tramiteSolicitudRepository);
|
||||
tramiteSolicitudRepository,
|
||||
NotificacionConfiguracionService);
|
||||
|
||||
IRepositorioFraccionamiento repositorioFraccionamiento =
|
||||
new RepositorioFraccionamiento(DbExecutor);
|
||||
@@ -153,6 +171,12 @@ namespace SIG.Web.AppCode.Configuration
|
||||
tramiteSolicitudRepository,
|
||||
BitacoraService);
|
||||
|
||||
IRepositorioLotesEtapa repositorioLotesEtapa =
|
||||
new RepositorioLotesEtapa(DbExecutor);
|
||||
ServicioLotesEtapa = new ServicioLotesEtapa(
|
||||
repositorioLotesEtapa,
|
||||
BitacoraService);
|
||||
|
||||
IRepositorioGisFraccionamiento repositorioGis =
|
||||
new RepositorioGisFraccionamiento(DbExecutor);
|
||||
IAlmacenArchivosGisFraccionamiento almacenArchivosGis =
|
||||
@@ -178,7 +202,8 @@ namespace SIG.Web.AppCode.Configuration
|
||||
repositorioFraccionamiento,
|
||||
BitacoraService,
|
||||
TramiteDocumentoService,
|
||||
UserContext);
|
||||
UserContext,
|
||||
NotificacionConfiguracionService);
|
||||
var clienteProfact = new ClienteTimbradoPacProfact(
|
||||
new ProveedorCredencialPacConfiguracion());
|
||||
ServicioTimbradoCfdi = new ServicioTimbradoCfdi(
|
||||
@@ -207,6 +232,14 @@ namespace SIG.Web.AppCode.Configuration
|
||||
|
||||
PermissionService = new PermissionService(
|
||||
permissionRepository);
|
||||
ServicioConvenios = new ServicioConvenios(new RepositorioConvenios(DbExecutor), UserContext);
|
||||
ServicioPortalCliente = new ServicioPortalCliente(
|
||||
new RepositorioPortalCliente(DbExecutor),
|
||||
ServicioFraccionamiento,
|
||||
TramiteDocumentoService,
|
||||
TramiteSolicitudService,
|
||||
new AlmacenComprobantesConvenio(),
|
||||
UserContext);
|
||||
ServicioPagosConvenios = new ServicioPagosConvenios(
|
||||
new RepositorioPagosConvenios(DbExecutor),
|
||||
tramiteSolicitudRepository,
|
||||
|
||||
@@ -59,14 +59,20 @@ namespace SIG.Web.AppCode.Configuration
|
||||
"~/Scripts/SigPdfDrawer.js",
|
||||
"~/Scripts/PanelLateral.js",
|
||||
"~/Scripts/DocumentosEtapa.js",
|
||||
"~/Scripts/DocumentosEtapaCargaMasiva.js",
|
||||
"~/Scripts/SigVisualizadorArchivo.js",
|
||||
"~/Scripts/DocumentosEtapaNavegacion.js",
|
||||
"~/Scripts/Visitas.js",
|
||||
"~/Scripts/PagosConvenios.js",
|
||||
"~/Scripts/custom.js",
|
||||
"~/Scripts/sig-alerts.js",
|
||||
"~/Scripts/filtrosig.js",
|
||||
"~/Scripts/scrollsig.js"
|
||||
));
|
||||
|
||||
"~/Scripts/scrollsig.js",
|
||||
"~/Scripts/sig-grid-agrupado.js",
|
||||
"~/Scripts/Convenios.js",
|
||||
"~/Scripts/VisorGis.js",
|
||||
"~/Scripts/LotesEtapa.js"
|
||||
));
|
||||
bundles.Add(new ScriptBundle("~/bundles/WebFormsJs").Include(
|
||||
"~/Scripts/WebForms/WebForms.js",
|
||||
"~/Scripts/WebForms/WebUIValidation.js",
|
||||
@@ -124,11 +130,19 @@ namespace SIG.Web.AppCode.Configuration
|
||||
"~/Styles/SigPdfViewer.css",
|
||||
"~/Styles/SigPdfDrawer.css",
|
||||
"~/Styles/PanelLateral.css",
|
||||
"~/Styles/SigVisualizadorArchivo.css",
|
||||
"~/Styles/DetalleEtapa.css",
|
||||
"~/Styles/DocumentosEtapa.css",
|
||||
"~/Styles/DocumentosEtapaCargaMasiva.css",
|
||||
"~/Styles/DocumentosEtapaNavegacion.css",
|
||||
"~/Styles/Archivos.css",
|
||||
"~/Styles/Estilos.css",
|
||||
"~/Styles/filtrosig.css",
|
||||
"~/Styles/scrollsig.css",
|
||||
"~/Styles/sig-grid-agrupado.css",
|
||||
"~/Styles/Convenios.css",
|
||||
"~/Styles/VisorGis.css",
|
||||
"~/Styles/LotesEtapa.css",
|
||||
"~/Metronic/assets/global/plugins/bootstrap-switch/css/bootstrap-switch.min.css",
|
||||
"~/Metronic/assets/global/plugins/bootstrap-toastr/toastr.min.css",
|
||||
"~/Metronic/assets/layouts/layout3/css/jquery.datetimepicker.css",
|
||||
|
||||
@@ -0,0 +1,40 @@
|
||||
using System.Collections.Generic;
|
||||
using SIG.Web.AppCode.Models.Clientes;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
|
||||
namespace SIG.Web.AppCode.Contracts.Clientes
|
||||
{
|
||||
public interface IRepositorioPortalCliente
|
||||
{
|
||||
DbResult<List<PagoPendienteTramiteCliente>> ListarPagosPendientesTramites(
|
||||
int cveCliente,
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<List<PagoConvenioClienteFila>> ListarPagos(
|
||||
int cveCliente,
|
||||
int? cveFraccionamiento,
|
||||
int? cveFraccionamientoEtapa,
|
||||
string agrupacion,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<List<ReciboConvenioDisponibleCliente>> ListarRecibosDisponibles(
|
||||
int cveCliente,
|
||||
int? cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<int> AgregarPago(
|
||||
SolicitudPagoConvenioCliente pago,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<ArchivoPagoConvenioCliente> ObtenerArchivoPago(
|
||||
int cveConvenioPago,
|
||||
int cveCliente,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,90 @@
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using SIG.Web.AppCode.Models.Clientes;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Fraccionamientos;
|
||||
using SIG.Web.AppCode.Models.Tramites;
|
||||
|
||||
namespace SIG.Web.AppCode.Contracts.Clientes
|
||||
{
|
||||
public interface IServicioPortalCliente
|
||||
{
|
||||
DbResult<List<ModeloFilaDesarrollos>> ListarDesarrollos(
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<ModeloFraccionamiento> ObtenerFraccionamiento(
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<ResultadoGuardarFraccionamientoConEtapas> GuardarFraccionamientoConEtapa(
|
||||
ModeloFraccionamiento fraccionamiento,
|
||||
ModeloEtapaFraccionamiento etapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<int> GuardarFraccionamiento(
|
||||
ModeloFraccionamiento fraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<List<ModeloEtapaFraccionamiento>> ListarEtapas(
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<ModeloEtapaFraccionamiento> ObtenerEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<int> GuardarEtapa(
|
||||
ModeloEtapaFraccionamiento etapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<List<TramiteClienteListado>> ListarTramites(
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<List<TramiteClienteListado>> ListarTramites(
|
||||
int cveFraccionamiento,
|
||||
int? cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<TramiteSolicitudStatusChangeModel> EnviarRevision(
|
||||
int cveSolicitud,
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<List<DocumentoClientePortal>> ListarDocumentos(
|
||||
FiltroDocumentosCliente filtro,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<List<PagoConvenioClienteFila>> ListarPagos(
|
||||
FiltroPagosCliente filtro,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<List<ReciboConvenioDisponibleCliente>> ListarRecibosDisponibles(
|
||||
int? cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<int> RegistrarPago(
|
||||
SolicitudPagoConvenioCliente pago,
|
||||
Stream contenido,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<ArchivoPagoConvenioCliente> ObtenerArchivoPago(
|
||||
int cveConvenioPago,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using System.Collections.Generic;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Convenios;
|
||||
|
||||
namespace SIG.Web.AppCode.Contracts.Convenios
|
||||
{
|
||||
public interface IRepositorioConvenios
|
||||
{
|
||||
DbResult<List<ConvenioListado>> Listar(FiltroConvenios filtro, int usuario, string dominio);
|
||||
DbResult<ConvenioDetalleCompleto> Obtener(int cveConvenio, int usuario, string dominio);
|
||||
DbResult<List<ConvenioConceptoCatalogo>> ListarConceptos(int usuario, string dominio);
|
||||
DbResult<int> Agregar(SolicitudAltaConvenio solicitud, int usuario, string dominio);
|
||||
DbResult<ConvenioLotesConvenio> ObtenerLotesConvenio(int cveConvenio, int usuario, string dominio);
|
||||
DbResult<bool> GuardarLotesConvenio(int cveConvenio, int lotesConvenio, int usuario, string dominio);
|
||||
DbResult<bool> Eliminar(int cveConvenio, int usuario, string dominio);
|
||||
}
|
||||
}
|
||||
15
SIG.Web/App_Code/Contracts/Convenios/IServicioConvenios.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using System.Collections.Generic;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Convenios;
|
||||
|
||||
namespace SIG.Web.AppCode.Contracts.Convenios
|
||||
{
|
||||
public interface IServicioConvenios
|
||||
{
|
||||
DbResult<List<ConvenioListado>> Listar(FiltroConvenios filtro, int usuario, string dominio);
|
||||
DbResult<ConvenioDetalleCompleto> Obtener(int cveConvenio, int usuario, string dominio);
|
||||
DbResult<List<ConvenioConceptoCatalogo>> ListarConceptos(int usuario, string dominio);
|
||||
DbResult<int> Agregar(SolicitudAltaConvenio solicitud, int usuario, string dominio);
|
||||
DbResult<bool> Eliminar(int cveConvenio, int usuario, string dominio);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
using System.IO;
|
||||
using SIG.Web.AppCode.Models.Clientes;
|
||||
|
||||
namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
{
|
||||
public interface IAlmacenComprobantesConvenio
|
||||
{
|
||||
void Guardar(
|
||||
SolicitudPagoConvenioCliente pago,
|
||||
Stream contenido);
|
||||
|
||||
string Resolver(
|
||||
int cveCliente,
|
||||
string nombreFisico);
|
||||
|
||||
void Eliminar(
|
||||
int cveCliente,
|
||||
string nombreFisico);
|
||||
}
|
||||
}
|
||||
@@ -8,7 +8,8 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
TramiteDocumentoPreparedFile Prepare(
|
||||
TramiteDocumentoUploadContextModel context,
|
||||
Stream source,
|
||||
string previousRelativePath);
|
||||
string previousRelativePath,
|
||||
string nombreArchivoOriginal);
|
||||
|
||||
void Promote(TramiteDocumentoPreparedFile preparedFile);
|
||||
void Rollback(TramiteDocumentoPreparedFile preparedFile);
|
||||
|
||||
@@ -5,6 +5,9 @@ using SIG.Web.AppCode.Models.Documentos;
|
||||
|
||||
namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
{
|
||||
// Los documentos y sus marcas particulares pertenecen a etapa y tipo de documento.
|
||||
// Los parámetros de trámite en carga se conservan por compatibilidad;
|
||||
// sólo los listados de requisitos utilizan el trámite como filtro.
|
||||
public interface ITramiteDocumentoRepository
|
||||
{
|
||||
DbResult<List<SolicitudDocumentoConfiguracionModel>> ListarConfiguracionSolicitud(
|
||||
@@ -12,7 +15,8 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
int cveSolicitud,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio,
|
||||
int? cveFraccionamientoEtapa = null);
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null);
|
||||
|
||||
DbResult<bool> ActualizarVencimientoEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
@@ -30,7 +34,8 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
int cveTipoDocumento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio,
|
||||
int? cveFraccionamientoEtapa = null);
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null);
|
||||
|
||||
DbResult<List<TramiteDocumentoSolicitudModel>> ListForDevelopment(
|
||||
int developmentId,
|
||||
@@ -52,7 +57,8 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
int documentTypeId,
|
||||
int executingUser,
|
||||
string domainName,
|
||||
int? cveFraccionamientoEtapa = null);
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null);
|
||||
|
||||
DbResult<TramiteDocumentoUploadContextModel> GetStageUploadContext(
|
||||
int stageId,
|
||||
@@ -76,7 +82,22 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
DateTime? fechaDocumento = null,
|
||||
DateTime? fechaVencimiento = null,
|
||||
bool actualizarFechas = false,
|
||||
int? cveFraccionamientoEtapa = null);
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null);
|
||||
|
||||
DbResult<TramiteDocumentoVencimientoResultModel> ActualizarFechaVencimiento(
|
||||
int cveFraccionamiento,
|
||||
int cveDocumentoSolicitud,
|
||||
DateTime? fechaVencimiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<TramiteDocumentoNotaResultModel> ActualizarNota(
|
||||
int cveFraccionamiento,
|
||||
int cveDocumentoSolicitud,
|
||||
string nota,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<TramiteDocumentoReviewResultModel> Review(
|
||||
int developmentId,
|
||||
|
||||
@@ -7,6 +7,9 @@ using SIG.Web.AppCode.Models.Documentos;
|
||||
|
||||
namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
{
|
||||
// Los documentos y sus marcas particulares pertenecen a etapa y tipo de documento.
|
||||
// Los parámetros de trámite en carga se conservan por compatibilidad;
|
||||
// sólo los listados de requisitos utilizan el trámite como filtro.
|
||||
public interface ITramiteDocumentoService
|
||||
{
|
||||
DbResult<List<SolicitudDocumentoConfiguracionModel>> ListarConfiguracionSolicitud(
|
||||
@@ -14,7 +17,8 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
int cveSolicitud,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio,
|
||||
int? cveFraccionamientoEtapa = null);
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null);
|
||||
|
||||
DbResult<bool> ActualizarVencimientoEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
@@ -32,7 +36,8 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
int cveTipoDocumento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio,
|
||||
int? cveFraccionamientoEtapa = null);
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null);
|
||||
|
||||
DbResult<List<TramiteDocumentoSolicitudModel>> ListForDevelopment(
|
||||
int developmentId,
|
||||
@@ -54,7 +59,8 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
int documentTypeId,
|
||||
int executingUser,
|
||||
string domainName,
|
||||
int? cveFraccionamientoEtapa = null);
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null);
|
||||
|
||||
DbResult<TramiteDocumentoSaveResultModel> Upload(
|
||||
int developmentId,
|
||||
@@ -69,7 +75,8 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
string domainName,
|
||||
DateTime? fechaDocumento = null,
|
||||
DateTime? fechaVencimiento = null,
|
||||
int? cveFraccionamientoEtapa = null);
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null);
|
||||
|
||||
DbResult<bool> Eliminar(
|
||||
int cveFraccionamiento,
|
||||
@@ -78,6 +85,20 @@ namespace SIG.Web.AppCode.Contracts.Documentos
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<TramiteDocumentoVencimientoResultModel> ActualizarFechaVencimiento(
|
||||
int cveFraccionamiento,
|
||||
int cveDocumentoSolicitud,
|
||||
DateTime? fechaVencimiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<TramiteDocumentoNotaResultModel> ActualizarNota(
|
||||
int cveFraccionamiento,
|
||||
int cveDocumentoSolicitud,
|
||||
string nota,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<TramiteDocumentoReviewResultModel> Review(
|
||||
int developmentId,
|
||||
int documentRequestId,
|
||||
|
||||
@@ -8,6 +8,7 @@ namespace SIG.Web.AppCode.Contracts.Fraccionamientos
|
||||
string ObtenerRutaFisica(ContextoGisFraccionamiento contexto);
|
||||
bool Existe(ContextoGisFraccionamiento contexto);
|
||||
void Guardar(ContextoGisFraccionamiento contexto, Stream origen);
|
||||
Stream GuardarOriginalZip(ContextoGisFraccionamiento contexto, Stream origen, long longitud);
|
||||
Stream AbrirLectura(ContextoGisFraccionamiento contexto);
|
||||
void Eliminar(ContextoGisFraccionamiento contexto);
|
||||
}
|
||||
|
||||
57
SIG.Web/App_Code/Contracts/Fraccionamientos/ILotesEtapa.cs
Normal file
@@ -0,0 +1,57 @@
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Fraccionamientos;
|
||||
|
||||
namespace SIG.Web.AppCode.Contracts.Fraccionamientos
|
||||
{
|
||||
public interface IRepositorioLotesEtapa
|
||||
{
|
||||
DbResult<ModeloLoteFraccionamiento> Obtener(
|
||||
int cveFraccionamiento, int cveLote,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<int> CambiarAprobacion(
|
||||
int cveFraccionamiento, int cveLote, bool aprobado,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<int> CambiarBloqueo(
|
||||
int cveFraccionamiento, int cveLote, bool bloqueado,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<int> ActualizarInfraestructura(
|
||||
int cveFraccionamiento, int cveLote,
|
||||
decimal avanceAgua, decimal avanceDrenaje,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<int> CambiarAutorizacionAgua(
|
||||
int cveFraccionamiento, int cveLote, bool autorizado,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<int> CambiarAutorizacionDrenaje(
|
||||
int cveFraccionamiento, int cveLote, bool autorizado,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
}
|
||||
|
||||
public interface IServicioLotesEtapa
|
||||
{
|
||||
DbResult<bool> CambiarAprobacion(
|
||||
int cveFraccionamiento, int cveLote, bool aprobado,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<bool> CambiarBloqueo(
|
||||
int cveFraccionamiento, int cveLote, bool bloqueado,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<bool> ActualizarInfraestructura(
|
||||
int cveFraccionamiento, int cveLote,
|
||||
decimal avanceAgua, decimal avanceDrenaje,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<bool> CambiarAutorizacionAgua(
|
||||
int cveFraccionamiento, int cveLote, bool autorizado,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<bool> CambiarAutorizacionDrenaje(
|
||||
int cveFraccionamiento, int cveLote, bool autorizado,
|
||||
int cveUsuarioEjecuta, string nombreDominio);
|
||||
}
|
||||
}
|
||||
@@ -6,6 +6,17 @@ namespace SIG.Web.AppCode.Contracts.Fraccionamientos
|
||||
{
|
||||
public interface IRepositorioGisFraccionamiento
|
||||
{
|
||||
DbResult<List<CapaGisFraccionamiento>> ListarCapas(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<bool> GuardarCapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
CapaGisFraccionamiento capa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<ContextoGisFraccionamiento> ObtenerContexto(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
|
||||
@@ -14,89 +14,33 @@ namespace SIG.Web.AppCode.Contracts.Fraccionamientos
|
||||
DbResult<int> VincularLoteTipoViviendaEtapa(int cveEtapa, int cveRegistro, int cveLote, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<bool> DesvincularLoteTipoViviendaEtapa(int cveEtapa, int cveVinculo, int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<List<ModeloFilaDesarrollos>> ListarDesarrollos(
|
||||
int cveCliente, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<List<ModeloFilaDesarrollos>> ListarDesarrollos( int cveCliente, int cveUsuarioEjecuta, string nombreDominio);
|
||||
|
||||
DbResult<List<OpcionClienteFraccionamiento>> ListarClientes(int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<List<OpcionEstatusFraccionamiento>> ListarEstatus(int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<List<ModeloFraccionamiento>> Listar(string texto, int? cveCliente, bool incluirInactivo, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<ModeloFraccionamiento> Obtener(int cveFraccionamiento, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<List<ModeloAvisoDetalleFraccionamiento>> ObtenerAvisosDetalle(
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<int> GuardarConEtapas(
|
||||
ModeloFraccionamiento fraccionamiento,
|
||||
IList<ModeloEtapaFraccionamiento> etapas,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<List<ModeloAvisoDetalleFraccionamiento>> ObtenerAvisosDetalle( int cveFraccionamiento, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<ResultadoGuardarFraccionamientoConEtapas> GuardarConEtapas(
|
||||
ModeloFraccionamiento fraccionamiento, IList<ModeloEtapaFraccionamiento> etapas, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<int> Guardar(ModeloFraccionamiento fraccionamiento, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<bool> Eliminar(int cveFraccionamiento, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<List<ModeloEtapaFraccionamiento>> ListarEtapas(int cveFraccionamiento, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<ModeloEtapaFraccionamiento> ObtenerEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<ResultadoAvanceEtapaFraccionamiento> ActualizarAvanceEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
decimal avance,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<ModeloCondicionesEtapaFraccionamiento> ObtenerCondicionesEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<ModeloCondicionesEtapaFraccionamiento> GuardarCondicionesEtapa(
|
||||
ModeloCondicionesEtapaFraccionamiento condiciones,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<ModeloGisEtapaFraccionamiento> ObtenerGisEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<ModeloGisEtapaFraccionamiento> GuardarGisEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<ModeloEtapaFraccionamiento> ObtenerEtapa( int cveFraccionamientoEtapa, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<ResultadoAvanceEtapaFraccionamiento> ActualizarAvanceEtapa( int cveFraccionamientoEtapa, decimal avance, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<ModeloCondicionesEtapaFraccionamiento> ObtenerCondicionesEtapa( int cveFraccionamientoEtapa, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<ModeloCondicionesEtapaFraccionamiento> GuardarCondicionesEtapa( ModeloCondicionesEtapaFraccionamiento condiciones, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<ModeloGisEtapaFraccionamiento> ObtenerGisEtapa( int cveFraccionamientoEtapa, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<ModeloGisEtapaFraccionamiento> GuardarGisEtapa( int cveFraccionamientoEtapa, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<List<ModeloTramiteEtapaFraccionamiento>> ListarTramitesEtapa(int cveFraccionamiento, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<int> GuardarEtapa(ModeloEtapaFraccionamiento etapa, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<bool> MoverOrdenEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveFraccionamientoEtapaReferencia,
|
||||
bool colocarDespues,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<bool> MoverOrdenEtapa( int cveFraccionamientoEtapa, int cveFraccionamientoEtapaReferencia, bool colocarDespues, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<bool> EliminarEtapa(int cveFraccionamientoEtapa, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<List<ModeloLoteFraccionamiento>> ListarLotes(
|
||||
int cveFraccionamiento,
|
||||
int? cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<ModeloLoteFraccionamiento> ObtenerLote(
|
||||
int cveFraccionamiento,
|
||||
int cveFraccionamientoLote,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<int> GuardarLote(
|
||||
int cveFraccionamiento,
|
||||
ModeloLoteFraccionamiento lote,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<int> GuardarLotes(
|
||||
int cveFraccionamiento,
|
||||
int cveFraccionamientoEtapa,
|
||||
IList<ModeloLoteFraccionamiento> lotes,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<bool> EliminarLote(
|
||||
int cveFraccionamiento,
|
||||
int cveFraccionamientoLote,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<int> LimpiarLotesEtapa(
|
||||
int cveFraccionamiento,
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
DbResult<List<ModeloLoteFraccionamiento>> ListarLotes(int cveFraccionamiento,int? cveFraccionamientoEtapa,int cveUsuarioEjecuta,string nombreDominio);
|
||||
DbResult<ModeloLoteFraccionamiento> ObtenerLote(int cveFraccionamiento,int cveFraccionamientoLote, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<int> GuardarLote( int cveFraccionamiento, ModeloLoteFraccionamiento lote, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<int> GuardarLotes( int cveFraccionamiento, int cveFraccionamientoEtapa, IList<ModeloLoteFraccionamiento> lotes, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<bool> EliminarLote( int cveFraccionamiento, int cveFraccionamientoLote, int cveUsuarioEjecuta, string nombreDominio);
|
||||
DbResult<int> LimpiarLotesEtapa( int cveFraccionamiento, int cveFraccionamientoEtapa, int cveUsuarioEjecuta, string nombreDominio);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,6 +7,31 @@ namespace SIG.Web.AppCode.Contracts.Fraccionamientos
|
||||
{
|
||||
public interface IServicioGisFraccionamiento
|
||||
{
|
||||
DbResult<ResultadoGuardadoGisFraccionamiento> DesvincularLote(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveFraccionamientoLote,
|
||||
string clavePoligono,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<ResultadoGuardadoGisFraccionamiento> VincularLote(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveFraccionamientoLote,
|
||||
string clavePoligono,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<List<CapaGisFraccionamiento>> ListarCapas(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<bool> GuardarCapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
CapaGisFraccionamiento capa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
|
||||
DbResult<VistaGisFraccionamiento> Obtener(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
|
||||
@@ -5,5 +5,6 @@ namespace SIG.Web.AppCode.Contracts.Security
|
||||
bool IsConfigured { get; }
|
||||
void SendVerification(string recipient, string verificationUrl);
|
||||
void EnviarContrasena(string destinatario, string nombreUsuario, string contrasena);
|
||||
void Send(string recipient, string subject, string htmlBody);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -75,6 +75,7 @@ namespace SIG.Web.AppCode.Contracts.Tramites
|
||||
DbResult<TramiteSolicitudStatusChangeModel> CambiarEstatus(
|
||||
ModeloCambioEstatusTramite cambioEstatus,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio);
|
||||
string nombreDominio,
|
||||
bool validarPagosRequeridos = true);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,73 @@
|
||||
using System;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Web;
|
||||
using System.Web.SessionState;
|
||||
using SIG.Web.AppCode.Configuration;
|
||||
using SIG.Web.AppCode.Models.Clientes;
|
||||
using SIG.Web.AppCode.Session;
|
||||
|
||||
namespace SIG.Web.Pages.Clientes
|
||||
{
|
||||
public sealed class ComprobanteConvenioPagoHandler
|
||||
: IHttpHandler, IReadOnlySessionState
|
||||
{
|
||||
public bool IsReusable
|
||||
{
|
||||
get { return false; }
|
||||
}
|
||||
|
||||
public void ProcessRequest(HttpContext contexto)
|
||||
{
|
||||
UserSessionModel usuario = AppServices.UserContext.GetCurrentUser();
|
||||
|
||||
if (usuario == null ||
|
||||
!AppServices.UserContext.IsAuthenticated() ||
|
||||
!usuario.EsDesarrollador)
|
||||
{
|
||||
contexto.Response.StatusCode = 401;
|
||||
return;
|
||||
}
|
||||
|
||||
int cvePago;
|
||||
|
||||
if (!int.TryParse(
|
||||
contexto.Request.QueryString["id"],
|
||||
NumberStyles.Integer,
|
||||
CultureInfo.InvariantCulture,
|
||||
out cvePago) ||
|
||||
cvePago <= 0)
|
||||
{
|
||||
contexto.Response.StatusCode = 404;
|
||||
return;
|
||||
}
|
||||
|
||||
var resultado = AppServices.ServicioPortalCliente.ObtenerArchivoPago(
|
||||
cvePago,
|
||||
usuario.CveUsuario,
|
||||
usuario.NombreDominio);
|
||||
|
||||
if (!resultado.Success ||
|
||||
resultado.Data == null ||
|
||||
string.IsNullOrWhiteSpace(resultado.Data.RutaFisica) ||
|
||||
!File.Exists(resultado.Data.RutaFisica))
|
||||
{
|
||||
contexto.Response.StatusCode = 404;
|
||||
return;
|
||||
}
|
||||
|
||||
ArchivoPagoConvenioCliente archivo = resultado.Data;
|
||||
contexto.Response.Clear();
|
||||
contexto.Response.ContentType = archivo.TipoContenido;
|
||||
contexto.Response.AddHeader("X-Content-Type-Options", "nosniff");
|
||||
contexto.Response.AddHeader(
|
||||
"Content-Disposition",
|
||||
"attachment; filename*=UTF-8''" +
|
||||
Uri.EscapeDataString(archivo.NombreArchivo));
|
||||
contexto.Response.Cache.SetCacheability(HttpCacheability.NoCache);
|
||||
contexto.Response.Cache.SetNoStore();
|
||||
contexto.Response.TransmitFile(archivo.RutaFisica);
|
||||
contexto.ApplicationInstance.CompleteRequest();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Web;
|
||||
@@ -7,6 +7,7 @@ using SIG.Web.AppCode.Configuration;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Documentos;
|
||||
using SIG.Web.AppCode.Session;
|
||||
using SIG.Web.AppCode.SigControls;
|
||||
|
||||
namespace SIG.Web.Pages.Fraccionamientos
|
||||
{
|
||||
@@ -24,9 +25,9 @@ namespace SIG.Web.Pages.Fraccionamientos
|
||||
|
||||
if (currentUser == null)
|
||||
{
|
||||
context.Response.StatusCode = 401;
|
||||
context.Response.ContentType = "text/plain";
|
||||
context.Response.Write(
|
||||
RespondError(
|
||||
context,
|
||||
401,
|
||||
"Su sesión no está disponible. Inicie sesión nuevamente.");
|
||||
return;
|
||||
}
|
||||
@@ -41,9 +42,10 @@ namespace SIG.Web.Pages.Fraccionamientos
|
||||
context.Request.QueryString["documento"],
|
||||
out documentRequestId))
|
||||
{
|
||||
context.Response.StatusCode = 400;
|
||||
context.Response.ContentType = "text/plain";
|
||||
context.Response.Write("El documento solicitado no es válido.");
|
||||
RespondError(
|
||||
context,
|
||||
400,
|
||||
"El documento solicitado no es válido.");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -58,9 +60,9 @@ namespace SIG.Web.Pages.Fraccionamientos
|
||||
result.Data == null ||
|
||||
result.Data.Content == null)
|
||||
{
|
||||
context.Response.StatusCode = 404;
|
||||
context.Response.ContentType = "text/plain";
|
||||
context.Response.Write(
|
||||
RespondError(
|
||||
context,
|
||||
404,
|
||||
result == null ||
|
||||
string.IsNullOrWhiteSpace(result.UserMessage)
|
||||
? "No se encontró el documento."
|
||||
@@ -69,21 +71,104 @@ namespace SIG.Web.Pages.Fraccionamientos
|
||||
}
|
||||
|
||||
TramiteDocumentoFileModel file = result.Data;
|
||||
bool visualizar = string.Equals(
|
||||
context.Request.QueryString["vista"],
|
||||
"1",
|
||||
StringComparison.Ordinal);
|
||||
|
||||
context.Response.Clear();
|
||||
context.Response.ClearHeaders();
|
||||
context.Response.TrySkipIisCustomErrors = true;
|
||||
context.Response.Cache.SetCacheability(HttpCacheability.NoCache);
|
||||
context.Response.Cache.SetNoStore();
|
||||
context.Response.ContentType =
|
||||
string.IsNullOrWhiteSpace(file.ContentType)
|
||||
string nombreArchivo = SanitizeFileName(file.NombreArchivo);
|
||||
string tipoContenido = string.IsNullOrWhiteSpace(file.ContentType)
|
||||
? MimeMapping.GetMimeMapping(nombreArchivo)
|
||||
: file.ContentType;
|
||||
|
||||
if (visualizar &&
|
||||
SigVisualizadorArchivoOfficeConverter.EsArchivoOffice(
|
||||
nombreArchivo,
|
||||
tipoContenido))
|
||||
{
|
||||
using (file.Content)
|
||||
using (var contenidoOffice = new MemoryStream())
|
||||
{
|
||||
file.Content.CopyTo(contenidoOffice);
|
||||
contenidoOffice.Position = 0;
|
||||
|
||||
if (SigVisualizadorArchivoVistaPreviaExcel.EsCompatible(nombreArchivo))
|
||||
{
|
||||
byte[] vistaPreviaExcel;
|
||||
string errorExcel;
|
||||
|
||||
if (SigVisualizadorArchivoVistaPreviaExcel.IntentarGenerarHtml(
|
||||
contenidoOffice,
|
||||
nombreArchivo,
|
||||
out vistaPreviaExcel,
|
||||
out errorExcel))
|
||||
{
|
||||
PrepareResponse(
|
||||
context,
|
||||
"text/html; charset=utf-8",
|
||||
false,
|
||||
Path.GetFileNameWithoutExtension(nombreArchivo) + ".html");
|
||||
context.Response.OutputStream.Write(
|
||||
vistaPreviaExcel,
|
||||
0,
|
||||
vistaPreviaExcel.Length);
|
||||
context.ApplicationInstance.CompleteRequest();
|
||||
return;
|
||||
}
|
||||
|
||||
contenidoOffice.Position = 0;
|
||||
}
|
||||
|
||||
SigVisualizadorArchivoOfficeResultado conversion;
|
||||
string errorConversion;
|
||||
|
||||
if (SigVisualizadorArchivoOfficeConverter.IntentarConvertir(
|
||||
contenidoOffice,
|
||||
nombreArchivo,
|
||||
out conversion,
|
||||
out errorConversion))
|
||||
{
|
||||
using (conversion)
|
||||
using (var contenidoPdf = new FileStream(
|
||||
conversion.RutaPdf,
|
||||
FileMode.Open,
|
||||
FileAccess.Read,
|
||||
FileShare.Read))
|
||||
{
|
||||
PrepareResponse(
|
||||
context,
|
||||
"application/pdf",
|
||||
false,
|
||||
Path.GetFileNameWithoutExtension(nombreArchivo) + ".pdf");
|
||||
contenidoPdf.CopyTo(context.Response.OutputStream);
|
||||
}
|
||||
|
||||
context.ApplicationInstance.CompleteRequest();
|
||||
return;
|
||||
}
|
||||
|
||||
RespondError(
|
||||
context,
|
||||
415,
|
||||
string.IsNullOrWhiteSpace(errorConversion)
|
||||
? "No fue posible generar la vista previa del archivo de Office."
|
||||
: errorConversion);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (visualizar && EsArchivoGis(nombreArchivo))
|
||||
{
|
||||
tipoContenido = "application/geo+json; charset=utf-8";
|
||||
}
|
||||
|
||||
PrepareResponse(
|
||||
context,
|
||||
string.IsNullOrWhiteSpace(tipoContenido)
|
||||
? "application/octet-stream"
|
||||
: file.ContentType;
|
||||
context.Response.AddHeader(
|
||||
"Content-Disposition",
|
||||
"attachment; filename=\"" +
|
||||
SanitizeFileName(file.NombreArchivo) +
|
||||
"\"");
|
||||
: tipoContenido,
|
||||
!visualizar,
|
||||
nombreArchivo);
|
||||
|
||||
using (file.Content)
|
||||
{
|
||||
@@ -93,6 +178,40 @@ namespace SIG.Web.Pages.Fraccionamientos
|
||||
context.ApplicationInstance.CompleteRequest();
|
||||
}
|
||||
|
||||
private static void PrepareResponse(
|
||||
HttpContext context,
|
||||
string contentType,
|
||||
bool download,
|
||||
string fileName)
|
||||
{
|
||||
context.Response.Clear();
|
||||
context.Response.ClearHeaders();
|
||||
context.Response.TrySkipIisCustomErrors = true;
|
||||
context.Response.Cache.SetCacheability(HttpCacheability.NoCache);
|
||||
context.Response.Cache.SetNoStore();
|
||||
context.Response.ContentType = contentType;
|
||||
context.Response.AddHeader(
|
||||
"Content-Disposition",
|
||||
(download ? "attachment" : "inline") +
|
||||
"; filename=\"" + SanitizeFileName(fileName) + "\"");
|
||||
}
|
||||
|
||||
private static void RespondError(
|
||||
HttpContext context,
|
||||
int statusCode,
|
||||
string message)
|
||||
{
|
||||
context.Response.Clear();
|
||||
context.Response.StatusCode = statusCode;
|
||||
context.Response.TrySkipIisCustomErrors = true;
|
||||
context.Response.ContentType = "text/plain; charset=utf-8";
|
||||
context.Response.AddHeader(
|
||||
"X-SIG-Visualizador-Mensaje",
|
||||
HttpUtility.UrlEncode(message ?? string.Empty));
|
||||
context.Response.Write(message);
|
||||
context.ApplicationInstance.CompleteRequest();
|
||||
}
|
||||
|
||||
private static UserSessionModel GetCurrentUser()
|
||||
{
|
||||
return AppServices.UserContext != null &&
|
||||
@@ -113,6 +232,13 @@ namespace SIG.Web.Pages.Fraccionamientos
|
||||
result > 0;
|
||||
}
|
||||
|
||||
private static bool EsArchivoGis(string nombreArchivo)
|
||||
{
|
||||
string extension = Path.GetExtension(nombreArchivo ?? string.Empty);
|
||||
return string.Equals(extension, ".gis", StringComparison.OrdinalIgnoreCase) ||
|
||||
string.Equals(extension, ".geojson", StringComparison.OrdinalIgnoreCase);
|
||||
}
|
||||
|
||||
private static string SanitizeFileName(string fileName)
|
||||
{
|
||||
string value = Path.GetFileName(
|
||||
|
||||
@@ -0,0 +1,538 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Web;
|
||||
using System.Web.SessionState;
|
||||
using SIG.Web.AppCode.Configuration;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Documentos;
|
||||
using SIG.Web.AppCode.Session;
|
||||
using SIG.Web.AppCode.Services.Logging;
|
||||
|
||||
namespace SIG.Web.Pages.Fraccionamientos
|
||||
{
|
||||
/// <summary>
|
||||
/// Descarga en un ZIP todos los archivos visibles para el usuario en el
|
||||
/// contexto actual del control DocumentosEtapa.
|
||||
///
|
||||
/// El escritor ZIP incluido aquí usa el método STORE (sin compresión) para
|
||||
/// no agregar dependencias nuevas al proyecto. El resultado sigue siendo
|
||||
/// un archivo .zip estándar.
|
||||
/// </summary>
|
||||
public sealed class TramiteDocumentosZipHandler
|
||||
: IHttpHandler, IRequiresSessionState
|
||||
{
|
||||
public bool IsReusable
|
||||
{
|
||||
get { return false; }
|
||||
}
|
||||
|
||||
public void ProcessRequest(HttpContext context)
|
||||
{
|
||||
UserSessionModel usuario = ObtenerUsuario();
|
||||
if (usuario == null)
|
||||
{
|
||||
ResponderError(context, 401, "Su sesión no está disponible. Inicie sesión nuevamente.");
|
||||
return;
|
||||
}
|
||||
|
||||
int cveFraccionamiento;
|
||||
if (!LeerEntero(context.Request.QueryString["fraccionamiento"], out cveFraccionamiento) ||
|
||||
cveFraccionamiento <= 0)
|
||||
{
|
||||
ResponderError(context, 400, "El fraccionamiento solicitado no es válido.");
|
||||
return;
|
||||
}
|
||||
|
||||
int? cveEtapa;
|
||||
int? cveTipoTramite;
|
||||
if (!LeerEnteroOpcional(context.Request.QueryString["etapa"], out cveEtapa) ||
|
||||
!LeerEnteroOpcional(context.Request.QueryString["tramite"], out cveTipoTramite))
|
||||
{
|
||||
ResponderError(context, 400, "Los filtros de descarga no son válidos.");
|
||||
return;
|
||||
}
|
||||
|
||||
DbResult<List<TramiteDocumentoSolicitudModel>> consulta =
|
||||
AppServices.TramiteDocumentoService.ListForDevelopment(
|
||||
cveFraccionamiento,
|
||||
cveEtapa,
|
||||
cveTipoTramite,
|
||||
usuario.CveUsuario,
|
||||
usuario.NombreDominio);
|
||||
|
||||
if (!consulta.Success)
|
||||
{
|
||||
ResponderError(context, 400, consulta.UserMessage ?? "No fue posible consultar los documentos.");
|
||||
return;
|
||||
}
|
||||
|
||||
List<TramiteDocumentoSolicitudModel> documentos =
|
||||
(consulta.Data ?? new List<TramiteDocumentoSolicitudModel>())
|
||||
.Where(documento => documento.TieneArchivo && documento.CveDocumentoSolicitud > 0)
|
||||
.GroupBy(documento => documento.CveDocumentoSolicitud)
|
||||
.Select(grupo => grupo.First())
|
||||
.ToList();
|
||||
|
||||
if (documentos.Count == 0)
|
||||
{
|
||||
ResponderError(context, 404, "No hay archivos cargados para descargar.");
|
||||
return;
|
||||
}
|
||||
|
||||
string rutaTemporal = Path.Combine(
|
||||
Path.GetTempPath(),
|
||||
"SIG-Documentos-" + Guid.NewGuid().ToString("N") + ".zip");
|
||||
|
||||
try
|
||||
{
|
||||
List<string> errores;
|
||||
int agregados = CrearZip(
|
||||
rutaTemporal,
|
||||
documentos,
|
||||
cveFraccionamiento,
|
||||
usuario,
|
||||
out errores);
|
||||
|
||||
if (agregados == 0)
|
||||
{
|
||||
ResponderError(
|
||||
context,
|
||||
404,
|
||||
errores.Count > 0
|
||||
? string.Join(" ", errores)
|
||||
: "No fue posible abrir los archivos solicitados.");
|
||||
return;
|
||||
}
|
||||
|
||||
string nombreZip = "Documentos-Fraccionamiento-" +
|
||||
cveFraccionamiento.ToString(CultureInfo.InvariantCulture);
|
||||
if (cveEtapa.HasValue)
|
||||
{
|
||||
nombreZip += "-Etapa-" + cveEtapa.Value.ToString(CultureInfo.InvariantCulture);
|
||||
}
|
||||
nombreZip += ".zip";
|
||||
|
||||
context.Response.Clear();
|
||||
context.Response.ClearHeaders();
|
||||
context.Response.TrySkipIisCustomErrors = true;
|
||||
context.Response.Cache.SetCacheability(HttpCacheability.NoCache);
|
||||
context.Response.Cache.SetNoStore();
|
||||
context.Response.ContentType = "application/zip";
|
||||
context.Response.AddHeader(
|
||||
"Content-Disposition",
|
||||
"attachment; filename=\"" + nombreZip + "\"");
|
||||
|
||||
var informacion = new FileInfo(rutaTemporal);
|
||||
context.Response.AddHeader(
|
||||
"Content-Length",
|
||||
informacion.Length.ToString(CultureInfo.InvariantCulture));
|
||||
|
||||
using (var archivoZip = new FileStream(
|
||||
rutaTemporal,
|
||||
FileMode.Open,
|
||||
FileAccess.Read,
|
||||
FileShare.Read))
|
||||
{
|
||||
archivoZip.CopyTo(context.Response.OutputStream);
|
||||
}
|
||||
|
||||
context.ApplicationInstance.CompleteRequest();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
const string mensaje =
|
||||
"No fue posible generar la descarga de documentos; favor de contactar a Sistemas.";
|
||||
ExceptionLogger.Log(
|
||||
ex,
|
||||
"TramiteDocumentosZipHandler.ProcessRequest",
|
||||
mensaje);
|
||||
ResponderError(context, 500, mensaje);
|
||||
}
|
||||
finally
|
||||
{
|
||||
try
|
||||
{
|
||||
if (File.Exists(rutaTemporal))
|
||||
{
|
||||
File.Delete(rutaTemporal);
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
// La limpieza del temporal no debe invalidar la descarga.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private static int CrearZip(
|
||||
string rutaZip,
|
||||
IList<TramiteDocumentoSolicitudModel> documentos,
|
||||
int cveFraccionamiento,
|
||||
UserSessionModel usuario,
|
||||
out List<string> errores)
|
||||
{
|
||||
errores = new List<string>();
|
||||
int agregados = 0;
|
||||
var nombres = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
|
||||
|
||||
using (var salida = new FileStream(
|
||||
rutaZip,
|
||||
FileMode.CreateNew,
|
||||
FileAccess.ReadWrite,
|
||||
FileShare.None))
|
||||
using (var zip = new ZipStoreWriter(salida))
|
||||
{
|
||||
foreach (TramiteDocumentoSolicitudModel documento in documentos)
|
||||
{
|
||||
DbResult<TramiteDocumentoFileModel> resultado =
|
||||
AppServices.TramiteDocumentoService.Open(
|
||||
cveFraccionamiento,
|
||||
documento.CveDocumentoSolicitud,
|
||||
usuario.CveUsuario,
|
||||
usuario.NombreDominio);
|
||||
|
||||
if (!resultado.Success || resultado.Data == null || resultado.Data.Content == null)
|
||||
{
|
||||
errores.Add(
|
||||
(documento.TipoDocumento ?? "Documento") + ": " +
|
||||
(resultado.UserMessage ?? "No fue posible abrir el archivo."));
|
||||
continue;
|
||||
}
|
||||
|
||||
TramiteDocumentoFileModel archivo = resultado.Data;
|
||||
string nombreEntrada = NombreUnico(
|
||||
LimpiarNombreArchivo(archivo.NombreArchivo, documento.CveDocumentoSolicitud),
|
||||
nombres);
|
||||
|
||||
using (archivo.Content)
|
||||
{
|
||||
zip.AddEntry(nombreEntrada, archivo.Content, DateTime.Now);
|
||||
}
|
||||
|
||||
agregados++;
|
||||
}
|
||||
|
||||
if (agregados > 0 && errores.Count > 0)
|
||||
{
|
||||
byte[] contenidoError = Encoding.UTF8.GetBytes(
|
||||
"Algunos archivos no pudieron agregarse a la descarga:\r\n\r\n" +
|
||||
string.Join("\r\n", errores.Select(error => "- " + error)));
|
||||
using (var memoria = new MemoryStream(contenidoError))
|
||||
{
|
||||
zip.AddEntry("_ERRORES.txt", memoria, DateTime.Now);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return agregados;
|
||||
}
|
||||
|
||||
private static string LimpiarNombreArchivo(string nombre, int clave)
|
||||
{
|
||||
string limpio = Path.GetFileName(nombre ?? string.Empty);
|
||||
if (string.IsNullOrWhiteSpace(limpio))
|
||||
{
|
||||
limpio = "Documento-" + clave.ToString(CultureInfo.InvariantCulture) + ".bin";
|
||||
}
|
||||
|
||||
foreach (char caracter in Path.GetInvalidFileNameChars())
|
||||
{
|
||||
limpio = limpio.Replace(caracter, '_');
|
||||
}
|
||||
|
||||
return limpio;
|
||||
}
|
||||
|
||||
private static string NombreUnico(string nombre, HashSet<string> usados)
|
||||
{
|
||||
if (usados.Add(nombre))
|
||||
{
|
||||
return nombre;
|
||||
}
|
||||
|
||||
string extension = Path.GetExtension(nombre);
|
||||
string baseNombre = Path.GetFileNameWithoutExtension(nombre);
|
||||
int consecutivo = 2;
|
||||
|
||||
while (true)
|
||||
{
|
||||
string candidato = baseNombre + " (" +
|
||||
consecutivo.ToString(CultureInfo.InvariantCulture) + ")" + extension;
|
||||
if (usados.Add(candidato))
|
||||
{
|
||||
return candidato;
|
||||
}
|
||||
consecutivo++;
|
||||
}
|
||||
}
|
||||
|
||||
private static UserSessionModel ObtenerUsuario()
|
||||
{
|
||||
return AppServices.UserContext != null && AppServices.UserContext.IsAuthenticated()
|
||||
? AppServices.UserContext.GetCurrentUser()
|
||||
: null;
|
||||
}
|
||||
|
||||
private static bool LeerEntero(string valor, out int resultado)
|
||||
{
|
||||
return int.TryParse(
|
||||
valor,
|
||||
NumberStyles.Integer,
|
||||
CultureInfo.InvariantCulture,
|
||||
out resultado);
|
||||
}
|
||||
|
||||
private static bool LeerEnteroOpcional(string valor, out int? resultado)
|
||||
{
|
||||
resultado = null;
|
||||
if (string.IsNullOrWhiteSpace(valor))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
int entero;
|
||||
if (!LeerEntero(valor, out entero) || entero <= 0)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
resultado = entero;
|
||||
return true;
|
||||
}
|
||||
|
||||
private static void ResponderError(HttpContext context, int statusCode, string mensaje)
|
||||
{
|
||||
context.Response.Clear();
|
||||
context.Response.StatusCode = statusCode;
|
||||
context.Response.TrySkipIisCustomErrors = true;
|
||||
context.Response.ContentType = "text/plain; charset=utf-8";
|
||||
context.Response.Write(mensaje ?? "No fue posible completar la descarga.");
|
||||
context.ApplicationInstance.CompleteRequest();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Escritor ZIP mínimo, método STORE (sin compresión), UTF-8 y data descriptor.
|
||||
/// Evita agregar una dependencia adicional únicamente para esta descarga.
|
||||
/// </summary>
|
||||
private sealed class ZipStoreWriter : IDisposable
|
||||
{
|
||||
private const uint FirmaLocal = 0x04034b50;
|
||||
private const uint FirmaDescriptor = 0x08074b50;
|
||||
private const uint FirmaCentral = 0x02014b50;
|
||||
private const uint FirmaFin = 0x06054b50;
|
||||
private const ushort Version = 20;
|
||||
private const ushort Flags = 0x0808; // UTF-8 + data descriptor.
|
||||
private const ushort MetodoStore = 0;
|
||||
|
||||
private readonly Stream _salida;
|
||||
private readonly BinaryWriter _writer;
|
||||
private readonly List<EntradaZip> _entradas = new List<EntradaZip>();
|
||||
private bool _cerrado;
|
||||
|
||||
public ZipStoreWriter(Stream salida)
|
||||
{
|
||||
_salida = salida ?? throw new ArgumentNullException("salida");
|
||||
if (!salida.CanWrite || !salida.CanSeek)
|
||||
{
|
||||
throw new ArgumentException("El stream ZIP debe permitir escritura y posicionamiento.", "salida");
|
||||
}
|
||||
|
||||
_writer = new BinaryWriter(salida, Encoding.UTF8, true);
|
||||
}
|
||||
|
||||
public void AddEntry(string nombre, Stream contenido, DateTime fecha)
|
||||
{
|
||||
if (_cerrado)
|
||||
{
|
||||
throw new ObjectDisposedException("ZipStoreWriter");
|
||||
}
|
||||
if (contenido == null)
|
||||
{
|
||||
throw new ArgumentNullException("contenido");
|
||||
}
|
||||
|
||||
byte[] nombreBytes = Encoding.UTF8.GetBytes(nombre ?? "archivo.bin");
|
||||
if (nombreBytes.Length > ushort.MaxValue)
|
||||
{
|
||||
throw new InvalidOperationException("El nombre del archivo es demasiado largo para el ZIP.");
|
||||
}
|
||||
|
||||
long offsetLocalLong = _salida.Position;
|
||||
if (offsetLocalLong > uint.MaxValue)
|
||||
{
|
||||
throw new InvalidOperationException("La descarga excede el tamaño ZIP soportado.");
|
||||
}
|
||||
|
||||
ushort horaDos;
|
||||
ushort fechaDos;
|
||||
ConvertirFechaDos(fecha, out horaDos, out fechaDos);
|
||||
|
||||
_writer.Write(FirmaLocal);
|
||||
_writer.Write(Version);
|
||||
_writer.Write(Flags);
|
||||
_writer.Write(MetodoStore);
|
||||
_writer.Write(horaDos);
|
||||
_writer.Write(fechaDos);
|
||||
_writer.Write((uint)0);
|
||||
_writer.Write((uint)0);
|
||||
_writer.Write((uint)0);
|
||||
_writer.Write((ushort)nombreBytes.Length);
|
||||
_writer.Write((ushort)0);
|
||||
_writer.Write(nombreBytes);
|
||||
|
||||
var crc = new Crc32();
|
||||
long longitud = 0;
|
||||
byte[] buffer = new byte[81920];
|
||||
int leidos;
|
||||
while ((leidos = contenido.Read(buffer, 0, buffer.Length)) > 0)
|
||||
{
|
||||
_salida.Write(buffer, 0, leidos);
|
||||
crc.Update(buffer, 0, leidos);
|
||||
longitud += leidos;
|
||||
|
||||
if (longitud > uint.MaxValue)
|
||||
{
|
||||
throw new InvalidOperationException(
|
||||
"Uno de los archivos excede el tamaño ZIP soportado.");
|
||||
}
|
||||
}
|
||||
|
||||
uint tamano = (uint)longitud;
|
||||
uint valorCrc = crc.Value;
|
||||
|
||||
_writer.Write(FirmaDescriptor);
|
||||
_writer.Write(valorCrc);
|
||||
_writer.Write(tamano);
|
||||
_writer.Write(tamano);
|
||||
|
||||
_entradas.Add(new EntradaZip
|
||||
{
|
||||
Nombre = nombreBytes,
|
||||
Crc = valorCrc,
|
||||
Tamano = tamano,
|
||||
OffsetLocal = (uint)offsetLocalLong,
|
||||
HoraDos = horaDos,
|
||||
FechaDos = fechaDos
|
||||
});
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (_cerrado)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
_cerrado = true;
|
||||
EscribirDirectorioCentral();
|
||||
_writer.Flush();
|
||||
_writer.Dispose();
|
||||
}
|
||||
|
||||
private void EscribirDirectorioCentral()
|
||||
{
|
||||
if (_entradas.Count > ushort.MaxValue)
|
||||
{
|
||||
throw new InvalidOperationException("La descarga contiene demasiados archivos.");
|
||||
}
|
||||
|
||||
long inicioCentralLong = _salida.Position;
|
||||
if (inicioCentralLong > uint.MaxValue)
|
||||
{
|
||||
throw new InvalidOperationException("La descarga excede el tamaño ZIP soportado.");
|
||||
}
|
||||
|
||||
foreach (EntradaZip entrada in _entradas)
|
||||
{
|
||||
_writer.Write(FirmaCentral);
|
||||
_writer.Write(Version);
|
||||
_writer.Write(Version);
|
||||
_writer.Write(Flags);
|
||||
_writer.Write(MetodoStore);
|
||||
_writer.Write(entrada.HoraDos);
|
||||
_writer.Write(entrada.FechaDos);
|
||||
_writer.Write(entrada.Crc);
|
||||
_writer.Write(entrada.Tamano);
|
||||
_writer.Write(entrada.Tamano);
|
||||
_writer.Write((ushort)entrada.Nombre.Length);
|
||||
_writer.Write((ushort)0);
|
||||
_writer.Write((ushort)0);
|
||||
_writer.Write((ushort)0);
|
||||
_writer.Write((ushort)0);
|
||||
_writer.Write((uint)0);
|
||||
_writer.Write(entrada.OffsetLocal);
|
||||
_writer.Write(entrada.Nombre);
|
||||
}
|
||||
|
||||
long finCentralLong = _salida.Position;
|
||||
long tamanoCentralLong = finCentralLong - inicioCentralLong;
|
||||
if (tamanoCentralLong > uint.MaxValue)
|
||||
{
|
||||
throw new InvalidOperationException("El directorio ZIP excede el tamaño soportado.");
|
||||
}
|
||||
|
||||
ushort cantidad = (ushort)_entradas.Count;
|
||||
_writer.Write(FirmaFin);
|
||||
_writer.Write((ushort)0);
|
||||
_writer.Write((ushort)0);
|
||||
_writer.Write(cantidad);
|
||||
_writer.Write(cantidad);
|
||||
_writer.Write((uint)tamanoCentralLong);
|
||||
_writer.Write((uint)inicioCentralLong);
|
||||
_writer.Write((ushort)0);
|
||||
}
|
||||
|
||||
private static void ConvertirFechaDos(DateTime fecha, out ushort hora, out ushort dia)
|
||||
{
|
||||
DateTime valor = fecha.Year < 1980
|
||||
? new DateTime(1980, 1, 1, 0, 0, 0)
|
||||
: fecha;
|
||||
|
||||
hora = (ushort)((valor.Hour << 11) |
|
||||
(valor.Minute << 5) |
|
||||
(valor.Second / 2));
|
||||
dia = (ushort)(((valor.Year - 1980) << 9) |
|
||||
(valor.Month << 5) |
|
||||
valor.Day);
|
||||
}
|
||||
|
||||
private sealed class EntradaZip
|
||||
{
|
||||
public byte[] Nombre { get; set; }
|
||||
public uint Crc { get; set; }
|
||||
public uint Tamano { get; set; }
|
||||
public uint OffsetLocal { get; set; }
|
||||
public ushort HoraDos { get; set; }
|
||||
public ushort FechaDos { get; set; }
|
||||
}
|
||||
|
||||
private sealed class Crc32
|
||||
{
|
||||
private uint _crc = 0xFFFFFFFF;
|
||||
|
||||
public uint Value
|
||||
{
|
||||
get { return _crc ^ 0xFFFFFFFF; }
|
||||
}
|
||||
|
||||
public void Update(byte[] buffer, int offset, int count)
|
||||
{
|
||||
for (int indice = offset; indice < offset + count; indice++)
|
||||
{
|
||||
_crc ^= buffer[indice];
|
||||
for (int bit = 0; bit < 8; bit++)
|
||||
{
|
||||
_crc = (_crc & 1) != 0
|
||||
? (_crc >> 1) ^ 0xEDB88320
|
||||
: _crc >> 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -53,6 +53,24 @@ namespace SIG.Web.Pages.Fraccionamientos
|
||||
"POST",
|
||||
StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
if (string.Equals(metodo, "DesvincularLote", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
DesvincularLote(contexto, actualUsuario);
|
||||
return;
|
||||
}
|
||||
|
||||
if (string.Equals(metodo, "VincularLote", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
VincularLote(contexto, actualUsuario);
|
||||
return;
|
||||
}
|
||||
|
||||
if (string.Equals(metodo, "GuardarCapa", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
GuardarCapa(contexto, actualUsuario);
|
||||
return;
|
||||
}
|
||||
|
||||
if (string.Equals(metodo, "Save", StringComparison.OrdinalIgnoreCase) ||
|
||||
string.Equals(metodo, "GuardarArchivo", StringComparison.OrdinalIgnoreCase) ||
|
||||
string.Equals(metodo, "GuardarVinculos", StringComparison.OrdinalIgnoreCase))
|
||||
@@ -94,6 +112,21 @@ namespace SIG.Web.Pages.Fraccionamientos
|
||||
return;
|
||||
}
|
||||
|
||||
if (string.Equals(metodo, "Capas", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
DbResult<List<CapaGisFraccionamiento>> capas =
|
||||
AppServices.ServicioGisFraccionamiento.ListarCapas(
|
||||
cveFraccionamientoEtapa, actualUsuario.CveUsuario, actualUsuario.NombreDominio);
|
||||
if (!capas.Success)
|
||||
{
|
||||
EscribirFalloResultado(contexto, capas, 400);
|
||||
return;
|
||||
}
|
||||
|
||||
EscribirJson(contexto, 200, new { success = true, data = capas.Data });
|
||||
return;
|
||||
}
|
||||
|
||||
if (string.Equals(metodo, "Context", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
ObtenerContexto(contexto, actualUsuario, cveFraccionamientoEtapa);
|
||||
@@ -162,6 +195,86 @@ namespace SIG.Web.Pages.Fraccionamientos
|
||||
});
|
||||
}
|
||||
|
||||
private static void VincularLote(HttpContext contexto, UserSessionModel actualUsuario)
|
||||
{
|
||||
int etapa;
|
||||
int lote;
|
||||
if (!IntentarObtenerCveEtapa(contexto, out etapa) ||
|
||||
!int.TryParse(contexto.Request.Form["CveFraccionamientoLote"], out lote))
|
||||
{
|
||||
EscribirJson(contexto, 400, new { success = false, message = "Seleccione una etapa y un lote válidos." });
|
||||
return;
|
||||
}
|
||||
|
||||
DbResult<ResultadoGuardadoGisFraccionamiento> resultado =
|
||||
AppServices.ServicioGisFraccionamiento.VincularLote(
|
||||
etapa, lote, contexto.Request.Form["ClavePoligono"],
|
||||
actualUsuario.CveUsuario, actualUsuario.NombreDominio);
|
||||
if (!resultado.Success)
|
||||
{
|
||||
EscribirFalloResultado(contexto, resultado, 400);
|
||||
return;
|
||||
}
|
||||
|
||||
EscribirJson(contexto, 200, new { success = true, message = "Lote vinculado correctamente." });
|
||||
}
|
||||
|
||||
private static void DesvincularLote(HttpContext contexto, UserSessionModel actualUsuario)
|
||||
{
|
||||
int etapa;
|
||||
int lote;
|
||||
if (!IntentarObtenerCveEtapa(contexto, out etapa) ||
|
||||
!int.TryParse(contexto.Request.Form["CveFraccionamientoLote"], out lote))
|
||||
{
|
||||
EscribirJson(contexto, 400, new { success = false, message = "Seleccione una etapa y un lote válidos." });
|
||||
return;
|
||||
}
|
||||
|
||||
var resultado = AppServices.ServicioGisFraccionamiento.DesvincularLote(
|
||||
etapa, lote, contexto.Request.Form["ClavePoligono"],
|
||||
actualUsuario.CveUsuario, actualUsuario.NombreDominio);
|
||||
if (!resultado.Success)
|
||||
{
|
||||
EscribirFalloResultado(contexto, resultado, 400);
|
||||
return;
|
||||
}
|
||||
|
||||
EscribirJson(contexto, 200, new { success = true, message = "Lote desvinculado correctamente." });
|
||||
}
|
||||
|
||||
private static void GuardarCapa(HttpContext contexto, UserSessionModel actualUsuario)
|
||||
{
|
||||
int etapa;
|
||||
bool visible;
|
||||
if (!IntentarObtenerCveEtapa(contexto, out etapa) ||
|
||||
!bool.TryParse(contexto.Request.Form["EsVisible"], out visible))
|
||||
{
|
||||
EscribirJson(contexto, 400, new
|
||||
{
|
||||
success = false,
|
||||
message = "Indique una etapa y configuración válidas."
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
CapaGisFraccionamiento capa = new CapaGisFraccionamiento
|
||||
{
|
||||
NombreCapa = contexto.Request.Form["NombreCapa"],
|
||||
TipoCapa = contexto.Request.Form["TipoCapa"],
|
||||
Color = contexto.Request.Form["Color"],
|
||||
EsVisible = visible
|
||||
};
|
||||
DbResult<bool> resultado = AppServices.ServicioGisFraccionamiento.GuardarCapa(
|
||||
etapa, capa, actualUsuario.CveUsuario, actualUsuario.NombreDominio);
|
||||
if (!resultado.Success)
|
||||
{
|
||||
EscribirFalloResultado(contexto, resultado, 400);
|
||||
return;
|
||||
}
|
||||
|
||||
EscribirJson(contexto, 200, new { success = true, message = "Capa guardada." });
|
||||
}
|
||||
|
||||
private static void Guardar(
|
||||
HttpContext contexto,
|
||||
UserSessionModel actualUsuario,
|
||||
|
||||
@@ -0,0 +1,136 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.HtmlControls;
|
||||
|
||||
namespace SIG.Web.AppCode.Infrastructure.WebForms
|
||||
{
|
||||
public static class CargaArchivoWebHelper
|
||||
{
|
||||
public static void Configurar(
|
||||
HtmlInputHidden control,
|
||||
string extensionesPermitidas,
|
||||
int? tamanoMaximoMb,
|
||||
int maximoArchivos = 1,
|
||||
string mensaje = null)
|
||||
{
|
||||
if (control == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (control.Page != null && control.Page.Form != null)
|
||||
{
|
||||
control.Page.Form.Enctype = "multipart/form-data";
|
||||
}
|
||||
|
||||
control.Attributes["data-readmode"] = "none";
|
||||
control.Attributes["data-input-name"] = ObtenerNombreCampo(control);
|
||||
control.Attributes["data-maxfile"] = Math.Max(1, maximoArchivos)
|
||||
.ToString(CultureInfo.InvariantCulture);
|
||||
|
||||
if (tamanoMaximoMb.HasValue && tamanoMaximoMb.Value > 0)
|
||||
{
|
||||
control.Attributes["data-maxfilesize"] = tamanoMaximoMb.Value
|
||||
.ToString(CultureInfo.InvariantCulture);
|
||||
}
|
||||
else
|
||||
{
|
||||
control.Attributes.Remove("data-maxfilesize");
|
||||
}
|
||||
|
||||
string extensiones = NormalizarExtensiones(extensionesPermitidas);
|
||||
if (string.IsNullOrWhiteSpace(extensiones))
|
||||
{
|
||||
control.Attributes.Remove("data-acceptedfiles");
|
||||
}
|
||||
else
|
||||
{
|
||||
control.Attributes["data-acceptedfiles"] = extensiones;
|
||||
}
|
||||
|
||||
control.Attributes["data-message"] = string.IsNullOrWhiteSpace(mensaje)
|
||||
? "Arrastra aquí un archivo o haz clic para seleccionarlo."
|
||||
: mensaje.Trim();
|
||||
}
|
||||
|
||||
public static HttpPostedFile ObtenerArchivo(Page pagina, HtmlInputHidden control)
|
||||
{
|
||||
return ObtenerArchivos(pagina, control).FirstOrDefault();
|
||||
}
|
||||
public static List<HttpPostedFile> ObtenerArchivos( Page pagina, HtmlInputHidden control)
|
||||
{
|
||||
var archivos = new List<HttpPostedFile>();
|
||||
|
||||
if (pagina == null || control == null)
|
||||
{
|
||||
return archivos;
|
||||
}
|
||||
|
||||
string nombreCampo = ObtenerNombreCampo(control);
|
||||
HttpFileCollection archivosRequest = pagina.Request.Files;
|
||||
|
||||
for (int indice = 0; indice < archivosRequest.Count; indice++)
|
||||
{
|
||||
string nombreCampoArchivo = archivosRequest.GetKey(indice);
|
||||
|
||||
if (!string.Equals(
|
||||
nombreCampoArchivo,
|
||||
nombreCampo,
|
||||
StringComparison.Ordinal))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
HttpPostedFile archivo = archivosRequest[indice];
|
||||
|
||||
if (archivo != null && archivo.ContentLength > 0)
|
||||
{
|
||||
archivos.Add(archivo);
|
||||
}
|
||||
}
|
||||
|
||||
return archivos;
|
||||
}
|
||||
|
||||
public static string ObtenerNombreCampo(Control control)
|
||||
{
|
||||
if (control == null)
|
||||
{
|
||||
throw new ArgumentNullException("control");
|
||||
}
|
||||
|
||||
return control.ClientID + "_archivo";
|
||||
}
|
||||
|
||||
private static string NormalizarExtensiones(string extensiones)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(extensiones))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
return string.Join(",",
|
||||
extensiones
|
||||
.Split(new[] { ',', ';', '|', ' ' }, StringSplitOptions.RemoveEmptyEntries)
|
||||
.Select(extension => extension.Trim())
|
||||
.Where(extension => !string.IsNullOrWhiteSpace(extension))
|
||||
.Select(extension =>
|
||||
{
|
||||
if (extension.Contains("/"))
|
||||
{
|
||||
return extension;
|
||||
}
|
||||
|
||||
extension = extension.TrimStart('*');
|
||||
return extension.StartsWith(".", StringComparison.Ordinal)
|
||||
? extension
|
||||
: "." + extension;
|
||||
})
|
||||
.Distinct(StringComparer.OrdinalIgnoreCase));
|
||||
}
|
||||
}
|
||||
}
|
||||
211
SIG.Web/App_Code/Models/Clientes/ModelosPortalCliente.cs
Normal file
@@ -0,0 +1,211 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SIG.Web.AppCode.Models.Clientes
|
||||
{
|
||||
[Serializable]
|
||||
public sealed class FiltroDocumentosCliente
|
||||
{
|
||||
public int? CveFraccionamiento { get; set; }
|
||||
public int? CveFraccionamientoEtapa { get; set; }
|
||||
public string Agrupacion { get; set; }
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class DocumentoClientePortal
|
||||
{
|
||||
public int CveDocumentoSolicitud { get; set; }
|
||||
public int CveSolicitud { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
public int CveFraccionamiento { get; set; }
|
||||
public string Fraccionamiento { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public int CveTipoTramite { get; set; }
|
||||
public string TipoTramite { get; set; }
|
||||
public int CveTipoDocumento { get; set; }
|
||||
public string TipoDocumento { get; set; }
|
||||
public string NombreArchivo { get; set; }
|
||||
public string Nota { get; set; }
|
||||
public bool? EsAprobado { get; set; }
|
||||
public DateTime? FechaDocumento { get; set; }
|
||||
public DateTime? FechaVencimiento { get; set; }
|
||||
public bool TieneArchivo { get; set; }
|
||||
public bool EsCliente { get; set; }
|
||||
public bool PuedeActualizarArchivo { get; set; }
|
||||
public bool EsRequerido { get; set; }
|
||||
public bool TieneVigencia { get; set; }
|
||||
public bool FechaExpirada { get; set; }
|
||||
public string EstadoDocumento { get; set; }
|
||||
public string Agrupacion { get; set; }
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class FiltroPagosCliente
|
||||
{
|
||||
public int? CveFraccionamiento { get; set; }
|
||||
public int? CveFraccionamientoEtapa { get; set; }
|
||||
public string Agrupacion { get; set; }
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class PagoPendienteTramiteCliente
|
||||
{
|
||||
public int CveSolicitud { get; set; }
|
||||
public int CveConvenioRecibo { get; set; }
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class PagoConvenioClienteFila
|
||||
{
|
||||
public string TipoRegistro { get; set; }
|
||||
public string Agrupacion { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
public int CveFraccionamiento { get; set; }
|
||||
public string Fraccionamiento { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public int? CveSolicitud { get; set; }
|
||||
public int CveConvenio { get; set; }
|
||||
public string NumeroConvenio { get; set; }
|
||||
public int? CveConvenioDetalle { get; set; }
|
||||
public string Concepto { get; set; }
|
||||
public int? CveConvenioRecibo { get; set; }
|
||||
public string NumeroRecibo { get; set; }
|
||||
public int? CveConvenioPago { get; set; }
|
||||
public decimal Importe { get; set; }
|
||||
public decimal ImporteAplicado { get; set; }
|
||||
public decimal SaldoPendiente { get; set; }
|
||||
public DateTime Fecha { get; set; }
|
||||
public string Estatus { get; set; }
|
||||
public string Referencia { get; set; }
|
||||
public string NumeroOperacion { get; set; }
|
||||
public string NombreArchivo { get; set; }
|
||||
public string RecibosAplicados { get; set; }
|
||||
public string Observaciones { get; set; }
|
||||
|
||||
public bool EsReciboPendiente
|
||||
{
|
||||
get
|
||||
{
|
||||
return string.Equals(
|
||||
TipoRegistro,
|
||||
"RECIBO",
|
||||
StringComparison.OrdinalIgnoreCase) &&
|
||||
string.Equals(
|
||||
Agrupacion,
|
||||
"Pendientes",
|
||||
StringComparison.OrdinalIgnoreCase);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class ReciboConvenioDisponibleCliente
|
||||
{
|
||||
public int CveConvenioRecibo { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
public int CveFraccionamiento { get; set; }
|
||||
public string Fraccionamiento { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public int CveConvenio { get; set; }
|
||||
public string NumeroConvenio { get; set; }
|
||||
public string Concepto { get; set; }
|
||||
public string NumeroRecibo { get; set; }
|
||||
public decimal Importe { get; set; }
|
||||
public decimal ImporteAplicado { get; set; }
|
||||
public decimal SaldoPendiente { get; set; }
|
||||
public DateTime FechaVencimiento { get; set; }
|
||||
|
||||
public string Descripcion
|
||||
{
|
||||
get
|
||||
{
|
||||
return string.Format(
|
||||
System.Globalization.CultureInfo.CurrentCulture,
|
||||
"{0} · {1} · {2} · saldo {3:N2}",
|
||||
Fraccionamiento,
|
||||
Etapa,
|
||||
NumeroRecibo,
|
||||
SaldoPendiente);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class AplicacionPagoConvenioCliente
|
||||
{
|
||||
public int CveConvenioRecibo { get; set; }
|
||||
public string NumeroRecibo { get; set; }
|
||||
public string Fraccionamiento { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public string Concepto { get; set; }
|
||||
public decimal SaldoPendiente { get; set; }
|
||||
public decimal ImporteAplicado { get; set; }
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class SolicitudPagoConvenioCliente
|
||||
{
|
||||
public int CveCliente { get; set; }
|
||||
public decimal Importe { get; set; }
|
||||
public DateTime FechaPago { get; set; }
|
||||
public string Referencia { get; set; }
|
||||
public string Banco { get; set; }
|
||||
public string NumeroOperacion { get; set; }
|
||||
public string Observaciones { get; set; }
|
||||
public string NombreArchivo { get; set; }
|
||||
public string NombreFisico { get; set; }
|
||||
public string TipoContenido { get; set; }
|
||||
public long TamanoBytes { get; set; }
|
||||
public List<AplicacionPagoConvenioCliente> Aplicaciones { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ArchivoPagoConvenioCliente
|
||||
{
|
||||
public int CveConvenioPago { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
public string NombreArchivo { get; set; }
|
||||
public string NombreFisico { get; set; }
|
||||
public string TipoContenido { get; set; }
|
||||
public long TamanoBytes { get; set; }
|
||||
public string RutaFisica { get; set; }
|
||||
}
|
||||
|
||||
public sealed class TramiteClienteListado
|
||||
{
|
||||
public int CveSolicitud { get; set; }
|
||||
public string Folio { get; set; }
|
||||
public int CveFraccionamiento { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public int CveTipoTramite { get; set; }
|
||||
public string TipoTramite { get; set; }
|
||||
public int CveEstatusSolicitud { get; set; }
|
||||
public string EstatusSolicitud { get; set; }
|
||||
public int DocumentosPendientes { get; set; }
|
||||
public int PagosPendientes { get; set; }
|
||||
public bool PuedeEnviarRevision { get; set; }
|
||||
|
||||
public string TextoDocumentos
|
||||
{
|
||||
get
|
||||
{
|
||||
return DocumentosPendientes == 0
|
||||
? "Completo"
|
||||
: DocumentosPendientes + " pendiente(s)";
|
||||
}
|
||||
}
|
||||
|
||||
public string TextoPagos
|
||||
{
|
||||
get
|
||||
{
|
||||
return PagosPendientes == 0
|
||||
? "Sin pendientes"
|
||||
: PagosPendientes + " pendiente(s)";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
146
SIG.Web/App_Code/Models/Convenios/ModelosConvenios.cs
Normal file
@@ -0,0 +1,146 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SIG.Web.AppCode.Models.Convenios
|
||||
{
|
||||
[Serializable]
|
||||
public sealed class FiltroConvenios
|
||||
{
|
||||
public int? CveCliente { get; set; }
|
||||
public int? CveFraccionamiento { get; set; }
|
||||
public int? CveFraccionamientoEtapa { get; set; }
|
||||
public int? CveTipoTramite { get; set; }
|
||||
public string Estatus { get; set; }
|
||||
public bool? ConSaldoPendiente { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ConvenioListado
|
||||
{
|
||||
public int CveConvenio { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
public string Cliente { get; set; }
|
||||
public int CveFraccionamiento { get; set; }
|
||||
public string Fraccionamiento { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public int CveTipoTramite { get; set; }
|
||||
public string TipoTramite { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public string NumeroConvenio { get; set; }
|
||||
public string NumeroOficio { get; set; }
|
||||
public string Estatus { get; set; }
|
||||
public DateTime FechaConvenio { get; set; }
|
||||
public decimal ImporteConvenio { get; set; }
|
||||
public decimal ImportePagado { get; set; }
|
||||
public decimal SaldoPendiente { get; set; }
|
||||
public bool TienePagos { get; set; }
|
||||
public bool PuedeEliminar { get { return !TienePagos; } }
|
||||
}
|
||||
|
||||
public sealed class ConvenioDetalleEncabezado
|
||||
{
|
||||
public int CveConvenio { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public int CveTipoTramite { get; set; }
|
||||
public string TipoTramite { get; set; }
|
||||
public string NumeroConvenio { get; set; }
|
||||
public string NumeroOficio { get; set; }
|
||||
public string Cliente { get; set; }
|
||||
public string Fraccionamiento { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public string Estatus { get; set; }
|
||||
public DateTime FechaConvenio { get; set; }
|
||||
public int? ViviendasAutorizadas { get; set; }
|
||||
public int ViviendasEnConvenio { get; set; }
|
||||
public int? ViviendasPendientes { get; set; }
|
||||
public int? ViviendasContratadas { get; set; }
|
||||
public int LotesConvenio { get; set; }
|
||||
public string Observaciones { get; set; }
|
||||
public decimal ImporteConvenio { get; set; }
|
||||
public decimal ImportePagado { get; set; }
|
||||
public decimal SaldoPendiente { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ConvenioConceptoDetalle
|
||||
{
|
||||
public int CveConvenioDetalle { get; set; }
|
||||
public int CveConvenioConcepto { get; set; }
|
||||
public string Concepto { get; set; }
|
||||
public decimal Importe { get; set; }
|
||||
public string Tipo { get; set; }
|
||||
public int NumeroPagos { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ConvenioReciboDetalle
|
||||
{
|
||||
public int CveConvenioRecibo { get; set; }
|
||||
public int CveConvenioDetalle { get; set; }
|
||||
public string NumeroRecibo { get; set; }
|
||||
public decimal Importe { get; set; }
|
||||
public decimal ImportePagado { get; set; }
|
||||
public decimal SaldoPendiente { get; set; }
|
||||
public DateTime FechaVencimiento { get; set; }
|
||||
public string Estatus { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ConvenioDetalleCompleto
|
||||
{
|
||||
public ConvenioDetalleEncabezado Encabezado { get; set; }
|
||||
public List<ConvenioConceptoDetalle> Conceptos { get; set; }
|
||||
public List<ConvenioReciboDetalle> Recibos { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ConvenioConceptoCatalogo
|
||||
{
|
||||
public int CveConvenioConcepto { get; set; }
|
||||
public string Concepto { get; set; }
|
||||
public string Descripcion { get; set; }
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class SolicitudAltaConvenio
|
||||
{
|
||||
public int CveCliente { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public int CveTipoTramite { get; set; }
|
||||
public string TipoTramite { get; set; }
|
||||
public string NumeroConvenio { get; set; }
|
||||
public string NumeroOficio { get; set; }
|
||||
public int? ViviendasAutorizadas { get; set; }
|
||||
public int ViviendasEnConvenio { get; set; }
|
||||
public int? ViviendasPendientes { get; set; }
|
||||
public int? ViviendasContratadas { get; set; }
|
||||
public int LotesConvenio { get; set; }
|
||||
public DateTime FechaConvenio { get; set; }
|
||||
public string Observaciones { get; set; }
|
||||
public List<ConvenioConceptoCaptura> Conceptos { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ConvenioLotesConvenio
|
||||
{
|
||||
public int CveConvenio { get; set; }
|
||||
public int LotesConvenio { get; set; }
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class ConvenioConceptoCaptura
|
||||
{
|
||||
public int ClaveTemporal { get; set; }
|
||||
public int CveConvenioConcepto { get; set; }
|
||||
public string Concepto { get; set; }
|
||||
public decimal Importe { get; set; }
|
||||
public string Tipo { get; set; }
|
||||
public int NumeroPagos { get; set; }
|
||||
public List<ConvenioReciboCaptura> Parcialidades { get; set; }
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
public sealed class ConvenioReciboCaptura
|
||||
{
|
||||
public int Orden { get; set; }
|
||||
public string NumeroRecibo { get; set; }
|
||||
public decimal Importe { get; set; }
|
||||
public DateTime FechaVencimiento { get; set; }
|
||||
public string Estatus { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -6,6 +6,7 @@ namespace SIG.Web.AppCode.Models.Documentos
|
||||
[Serializable]
|
||||
public sealed class SolicitudDocumentoConfiguracionModel
|
||||
{
|
||||
public int CveTipoTramite { get; set; }
|
||||
public int CveSolicitud { get; set; }
|
||||
public int CveTipoDocumento { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
@@ -94,6 +95,16 @@ namespace SIG.Web.AppCode.Models.Documentos
|
||||
{
|
||||
get { return EsRequerido && !TieneArchivo; }
|
||||
}
|
||||
|
||||
public bool ImpideAvanzar
|
||||
{
|
||||
get
|
||||
{
|
||||
return EsRequerido &&
|
||||
(!TieneArchivo || EsAprobado != true || FechaExpirada ||
|
||||
(TieneVigencia && !FechaVencimiento.HasValue));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public sealed class TramiteDocumentoUploadContextModel
|
||||
@@ -168,6 +179,24 @@ namespace SIG.Web.AppCode.Models.Documentos
|
||||
public DateTime? FechaRevisionAnterior { get; set; }
|
||||
}
|
||||
|
||||
public sealed class TramiteDocumentoVencimientoResultModel
|
||||
{
|
||||
public int CveDocumentoSolicitud { get; set; }
|
||||
public int CveSolicitud { get; set; }
|
||||
public string Folio { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
public int CveFraccionamiento { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public int CveTipoTramite { get; set; }
|
||||
public string TipoTramite { get; set; }
|
||||
public int CveTipoDocumento { get; set; }
|
||||
public string TipoDocumento { get; set; }
|
||||
public DateTime? FechaDocumento { get; set; }
|
||||
public DateTime? FechaVencimientoAnterior { get; set; }
|
||||
public DateTime? FechaVencimiento { get; set; }
|
||||
}
|
||||
|
||||
public sealed class TramiteDocumentoReviewResultModel
|
||||
{
|
||||
public int CveDocumentoSolicitud { get; set; }
|
||||
@@ -193,6 +222,24 @@ namespace SIG.Web.AppCode.Models.Documentos
|
||||
public bool HuboCambio { get; set; }
|
||||
}
|
||||
|
||||
public sealed class TramiteDocumentoNotaResultModel
|
||||
{
|
||||
public int CveDocumentoSolicitud { get; set; }
|
||||
public int CveSolicitud { get; set; }
|
||||
public string Folio { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
public int CveFraccionamiento { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public int CveTipoTramite { get; set; }
|
||||
public string TipoTramite { get; set; }
|
||||
public int CveTipoDocumento { get; set; }
|
||||
public string TipoDocumento { get; set; }
|
||||
public string NombreArchivo { get; set; }
|
||||
public string ComentarioAdministrativoAnterior { get; set; }
|
||||
public string ComentarioAdministrativo { get; set; }
|
||||
}
|
||||
|
||||
public sealed class TramiteDocumentoDeleteResultModel
|
||||
{
|
||||
public int CveDocumentoSolicitud { get; set; }
|
||||
|
||||
33
SIG.Web/App_Code/Models/Fraccionamientos/ModeloLoteEtapa.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using System;
|
||||
|
||||
namespace SIG.Web.AppCode.Models.Fraccionamientos
|
||||
{
|
||||
[Serializable]
|
||||
public sealed class ModeloLoteEtapa
|
||||
{
|
||||
public int CveFraccionamientoLote { get; set; }
|
||||
public int CveFraccionamientoEtapa { get; set; }
|
||||
public int CveFraccionamiento { get; set; }
|
||||
public int CveCliente { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public string Nombre { get; set; }
|
||||
public string Tipo { get; set; }
|
||||
public string Calle { get; set; }
|
||||
public string Catastro { get; set; }
|
||||
public decimal? MetrosCuadrados { get; set; }
|
||||
public string Duplicador { get; set; }
|
||||
public bool EsActivo { get; set; }
|
||||
public int? CveTipoVivienda { get; set; }
|
||||
public string TipoVivienda { get; set; }
|
||||
public decimal? Latitud { get; set; }
|
||||
public decimal? Longitud { get; set; }
|
||||
public decimal AvanceAguaPotable { get; set; }
|
||||
public decimal AvanceDrenaje { get; set; }
|
||||
public bool AguaPotableAutorizada { get; set; }
|
||||
public bool DrenajeAutorizado { get; set; }
|
||||
public bool Aprobado { get; set; }
|
||||
public bool Bloqueado { get; set; }
|
||||
public bool PuedeEditar { get; set; }
|
||||
public string GISPoligonoClave { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SIG.Web.AppCode.Models.Fraccionamientos
|
||||
{
|
||||
@@ -14,6 +14,7 @@ namespace SIG.Web.AppCode.Models.Fraccionamientos
|
||||
public bool EsFraccionamiento { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public decimal? Hectareas { get; set; }
|
||||
public decimal Avance { get; set; }
|
||||
public bool Fideicomiso { get; set; }
|
||||
public bool EsActivo { get; set; }
|
||||
}
|
||||
@@ -149,6 +150,30 @@ namespace SIG.Web.AppCode.Models.Fraccionamientos
|
||||
public string Duplicador { get; set; }
|
||||
|
||||
public bool EsActivo { get; set; }
|
||||
|
||||
public int? CveTipoVivienda { get; set; }
|
||||
|
||||
public string TipoVivienda { get; set; }
|
||||
|
||||
public decimal? Latitud { get; set; }
|
||||
|
||||
public decimal? Longitud { get; set; }
|
||||
|
||||
public decimal AvanceAguaPotable { get; set; }
|
||||
|
||||
public decimal AvanceDrenaje { get; set; }
|
||||
|
||||
public bool AguaPotableAutorizada { get; set; }
|
||||
|
||||
public bool DrenajeAutorizado { get; set; }
|
||||
|
||||
public bool Aprobado { get; set; }
|
||||
|
||||
public bool Bloqueado { get; set; }
|
||||
|
||||
public bool PuedeEditar { get; set; }
|
||||
|
||||
public string GISPoligonoClave { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ModeloTramiteEtapaFraccionamiento
|
||||
|
||||
@@ -4,6 +4,16 @@ using System.IO;
|
||||
|
||||
namespace SIG.Web.AppCode.Models.Fraccionamientos
|
||||
{
|
||||
public sealed class CapaGisFraccionamiento
|
||||
{
|
||||
public string NombreCapa { get; set; }
|
||||
public string TipoCapa { get; set; }
|
||||
public string Color { get; set; }
|
||||
public bool EsVisible { get; set; }
|
||||
public string Geometria { get; set; }
|
||||
public int Elementos { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ContextoGisFraccionamiento
|
||||
{
|
||||
public int CveCliente { get; set; }
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SIG.Web.AppCode.Models.Fraccionamientos
|
||||
{
|
||||
public sealed class ResultadoGuardarFraccionamientoConEtapas
|
||||
{
|
||||
public int CveFraccionamiento { get; set; }
|
||||
|
||||
public List<ModeloEtapaFraccionamiento> Etapas { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -44,10 +44,33 @@ namespace SIG.Web.AppCode.Models.Tramites
|
||||
public int CveEstatusSolicitud { get; set; }
|
||||
public string EstatusSolicitud { get; set; }
|
||||
public bool EsEstatusCliente { get; set; }
|
||||
public bool EsEstatusOk { get; set; }
|
||||
public DateTime? FechaInicio { get; set; }
|
||||
public DateTime? FechaAutorizacion { get; set; }
|
||||
public bool PuedeCambiarEstatus { get; set; }
|
||||
public bool EsAutorizada { get; set; }
|
||||
public int DocumentosPendientes { get; set; }
|
||||
public int PagosPendientes { get; set; }
|
||||
|
||||
public string TextoDocumentos
|
||||
{
|
||||
get
|
||||
{
|
||||
return DocumentosPendientes == 0
|
||||
? "Completo"
|
||||
: DocumentosPendientes + " pendiente(s)";
|
||||
}
|
||||
}
|
||||
|
||||
public string TextoPagos
|
||||
{
|
||||
get
|
||||
{
|
||||
return PagosPendientes == 0
|
||||
? "Sin pendientes"
|
||||
: PagosPendientes + " pendiente(s)";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
@@ -59,6 +82,7 @@ namespace SIG.Web.AppCode.Models.Tramites
|
||||
public int Orden { get; set; }
|
||||
public bool EsFinal { get; set; }
|
||||
public bool EsCliente { get; set; }
|
||||
public bool EsOK { get; set; }
|
||||
}
|
||||
|
||||
public sealed class TramiteSolicitudStatusChangeModel
|
||||
|
||||
@@ -0,0 +1,41 @@
|
||||
using System.Collections.Generic;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Documentos;
|
||||
using SIG.Web.AppCode.Models.Tramites;
|
||||
using SIG.Web.AppCode.Notifications.Models;
|
||||
|
||||
namespace SIG.Web.AppCode.Notifications.Contracts
|
||||
{
|
||||
public interface INotificacionConfiguracionService
|
||||
{
|
||||
DbResult<List<TipoNotificacionModel>> ListarTipos(
|
||||
bool incluirInactivos, int usuario, string dominio);
|
||||
DbResult<TipoNotificacionModel> ObtenerTipo(
|
||||
int cveTipoNotificacion, int usuario, string dominio);
|
||||
DbResult<int> GuardarTipo(
|
||||
TipoNotificacionModel model, int usuario, string dominio);
|
||||
DbResult<bool> EliminarTipo(
|
||||
int cveTipoNotificacion, int usuario, string dominio);
|
||||
|
||||
DbResult<List<ConfiguracionNotificacionModel>> ListarConfiguraciones(
|
||||
string origen, int? cveOrigen, int usuario, string dominio);
|
||||
DbResult<int> GuardarConfiguracion(
|
||||
ConfiguracionNotificacionModel model, int usuario, string dominio);
|
||||
DbResult<bool> EliminarConfiguracion(
|
||||
string origen, int cveConfiguracion, int usuario, string dominio);
|
||||
|
||||
void NotificarDocumentoCargado(
|
||||
TramiteDocumentoSaveResultModel documento,
|
||||
int usuario,
|
||||
string dominio);
|
||||
void NotificarDocumentoRevisado(
|
||||
TramiteDocumentoReviewResultModel documento,
|
||||
int usuario,
|
||||
string dominio);
|
||||
void NotificarTramite(
|
||||
string evento,
|
||||
TramiteSolicitudStatusChangeModel tramite,
|
||||
int usuario,
|
||||
string dominio);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
using System.Collections.Generic;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Notifications.Models;
|
||||
|
||||
namespace SIG.Web.AppCode.Notifications.Contracts
|
||||
{
|
||||
public interface INotificacionRepository
|
||||
{
|
||||
DbResult<List<TipoNotificacionModel>> ListarTipos(
|
||||
bool incluirInactivos, int usuario, string dominio);
|
||||
DbResult<TipoNotificacionModel> ObtenerTipo(
|
||||
int cveTipoNotificacion, int usuario, string dominio);
|
||||
DbResult<int> GuardarTipo(
|
||||
TipoNotificacionModel model, int usuario, string dominio);
|
||||
DbResult<bool> EliminarTipo(
|
||||
int cveTipoNotificacion, int usuario, string dominio);
|
||||
|
||||
DbResult<List<ConfiguracionNotificacionModel>> ListarConfiguraciones(
|
||||
string origen, int? cveOrigen, int usuario, string dominio);
|
||||
DbResult<int> GuardarConfiguracion(
|
||||
ConfiguracionNotificacionModel model, int usuario, string dominio);
|
||||
DbResult<bool> EliminarConfiguracion(
|
||||
string origen, int cveConfiguracion, int usuario, string dominio);
|
||||
|
||||
DbResult<List<ConfiguracionNotificacionModel>> ResolverDocumento(
|
||||
int cveTipoDocumento,
|
||||
string evento,
|
||||
int cveCliente,
|
||||
int cveFraccionamientoEtapa,
|
||||
int usuario,
|
||||
string dominio);
|
||||
|
||||
DbResult<List<ConfiguracionNotificacionModel>> ResolverTramite(
|
||||
int cveTipoTramite,
|
||||
string evento,
|
||||
int cveCliente,
|
||||
int cveFraccionamientoEtapa,
|
||||
int usuario,
|
||||
string dominio);
|
||||
|
||||
DbResult<long> RegistrarHistorial(
|
||||
HistorialNotificacionModel model,
|
||||
int usuario,
|
||||
string dominio);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Notifications.Models;
|
||||
|
||||
namespace SIG.Web.AppCode.Notifications.Contracts
|
||||
{
|
||||
public interface INotificacionService
|
||||
{
|
||||
DbResult<bool> Enviar(
|
||||
SolicitudEnvioNotificacionModel solicitud,
|
||||
int usuario,
|
||||
string dominio);
|
||||
}
|
||||
}
|
||||
65
SIG.Web/App_Code/Notifications/Models/NotificacionModels.cs
Normal file
@@ -0,0 +1,65 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SIG.Web.AppCode.Notifications.Models
|
||||
{
|
||||
public sealed class TipoNotificacionModel
|
||||
{
|
||||
public int CveTipoNotificacion { get; set; }
|
||||
public string Codigo { get; set; }
|
||||
public string Nombre { get; set; }
|
||||
public string TipoEnvio { get; set; }
|
||||
public string Asunto { get; set; }
|
||||
public string CuerpoHtml { get; set; }
|
||||
public bool GeneraHistorial { get; set; }
|
||||
public bool EsActivo { get; set; }
|
||||
}
|
||||
|
||||
public sealed class ConfiguracionNotificacionModel
|
||||
{
|
||||
public int CveConfiguracionNotificacion { get; set; }
|
||||
public string Origen { get; set; }
|
||||
public int CveOrigen { get; set; }
|
||||
public string OrigenNombre { get; set; }
|
||||
public string Evento { get; set; }
|
||||
public int CveTipoNotificacion { get; set; }
|
||||
public string TipoNotificacion { get; set; }
|
||||
public string CorreoDestino { get; set; }
|
||||
public int? CveCliente { get; set; }
|
||||
public string Cliente { get; set; }
|
||||
public int? CveFraccionamientoEtapa { get; set; }
|
||||
public string Fraccionamiento { get; set; }
|
||||
public string Etapa { get; set; }
|
||||
public bool EsActivo { get; set; }
|
||||
}
|
||||
|
||||
public sealed class SolicitudEnvioNotificacionModel
|
||||
{
|
||||
public int CveTipoNotificacion { get; set; }
|
||||
public string CorreoDestino { get; set; }
|
||||
public string Origen { get; set; }
|
||||
public string Evento { get; set; }
|
||||
public long? CveReferencia { get; set; }
|
||||
public int? CveCliente { get; set; }
|
||||
public int? CveFraccionamientoEtapa { get; set; }
|
||||
public IDictionary<string, string> Variables { get; set; }
|
||||
}
|
||||
|
||||
public sealed class HistorialNotificacionModel
|
||||
{
|
||||
public int CveTipoNotificacion { get; set; }
|
||||
public string TipoEnvio { get; set; }
|
||||
public string Origen { get; set; }
|
||||
public string Evento { get; set; }
|
||||
public long? CveReferencia { get; set; }
|
||||
public int? CveCliente { get; set; }
|
||||
public int? CveFraccionamientoEtapa { get; set; }
|
||||
public string Destinatario { get; set; }
|
||||
public string Asunto { get; set; }
|
||||
public string Mensaje { get; set; }
|
||||
public bool Enviado { get; set; }
|
||||
public DateTime FechaIntento { get; set; }
|
||||
public DateTime? FechaEnvio { get; set; }
|
||||
public string MensajeResultado { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,197 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using SIG.Web.AppCode.Contracts.Database;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Notifications.Contracts;
|
||||
using SIG.Web.AppCode.Notifications.Models;
|
||||
using SIG.Web.AppCode.Repositories.Database;
|
||||
|
||||
namespace SIG.Web.AppCode.Notifications.Repositories
|
||||
{
|
||||
public sealed class NotificacionRepository
|
||||
: RepositoryBase, INotificacionRepository
|
||||
{
|
||||
public NotificacionRepository(IDbExecutor db)
|
||||
: base(db)
|
||||
{
|
||||
}
|
||||
|
||||
public DbResult<List<TipoNotificacionModel>> ListarTipos(
|
||||
bool incluirInactivos, int usuario, string dominio)
|
||||
{
|
||||
return QueryList<TipoNotificacionModel>(
|
||||
"dbo.PA_Not_TipoNotificacionList",
|
||||
usuario,
|
||||
dominio,
|
||||
c => StoredProcedureCommand.AddInput(
|
||||
c, "@IncluirInactivos", incluirInactivos, DbType.Boolean));
|
||||
}
|
||||
|
||||
public DbResult<TipoNotificacionModel> ObtenerTipo(
|
||||
int cveTipoNotificacion, int usuario, string dominio)
|
||||
{
|
||||
return QueryOne<TipoNotificacionModel>(
|
||||
"dbo.PA_Not_TipoNotificacionGet",
|
||||
usuario,
|
||||
dominio,
|
||||
c => StoredProcedureCommand.AddInput(
|
||||
c, "@CveTipoNotificacion", cveTipoNotificacion, DbType.Int32));
|
||||
}
|
||||
|
||||
public DbResult<int> GuardarTipo(
|
||||
TipoNotificacionModel model, int usuario, string dominio)
|
||||
{
|
||||
return QueryScalarId(
|
||||
"dbo.PA_Not_TipoNotificacionSave",
|
||||
usuario,
|
||||
dominio,
|
||||
c =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(c, "@CveTipoNotificacion",
|
||||
model.CveTipoNotificacion <= 0 ? (object)null : model.CveTipoNotificacion,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@Codigo", model.Codigo, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@Nombre", model.Nombre, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@TipoEnvio", model.TipoEnvio, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@Asunto", model.Asunto, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@CuerpoHtml", model.CuerpoHtml, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@GeneraHistorial", model.GeneraHistorial, DbType.Boolean);
|
||||
StoredProcedureCommand.AddInput(c, "@EsActivo", model.EsActivo, DbType.Boolean);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<bool> EliminarTipo(
|
||||
int cveTipoNotificacion, int usuario, string dominio)
|
||||
{
|
||||
return Execute(
|
||||
"dbo.PA_Not_TipoNotificacionDelete",
|
||||
usuario,
|
||||
dominio,
|
||||
c => StoredProcedureCommand.AddInput(
|
||||
c, "@CveTipoNotificacion", cveTipoNotificacion, DbType.Int32));
|
||||
}
|
||||
|
||||
public DbResult<List<ConfiguracionNotificacionModel>> ListarConfiguraciones(
|
||||
string origen, int? cveOrigen, int usuario, string dominio)
|
||||
{
|
||||
return QueryList<ConfiguracionNotificacionModel>(
|
||||
"dbo.PA_Not_ConfiguracionList",
|
||||
usuario,
|
||||
dominio,
|
||||
c =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(c, "@Origen", origen, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@CveOrigen", cveOrigen, DbType.Int32);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<int> GuardarConfiguracion(
|
||||
ConfiguracionNotificacionModel model, int usuario, string dominio)
|
||||
{
|
||||
return QueryScalarId(
|
||||
"dbo.PA_Not_ConfiguracionSave",
|
||||
usuario,
|
||||
dominio,
|
||||
c =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(c, "@Origen", model.Origen, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@CveConfiguracionNotificacion",
|
||||
model.CveConfiguracionNotificacion <= 0
|
||||
? (object)null
|
||||
: model.CveConfiguracionNotificacion,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@CveOrigen", model.CveOrigen, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@Evento", model.Evento, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@CveTipoNotificacion", model.CveTipoNotificacion, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@CorreoDestino", model.CorreoDestino, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@CveCliente", model.CveCliente, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamientoEtapa", model.CveFraccionamientoEtapa, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@EsActivo", model.EsActivo, DbType.Boolean);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<bool> EliminarConfiguracion(
|
||||
string origen, int cveConfiguracion, int usuario, string dominio)
|
||||
{
|
||||
return Execute(
|
||||
"dbo.PA_Not_ConfiguracionDelete",
|
||||
usuario,
|
||||
dominio,
|
||||
c =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(c, "@Origen", origen, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@CveConfiguracionNotificacion", cveConfiguracion, DbType.Int32);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<List<ConfiguracionNotificacionModel>> ResolverDocumento(
|
||||
int cveTipoDocumento,
|
||||
string evento,
|
||||
int cveCliente,
|
||||
int cveFraccionamientoEtapa,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
return QueryList<ConfiguracionNotificacionModel>(
|
||||
"dbo.PA_Not_TipoDocumentoNotificacionResolve",
|
||||
usuario,
|
||||
dominio,
|
||||
c =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(c, "@CveTipoDocumento", cveTipoDocumento, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@Evento", evento, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@CveCliente", cveCliente, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamientoEtapa", cveFraccionamientoEtapa, DbType.Int32);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<List<ConfiguracionNotificacionModel>> ResolverTramite(
|
||||
int cveTipoTramite,
|
||||
string evento,
|
||||
int cveCliente,
|
||||
int cveFraccionamientoEtapa,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
return QueryList<ConfiguracionNotificacionModel>(
|
||||
"dbo.PA_Not_TipoTramiteNotificacionResolve",
|
||||
usuario,
|
||||
dominio,
|
||||
c =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(c, "@CveTipoTramite", cveTipoTramite, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@Evento", evento, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@CveCliente", cveCliente, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamientoEtapa", cveFraccionamientoEtapa, DbType.Int32);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<long> RegistrarHistorial(
|
||||
HistorialNotificacionModel model,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
return QueryScalarLong(
|
||||
"dbo.PA_Not_NotificacionAdd",
|
||||
usuario,
|
||||
dominio,
|
||||
c =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(c, "@CveTipoNotificacion", model.CveTipoNotificacion, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@TipoEnvio", model.TipoEnvio, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@Origen", model.Origen, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@Evento", model.Evento, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@CveReferencia", model.CveReferencia, DbType.Int64);
|
||||
StoredProcedureCommand.AddInput(c, "@CveCliente", model.CveCliente, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamientoEtapa", model.CveFraccionamientoEtapa, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@Destinatario", model.Destinatario, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@Asunto", model.Asunto, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@Mensaje", model.Mensaje, DbType.String);
|
||||
StoredProcedureCommand.AddInput(c, "@Enviado", model.Enviado, DbType.Boolean);
|
||||
StoredProcedureCommand.AddInput(c, "@FechaIntento", model.FechaIntento, DbType.DateTime2);
|
||||
StoredProcedureCommand.AddInput(c, "@FechaEnvio", model.FechaEnvio, DbType.DateTime2);
|
||||
StoredProcedureCommand.AddInput(c, "@MensajeResultado", model.MensajeResultado, DbType.String);
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,391 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Net.Mail;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Documentos;
|
||||
using SIG.Web.AppCode.Models.Tramites;
|
||||
using SIG.Web.AppCode.Notifications.Contracts;
|
||||
using SIG.Web.AppCode.Notifications.Models;
|
||||
using SIG.Web.AppCode.Services.Logging;
|
||||
|
||||
namespace SIG.Web.AppCode.Notifications.Services
|
||||
{
|
||||
public sealed class NotificacionConfiguracionService
|
||||
: INotificacionConfiguracionService
|
||||
{
|
||||
public const string OrigenDocumento = "DOCUMENTO";
|
||||
public const string OrigenTramite = "TRAMITE";
|
||||
|
||||
private readonly INotificacionRepository _repository;
|
||||
private readonly INotificacionService _notificacionService;
|
||||
|
||||
public NotificacionConfiguracionService(
|
||||
INotificacionRepository repository,
|
||||
INotificacionService notificacionService)
|
||||
{
|
||||
_repository = repository ?? throw new ArgumentNullException("repository");
|
||||
_notificacionService = notificacionService ?? throw new ArgumentNullException("notificacionService");
|
||||
}
|
||||
|
||||
public DbResult<List<TipoNotificacionModel>> ListarTipos(
|
||||
bool incluirInactivos, int usuario, string dominio)
|
||||
{
|
||||
return _repository.ListarTipos(incluirInactivos, usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<TipoNotificacionModel> ObtenerTipo(
|
||||
int cveTipoNotificacion, int usuario, string dominio)
|
||||
{
|
||||
return cveTipoNotificacion > 0
|
||||
? _repository.ObtenerTipo(cveTipoNotificacion, usuario, dominio)
|
||||
: DbResult<TipoNotificacionModel>.Fail(
|
||||
"Seleccione un tipo de notificación válido.",
|
||||
"CveTipoNotificacion inválida.",
|
||||
null);
|
||||
}
|
||||
|
||||
public DbResult<int> GuardarTipo(
|
||||
TipoNotificacionModel model, int usuario, string dominio)
|
||||
{
|
||||
if (model == null ||
|
||||
string.IsNullOrWhiteSpace(model.Codigo) ||
|
||||
string.IsNullOrWhiteSpace(model.Nombre) ||
|
||||
string.IsNullOrWhiteSpace(model.Asunto) ||
|
||||
string.IsNullOrWhiteSpace(model.CuerpoHtml))
|
||||
{
|
||||
return DbResult<int>.Fail(
|
||||
"Capture código, nombre, asunto y cuerpo de la notificación.",
|
||||
"Datos incompletos para Not_TiposNotificacion.",
|
||||
null);
|
||||
}
|
||||
|
||||
model.Codigo = model.Codigo.Trim().ToUpperInvariant();
|
||||
model.Nombre = model.Nombre.Trim();
|
||||
model.TipoEnvio = string.IsNullOrWhiteSpace(model.TipoEnvio)
|
||||
? "CORREO"
|
||||
: model.TipoEnvio.Trim().ToUpperInvariant();
|
||||
model.Asunto = model.Asunto.Trim();
|
||||
model.CuerpoHtml = model.CuerpoHtml.Trim();
|
||||
|
||||
return _repository.GuardarTipo(model, usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<bool> EliminarTipo(
|
||||
int cveTipoNotificacion, int usuario, string dominio)
|
||||
{
|
||||
return cveTipoNotificacion > 0
|
||||
? _repository.EliminarTipo(cveTipoNotificacion, usuario, dominio)
|
||||
: DbResult<bool>.Fail(
|
||||
"Seleccione un tipo de notificación válido.",
|
||||
"CveTipoNotificacion inválida.",
|
||||
null);
|
||||
}
|
||||
|
||||
public DbResult<List<ConfiguracionNotificacionModel>> ListarConfiguraciones(
|
||||
string origen, int? cveOrigen, int usuario, string dominio)
|
||||
{
|
||||
origen = NormalizarOrigen(origen);
|
||||
if (origen == null ||
|
||||
(cveOrigen.HasValue && cveOrigen.Value <= 0))
|
||||
{
|
||||
return DbResult<List<ConfiguracionNotificacionModel>>.Fail(
|
||||
"Seleccione un origen válido.",
|
||||
"Origen o CveOrigen inválidos.",
|
||||
null);
|
||||
}
|
||||
|
||||
return _repository.ListarConfiguraciones(
|
||||
origen, cveOrigen, usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<int> GuardarConfiguracion(
|
||||
ConfiguracionNotificacionModel model, int usuario, string dominio)
|
||||
{
|
||||
if (model == null)
|
||||
{
|
||||
return DbResult<int>.Fail(
|
||||
"Capture la configuración de notificación.",
|
||||
"ConfiguracionNotificacionModel nulo.",
|
||||
null);
|
||||
}
|
||||
|
||||
model.Origen = NormalizarOrigen(model.Origen);
|
||||
model.Evento = (model.Evento ?? string.Empty).Trim().ToUpperInvariant();
|
||||
model.CorreoDestino = (model.CorreoDestino ?? string.Empty).Trim();
|
||||
|
||||
if (model.Origen == null ||
|
||||
model.CveOrigen <= 0 ||
|
||||
model.CveTipoNotificacion <= 0 ||
|
||||
model.Evento.Length == 0 ||
|
||||
!CorreoValido(model.CorreoDestino))
|
||||
{
|
||||
return DbResult<int>.Fail(
|
||||
"Seleccione el evento y tipo de notificación, y capture un correo válido.",
|
||||
"Configuración de notificación incompleta.",
|
||||
null);
|
||||
}
|
||||
|
||||
return _repository.GuardarConfiguracion(model, usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<bool> EliminarConfiguracion(
|
||||
string origen, int cveConfiguracion, int usuario, string dominio)
|
||||
{
|
||||
origen = NormalizarOrigen(origen);
|
||||
if (origen == null || cveConfiguracion <= 0)
|
||||
{
|
||||
return DbResult<bool>.Fail(
|
||||
"Seleccione una configuración válida.",
|
||||
"Origen o CveConfiguracion inválidos.",
|
||||
null);
|
||||
}
|
||||
|
||||
return _repository.EliminarConfiguracion(
|
||||
origen, cveConfiguracion, usuario, dominio);
|
||||
}
|
||||
|
||||
public void NotificarDocumentoCargado(
|
||||
TramiteDocumentoSaveResultModel documento,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
if (documento == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
NotificarDocumento(
|
||||
"CARGADO",
|
||||
documento.CveTipoDocumento,
|
||||
documento.CveCliente,
|
||||
documento.CveFraccionamiento,
|
||||
documento.CveFraccionamientoEtapa,
|
||||
documento.CveDocumentoSolicitud,
|
||||
documento.Folio,
|
||||
documento.TipoTramite,
|
||||
documento.TipoDocumento,
|
||||
documento.NombreArchivo,
|
||||
documento.Etapa,
|
||||
usuario,
|
||||
dominio);
|
||||
}
|
||||
|
||||
public void NotificarDocumentoRevisado(
|
||||
TramiteDocumentoReviewResultModel documento,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
if (documento == null || !documento.HuboCambio)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
string evento = documento.EsAprobado == true
|
||||
? "APROBADO"
|
||||
: "RECHAZADO";
|
||||
|
||||
NotificarDocumento(
|
||||
evento,
|
||||
documento.CveTipoDocumento,
|
||||
documento.CveCliente,
|
||||
documento.CveFraccionamiento,
|
||||
documento.CveFraccionamientoEtapa,
|
||||
documento.CveDocumentoSolicitud,
|
||||
documento.Folio,
|
||||
documento.TipoTramite,
|
||||
documento.TipoDocumento,
|
||||
documento.NombreArchivo,
|
||||
documento.Etapa,
|
||||
usuario,
|
||||
dominio);
|
||||
}
|
||||
|
||||
public void NotificarTramite(
|
||||
string evento,
|
||||
TramiteSolicitudStatusChangeModel tramite,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
if (tramite == null || !tramite.HuboCambio)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
evento = (evento ?? string.Empty).Trim().ToUpperInvariant();
|
||||
if (evento.Length == 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
DbResult<List<ConfiguracionNotificacionModel>> configuraciones =
|
||||
_repository.ResolverTramite(
|
||||
tramite.CveTipoTramite,
|
||||
evento,
|
||||
tramite.CveCliente,
|
||||
tramite.CveFraccionamientoEtapa,
|
||||
usuario,
|
||||
dominio);
|
||||
|
||||
if (!configuraciones.Success)
|
||||
{
|
||||
RegistrarErrorConfiguracion(
|
||||
configuraciones,
|
||||
"NotificacionConfiguracionService.NotificarTramite");
|
||||
return;
|
||||
}
|
||||
|
||||
var variables = new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase)
|
||||
{
|
||||
{ "Evento", evento },
|
||||
{ "Folio", tramite.Folio },
|
||||
{ "TipoTramite", tramite.TipoTramite },
|
||||
{ "Etapa", tramite.Etapa },
|
||||
{ "Estatus", tramite.EstatusSolicitud },
|
||||
{ "EstatusAnterior", tramite.EstatusSolicitudAnterior },
|
||||
{ "CveCliente", tramite.CveCliente.ToString() },
|
||||
{ "CveFraccionamiento", tramite.CveFraccionamiento.ToString() },
|
||||
{ "CveFraccionamientoEtapa", tramite.CveFraccionamientoEtapa.ToString() }
|
||||
};
|
||||
|
||||
EnviarConfiguraciones(
|
||||
configuraciones.Data,
|
||||
OrigenTramite,
|
||||
evento,
|
||||
tramite.CveSolicitud,
|
||||
tramite.CveCliente,
|
||||
tramite.CveFraccionamientoEtapa,
|
||||
variables,
|
||||
usuario,
|
||||
dominio);
|
||||
}
|
||||
|
||||
private void NotificarDocumento(
|
||||
string evento,
|
||||
int cveTipoDocumento,
|
||||
int cveCliente,
|
||||
int cveFraccionamiento,
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveDocumentoSolicitud,
|
||||
string folio,
|
||||
string tipoTramite,
|
||||
string tipoDocumento,
|
||||
string nombreArchivo,
|
||||
string etapa,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
DbResult<List<ConfiguracionNotificacionModel>> configuraciones =
|
||||
_repository.ResolverDocumento(
|
||||
cveTipoDocumento,
|
||||
evento,
|
||||
cveCliente,
|
||||
cveFraccionamientoEtapa,
|
||||
usuario,
|
||||
dominio);
|
||||
|
||||
if (!configuraciones.Success)
|
||||
{
|
||||
RegistrarErrorConfiguracion(
|
||||
configuraciones,
|
||||
"NotificacionConfiguracionService.NotificarDocumento");
|
||||
return;
|
||||
}
|
||||
|
||||
var variables = new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase)
|
||||
{
|
||||
{ "Evento", evento },
|
||||
{ "Folio", folio },
|
||||
{ "TipoTramite", tipoTramite },
|
||||
{ "TipoDocumento", tipoDocumento },
|
||||
{ "NombreArchivo", nombreArchivo },
|
||||
{ "Etapa", etapa },
|
||||
{ "CveCliente", cveCliente.ToString() },
|
||||
{ "CveFraccionamiento", cveFraccionamiento.ToString() },
|
||||
{ "CveFraccionamientoEtapa", cveFraccionamientoEtapa.ToString() }
|
||||
};
|
||||
|
||||
EnviarConfiguraciones(
|
||||
configuraciones.Data,
|
||||
OrigenDocumento,
|
||||
evento,
|
||||
cveDocumentoSolicitud,
|
||||
cveCliente,
|
||||
cveFraccionamientoEtapa,
|
||||
variables,
|
||||
usuario,
|
||||
dominio);
|
||||
}
|
||||
|
||||
private void EnviarConfiguraciones(
|
||||
IEnumerable<ConfiguracionNotificacionModel> configuraciones,
|
||||
string origen,
|
||||
string evento,
|
||||
long cveReferencia,
|
||||
int cveCliente,
|
||||
int cveFraccionamientoEtapa,
|
||||
IDictionary<string, string> variables,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
foreach (ConfiguracionNotificacionModel configuracion in
|
||||
configuraciones ?? Enumerable.Empty<ConfiguracionNotificacionModel>())
|
||||
{
|
||||
_notificacionService.Enviar(
|
||||
new SolicitudEnvioNotificacionModel
|
||||
{
|
||||
CveTipoNotificacion = configuracion.CveTipoNotificacion,
|
||||
CorreoDestino = configuracion.CorreoDestino,
|
||||
Origen = origen,
|
||||
Evento = evento,
|
||||
CveReferencia = cveReferencia,
|
||||
CveCliente = cveCliente,
|
||||
CveFraccionamientoEtapa = cveFraccionamientoEtapa,
|
||||
Variables = variables
|
||||
},
|
||||
usuario,
|
||||
dominio);
|
||||
}
|
||||
}
|
||||
|
||||
private static string NormalizarOrigen(string origen)
|
||||
{
|
||||
string valor = (origen ?? string.Empty).Trim().ToUpperInvariant();
|
||||
return valor == OrigenDocumento || valor == OrigenTramite
|
||||
? valor
|
||||
: null;
|
||||
}
|
||||
|
||||
private static bool CorreoValido(string correo)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(correo))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
var mail = new MailAddress(correo.Trim());
|
||||
return string.Equals(
|
||||
mail.Address,
|
||||
correo.Trim(),
|
||||
StringComparison.OrdinalIgnoreCase);
|
||||
}
|
||||
catch
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
private static void RegistrarErrorConfiguracion<T>(
|
||||
DbResult<T> resultado,
|
||||
string origen)
|
||||
{
|
||||
ExceptionLogger.Log(
|
||||
resultado.Exception ?? new InvalidOperationException(
|
||||
resultado.TechnicalMessage ?? resultado.UserMessage),
|
||||
origen,
|
||||
"No fue posible resolver las notificaciones configuradas.");
|
||||
}
|
||||
}
|
||||
}
|
||||
239
SIG.Web/App_Code/Notifications/Services/NotificacionService.cs
Normal file
@@ -0,0 +1,239 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using SIG.Web.AppCode.Contracts.Security;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Notifications.Contracts;
|
||||
using SIG.Web.AppCode.Notifications.Models;
|
||||
using SIG.Web.AppCode.Services.Logging;
|
||||
|
||||
namespace SIG.Web.AppCode.Notifications.Services
|
||||
{
|
||||
public sealed class NotificacionService : INotificacionService
|
||||
{
|
||||
private readonly INotificacionRepository _repository;
|
||||
private readonly IEmailSender _emailSender;
|
||||
|
||||
public NotificacionService(
|
||||
INotificacionRepository repository,
|
||||
IEmailSender emailSender)
|
||||
{
|
||||
_repository = repository ?? throw new ArgumentNullException("repository");
|
||||
_emailSender = emailSender ?? throw new ArgumentNullException("emailSender");
|
||||
}
|
||||
|
||||
public DbResult<bool> Enviar(
|
||||
SolicitudEnvioNotificacionModel solicitud,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
if (solicitud == null || solicitud.CveTipoNotificacion <= 0)
|
||||
{
|
||||
return DbResult<bool>.Fail(
|
||||
"Seleccione un tipo de notificación válido.",
|
||||
"Solicitud de notificación sin tipo.",
|
||||
null);
|
||||
}
|
||||
|
||||
if (string.IsNullOrWhiteSpace(solicitud.CorreoDestino))
|
||||
{
|
||||
return DbResult<bool>.Fail(
|
||||
"La notificación no tiene destinatario.",
|
||||
"Solicitud de notificación sin CorreoDestino.",
|
||||
null);
|
||||
}
|
||||
|
||||
DbResult<TipoNotificacionModel> tipo =
|
||||
_repository.ObtenerTipo(
|
||||
solicitud.CveTipoNotificacion,
|
||||
usuario,
|
||||
dominio);
|
||||
|
||||
if (!tipo.Success || tipo.Data == null || !tipo.Data.EsActivo)
|
||||
{
|
||||
string detalle = tipo.Success
|
||||
? "El tipo de notificación está inactivo o no existe."
|
||||
: tipo.TechnicalMessage;
|
||||
|
||||
ExceptionLogger.Log(
|
||||
new InvalidOperationException(detalle),
|
||||
"NotificacionService.Enviar.Tipo",
|
||||
"No fue posible preparar la notificación.");
|
||||
|
||||
return DbResult<bool>.Fail(
|
||||
"No fue posible preparar la notificación.",
|
||||
detalle,
|
||||
tipo.Exception);
|
||||
}
|
||||
|
||||
using (var envio = new NotificacionEnvioScope(
|
||||
_repository,
|
||||
_emailSender,
|
||||
tipo.Data,
|
||||
solicitud,
|
||||
usuario,
|
||||
dominio))
|
||||
{
|
||||
return envio.Enviar();
|
||||
}
|
||||
}
|
||||
|
||||
private sealed class NotificacionEnvioScope : IDisposable
|
||||
{
|
||||
private readonly INotificacionRepository _repository;
|
||||
private readonly IEmailSender _emailSender;
|
||||
private readonly TipoNotificacionModel _tipo;
|
||||
private readonly SolicitudEnvioNotificacionModel _solicitud;
|
||||
private readonly int _usuario;
|
||||
private readonly string _dominio;
|
||||
private readonly DateTime _fechaIntento;
|
||||
private bool _enviado;
|
||||
private DateTime? _fechaEnvio;
|
||||
private string _resultado;
|
||||
private string _asunto;
|
||||
private string _mensaje;
|
||||
private bool _disposed;
|
||||
|
||||
public NotificacionEnvioScope(
|
||||
INotificacionRepository repository,
|
||||
IEmailSender emailSender,
|
||||
TipoNotificacionModel tipo,
|
||||
SolicitudEnvioNotificacionModel solicitud,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
_repository = repository;
|
||||
_emailSender = emailSender;
|
||||
_tipo = tipo;
|
||||
_solicitud = solicitud;
|
||||
_usuario = usuario;
|
||||
_dominio = dominio;
|
||||
_fechaIntento = DateTime.Now;
|
||||
_enviado = false;
|
||||
_resultado = "No fue posible enviar la notificación.";
|
||||
_asunto = AplicarVariables(tipo.Asunto, solicitud.Variables);
|
||||
_mensaje = AplicarVariables(tipo.CuerpoHtml, solicitud.Variables);
|
||||
}
|
||||
|
||||
public DbResult<bool> Enviar()
|
||||
{
|
||||
try
|
||||
{
|
||||
if (!string.Equals(
|
||||
_tipo.TipoEnvio,
|
||||
"CORREO",
|
||||
StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
throw new InvalidOperationException(
|
||||
"Tipo de envío no soportado: " + _tipo.TipoEnvio + ".");
|
||||
}
|
||||
|
||||
_emailSender.Send(
|
||||
_solicitud.CorreoDestino,
|
||||
_asunto,
|
||||
_mensaje);
|
||||
|
||||
_enviado = true;
|
||||
_fechaEnvio = DateTime.Now;
|
||||
_resultado = "Enviado correctamente.";
|
||||
return DbResult<bool>.Ok(true);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
_enviado = false;
|
||||
_fechaEnvio = null;
|
||||
_resultado = "No fue posible enviar la notificación.";
|
||||
|
||||
ExceptionLogger.Log(
|
||||
ex,
|
||||
"NotificacionService.Enviar.Correo",
|
||||
_resultado +
|
||||
" Tipo=" + _tipo.Codigo +
|
||||
"; Destinatario=" + _solicitud.CorreoDestino +
|
||||
"; Origen=" + _solicitud.Origen +
|
||||
"; Evento=" + _solicitud.Evento + ".");
|
||||
|
||||
return DbResult<bool>.Fail(
|
||||
_resultado,
|
||||
ex.Message,
|
||||
ex);
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (_disposed)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
_disposed = true;
|
||||
|
||||
if (!_tipo.GeneraHistorial)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
DbResult<long> registro = _repository.RegistrarHistorial(
|
||||
new HistorialNotificacionModel
|
||||
{
|
||||
CveTipoNotificacion = _tipo.CveTipoNotificacion,
|
||||
TipoEnvio = _tipo.TipoEnvio,
|
||||
Origen = _solicitud.Origen,
|
||||
Evento = _solicitud.Evento,
|
||||
CveReferencia = _solicitud.CveReferencia,
|
||||
CveCliente = _solicitud.CveCliente,
|
||||
CveFraccionamientoEtapa = _solicitud.CveFraccionamientoEtapa,
|
||||
Destinatario = _solicitud.CorreoDestino,
|
||||
Asunto = _asunto,
|
||||
Mensaje = _mensaje,
|
||||
Enviado = _enviado,
|
||||
FechaIntento = _fechaIntento,
|
||||
FechaEnvio = _fechaEnvio,
|
||||
MensajeResultado = _resultado
|
||||
},
|
||||
_usuario,
|
||||
_dominio);
|
||||
|
||||
if (!registro.Success)
|
||||
{
|
||||
ExceptionLogger.Log(
|
||||
registro.Exception ?? new InvalidOperationException(
|
||||
registro.TechnicalMessage ?? registro.UserMessage),
|
||||
"NotificacionService.Dispose.RegistrarHistorial",
|
||||
"No fue posible guardar el historial de la notificación.");
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
// El Dispose nunca debe tapar el resultado de la operación original.
|
||||
ExceptionLogger.Log(
|
||||
ex,
|
||||
"NotificacionService.Dispose",
|
||||
"No fue posible guardar el historial de la notificación.");
|
||||
}
|
||||
}
|
||||
|
||||
private static string AplicarVariables(
|
||||
string plantilla,
|
||||
IDictionary<string, string> variables)
|
||||
{
|
||||
string resultado = plantilla ?? string.Empty;
|
||||
if (variables == null)
|
||||
{
|
||||
return resultado;
|
||||
}
|
||||
|
||||
foreach (KeyValuePair<string, string> variable in variables)
|
||||
{
|
||||
resultado = resultado.Replace(
|
||||
"{" + variable.Key + "}",
|
||||
variable.Value ?? string.Empty);
|
||||
}
|
||||
|
||||
return resultado;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,243 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Globalization;
|
||||
using System.Linq;
|
||||
using System.Xml.Linq;
|
||||
using SIG.Web.AppCode.Contracts.Clientes;
|
||||
using SIG.Web.AppCode.Contracts.Database;
|
||||
using SIG.Web.AppCode.Models.Clientes;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Repositories.Database;
|
||||
|
||||
namespace SIG.Web.AppCode.Repositories.Clientes
|
||||
{
|
||||
public sealed class RepositorioPortalCliente
|
||||
: RepositoryBase, IRepositorioPortalCliente
|
||||
{
|
||||
private const string ProcedimientoPagosListar =
|
||||
"dbo.PA_Clientes_ConvenioPagoList";
|
||||
private const string ProcedimientoPagosPendientesTramitesListar =
|
||||
"dbo.PA_Clientes_ConvenioPagoPendienteTramiteList";
|
||||
private const string ProcedimientoRecibosListar =
|
||||
"dbo.PA_Clientes_ConvenioReciboPendienteList";
|
||||
private const string ProcedimientoPagoAgregar =
|
||||
"dbo.PA_Clientes_ConvenioPagoAdd";
|
||||
private const string ProcedimientoPagoArchivoObtener =
|
||||
"dbo.PA_Clientes_ConvenioPagoArchivoGet";
|
||||
|
||||
public RepositorioPortalCliente(IDbExecutor ejecutor)
|
||||
: base(ejecutor)
|
||||
{
|
||||
}
|
||||
|
||||
public DbResult<List<PagoPendienteTramiteCliente>> ListarPagosPendientesTramites(
|
||||
int cveCliente,
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return QueryList<PagoPendienteTramiteCliente>(
|
||||
ProcedimientoPagosPendientesTramitesListar,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveCliente",
|
||||
cveCliente,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveFraccionamiento",
|
||||
cveFraccionamiento,
|
||||
DbType.Int32);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<List<PagoConvenioClienteFila>> ListarPagos(
|
||||
int cveCliente,
|
||||
int? cveFraccionamiento,
|
||||
int? cveFraccionamientoEtapa,
|
||||
string agrupacion,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return QueryList<PagoConvenioClienteFila>(
|
||||
ProcedimientoPagosListar,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveCliente",
|
||||
cveCliente,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveFraccionamiento",
|
||||
cveFraccionamiento,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveFraccionamientoEtapa",
|
||||
cveFraccionamientoEtapa,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@Agrupacion",
|
||||
agrupacion,
|
||||
DbType.String);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<List<ReciboConvenioDisponibleCliente>> ListarRecibosDisponibles(
|
||||
int cveCliente,
|
||||
int? cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return QueryList<ReciboConvenioDisponibleCliente>(
|
||||
ProcedimientoRecibosListar,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveCliente",
|
||||
cveCliente,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveFraccionamiento",
|
||||
cveFraccionamiento,
|
||||
DbType.Int32);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<int> AgregarPago(
|
||||
SolicitudPagoConvenioCliente pago,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return QueryScalarId(
|
||||
ProcedimientoPagoAgregar,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveCliente",
|
||||
pago.CveCliente,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@Importe",
|
||||
pago.Importe,
|
||||
DbType.Decimal);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@FechaPago",
|
||||
pago.FechaPago,
|
||||
DbType.DateTime);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@Referencia",
|
||||
pago.Referencia,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@Banco",
|
||||
pago.Banco,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@NumeroOperacion",
|
||||
pago.NumeroOperacion,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@Observaciones",
|
||||
pago.Observaciones,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@NombreArchivo",
|
||||
pago.NombreArchivo,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@NombreFisico",
|
||||
pago.NombreFisico,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@TipoContenido",
|
||||
pago.TipoContenido,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@TamanoBytes",
|
||||
pago.TamanoBytes,
|
||||
DbType.Int64);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@AplicacionesXml",
|
||||
SerializarAplicaciones(pago.Aplicaciones),
|
||||
DbType.Xml);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<ArchivoPagoConvenioCliente> ObtenerArchivoPago(
|
||||
int cveConvenioPago,
|
||||
int cveCliente,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return QueryOne<ArchivoPagoConvenioCliente>(
|
||||
ProcedimientoPagoArchivoObtener,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveConvenioPago",
|
||||
cveConvenioPago,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveCliente",
|
||||
cveCliente,
|
||||
DbType.Int32);
|
||||
});
|
||||
}
|
||||
|
||||
private static string SerializarAplicaciones(
|
||||
IEnumerable<AplicacionPagoConvenioCliente> aplicaciones)
|
||||
{
|
||||
IEnumerable<AplicacionPagoConvenioCliente> lista =
|
||||
aplicaciones ?? Enumerable.Empty<AplicacionPagoConvenioCliente>();
|
||||
|
||||
var raiz = new XElement(
|
||||
"Aplicaciones",
|
||||
lista.Select((aplicacion, indice) =>
|
||||
new XElement(
|
||||
"Aplicacion",
|
||||
new XAttribute("Orden", indice + 1),
|
||||
new XAttribute(
|
||||
"CveConvenioRecibo",
|
||||
aplicacion.CveConvenioRecibo),
|
||||
new XAttribute(
|
||||
"ImporteAplicado",
|
||||
aplicacion.ImporteAplicado.ToString(
|
||||
"0.######",
|
||||
CultureInfo.InvariantCulture)))));
|
||||
|
||||
return raiz.ToString(SaveOptions.DisableFormatting);
|
||||
}
|
||||
}
|
||||
}
|
||||
317
SIG.Web/App_Code/Repositories/Convenios/RepositorioConvenios.cs
Normal file
@@ -0,0 +1,317 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Globalization;
|
||||
using System.Linq;
|
||||
using System.Xml.Linq;
|
||||
using SIG.Web.AppCode.Contracts.Convenios;
|
||||
using SIG.Web.AppCode.Contracts.Database;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Convenios;
|
||||
using SIG.Web.AppCode.Repositories.Database;
|
||||
using SIG.Web.AppCode.Utilities;
|
||||
|
||||
namespace SIG.Web.AppCode.Repositories.Convenios
|
||||
{
|
||||
public sealed class RepositorioConvenios : RepositoryBase, IRepositorioConvenios
|
||||
{
|
||||
private const string ProcedimientoListar = "dbo.PA_Tra_ConvenioList";
|
||||
private const string ProcedimientoObtener = "dbo.PA_Tra_ConvenioGet";
|
||||
private const string ProcedimientoListarConceptos = "dbo.PA_Tra_ConvenioConceptoList";
|
||||
private const string ProcedimientoAgregar = "dbo.PA_Tra_ConvenioAdd";
|
||||
private const string ProcedimientoObtenerLotes = "dbo.PA_Tra_ConvenioLotesGet";
|
||||
private const string ProcedimientoGuardarLotes = "dbo.PA_Tra_ConvenioLotesUpdate";
|
||||
private const string ProcedimientoEliminar = "dbo.PA_Tra_ConvenioDelete";
|
||||
|
||||
public RepositorioConvenios(IDbExecutor ejecutor)
|
||||
: base(ejecutor)
|
||||
{
|
||||
}
|
||||
|
||||
public DbResult<List<ConvenioListado>> Listar(
|
||||
FiltroConvenios filtro,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
filtro = filtro ?? new FiltroConvenios();
|
||||
|
||||
return QueryList<ConvenioListado>(
|
||||
ProcedimientoListar,
|
||||
usuario,
|
||||
dominio,
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveCliente",
|
||||
filtro.CveCliente,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveFraccionamiento",
|
||||
filtro.CveFraccionamiento,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveFraccionamientoEtapa",
|
||||
filtro.CveFraccionamientoEtapa,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveTipoTramite",
|
||||
filtro.CveTipoTramite,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@Estatus",
|
||||
filtro.Estatus,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@ConSaldoPendiente",
|
||||
filtro.ConSaldoPendiente,
|
||||
DbType.Boolean);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<ConvenioDetalleCompleto> Obtener(
|
||||
int cveConvenio,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
return QueryReader(
|
||||
ProcedimientoObtener,
|
||||
usuario,
|
||||
dominio,
|
||||
comando => StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveConvenio",
|
||||
cveConvenio,
|
||||
DbType.Int32),
|
||||
lector =>
|
||||
{
|
||||
var resultado = new ConvenioDetalleCompleto
|
||||
{
|
||||
Encabezado = lector.ToObject<ConvenioDetalleEncabezado>(),
|
||||
Conceptos = new List<ConvenioConceptoDetalle>(),
|
||||
Recibos = new List<ConvenioReciboDetalle>()
|
||||
};
|
||||
|
||||
if (!lector.NextResult())
|
||||
{
|
||||
throw new InvalidOperationException(
|
||||
"Falta el resultado de conceptos del convenio.");
|
||||
}
|
||||
|
||||
resultado.Conceptos = lector.ToList<ConvenioConceptoDetalle>();
|
||||
|
||||
if (!lector.NextResult())
|
||||
{
|
||||
throw new InvalidOperationException(
|
||||
"Falta el resultado de recibos del convenio.");
|
||||
}
|
||||
|
||||
resultado.Recibos = lector.ToList<ConvenioReciboDetalle>();
|
||||
return resultado;
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<List<ConvenioConceptoCatalogo>> ListarConceptos(
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
return QueryList<ConvenioConceptoCatalogo>(
|
||||
ProcedimientoListarConceptos,
|
||||
usuario,
|
||||
dominio,
|
||||
null);
|
||||
}
|
||||
|
||||
public DbResult<int> Agregar(
|
||||
SolicitudAltaConvenio solicitud,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
if (solicitud == null)
|
||||
{
|
||||
throw new ArgumentNullException("solicitud");
|
||||
}
|
||||
|
||||
string conceptosXml = SerializarConceptos(solicitud.Conceptos);
|
||||
|
||||
return QueryScalarId(
|
||||
ProcedimientoAgregar,
|
||||
usuario,
|
||||
dominio,
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveCliente",
|
||||
solicitud.CveCliente,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveFraccionamientoEtapa",
|
||||
solicitud.CveFraccionamientoEtapa,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveTipoTramite",
|
||||
solicitud.CveTipoTramite,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@NumeroConvenio",
|
||||
solicitud.NumeroConvenio,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@NumeroOficio",
|
||||
solicitud.NumeroOficio,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@ViviendasAutorizadas",
|
||||
solicitud.ViviendasAutorizadas,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@ViviendasEnConvenio",
|
||||
solicitud.ViviendasEnConvenio,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@ViviendasPendientes",
|
||||
solicitud.ViviendasPendientes,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@ViviendasContratadas",
|
||||
solicitud.ViviendasContratadas,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@FechaConvenio",
|
||||
solicitud.FechaConvenio,
|
||||
DbType.Date);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@Observaciones",
|
||||
solicitud.Observaciones,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@ConceptosXml",
|
||||
conceptosXml,
|
||||
DbType.Xml);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<ConvenioLotesConvenio> ObtenerLotesConvenio(
|
||||
int cveConvenio,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
return QueryOne<ConvenioLotesConvenio>(
|
||||
ProcedimientoObtenerLotes,
|
||||
usuario,
|
||||
dominio,
|
||||
comando => StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveConvenio",
|
||||
cveConvenio,
|
||||
DbType.Int32));
|
||||
}
|
||||
|
||||
public DbResult<bool> GuardarLotesConvenio(
|
||||
int cveConvenio,
|
||||
int lotesConvenio,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
return Execute(
|
||||
ProcedimientoGuardarLotes,
|
||||
usuario,
|
||||
dominio,
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveConvenio",
|
||||
cveConvenio,
|
||||
DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@LotesConvenio",
|
||||
lotesConvenio,
|
||||
DbType.Int32);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<bool> Eliminar(
|
||||
int cveConvenio,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
return Execute(
|
||||
ProcedimientoEliminar,
|
||||
usuario,
|
||||
dominio,
|
||||
comando => StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveConvenio",
|
||||
cveConvenio,
|
||||
DbType.Int32));
|
||||
}
|
||||
|
||||
private static string SerializarConceptos(
|
||||
IEnumerable<ConvenioConceptoCaptura> conceptos)
|
||||
{
|
||||
IEnumerable<ConvenioConceptoCaptura> lista =
|
||||
conceptos ?? Enumerable.Empty<ConvenioConceptoCaptura>();
|
||||
|
||||
var raiz = new XElement(
|
||||
"Conceptos",
|
||||
lista.Select((concepto, indiceConcepto) =>
|
||||
new XElement(
|
||||
"Concepto",
|
||||
new XAttribute("Orden", indiceConcepto + 1),
|
||||
new XAttribute(
|
||||
"CveConvenioConcepto",
|
||||
concepto.CveConvenioConcepto),
|
||||
new XAttribute(
|
||||
"Importe",
|
||||
concepto.Importe.ToString(
|
||||
"0.######",
|
||||
CultureInfo.InvariantCulture)),
|
||||
new XAttribute("Tipo", concepto.Tipo ?? string.Empty),
|
||||
new XAttribute("NumeroPagos", concepto.NumeroPagos),
|
||||
new XElement(
|
||||
"Recibos",
|
||||
(concepto.Parcialidades ??
|
||||
new List<ConvenioReciboCaptura>())
|
||||
.Select((recibo, indiceRecibo) =>
|
||||
new XElement(
|
||||
"Recibo",
|
||||
new XAttribute("Orden", indiceRecibo + 1),
|
||||
new XAttribute(
|
||||
"Importe",
|
||||
recibo.Importe.ToString(
|
||||
"0.######",
|
||||
CultureInfo.InvariantCulture)),
|
||||
new XAttribute(
|
||||
"FechaVencimiento",
|
||||
recibo.FechaVencimiento.ToString(
|
||||
"yyyy-MM-dd",
|
||||
CultureInfo.InvariantCulture)),
|
||||
new XAttribute(
|
||||
"Estatus",
|
||||
string.IsNullOrWhiteSpace(recibo.Estatus)
|
||||
? "PENDIENTE"
|
||||
: recibo.Estatus)))))));
|
||||
|
||||
return raiz.ToString(SaveOptions.DisableFormatting);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -22,7 +22,8 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
int cveSolicitud,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio,
|
||||
int? cveFraccionamientoEtapa = null)
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null)
|
||||
{
|
||||
return QueryList<SolicitudDocumentoConfiguracionModel>(
|
||||
"dbo.PA_Tramites_SolicitudDocumentoConfiguracionList",
|
||||
@@ -31,6 +32,7 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(comando, "@CveFraccionamientoEtapa", cveFraccionamientoEtapa, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(comando, "@CveTipoTramite", null, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@CveFraccionamiento", cveFraccionamiento, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
@@ -68,6 +70,8 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
comando, "@CveFraccionamiento", configuracion.CveFraccionamiento, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@CveSolicitud", configuracion.CveSolicitud, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@CveTipoTramite", null, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@CveTipoDocumento", configuracion.CveTipoDocumento, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
@@ -89,7 +93,8 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
int cveTipoDocumento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio,
|
||||
int? cveFraccionamientoEtapa = null)
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null)
|
||||
{
|
||||
return Execute(
|
||||
"dbo.PA_Tramites_SolicitudDocumentoConfiguracionDelete",
|
||||
@@ -98,6 +103,7 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(comando, "@CveFraccionamientoEtapa", cveFraccionamientoEtapa, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(comando, "@CveTipoTramite", null, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@CveFraccionamiento", cveFraccionamiento, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
@@ -171,7 +177,8 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
int documentTypeId,
|
||||
int executingUser,
|
||||
string domainName,
|
||||
int? cveFraccionamientoEtapa = null)
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null)
|
||||
{
|
||||
return QueryOne<TramiteDocumentoUploadContextModel>(
|
||||
"dbo.PA_Tramites_DocumentoSolicitudUploadContextGet",
|
||||
@@ -180,6 +187,7 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
command =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(command, "@CveFraccionamientoEtapa", cveFraccionamientoEtapa, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(command, "@CveTipoTramite", null, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
command,
|
||||
"@CveFraccionamiento",
|
||||
@@ -244,7 +252,8 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
DateTime? fechaDocumento = null,
|
||||
DateTime? fechaVencimiento = null,
|
||||
bool actualizarFechas = false,
|
||||
int? cveFraccionamientoEtapa = null)
|
||||
int? cveFraccionamientoEtapa = null,
|
||||
int? cveTipoTramite = null)
|
||||
{
|
||||
return QueryOne<TramiteDocumentoSaveResultModel>(
|
||||
"dbo.PA_Tramites_DocumentoSolicitudSave",
|
||||
@@ -253,6 +262,7 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
command =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(command, "@CveFraccionamientoEtapa", cveFraccionamientoEtapa, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(command, "@CveTipoTramite", null, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(command, "@CveFraccionamiento", developmentId, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(command, "@CveSolicitud", requestId, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(command, "@CveTipoDocumento", documentTypeId, DbType.Int32);
|
||||
@@ -268,6 +278,50 @@ namespace SIG.Web.AppCode.Repositories.Documentos
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<TramiteDocumentoVencimientoResultModel> ActualizarFechaVencimiento(
|
||||
int cveFraccionamiento,
|
||||
int cveDocumentoSolicitud,
|
||||
DateTime? fechaVencimiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return QueryOne<TramiteDocumentoVencimientoResultModel>(
|
||||
"dbo.PA_Tramites_DocumentoSolicitudVencimientoUpdate",
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
command =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
command, "@CveFraccionamiento", cveFraccionamiento, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
command, "@CveDocumentoSolicitud", cveDocumentoSolicitud, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
command, "@FechaVencimiento", fechaVencimiento, DbType.Date);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<TramiteDocumentoNotaResultModel> ActualizarNota(
|
||||
int cveFraccionamiento,
|
||||
int cveDocumentoSolicitud,
|
||||
string nota,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return QueryOne<TramiteDocumentoNotaResultModel>(
|
||||
"dbo.PA_Tramites_DocumentoSolicitudNotaUpdate",
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
command =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
command, "@CveFraccionamiento", cveFraccionamiento, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
command, "@CveDocumentoSolicitud", cveDocumentoSolicitud, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
command, "@Nota", nota, DbType.String);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<TramiteDocumentoReviewResultModel> Review(
|
||||
int developmentId,
|
||||
int documentRequestId,
|
||||
|
||||
@@ -479,6 +479,25 @@ namespace SIG.Web.AppCode.Repositories.Fraccionamientos
|
||||
"@Duplicador",
|
||||
lote.Duplicador,
|
||||
DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@CveTipoVivienda",
|
||||
lote.CveTipoVivienda,
|
||||
DbType.Int32);
|
||||
var parametroLatitud = StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@Latitud",
|
||||
lote.Latitud,
|
||||
DbType.Decimal);
|
||||
parametroLatitud.Precision = 10;
|
||||
parametroLatitud.Scale = 7;
|
||||
var parametroLongitud = StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@Longitud",
|
||||
lote.Longitud,
|
||||
DbType.Decimal);
|
||||
parametroLongitud.Precision = 10;
|
||||
parametroLongitud.Scale = 7;
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando,
|
||||
"@EsActivo",
|
||||
@@ -512,6 +531,21 @@ namespace SIG.Web.AppCode.Repositories.Fraccionamientos
|
||||
new XAttribute(
|
||||
"Duplicador",
|
||||
lote.Duplicador ?? string.Empty),
|
||||
new XAttribute(
|
||||
"CveTipoVivienda",
|
||||
lote.CveTipoVivienda.HasValue
|
||||
? lote.CveTipoVivienda.Value.ToString(CultureInfo.InvariantCulture)
|
||||
: string.Empty),
|
||||
new XAttribute(
|
||||
"Latitud",
|
||||
lote.Latitud.HasValue
|
||||
? lote.Latitud.Value.ToString(CultureInfo.InvariantCulture)
|
||||
: string.Empty),
|
||||
new XAttribute(
|
||||
"Longitud",
|
||||
lote.Longitud.HasValue
|
||||
? lote.Longitud.Value.ToString(CultureInfo.InvariantCulture)
|
||||
: string.Empty),
|
||||
new XAttribute("EsActivo", lote.EsActivo ? 1 : 0))));
|
||||
|
||||
return QueryList<ModeloLoteFraccionamiento>(
|
||||
|
||||
@@ -18,6 +18,44 @@ namespace SIG.Web.AppCode.Repositories.Fraccionamientos
|
||||
{
|
||||
}
|
||||
|
||||
public DbResult<List<CapaGisFraccionamiento>> ListarCapas(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return QueryList<CapaGisFraccionamiento>(
|
||||
"dbo.PA_Fraccionamientos_EtapaGISCapasList",
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
comando => StoredProcedureCommand.AddInput(
|
||||
comando, "@CveFraccionamientoEtapa", cveFraccionamientoEtapa, DbType.Int32));
|
||||
}
|
||||
|
||||
public DbResult<bool> GuardarCapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
CapaGisFraccionamiento capa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return Execute(
|
||||
"dbo.PA_Fraccionamientos_EtapaGISCapasSave",
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
comando =>
|
||||
{
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@CveFraccionamientoEtapa", cveFraccionamientoEtapa, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@NombreCapa", capa.NombreCapa, DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@TipoCapa", capa.TipoCapa, DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@Color", capa.Color, DbType.String);
|
||||
StoredProcedureCommand.AddInput(
|
||||
comando, "@EsVisible", capa.EsVisible, DbType.Boolean);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<ContextoGisFraccionamiento> ObtenerContexto(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
|
||||
@@ -0,0 +1,85 @@
|
||||
using System.Data;
|
||||
using SIG.Web.AppCode.Contracts.Database;
|
||||
using SIG.Web.AppCode.Contracts.Fraccionamientos;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Fraccionamientos;
|
||||
using SIG.Web.AppCode.Repositories.Database;
|
||||
using SIG.Web.AppCode.Utilities;
|
||||
|
||||
namespace SIG.Web.AppCode.Repositories.Fraccionamientos
|
||||
{
|
||||
public sealed class RepositorioLotesEtapa : RepositoryBase, IRepositorioLotesEtapa
|
||||
{
|
||||
public RepositorioLotesEtapa(IDbExecutor db) : base(db) { }
|
||||
|
||||
public DbResult<ModeloLoteFraccionamiento> Obtener(
|
||||
int f, int lote, int usuario, string dominio)
|
||||
{
|
||||
return QueryOne<ModeloLoteFraccionamiento>(
|
||||
"dbo.PA_Fraccionamientos_LoteGet", usuario, dominio,
|
||||
c => {
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamiento", f, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamientoLote", lote, DbType.Int32);
|
||||
});
|
||||
}
|
||||
|
||||
public DbResult<int> CambiarAprobacion(
|
||||
int f, int lote, bool valor, int usuario, string dominio)
|
||||
{
|
||||
return EjecutarEstado("dbo.PA_Fraccionamientos_LoteAprobacionSet",
|
||||
f, lote, "@Aprobado", valor, usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<int> CambiarBloqueo(
|
||||
int f, int lote, bool valor, int usuario, string dominio)
|
||||
{
|
||||
return EjecutarEstado("dbo.PA_Fraccionamientos_LoteBloqueoSet",
|
||||
f, lote, "@Bloqueado", valor, usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<int> CambiarAutorizacionAgua(
|
||||
int f, int lote, bool valor, int usuario, string dominio)
|
||||
{
|
||||
return EjecutarEstado("dbo.PA_Fraccionamientos_LoteAguaAutorizacionSet",
|
||||
f, lote, "@Autorizado", valor, usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<int> CambiarAutorizacionDrenaje(
|
||||
int f, int lote, bool valor, int usuario, string dominio)
|
||||
{
|
||||
return EjecutarEstado("dbo.PA_Fraccionamientos_LoteDrenajeAutorizacionSet",
|
||||
f, lote, "@Autorizado", valor, usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<int> ActualizarInfraestructura(
|
||||
int f, int lote, decimal agua, decimal drenaje,
|
||||
int usuario, string dominio)
|
||||
{
|
||||
return QueryScalarId(
|
||||
"dbo.PA_Fraccionamientos_LoteInfraestructuraUpdate",
|
||||
usuario, dominio,
|
||||
c => {
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamiento", f, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamientoLote", lote, DbType.Int32);
|
||||
var p1 = StoredProcedureCommand.AddInput(
|
||||
c, "@AvanceAguaPotable", agua, DbType.Decimal);
|
||||
p1.Precision = 5; p1.Scale = 2;
|
||||
var p2 = StoredProcedureCommand.AddInput(
|
||||
c, "@AvanceDrenaje", drenaje, DbType.Decimal);
|
||||
p2.Precision = 5; p2.Scale = 2;
|
||||
});
|
||||
}
|
||||
|
||||
private DbResult<int> EjecutarEstado(
|
||||
string sp, int f, int lote, string parametro, bool valor,
|
||||
int usuario, string dominio)
|
||||
{
|
||||
return QueryScalarId(sp, usuario, dominio,
|
||||
c => {
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamiento", f, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, "@CveFraccionamientoLote", lote, DbType.Int32);
|
||||
StoredProcedureCommand.AddInput(c, parametro, valor, DbType.Boolean);
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
925
SIG.Web/App_Code/Services/Clientes/ServicioPortalCliente.cs
Normal file
@@ -0,0 +1,925 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Transactions;
|
||||
using SIG.Web.AppCode.Contracts.Clientes;
|
||||
using SIG.Web.AppCode.Contracts.Documentos;
|
||||
using SIG.Web.AppCode.Contracts.Fraccionamientos;
|
||||
using SIG.Web.AppCode.Contracts.Security;
|
||||
using SIG.Web.AppCode.Contracts.Tramites;
|
||||
using SIG.Web.AppCode.Infrastructure;
|
||||
using SIG.Web.AppCode.Infrastructure.Transactions;
|
||||
using SIG.Web.AppCode.Models.Clientes;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Documentos;
|
||||
using SIG.Web.AppCode.Models.Fraccionamientos;
|
||||
using SIG.Web.AppCode.Models.Tramites;
|
||||
using SIG.Web.AppCode.Session;
|
||||
|
||||
namespace SIG.Web.AppCode.Services.Clientes
|
||||
{
|
||||
public sealed class ServicioPortalCliente : IServicioPortalCliente
|
||||
{
|
||||
private readonly IRepositorioPortalCliente _repositorio;
|
||||
private readonly IServicioFraccionamiento _servicioFraccionamiento;
|
||||
private readonly ITramiteDocumentoService _servicioDocumentos;
|
||||
private readonly ITramiteSolicitudService _servicioTramites;
|
||||
private readonly IAlmacenComprobantesConvenio _almacenComprobantes;
|
||||
private readonly IUserContextProvider _contextoUsuario;
|
||||
|
||||
public ServicioPortalCliente(
|
||||
IRepositorioPortalCliente repositorio,
|
||||
IServicioFraccionamiento servicioFraccionamiento,
|
||||
ITramiteDocumentoService servicioDocumentos,
|
||||
ITramiteSolicitudService servicioTramites,
|
||||
IAlmacenComprobantesConvenio almacenComprobantes,
|
||||
IUserContextProvider contextoUsuario)
|
||||
{
|
||||
_repositorio = repositorio;
|
||||
_servicioFraccionamiento = servicioFraccionamiento;
|
||||
_servicioDocumentos = servicioDocumentos;
|
||||
_servicioTramites = servicioTramites;
|
||||
_almacenComprobantes = almacenComprobantes;
|
||||
_contextoUsuario = contextoUsuario;
|
||||
}
|
||||
|
||||
public DbResult<List<ModeloFilaDesarrollos>> ListarDesarrollos(
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<List<ModeloFilaDesarrollos>>(acceso.UserMessage);
|
||||
}
|
||||
|
||||
return _servicioFraccionamiento.ListarDesarrollos(
|
||||
usuario.CveCliente,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
}
|
||||
|
||||
public DbResult<ModeloFraccionamiento> ObtenerFraccionamiento(
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<ModeloFraccionamiento>(acceso.UserMessage);
|
||||
}
|
||||
|
||||
DbResult<ModeloFraccionamiento> resultado =
|
||||
_servicioFraccionamiento.Obtener(
|
||||
cveFraccionamiento,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!resultado.Success || resultado.Data == null)
|
||||
{
|
||||
return resultado;
|
||||
}
|
||||
|
||||
if (usuario.CveCliente ==1 && resultado.Data.CveCliente != usuario.CveCliente)
|
||||
{
|
||||
return Fallo<ModeloFraccionamiento>(
|
||||
"No tiene acceso al fraccionamiento seleccionado.");
|
||||
}
|
||||
|
||||
return resultado;
|
||||
}
|
||||
|
||||
public DbResult<ResultadoGuardarFraccionamientoConEtapas> GuardarFraccionamientoConEtapa(
|
||||
ModeloFraccionamiento fraccionamiento,
|
||||
ModeloEtapaFraccionamiento etapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<ResultadoGuardarFraccionamientoConEtapas>(acceso.UserMessage);
|
||||
}
|
||||
|
||||
if (fraccionamiento == null)
|
||||
{
|
||||
return Fallo<ResultadoGuardarFraccionamientoConEtapas>("No se recibieron los datos del fraccionamiento.");
|
||||
}
|
||||
|
||||
if (etapa == null)
|
||||
{
|
||||
return Fallo<ResultadoGuardarFraccionamientoConEtapas>("Capture la etapa inicial del fraccionamiento.");
|
||||
}
|
||||
|
||||
fraccionamiento.CveFraccionamiento = 0;
|
||||
fraccionamiento.CveCliente = usuario.CveCliente;
|
||||
fraccionamiento.CveEstatus = 1;
|
||||
fraccionamiento.EsActivo = true;
|
||||
|
||||
etapa.CveFraccionamientoEtapa = 0;
|
||||
etapa.CveCliente = usuario.CveCliente;
|
||||
etapa.CveFraccionamiento = 0;
|
||||
etapa.EsActivo = true;
|
||||
|
||||
return _servicioFraccionamiento.GuardarConEtapas(
|
||||
fraccionamiento,
|
||||
new List<ModeloEtapaFraccionamiento> { etapa },
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
}
|
||||
|
||||
public DbResult<int> GuardarFraccionamiento(
|
||||
ModeloFraccionamiento fraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
if (fraccionamiento == null ||
|
||||
fraccionamiento.CveFraccionamiento <= 0)
|
||||
{
|
||||
return Fallo<int>("Seleccione un fraccionamiento válido.");
|
||||
}
|
||||
|
||||
DbResult<ModeloFraccionamiento> actual =
|
||||
ObtenerFraccionamiento(
|
||||
fraccionamiento.CveFraccionamiento,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!actual.Success || actual.Data == null)
|
||||
{
|
||||
return DbResult<int>.Fail(
|
||||
actual.UserMessage,
|
||||
actual.TechnicalMessage,
|
||||
actual.Exception);
|
||||
}
|
||||
|
||||
actual.Data.Fraccionamiento = fraccionamiento.Fraccionamiento;
|
||||
actual.Data.Ubicacion = fraccionamiento.Ubicacion;
|
||||
actual.Data.Hectareas = fraccionamiento.Hectareas;
|
||||
|
||||
return _servicioFraccionamiento.Guardar(
|
||||
actual.Data,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
}
|
||||
|
||||
|
||||
public DbResult<List<ModeloEtapaFraccionamiento>> ListarEtapas(
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
DbResult<ModeloFraccionamiento> fraccionamiento =
|
||||
ObtenerFraccionamiento(
|
||||
cveFraccionamiento,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!fraccionamiento.Success)
|
||||
{
|
||||
return Fallo<List<ModeloEtapaFraccionamiento>>(
|
||||
fraccionamiento.UserMessage);
|
||||
}
|
||||
|
||||
return _servicioFraccionamiento.ListarEtapas(
|
||||
cveFraccionamiento,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
}
|
||||
|
||||
public DbResult<ModeloEtapaFraccionamiento> ObtenerEtapa(
|
||||
int cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<ModeloEtapaFraccionamiento>(acceso.UserMessage);
|
||||
}
|
||||
|
||||
DbResult<ModeloEtapaFraccionamiento> resultado =
|
||||
_servicioFraccionamiento.ObtenerEtapa(
|
||||
cveFraccionamientoEtapa,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!resultado.Success || resultado.Data == null)
|
||||
{
|
||||
return resultado;
|
||||
}
|
||||
|
||||
if (resultado.Data.CveCliente != usuario.CveCliente)
|
||||
{
|
||||
return Fallo<ModeloEtapaFraccionamiento>(
|
||||
"No tiene acceso a la etapa seleccionada.");
|
||||
}
|
||||
|
||||
return resultado;
|
||||
}
|
||||
|
||||
public DbResult<int> GuardarEtapa(
|
||||
ModeloEtapaFraccionamiento etapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
if (etapa == null || etapa.CveFraccionamiento <= 0)
|
||||
{
|
||||
return Fallo<int>("Seleccione un fraccionamiento válido.");
|
||||
}
|
||||
|
||||
DbResult<ModeloFraccionamiento> fraccionamiento =
|
||||
ObtenerFraccionamiento(
|
||||
etapa.CveFraccionamiento,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!fraccionamiento.Success || fraccionamiento.Data == null)
|
||||
{
|
||||
return DbResult<int>.Fail(
|
||||
fraccionamiento.UserMessage,
|
||||
fraccionamiento.TechnicalMessage,
|
||||
fraccionamiento.Exception);
|
||||
}
|
||||
|
||||
etapa.CveFraccionamientoEtapa = 0;
|
||||
etapa.CveCliente = fraccionamiento.Data.CveCliente;
|
||||
etapa.EsActivo = true;
|
||||
|
||||
return _servicioFraccionamiento.GuardarEtapa(
|
||||
etapa,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
}
|
||||
|
||||
|
||||
public DbResult<List<TramiteClienteListado>> ListarTramites(
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
return ListarTramites(
|
||||
cveFraccionamiento,
|
||||
null,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
}
|
||||
|
||||
public DbResult<List<TramiteClienteListado>> ListarTramites(
|
||||
int cveFraccionamiento,
|
||||
int? cveFraccionamientoEtapa,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<List<TramiteClienteListado>>(acceso.UserMessage);
|
||||
}
|
||||
|
||||
DbResult<ModeloFraccionamiento> fraccionamiento =
|
||||
ObtenerFraccionamiento(
|
||||
cveFraccionamiento,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!fraccionamiento.Success)
|
||||
{
|
||||
return Fallo<List<TramiteClienteListado>>(
|
||||
fraccionamiento.UserMessage);
|
||||
}
|
||||
|
||||
if (cveFraccionamientoEtapa.HasValue)
|
||||
{
|
||||
DbResult<ModeloEtapaFraccionamiento> etapa =
|
||||
ObtenerEtapa(
|
||||
cveFraccionamientoEtapa.Value,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!etapa.Success ||
|
||||
etapa.Data == null ||
|
||||
etapa.Data.CveFraccionamiento != cveFraccionamiento)
|
||||
{
|
||||
return Fallo<List<TramiteClienteListado>>(
|
||||
"La etapa seleccionada no pertenece al fraccionamiento.");
|
||||
}
|
||||
}
|
||||
|
||||
DbResult<List<TramiteSolicitudModel>> solicitudes =
|
||||
_servicioTramites.ListForDevelopment(
|
||||
cveFraccionamiento,
|
||||
cveFraccionamientoEtapa,
|
||||
null,
|
||||
null,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!solicitudes.Success)
|
||||
{
|
||||
return DbResult<List<TramiteClienteListado>>.Fail(
|
||||
solicitudes.UserMessage,
|
||||
solicitudes.TechnicalMessage,
|
||||
solicitudes.Exception);
|
||||
}
|
||||
|
||||
DbResult<List<TramiteDocumentoSolicitudModel>> documentos =
|
||||
_servicioDocumentos.ListarRequisitos(
|
||||
cveFraccionamiento,
|
||||
cveFraccionamientoEtapa,
|
||||
null,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!documentos.Success)
|
||||
{
|
||||
return DbResult<List<TramiteClienteListado>>.Fail(
|
||||
documentos.UserMessage,
|
||||
documentos.TechnicalMessage,
|
||||
documentos.Exception);
|
||||
}
|
||||
|
||||
DbResult<List<PagoPendienteTramiteCliente>> pagos =
|
||||
_repositorio.ListarPagosPendientesTramites(
|
||||
usuario.CveCliente,
|
||||
cveFraccionamiento,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!pagos.Success)
|
||||
{
|
||||
return DbResult<List<TramiteClienteListado>>.Fail(
|
||||
pagos.UserMessage,
|
||||
pagos.TechnicalMessage,
|
||||
pagos.Exception);
|
||||
}
|
||||
|
||||
List<TramiteDocumentoSolicitudModel> documentosActuales =
|
||||
documentos.Data ?? new List<TramiteDocumentoSolicitudModel>();
|
||||
List<PagoPendienteTramiteCliente> pagosActuales =
|
||||
pagos.Data ?? new List<PagoPendienteTramiteCliente>();
|
||||
|
||||
List<TramiteClienteListado> resultado =
|
||||
(solicitudes.Data ?? new List<TramiteSolicitudModel>())
|
||||
.Select(solicitud =>
|
||||
{
|
||||
int documentosPendientes = documentosActuales.Count(documento =>
|
||||
(
|
||||
documento.CveSolicitud == solicitud.CveSolicitud ||
|
||||
(
|
||||
documento.CveSolicitud <= 0 &&
|
||||
documento.CveFraccionamientoEtapa ==
|
||||
solicitud.CveFraccionamientoEtapa &&
|
||||
documento.CveTipoTramite ==
|
||||
solicitud.CveTipoTramite
|
||||
)
|
||||
) &&
|
||||
documento.EsRequerido &&
|
||||
(!documento.TieneArchivo || documento.FechaExpirada));
|
||||
|
||||
int pagosPendientes = pagosActuales.Count(pago =>
|
||||
pago.CveSolicitud == solicitud.CveSolicitud);
|
||||
|
||||
return new TramiteClienteListado
|
||||
{
|
||||
CveSolicitud = solicitud.CveSolicitud,
|
||||
Folio = solicitud.Folio,
|
||||
CveFraccionamiento = solicitud.CveFraccionamiento,
|
||||
CveFraccionamientoEtapa = solicitud.CveFraccionamientoEtapa,
|
||||
Etapa = solicitud.Etapa,
|
||||
CveTipoTramite = solicitud.CveTipoTramite,
|
||||
TipoTramite = solicitud.TipoTramite,
|
||||
CveEstatusSolicitud = solicitud.CveEstatusSolicitud,
|
||||
EstatusSolicitud = solicitud.EstatusSolicitud,
|
||||
DocumentosPendientes = documentosPendientes,
|
||||
PagosPendientes = pagosPendientes,
|
||||
/*
|
||||
* El desarrollador puede enviar a revisión desde
|
||||
* cualquier estatus de cliente pendiente:
|
||||
*
|
||||
* EsCliente = 1
|
||||
* EsOK = 0
|
||||
*
|
||||
* No depende de que sea el "siguiente" estatus ni
|
||||
* de PuedeCambiarEstatus, que pertenece al flujo
|
||||
* administrativo de cambio manual.
|
||||
*/
|
||||
PuedeEnviarRevision =
|
||||
solicitud.EsEstatusCliente &&
|
||||
!solicitud.EsEstatusOk &&
|
||||
documentosPendientes == 0 &&
|
||||
pagosPendientes == 0
|
||||
};
|
||||
})
|
||||
.OrderBy(x => x.Etapa)
|
||||
.ThenBy(x => x.TipoTramite)
|
||||
.ToList();
|
||||
|
||||
return DbResult<List<TramiteClienteListado>>.Ok(resultado);
|
||||
}
|
||||
|
||||
public DbResult<TramiteSolicitudStatusChangeModel> EnviarRevision(
|
||||
int cveSolicitud,
|
||||
int cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
DbResult<List<TramiteClienteListado>> tramites =
|
||||
ListarTramites(
|
||||
cveFraccionamiento,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!tramites.Success)
|
||||
{
|
||||
return DbResult<TramiteSolicitudStatusChangeModel>.Fail(
|
||||
tramites.UserMessage,
|
||||
tramites.TechnicalMessage,
|
||||
tramites.Exception);
|
||||
}
|
||||
|
||||
TramiteClienteListado tramite =
|
||||
(tramites.Data ?? new List<TramiteClienteListado>())
|
||||
.FirstOrDefault(x => x.CveSolicitud == cveSolicitud);
|
||||
|
||||
if (tramite == null)
|
||||
{
|
||||
return Fallo<TramiteSolicitudStatusChangeModel>(
|
||||
"No se encontró el trámite seleccionado.");
|
||||
}
|
||||
|
||||
if (tramite.DocumentosPendientes > 0)
|
||||
{
|
||||
return Fallo<TramiteSolicitudStatusChangeModel>(
|
||||
"Existen documentos requeridos pendientes de cargar o renovar.");
|
||||
}
|
||||
|
||||
if (tramite.PagosPendientes > 0)
|
||||
{
|
||||
return Fallo<TramiteSolicitudStatusChangeModel>(
|
||||
"Existen recibos pendientes de pago.");
|
||||
}
|
||||
|
||||
if (!tramite.PuedeEnviarRevision)
|
||||
{
|
||||
return Fallo<TramiteSolicitudStatusChangeModel>(
|
||||
"El trámite ya no se encuentra en un estatus que pueda enviarse a revisión.");
|
||||
}
|
||||
|
||||
DbResult<ModeloContextoCambioEstatus> contexto =
|
||||
_servicioTramites.ObtenerContextoCambioEstatus(
|
||||
cveSolicitud,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!contexto.Success || contexto.Data == null)
|
||||
{
|
||||
return DbResult<TramiteSolicitudStatusChangeModel>.Fail(
|
||||
contexto.UserMessage,
|
||||
contexto.TechnicalMessage,
|
||||
contexto.Exception);
|
||||
}
|
||||
|
||||
/*
|
||||
* El botón Enviar a revisión NO recorre el flujo de uno en uno.
|
||||
*
|
||||
* Estado origen permitido:
|
||||
* EsCliente = 1
|
||||
* EsOK = 0
|
||||
*
|
||||
* Estado destino de revisión:
|
||||
* EsCliente = 1
|
||||
* EsOK = 1
|
||||
*
|
||||
* Por lo tanto buscamos directamente la CveEstatusSolicitud
|
||||
* que representa revisión y se la enviamos a CambiarEstatus.
|
||||
*/
|
||||
if (!contexto.Data.Solicitud.EsEstatusCliente ||
|
||||
contexto.Data.Solicitud.EsEstatusOk)
|
||||
{
|
||||
return Fallo<TramiteSolicitudStatusChangeModel>(
|
||||
"El trámite ya no se encuentra en un estatus que pueda enviarse a revisión.");
|
||||
}
|
||||
|
||||
TramiteSolicitudEstatusOptionModel estatusRevision =
|
||||
(contexto.Data.Estatus ??
|
||||
new List<TramiteSolicitudEstatusOptionModel>())
|
||||
.FirstOrDefault(estatus =>
|
||||
estatus.EsCliente &&
|
||||
estatus.EsOK);
|
||||
|
||||
if (estatusRevision == null)
|
||||
{
|
||||
return Fallo<TramiteSolicitudStatusChangeModel>(
|
||||
"No se encontró el estatus configurado para enviar a revisión.");
|
||||
}
|
||||
|
||||
if (estatusRevision.CveEstatusSolicitud ==
|
||||
contexto.Data.Solicitud.CveEstatusSolicitud)
|
||||
{
|
||||
return Fallo<TramiteSolicitudStatusChangeModel>(
|
||||
"El trámite ya se encuentra enviado a revisión.");
|
||||
}
|
||||
|
||||
var cambio = new ModeloCambioEstatusTramite
|
||||
{
|
||||
CveSolicitud = cveSolicitud,
|
||||
CveEstatusSolicitudAnterior =
|
||||
contexto.Data.Solicitud.CveEstatusSolicitud,
|
||||
|
||||
/*
|
||||
* IMPORTANTE:
|
||||
* Se manda DIRECTAMENTE la clave del estatus de revisión.
|
||||
* No se usa CveSiguienteEstatus.
|
||||
*/
|
||||
CveEstatusSolicitud =
|
||||
estatusRevision.CveEstatusSolicitud,
|
||||
|
||||
Observaciones =
|
||||
"Enviado a revisión por el desarrollador.",
|
||||
CvesCondicionesMostradas = new List<int>()
|
||||
};
|
||||
|
||||
return _servicioTramites.CambiarEstatus(
|
||||
cambio,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio,
|
||||
false);
|
||||
}
|
||||
|
||||
public DbResult<List<DocumentoClientePortal>> ListarDocumentos(
|
||||
FiltroDocumentosCliente filtro,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<List<DocumentoClientePortal>>(acceso.UserMessage);
|
||||
}
|
||||
|
||||
filtro = filtro ?? new FiltroDocumentosCliente();
|
||||
|
||||
DbResult<List<ModeloFilaDesarrollos>> desarrollos =
|
||||
_servicioFraccionamiento.ListarDesarrollos(
|
||||
usuario.CveCliente,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!desarrollos.Success)
|
||||
{
|
||||
return DbResult<List<DocumentoClientePortal>>.Fail(
|
||||
desarrollos.UserMessage,
|
||||
desarrollos.TechnicalMessage,
|
||||
desarrollos.Exception);
|
||||
}
|
||||
|
||||
var fraccionamientos =
|
||||
(desarrollos.Data ?? new List<ModeloFilaDesarrollos>())
|
||||
.Where(x => x.CveFraccionamiento > 0)
|
||||
.GroupBy(x => x.CveFraccionamiento)
|
||||
.Select(grupo => new
|
||||
{
|
||||
CveFraccionamiento = grupo.Key,
|
||||
Fraccionamiento = grupo.First().Fraccionamiento
|
||||
})
|
||||
.Where(x =>
|
||||
!filtro.CveFraccionamiento.HasValue ||
|
||||
x.CveFraccionamiento == filtro.CveFraccionamiento.Value)
|
||||
.OrderBy(x => x.Fraccionamiento)
|
||||
.ToList();
|
||||
|
||||
var resultado = new List<DocumentoClientePortal>();
|
||||
|
||||
foreach (var fraccionamiento in fraccionamientos)
|
||||
{
|
||||
DbResult<List<TramiteDocumentoSolicitudModel>> documentos =
|
||||
_servicioDocumentos.ListarRequisitos(
|
||||
fraccionamiento.CveFraccionamiento,
|
||||
filtro.CveFraccionamientoEtapa,
|
||||
null,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!documentos.Success)
|
||||
{
|
||||
return DbResult<List<DocumentoClientePortal>>.Fail(
|
||||
documentos.UserMessage,
|
||||
documentos.TechnicalMessage,
|
||||
documentos.Exception);
|
||||
}
|
||||
|
||||
foreach (TramiteDocumentoSolicitudModel documento in
|
||||
documentos.Data ?? new List<TramiteDocumentoSolicitudModel>())
|
||||
{
|
||||
string agrupacion = documento.Agrupacion;
|
||||
|
||||
if (!string.IsNullOrWhiteSpace(filtro.Agrupacion) &&
|
||||
!string.Equals(
|
||||
filtro.Agrupacion,
|
||||
agrupacion,
|
||||
StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
resultado.Add(new DocumentoClientePortal
|
||||
{
|
||||
CveDocumentoSolicitud = documento.CveDocumentoSolicitud,
|
||||
CveSolicitud = documento.CveSolicitud,
|
||||
CveCliente = documento.CveCliente,
|
||||
CveFraccionamiento = documento.CveFraccionamiento,
|
||||
Fraccionamiento = fraccionamiento.Fraccionamiento,
|
||||
CveFraccionamientoEtapa = documento.CveFraccionamientoEtapa,
|
||||
Etapa = documento.Etapa,
|
||||
CveTipoTramite = documento.CveTipoTramite,
|
||||
TipoTramite = documento.TipoTramite,
|
||||
CveTipoDocumento = documento.CveTipoDocumento,
|
||||
TipoDocumento = documento.TipoDocumento,
|
||||
NombreArchivo = documento.NombreArchivo,
|
||||
Nota = documento.Nota,
|
||||
EsAprobado = documento.EsAprobado,
|
||||
FechaDocumento = documento.FechaDocumento,
|
||||
FechaVencimiento = documento.FechaVencimiento,
|
||||
TieneArchivo = documento.TieneArchivo,
|
||||
EsCliente = documento.EsCliente,
|
||||
PuedeActualizarArchivo = documento.PuedeActualizarArchivo,
|
||||
EsRequerido = documento.EsRequerido,
|
||||
TieneVigencia = documento.TieneVigencia,
|
||||
FechaExpirada = documento.FechaExpirada,
|
||||
EstadoDocumento = documento.EstadoDocumento,
|
||||
Agrupacion = agrupacion
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
return DbResult<List<DocumentoClientePortal>>.Ok(
|
||||
resultado
|
||||
.OrderBy(x => x.Fraccionamiento)
|
||||
.ThenBy(x => x.Etapa)
|
||||
.ThenBy(x => x.Agrupacion)
|
||||
.ThenBy(x => x.TipoDocumento)
|
||||
.ToList());
|
||||
}
|
||||
|
||||
public DbResult<List<PagoConvenioClienteFila>> ListarPagos(
|
||||
FiltroPagosCliente filtro,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<List<PagoConvenioClienteFila>>(acceso.UserMessage);
|
||||
}
|
||||
|
||||
filtro = filtro ?? new FiltroPagosCliente();
|
||||
|
||||
return _repositorio.ListarPagos(
|
||||
usuario.CveCliente,
|
||||
filtro.CveFraccionamiento,
|
||||
filtro.CveFraccionamientoEtapa,
|
||||
filtro.Agrupacion,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
}
|
||||
|
||||
public DbResult<List<ReciboConvenioDisponibleCliente>> ListarRecibosDisponibles(
|
||||
int? cveFraccionamiento,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<List<ReciboConvenioDisponibleCliente>>(
|
||||
acceso.UserMessage);
|
||||
}
|
||||
|
||||
return _repositorio.ListarRecibosDisponibles(
|
||||
usuario.CveCliente,
|
||||
cveFraccionamiento,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
}
|
||||
|
||||
public DbResult<int> RegistrarPago(
|
||||
SolicitudPagoConvenioCliente pago,
|
||||
Stream contenido,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<int>(acceso.UserMessage);
|
||||
}
|
||||
|
||||
if (pago == null)
|
||||
{
|
||||
return Fallo<int>("Capture los datos del pago.");
|
||||
}
|
||||
|
||||
pago.CveCliente = usuario.CveCliente;
|
||||
pago.Referencia = RecortarONulo(pago.Referencia, 200);
|
||||
pago.Banco = RecortarONulo(pago.Banco, 200);
|
||||
pago.NumeroOperacion = RecortarONulo(pago.NumeroOperacion, 200);
|
||||
pago.Observaciones = RecortarONulo(pago.Observaciones, 1000);
|
||||
|
||||
if (pago.Importe <= 0m)
|
||||
{
|
||||
return Fallo<int>("Capture un importe de pago mayor a cero.");
|
||||
}
|
||||
|
||||
if (pago.Aplicaciones == null || pago.Aplicaciones.Count == 0)
|
||||
{
|
||||
return Fallo<int>("Vincule al menos un recibo al comprobante.");
|
||||
}
|
||||
|
||||
if (pago.Aplicaciones.Any(x =>
|
||||
x.CveConvenioRecibo <= 0 ||
|
||||
x.ImporteAplicado <= 0m))
|
||||
{
|
||||
return Fallo<int>(
|
||||
"Revise los recibos y los importes aplicados.");
|
||||
}
|
||||
|
||||
if (pago.Aplicaciones
|
||||
.GroupBy(x => x.CveConvenioRecibo)
|
||||
.Any(grupo => grupo.Count() > 1))
|
||||
{
|
||||
return Fallo<int>(
|
||||
"El mismo recibo no puede agregarse dos veces al pago.");
|
||||
}
|
||||
|
||||
decimal totalAplicado = pago.Aplicaciones.Sum(
|
||||
x => x.ImporteAplicado);
|
||||
|
||||
if (totalAplicado > pago.Importe)
|
||||
{
|
||||
return Fallo<int>(
|
||||
"El importe aplicado a recibos no puede ser mayor al importe del pago.");
|
||||
}
|
||||
|
||||
bool archivoGuardado = false;
|
||||
|
||||
try
|
||||
{
|
||||
_almacenComprobantes.Guardar(pago, contenido);
|
||||
archivoGuardado = true;
|
||||
|
||||
using (var transaccion = new TransactionLogic(
|
||||
IsolationLevel.Serializable))
|
||||
{
|
||||
DbResult<int> resultado = _repositorio.AgregarPago(
|
||||
pago,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!resultado.Success)
|
||||
{
|
||||
_almacenComprobantes.Eliminar(
|
||||
pago.CveCliente,
|
||||
pago.NombreFisico);
|
||||
archivoGuardado = false;
|
||||
return resultado;
|
||||
}
|
||||
|
||||
transaccion.Commit();
|
||||
return resultado;
|
||||
}
|
||||
}
|
||||
catch (ControlledApplicationException excepcion)
|
||||
{
|
||||
if (archivoGuardado)
|
||||
{
|
||||
_almacenComprobantes.Eliminar(
|
||||
pago.CveCliente,
|
||||
pago.NombreFisico);
|
||||
}
|
||||
|
||||
return DbResult<int>.Fail(
|
||||
excepcion.Message,
|
||||
excepcion.Message,
|
||||
excepcion);
|
||||
}
|
||||
catch
|
||||
{
|
||||
if (archivoGuardado)
|
||||
{
|
||||
_almacenComprobantes.Eliminar(
|
||||
pago.CveCliente,
|
||||
pago.NombreFisico);
|
||||
}
|
||||
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public DbResult<ArchivoPagoConvenioCliente> ObtenerArchivoPago(
|
||||
int cveConvenioPago,
|
||||
int cveUsuarioEjecuta,
|
||||
string nombreDominio)
|
||||
{
|
||||
UserSessionModel usuario;
|
||||
DbResult<bool> acceso = ValidarCliente(
|
||||
cveUsuarioEjecuta,
|
||||
out usuario);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return Fallo<ArchivoPagoConvenioCliente>(acceso.UserMessage);
|
||||
}
|
||||
|
||||
DbResult<ArchivoPagoConvenioCliente> resultado =
|
||||
_repositorio.ObtenerArchivoPago(
|
||||
cveConvenioPago,
|
||||
usuario.CveCliente,
|
||||
cveUsuarioEjecuta,
|
||||
nombreDominio);
|
||||
|
||||
if (!resultado.Success || resultado.Data == null)
|
||||
{
|
||||
return resultado;
|
||||
}
|
||||
|
||||
resultado.Data.RutaFisica = _almacenComprobantes.Resolver(
|
||||
resultado.Data.CveCliente,
|
||||
resultado.Data.NombreFisico);
|
||||
|
||||
return resultado;
|
||||
}
|
||||
|
||||
private DbResult<bool> ValidarCliente(
|
||||
int cveUsuarioEjecuta,
|
||||
out UserSessionModel usuario)
|
||||
{
|
||||
usuario = _contextoUsuario.GetCurrentUser();
|
||||
|
||||
|
||||
return DbResult<bool>.Ok(true);
|
||||
}
|
||||
|
||||
private static string RecortarONulo(
|
||||
string texto,
|
||||
int longitudMaxima)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(texto))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
string valor = texto.Trim();
|
||||
|
||||
return valor.Length <= longitudMaxima
|
||||
? valor
|
||||
: valor.Substring(0, longitudMaxima);
|
||||
}
|
||||
|
||||
private static DbResult<T> Fallo<T>(string mensaje)
|
||||
{
|
||||
return DbResult<T>.Fail(
|
||||
mensaje,
|
||||
mensaje,
|
||||
null);
|
||||
}
|
||||
}
|
||||
}
|
||||
282
SIG.Web/App_Code/Services/Convenios/ServicioConvenios.cs
Normal file
@@ -0,0 +1,282 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Transactions;
|
||||
using SIG.Web.AppCode.Contracts.Convenios;
|
||||
using SIG.Web.AppCode.Contracts.Security;
|
||||
using SIG.Web.AppCode.Infrastructure.Transactions;
|
||||
using SIG.Web.AppCode.Models.Common;
|
||||
using SIG.Web.AppCode.Models.Convenios;
|
||||
|
||||
namespace SIG.Web.AppCode.Services.Convenios
|
||||
{
|
||||
public sealed class ServicioConvenios : IServicioConvenios
|
||||
{
|
||||
private readonly IRepositorioConvenios _repositorio;
|
||||
private readonly IUserContextProvider _usuario;
|
||||
|
||||
public ServicioConvenios(
|
||||
IRepositorioConvenios repositorio,
|
||||
IUserContextProvider usuario)
|
||||
{
|
||||
_repositorio = repositorio;
|
||||
_usuario = usuario;
|
||||
}
|
||||
|
||||
public DbResult<List<ConvenioListado>> Listar(
|
||||
FiltroConvenios filtro,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
filtro = filtro ?? new FiltroConvenios();
|
||||
|
||||
var actual = _usuario.GetCurrentUser();
|
||||
|
||||
if (actual != null && actual.EsDesarrollador)
|
||||
{
|
||||
filtro.CveCliente = actual.CveCliente;
|
||||
}
|
||||
|
||||
return _repositorio.Listar(filtro, usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<ConvenioDetalleCompleto> Obtener(
|
||||
int cveConvenio,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
var resultado = _repositorio.Obtener(
|
||||
cveConvenio,
|
||||
usuario,
|
||||
dominio);
|
||||
|
||||
if (!resultado.Success ||
|
||||
resultado.Data == null ||
|
||||
resultado.Data.Encabezado == null)
|
||||
{
|
||||
return resultado;
|
||||
}
|
||||
|
||||
var actual = _usuario.GetCurrentUser();
|
||||
|
||||
if (actual != null &&
|
||||
actual.EsDesarrollador &&
|
||||
resultado.Data.Encabezado.CveCliente != actual.CveCliente)
|
||||
{
|
||||
return DbResult<ConvenioDetalleCompleto>.Fail(
|
||||
"No tiene acceso al convenio solicitado.",
|
||||
"Convenio fuera del cliente asignado.",
|
||||
null);
|
||||
}
|
||||
|
||||
DbResult<ConvenioLotesConvenio> lotes =
|
||||
_repositorio.ObtenerLotesConvenio(
|
||||
cveConvenio,
|
||||
usuario,
|
||||
dominio);
|
||||
|
||||
if (!lotes.Success)
|
||||
{
|
||||
return DbResult<ConvenioDetalleCompleto>.Fail(
|
||||
lotes.UserMessage,
|
||||
lotes.TechnicalMessage,
|
||||
lotes.Exception);
|
||||
}
|
||||
|
||||
resultado.Data.Encabezado.LotesConvenio =
|
||||
lotes.Data == null ? 0 : lotes.Data.LotesConvenio;
|
||||
|
||||
return resultado;
|
||||
}
|
||||
|
||||
public DbResult<List<ConvenioConceptoCatalogo>> ListarConceptos(
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
return _repositorio.ListarConceptos(usuario, dominio);
|
||||
}
|
||||
|
||||
public DbResult<int> Agregar(
|
||||
SolicitudAltaConvenio solicitud,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
var actual = _usuario.GetCurrentUser();
|
||||
|
||||
if (actual != null && actual.EsDesarrollador)
|
||||
{
|
||||
return DbResult<int>.Fail(
|
||||
"La captura de convenios está disponible para usuarios administrativos.",
|
||||
"Un usuario desarrollador intentó registrar un convenio.",
|
||||
null);
|
||||
}
|
||||
|
||||
string mensajeValidacion = ValidarSolicitud(solicitud);
|
||||
|
||||
if (!string.IsNullOrWhiteSpace(mensajeValidacion))
|
||||
{
|
||||
return DbResult<int>.Fail(
|
||||
mensajeValidacion,
|
||||
mensajeValidacion,
|
||||
null);
|
||||
}
|
||||
|
||||
using (var transaccion = new TransactionLogic(
|
||||
IsolationLevel.Serializable))
|
||||
{
|
||||
var resultado = _repositorio.Agregar(
|
||||
solicitud,
|
||||
usuario,
|
||||
dominio);
|
||||
|
||||
if (!resultado.Success)
|
||||
{
|
||||
return resultado;
|
||||
}
|
||||
|
||||
DbResult<bool> lotes = _repositorio.GuardarLotesConvenio(
|
||||
resultado.Data,
|
||||
solicitud.LotesConvenio,
|
||||
usuario,
|
||||
dominio);
|
||||
|
||||
if (!lotes.Success)
|
||||
{
|
||||
return DbResult<int>.Fail(
|
||||
lotes.UserMessage,
|
||||
lotes.TechnicalMessage,
|
||||
lotes.Exception);
|
||||
}
|
||||
|
||||
transaccion.Commit();
|
||||
return resultado;
|
||||
}
|
||||
}
|
||||
|
||||
public DbResult<bool> Eliminar(
|
||||
int cveConvenio,
|
||||
int usuario,
|
||||
string dominio)
|
||||
{
|
||||
var acceso = Obtener(cveConvenio, usuario, dominio);
|
||||
|
||||
if (!acceso.Success)
|
||||
{
|
||||
return DbResult<bool>.Fail(
|
||||
acceso.UserMessage,
|
||||
acceso.TechnicalMessage,
|
||||
acceso.Exception);
|
||||
}
|
||||
|
||||
var actual = _usuario.GetCurrentUser();
|
||||
|
||||
if (actual != null && actual.EsDesarrollador)
|
||||
{
|
||||
return DbResult<bool>.Fail(
|
||||
"No tiene permiso para eliminar convenios.",
|
||||
"El rol desarrollador intentó eliminar un convenio.",
|
||||
null);
|
||||
}
|
||||
|
||||
using (var transaccion = new TransactionLogic(
|
||||
IsolationLevel.Serializable))
|
||||
{
|
||||
var resultado = _repositorio.Eliminar(
|
||||
cveConvenio,
|
||||
usuario,
|
||||
dominio);
|
||||
|
||||
if (resultado.Success)
|
||||
{
|
||||
transaccion.Commit();
|
||||
}
|
||||
|
||||
return resultado;
|
||||
}
|
||||
}
|
||||
|
||||
private static string ValidarSolicitud(
|
||||
SolicitudAltaConvenio solicitud)
|
||||
{
|
||||
if (solicitud == null)
|
||||
{
|
||||
return "Capture los datos del convenio.";
|
||||
}
|
||||
|
||||
if (solicitud.CveCliente <= 0)
|
||||
{
|
||||
return "Seleccione el desarrollador del convenio.";
|
||||
}
|
||||
|
||||
if (solicitud.CveTipoTramite <= 0)
|
||||
{
|
||||
return "Seleccione el tipo de trámite del convenio.";
|
||||
}
|
||||
|
||||
if (solicitud.CveFraccionamientoEtapa <= 0)
|
||||
{
|
||||
return "Seleccione el fraccionamiento y etapa del convenio.";
|
||||
}
|
||||
|
||||
if (string.IsNullOrWhiteSpace(solicitud.NumeroConvenio))
|
||||
{
|
||||
return "Capture el número de convenio.";
|
||||
}
|
||||
|
||||
if (solicitud.ViviendasEnConvenio < 0)
|
||||
{
|
||||
return "La cantidad de viviendas en convenio no es válida.";
|
||||
}
|
||||
|
||||
if (solicitud.LotesConvenio < 0)
|
||||
{
|
||||
return "La cantidad de lotes del convenio no es válida.";
|
||||
}
|
||||
|
||||
if (solicitud.Conceptos == null || solicitud.Conceptos.Count == 0)
|
||||
{
|
||||
return "Agregue al menos un concepto al convenio.";
|
||||
}
|
||||
|
||||
foreach (var concepto in solicitud.Conceptos)
|
||||
{
|
||||
if (concepto.CveConvenioConcepto <= 0 || concepto.Importe <= 0)
|
||||
{
|
||||
return "Revise los conceptos e importes del convenio.";
|
||||
}
|
||||
|
||||
if (string.IsNullOrWhiteSpace(concepto.Tipo))
|
||||
{
|
||||
return "Seleccione el tipo de moneda de cada concepto.";
|
||||
}
|
||||
|
||||
if (concepto.NumeroPagos < 1 || concepto.NumeroPagos > 12)
|
||||
{
|
||||
return "Cada concepto debe tener entre 1 y 12 parcialidades.";
|
||||
}
|
||||
|
||||
var parcialidades = concepto.Parcialidades ??
|
||||
new List<ConvenioReciboCaptura>();
|
||||
|
||||
if (parcialidades.Count != concepto.NumeroPagos)
|
||||
{
|
||||
return "La cantidad de parcialidades debe coincidir con el número de pagos del concepto.";
|
||||
}
|
||||
|
||||
if (parcialidades.Any(x => x.Importe <= 0))
|
||||
{
|
||||
return "Todas las parcialidades deben tener un importe mayor a cero.";
|
||||
}
|
||||
|
||||
decimal suma = parcialidades.Sum(x => x.Importe);
|
||||
|
||||
if (suma != concepto.Importe)
|
||||
{
|
||||
return "La suma de las parcialidades debe coincidir con el importe del concepto.";
|
||||
}
|
||||
}
|
||||
|
||||
return string.Empty;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,199 @@
|
||||
using System;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Web.Hosting;
|
||||
using SIG.Web.AppCode.Contracts.Documentos;
|
||||
using SIG.Web.AppCode.Infrastructure;
|
||||
using SIG.Web.AppCode.Models.Clientes;
|
||||
|
||||
namespace SIG.Web.AppCode.Services.Documentos
|
||||
{
|
||||
public sealed class AlmacenComprobantesConvenio
|
||||
: IAlmacenComprobantesConvenio
|
||||
{
|
||||
private const int TamanoMaximo = 5 * 1024 * 1024;
|
||||
|
||||
public void Guardar(
|
||||
SolicitudPagoConvenioCliente pago,
|
||||
Stream contenido)
|
||||
{
|
||||
if (pago == null)
|
||||
{
|
||||
throw new ControlledApplicationException(
|
||||
"Capture el comprobante del pago.");
|
||||
}
|
||||
|
||||
string extension = Path.GetExtension(
|
||||
pago.NombreArchivo ?? string.Empty).ToLowerInvariant();
|
||||
string tipoContenido = ObtenerTipoContenido(extension);
|
||||
|
||||
if (tipoContenido == null ||
|
||||
contenido == null ||
|
||||
!contenido.CanRead ||
|
||||
pago.TamanoBytes <= 0 ||
|
||||
pago.TamanoBytes > TamanoMaximo ||
|
||||
!string.Equals(
|
||||
tipoContenido,
|
||||
pago.TipoContenido,
|
||||
StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
throw new ControlledApplicationException(
|
||||
"Seleccione un comprobante PDF, JPG o PNG de hasta 5 MB.");
|
||||
}
|
||||
|
||||
byte[] archivo;
|
||||
|
||||
using (var memoria = new MemoryStream())
|
||||
{
|
||||
var bloque = new byte[81920];
|
||||
int leidos;
|
||||
|
||||
while ((leidos = contenido.Read(
|
||||
bloque,
|
||||
0,
|
||||
bloque.Length)) > 0)
|
||||
{
|
||||
if (memoria.Length + leidos > TamanoMaximo)
|
||||
{
|
||||
throw new ControlledApplicationException(
|
||||
"El comprobante excede 5 MB.");
|
||||
}
|
||||
|
||||
memoria.Write(bloque, 0, leidos);
|
||||
}
|
||||
|
||||
archivo = memoria.ToArray();
|
||||
}
|
||||
|
||||
if (archivo.Length != pago.TamanoBytes ||
|
||||
archivo.Length < 12 ||
|
||||
!SIG.Web.AppCode.Services.Visitas.AlmacenDocumentosVisita
|
||||
.FirmaValida(extension, archivo, 12))
|
||||
{
|
||||
throw new ControlledApplicationException(
|
||||
"El contenido del comprobante no corresponde al formato indicado.");
|
||||
}
|
||||
|
||||
pago.NombreArchivo = Path.GetFileName(pago.NombreArchivo);
|
||||
|
||||
if (string.IsNullOrWhiteSpace(pago.NombreArchivo) ||
|
||||
pago.NombreArchivo.Length > 255)
|
||||
{
|
||||
throw new ControlledApplicationException(
|
||||
"El nombre del comprobante no es válido.");
|
||||
}
|
||||
|
||||
pago.NombreFisico = Guid.NewGuid().ToString("N") + extension;
|
||||
pago.TipoContenido = tipoContenido;
|
||||
|
||||
string raizDocumentos = HostingEnvironment.MapPath("~/Documentos/");
|
||||
|
||||
if (string.IsNullOrWhiteSpace(raizDocumentos))
|
||||
{
|
||||
throw new ControlledApplicationException(
|
||||
"No fue posible resolver la carpeta de documentos.");
|
||||
}
|
||||
|
||||
Directory.CreateDirectory(raizDocumentos);
|
||||
Directory.CreateDirectory(
|
||||
Path.Combine(raizDocumentos, "Generales"));
|
||||
Directory.CreateDirectory(
|
||||
Path.Combine(raizDocumentos, "Clientes"));
|
||||
|
||||
string ruta = Resolver(
|
||||
pago.CveCliente,
|
||||
pago.NombreFisico);
|
||||
|
||||
Directory.CreateDirectory(Path.GetDirectoryName(ruta));
|
||||
|
||||
try
|
||||
{
|
||||
using (var destino = new FileStream(
|
||||
ruta,
|
||||
FileMode.CreateNew,
|
||||
FileAccess.Write,
|
||||
FileShare.None))
|
||||
{
|
||||
destino.Write(archivo, 0, archivo.Length);
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
Eliminar(pago.CveCliente, pago.NombreFisico);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
public string Resolver(
|
||||
int cveCliente,
|
||||
string nombreFisico)
|
||||
{
|
||||
Guid identificador;
|
||||
|
||||
if (cveCliente <= 0 ||
|
||||
string.IsNullOrWhiteSpace(nombreFisico) ||
|
||||
Path.GetFileName(nombreFisico) != nombreFisico ||
|
||||
!Guid.TryParseExact(
|
||||
Path.GetFileNameWithoutExtension(nombreFisico),
|
||||
"N",
|
||||
out identificador))
|
||||
{
|
||||
throw new ControlledApplicationException(
|
||||
"El comprobante no está disponible.");
|
||||
}
|
||||
|
||||
string raizClientes = HostingEnvironment.MapPath(
|
||||
"~/Documentos/Clientes/");
|
||||
|
||||
if (string.IsNullOrWhiteSpace(raizClientes))
|
||||
{
|
||||
throw new ControlledApplicationException(
|
||||
"El comprobante no está disponible.");
|
||||
}
|
||||
|
||||
return Path.Combine(
|
||||
raizClientes,
|
||||
cveCliente.ToString(CultureInfo.InvariantCulture),
|
||||
"Convenios",
|
||||
"Pagos",
|
||||
nombreFisico);
|
||||
}
|
||||
|
||||
public void Eliminar(
|
||||
int cveCliente,
|
||||
string nombreFisico)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(nombreFisico))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
string ruta = Resolver(cveCliente, nombreFisico);
|
||||
|
||||
if (File.Exists(ruta))
|
||||
{
|
||||
File.Delete(ruta);
|
||||
}
|
||||
}
|
||||
|
||||
private static string ObtenerTipoContenido(string extension)
|
||||
{
|
||||
if (extension == ".pdf")
|
||||
{
|
||||
return "application/pdf";
|
||||
}
|
||||
|
||||
if (extension == ".png")
|
||||
{
|
||||
return "image/png";
|
||||
}
|
||||
|
||||
if (extension == ".jpg" || extension == ".jpeg")
|
||||
{
|
||||
return "image/jpeg";
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||