Changeset 199 for trunk/admin
- Timestamp:
- Apr 23, 2014, 12:08:28 AM (11 years ago)
- Location:
- trunk/admin
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/admin/modules/Elezioni/ele_associazioni.php
r192 r199 183 183 list($fasciacom)=mysql_fetch_row($rescomu); 184 184 } else $fasciacom=0; 185 $rescomu = mysql_query("SELECT id_conf, descrizione from ".$prefix."_ele_conf order by descrizione asc", $dbi);185 $rescomu = mysql_query("SELECT id_conf, descrizione from ".$prefix."_ele_conf order by id_conf desc", $dbi); 186 186 echo "<td><select name=\"id_conf\" id=\"id_conf\" onchange=\"javascript:showdate('modules/Elezioni/ele_desc_fasce.php?fascia=$fasciacom&id_conf=' + model.id_conf.options[model.id_conf.selectedIndex].value,'fasceconf');\">"; 187 187 echo "<option value=\"0\"> "; -
trunk/admin/modules/Elezioni/ele_voti.php
r197 r199 40 40 if (isset($param['prev_sez'])) $prev_sez=intval($param['prev_sez']); else $prev_sez=''; 41 41 if (isset($param['id_gruppo'])) $id_gruppo=intval($param['id_gruppo']); else $id_gruppo=''; 42 if (isset($param['update'])) $update=intval($param['update']); else $update=''; 42 43 include("modules/Elezioni/funzionidata.php"); 43 44 include("modules/Elezioni/ele.php"); … … 455 456 if ($ops == 1) { 456 457 votanti($id_cons,$do,$id_circ,$id_sede,$id_sez,$ops,$ov,$mv,$gv,$msv,$av); 457 } 458 }else{ 459 ############# Controllo flag per cancellazione consultazione 460 echo "<SCRIPT type=\"text/javascript\">\n\n<!--\n" 461 ."//-->\n"; 462 echo "function del_dati() {\n"; 463 echo "if (document.getElementById('pwd3').checked==false) {\n"; 464 echo "document.getElementById('update').value=\""._OK."\" \n"; 465 echo "document.getElementById('do').value=\"0\" \n"; 466 echo "}else{\n"; 467 echo "document.getElementById('update').value=\""._DELETE."\" \n"; 468 echo "document.getElementById('do').value=\"1\" \n"; 469 echo "} \n"; 470 echo "} \n"; 471 echo "</script>\n"; 472 } 458 473 /* 459 474 if ($ops == 2) { … … 597 612 ."<input type=\"hidden\" name=\"id_sede\" value=\"$id_sede\">" 598 613 ."<input type=\"hidden\" name=\"tabella\" value=\"$tab\">" 599 ."<input type=\"hidden\" name=\"id_lista\" value=\"$id_lista\">\n"; 614 ."<input type=\"hidden\" name=\"id_lista\" value=\"$id_lista\">\n" 615 ."<input type=\"hidden\" name=\"do\" id=\"do\" value=\"0\">\n"; 600 616 echo "<table class=\"table-menu\" style=\"width: 90%; color: black\">"; 601 617 echo "<tr><td bgcolor=\"$bgcolor1\" align=\"left\" width=\"32\">"; … … 696 712 697 713 } 698 echo "<tr><td></td><td></td><td align=\"center\"><input type=\"submit\" name=\"update\" value=\" "._OK. "\"></td>"; 699 echo "</tr></table></form></tr></table>"; 714 echo "<tr>"; 715 echo "<td></td><td></td>"; 716 echo "<td align=\"center\"><input type=\"submit\" id=\"update\" name=\"update\" value=\""._OK."\"></td>"; 717 echo "</tr></table></form></tr>"; 718 if(chisei()>=64){ 719 echo "<td></td><td> <input type=\"checkbox\" id=\"pwd3\" name=\"pwd3\" value=\"\" onclick=\"javascript:del_dati()\">"._DELETE."</td>"; 720 } 721 echo "</table>"; 700 722 echo "<SCRIPT type=\"text/javascript\">\n\n<!--\n" 701 723 ."document.sezioni.voti1.focus()\n" … … 716 738 717 739 function rec_voti() { 718 global $prefix, $dbi,$aid,$id_cons,$ops,$genere,$votog,$fileout,$id_comune,$limite ;740 global $prefix, $dbi,$aid,$id_cons,$ops,$genere,$votog,$fileout,$id_comune,$limite,$update; 719 741 $sqlcomu="select id_fascia from ".$prefix."_ele_cons_comune where id_cons='$id_cons'"; 720 742 $res = mysql_query($sqlcomu); … … 735 757 $tab = $arg[5]; 736 758 $id_lista = intval($arg[6]); 759 $do= intval($arg[7]); 737 760 if ($tab=="_ele_voti_candidati") { 738 761 $condizione="id_cand"; … … 742 765 if ((($genere==3) OR ($genere==5)) and !$id_lista and !$votog and ($fascia>$limite)) $y = (count($arg)-4); 743 766 else $y=count($arg); 744 for($i=7,$y--;$i< $y;$i++) { 767 if($do==1) { 768 mysql_query("delete from ".$prefix."_ele_voti_lista where id_cons='$id_cons' and id_sez='$id_sez'", $dbi); 769 mysql_query("delete from ".$prefix."_ele_voti_candidati where id_cons='$id_cons' and id_sez='$id_sez'", $dbi); 770 mysql_query("update ".$prefix."_ele_sezioni set validi_lista='',contestati_lista='',voti_nulli_lista='',solo_gruppo='' where id_cons='$id_cons' and id_sez='$id_sez'", $dbi); 771 772 }else{ 773 for($i=8,$y--;$i< $y;$i++) { 745 774 $voti = intval($arg[$i++]); 746 775 $id_cand = intval($arg[$i]); … … 788 817 } 789 818 } 790 819 } 791 820 792 821 // $ops = $arg[$argc]; … … 1182 1211 echo "<td></td></tr></table>"; 1183 1212 if ($validi+$nulli+$bianchi+$contestati+$votinulli>0 or $genere==0) { 1184 echo "< form name=\"sezioni\" action=\"admin.php\">";1213 echo "<table class=\"table-menu\" style=\"width: 60%; color: black\"><tr><td colspan=\"3\"><form name=\"sezioni\" action=\"admin.php\">"; 1185 1214 echo "<input type=\"hidden\" name=\"op\" value=\"rec_voti_gruppi\">" 1186 1215 ."<input type=\"hidden\" name=\"id_cons_gen\" value=\"$id_cons_gen\">" 1187 1216 ."<input type=\"hidden\" name=\"id_sez\" value=\"$id_sez\">" 1188 1217 ."<input type=\"hidden\" name=\"id_circ\" value=\"$id_circ\">" 1189 ."<input type=\"hidden\" name=\"id_sede\" value=\"$id_sede\">"; 1190 echo "<br><br> <table class=\"table-menu\" style=\"width: 60%; color: black\"><tr align=\"center\" bgcolor=\"$bgcolor1\">" 1218 ."<input type=\"hidden\" name=\"id_sede\" value=\"$id_sede\">" 1219 ."<input type=\"hidden\" name=\"do\" id=\"do\" value=\"0\">"; 1220 echo "<br><br> <table class=\"table-menu\" style=\"width: 100%; color: black\"><tr align=\"center\" bgcolor=\"$bgcolor1\">" 1191 1221 ."<td width=\"3%\"><b>"._NUM."</b></td>" 1192 1222 ."<td width=\"50%\"><b>"._GRUPPO."</b></td>"; … … 1265 1295 } 1266 1296 1267 echo "<tr><td></td><td></td><td align=\"center\"><input type=\"submit\" name=\"update\" value=\" "._OK. "\"></td>"; 1268 1269 echo "</tr></table></form><br><br> "; 1297 echo "<tr><td></td><td></td><td align=\"center\"><input type=\"submit\" name=\"update\" id=\"update\" value=\" "._OK. "\"></td>"; 1298 1299 echo "</tr></table></form></td></tr>"; 1300 if(chisei()>=64){ 1301 echo "<tr><td><input type=\"checkbox\" id=\"pwd3\" name=\"pwd3\" value=\"\" onclick=\"javascript:del_dati()\">"._DELETE.""; 1302 } 1303 1304 echo "</td></tr></table>"; 1270 1305 } 1271 1306 if ($genere!=0){ … … 1295 1330 $id_circ = intval($arg[3]); 1296 1331 $id_sede = intval($arg[4]); 1297 $y=count($arg)-1; 1332 $do = intval($arg[5]); 1333 $y=count($arg)-1; 1334 if($do==1) { 1335 mysql_query("delete from ".$prefix."_ele_voti_gruppo where id_cons='$id_cons' and id_sez='$id_sez'", $dbi); 1336 mysql_query("delete from ".$prefix."_ele_voti_lista where id_cons='$id_cons' and id_sez='$id_sez'", $dbi); 1337 mysql_query("delete from ".$prefix."_ele_voti_candidati where id_cons='$id_cons' and id_sez='$id_sez'", $dbi); 1338 mysql_query("update ".$prefix."_ele_sezioni set validi_lista='',contestati_lista='',voti_nulli_lista='',solo_gruppo='',solo_lista='' where id_cons='$id_cons' and id_sez='$id_sez'", $dbi); 1339 1340 }else{ 1341 1298 1342 if ($genere==0) { 1299 1343 $tab="_ele_voti_ref"; … … 1306 1350 } 1307 1351 1308 for($i= 5;$i< $y;) {1352 for($i=6;$i< $y;) { 1309 1353 $id_gruppo = intval($arg[$i++]); 1310 1354 $testval=0; … … 1367 1411 1368 1412 } 1413 } 1369 1414 //$ops = $arg[$argc]; 1370 1415 if ($fileout) fclose($fp); -
trunk/admin/versione.php
r198 r199 1 1 <?php 2 $versione="2.0 rev 19 8";2 $versione="2.0 rev 199"; 3 3 ?>
Note:
See TracChangeset
for help on using the changeset viewer.