/**
 * @author apellet
 */
var tmpl_elementList = null;
var tmpl_maxiInfo = null;

/**
 * Methode qui initialise tous les templates utilisés dabs l'application
 */
function initTemplates ()
{
	initTemplateElementList ();
	initTemplateMaxiInfo ();
}



/**
 * Création du template concernant les elements de la liste des résultats.
 */
function initTemplateElementList(){
	var h = "";
	//h += '<li  id="element_${a_code}"><a class="unselected" href="javascript:map_asso[\'${a_code}\'].openInfoWindow();">${a_nom} - ${a_codpos}&nbsp;${a_commune}</a></li>';
	h += '<li  id="element_${a_code}"><a class="unselected" href="#ancre_map" onclick="javascript:map_asso[\'${a_code}\'].openInfoWindow();">${a_nom} - ${a_codpos}&nbsp;${a_commune}</a></li>';
	
	tmpl_elementList = jQuery.template ( h );	
}


/**
 * Création du template concernant la fiche d'info detaillée.
 * On utilisera plus certainement une autre méthode pour remplir la fiche
 */
function initTemplateMaxiInfo ()
{
	var h = "";
	 h += '<div class="dlg-content">';
					 h += '<div id="left_content">';
						 h += '<div id="block_asso">';
							 h += '<h3>Coordonn&eacute;es :</h3>';
							 h += '<p id="asso_adresse1"></p>';
							 h += '<p id="asso_adresse2"></p>';
							 h += '<p id="asso_cod_ville"></p>';
							 h += '<p id="asso_tel"><span>Tel : </span><span class="val"></span></p>';
							 h += '<p id="asso_fax"><span>Fax : </span><span class="val"></span></p>';
							 h += '<p id="asso_email"><span>E-mail : </span><a href=""></a></p>';

							 h += '<p id="asso_web"><a href="" target="_blank"></a></p>';
							
						 h += '</div>';
						 h += '<div id="block_president">';
							 h += '<h3>Coordonn&eacute;es du pr&eacute;sident :</h3>';
							 h += '<p id="president_adresse1"></p>';
							 h += '<p id="president_adresse2"></p>';
							 h += '<p id="president_cod_ville"></p>';
							 h += '<p id="president_tel"><span>Tel : </span><span class="val"></span></p>';
							 h += '<p id="president_portable"><span>Portable : </span><span class="val"></span></p>';
							 h += '<p id="president_email"><span>E-mail : </span><a href=""></a></p>';
						 h += '</div>';
						 h += '<div id="block_contact">';
							 h += '<h3>Coordonn&eacute;es du contact :</h3>';
							 h += '<p id="contact_adresse1"></p>';
							 h += '<p id="contact_adresse2"></p>';
							 h += '<p id="contact_cod_ville"></p>';
							 h += '<p id="contact_tel"><span>Tel : </span><span class="val"></span></p>';
							 h += '<p id="contact_portable"><span>Portable : </span><span class="val"></span></p>';
							 h += '<p id="contact_email"><span>E-mail : </span><a href=""></a></p>';
						 h += '</div>';
					 h += '</div>';
					 h += '<div id="middle_content"></div>';
					 h += '<div id="right_content">';
						 h += '<div id="block_activite">';
							 h += '<h3>Activit&eacute;s :</h3>';
						 h += '</div>';
					 h += '</div>';
				 h += '</div>';
				 
				 tmpl_maxiInfo = jQuery.template ( h );
}

	//jQuery("#map #tool_cookie .body #content-cookie").append ( tmpl_param, all );



