From 9fe2aefd76eb4c300a8bb531be7461e86824c070 Mon Sep 17 00:00:00 2001 From: Juanjo Menent Date: Fri, 17 Dec 2010 16:54:37 +0000 Subject: [PATCH] task #10611: Add option to choose order of key in bank account info on PDF --- htdocs/compta/bank/admin/bank.php | 71 +++++++++++++++++-- htdocs/install/mysql/data/llx_const.sql | 5 ++ .../install/mysql/migration/2.9.0-3.0.0.sql | 3 + htdocs/langs/ca_ES/admin.lang | 7 ++ htdocs/langs/en_US/admin.lang | 7 ++ htdocs/langs/es_AR/admin.lang | 7 ++ htdocs/langs/es_ES/admin.lang | 7 ++ htdocs/langs/fr_FR/admin.lang | 7 ++ htdocs/lib/pdf.lib.php | 6 +- 9 files changed, 113 insertions(+), 7 deletions(-) diff --git a/htdocs/compta/bank/admin/bank.php b/htdocs/compta/bank/admin/bank.php index afbbb1116b9..ec647bbeab8 100644 --- a/htdocs/compta/bank/admin/bank.php +++ b/htdocs/compta/bank/admin/bank.php @@ -1,6 +1,7 @@ - * + * Copyright (C) 2010 Juanjo Menent + * * 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 * the Free Software Foundation; either version 2 of the License, or @@ -48,6 +49,19 @@ if ($_POST["action"] == 'set_BANK_CHEQUERECEIPT_FREE_TEXT') dolibarr_set_const($db, "BANK_CHEQUERECEIPT_FREE_TEXT",$_POST["BANK_CHEQUERECEIPT_FREE_TEXT"],'chaine',0,'',$conf->entity); } +//Order display of bank account +if ($_GET["action"] == 'setbankorder') +{ + if (dolibarr_set_const($db, "BANK_SHOW_ORDER_OPTION",$_GET["value"],'chaine',0,'',$conf->entity) > 0) + { + Header("Location: ".$_SERVER["PHP_SELF"]); + exit; + } + else + { + dol_print_error($db); + } +} /* * view @@ -57,12 +71,10 @@ llxHeader("",""); $html=new Form($db); - $linkback=''.$langs->trans("BackToModuleList").''; print_fiche_titre($langs->trans("BankSetupModule"),$linkback,'setup'); print '
'; - print ''; print ''; print ''; @@ -81,7 +93,8 @@ print '
'.$langs->trans("Parameters").'