|
|
@@ -14,6 +14,32 @@ function majIndics() {
|
|
|
* se sdifferentes infos dans la fenetre d'evenements
|
|
|
* et ses lois associées dans la fenetre des lois
|
|
|
*/
|
|
|
-function afficherEvenement(event) {
|
|
|
+function afficherEvenement(evenement) {
|
|
|
+ let divEve = document.getElementById("evenement");
|
|
|
+ let divL1 = document.getElementById("choixLoi1");
|
|
|
+ let divL2 = document.getElementById("choixLoi2");
|
|
|
+ let pNom = document.createElement('p');
|
|
|
+ let pDesc = document.createElement('p');
|
|
|
+ let b1 = document.createElement('input');
|
|
|
+ let b2 = document.createElement('input');
|
|
|
+ b1.type = 'button';
|
|
|
+ b2.type = 'button';
|
|
|
+ pNom.innerHTML = evenement.nom;
|
|
|
+ pDesc.innerHTML = evenement.description;
|
|
|
+ b1.value = evenement.lois[0].nom;
|
|
|
+ b2.value = evenement.lois[1].nom;
|
|
|
+ b1.addEventListener('click', function() {
|
|
|
+ alert(evenement.lois[0].descriptions[0]);
|
|
|
+ }, false);
|
|
|
+ b2.addEventListener('click', function() {
|
|
|
+ alert(evenement.lois[1].descriptions[0]);
|
|
|
+ }, false);
|
|
|
+ divEve.appendChild(pNom);
|
|
|
+ divEve.appendChild(pDesc);
|
|
|
+ divL1.appendChild(b1);
|
|
|
+ divL2.appendChild(b2);
|
|
|
+}
|
|
|
|
|
|
+function afficherLoi(law) {
|
|
|
+
|
|
|
}
|