<commit_before>/**
 * fonctions pour la page "enroler"
 **/

function enroler(){
    var eleve=$("#eleve").val();
    var cours0val=$("#cours0").val();
    var cours1val=$("#cours1").val();
    console.log(cours0)
    var re = /^.*\((\S*)\)$/;
    var uid=eleve.match(re)[1];
    var id0=cours0val.match(re)[1];
    var m1=cours1val.match(re);
    if (m1) id1=m1[1]; else id1=-1;
    var csrf=$("#csrf").val();
    console.log("inscrire dans le cours :", id0, id1, uid);
    var url="/votes/enroleEleveCours"
    $.post(url,
	   { cours: id0, cours2: id1, uid: uid, csrfmiddlewaretoken: csrf}
	 ).done(function(data){
	     console.log(data, data.msg);
	      $("#dialog").dialog({
		  title: "Résultat",
		  width: 400,
		  buttons: [
		      {
			  text: "OK",
			  click: function() {
			      $( this ).dialog( "close" );
			  }
		      }
		  ],
		  beforeClose: function(event, ui){
		      $("#eleve").val("");
		      var uri="/votes/enroler?"+encodeURI(
			  "c0="+id0+"&c1="+id1
		      );
		      console.log("GRRRR", uri);
		      document.location=uri;
		  },
	      }).html(data.msg);
	  }).fail(function(data){
	      alert("Erreur : "+data.status+" "+data.statusText+" "+url);
	  });
}<commit_msg>retiré un console.log()<commit_after>/**
 * fonctions pour la page "enroler"
 **/

function enroler(){
    var eleve=$("#eleve").val();
    var cours0val=$("#cours0").val();
    var cours1val=$("#cours1").val();
    console.log(cours0)
    var re = /^.*\((\S*)\)$/;
    var uid=eleve.match(re)[1];
    var id0=cours0val.match(re)[1];
    var m1=cours1val.match(re);
    if (m1) id1=m1[1]; else id1=-1;
    var csrf=$("#csrf").val();
    console.log("inscrire dans le cours :", id0, id1, uid);
    var url="/votes/enroleEleveCours"
    $.post(url,
	   { cours: id0, cours2: id1, uid: uid, csrfmiddlewaretoken: csrf}
	 ).done(function(data){
	     console.log(data, data.msg);
	      $("#dialog").dialog({
		  title: "Résultat",
		  width: 400,
		  buttons: [
		      {
			  text: "OK",
			  click: function() {
			      $( this ).dialog( "close" );
			  }
		      }
		  ],
		  beforeClose: function(event, ui){
		      $("#eleve").val("");
		      var uri="/votes/enroler?"+encodeURI(
			  "c0="+id0+"&c1="+id1
		      );
		      document.location=uri;
		  },
	      }).html(data.msg);
	  }).fail(function(data){
	      alert("Erreur : "+data.status+" "+data.statusText+" "+url);
	  });
}
{'fraction_non_alphanumeric': 0.22259274697790746, 'fraction_numerical': 0.02417674030846186, 'mean_word_length': 2.598200899550225, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4532535', 'n_tokens_mistral': 1008, 'n_tokens_neox': 926, 'n_words': 162}