dmencu 0.8.5 → 0.8.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -16,14 +16,15 @@ AS $BODY$
|
|
|
16
16
|
v_norea integer;
|
|
17
17
|
v_rea_sup integer;
|
|
18
18
|
v_norea_sup integer;
|
|
19
|
+
v_estado text;
|
|
19
20
|
begin
|
|
20
21
|
if old.tarea_actual is distinct from new.tarea_actual and new.tarea_actual is not null and old.tarea_actual is not null then
|
|
21
22
|
select coalesce(max(orden),0)+1 into v_proximo_orden
|
|
22
23
|
from historial_tem
|
|
23
24
|
where operativo = old.operativo and enc = old.enc;
|
|
24
25
|
|
|
25
|
-
select recepcionista, asignado, resumen_estado, resumen_estado_sup, rea, norea, rea_sup, norea_sup into
|
|
26
|
-
v_recepcionista, v_asignado, v_resumen_estado, v_resumen_estado_sup, v_rea, v_norea, v_rea_sup, v_norea_sup
|
|
26
|
+
select recepcionista, asignado, resumen_estado, resumen_estado_sup, rea, norea, rea_sup, norea_sup, estado into
|
|
27
|
+
v_recepcionista, v_asignado, v_resumen_estado, v_resumen_estado_sup, v_rea, v_norea, v_rea_sup, v_norea_sup, v_estado
|
|
27
28
|
from tareas_tem
|
|
28
29
|
where operativo = old.operativo and enc = old.enc and tarea = old.tarea_actual;
|
|
29
30
|
|
|
@@ -33,7 +34,7 @@ begin
|
|
|
33
34
|
where operativo = old.operativo and enc = old.enc;
|
|
34
35
|
|
|
35
36
|
insert into historial_tem (operativo, enc, orden, tarea, estado, ts_salida, recepcionista, asignado, json_encuesta, resumen_estado, resumen_estado_sup, rea, norea, rea_sup, norea_sup) values
|
|
36
|
-
(old.operativo, old.enc, v_proximo_orden, old.
|
|
37
|
+
(old.operativo, old.enc, v_proximo_orden, old.tarea_actual, v_estado, current_timestamp, v_recepcionista, v_asignado, v_json_encuesta, v_resumen_estado, v_resumen_estado_sup, v_rea, v_norea, v_rea_sup, v_norea_sup);
|
|
37
38
|
end if;
|
|
38
39
|
return new;
|
|
39
40
|
end;
|
package/package.json
CHANGED