From 7a1e01f082497a12f39f0350577cb710970f9f30 Mon Sep 17 00:00:00 2001 From: Luca Date: Fri, 16 Feb 2018 18:16:17 +0100 Subject: [PATCH] Rimosso file caricato per errore --- modules/dashboard/edit__.php | 571 ----------------------------------- 1 file changed, 571 deletions(-) delete mode 100644 modules/dashboard/edit__.php diff --git a/modules/dashboard/edit__.php b/modules/dashboard/edit__.php deleted file mode 100644 index 65e36d6d2..000000000 --- a/modules/dashboard/edit__.php +++ /dev/null @@ -1,571 +0,0 @@ -fetchArray("SELECT an_anagrafiche.idanagrafica AS id FROM an_anagrafiche INNER JOIN (an_tipianagrafiche_anagrafiche INNER JOIN an_tipianagrafiche ON an_tipianagrafiche_anagrafiche.idtipoanagrafica=an_tipianagrafiche.idtipoanagrafica) ON an_anagrafiche.idanagrafica=an_tipianagrafiche_anagrafiche.idanagrafica WHERE deleted=0 AND descrizione='Tecnico'"); - - $_SESSION['dashboard']['idtecnici'] = ["'-1'"]; - - for ($i = 0; $i < count($rs); ++$i) { - $_SESSION['dashboard']['idtecnici'][] = "'".$rs[$i]['id']."'"; - } -} - -if (!isset($_SESSION['dashboard']['idstatiintervento'])) { - $rs = $dbo->fetchArray('SELECT idstatointervento AS id, descrizione FROM in_statiintervento'); - - $_SESSION['dashboard']['idstatiintervento'] = ["'-1'"]; - - for ($i = 0; $i < count($rs); ++$i) { - $_SESSION['dashboard']['idstatiintervento'][] = "'".$rs[$i]['id']."'"; - } -} - -if (!isset($_SESSION['dashboard']['idtipiintervento'])) { - $rs = $dbo->fetchArray('SELECT idtipointervento AS id, descrizione FROM in_tipiintervento'); - - $_SESSION['dashboard']['idtipiintervento'] = ["'-1'"]; - - for ($i = 0; $i < count($rs); ++$i) { - $_SESSION['dashboard']['idtipiintervento'][] = "'".$rs[$i]['id']."'"; - } -} - -if (!isset($_SESSION['dashboard']['idzone'])) { - $rs = $dbo->fetchArray('SELECT id, descrizione FROM an_zone'); - - $_SESSION['dashboard']['idzone'] = ["'-1'"]; - - for ($i = 0; $i < count($rs); ++$i) { - $_SESSION['dashboard']['idzone'][] = "'".$rs[$i]['id']."'"; - } -} - -// Stati intervento -$checks = ''; -$count = 0; -$total = 0; - -$rs = $dbo->fetchArray('SELECT idstatointervento AS id, descrizione, colore FROM in_statiintervento ORDER BY descrizione ASC'); -$total = count($rs); - -$allchecksstati = ''; -for ($i = 0; $i < count($rs); ++$i) { - $attr = ''; - - foreach ($_SESSION['dashboard']['idstatiintervento'] as $idx => $val) { - if ($val == "'".$rs[$i]['id']."'") { - $attr = 'checked="checked"'; - ++$count; - } - } - - $checks .= "
  • \n"; - - $allchecksstati .= "session_set_array( 'dashboard,idstatiintervento', '".$rs[$i]['id']."', 0 ); "; -} - -if ($count == $total) { - $class = 'btn-success'; -} elseif ($count == 0) { - $class = 'btn-danger'; -} else { - $class = 'btn-warning'; -} - -if ($total == 0) { - $class = 'btn-primary disabled'; -} -?> - - -
    - - - -fetchArray('SELECT idtipointervento AS id, descrizione FROM in_tipiintervento ORDER BY descrizione ASC'); -$total = count($rs); - -$allcheckstipi = ''; -for ($i = 0; $i < count($rs); ++$i) { - $attr = ''; - - foreach ($_SESSION['dashboard']['idtipiintervento'] as $idx => $val) { - if ($val == "'".$rs[$i]['id']."'") { - $attr = 'checked="checked"'; - ++$count; - } - } - - $checks .= "
  • \n"; - - $allcheckstipi .= "session_set_array( 'dashboard,idtipiintervento', '".$rs[$i]['id']."', 0 ); "; -} - -if ($count == $total) { - $class = 'btn-success'; -} elseif ($count == 0) { - $class = 'btn-danger'; -} else { - $class = 'btn-warning'; -} - -if ($total == 0) { - $class = 'btn-primary disabled'; -} -?> - - - -fetchArray("SELECT an_anagrafiche.idanagrafica AS id, ragione_sociale FROM an_anagrafiche INNER JOIN (an_tipianagrafiche_anagrafiche INNER JOIN an_tipianagrafiche ON an_tipianagrafiche_anagrafiche.idtipoanagrafica=an_tipianagrafiche.idtipoanagrafica) ON an_anagrafiche.idanagrafica=an_tipianagrafiche_anagrafiche.idanagrafica -LEFT OUTER JOIN in_interventi_tecnici ON in_interventi_tecnici.idtecnico = an_anagrafiche.idanagrafica INNER JOIN in_interventi ON in_interventi_tecnici.idintervento=in_interventi.id -WHERE an_anagrafiche.deleted=0 AND an_tipianagrafiche.descrizione='Tecnico' ".Modules::getAdditionalsQuery('Interventi')." GROUP BY an_anagrafiche.idanagrafica ORDER BY ragione_sociale ASC"); -$total = count($rs); - -$totale_tecnici += $total; - -$allchecktecnici = ''; -for ($i = 0; $i < count($rs); ++$i) { - $attr = ''; - - foreach ($_SESSION['dashboard']['idtecnici'] as $idx => $val) { - if ($val == "'".$rs[$i]['id']."'") { - $attr = 'checked="checked"'; - ++$count; - } - } - - $checks .= "
  • \n"; - - $allchecktecnici .= "session_set_array( 'dashboard,idtecnici', '".$rs[$i]['id']."', 0 ); "; -} - -// TECNICI ELIMINATI -$rs = $dbo->fetchArray("SELECT an_anagrafiche.idanagrafica AS id, ragione_sociale FROM an_anagrafiche INNER JOIN (an_tipianagrafiche_anagrafiche INNER JOIN an_tipianagrafiche ON an_tipianagrafiche_anagrafiche.idtipoanagrafica=an_tipianagrafiche.idtipoanagrafica) ON an_anagrafiche.idanagrafica=an_tipianagrafiche_anagrafiche.idanagrafica WHERE deleted=1 AND descrizione='Tecnico' ORDER BY ragione_sociale ASC"); -$total = count($rs); - -$totale_tecnici += $total; - -if ($total > 0) { - $checks .= "

  • Tecnici eliminati:
  • \n"; - for ($i = 0; $i < count($rs); ++$i) { - $attr = ''; - - foreach ($_SESSION['dashboard']['idtecnici'] as $idx => $val) { - if ($val == "'".$rs[$i]['id']."'") { - $attr = 'checked="checked"'; - ++$count; - } - } - - $checks .= "
  • \n"; - - $allchecktecnici .= "session_set_array( 'dashboard,idtecnici', '".$rs[$i]['id']."', 0 ); "; - } // end for -} // end if - -if ($count == $totale_tecnici) { - $class = 'btn-success'; -} elseif ($count == 0) { - $class = 'btn-danger'; -} else { - $class = 'btn-warning'; -} - -if ($totale_tecnici == 0) { - $class = 'btn-primary disabled'; -} - -?> - - - - -fetchArray('SELECT id, descrizione FROM an_zone ORDER BY descrizione ASC'); -$total = count($rs); - -for ($i = 0; $i < count($rs); ++$i) { - $attr = ''; - - foreach ($_SESSION['dashboard']['idzone'] as $idx => $val) { - if ($val == "'".$rs[$i]['id']."'") { - $attr = 'checked="checked"'; - ++$count; - } - } - - $checks .= "
  • \n"; - - $allcheckzone .= "session_set_array( 'dashboard,idzone', '".$rs[$i]['id']."', 0 ); "; -} - -if ($count == $total) { - $class = 'btn-success'; -} elseif ($count == 0) { - $class = 'btn-danger'; -} else { - $class = 'btn-warning'; -} - -if ($total == 0) { - $class = 'btn-primary disabled'; -} -?> - - -
    -
    -fetchArray($qp); - -if (!empty($rsp)) { - echo ' -
    -
    '; -} - -echo ' -
    '; - -if (!empty($rsp)) { - echo ' -
    - - -
    '; -} - -$vista = get_var('Vista dashboard'); -if ($vista == 'mese') { - $def = 'month'; -} elseif ($vista == 'giorno') { - $def = 'agendaDay'; -} else { - $def = 'agendaWeek'; -} -?> - -