From ef88a04f93bb6c5f71c93309aac018fe237b9c28 Mon Sep 17 00:00:00 2001 From: aspangaro Date: Tue, 2 Jun 2015 20:41:02 +0200 Subject: [PATCH 1/3] Fix: Donation error on admin tab --- htdocs/core/lib/donation.lib.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/core/lib/donation.lib.php b/htdocs/core/lib/donation.lib.php index 1fdd2399610..f7d5421d2ac 100644 --- a/htdocs/core/lib/donation.lib.php +++ b/htdocs/core/lib/donation.lib.php @@ -27,7 +27,7 @@ * @param Donation $object Donation * @return array Array of tabs to show */ -function donation_admin_prepare_head($object) +function donation_admin_prepare_head() { global $langs, $conf; @@ -43,14 +43,14 @@ function donation_admin_prepare_head($object) // Entries must be declared in modules descriptor with line // $this->tabs = array('entity:+tabname:Title:@mymodule:/mymodule/mypage.php?id=__ID__'); to add new tab // $this->tabs = array('entity:-tabname); to remove a tab - complete_head_from_modules($conf, $langs, $object, $head, $h, 'donation_admin'); + complete_head_from_modules($conf, $langs, null, $head, $h, 'donation_admin'); $head[$h][0] = DOL_URL_ROOT . '/don/admin/donation_extrafields.php'; $head[$h][1] = $langs->trans("ExtraFields"); $head[$h][2] = 'attributes'; $h++; - complete_head_from_modules($conf, $langs, $object, $head, $h, 'donation_admin', 'remove'); + complete_head_from_modules($conf, $langs, null, $head, $h, 'donation_admin', 'remove'); return $head; } From d28a56c8ac7386d72c625cbdd59dacedc0e070c0 Mon Sep 17 00:00:00 2001 From: aspangaro Date: Wed, 3 Jun 2015 05:49:43 +0200 Subject: [PATCH 2/3] Correct travis --- htdocs/core/lib/donation.lib.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/htdocs/core/lib/donation.lib.php b/htdocs/core/lib/donation.lib.php index f7d5421d2ac..c9362425459 100644 --- a/htdocs/core/lib/donation.lib.php +++ b/htdocs/core/lib/donation.lib.php @@ -24,7 +24,6 @@ /** * Prepare array with list of admin tabs * - * @param Donation $object Donation * @return array Array of tabs to show */ function donation_admin_prepare_head() @@ -32,7 +31,7 @@ function donation_admin_prepare_head() global $langs, $conf; $h = 0; - $head = array (); + $head = array(); $head[$h][0] = DOL_URL_ROOT . '/don/admin/donation.php'; $head[$h][1] = $langs->trans("Miscellaneous"); @@ -66,7 +65,7 @@ function donation_prepare_head($object) global $langs, $conf; $h = 0; - $head = array (); + $head = array(); $head[$h][0] = DOL_URL_ROOT . '/don/card.php?id=' . $object->id; $head[$h][1] = $langs->trans("Card"); From bde91633da7a91d595fc7d4d30d770ecc6a747b9 Mon Sep 17 00:00:00 2001 From: aspangaro Date: Wed, 3 Jun 2015 06:01:05 +0200 Subject: [PATCH 3/3] Fix: input of french article is disabled by default --- htdocs/core/modules/dons/html_cerfafr.modules.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/htdocs/core/modules/dons/html_cerfafr.modules.php b/htdocs/core/modules/dons/html_cerfafr.modules.php index 69c862d916d..67131a28645 100644 --- a/htdocs/core/modules/dons/html_cerfafr.modules.php +++ b/htdocs/core/modules/dons/html_cerfafr.modules.php @@ -3,7 +3,7 @@ * Copyright (C) 2005-2006 Laurent Destailleur * Copyright (C) 2012 Regis Houssin * Copyright (C) 2012 Marcos GarcĂ­a - * Copyright (C) 2014 Alexandre Spangaro + * Copyright (C) 2014-2015 Alexandre Spangaro * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -181,11 +181,11 @@ class html_cerfafr extends ModeleDon if (preg_match('/fr/i',$outputlangs->defaultlang)) { if ($conf->global->DONATION_ART200 >= 1) { - $art200='200 du CGI'; + $art200='200 du CGI'; } else { - $art200='200 du CGI'; + $art200='200 du CGI'; } } $form = str_replace('__ARTICLE200__',$art200,$form); @@ -194,11 +194,11 @@ class html_cerfafr extends ModeleDon if (preg_match('/fr/i',$outputlangs->defaultlang)) { if ($conf->global->DONATION_ART238 >= 1) { - $art238='238 bis du CGI'; + $art238='238 bis du CGI'; } else { - $art238='238 bis du CGI'; + $art238='238 bis du CGI'; } } $form = str_replace('__ARTICLE238__',$art238,$form); @@ -207,11 +207,11 @@ class html_cerfafr extends ModeleDon if (preg_match('/fr/i',$outputlangs->defaultlang)) { if ($conf->global->DONATION_ART885 >= 1) { - $art885='885-0 V bis du CGI'; + $art885='885-0 V bis du CGI'; } else { - $art885='885-0 V bis du CGI'; + $art885='885-0 V bis du CGI'; } } $form = str_replace('__ARTICLE885__',$art885,$form);