Changeset 279 for trunk/client/modules
- Timestamp:
- Apr 20, 2019, 8:32:48 PM (6 years ago)
- Location:
- trunk/client/modules/Elezioni
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/client/modules/Elezioni/blocchi/00_affluenze.php
r269 r279 45 45 $tot_v_m=0;$tot_v_d=0;$tot_t=0; 46 46 47 $sql="select t3. *from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos group by t3.id_sez ";47 $sql="select t3.id_sez from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos group by t3.id_sez "; 48 48 $res1 = $dbi->prepare("$sql"); 49 49 $res1->execute(); … … 66 66 else 67 67 $sql="select sum(t3.voti_complessivi),0,0 from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos"; 68 $res l= $dbi->prepare("$sql");69 $res l->execute();68 $res1 = $dbi->prepare("$sql"); 69 $res1->execute(); 70 70 71 71 #fine modifica -
trunk/client/modules/Elezioni/blocchi/01_votanti.php
r273 r279 69 69 else 70 70 $numero=0; 71 $sql="select t3.* from ".$prefix."_ele_voti_".$tab." as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join 72 ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' $circos group by t3.id_sez "; 73 $res_sez = $dbi->prepare("$sql"); 74 $res_sez->execute(); 71 #$sql="select t3.* from ".$prefix."_ele_voti_".$tab." as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' $circos group by t3.id_sez "; 72 # $res_sez = $dbi->prepare("$sql"); 73 # $res_sez->execute(); 75 74 76 $sql="select t1. *from ".$prefix."_ele_sezioni as t1 left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t1.id_cons='$id_cons' $circos";75 $sql="select t1.id_sez from ".$prefix."_ele_sezioni as t1 left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t1.id_cons='$id_cons' $circos"; 77 76 $res_sez = $dbi->prepare("$sql"); 78 77 $res_sez->execute(); -
trunk/client/modules/Elezioni/blocchi/bar_affluenze.php
r276 r279 32 32 33 33 34 $sql="select t3. *from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos group by t3.id_sez ";34 $sql="select t3.id_sez from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos group by t3.id_sez "; 35 35 $res1 = $dbi->prepare("$sql"); 36 36 $res1->execute(); -
trunk/client/modules/Elezioni/blocchi/gom_affluenze.php
r278 r279 33 33 34 34 35 $sql="select t3. * from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos group by t3.id_sez ";35 $sql="select t3.id_sez from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos group by t3.id_sez "; 36 36 $res1 = $dbi->prepare("$sql"); 37 37 $res1->execute(); … … 51 51 else 52 52 $sql="select sum(t3.voti_complessivi),0,0 from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos"; 53 $res l= $dbi->prepare("$sql");54 $res l->execute();53 $res1 = $dbi->prepare("$sql"); 54 $res1->execute(); 55 55 56 56 #fine modifica -
trunk/client/modules/Elezioni/blocchi/pie_affluenze.php
r273 r279 39 39 40 40 41 $sql="select t3. *from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos group by t3.id_sez ";41 $sql="select t3.id_sez from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos group by t3.id_sez "; 42 42 $res1 = $dbi->prepare("$sql"); 43 43 $res1->execute(); … … 54 54 #modifica del 26giugno 09 per gestione circoscrizionali 55 55 if($genere==0) { $sql="select sum(t1.voti_complessivi), t2.num_gruppo , t2.id_gruppo from ".$prefix."_ele_voti_parziale as t1 left join ".$prefix."_ele_gruppo as t2 on (t1.id_gruppo=t2.id_gruppo) where t1.id_cons='$id_cons' and t1.orario='$orario' and t1.data='$data' group by t2.num_gruppo,t2.id_gruppo order by t2.num_gruppo " ; 56 $res l= $dbi->prepare("$sql");57 $res l->execute();56 $res1 = $dbi->prepare("$sql"); 57 $res1->execute(); 58 58 59 59 }else{ 60 60 $sql="select sum(t3.voti_complessivi),0,0 from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos"; 61 $res l= $dbi->prepare("$sql");62 $res l->execute();61 $res1 = $dbi->prepare("$sql"); 62 $res1->execute(); 63 63 } 64 64 #fine modifica -
trunk/client/modules/Elezioni/funzioni.php
r274 r279 259 259 260 260 261 $sql="select *from ".$prefix."_$tab where id_cons='$id_cons' group by id_sez ";261 $sql="select id_cons from ".$prefix."_$tab where id_cons='$id_cons' group by id_sez "; 262 262 $res = $dbi->prepare("$sql"); 263 263 $res->execute(); 264 264 265 265 266 if ($res) $numero=$res->rowCount();else $numero=0;266 $numero=$res->rowCount(); 267 267 $sql="select t2.* from ".$prefix."_ele_sezioni as t2, ".$prefix."_ele_sede as t1 where t2.id_cons='$id_cons' and t1.id_sede=t2.id_sede $circondt1"; 268 268 $res = $dbi->prepare("$sql"); -
trunk/client/modules/Elezioni/index.php
r278 r279 713 713 $numero_l=$res_num_list->rowCount(); 714 714 // verifica delle sezioni in relazione ai candidati (comuni >=15000) non c'e' il voto di lista e quindi ci metto se scrutinate le preferenze sulla lista [$numero_c] - 5/5/2009 715 $sql="select *from ".$prefix."_ele_voti_candidati where id_cons='$id_cons' group by id_sez ";715 $sql="select id_sez from ".$prefix."_ele_voti_candidati where id_cons='$id_cons' group by id_sez "; 716 716 $res_num_list = $dbi->prepare("$sql"); 717 717 $res_num_list->execute();
Note:
See TracChangeset
for help on using the changeset viewer.