From bd3b9a2e39445352213691f849c6ae63b56bef70 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Olivier=20T=C3=A9tard?= Date: Thu, 16 Jan 2014 10:53:31 +0100 Subject: [PATCH] =?utf8?q?Am=C3=A9lioration=20de=20la=20d=C3=A9claration?= =?utf8?q?=20des=20champs=20recherch=C3=A9s.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit On me fait signe qu'il est possible de déclarer directement ``rechercher_champs`` dans le pipeline ``declarer_tables_objets_sql``. Merci à @Cerdic :). --- base/souscription.php | 9 ++++++++- paquet.xml | 2 -- souscription_pipelines.php | 15 --------------- 3 files changed, 8 insertions(+), 18 deletions(-) diff --git a/base/souscription.php b/base/souscription.php index 055dd53..34f3315 100644 --- a/base/souscription.php +++ b/base/souscription.php @@ -69,7 +69,14 @@ function souscription_declarer_tables_objets_sql($tables) { 'date' => "date_souscription", 'champs_editables' => array('courriel', 'nom', 'prenom', 'code_postal', 'adresse', 'ville', 'pays', 'recu_fiscal', 'envoyer_info'), 'champs_versionnes' => array('courriel', 'nom', 'prenom', 'code_postal', 'adresse', 'ville', 'pays', 'recu_fiscal', 'envoyer_info'), - 'rechercher_champs' => array(), + 'rechercher_champs' => array("id_souscription" => 1, + "courriel" => 1, + "nom" => 1, + "prenom" => 1, + "adresse" => 1, + "ville" => 1, + "code_postal" => 1 + ), 'join' => array("id_transaction" => "id_transaction"), 'tables_jointures' => array('spip_transactions'), ); diff --git a/paquet.xml b/paquet.xml index ccd3ed2..27ce035 100644 --- a/paquet.xml +++ b/paquet.xml @@ -28,8 +28,6 @@ inclure="souscription_pipelines.php"/> - 1, - "courriel" => 1, - "nom" => 1, - "prenom" => 1, - "adresse" => 1, - "ville" => 1, - "code_postal" => 1, - ); - - return $flux; -} \ No newline at end of file -- 2.30.2