diff --git a/htdocs/compta/tva/card.php b/htdocs/compta/tva/card.php index 4480682b091..69483d84be0 100644 --- a/htdocs/compta/tva/card.php +++ b/htdocs/compta/tva/card.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2016 Laurent Destailleur * Copyright (C) 2005-2013 Regis Houssin * Copyright (C) 2015-2017 Alexandre Spangaro + * Copyright (C) 2018 Frédéric France * * 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 @@ -255,11 +256,11 @@ if ($action == 'create') print ""; print ''.$langs->trans("DatePayment").''; - print $form->select_date($datep,"datep",'','','','add',1,1); + print $form->selectDate($datep, "datep", '', '', '', 'add', 1, 1); print ''; print ''.$form->textwithpicto($langs->trans("PeriodEndDate"), $langs->trans("LastDayTaxIsRelatedTo")).''; - print $form->select_date($datev,"datev",'','','','add',1,1); + print $form->selectDate($datev, "datev", '', '', '', 'add', 1, 1); print ''; // Label diff --git a/htdocs/compta/tva/clients.php b/htdocs/compta/tva/clients.php index ae95d71ca9c..74a08d0d142 100644 --- a/htdocs/compta/tva/clients.php +++ b/htdocs/compta/tva/clients.php @@ -3,7 +3,8 @@ * Copyright (C) 2004 Eric Seigne * Copyright (C) 2004-2018 Laurent Destailleur * Copyright (C) 2006 Yannick Warnier - * Copyright (C) 2014 Ferran Marcet + * Copyright (C) 2014 Ferran Marcet + * Copyright (C) 2018 Frédéric France * * 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 @@ -136,18 +137,22 @@ if ($modetax == 1) $calcmode=$langs->trans('OptionVATDebitOption'); if ($modetax == 2) $calcmode=$langs->trans('OptionPaymentForProductAndServices'); $calcmode.='
('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')'; // Set period -$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1); -$prevyear=$year_start; $prevquarter=$q; +$period=$form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0); +$prevyear=$year_start; +$prevquarter=$q; if ($prevquarter > 1) { $prevquarter--; } else { - $prevquarter=4; $prevyear--; + $prevquarter=4; + $prevyear--; } -$nextyear=$year_start; $nextquarter=$q; +$nextyear=$year_start; +$nextquarter=$q; if ($nextquarter < 4) { $nextquarter++; } else { - $nextquarter=1; $nextyear++; + $nextquarter=1; + $nextyear++; } $builddate=dol_now(); diff --git a/htdocs/compta/tva/index.php b/htdocs/compta/tva/index.php index 7c4912411f6..8e4fccf4168 100644 --- a/htdocs/compta/tva/index.php +++ b/htdocs/compta/tva/index.php @@ -4,6 +4,7 @@ * Copyright (C) 2004-2018 Laurent Destailleur * Copyright (C) 2005-2009 Regis Houssin * Copyright (C) 2014 Ferran Marcet + * Copyright (C) 2018 Frédéric France * * 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 @@ -217,7 +218,7 @@ if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) { } if (! empty($conf->global->MAIN_MODULE_ACCOUNTING)) $description.='
'.$langs->trans("ThisIsAnEstimatedValue"); -$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1); +$period=$form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0); $builddate=dol_now(); diff --git a/htdocs/compta/tva/quadri_detail.php b/htdocs/compta/tva/quadri_detail.php index e2c7cc5d793..ff3e3ce127d 100644 --- a/htdocs/compta/tva/quadri_detail.php +++ b/htdocs/compta/tva/quadri_detail.php @@ -1,9 +1,10 @@ - * Copyright (C) 2004 Eric Seigne - * Copyright (C) 2004-2013 Laurent Destailleur - * Copyright (C) 2006-2007, 2015 Yannick Warnier - * Copyright (C) 2014 Ferran Marcet +/* Copyright (C) 2001-2003 Rodolphe Quiedeville + * Copyright (C) 2004 Eric Seigne + * Copyright (C) 2004-2013 Laurent Destailleur + * Copyright (C) 2006-2015 Yannick Warnier + * Copyright (C) 2014 Ferran Marcet + * Copyright (C) 2018 Frédéric France * * 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 @@ -135,18 +136,21 @@ if ($modetax == 1) $calcmode=$langs->trans('OptionVATDebitOption'); if ($modetax == 2) $calcmode=$langs->trans('OptionPaymentForProductAndServices'); $calcmode.='
('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')'; // Set period -$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1); +$period=$form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0); $prevyear=$year_start; $prevquarter=$q; if ($prevquarter > 1) { $prevquarter--; } else { - $prevquarter=4; $prevyear--; + $prevquarter=4; + $prevyear--; } -$nextyear=$year_start; $nextquarter=$q; +$nextyear=$year_start; +$nextquarter=$q; if ($nextquarter < 4) { $nextquarter++; } else { - $nextquarter=1; $nextyear++; + $nextquarter=1; + $nextyear++; } $description.=$fsearch; $builddate=dol_now(); diff --git a/htdocs/projet/activity/perday.php b/htdocs/projet/activity/perday.php index f4caef2b5ad..c3351a5efff 100644 --- a/htdocs/projet/activity/perday.php +++ b/htdocs/projet/activity/perday.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2016 Laurent Destailleur * Copyright (C) 2005-2010 Regis Houssin * Copyright (C) 2010 François Legastelois + * Copyright (C) 2018 Frédéric France * * 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 @@ -366,7 +367,7 @@ $nav.=dol_print_date(dol_mktime(0,0,0,$month,$day,$year),"%A").' '; $nav.=" ".dol_print_date(dol_mktime(0,0,0,$month,$day,$year),"day")." \n"; $nav.=''.img_next($langs->trans("Next"))."\n"; $nav.="   (".$langs->trans("Today").")"; -$nav.='
'.$form->select_date(-1,'',0,0,2,"addtime",1,0,1).' '; +$nav.='
'.$form->selectDate(-1, '', 0, 0, 2, "addtime", 1, 0).' '; $nav.=' '; $picto='calendarweek'; diff --git a/htdocs/projet/activity/perweek.php b/htdocs/projet/activity/perweek.php index 200851b6307..fdf7b9ea187 100644 --- a/htdocs/projet/activity/perweek.php +++ b/htdocs/projet/activity/perweek.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2015 Laurent Destailleur * Copyright (C) 2005-2010 Regis Houssin * Copyright (C) 2010 François Legastelois + * Copyright (C) 2018 Frédéric France * * 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 @@ -369,7 +370,7 @@ $nav ='".dol_print_date(dol_mktime(0,0,0,$first_month,$first_day,$first_year),"%Y").", ".$langs->trans("WeekShort")." ".$week." \n"; $nav.=''.img_next($langs->trans("Next"))."\n"; $nav.="   (".$langs->trans("Today").")"; -$nav.='
'.$form->select_date(-1,'',0,0,2,"addtime",1,0,1).' '; +$nav.='
'.$form->selectDate(-1, '', 0, 0, 2, "addtime", 1, 0).' '; $nav.=' '; $picto='calendarweek';