commit fa2eb127f84c5109896ea2f1b84fcec813adc0a4
Author: Eric Seigne <eric.seigne@ryxeo.com>
Date:   Mon Feb 14 20:59:02 2011 +0100

    2010->2011

diff --git a/plugins/anet_epacks/front/plugin_anet_epacks.config.form.php b/plugins/anet_epacks/front/plugin_anet_epacks.config.form.php
index 189a503..824e5ce 100644
--- a/plugins/anet_epacks/front/plugin_anet_epacks.config.form.php
+++ b/plugins/anet_epacks/front/plugin_anet_epacks.config.form.php
@@ -38,7 +38,7 @@ for($i = 0; $i < $nb_packs; $i++) {
   srand();
   $code=$prefix . rand(1000,9999) . "-" . chr(rand(65,90)) . chr(rand(65,90)) . chr(rand(65,90)) . chr(rand(65,90)) . "-" . rand(1000,9999);
   $password=rand(1000,9999) . "-" . rand(1000,9999);
-  $query="INSERT into glpi_plugin_anet_epacks values('','','','2010-12-31','$code','$password',0,0,0,0);";
+  $query="INSERT into glpi_plugin_anet_epacks values('','','','2011-12-31','$code','$password',0,0,0,0);";
   //print "<p>" . $query . "</p>";
   //exit;
   $DB->query($query);// or die($DB->error());
diff --git a/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_activated.form.php b/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_activated.form.php
index 213e6cf..bf62af9 100644
--- a/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_activated.form.php
+++ b/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_activated.form.php
@@ -68,7 +68,7 @@ $odf->setVars('clientfinalcp', $data['g4dpostcode']);
 $odf->setVars('clientfinalville', $data['g4dtown'], true, 'UTF-8');
 
 if(preg_match("/avenant_contrat_partenaire/i",$_GET['mode'])) {
-  $odf->setVars('cname', "ABE10-" . $data['code'], true, 'UTF-8');
+  $odf->setVars('cname', "ABE11-" . $data['code'], true, 'UTF-8');
 
   $query2 = "SELECT * FROM glpi_contracts WHERE FK_entities='" . $data['g2id'] . "' AND name LIKE '%-ENR20'";
   $result2 = $DB->query($query2);
diff --git a/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_client2.form.php b/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_client2.form.php
index 9a15174..46b01e0 100644
--- a/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_client2.form.php
+++ b/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_client2.form.php
@@ -50,7 +50,7 @@ if(isset($_GET['code'])) {
    $fk_entitee = $_POST['FK_entitee'];
 
   //Un pack non attribué
-  $query="SELECT * FROM glpi_plugin_anet_epacks WHERE FK_clientderyxeo='0' AND creation_date='0000-00-00' AND code LIKE 'ABE10%' LIMIT 1;";
+  $query="SELECT * FROM glpi_plugin_anet_epacks WHERE FK_clientderyxeo='0' AND creation_date='0000-00-00' AND code LIKE 'ABE11%' LIMIT 1;";
   //$DB->query($query) or die($DB->error());
   $result = $DB->query($query);
   $data=$DB->fetch_array($result);
@@ -60,12 +60,12 @@ if(isset($_GET['code'])) {
     print "On vient d'en créer un nouveau, re-essayez ...";
     global $DB;
     $nb_packs = 1;
-    $prefix = "ABE10-01-";
+    $prefix = "ABE11-01-";
     for($i = 0; $i < $nb_packs; $i++) {
       srand();
       $code=$prefix . rand(1000,9999) . "-" . chr(rand(65,90)) . chr(rand(65,90)) . chr(rand(65,90)) . chr(rand(65,90)) . "-" . rand(1000,9999);
       $password=rand(1000,9999) . "-" . rand(1000,9999);
-      $query="INSERT into glpi_plugin_anet_epacks(creation_date,expiration_date,code,password) values( '0000-00-00' ,'2010-12-31','$code','$password');";
+      $query="INSERT into glpi_plugin_anet_epacks(creation_date,expiration_date,code,password) values( '0000-00-00' ,'2011-12-31','$code','$password');";
       print $query;
       $DB->query($query);// or die($DB->error());
     }
diff --git a/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_client2_8_to_9.form.php b/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_client2_8_to_9.form.php
index caeb8a1..4fcbfaa 100644
--- a/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_client2_8_to_9.form.php
+++ b/plugins/anet_epacks/front/plugin_anet_epacks.generate_odt_client2_8_to_9.form.php
@@ -71,7 +71,7 @@ if(count($data_maint) > 1) {
  }
 
 //Un pack non attribué
-$query="SELECT * FROM glpi_plugin_anet_epacks WHERE FK_clientderyxeo='0' AND creation_date='0000-00-00' AND code LIKE 'ABE10%' LIMIT 1;";
+$query="SELECT * FROM glpi_plugin_anet_epacks WHERE FK_clientderyxeo='0' AND creation_date='0000-00-00' AND code LIKE 'ABE11%' LIMIT 1;";
 //$DB->query($query) or die($DB->error());
 $result = $DB->query($query);
 $data=$DB->fetch_array($result);
@@ -81,12 +81,12 @@ if($data['code'] == "") {
   print "<p>Génération automatique d'un nouveau epack, actualisez la page et tout devrait marcher ...</p>";
   global $DB;
   $nb_packs = 1;
-  $prefix = "ABE10-01-";
+  $prefix = "ABE11-01-";
   for($i = 0; $i < $nb_packs; $i++) {
     srand();
     $code=$prefix . rand(1000,9999) . "-" . chr(rand(65,90)) . chr(rand(65,90)) . chr(rand(65,90)) . chr(rand(65,90)) . "-" . rand(1000,9999);
     $password=rand(1000,9999) . "-" . rand(1000,9999);
-    $query="INSERT into glpi_plugin_anet_epacks(creation_date,expiration_date,code,password) values( '0000-00-00' ,'2010-12-31','$code','$password');";
+    $query="INSERT into glpi_plugin_anet_epacks(creation_date,expiration_date,code,password) values( '0000-00-00' ,'2011-12-31','$code','$password');";
     //    print $query;
     $DB->query($query);// or die($DB->error());
   }
