1
0
mirror of https://github.com/devcode-it/openstamanager.git synced 2024-12-27 08:12:47 +01:00

Rimozione query inutile

This commit is contained in:
loviuz 2019-04-14 12:53:37 +02:00
parent b7cd31d8e1
commit e49e6e067c

View File

@ -225,10 +225,4 @@ UPDATE `zz_settings` SET `nome` = 'Tipo Cassa Previdenziale' WHERE `zz_settings`
-- Aggiunta campo "Rif. fattura" nello scadenzario
INSERT INTO `zz_views` (`id`, `id_module`, `name`, `query`, `order`, `search`, `slow`, `format`, `search_inside`, `order_by`, `visible`, `summable`, `default`) VALUES (NULL, (SELECT id FROM zz_modules WHERE name='Scadenzario'), 'Rif. Fattura', 'IF( numero_esterno!="", numero_esterno, numero )', '2', '1', '0', '0', NULL, NULL, '1', '0', '1');
INSERT INTO `zz_group_view`(`id_gruppo`, `id_vista`) VALUES
( (SELECT `id` FROM `zz_groups` WHERE `nome`='Amministratori'), (SELECT `id` FROM `zz_views` WHERE `id_module`=(SELECT `id` FROM `zz_modules` WHERE `name`='Scadenzario') AND `name`='Rif. Fattura') ),
( (SELECT `id` FROM `zz_groups` WHERE `nome`='Clienti'), (SELECT `id` FROM `zz_views` WHERE `id_module`=(SELECT `id` FROM `zz_modules` WHERE `name`='Scadenzario') AND `name`='Rif. Fattura') ),
( (SELECT `id` FROM `zz_groups` WHERE `nome`='Tecnici'), (SELECT `id` FROM `zz_views` WHERE `id_module`=(SELECT `id` FROM `zz_modules` WHERE `name`='Scadenzario') AND `name`='Rif. Fattura') ),
( (SELECT `id` FROM `zz_groups` WHERE `nome`='Agenti'), (SELECT `id` FROM `zz_views` WHERE `id_module`=(SELECT `id` FROM `zz_modules` WHERE `name`='Scadenzario') AND `name`='Rif. Fattura') );
UPDATE `zz_views` SET `order`=`order`+1 WHERE `id_module`=(SELECT `id` FROM `zz_modules` WHERE `name`='Scadenzario') AND `order` > 1 AND `name` != 'Rif. Fattura';