diff --git a/PROYECTO/addir/adprmt001.4gl b/PROYECTO/addir/adprmt001.4gl
index be593d8..b1adf9f 100644
--- a/PROYECTO/addir/adprmt001.4gl
+++ b/PROYECTO/addir/adprmt001.4gl
@@ -55,7 +55,8 @@ FUNCTION adpcad001()
{WHENEVER ERROR CONTINUE}
## CAPTURA LOS DATOS QUE VA A CONTENER EL REGISTRO
- INPUT BY NAME depto.* #,m_estado_a,m_estado_m
+ INPUT BY NAME depto.departamento, depto.nom_dpto, depto.status_t, depto.us_crea,
+ depto.fech_crea, depto.us_mod, depto.fech_mod #,m_estado_a,m_estado_m
## VERIFICA QUE EL CODIGO NO EXISTA EN EL CATALOGO DE DEPARTAMENTO. SI EXISTE,
## ENTONCES DESPLEGA LOS DATOS DEL REGISTRO EXISTENTE.
@@ -77,7 +78,8 @@ FUNCTION adpcad001()
NEXT FIELD departamento
END IF
- DISPLAY BY NAME depto.*
+ DISPLAY BY NAME depto.departamento, depto.nom_dpto, depto.status_t, depto.us_crea,
+ depto.fech_crea, depto.us_mod, depto.fech_mod
LET numero_msg = 12
CALL msg(numero_msg)
LET depto.nom_dpto = NULL
@@ -113,10 +115,12 @@ FUNCTION adpcad001()
CALL msg(numero_msg)
NEXT FIELD nom_dpto
ELSE
- INSERT INTO adtb00001 VALUES (depto.departamento,depto.nom_dpto,
+ INSERT INTO adtb00001 (departamento,nom_dpto,status_t,us_crea,fech_crea,us_mod,fech_mod)
+ VALUES (depto.departamento,depto.nom_dpto,
null, SUSER_SNAME (), GETDATE (), null, null)
- INSERT INTO adtb00029 VALUES (depto.departamento,m_estado_a,m_estado_m,
+ INSERT INTO adtb00029 (departamento,estado_a,estado_m,depto_ant,estatus_t,us_crea,fech_crea,us_mod,fech_mod)
+ VALUES (depto.departamento,m_estado_a,m_estado_m,
depto.departamento,null,SUSER_SNAME(), GETDATE (),null,null)
LET m_depto = depto.departamento
@@ -159,7 +163,7 @@ FUNCTION adpcmf001()
RETURN
END IF
- LET SELEC = " SELECT UNIQUE * FROM adtb00001 where ",
+ LET SELEC = " SELECT DISTINCT * FROM adtb00001 where ",
" status_t is null and ",
criterio clipped,
" ORDER BY 1"
@@ -246,9 +250,7 @@ FUNCTION adpcmf001()
END IF
## SE SELECCIONAN LOS CAMPOS QUE SON MODIFICABLES
- INPUT BY NAME depto.nom_dpto,
- m_estado_a,
- m_estado_m WITHOUT DEFAULTS
+ INPUT BY NAME depto.nom_dpto WITHOUT DEFAULTS
AFTER FIELD nom_dpto
IF depto.nom_dpto IS NULL THEN
@@ -283,9 +285,7 @@ FUNCTION adpcmf001()
UPDATE chequeo SET nom_dpto = depto.nom_dpto
WHERE departamento = depto.departamento
- UPDATE adtb00029 SET estado_a = m_estado_a,
- estado_m = m_estado_m,
- us_mod = SUSER_NAME(),
+ UPDATE adtb00029 SET us_mod = SUSER_NAME(),
fech_mod = GETDATE()
WHERE departamento = depto.departamento
diff --git a/PROYECTO/mbsERP.4pw b/PROYECTO/mbsERP.4pw
index 0062bf5..3e7f0ac 100644
--- a/PROYECTO/mbsERP.4pw
+++ b/PROYECTO/mbsERP.4pw
@@ -754,8 +754,15 @@
+
-
+
+
+
+
+
+
+