From 917423dc0c76e557fac2fcca0c1114ced4cea52b Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Wed, 26 Nov 2014 14:16:59 +0100 Subject: [PATCH 1/9] add default payment mode select --- htdocs/comm/card.php | 4 ++++ htdocs/fourn/card.php | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/htdocs/comm/card.php b/htdocs/comm/card.php index d0dd842cd7c..7c47c25409d 100644 --- a/htdocs/comm/card.php +++ b/htdocs/comm/card.php @@ -347,6 +347,10 @@ if ($id > 0) print ''; if ($action == 'editmode') { + if (empty($object->mode_reglement_id)) + { + $object->mode_reglement_id=$conf->global->MAIN_PAYMENT_MODE_DEFAULT; + } $form->form_modes_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id,$object->mode_reglement_id,'mode_reglement_id'); } else diff --git a/htdocs/fourn/card.php b/htdocs/fourn/card.php index 3e234af68cd..30c55c7b130 100644 --- a/htdocs/fourn/card.php +++ b/htdocs/fourn/card.php @@ -232,6 +232,10 @@ if ($object->fetch($id)) print ''; if ($action == 'editmode') { + if (empty($object->mode_reglement_supplier_id)) + { + $object->mode_reglement_supplier_id=$conf->global->MAIN_PAYMENT_MODE_DEFAULT; + } $form->form_modes_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id,$object->mode_reglement_supplier_id,'mode_reglement_supplier_id'); } else From 217cacbc295a16daafb33e48494fa6f1531fac0e Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Thu, 27 Nov 2014 17:26:06 +0100 Subject: [PATCH 2/9] To avoid over wrighting lines --- htdocs/core/lib/pdf.lib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/lib/pdf.lib.php b/htdocs/core/lib/pdf.lib.php index 3223412dc5f..bc0a9e71f38 100644 --- a/htdocs/core/lib/pdf.lib.php +++ b/htdocs/core/lib/pdf.lib.php @@ -897,7 +897,7 @@ function pdf_writeLinkedObjects(&$pdf,$object,$outputlangs,$posx,$posy,$w,$h,$al if (! empty($linkedobject["date_title"]) && ! empty($linkedobject["date_value"])) { - $posy+=3; + $posy+=7; $pdf->SetXY($posx,$posy); $pdf->MultiCell($w, $h, $linkedobject["date_title"].' : '.$linkedobject["date_value"], '', $align); } From c3d66b037dc0cc13e078b7357d1f095413091ff9 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Fri, 28 Nov 2014 10:35:02 +0100 Subject: [PATCH 3/9] Revert "add default payment mode select" This reverts commit 917423dc0c76e557fac2fcca0c1114ced4cea52b. --- htdocs/comm/card.php | 4 ---- htdocs/fourn/card.php | 4 ---- 2 files changed, 8 deletions(-) diff --git a/htdocs/comm/card.php b/htdocs/comm/card.php index 7c47c25409d..d0dd842cd7c 100644 --- a/htdocs/comm/card.php +++ b/htdocs/comm/card.php @@ -347,10 +347,6 @@ if ($id > 0) print ''; if ($action == 'editmode') { - if (empty($object->mode_reglement_id)) - { - $object->mode_reglement_id=$conf->global->MAIN_PAYMENT_MODE_DEFAULT; - } $form->form_modes_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id,$object->mode_reglement_id,'mode_reglement_id'); } else diff --git a/htdocs/fourn/card.php b/htdocs/fourn/card.php index 30c55c7b130..3e234af68cd 100644 --- a/htdocs/fourn/card.php +++ b/htdocs/fourn/card.php @@ -232,10 +232,6 @@ if ($object->fetch($id)) print ''; if ($action == 'editmode') { - if (empty($object->mode_reglement_supplier_id)) - { - $object->mode_reglement_supplier_id=$conf->global->MAIN_PAYMENT_MODE_DEFAULT; - } $form->form_modes_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id,$object->mode_reglement_supplier_id,'mode_reglement_supplier_id'); } else From 15311fb643fc0d44524ab420abc5809d56b83eb8 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Fri, 28 Nov 2014 12:41:53 +0100 Subject: [PATCH 4/9] form should not be inside table --- htdocs/accountancy/admin/importaccounts.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/accountancy/admin/importaccounts.php b/htdocs/accountancy/admin/importaccounts.php index 9e5c59f4555..6358bf353f3 100644 --- a/htdocs/accountancy/admin/importaccounts.php +++ b/htdocs/accountancy/admin/importaccounts.php @@ -120,6 +120,9 @@ if ($result) { $i = 0; print_barre_liste($langs->trans("ImportAccount"), $page, $_SERVER["PHP_SELF"], "", $sortfield, $sortorder, '', $num_lines); + print '
' . "\n"; + print ''; + print ''; print ''; print ''; @@ -132,9 +135,6 @@ if ($result) { $form = new Form($db); $htmlacc = new FormVentilation($db); - print '' . "\n"; - print ''; - $var = true; while ( $i < min($num_lines, $limit) ) { $objp = $db->fetch_object($result); From d156e1ba82217abba188ac2b645243a76a804773 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Fri, 28 Nov 2014 12:51:08 +0100 Subject: [PATCH 5/9] form should be outside table --- htdocs/accountancy/admin/journaux.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/accountancy/admin/journaux.php b/htdocs/accountancy/admin/journaux.php index f7507cda234..84c8042027a 100644 --- a/htdocs/accountancy/admin/journaux.php +++ b/htdocs/accountancy/admin/journaux.php @@ -112,8 +112,8 @@ foreach ( $list as $key ) { print ''; } -print ''; print "
' . $langs->trans("accountingaccount") . '' . $langs->trans("label") . '
\n"; +print ''; print '
'; From 9118ef7c8f3ac99b72f4b03fe7b34f9c69e85af0 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Mon, 1 Dec 2014 12:03:23 +0100 Subject: [PATCH 6/9] form should be outside table and close form was twice --- htdocs/accountancy/admin/export.php | 2 +- htdocs/accountancy/admin/index.php | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/htdocs/accountancy/admin/export.php b/htdocs/accountancy/admin/export.php index d0eef1dc2f4..a5f54d5c431 100644 --- a/htdocs/accountancy/admin/export.php +++ b/htdocs/accountancy/admin/export.php @@ -155,8 +155,8 @@ foreach ( $list as $key ) { print ''; } -print ''; print "\n"; +print ''; print '
'; diff --git a/htdocs/accountancy/admin/index.php b/htdocs/accountancy/admin/index.php index e72df6a0431..85e49028298 100644 --- a/htdocs/accountancy/admin/index.php +++ b/htdocs/accountancy/admin/index.php @@ -181,7 +181,6 @@ print ''.nl2br($langs->trans('OptionModeTrueDesc')); print "\n"; print ' '.$langs->trans('OptionModeVirtual').''; print ''.nl2br($langs->trans('OptionModeVirtualDesc'))."\n"; -print ''; print "\n"; @@ -285,10 +284,10 @@ if (! empty($conf->global->ACCOUNTING_LIST_SORT_VENTILATION_DONE)) { } print ''; -print ''; + print "\n"; print '

'; - +print ''; llxFooter(); $db->close(); \ No newline at end of file From b33612d2311ebbc3242a39319188908479096229 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Mon, 1 Dec 2014 12:09:05 +0100 Subject: [PATCH 7/9] close form should be outside button --- htdocs/accountancy/admin/journaux.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/accountancy/admin/journaux.php b/htdocs/accountancy/admin/journaux.php index 84c8042027a..d97af918f90 100644 --- a/htdocs/accountancy/admin/journaux.php +++ b/htdocs/accountancy/admin/journaux.php @@ -113,9 +113,9 @@ foreach ( $list as $key ) { } print "\n"; -print ''; print '
'; +print ''; print '
'; From d7dcd153f0d519a0e0d4c998b7810d2cde785246 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Mon, 1 Dec 2014 12:21:54 +0100 Subject: [PATCH 8/9] missing close form --- htdocs/accountancy/bookkeeping/card.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/htdocs/accountancy/bookkeeping/card.php b/htdocs/accountancy/bookkeeping/card.php index 608c62cf1d0..a24ed34e052 100644 --- a/htdocs/accountancy/bookkeeping/card.php +++ b/htdocs/accountancy/bookkeeping/card.php @@ -358,7 +358,8 @@ else print ''; print ''; } - print ""; + print ''; + print ''; } } } From e18196eac6052d1f67ffa4c2892f35572988533c Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Mon, 1 Dec 2014 16:50:27 +0100 Subject: [PATCH 9/9] to avoid undefined method --- htdocs/accountancy/class/bookkeeping.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/accountancy/class/bookkeeping.class.php b/htdocs/accountancy/class/bookkeeping.class.php index 6291790d008..9d0de035223 100644 --- a/htdocs/accountancy/class/bookkeeping.class.php +++ b/htdocs/accountancy/class/bookkeeping.class.php @@ -27,7 +27,7 @@ /** * Class to manage accountancy book keeping */ -class BookKeeping +class BookKeeping extends CommonObject { var $db; var $error;