From 20502e88e28a238385a20dba818b0aa1f16d00fb Mon Sep 17 00:00:00 2001 From: Thomas Zilio Date: Thu, 21 Feb 2019 11:59:00 +0100 Subject: [PATCH] Fix ricerca documentali --- plugins/exportFE/src/Connection.php | 2 +- update/2_4_7.sql | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/exportFE/src/Connection.php b/plugins/exportFE/src/Connection.php index c297a0e7b..47c243388 100644 --- a/plugins/exportFE/src/Connection.php +++ b/plugins/exportFE/src/Connection.php @@ -51,7 +51,7 @@ class Connection { if (!isset(self::$client)) { self::$client = new Client([ - 'base_uri' => 'https://services.osmcloud.it/v1/', + 'base_uri' => 'https://services.osmcloud.it/api/', 'verify' => false, ]); } diff --git a/update/2_4_7.sql b/update/2_4_7.sql index 9fa73d84d..f960456fc 100644 --- a/update/2_4_7.sql +++ b/update/2_4_7.sql @@ -25,3 +25,7 @@ ALTER TABLE `co_documenti` ADD FOREIGN KEY (`id_ritenuta_contributi`) REFERENCES ALTER TABLE `co_righe_documenti` ADD `ritenuta_contributi` BOOLEAN NOT NULL DEFAULT FALSE; INSERT INTO `zz_settings` (`id`, `nome`, `valore`, `tipo`, `editable`, `sezione`, `order`) VALUES (NULL, 'Ritenuta contributi', '', 'query=SELECT * FROM co_ritenuta_contributi', 1, 'Fatturazione', 12); + +-- Fix ricerca documentali +UPDATE `zz_modules` SET `options` = '{ "main_query": [ { "type": "table", "fields": "Descrizione", "query": "SELECT zz_documenti_categorie.`descrizione`as Descrizione, zz_documenti_categorie.`id`as id FROM zz_documenti_categorie WHERE deleted_at IS NULL AND 1=1 HAVING 2=2"} ]}' WHERE `name` = 'Categorie documenti'; +UPDATE `zz_modules` SET `options` = '{ "main_query": [ { "type": "table", "fields": "Categoria, Nome, Data", "query": "SELECT id,(SELECT descrizione FROM zz_documenti_categorie WHERE zz_documenti_categorie.id = idcategoria) AS Categoria, zz_documenti.nome AS Nome, DATE_FORMAT( zz_documenti.`data`, ''%d/%m/%Y'' ) AS `Data` FROM zz_documenti WHERE `data` >= ''|period_start|'' AND `data` <= ''|period_end|'' AND 1=1 HAVING 2=2"} ]}' WHERE `name` = 'Gestione documentale';