From 01a0e48b955537f537d3fb8b6abe6a7bf262bb88 Mon Sep 17 00:00:00 2001 From: atm-steve Date: Tue, 21 Jun 2022 10:06:26 +0200 Subject: [PATCH] add conf and set default date to yes --- htdocs/core/tpl/objectline_create.tpl.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/htdocs/core/tpl/objectline_create.tpl.php b/htdocs/core/tpl/objectline_create.tpl.php index 335754a8168..37cc7f94ce8 100644 --- a/htdocs/core/tpl/objectline_create.tpl.php +++ b/htdocs/core/tpl/objectline_create.tpl.php @@ -348,6 +348,10 @@ if ($nolinesbefore) { if (!empty($conf->service->enabled) && ($object->element == 'facturerec' || $object->element == 'invoice_supplier_rec')) { echo '

'; echo $langs->trans('AutoFillDateFrom').' '; + if ($conf->global->INVOICE_REC_DATE_TO_YES) { + $line->date_start_fill = 1; + $line->date_end_fill = 1; + } echo $form->selectyesno('date_start_fill', $line->date_start_fill, 1); echo ' - '; echo $langs->trans('AutoFillDateTo').' ';