From e5ef45562883733fcb7ae5c65533c310105eb73f Mon Sep 17 00:00:00 2001 From: Florian HENRY Date: Mon, 11 Jan 2021 19:46:08 +0100 Subject: [PATCH] fix: date auto fill date paiement tax --- htdocs/compta/paiement_charge.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/compta/paiement_charge.php b/htdocs/compta/paiement_charge.php index 509e20f3613..a1c3a246829 100644 --- a/htdocs/compta/paiement_charge.php +++ b/htdocs/compta/paiement_charge.php @@ -224,8 +224,8 @@ if ($action == 'create') print ''.$langs->trans("Date").''; $datepaye = dol_mktime(12, 0, 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]); - $datepayment = empty($conf->global->MAIN_AUTOFILL_DATE) ? (empty($_POST["remonth"]) ?-1 : $datepaye) : 0; - print $form->selectDate($datepayment, '', '', '', '', "add_payment", 1, 1); + $datepaye = ($datepaye == '' ? (empty($conf->global->MAIN_AUTOFILL_DATE) ?-1 : '') : $datepaye); + print $form->selectDate($datepaye, '', '', '', '', "add_payment", 1, 1); print ""; print '';