Registra noprrp041 (Reporte de Horas Extras) y corrige bugs

- Registra nofmrp041.4fd y la aplicacion noprrp041 en el subgrupo NOMINA.
- nofmrp041.4fd: el del repo no era el de este programa; se usa el de 3.20
  (fecha_inicial, fecha_final, cod_sup, num_emp) con format dd/mm/yyyy.
- noprrp041.4gl: el JOIN comparaba notb00028.supervisor (texto
  '(cod) NOMBRE') con adtb00003.num_emp -> error 245; ahora une por
  notb00028.num_emp. El filtro Empleado filtra b.num_emp. Fechas del SQL
  en yyyymmdd con fecha_final+1 (sin BETWEEN).
Verificado contra la BD .250 (dic-2019: 3,552 horas / 544,076.97).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
Abel López
2026-10-16 15:39:35 -04:00
co-authored by Claude Sonnet 5.5
parent 79a4a4530c
commit fc5a23132d
3 changed files with 22 additions and 12 deletions
+13 -9
View File
@@ -1,20 +1,24 @@
<?xml version="1.0" encoding="UTF-8" ?>
<ManagedForm fileVersion="31400" gstVersion="3140a" name="ManagedForm" uid="{4cf2aa58-ffb3-40ad-8821-bc58edfe0d03}">
<ManagedForm fileVersion="31400" gstVersion="31408" name="ManagedForm" uid="{4cf2aa58-ffb3-40ad-8821-bc58edfe0d03}">
<AGSettings>
<DynamicProperties version="2"/>
</AGSettings>
<Record additionalTables="" joinLeft="" joinOperator="" joinRight="" name="Undefined" order="" uid="{14657cfd-6ea9-484d-85b5-36c7f2503c70}" where="">
<RecordField colName="" fieldIdRef="1" name="fecha_inicial" sqlTabName="" table_alias_name="" uid="{ea62721d-1145-41ce-8d25-da746f2aef2c}"/>
<RecordField colName="" fieldIdRef="2" name="fecha_final" sqlTabName="" table_alias_name="" uid="{53fc6932-3358-481a-89da-8d1725963d21}"/>
<RecordField colName="" fieldIdRef="4" name="cod_sup" sqlTabName="" table_alias_name="" uid="{743b47a0-0a5f-44ed-a6b8-85748e888f94}"/>
<RecordField colName="" fieldIdRef="6" name="num_emp" sqlTabName="" table_alias_name="" uid="{437cc479-28ae-4447-996d-ff226613accb}"/>
<RecordField fieldIdRef="1" name="num_nomi" uid="{e896a050-89b9-484e-a851-bcfbbf17dfea}"/>
<RecordField fieldIdRef="2" name="nom_emp" uid="{ee09c82c-1e71-4b43-8ae1-6f5059b5fcfb}"/>
</Record>
<Form gridHeight="11" gridWidth="46" name="Form" text="Form">
<Form gridHeight="8" gridWidth="38" name="Form" text="Form">
<Grid gridHeight="6" gridWidth="34" name="Grid1" posX="2" posY="1">
<Label gridHeight="1" gridWidth="10" name="Label1" posX="2" posY="2" text="No. Nómina"/>
<Edit fieldId="1" gridHeight="1" gridWidth="5" name="num_nomi" posX="13" posY="2" tabIndex="-1" title="edit1" widget="Edit"/>
<Label gridHeight="1" gridWidth="10" name="Label4" posX="2" posY="3" text="Empleado"/>
<Edit aggregateColName="" aggregateName="" aggregateTableAliasName="" aggregateTableName="" colName="" fieldId="6" gridHeight="1" gridWidth="5" name="num_emp" posX="13" posY="3" sqlTabName="" tabIndex="1" table_alias_name="" title="Edit1" widget="Edit"/>
<Edit fieldId="2" gridHeight="1" gridWidth="14" name="nom_emp" noEntry="true" posX="19" posY="3" scroll="true" tabIndex="-1" title="edit1" widget="Edit"/>
<Label gridHeight="1" gridWidth="10" name="Label1" posX="3" posY="1" text="Fecha Inicial"/>
<DateEdit aggregateColName="" aggregateName="" aggregateTableAliasName="" aggregateTableName="" colName="" fieldId="1" format="dd/mm/yyyy" gridHeight="1" gridWidth="12" name="fecha_inicial" posX="16" posY="1" sqlTabName="" tabIndex="1" table_alias_name="" title="DateEdit1" widget="DateEdit"/>
<Label gridHeight="1" gridWidth="10" name="Label2" posX="3" posY="2" text="Fecha Final"/>
<DateEdit aggregateColName="" aggregateName="" aggregateTableAliasName="" aggregateTableName="" colName="" fieldId="2" format="dd/mm/yyyy" gridHeight="1" gridWidth="12" name="fecha_final" posX="16" posY="2" sqlTabName="" tabIndex="2" table_alias_name="" title="DateEdit1" widget="DateEdit"/>
<Label gridHeight="1" gridWidth="10" name="Label3" posX="3" posY="3" text="Supervisor"/>
<Edit aggregateColName="" aggregateName="" aggregateTableAliasName="" aggregateTableName="" colName="" fieldId="4" gridHeight="1" gridWidth="6" name="cod_sup" posX="16" posY="3" sqlTabName="" tabIndex="3" table_alias_name="" title="Edit1" widget="Edit"/>
<Label gridHeight="1" gridWidth="10" name="Label4" posX="3" posY="4" text="Empleado"/>
<Edit aggregateColName="" aggregateName="" aggregateTableAliasName="" aggregateTableName="" colName="" fieldId="6" gridHeight="1" gridWidth="6" name="num_emp" posX="16" posY="4" sqlTabName="" tabIndex="4" table_alias_name="" title="Edit1" widget="Edit"/>
</Grid>
</Form>
<DiagramLayout>
+3 -3
View File
@@ -71,7 +71,7 @@ END GLOBALS
END INPUT
CONSTRUCT criterio ON a.supervisor, a.num_emp
CONSTRUCT criterio ON a.num_emp, b.num_emp
FROM cod_sup, num_emp
ON ACTION mostrar
@@ -79,9 +79,9 @@ END GLOBALS
b.num_emp, b.nombre, a.fecha,b.cantidad,b.valor,b.descrip_mov,a.num_doc,b.fech_crea
from notb00028 a
inner join notb00029 b on a.num_doc = b.num_doc
inner join adtb00003 c on a.supervisor = c.num_emp
inner join adtb00003 c on a.num_emp = c.num_emp
where " , criterio CLIPPED, " and ","
a.fecha between '", datos.fecha_inicial USING "mm/dd/yyyy" , "' and '",datos.fecha_final USING "mm/dd/yyyy","' "
a.fecha >= '", datos.fecha_inicial USING "yyyymmdd" , "' and a.fecha < '",(datos.fecha_final + 1) USING "yyyymmdd","' "
DISPLAY selec
PREPARE comando FROM selec
DECLARE cotizaciones CURSOR FOR comando