From: Olivier Tétard Date: Thu, 3 Oct 2013 19:07:26 +0000 (+0200) Subject: Ajout d'un champ 'limite' dans la table souscription_campagne. X-Git-Url: http://olivier.miskin.fr/git/?a=commitdiff_plain;h=eb08f3fa2fef5aba3adc1c86ce64af6264e920ea;p=spip_souscriptions.git Ajout d'un champ 'limite' dans la table souscription_campagne. Ce champs va permettre de limiter certaines campagnes en nombre. --- diff --git a/base/souscription.php b/base/souscription.php index 7c3d4cc..d0fc1db 100644 --- a/base/souscription.php +++ b/base/souscription.php @@ -85,6 +85,7 @@ function souscription_declarer_tables_objets_sql($tables) { "titre" => "text NOT NULL DEFAULT ''", "texte" => "longtext NOT NULL DEFAULT ''", "statut" => "varchar(255) NOT NULL DEFAULT 0", + "limite" => "bigint(21) NOT NULL DEFAULT 0", "date" => "datetime NOT NULL DEFAULT '0000-00-00 00:00:00'", "maj" => "TIMESTAMP" ), diff --git a/paquet.xml b/paquet.xml index 3f110c6..58191b2 100644 --- a/paquet.xml +++ b/paquet.xml @@ -5,7 +5,7 @@ compatibilite="[3.0.5;3.0.*]" logo="" documentation="" - schema="0.3"> + schema="0.4"> Souscription Olivier Tétard diff --git a/souscription_administrations.php b/souscription_administrations.php index 70c5343..a3d3bc0 100644 --- a/souscription_administrations.php +++ b/souscription_administrations.php @@ -34,6 +34,8 @@ function souscription_upgrade($nom_meta_base_version, $version_cible) { $maj['0.3'] = array(array('sql_alter', "TABLE spip_souscriptions ADD telephone text NOT NULL DEFAULT ''")); + $maj['0.4'] = array(array('sql_alter', "TABLE spip_souscription_campagnes ADD limite bigint(21) NOT NULL DEFAULT 0")); + include_spip('base/upgrade'); maj_plugin($nom_meta_base_version, $version_cible, $maj); }