diff --git a/sql/data.sql b/sql/data.sql index 916442a16..0d63a12e3 100644 --- a/sql/data.sql +++ b/sql/data.sql @@ -861,7 +861,6 @@ INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, lab INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'firepermit@digiriskdolibarr', 'FIREPERMIT_CREATE', 'FirePermitCreated', 'Executed when a fire permit is created', 1, 320); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'firepermit@digiriskdolibarr', 'FIREPERMIT_MODIFY', 'FirePermitModified', 'Executed when a fire permit is modified', 1, 330); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'firepermit@digiriskdolibarr', 'FIREPERMIT_DELETE', 'FirePermitDeleted', 'Executed when a fire permit is deleted', 1, 340); -INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'firepermit@digiriskdolibarr', 'FIREPERMIT_INPROGRESS', 'FirePermitInProgress', 'Executed when a fire permit status is in progress', 1, 350); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'firepermit@digiriskdolibarr', 'FIREPERMIT_PENDINGSIGNATURE', 'FirePermitPendingSignature', 'Executed when a fire permit status is pending signature', 1, 360); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'firepermit@digiriskdolibarr', 'FIREPERMIT_LOCK', 'FirePermitLocked', 'Executed when a fire permit is locked', 1, 370); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'firepermit@digiriskdolibarr', 'FIREPERMIT_ARCHIVE', 'FirePermitArchived', 'Executed when a fire permit is archived', 1, 380); @@ -872,7 +871,6 @@ INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, lab INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'preventionplan@digiriskdolibarr', 'PREVENTIONPLAN_CREATE', 'PreventionPlanCreated', 'Executed when a prevention plan is created', 1, 430); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'preventionplan@digiriskdolibarr', 'PREVENTIONPLAN_MODIFY', 'PreventionPlanModified', 'Executed when a prevention plan is modified', 1, 440); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'preventionplan@digiriskdolibarr', 'PREVENTIONPLAN_DELETE', 'PreventionPlanDeleted', 'Executed when a prevention plan is deleted', 1, 450); -INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'preventionplan@digiriskdolibarr', 'PREVENTIONPLAN_INPROGRESS', 'PreventionPlanInProgress', 'Executed when a prevention plan status is in progress', 1, 460); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'preventionplan@digiriskdolibarr', 'PREVENTIONPLAN_PENDINGSIGNATURE', 'PreventionPlanPendingSignature', 'Executed when a prevention plan status is pending signature', 1, 470); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'preventionplan@digiriskdolibarr', 'PREVENTIONPLAN_LOCK', 'PreventionPlanLocked', 'Executed when a prevention plan is locked', 1, 480); INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'preventionplan@digiriskdolibarr', 'PREVENTIONPLAN_ARCHIVE', 'PreventionPlanArchived', 'Executed when a prevention plan is archived', 1, 490); @@ -903,3 +901,11 @@ INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, lab -- 9.14.0 INSERT INTO `llx_c_accident_attendants_role` (`rowid`, `entity`, `ref`, `label`, `description`, `active`, `position`) VALUES (1, 0, 'Victim', 'Victim', '', 1, 1); INSERT INTO `llx_c_accident_attendants_role` (`rowid`, `entity`, `ref`, `label`, `description`, `active`, `position`) VALUES (2, 0, 'Caregiver', 'Caregiver', '', 1, 10); + +-- 9.14.1 +INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'firepermit@digiriskdolibarr', 'FIREPERMIT_UNVALIDATE', 'FirePermitUnValidate', 'Executed when a fire permit is re-open', 1, 350); +INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'preventionplan@digiriskdolibarr', 'PREVENTIONPLAN_UNVALIDATE', 'PreventionPlanUnValidate', 'Executed when a prevention plan is re-open', 1, 460); +INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'accident@digiriskdolibarr', 'ACCIDENT_VALIDATE', 'AccidentValidated', 'Executed when an accident is validated', 1, 121); +INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'accident@digiriskdolibarr', 'ACCIDENT_UNVALIDATE', 'AccidentUnValidated', 'Executed when an accident is re-open', 1, 122); +INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'accident@digiriskdolibarr', 'ACCIDENT_ARCHIVE', 'AccidentArchived', 'Executed when an accident is archived', 1, 123); +INSERT INTO llx_c_digiriskdolibarr_action_trigger (entity, elementtype, ref, label, description, active, position) VALUES (0, 'accident@digiriskdolibarr', 'ACCIDENT_LOCK', 'AccidentLocked', 'Executed when an accident is locked', 1, 124); diff --git a/sql/update.sql b/sql/update.sql index 44d78165d..d4c6863b6 100644 --- a/sql/update.sql +++ b/sql/update.sql @@ -241,3 +241,7 @@ UPDATE llx_digiriskdolibarr_risk SET category = 21 WHERE category = 20; UPDATE llx_digiriskdolibarr_risk SET category = 22 WHERE category = 21; ALTER TABLE llx_digiriskdolibarr_accident ADD fk_ticket integer; ALTER TABLE llx_digiriskdolibarr_accident DROP COLUMN fk_user_victim; + +-- 9.14.1 +DELETE FROM llx_c_digiriskdolibarr_action_trigger WHERE ref = 'FIREPERMIT_INPROGRESS'; +DELETE FROM llx_c_digiriskdolibarr_action_trigger WHERE ref = 'PREVENTIONPLAN_INPROGRESS';