Subversion Repository Public Repository

Nextrek

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
<?php $__env->startSection('content'); ?>
<div class="img-titolo">
	<div><hr><h2>Soci</h2><hr></div>
	<img src="<?php echo URL::asset('image/soci-bg.jpg'); ?>" alt="">
</div>

<div class="wrap soci">
	<div class="r-wrap">
		<ul class="cerca">
			<li>I brokers assicurativi che fanno parte dell'AIBA hanno una presenza capillare sul territorio. <br> 
		Scopri il broker piĆ¹ vicino a te effettuando una ricerca per nominativo oppure cliccando sul nome della regione.</li>
			<li>
				<form action="<?php echo URL::route('soci-cerca'); ?>" method="post" id="form-search">
				<span class="mdl"><input type="text" name="nome"><i style="cursor:pointer" class="fa fa-search" id="submit"></i></span>
				<?php echo Form::token(); ?>

			</form>
			</li>
		</ul>

		<hr>
		
		<aside class="regioni">
			<div class="italia" >
				<img src="<?php echo URL::asset('image/italia.jpg'); ?>" alt="">
			</div>
			<div class="select">
				<select name="">
					<?php foreach(Province::groupBy('regione')->orderBy('regione')->get() as $provincia): ?>
						<?php if($provincia->regione!='Estero'): ?>
							<?php if(HTML::activeState('soci/'.$provincia->regione) || HTML::activeState('nxt_2019/'.$provincia->regione)): ?>
							<option selected value="<?php echo $provincia->regione; ?>"><?php echo $provincia->regione; ?></a></option>
							<?php else: ?>
							<option value="<?php echo $provincia->regione; ?>"><?php echo $provincia->regione; ?></a></option>
							<?php endif; ?>
						<?php endif; ?>
					<?php endforeach; ?>
					<?php if(HTML::activeState('soci/Estero')): ?>
					<option selected value="Estero">
						<i class="fa fa-angle-right"></i>Estero</a>
					</option>
					<?php else: ?>
					<option value="Estero">
						<i class="fa fa-angle-right"></i>Estero</a>
					</option>
					<?php endif; ?>

				</select>
				<i class="fa fa-sort-desc"></i>
			</div>
		</aside>
		
		<div class="result toFill">
			<ul>
				
			</ul>
		</div>
	</div>
</div>

