From 19b275f2d16207db6d415ec0c52021c273f733b8 Mon Sep 17 00:00:00 2001 From: Alexandre SPANGARO Date: Sun, 26 May 2019 22:33:35 +0200 Subject: [PATCH] Fix bankline cat with various payment --- htdocs/compta/bank/class/paymentvarious.class.php | 2 +- htdocs/compta/bank/various_payment/card.php | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/htdocs/compta/bank/class/paymentvarious.class.php b/htdocs/compta/bank/class/paymentvarious.class.php index fad76c45d1b..ebdf085e18c 100644 --- a/htdocs/compta/bank/class/paymentvarious.class.php +++ b/htdocs/compta/bank/class/paymentvarious.class.php @@ -421,7 +421,7 @@ class PaymentVarious extends CommonObject $this->label, $sign * abs($this->amount), $this->num_payment, - ($category_transaction > 0 ? $category_transaction : 0), + ($this->category_transaction > 0 ? $this->category_transaction : 0), $user ); diff --git a/htdocs/compta/bank/various_payment/card.php b/htdocs/compta/bank/various_payment/card.php index 176fea7e8db..5b4ae6c8b4a 100644 --- a/htdocs/compta/bank/various_payment/card.php +++ b/htdocs/compta/bank/various_payment/card.php @@ -53,7 +53,7 @@ $paymenttype = GETPOST("paymenttype", "int"); $accountancy_code = GETPOST("accountancy_code", "alpha"); $subledger_account = GETPOST("subledger_account", "alpha"); $projectid = (GETPOST('projectid', 'int') ? GETPOST('projectid', 'int') : GETPOST('fk_project', 'int')); -$cat1 = GETPOST("cat1", 'alpha'); +$category_transaction = GETPOST("category_transaction", 'alpha'); // Security check $socid = GETPOST("socid", "int"); @@ -112,7 +112,7 @@ if (empty($reshook)) $object->type_payment=GETPOST("paymenttype", 'int') > 0 ? GETPOST("paymenttype", "int") : 0; $object->num_payment=GETPOST("num_payment", 'alpha'); $object->fk_user_author=$user->id; - $object->category_transaction=GETPOST("cat1", 'alpha'); + $object->category_transaction=GETPOST("category_transaction", 'alpha'); $object->accountancy_code=GETPOST("accountancy_code") > 0 ? GETPOST("accountancy_code", "alpha") : ""; $object->subledger_account=GETPOST("subledger_account") > 0 ? GETPOST("subledger_account", "alpha") : ""; @@ -328,7 +328,7 @@ if ($action == 'create') if (is_array($options) && count($options)) { print ''.$langs->trans("Rubrique").''; - print Form::selectarray('cat1', $options, GETPOST('cat1'), 1); + print Form::selectarray('category_transaction', $options, GETPOST('category_transaction'), 1); print ''; }