PageSourceSearch

https://www.smlh.fr/global/javascript/famille.js?v=20260909_20230714

js smlh.fr collected 2026-09-25 05:16:52 UTC 5,673 bytes, 182 lines download raw bytes

1var vis = new Array();
2var iIdLine=1; // Identifiant de la ligne à supprimer
3// Ajoute une ligne pour pouvoir uploader le fichier
4function addLigneTableEnfant (idTable,classIn,affiche_prenom,affiche_nom,affiche_datenaiss,affiche_promo,affiche_dcd) {
5	
6	
7if(!classIn) classIn="";
8var ligne = document.createElement('tr');
9
10var celluleEnfant = document.createElement('td');
11celluleEnfant.setAttribute("width","50%");
12var cellulePrenom = document.createElement('td');
13cellulePrenom.className = "text_n_12";
14var celluleNom = document.createElement('td');
15var celluleDateNais = document.createElement('td');
16var cellulePromo = document.createElement('td');
17var celluleDCD = document.createElement('td');
18var celluleSup = document.createElement('td');
19
20// Cellule Prenom
21	
22	var cptInputPrenom = document.createElement('input');
23	cptInputPrenom.setAttribute("type","text");
24	
25	//cptInputPrenom.setAttribute("class","text"+classIn);
26	cptInputPrenom.className= "text"+classIn;
27	cptInputPrenom.setAttribute("name","prenom_enfant[]");
28	cptInputPrenom.setAttribute("size","20");
29	cellulePrenom.appendChild(cptInputPrenom);
30	// Rattachement à la ligne
31	if(affiche_prenom) ligne.appendChild(cellulePrenom);
32
33// Cellule Nom
34	
35	var cptInputNom = document.createElement('input');
36	cptInputNom.setAttribute("type","text");
37	//cptInputNom.setAttribute("class","text"+classIn);
38	cptInputNom.className= "text"+classIn;
39	cptInputNom.setAttribute("name","nom_enfant[]");
40	cptInputNom.setAttribute("size","20");
41	celluleNom.appendChild(cptInputNom);
42	// Rattachement à la ligne
43	if(affiche_nom) ligne.appendChild(celluleNom);
44
45// Cellule Année de naissance
46	var cptInputNaisAn = document.createElement('select');
47	
48	//cptInputNaisAn.setAttribute("class","select_disabled"+classIn);
49	
50	cptInputNaisAn.className= "select"+classIn;
51	cptInputNaisAn.setAttribute("name","enaissance_annee[]");
52	cptInputNaisAn.id='anneNAiss'+iIdLine;
53	insertOptionSelect(cptInputNaisAn, "0000", "0000");
54	var  ladate=new  Date()
55	for(j=ladate.getFullYear(); j>1900; j--) insertOptionSelect(cptInputNaisAn,j,j);
56	
57	celluleDateNais.appendChild(cptInputNaisAn);
58	// Rattachement à la ligne
59	if(affiche_datenaiss) ligne.appendChild(celluleDateNais);
60	
61// Cellule Promo
62	var cptInputPromo = document.createElement('input');
63	cptInputPromo.setAttribute("type","text");
64	cptInputPromo.className="text"+classIn;
65	//cptInputPromo.setAttribute("class","select_disabled"+classIn);
66	cptInputPromo.setAttribute("name","promo_enfant[]");
67	cptInputPromo.setAttribute("size","4");
68	cellulePromo.appendChild(cptInputPromo);
69	// Rattachement à la ligne
70	if(affiche_promo) ligne.appendChild(cellulePromo);
71// Cellule DCD
72	var cptInputDCD = document.createElement('input');
73	cptInputDCD.setAttribute("type","checkbox");
74	cptInputDCD.setAttribute("name","decede[]");
75	celluleDCD.appendChild(cptInputDCD);
76	celluleDCD.setAttribute("class","text_n_12"+classIn);
77	celluleDCD.appendChild(document.createTextNode("Décédé(e)"));
78	celluleDCD.className= "text_n_12"+classIn;
79	// Rattachement à la ligne
80	if(affiche_dcd) ligne.appendChild(celluleDCD);
81	
82// Cellule Supprimer
83	var hrefImgSup = document.createElement('a');
84	var imageSup = document.createElement('img');
85	imageSup.src="/global/images/del_rouge.gif";
86	imageSup.border="0";
87	hrefImgSup.href="javascript:supTabLigne('"+idTable+"','"+iIdLine+"');";
88	hrefImgSup.appendChild(imageSup);
89	celluleSup.appendChild(hrefImgSup);
90	// Rattachement à la ligne
91	ligne.appendChild(celluleSup);
92
93
94
95//  Rattachement au tableau
96var table = document.getElementById(idTable);
97var tableBody = table.lastChild;
98
99ligne.id=iIdLine;
100tableBody.appendChild(ligne);
101
102
103iIdLine++;
104
105} //addLigneFileUpload
106
107
108function insertOptionSelect(elSel,textOption,valueOption){
109	
110	
111    var elOptNew = document.createElement('option');
112	
113	if(navigator.appName=='Netscape')  elOptNew.text = textOption; else elOptNew.innerText = textOption; 
114
115    
116    elOptNew.value = valueOption;
117	
118	elSel.appendChild(elOptNew);
119 
120}
121
122
123
124// Supprimer la ligne
125function supTabLigne (idTable,idTr)
126{
127 // Boucler sur tout les tr du tableau et regarder l'id qu'il faut suprimer
128 var table = document.getElementById(idTable);
129 var tableBody = table.lastChild;
130 var nbrNodes=tableBody.childNodes.length;
131
132 for(i=0;i<nbrNodes;i++){
133     // Supprimer le noeud qui a l'id
134     if(tableBody.childNodes[i].id==idTr){
135        supAllChildNodes(tableBody.childNodes[i]);
136        tableBody.removeChild(tableBody.childNodes[i]);
137        break;
138     }
139 }
140} // supUploadFileLigne
141
142function supAllChildNodes(node) {
143		 if (node && node.hasChildNodes && node.removeChild) {
144		 		 while (node.hasChildNodes()) {
145		 		 node.removeChild(node.firstChild);
146		 		 }
147		 }
148} // supAllChildNodes
149
150
151function fenetre_conjoint_modal(nom_formulaire, as_no, modal) {
152	rech_as_no_modal("/global/gene/rech_as_no.php?nom_formulaire=" + nom_formulaire +"&personne=conjoint_fiche&no_as_no="+as_no, modal);
153
154}
155
156function fenetre_conjoint(formulaire, ecole, num_champs, as_no) {
157   fen = window.open("/global/gene/rech_as_no_conjoint.php?" + formulaire +"&num_champs="+num_champs+"&as_no="+as_no, "", "width=600,height=600,scrollbars=yes");
158   if (!fen.opener) fen.opener = self;
159
160}
161
162function supp_conjoint() {
163	document.formulaire_maj.as_no_conjoint.value = '';
164	document.formulaire_maj.nom_conjoint.value = '';
165}
166
167
168function conjointMember(val) {
169	if(val == 1)  {
170		$('.modal_rech_asno').show();
171		$('#prenom_conjoint').hide();
172		$('#nom_conjoint').attr('readonly', true);
173		$('.phrase_conjoint_membre').show();
174	}
175	else {
176		$('.modal_rech_asno').hide();
177		$('#prenom_conjoint').show();
178		$('#nom_conjoint').attr('readonly', false);
179		$('.phrase_conjoint_membre').hide();
180	}
181}
182

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.