<?php echo $__env->make('layout.info', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('scripts'); ?>
	<script>
	$(function(){
		$('#submit').click(function(){
			$('.soci #form-search').submit();
		});
		
		associatiReg = associatiReg.replace(//g, "");
		associatiReg = JSON.parse(associatiReg);
		
		var elemToFill = $("div.result.toFill ul");
		
		var htmlToPut = "";
		
		associatiReg.sort(function(a, b){
			if (a.datiAssociati.ragioneSociale.trim() > b.datiAssociati.ragioneSociale.trim()){
				return 1;
			}else{
				return -1;
			}
		});
		
		
		for (elem in associatiReg){
			if (associatiReg[elem] && typeof(associatiReg[elem]) != "function" && associatiReg[elem].datiAssociati && associatiReg[elem].datiAssociati.ragioneSociale != "test"){
				var regioneAssociato = provinceRegioni[associatiReg[elem].datiAssociati.provincia];
				
				if (regioneAssociato == regione){
					htmlToPut += "<li>";
					htmlToPut += '<span class="titolo">'+associatiReg[elem].datiAssociati.ragioneSociale+'</span><br>';
					htmlToPut += '<span class="sede">';
					htmlToPut += 'Sede principale';
					htmlToPut += '</span><br>';
					htmlToPut += '<span class="indirizzo">'+associatiReg[elem].datiAssociati.indirizzo+' - '+associatiReg[elem].datiAssociati.cap+' - '+associatiReg[elem].datiAssociati.localita+' ('+associatiReg[elem].datiAssociati.provincia+')</span><br>';
					for (elem2 in associatiReg[elem].datiAssociati.elencoSediAziendali){
						htmlToPut += '<span class="sede">';
						htmlToPut += 'Altre sedi';
						htmlToPut += '</span><br>';
						if (typeof(associatiReg[elem].datiAssociati.elencoSediAziendali[elem2]) == "object"){
							htmlToPut += '<span class="indirizzo">'+associatiReg[elem].datiAssociati.elencoSediAziendali[elem2].indirizzo+' - '+associatiReg[elem].datiAssociati.elencoSediAziendali[elem2].cap+' - '+associatiReg[elem].datiAssociati.elencoSediAziendali[elem2].localita+' ('+associatiReg[elem].datiAssociati.elencoSediAziendali[elem2].provincia+')</span><br>';
						}else if (typeof(associatiReg[elem].datiAssociati.elencoSediAziendali[elem2]) == "string"){
							htmlToPut += '<span class="indirizzo">'+associatiReg[elem].datiAssociati.elencoSediAziendali[elem2]+'</span><br>';
						}
						
					}
					htmlToPut += '<span class="tel">Tel: '+associatiReg[elem].datiAssociati.telefono+' - Fax: '+(associatiReg[elem].datiAssociati.fax ? associatiReg[elem].datiAssociati.fax : '-' )+'</span>';
					htmlToPut += '<a style="display:block; margin-top:10px" href="/soci/scheda/'+associatiReg[elem].id+'"><i class="fa fa-chevron-right"></i> Altre informazioni</a>';
					htmlToPut += "</li>";
				}
			}
		}
		
		elemToFill.append(htmlToPut);
		
		
	});
		
	var associatiReg = '<?php echo $associati; ?>';
	var regione = "<?php echo $regione; ?>";
		
	var provinceRegioni = {"AG":"Sicilia","AL":"Piemonte","AN":"Marche","AR":"Toscana","AP":"Marche","AT":"Piemonte","AV":"Campania","BA":"Puglia","BT":"Puglia","BL":"Veneto","BN":"Campania","BG":"Lombardia","BI":"Piemonte","BO":"Emilia Romagna","BZ":"Trentino Alto Adige","BS":"Lombardia","BR":"Puglia","CA":"Sardegna","CL":"Sicilia","CB":"Molise","CI":"Sardegna","CE":"Campania","CT":"Sicilia","CZ":"Calabria","CH":"Abruzzo","CO":"Lombardia","CS":"Calabria","CR":"Lombardia","KR":"Calabria","CN":"Piemonte","EN":"Sicilia","FM":"Marche","FE":"Emilia Romagna","FI":"Toscana","FG":"Puglia","FC":"Emilia Romagna","FR":"Lazio","GE":"Liguria","GO":"Friuli Venezia Giulia","GR":"Toscana","IM":"Liguria","IS":"Molise","AQ":"Abruzzo","SP":"Liguria","LT":"Lazio","LE":"Puglia","LC":"Lombardia","LI":"Toscana","LO":"Lombardia","LU":"Toscana","MC":"Marche","MN":"Lombardia","MS":"Toscana","MT":"Basilicata","VS":"Sardegna","ME":"Sicilia","MI":"Lombardia","MO":"Emilia Romagna","MB":"Lombardia","NA":"Campania","NO":"Piemonte","NU":"Sardegna","OG":"Sardegna","OT":"Sardegna","OR":"Sardegna","PD":"Veneto","PA":"Sicilia","PR":"Emilia Romagna","PV":"Lombardia","PG":"Umbria","PU":"Marche","PE":"Abruzzo","PC":"Emilia Romagna","PI":"Toscana","PT":"Toscana","PN":"Friuli Venezia Giulia","PZ":"Basilicata","PO":"Toscana","RG":"Sicilia","RA":"Emilia Romagna","RC":"Calabria","RE":"Emilia Romagna","RI":"Lazio","RN":"Emilia Romagna","RM":"Lazio","RO":"Veneto","SA":"Campania","SS":"Sardegna","SV":"Liguria","SI":"Toscana","SR":"Sicilia","SO":"Lombardia","TA":"Puglia","TE":"Abruzzo","TR":"Umbria","TO":"Piemonte","TP":"Sicilia","TN":"Trentino Alto Adige","TV":"Veneto","TS":"Friuli Venezia Giulia","UD":"Friuli Venezia Giulia","AO":"Valle d'Aosta","VA":"Lombardia","VE":"Veneto","VB":"Piemonte","VC":"Piemonte","VR":"Veneto","VV":"Calabria","VI":"Veneto","VT":"Lazio","SM":"Estero","ES":"Estero"};
		
	var regioniProvince = {"Sicilia":["AG","CL","CT","EN","ME","PA","RG","SR","TP"],"Piemonte":["AL","AT","BI","CN","NO","TO","VB","VC"],"Marche":["AN","AP","FM","MC","PU"],"Toscana":["AR","FI","GR","LI","LU","MS","PI","PT","PO","SI"],"Campania":["AV","BN","CE","NA","SA"],"Puglia":["BA","BT","BR","FG","LE","TA"],"Veneto":["BL","PD","RO","TV","VE","VR","VI"],"Lombardia":["BG","BS","CO","CR","LC","LO","MN","MI","MB","PV","SO","VA"],"Emilia Romagna":["BO","FE","FC","MO","PR","PC","RA","RE","RN"],"Trentino Alto Adige":["BZ","TN"],"Sardegna":["CA","CI","VS","NU","OG","OT","OR","SS"],"Molise":["CB","IS"],"Calabria":["CZ","CS","KR","RC","VV"],"Abruzzo":["CH","AQ","PE","TE"],"Lazio":["FR","LT","RI","RM","VT"],"Liguria":["GE","IM","SP","SV"],"Friuli Venezia Giulia":["GO","PN","TS","UD"],"Basilicata":["MT","PZ"],"Umbria":["PG","TR"],"Valle d'Aosta":["AO"],"Estero":["ES", "SM"]};
		
	</script>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('layout.main', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>

Commits for Nextrek/Aiba_backup/app/storage/_views/6ca91717ad3f67241f9784d7138c0c10

Diff revisions: vs.
Revision Author Commited Message
1464 MOliva picture MOliva Tue 13 Oct, 2020 11:16:56 +0000