diff --git a/modules/interventi/edit.php b/modules/interventi/edit.php index cc875a16a..8c22fa82f 100755 --- a/modules/interventi/edit.php +++ b/modules/interventi/edit.php @@ -27,7 +27,8 @@ $module_anagrafiche = Modules::get('Anagrafiche'); // Verifica aggiuntive sulla sequenzialità dei numeri $numero_previsto = verifica_numero_intervento($intervento); -if (!empty($numero_previsto)) { + +if (!empty($numero_previsto) && intval((setting('Verifica numero intervento'))) ) { echo '
'.tr("E' assente una attività di numero _NUM_ in data precedente o corrispondente a _DATE_: si potrebbero verificare dei problemi con la numerazione corrente delle attività", [ diff --git a/update/2_4_23.sql b/update/2_4_23.sql index f75805c6c..dadd1dbab 100644 --- a/update/2_4_23.sql +++ b/update/2_4_23.sql @@ -183,4 +183,8 @@ ALTER TABLE `co_banche` ADD `branch_code` VARCHAR(20) NULL, ADD FOREIGN KEY (`id_nazione`) REFERENCES `an_nazioni`(`id`); -- Fix gestione documentale -UPDATE `zz_modules` SET `options` = 'SELECT |select| FROM `do_documenti`\r\nINNER JOIN `do_categorie` ON `do_categorie`.`id` = `do_documenti`.`idcategoria`\r\nWHERE 1=1 AND `deleted_at` IS NULL AND\r\n (SELECT `idgruppo` FROM `zz_users` WHERE `zz_users`.`id` = |id_utente|) IN (SELECT `id_gruppo` FROM `do_permessi` WHERE `id_categoria` = `do_documenti`.`idcategoria`)\r\n |date_period(`data`)| OR data IS NULL\r\nHAVING 2=2' WHERE `zz_modules`.`name` = 'Gestione documentale'; \ No newline at end of file +UPDATE `zz_modules` SET `options` = 'SELECT |select| FROM `do_documenti`\r\nINNER JOIN `do_categorie` ON `do_categorie`.`id` = `do_documenti`.`idcategoria`\r\nWHERE 1=1 AND `deleted_at` IS NULL AND\r\n (SELECT `idgruppo` FROM `zz_users` WHERE `zz_users`.`id` = |id_utente|) IN (SELECT `id_gruppo` FROM `do_permessi` WHERE `id_categoria` = `do_documenti`.`idcategoria`)\r\n |date_period(`data`)| OR data IS NULL\r\nHAVING 2=2' WHERE `zz_modules`.`name` = 'Gestione documentale'; + +-- Messaggio Verifica numero intervento +INSERT INTO `zz_settings` (`id`, `nome`, `valore`, `tipo`, `editable`, `sezione`, `order`, `help`) VALUES +(NULL, 'Verifica numero intervento', '1', 'boolean', 1, 'Attività', 1, 'Visualizza il messaggio che verifica la continuità dei numeri per le attività'); \ No newline at end of file