Merge remote-tracking branch 'Upstream/develop' into 4.0-p2

This commit is contained in:
aspangaro 2016-03-22 12:58:40 +01:00
commit 53f2a7a0ac
104 changed files with 314 additions and 311 deletions

View File

@ -24,7 +24,9 @@ Dolibarr 4.0 should be compatible with PHP 7 but more feedbacks are still expect
Following changes may create regression for some external modules, but were necessary to make Following changes may create regression for some external modules, but were necessary to make
Dolibarr better: Dolibarr better:
- Method select_type_comptes_financiers() has been renamed into selectTypeOfBankAccount() - Method FormBank::select_type_comptes_financiers() has been renamed into FormBank::selectTypeOfBankAccount()
- Method Form::form_date() has been renamed into Form::formDate()
- Method Form::select_date() has been renamed into Form::selectDate()

View File

@ -162,12 +162,12 @@ if ($action == 'create') {
// Date start // Date start
print '<tr><td class="fieldrequired">' . $langs->trans("DateStart") . '</td><td>'; print '<tr><td class="fieldrequired">' . $langs->trans("DateStart") . '</td><td>';
print Form::select_date(($date_start ? $date_start : ''), 'fiscalyear'); print Form::selectDate(($date_start ? $date_start : ''), 'fiscalyear');
print '</td></tr>'; print '</td></tr>';
// Date end // Date end
print '<tr><td class="fieldrequired">' . $langs->trans("DateEnd") . '</td><td>'; print '<tr><td class="fieldrequired">' . $langs->trans("DateEnd") . '</td><td>';
print Form::select_date(($date_end ? $date_end : - 1), 'fiscalyearend'); print Form::selectDate(($date_end ? $date_end : - 1), 'fiscalyearend');
print '</td></tr>'; print '</td></tr>';
// Statut // Statut
@ -216,12 +216,12 @@ if ($action == 'create') {
// Date start // Date start
print '<tr><td class="fieldrequired">' . $langs->trans("DateStart") . '</td><td>'; print '<tr><td class="fieldrequired">' . $langs->trans("DateStart") . '</td><td>';
print Form::select_date($object->date_start ? $object->date_start : - 1, 'fiscalyear'); print Form::selectDate($object->date_start ? $object->date_start : - 1, 'fiscalyear');
print '</td></tr>'; print '</td></tr>';
// Date end // Date end
print '<tr><td class="fieldrequired">' . $langs->trans("DateEnd") . '</td><td>'; print '<tr><td class="fieldrequired">' . $langs->trans("DateEnd") . '</td><td>';
print Form::select_date($object->date_end ? $object->date_end : - 1, 'fiscalyearend'); print Form::selectDate($object->date_end ? $object->date_end : - 1, 'fiscalyearend');
print '</td></tr>'; print '</td></tr>';
// Statut // Statut

View File

@ -161,9 +161,9 @@ else {
print '<div class="liste_titre">'; print '<div class="liste_titre">';
print $langs->trans('DateStart') . ': '; print $langs->trans('DateStart') . ': ';
print Form::select_date($search_date_start, 'date_start', 0, 0, 1); print Form::selectDate($search_date_start, 'date_start', 0, 0, 1);
print $langs->trans('DateEnd') . ': '; print $langs->trans('DateEnd') . ': ';
print Form::select_date($search_date_end, 'date_end', 0, 0, 1); print Form::selectDate($search_date_end, 'date_end', 0, 0, 1);
print '</div>'; print '</div>';
print '<table class="noborder" width="100%">'; print '<table class="noborder" width="100%">';

View File

@ -248,7 +248,7 @@ if ($action == 'create') {
print '<tr>'; print '<tr>';
print '<td>' . $langs->trans("Docdate") . '</td>'; print '<td>' . $langs->trans("Docdate") . '</td>';
print '<td>'; print '<td>';
print Form::select_date('', 'doc_date', '', '', '', "create_mvt", 1, 1); print Form::selectDate('', 'doc_date', '', '', '', "create_mvt", 1, 1);
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';

View File

@ -394,10 +394,10 @@ else {
print '<td><input type="text" name="search_mvt_num" size="6" value="' . $search_mvt_num . '"></td>'; print '<td><input type="text" name="search_mvt_num" size="6" value="' . $search_mvt_num . '"></td>';
print '<td class="liste_titre">'; print '<td class="liste_titre">';
print $langs->trans('From') . ': '; print $langs->trans('From') . ': ';
print Form::select_date($search_date_start, 'date_start', 0, 0, 1); print Form::selectDate($search_date_start, 'date_start', 0, 0, 1);
print '<br>'; print '<br>';
print $langs->trans('To') . ': '; print $langs->trans('To') . ': ';
print Form::select_date($search_date_end, 'date_end', 0, 0, 1); print Form::selectDate($search_date_end, 'date_end', 0, 0, 1);
print '</td>'; print '</td>';
print '<td><input type="text" name="search_doc_ref" size="8" value="' . $search_doc_ref . '"></td>'; print '<td><input type="text" name="search_doc_ref" size="8" value="' . $search_doc_ref . '"></td>';
print '<td>'; print '<td>';

View File

@ -176,9 +176,9 @@ print_barre_liste($langs->trans("Bookkeeping") . ' ' . dol_print_date($search_da
print '<form method="GET" id="searchFormList" action="' . $_SERVER["PHP_SELF"] . '">'; print '<form method="GET" id="searchFormList" action="' . $_SERVER["PHP_SELF"] . '">';
print '<div class="liste_titre">'; print '<div class="liste_titre">';
print $langs->trans('DateStart') . ': '; print $langs->trans('DateStart') . ': ';
print Form::select_date($search_date_start, 'date_start'); print Form::selectDate($search_date_start, 'date_start');
print $langs->trans('DateEnd') . ': '; print $langs->trans('DateEnd') . ': ';
print Form::select_date($search_date_end, 'date_end'); print Form::selectDate($search_date_end, 'date_end');
print '</div>'; print '</div>';
print '<div class="liste_titre">'; print '<div class="liste_titre">';
print $langs->trans('From') . ' ' . $langs->trans('AccountAccounting') . ': '; print $langs->trans('From') . ' ' . $langs->trans('AccountAccounting') . ': ';
@ -220,7 +220,7 @@ print '<input type="text" size=7 class="flat" name="search_doc_type" value="' .
print '</td>'; print '</td>';
print '<td class="liste_titre">'; print '<td class="liste_titre">';
print Form::select_date($search_doc_date, 'doc_date', 0, 0, 1); print Form::selectDate($search_doc_date, 'doc_date', 0, 0, 1);
print '</td>'; print '</td>';
print '<td class="liste_titre">'; print '<td class="liste_titre">';

View File

@ -541,7 +541,7 @@ else {
$nom = $langs->trans("FinanceJournal") . ' - ' . $bank_code_journal->getNomUrl(1); $nom = $langs->trans("FinanceJournal") . ' - ' . $bank_code_journal->getNomUrl(1);
$builddate = time(); $builddate = time();
$description = $langs->trans("DescFinanceJournal") . '<br>'; $description = $langs->trans("DescFinanceJournal") . '<br>';
$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, 1) . ' - ' . Form::selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0, 1);
$varlink = 'id_account=' . $id_bank_account; $varlink = 'id_account=' . $id_bank_account;
report_header($nom, $nomlink, $period, $periodlink, $description, $builddate, $exportlink, array ( report_header($nom, $nomlink, $period, $periodlink, $description, $builddate, $exportlink, array (

View File

@ -403,7 +403,7 @@ if ($action == 'export_csv') {
$description .= $langs->trans("DepositsAreIncluded"); $description .= $langs->trans("DepositsAreIncluded");
} }
$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, 1) . ' - ' . Form::selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0, 1);
report_header($nom, $nomlink, $period, $periodlink, $description, $builddate, $exportlink, array ( report_header($nom, $nomlink, $period, $periodlink, $description, $builddate, $exportlink, array (
'action' => '' 'action' => ''
)); ));

View File

@ -418,7 +418,7 @@ if ($action == 'export_csv') {
$description .= $langs->trans("DepositsAreNotIncluded"); $description .= $langs->trans("DepositsAreNotIncluded");
else else
$description .= $langs->trans("DepositsAreIncluded"); $description .= $langs->trans("DepositsAreIncluded");
$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, 1) . ' - ' . Form::selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0, 1);
report_header($nom, $nomlink, $period, $periodlink, $description, $builddate, $exportlink, array ( report_header($nom, $nomlink, $period, $periodlink, $description, $builddate, $exportlink, array (
'action' => '' 'action' => ''
)); ));

View File

@ -900,7 +900,7 @@ else
// Birthday // Birthday
print "<tr><td>".$langs->trans("Birthday")."</td><td>\n"; print "<tr><td>".$langs->trans("Birthday")."</td><td>\n";
Form::select_date(($object->birth ? $object->birth : -1),'birth','','',1,'formsoc'); Form::selectDate(($object->birth ? $object->birth : -1),'birth','','',1,'formsoc');
print "</td></tr>\n"; print "</td></tr>\n";
// Public profil // Public profil
@ -1154,7 +1154,7 @@ else
// Birthday // Birthday
print "<tr><td>".$langs->trans("Birthday")."</td><td>\n"; print "<tr><td>".$langs->trans("Birthday")."</td><td>\n";
Form::select_date(($object->birth ? $object->birth : -1),'birth','','',1,'formsoc'); Form::selectDate(($object->birth ? $object->birth : -1),'birth','','',1,'formsoc');
print "</td></tr>\n"; print "</td></tr>\n";
// Public profil // Public profil

View File

@ -974,7 +974,7 @@ if ($rowid > 0)
$datefrom=$object->datevalid; $datefrom=$object->datevalid;
} }
} }
print Form::select_date($datefrom,'','','','',"cotisation",1,1,1); print Form::selectDate($datefrom,'','','','',"cotisation",1,1,1);
print "</td></tr>"; print "</td></tr>";
// Date end subscription // Date end subscription
@ -987,7 +987,7 @@ if ($rowid > 0)
$dateto=-1; // By default, no date is suggested $dateto=-1; // By default, no date is suggested
} }
print '<tr><td>'.$langs->trans("DateEndSubscription").'</td><td>'; print '<tr><td>'.$langs->trans("DateEndSubscription").'</td><td>';
print Form::select_date($dateto,'end','','','',"cotisation",1,0,1); print Form::selectDate($dateto,'end','','','',"cotisation",1,0,1);
print "</td></tr>"; print "</td></tr>";
if ($adht->cotisation) if ($adht->cotisation)
@ -1088,7 +1088,7 @@ if ($rowid > 0)
// Date of payment // Date of payment
print '<tr class="bankswitchclass"><td class="fieldrequired">'.$langs->trans("DatePayment").'</td><td>'; print '<tr class="bankswitchclass"><td class="fieldrequired">'.$langs->trans("DatePayment").'</td><td>';
print Form::select_date(isset($paymentdate)?$paymentdate:-1,'payment',0,0,1,'cotisation',1,1,1); print Form::selectDate(isset($paymentdate)?$paymentdate:-1,'payment',0,0,1,'cotisation',1,1,1);
print "</td></tr>\n"; print "</td></tr>\n";
print '<tr class="bankswitchclass2"><td>'.$langs->trans('Numero'); print '<tr class="bankswitchclass2"><td>'.$langs->trans('Numero');

View File

@ -207,13 +207,13 @@ if ($user->rights->adherent->cotisation->creer && $action == 'edit')
// Date start subscription // Date start subscription
print '<tr><td>'.$langs->trans("DateSubscription").'</td><td class="valeur" colspan="2">'; print '<tr><td>'.$langs->trans("DateSubscription").'</td><td class="valeur" colspan="2">';
Form::select_date($subscription->dateh,'datesub',1,1,0,'update',1); Form::selectDate($subscription->dateh,'datesub',1,1,0,'update',1);
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';
// Date end subscription // Date end subscription
print '<tr><td>'.$langs->trans("DateEndSubscription").'</td><td class="valeur" colspan="2">'; print '<tr><td>'.$langs->trans("DateEndSubscription").'</td><td class="valeur" colspan="2">';
Form::select_date($subscription->datef,'datesubend',0,0,0,'update',1); Form::selectDate($subscription->datef,'datesubend',0,0,0,'update',1);
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';

View File

@ -198,7 +198,7 @@ if ($result)
// Lignes des champs de filtres // Lignes des champs de filtres
print '<tr class="liste_titre">'; print '<tr class="liste_titre">';
print '<td class="liste_titre" width="15%">'.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).'</td>'; print '<td class="liste_titre" width="15%">'.Form::selectDate($date_start,'date_start',0,0,0,'',1,0,1).Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1).'</td>';
print '<td align="left" class="liste_titre">'; print '<td align="left" class="liste_titre">';
print '<input class="flat" type="text" size="10" name="search_code" value="'.$search_code.'">'; print '<input class="flat" type="text" size="10" name="search_code" value="'.$search_code.'">';

View File

@ -43,10 +43,10 @@ $langs->load("cashdesk");
<tr> <tr>
<!-- Affichage de la reference et de la designation --> <!-- Affichage de la reference et de la designation -->
<td><input class="texte_ref" type="text" id ="txtRef" name="txtRef" value="<?php echo $obj_facturation->ref() ?>" <td><input class="texte_ref" type="text" id ="txtRef" name="txtRef" value="<?php echo $obj_facturation->ref() ?>"
onchange="javascript: setSource('REF');" onchange="setSource('REF');"
onkeyup="javascript: verifResultat('resultats_dhtml', this.value, <?php echo (isset($conf->global->BARCODE_USE_SEARCH_TO_SELECT) ? (int) $conf->global->BARCODE_USE_SEARCH_TO_SELECT : 1) ?>);" onkeyup="verifResultat('resultats_dhtml', this.value, <?php echo (isset($conf->global->BARCODE_USE_SEARCH_TO_SELECT) ? (int) $conf->global->BARCODE_USE_SEARCH_TO_SELECT : 1) ?>);"
onfocus="javascript: this.select(); verifResultat('resultats_dhtml', this.value, <?php echo (isset($conf->global->BARCODE_USE_SEARCH_TO_SELECT) ? (int) $conf->global->BARCODE_USE_SEARCH_TO_SELECT : 1) ?>);" onfocus="this.select(); verifResultat('resultats_dhtml', this.value, <?php echo (isset($conf->global->BARCODE_USE_SEARCH_TO_SELECT) ? (int) $conf->global->BARCODE_USE_SEARCH_TO_SELECT : 1) ?>);"
onBlur="javascript: document.getElementById('resultats_dhtml').innerHTML = '';"/> onBlur="document.getElementById('resultats_dhtml').innerHTML = '';"/>
</td> </td>
<td class="select_design"> <td class="select_design">
<?php /* <?php /*
@ -60,7 +60,7 @@ $langs->load("cashdesk");
*/ */
?> ?>
<select id="selProduit" name="selProduit" onchange="javascript: setSource('LISTE');"> <select id="selProduit" name="selProduit" onchange="setSource('LISTE');">
<?php <?php
print '<option value="0">'.$top_liste_produits.'</option>'."\n"; print '<option value="0">'.$top_liste_produits.'</option>'."\n";
@ -93,7 +93,7 @@ $langs->load("cashdesk");
</table> </table>
</form> </form>
<form id="frmQte" class="formulaire1" method="post" action="facturation_verif.php?action=ajout_article" onsubmit ="javascript: return verifSaisie();"> <form id="frmQte" class="formulaire1" method="post" action="facturation_verif.php?action=ajout_article" onsubmit ="return verifSaisie();">
<input type="hidden" name="token" value="<?php echo $_SESSION['newtoken']; ?>" /> <input type="hidden" name="token" value="<?php echo $_SESSION['newtoken']; ?>" />
<table> <table>
<tr><th><?php echo $langs->trans("Qty"); ?></th> <tr><th><?php echo $langs->trans("Qty"); ?></th>
@ -106,7 +106,7 @@ $langs->load("cashdesk");
<th><?php echo $langs->trans("VATRate"); ?></th> <th><?php echo $langs->trans("VATRate"); ?></th>
</tr> </tr>
<tr> <tr>
<td><input class="texte1" type="text" id="txtQte" name="txtQte" value="1" onkeyup="javascript: modif();" onfocus="javascript: this.select();" /> <td><input class="texte1" type="text" id="txtQte" name="txtQte" value="1" onkeyup="modif();" onfocus="this.select();" />
<?php print genkeypad("txtQte", "frmQte");?> <?php print genkeypad("txtQte", "frmQte");?>
</td> </td>
<!-- Affichage du stock pour l'article courant --> <!-- Affichage du stock pour l'article courant -->
@ -115,10 +115,10 @@ $langs->load("cashdesk");
</td> </td>
<!-- Show unit price --> <!-- Show unit price -->
<?php // TODO Remove the disabled and use this value when adding product into cart ?> <?php // TODO Remove the disabled and use this value when adding product into cart ?>
<td><input class="texte1_off" type="text" name="txtPrixUnit" value="<?php echo price2num($obj_facturation->prix(), 'MU'); ?>" onchange="javascript: modif();" disabled /></td> <td><input class="texte1_off" type="text" name="txtPrixUnit" value="<?php echo price2num($obj_facturation->prix(), 'MU'); ?>" onchange="modif();" disabled /></td>
<td></td> <td></td>
<!-- Choix de la remise --> <!-- Choix de la remise -->
<td><input class="texte1" type="text" id="txtRemise" name="txtRemise" value="0" onkeyup="javascript: modif();" onfocus="javascript: this.select();"/> <td><input class="texte1" type="text" id="txtRemise" name="txtRemise" value="0" onkeyup="modif();" onfocus="this.select();"/>
<?php print genkeypad("txtRemise", "frmQte");?> <?php print genkeypad("txtRemise", "frmQte");?>
</td> </td>
<!-- Affichage du total HT --> <!-- Affichage du total HT -->
@ -126,7 +126,7 @@ $langs->load("cashdesk");
<!-- Choix du taux de TVA --> <!-- Choix du taux de TVA -->
<td class="select_tva"> <td class="select_tva">
<?php //var_dump($tab_tva); ?> <?php //var_dump($tab_tva); ?>
<select name="selTva" onchange="javascript: modif();" > <select name="selTva" onchange="modif();" >
<?php <?php
$tva_tx = $obj_facturation->tva(); // Try to get a previously entered VAT rowid. First time, this will return empty. $tva_tx = $obj_facturation->tva(); // Try to get a previously entered VAT rowid. First time, this will return empty.
@ -151,7 +151,7 @@ $langs->load("cashdesk");
</fieldset> </fieldset>
<!-- ========================= Cadre "Amount" ============================= --> <!-- ========================= Cadre "Amount" ============================= -->
<form id="frmDifference" class="formulaire1" method="post" onsubmit="javascript: return verifReglement()" action="validation_verif.php?action=valide_achat"> <form id="frmDifference" class="formulaire1" method="post" onsubmit="return verifReglement()" action="validation_verif.php?action=valide_achat">
<input type="hidden" name="hdnChoix" value="" /> <input type="hidden" name="hdnChoix" value="" />
<input type="hidden" name="token" value="<?php echo $_SESSION['newtoken']; ?>" /> <input type="hidden" name="token" value="<?php echo $_SESSION['newtoken']; ?>" />
<fieldset class="cadre_facturation"><legend class="titre1"><?php echo $langs->trans("Amount"); ?></legend> <fieldset class="cadre_facturation"><legend class="titre1"><?php echo $langs->trans("Amount"); ?></legend>
@ -161,7 +161,7 @@ $langs->load("cashdesk");
<!-- Affichage du montant du --> <!-- Affichage du montant du -->
<td><input class="texte2_off" type="text" name="txtDu" value="<?php echo price2num($obj_facturation->prixTotalTtc(), 'MT'); ?>" disabled /></td> <td><input class="texte2_off" type="text" name="txtDu" value="<?php echo price2num($obj_facturation->prixTotalTtc(), 'MT'); ?>" disabled /></td>
<!-- Choix du montant encaisse --> <!-- Choix du montant encaisse -->
<td><input class="texte2" type="text" id="txtEncaisse" name="txtEncaisse" value="" onkeyup="javascript: verifDifference();" onfocus="javascript: this.select();" /> <td><input class="texte2" type="text" id="txtEncaisse" name="txtEncaisse" value="" onkeyup="verifDifference();" onfocus="this.select();" />
<?php print genkeypad("txtEncaisse", "frmDifference");?> <?php print genkeypad("txtEncaisse", "frmDifference");?>
</td> </td>
<!-- Affichage du montant rendu --> <!-- Affichage du montant rendu -->
@ -201,10 +201,10 @@ $langs->load("cashdesk");
print '<div class="clearboth">'; print '<div class="clearboth">';
print '<div class="inline-block" style="margin: 6px;">'; print '<div class="inline-block" style="margin: 6px;">';
?> ?>
<input class="button bouton_mode_reglement" type="submit" name="btnModeReglement" value="<?php echo $langs->trans("Reported"); ?>" onclick="javascript: verifClic('DIF');" /> <input class="button bouton_mode_reglement" type="submit" name="btnModeReglement" value="<?php echo $langs->trans("Reported"); ?>" onclick="verifClic('DIF');" />
<?php <?php
print $langs->trans("DateEcheance").' :'; print $langs->trans("DateEcheance").' :';
print Form::select_date(-1,'txtDatePaiement',0,0,0,'paymentmode',1,0,1); print Form::selectDate(-1,'txtDatePaiement',0,0,0,'paymentmode',1,0,1);
print '</div>'; print '</div>';
?> ?>
</div> </div>

View File

@ -665,9 +665,9 @@ if ($action == 'create')
$datep=($datep?$datep:$object->datep); $datep=($datep?$datep:$object->datep);
if (GETPOST('datep','int',1)) $datep=dol_stringtotime(GETPOST('datep','int',1),0); if (GETPOST('datep','int',1)) $datep=dol_stringtotime(GETPOST('datep','int',1),0);
print '<tr><td width="30%" class="nowrap"><span class="fieldrequired">'.$langs->trans("DateActionStart").'</span></td><td>'; print '<tr><td width="30%" class="nowrap"><span class="fieldrequired">'.$langs->trans("DateActionStart").'</span></td><td>';
if (GETPOST("afaire") == 1) Form::select_date($datep,'ap',1,1,0,"action",1,1,0,0,'fulldayend'); if (GETPOST("afaire") == 1) Form::selectDate($datep,'ap',1,1,0,"action",1,1,0,0,'fulldayend');
else if (GETPOST("afaire") == 2) Form::select_date($datep,'ap',1,1,1,"action",1,1,0,0,'fulldayend'); else if (GETPOST("afaire") == 2) Form::selectDate($datep,'ap',1,1,1,"action",1,1,0,0,'fulldayend');
else Form::select_date($datep,'ap',1,1,1,"action",1,1,0,0,'fulldaystart'); else Form::selectDate($datep,'ap',1,1,1,"action",1,1,0,0,'fulldaystart');
print '</td></tr>'; print '</td></tr>';
// Date end // Date end
@ -678,9 +678,9 @@ if ($action == 'create')
$datef=dol_time_plus_duree($datep, $conf->global->AGENDA_AUTOSET_END_DATE_WITH_DELTA_HOURS, 'h'); $datef=dol_time_plus_duree($datep, $conf->global->AGENDA_AUTOSET_END_DATE_WITH_DELTA_HOURS, 'h');
} }
print '<tr><td><span id="dateend"'.(GETPOST("actioncode") == 'AC_RDV'?' class="fieldrequired"':'').'>'.$langs->trans("DateActionEnd").'</span></td><td>'; print '<tr><td><span id="dateend"'.(GETPOST("actioncode") == 'AC_RDV'?' class="fieldrequired"':'').'>'.$langs->trans("DateActionEnd").'</span></td><td>';
if (GETPOST("afaire") == 1) Form::select_date($datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); if (GETPOST("afaire") == 1) Form::selectDate($datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend');
else if (GETPOST("afaire") == 2) Form::select_date($datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); else if (GETPOST("afaire") == 2) Form::selectDate($datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend');
else Form::select_date($datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); else Form::selectDate($datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend');
print '</td></tr>'; print '</td></tr>';
// Status // Status
@ -955,16 +955,16 @@ if ($id > 0)
// Date start // Date start
print '<tr><td class="nowrap"><span class="fieldrequired">'.$langs->trans("DateActionStart").'</span></td><td colspan="3">'; print '<tr><td class="nowrap"><span class="fieldrequired">'.$langs->trans("DateActionStart").'</span></td><td colspan="3">';
if (GETPOST("afaire") == 1) Form::select_date($datep?$datep:$object->datep,'ap',1,1,0,"action",1,1,0,0,'fulldaystart'); if (GETPOST("afaire") == 1) Form::selectDate($datep?$datep:$object->datep,'ap',1,1,0,"action",1,1,0,0,'fulldaystart');
else if (GETPOST("afaire") == 2) Form::select_date($datep?$datep:$object->datep,'ap',1,1,1,"action",1,1,0,0,'fulldaystart'); else if (GETPOST("afaire") == 2) Form::selectDate($datep?$datep:$object->datep,'ap',1,1,1,"action",1,1,0,0,'fulldaystart');
else Form::select_date($datep?$datep:$object->datep,'ap',1,1,1,"action",1,1,0,0,'fulldaystart'); else Form::selectDate($datep?$datep:$object->datep,'ap',1,1,1,"action",1,1,0,0,'fulldaystart');
print '</td></tr>'; print '</td></tr>';
// Date end // Date end
print '<tr><td>'.$langs->trans("DateActionEnd").'</td><td colspan="3">'; print '<tr><td>'.$langs->trans("DateActionEnd").'</td><td colspan="3">';
if (GETPOST("afaire") == 1) Form::select_date($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); if (GETPOST("afaire") == 1) Form::selectDate($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend');
else if (GETPOST("afaire") == 2) Form::select_date($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); else if (GETPOST("afaire") == 2) Form::selectDate($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend');
//else Form::select_date($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend','ap'); //else Form::selectDate($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend','ap');
else Form::select_date($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend'); else Form::selectDate($datef?$datef:$object->datef,'p2',1,1,1,"action",1,1,0,0,'fulldayend');
print '</td></tr>'; print '</td></tr>';
$userepeatevent=0; // Dev in progress $userepeatevent=0; // Dev in progress

View File

@ -142,7 +142,7 @@ $form=new Form($db);
$userstatic=new User($db); $userstatic=new User($db);
$nav=''; $nav='';
$nav.=Form::select_date($dateselect, 'dateselect', 0, 0, 1, '', 1, 0, 1); $nav.=Form::selectDate($dateselect, 'dateselect', 0, 0, 1, '', 1, 0, 1);
$nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">'; $nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">';
$now=dol_now(); $now=dol_now();
@ -320,10 +320,10 @@ if ($resql)
//print '<td class="liste_titre"><input type="text" name="search_type" value="'.$search_type.'"></td>'; //print '<td class="liste_titre"><input type="text" name="search_type" value="'.$search_type.'"></td>';
} }
print '<td class="liste_titre" align="center">'; print '<td class="liste_titre" align="center">';
print Form::select_date($datestart, 'datestart', 0, 0, 1, '', 1, 0, 1); print Form::selectDate($datestart, 'datestart', 0, 0, 1, '', 1, 0, 1);
print '</td>'; print '</td>';
print '<td class="liste_titre" align="center">'; print '<td class="liste_titre" align="center">';
print Form::select_date($dateend, 'dateend', 0, 0, 1, '', 1, 0, 1); print Form::selectDate($dateend, 'dateend', 0, 0, 1, '', 1, 0, 1);
print '</td>'; print '</td>';
print '<td class="liste_titre"></td>'; print '<td class="liste_titre"></td>';
print '<td class="liste_titre"></td>'; print '<td class="liste_titre"></td>';

View File

@ -261,7 +261,7 @@ $nav.='<input type="hidden" name="begin_d" value="' . $begin_d . '">';
$nav.='<input type="hidden" name="end_d" value="' . $end_d . '">'; $nav.='<input type="hidden" name="end_d" value="' . $end_d . '">';
$nav.='<input type="hidden" name="showbirthday" value="' . $showbirthday . '">'; $nav.='<input type="hidden" name="showbirthday" value="' . $showbirthday . '">';
$nav.=Form::select_date($dateselect, 'dateselect', 0, 0, 1, '', 1, 0, 1); $nav.=Form::selectDate($dateselect, 'dateselect', 0, 0, 1, '', 1, 0, 1);
$nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">'; $nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">';
$nav.='</form>'; $nav.='</form>';

View File

@ -264,7 +264,7 @@ $nav.='<input type="hidden" name="begin_d" value="' . $begin_d . '">';
$nav.='<input type="hidden" name="end_d" value="' . $end_d . '">'; $nav.='<input type="hidden" name="end_d" value="' . $end_d . '">';
$nav.='<input type="hidden" name="showbirthday" value="' . $showbirthday . '">'; $nav.='<input type="hidden" name="showbirthday" value="' . $showbirthday . '">';
$nav.=Form::select_date($dateselect, 'dateselect', 0, 0, 1, '', 1, 0, 1); $nav.=Form::selectDate($dateselect, 'dateselect', 0, 0, 1, '', 1, 0, 1);
$nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">'; $nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">';
$nav.='</form>'; $nav.='</form>';

View File

@ -1368,7 +1368,7 @@ if ($action == 'create')
// Date // Date
print '<tr><td class="fieldrequired">' . $langs->trans('Date') . '</td><td colspan="2">'; print '<tr><td class="fieldrequired">' . $langs->trans('Date') . '</td><td colspan="2">';
Form::select_date('', '', '', '', '', "addprop", 1, 1); Form::selectDate('', '', '', '', '', "addprop", 1, 1);
print '</td></tr>'; print '</td></tr>';
// Validaty duration // Validaty duration
@ -1416,9 +1416,9 @@ if ($action == 'create')
$syear = date("Y", $tmpdte); $syear = date("Y", $tmpdte);
$smonth = date("m", $tmpdte); $smonth = date("m", $tmpdte);
$sday = date("d", $tmpdte); $sday = date("d", $tmpdte);
Form::select_date($syear."-".$smonth."-".$sday, 'date_livraison', '', '', '', "addprop"); Form::selectDate($syear."-".$smonth."-".$sday, 'date_livraison', '', '', '', "addprop");
} else { } else {
Form::select_date(-1, 'date_livraison', '', '', '', "addprop", 1, 1); Form::selectDate(-1, 'date_livraison', '', '', '', "addprop", 1, 1);
} }
print '</td></tr>'; print '</td></tr>';
@ -1804,7 +1804,7 @@ if ($action == 'create')
print '<form name="editdate" action="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '" method="post">'; print '<form name="editdate" action="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '" method="post">';
print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">'; print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">';
print '<input type="hidden" name="action" value="setdate">'; print '<input type="hidden" name="action" value="setdate">';
Form::select_date($object->date, 're', '', '', 0, "editdate"); Form::selectDate($object->date, 're', '', '', 0, "editdate");
print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">'; print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">';
print '</form>'; print '</form>';
} else { } else {
@ -1830,7 +1830,7 @@ if ($action == 'create')
print '<form name="editecheance" action="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '" method="post">'; print '<form name="editecheance" action="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '" method="post">';
print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">'; print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">';
print '<input type="hidden" name="action" value="setecheance">'; print '<input type="hidden" name="action" value="setecheance">';
Form::select_date($object->fin_validite, 'ech', '', '', '', "editecheance"); Form::selectDate($object->fin_validite, 'ech', '', '', '', "editecheance");
print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">'; print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">';
print '</form>'; print '</form>';
} else { } else {

View File

@ -1505,7 +1505,7 @@ if ($action == 'create' && $user->rights->commande->creer)
} }
// Date // Date
print '<tr><td class="fieldrequired">' . $langs->trans('Date') . '</td><td colspan="2">'; print '<tr><td class="fieldrequired">' . $langs->trans('Date') . '</td><td colspan="2">';
Form::select_date('', 're', '', '', '', "crea_commande", 1, 1); // Always autofill date with current date Form::selectDate('', 're', '', '', '', "crea_commande", 1, 1); // Always autofill date with current date
print '</td></tr>'; print '</td></tr>';
// Delivery date planed // Delivery date planed
@ -1515,7 +1515,7 @@ if ($action == 'create' && $user->rights->commande->creer)
if (! empty($conf->global->DATE_LIVRAISON_WEEK_DELAY)) $datedelivery = time() + ((7*$conf->global->DATE_LIVRAISON_WEEK_DELAY) * 24 * 60 * 60); if (! empty($conf->global->DATE_LIVRAISON_WEEK_DELAY)) $datedelivery = time() + ((7*$conf->global->DATE_LIVRAISON_WEEK_DELAY) * 24 * 60 * 60);
else $datedelivery=empty($conf->global->MAIN_AUTOFILL_DATE_DELIVERY)?-1:''; else $datedelivery=empty($conf->global->MAIN_AUTOFILL_DATE_DELIVERY)?-1:'';
} }
Form::select_date($datedelivery, 'liv_', '', '', '', "crea_commande", 1, 1); Form::selectDate($datedelivery, 'liv_', '', '', '', "crea_commande", 1, 1);
print "</td></tr>"; print "</td></tr>";
// Conditions de reglement // Conditions de reglement
@ -2047,7 +2047,7 @@ if ($action == 'create' && $user->rights->commande->creer)
print '<form name="setdate" action="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '" method="post">'; print '<form name="setdate" action="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '" method="post">';
print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">'; print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">';
print '<input type="hidden" name="action" value="setdate">'; print '<input type="hidden" name="action" value="setdate">';
Form::select_date($object->date, 'order_', '', '', '', "setdate"); Form::selectDate($object->date, 'order_', '', '', '', "setdate");
print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">'; print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">';
print '</form>'; print '</form>';
} else { } else {
@ -2072,7 +2072,7 @@ if ($action == 'create' && $user->rights->commande->creer)
print '<form name="setdate_livraison" action="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '" method="post">'; print '<form name="setdate_livraison" action="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '" method="post">';
print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">'; print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">';
print '<input type="hidden" name="action" value="setdate_livraison">'; print '<input type="hidden" name="action" value="setdate_livraison">';
Form::select_date($object->date_livraison ? $object->date_livraison : - 1, 'liv_', '', '', '', "setdate_livraison"); Form::selectDate($object->date_livraison ? $object->date_livraison : - 1, 'liv_', '', '', '', "setdate_livraison");
print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">'; print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">';
print '</form>'; print '</form>';
} else { } else {

View File

@ -427,7 +427,7 @@ if ($action == 'create' && !$error)
// Date invoice // Date invoice
print '<tr><td class="fieldrequired">'.$langs->trans('Date').'</td><td colspan="2">'; print '<tr><td class="fieldrequired">'.$langs->trans('Date').'</td><td colspan="2">';
Form::select_date('','','','','',"add",1,1); Form::selectDate('','','','','',"add",1,1);
print '</td></tr>'; print '</td></tr>';
// Payment term // Payment term
print '<tr><td class="nowrap">'.$langs->trans('PaymentConditionsShort').'</td><td colspan="2">'; print '<tr><td class="nowrap">'.$langs->trans('PaymentConditionsShort').'</td><td colspan="2">';
@ -575,8 +575,8 @@ if (($action != 'create' && $action != 'add') || ($action == 'create' && $error)
$num = $db->num_rows($resql); $num = $db->num_rows($resql);
print load_fiche_titre($title); print load_fiche_titre($title);
$i = 0; $i = 0;
$period=Form::select_date($date_start,'date_start',0,0,1,'',1,0,1).' - '.Form::select_date($date_end,'date_end',0,0,1,'',1,0,1); $period=Form::selectDate($date_start,'date_start',0,0,1,'',1,0,1).' - '.Form::selectDate($date_end,'date_end',0,0,1,'',1,0,1);
$periodely=Form::select_date($date_starty,'date_start_dely',0,0,1,'',1,0,1).' - '.Form::select_date($date_endy,'date_end_dely',0,0,1,'',1,0,1); $periodely=Form::selectDate($date_starty,'date_start_dely',0,0,1,'',1,0,1).' - '.Form::selectDate($date_endy,'date_end_dely',0,0,1,'',1,0,1);
if (! empty($socid)) if (! empty($socid))
{ {

View File

@ -466,7 +466,7 @@ if ($id > 0 || ! empty($ref))
print '<tr '.$bc[false].'>'; print '<tr '.$bc[false].'>';
print '<td class="nowrap" colspan="2">'; print '<td class="nowrap" colspan="2">';
Form::select_date($dateop,'op',0,0,0,'transaction'); Form::selectDate($dateop,'op',0,0,0,'transaction');
print '</td>'; print '</td>';
print '<td class="nowrap">'; print '<td class="nowrap">';
$form->select_types_paiements((GETPOST('operation')?GETPOST('operation'):($object->courant == Account::TYPE_CASH ? 'LIQ' : '')),'operation','1,2',2,1); $form->select_types_paiements((GETPOST('operation')?GETPOST('operation'):($object->courant == Account::TYPE_CASH ? 'LIQ' : '')),'operation','1,2',2,1);
@ -521,9 +521,9 @@ if ($id > 0 || ! empty($ref))
print '<input type="hidden" name="action" value="search">'; print '<input type="hidden" name="action" value="search">';
print '<input type="hidden" name="id" value="'.$object->id.'">'; print '<input type="hidden" name="id" value="'.$object->id.'">';
$period_filter .= $langs->trans('From').'&nbsp;'.Form::select_date($req_stdt,'req_stdt',0,0,1,null,1,1,1); $period_filter .= $langs->trans('From').'&nbsp;'.Form::selectDate($req_stdt,'req_stdt',0,0,1,null,1,1,1);
$period_filter .= '&nbsp;'; $period_filter .= '&nbsp;';
$period_filter .= $langs->trans('to').'&nbsp;'.Form::select_date($req_enddt,'req_enddt',0,0,1,null,1,1,1); $period_filter .= $langs->trans('to').'&nbsp;'.Form::selectDate($req_enddt,'req_enddt',0,0,1,null,1,1,1);
print '<tr class="liste_titre">'; print '<tr class="liste_titre">';
print '<td colspan="2">'.$period_filter.'</td>'; print '<td colspan="2">'.$period_filter.'</td>';

View File

@ -365,7 +365,7 @@ if ($action == 'create')
print '<tr><td>'.$langs->trans("Date").'</td>'; print '<tr><td>'.$langs->trans("Date").'</td>';
print '<td colspan="3">'; print '<td colspan="3">';
Form::select_date('', 're', 0, 0, 0, 'formsoc'); Form::selectDate('', 're', 0, 0, 0, 'formsoc');
print '</td></tr>'; print '</td></tr>';
print '<tr><td>'.$langs->trans("BalanceMinimalAllowed").'</td>'; print '<tr><td>'.$langs->trans("BalanceMinimalAllowed").'</td>';

View File

@ -451,7 +451,7 @@ if ($result)
if ($user->rights->banque->modifier || $user->rights->banque->consolidate) if ($user->rights->banque->modifier || $user->rights->banque->consolidate)
{ {
print '<td colspan="3">'; print '<td colspan="3">';
print Form::select_date($db->jdate($objp->do),'dateo','','','','update',1,0,1,$objp->rappro); print Form::selectDate($db->jdate($objp->do),'dateo','','','','update',1,0,1,$objp->rappro);
print '</td>'; print '</td>';
} }
else else
@ -467,7 +467,7 @@ if ($result)
if ($user->rights->banque->modifier || $user->rights->banque->consolidate) if ($user->rights->banque->modifier || $user->rights->banque->consolidate)
{ {
print '<td colspan="3">'; print '<td colspan="3">';
print Form::select_date($db->jdate($objp->dv),'datev','','','','update',1,0,1,$objp->rappro); print Form::selectDate($db->jdate($objp->dv),'datev','','','','update',1,0,1,$objp->rappro);
if (! $objp->rappro) if (! $objp->rappro)
{ {
print ' &nbsp; '; print ' &nbsp; ';

View File

@ -191,9 +191,9 @@ if ($resql)
$moreforfilter = ''; $moreforfilter = '';
$moreforfilter.='<div class="divsearchfield">'; $moreforfilter.='<div class="divsearchfield">';
$moreforfilter .= $langs->trans('Period') . ' ('.$langs->trans('DateOperationShort').') : ' . $langs->trans('StartDate') . ' '; $moreforfilter .= $langs->trans('Period') . ' ('.$langs->trans('DateOperationShort').') : ' . $langs->trans('StartDate') . ' ';
$moreforfilter .= Form::select_date($search_dt_start, 'search_start_dt', 0, 0, 1, "search_form", 1, 0, 1); $moreforfilter .= Form::selectDate($search_dt_start, 'search_start_dt', 0, 0, 1, "search_form", 1, 0, 1);
$moreforfilter .= ' - '; $moreforfilter .= ' - ';
$moreforfilter .= $langs->trans('EndDate') . ' ' . Form::select_date($search_dt_end, 'search_end_dt', 0, 0, 1, "search_form", 1, 0, 1); $moreforfilter .= $langs->trans('EndDate') . ' ' . Form::selectDate($search_dt_end, 'search_end_dt', 0, 0, 1, "search_form", 1, 0, 1);
$moreforfilter .= '</div>'; $moreforfilter .= '</div>';
if ($moreforfilter) if ($moreforfilter)

View File

@ -177,7 +177,7 @@ $form->select_comptes($account_to,'account_to',0,'',1);
print "</td>\n"; print "</td>\n";
print "<td>"; print "<td>";
Form::select_date((! empty($dateo)?$dateo:''),'','','','','add'); Form::selectDate((! empty($dateo)?$dateo:''),'','','','','add');
print "</td>\n"; print "</td>\n";
print '<td><input name="label" class="flat" type="text" size="40" value="'.$label.'"></td>'; print '<td><input name="label" class="flat" type="text" size="40" value="'.$label.'"></td>';
print '<td><input name="amount" class="flat" type="text" size="8" value="'.$amount.'"></td>'; print '<td><input name="amount" class="flat" type="text" size="8" value="'.$amount.'"></td>';

View File

@ -262,7 +262,7 @@ if ($action == 'create')
print "<tr>"; print "<tr>";
print '<td class="fieldrequired">'.$langs->trans("Date").'</td><td>'; print '<td class="fieldrequired">'.$langs->trans("Date").'</td><td>';
print Form::select_date($datec?$datec:-1,'','','','','add',1,1,1); print Form::selectDate($datec?$datec:-1,'','','','','add',1,1,1);
print '</td></tr>'; print '</td></tr>';
// Km // Km
@ -358,7 +358,7 @@ else if ($id)
// Date // Date
print '<tr><td class="fieldrequired">'.$langs->trans("Date").'</td><td>'; print '<tr><td class="fieldrequired">'.$langs->trans("Date").'</td><td>';
print Form::select_date($object->date,'',0,0,0,'update',1,0,1); print Form::selectDate($object->date,'',0,0,0,'update',1,0,1);
print '</td></tr>'; print '</td></tr>';
// Km // Km

View File

@ -2354,7 +2354,7 @@ if ($action == 'create')
// Date invoice // Date invoice
print '<tr><td class="fieldrequired">' . $langs->trans('Date') . '</td><td colspan="2">'; print '<tr><td class="fieldrequired">' . $langs->trans('Date') . '</td><td colspan="2">';
$datefacture = dol_mktime(12, 0, 0, $_POST['remonth'], $_POST['reday'], $_POST['reyear']); $datefacture = dol_mktime(12, 0, 0, $_POST['remonth'], $_POST['reday'], $_POST['reyear']);
print Form::select_date($datefacture?$datefacture:$dateinvoice, '', '', '', '', "add", 1, 1, 1); print Form::selectDate($datefacture?$datefacture:$dateinvoice, '', '', '', '', "add", 1, 1, 1);
print '</td></tr>'; print '</td></tr>';
// Payment term // Payment term
@ -2548,12 +2548,12 @@ if ($action == 'create')
print '<td class="nobordernopadding nowrap">'; print '<td class="nobordernopadding nowrap">';
print $langs->trans('From') . ' '; print $langs->trans('From') . ' ';
print '</td><td class="nobordernopadding nowrap">'; print '</td><td class="nobordernopadding nowrap">';
print Form::select_date('', 'date_start' . $i, $usehm, $usehm, 1, "add", 1, 0, 1); print Form::selectDate('', 'date_start' . $i, $usehm, $usehm, 1, "add", 1, 0, 1);
print '</td></tr>'; print '</td></tr>';
print '<td class="nobordernopadding nowrap">'; print '<td class="nobordernopadding nowrap">';
print $langs->trans('to') . ' '; print $langs->trans('to') . ' ';
print '</td><td class="nobordernopadding nowrap">'; print '</td><td class="nobordernopadding nowrap">';
print Form::select_date('', 'date_end' . $i, $usehm, $usehm, 1, "add", 1, 0, 1); print Form::selectDate('', 'date_end' . $i, $usehm, $usehm, 1, "add", 1, 0, 1);
print '</td></tr></table>'; print '</td></tr></table>';
print '</td>'; print '</td>';
} }
@ -3091,7 +3091,7 @@ else if ($id > 0 || ! empty($ref))
if ($object->type != Facture::TYPE_CREDIT_NOTE) { if ($object->type != Facture::TYPE_CREDIT_NOTE) {
if ($action == 'editinvoicedate') { if ($action == 'editinvoicedate') {
Form::form_date($_SERVER['PHP_SELF'] . '?facid=' . $object->id, $object->date, 'invoicedate'); Form::formDate($_SERVER['PHP_SELF'] . '?facid=' . $object->id, $object->date, 'invoicedate');
} else { } else {
print dol_print_date($object->date, 'daytext'); print dol_print_date($object->date, 'daytext');
} }
@ -3454,7 +3454,7 @@ else if ($id > 0 || ! empty($ref))
if ($object->type != Facture::TYPE_CREDIT_NOTE) if ($object->type != Facture::TYPE_CREDIT_NOTE)
{ {
if ($action == 'editpaymentterm') { if ($action == 'editpaymentterm') {
Form::form_date($_SERVER['PHP_SELF'] . '?facid=' . $object->id, $object->date_lim_reglement, 'paymentterm'); Form::formDate($_SERVER['PHP_SELF'] . '?facid=' . $object->id, $object->date_lim_reglement, 'paymentterm');
} else { } else {
print dol_print_date($object->date_lim_reglement, 'daytext'); print dol_print_date($object->date_lim_reglement, 'daytext');
if ($object->hasDelay()) { if ($object->hasDelay()) {

View File

@ -349,7 +349,7 @@ if ($action == 'create')
// First date of execution for cron // First date of execution for cron
print "<tr><td>".$langs->trans('NextDateToExecution')."</td><td>"; print "<tr><td>".$langs->trans('NextDateToExecution')."</td><td>";
$date_next_execution = isset($date_next_execution) ? $date_next_execution : (GETPOST('remonth') ? dol_mktime(12, 0, 0, GETPOST('remonth'), GETPOST('reday'), GETPOST('reyear')) : -1); $date_next_execution = isset($date_next_execution) ? $date_next_execution : (GETPOST('remonth') ? dol_mktime(12, 0, 0, GETPOST('remonth'), GETPOST('reday'), GETPOST('reyear')) : -1);
print Form::select_date($date_next_execution, '', 1, 1, '', "add", 1, 1, 1); print Form::selectDate($date_next_execution, '', 1, 1, '', "add", 1, 1, 1);
print "</td></tr>"; print "</td></tr>";
// Number max of generation // Number max of generation

View File

@ -300,7 +300,7 @@ if ($object->id > 0)
{ {
if ($action == 'editinvoicedate') if ($action == 'editinvoicedate')
{ {
Form::form_date($_SERVER['PHP_SELF'].'?id='.$object->id,$object->date,'invoicedate'); Form::formDate($_SERVER['PHP_SELF'].'?id='.$object->id,$object->date,'invoicedate');
} }
else else
{ {
@ -351,7 +351,7 @@ if ($object->id > 0)
{ {
if ($action == 'editpaymentterm') if ($action == 'editpaymentterm')
{ {
Form::form_date($_SERVER['PHP_SELF'].'?id='.$object->id,$object->date_lim_reglement,'paymentterm'); Form::formDate($_SERVER['PHP_SELF'].'?id='.$object->id,$object->date_lim_reglement,'paymentterm');
} }
else else
{ {

View File

@ -92,7 +92,7 @@ $builddate=time();
$description=$langs->trans("DescPurchasesJournal").'<br>'; $description=$langs->trans("DescPurchasesJournal").'<br>';
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded"); if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded");
else $description.= $langs->trans("DepositsAreIncluded"); else $description.= $langs->trans("DepositsAreIncluded");
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink); report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink);
$p = explode(":", $conf->global->MAIN_INFO_SOCIETE_COUNTRY); $p = explode(":", $conf->global->MAIN_INFO_SOCIETE_COUNTRY);

View File

@ -96,7 +96,7 @@ $builddate=time();
$description=$langs->trans("DescSellsJournal").'<br>'; $description=$langs->trans("DescSellsJournal").'<br>';
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded"); if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded");
else $description.= $langs->trans("DepositsAreIncluded"); else $description.= $langs->trans("DepositsAreIncluded");
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink); report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink);
$p = explode(":", $conf->global->MAIN_INFO_SOCIETE_COUNTRY); $p = explode(":", $conf->global->MAIN_INFO_SOCIETE_COUNTRY);

View File

@ -164,11 +164,11 @@ if ($_GET["action"] == 'create')
print "<tr>"; print "<tr>";
print '<td class="fieldrequired">'.$langs->trans("DatePayment").'</td><td>'; print '<td class="fieldrequired">'.$langs->trans("DatePayment").'</td><td>';
print Form::select_date($datep,"datep",'','','','add'); print Form::selectDate($datep,"datep",'','','','add');
print '</td></tr>'; print '</td></tr>';
print '<tr><td class="fieldrequired">'.$langs->trans("DateValue").'</td><td>'; print '<tr><td class="fieldrequired">'.$langs->trans("DateValue").'</td><td>';
print Form::select_date($datev,"datev",'','','','add'); print Form::selectDate($datev,"datev",'','','','add');
print '</td></tr>'; print '</td></tr>';
// Label // Label

View File

@ -111,7 +111,7 @@ if ($conf->global->$calc==0 || $conf->global->$calc==1) // Calculate on invoice
$nom=$langs->transcountry($local==1?"LT1ReportByCustomersInInputOutputMode":"LT2ReportByCustomersInInputOutputMode",$mysoc->country_code); $nom=$langs->transcountry($local==1?"LT1ReportByCustomersInInputOutputMode":"LT2ReportByCustomersInInputOutputMode",$mysoc->country_code);
$calcmode=$calc==0?$langs->trans("CalcModeLT".$local):$langs->trans("CalcModeLT".$local."Rec"); $calcmode=$calc==0?$langs->trans("CalcModeLT".$local):$langs->trans("CalcModeLT".$local."Rec");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
if (! empty($conf->global->MAIN_MODULE_COMPTABILITE)) $description.='<br>'.$langs->trans("WarningDepositsNotIncluded"); if (! empty($conf->global->MAIN_MODULE_COMPTABILITE)) $description.='<br>'.$langs->trans("WarningDepositsNotIncluded");
$description.=$fsearch; $description.=$fsearch;
$description.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')'; $description.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')';
@ -129,7 +129,7 @@ if ($conf->global->$calc==2) // Invoice for goods, payment for services
$nom=$langs->transcountry($local==1?"LT1ReportByCustomersInInputOutputMode":"LT2ReportByCustomersInInputOutputMode",$mysoc->country_code); $nom=$langs->transcountry($local==1?"LT1ReportByCustomersInInputOutputMode":"LT2ReportByCustomersInInputOutputMode",$mysoc->country_code);
$calcmode=$langs->trans("CalcModeLT2Debt"); $calcmode=$langs->trans("CalcModeLT2Debt");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
if (! empty($conf->global->MAIN_MODULE_COMPTABILITE)) $description.='<br>'.$langs->trans("WarningDepositsNotIncluded"); if (! empty($conf->global->MAIN_MODULE_COMPTABILITE)) $description.='<br>'.$langs->trans("WarningDepositsNotIncluded");
$description.=$fsearch; $description.=$fsearch;
$description.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')'; $description.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')';

View File

@ -131,7 +131,7 @@ if ($conf->global->$calc==0 || $conf->global->$calc==1) // Calculate on invoice
$nom=$langs->trans($local==1?"LT1ReportByQuartersInDueDebtMode":"LT2ReportByQuartersInDueDebtMode"); $nom=$langs->trans($local==1?"LT1ReportByQuartersInDueDebtMode":"LT2ReportByQuartersInDueDebtMode");
$calcmode=$calc==0?$langs->trans("CalcModeLT".$local):$langs->trans("CalcModeLT".$local."Rec"); $calcmode=$calc==0?$langs->trans("CalcModeLT".$local):$langs->trans("CalcModeLT".$local."Rec");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
$prevyear=$year_start; $prevquarter=$q; $prevyear=$year_start; $prevquarter=$q;
if ($prevquarter > 1) $prevquarter--; if ($prevquarter > 1) $prevquarter--;
else { $prevquarter=4; $prevyear--; } else { $prevquarter=4; $prevyear--; }
@ -163,7 +163,7 @@ if ($conf->global->$calc==2) // Invoice for goods, payment for services
$nom=$langs->trans($local==1?"LT1ReportByQuartersInInputOutputMode":"LT2ReportByQuartersInInputOutputMode"); $nom=$langs->trans($local==1?"LT1ReportByQuartersInInputOutputMode":"LT2ReportByQuartersInInputOutputMode");
$calcmode=$calc==0?$langs->trans("CalcModeLT".$local):$langs->trans("CalcModeLT".$local."Rec"); $calcmode=$calc==0?$langs->trans("CalcModeLT".$local):$langs->trans("CalcModeLT".$local."Rec");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT",DOL_URL_ROOT.'/admin/company.php').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
$prevyear=$year_start; $prevquarter=$q; $prevyear=$year_start; $prevquarter=$q;
if ($prevquarter > 1) $prevquarter--; if ($prevquarter > 1) $prevquarter--;
else { $prevquarter=4; $prevyear--; } else { $prevquarter=4; $prevyear--; }

View File

@ -462,7 +462,7 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie
print '<tr><td><span class="fieldrequired">'.$langs->trans('Date').'</span></td><td>'; print '<tr><td><span class="fieldrequired">'.$langs->trans('Date').'</span></td><td>';
$datepayment = dol_mktime(12, 0, 0, $_POST['remonth'], $_POST['reday'], $_POST['reyear']); $datepayment = dol_mktime(12, 0, 0, $_POST['remonth'], $_POST['reday'], $_POST['reyear']);
$datepayment= ($datepayment == '' ? (empty($conf->global->MAIN_AUTOFILL_DATE)?-1:'') : $datepayment); $datepayment= ($datepayment == '' ? (empty($conf->global->MAIN_AUTOFILL_DATE)?-1:'') : $datepayment);
Form::select_date($datepayment,'','','',0,"add_paiement",1,1,0,0,'','',$facture->date); Form::selectDate($datepayment,'','','',0,"add_paiement",1,1,0,0,'','',$facture->date);
print '</td>'; print '</td>';
print '<td>'.$langs->trans('Comments').'</td></tr>'; print '<td>'.$langs->trans('Comments').'</td></tr>';

View File

@ -387,7 +387,7 @@ if ($action == 'new')
//print '<tr><td width="30%">'.$langs->trans('Date').'</td><td width="70%">'.dol_print_date($now,'day').'</td></tr>'; //print '<tr><td width="30%">'.$langs->trans('Date').'</td><td width="70%">'.dol_print_date($now,'day').'</td></tr>';
// Filter // Filter
print '<tr><td width="200">'.$langs->trans("DateChequeReceived").'</td><td>'; print '<tr><td width="200">'.$langs->trans("DateChequeReceived").'</td><td>';
print Form::select_date($filterdate,'fd',0,0,1,'',1,1,1); print Form::selectDate($filterdate,'fd',0,0,1,'',1,1,1);
print '</td></tr>'; print '</td></tr>';
print '<tr><td>'.$langs->trans("BankAccount").'</td><td>'; print '<tr><td>'.$langs->trans("BankAccount").'</td><td>';
$form->select_comptes($filteraccountid,'accountid',0,'courant <> 2',1); $form->select_comptes($filteraccountid,'accountid',0,'courant <> 2',1);
@ -601,7 +601,7 @@ else
print '<form name="setdate" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="post">'; print '<form name="setdate" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="post">';
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">'; print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
print '<input type="hidden" name="action" value="setdate">'; print '<input type="hidden" name="action" value="setdate">';
Form::select_date($object->date_bordereau,'datecreate_','','','',"setdate"); Form::selectDate($object->date_bordereau,'datecreate_','','','',"setdate");
print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">'; print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">';
print '</form>'; print '</form>';
} }

View File

@ -209,7 +209,7 @@ if ($_GET["action"] == 'create')
print '<tr><td class="fieldrequired">'.$langs->trans("Date").'</td><td colspan="2">'; print '<tr><td class="fieldrequired">'.$langs->trans("Date").'</td><td colspan="2">';
$datepaye = dol_mktime(12, 0, 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]); $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; $datepayment=empty($conf->global->MAIN_AUTOFILL_DATE)?(empty($_POST["remonth"])?-1:$datepaye):0;
Form::select_date($datepayment,'','','','',"add_payment",1,1); Form::selectDate($datepayment,'','','','',"add_payment",1,1);
print "</td>"; print "</td>";
print '</tr>'; print '</tr>';

View File

@ -214,7 +214,7 @@ if ($id > 0)
print '<tr class="liste_titre">'; print '<tr class="liste_titre">';
print '<td colspan="3">'.$langs->trans("NotifyTransmision").'</td></tr>'; print '<td colspan="3">'.$langs->trans("NotifyTransmision").'</td></tr>';
print '<tr '.$bc[false].'><td width="20%">'.$langs->trans("TransData").'</td><td>'; print '<tr '.$bc[false].'><td width="20%">'.$langs->trans("TransData").'</td><td>';
print Form::select_date('','','','','',"userfile",1,1); print Form::selectDate('','','','','',"userfile",1,1);
print '</td></tr>'; print '</td></tr>';
print '<tr '.$bc[false].'><td width="20%">'.$langs->trans("TransMetod").'</td><td>'; print '<tr '.$bc[false].'><td width="20%">'.$langs->trans("TransMetod").'</td><td>';
print Form::selectarray("methode",$bon->methodes_trans); print Form::selectarray("methode",$bon->methodes_trans);
@ -237,7 +237,7 @@ if ($id > 0)
print '<tr class="liste_titre">'; print '<tr class="liste_titre">';
print '<td colspan="3">'.$langs->trans("NotifyCredit").'</td></tr>'; print '<td colspan="3">'.$langs->trans("NotifyCredit").'</td></tr>';
print '<tr '.$bc[false].'><td width="20%">'.$langs->trans('CreditDate').'</td><td>'; print '<tr '.$bc[false].'><td width="20%">'.$langs->trans('CreditDate').'</td><td>';
print Form::select_date('','','','','',"infocredit",1,1); print Form::selectDate('','','','','',"infocredit",1,1);
print '</td></tr>'; print '</td></tr>';
print '</table>'; print '</table>';
print '<br>'.$langs->trans("ThisWillAlsoAddPaymentOnInvoice"); print '<br>'.$langs->trans("ThisWillAlsoAddPaymentOnInvoice");

View File

@ -199,7 +199,7 @@ if ($id)
//Date //Date
print '<tr><td class="fieldrequired valid">'.$langs->trans("RefusedData").'</td>'; print '<tr><td class="fieldrequired valid">'.$langs->trans("RefusedData").'</td>';
print '<td colspan="2" class="valid">'; print '<td colspan="2" class="valid">';
print Form::select_date('','','','','',"confirm_rejet"); print Form::selectDate('','','','','',"confirm_rejet");
print '</td></tr>'; print '</td></tr>';
//Reason //Reason

View File

@ -125,7 +125,7 @@ if ($modecompta=="CREANCES-DETTES")
$name=$langs->trans("AnnualByCompaniesDueDebtMode"); $name=$langs->trans("AnnualByCompaniesDueDebtMode");
$calcmode=$langs->trans("CalcModeDebt"); $calcmode=$langs->trans("CalcModeDebt");
$calcmode.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.(GETPOST("month")>0?'&month='.GETPOST("month"):'').'&modecompta=RECETTES-DEPENSES">','</a>').')'; $calcmode.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.(GETPOST("month")>0?'&month='.GETPOST("month"):'').'&modecompta=RECETTES-DEPENSES">','</a>').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
//$periodlink='<a href="'.$_SERVER["PHP_SELF"].'?year='.($year-1).'&modecompta='.$modecompta.'">'.img_previous().'</a> <a href="'.$_SERVER["PHP_SELF"].'?year='.($year+1).'&modecompta='.$modecompta.'">'.img_next().'</a>'; //$periodlink='<a href="'.$_SERVER["PHP_SELF"].'?year='.($year-1).'&modecompta='.$modecompta.'">'.img_previous().'</a> <a href="'.$_SERVER["PHP_SELF"].'?year='.($year+1).'&modecompta='.$modecompta.'">'.img_next().'</a>';
$description=$langs->trans("RulesResultDue"); $description=$langs->trans("RulesResultDue");
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded"); if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded");
@ -137,8 +137,8 @@ else {
$name=$langs->trans("AnnualByCompaniesInputOutputMode"); $name=$langs->trans("AnnualByCompaniesInputOutputMode");
$calcmode=$langs->trans("CalcModeEngagement"); $calcmode=$langs->trans("CalcModeEngagement");
$calcmode.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.(GETPOST("month")>0?'&month='.GETPOST("month"):'').'&modecompta=CREANCES-DETTES">','</a>').')'; $calcmode.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.(GETPOST("month")>0?'&month='.GETPOST("month"):'').'&modecompta=CREANCES-DETTES">','</a>').')';
//$period=Form::select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.Form::select_date($date_end,'date_end',1,1,0,'',1,0,1); //$period=Form::selectDate($date_start,'date_start',0,0,0,'',1,0,1).' - '.Form::selectDate($date_end,'date_end',1,1,0,'',1,0,1);
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
//$periodlink='<a href="'.$_SERVER["PHP_SELF"].'?year='.($year-1).'&modecompta='.$modecompta.'">'.img_previous().'</a> <a href="'.$_SERVER["PHP_SELF"].'?year='.($year+1).'&modecompta='.$modecompta.'">'.img_next().'</a>'; //$periodlink='<a href="'.$_SERVER["PHP_SELF"].'?year='.($year-1).'&modecompta='.$modecompta.'">'.img_previous().'</a> <a href="'.$_SERVER["PHP_SELF"].'?year='.($year+1).'&modecompta='.$modecompta.'">'.img_next().'</a>';
$description=$langs->trans("RulesResultInOut"); $description=$langs->trans("RulesResultInOut");
$builddate=time(); $builddate=time();

View File

@ -239,13 +239,13 @@ if ($action == 'create')
// Date payment // Date payment
print '<tr><td>'; print '<tr><td>';
print fieldLabel('DatePayment','datep',1).'</td><td>'; print fieldLabel('DatePayment','datep',1).'</td><td>';
print Form::select_date((empty($datep)?-1:$datep),"datep",'','','','add',1,1); print Form::selectDate((empty($datep)?-1:$datep),"datep",'','','','add',1,1);
print '</td></tr>'; print '</td></tr>';
// Date value for bank // Date value for bank
print '<tr><td>'; print '<tr><td>';
print fieldLabel('DateValue','datev',0).'</td><td>'; print fieldLabel('DateValue','datev',0).'</td><td>';
print Form::select_date((empty($datev)?-1:$datev),"datev",'','','','add',1,1); print Form::selectDate((empty($datev)?-1:$datev),"datev",'','','','add',1,1);
print '</td></tr>'; print '</td></tr>';
// Employee // Employee
@ -263,13 +263,13 @@ if ($action == 'create')
// Date start period // Date start period
print '<tr><td>'; print '<tr><td>';
print fieldLabel('DateStartPeriod','datesp',1).'</td><td>'; print fieldLabel('DateStartPeriod','datesp',1).'</td><td>';
print Form::select_date($datesp,"datesp",'','','','add'); print Form::selectDate($datesp,"datesp",'','','','add');
print '</td></tr>'; print '</td></tr>';
// Date end period // Date end period
print '<tr><td>'; print '<tr><td>';
print fieldLabel('DateEndPeriod','dateep',1).'</td><td>'; print fieldLabel('DateEndPeriod','dateep',1).'</td><td>';
print Form::select_date($dateep,"dateep",'','','','add'); print Form::selectDate($dateep,"dateep",'','','','add');
print '</td></tr>'; print '</td></tr>';
// Amount // Amount

View File

@ -270,7 +270,7 @@ if ($action == 'create')
print $langs->trans("PeriodEndDate"); print $langs->trans("PeriodEndDate");
print '</td>'; print '</td>';
print '<td>'; print '<td>';
print Form::select_date(! empty($dateperiod)?$dateperiod:'-1', 'period', 0, 0, 0, 'charge', 1); print Form::selectDate(! empty($dateperiod)?$dateperiod:'-1', 'period', 0, 0, 0, 'charge', 1);
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';
// Amount // Amount
@ -286,7 +286,7 @@ if ($action == 'create')
print $langs->trans("DateDue"); print $langs->trans("DateDue");
print '</td>'; print '</td>';
print '<td>'; print '<td>';
print Form::select_date(! empty($dateech)?$dateech:'-1', 'ech', 0, 0, 0, 'charge', 1); print Form::selectDate(! empty($dateech)?$dateech:'-1', 'ech', 0, 0, 0, 'charge', 1);
print '</td>'; print '</td>';
print "</tr>\n"; print "</tr>\n";
@ -443,7 +443,7 @@ if ($id > 0)
print "<td>"; print "<td>";
if ($action == 'edit') if ($action == 'edit')
{ {
print Form::select_date($object->periode, 'period', 0, 0, 0, 'charge', 1); print Form::selectDate($object->periode, 'period', 0, 0, 0, 'charge', 1);
} }
else else
{ {
@ -455,7 +455,7 @@ if ($id > 0)
if ($action == 'edit') if ($action == 'edit')
{ {
print '<tr><td>'.$langs->trans("DateDue")."</td><td>"; print '<tr><td>'.$langs->trans("DateDue")."</td><td>";
print Form::select_date($object->date_ech, 'ech', 0, 0, 0, 'charge', 1); print Form::selectDate($object->date_ech, 'ech', 0, 0, 0, 'charge', 1);
print "</td></tr>"; print "</td></tr>";
} }
else { else {

View File

@ -130,7 +130,7 @@ if ($object->id)
print "<td>"; print "<td>";
if ($action == 'edit') if ($action == 'edit')
{ {
print Form::select_date($object->periode, 'period', 0, 0, 0, 'charge', 1); print Form::selectDate($object->periode, 'period', 0, 0, 0, 'charge', 1);
} }
else else
{ {
@ -143,7 +143,7 @@ if ($object->id)
if ($action == 'edit') if ($action == 'edit')
{ {
print '<tr><td>'.$langs->trans("DateDue")."</td><td>"; print '<tr><td>'.$langs->trans("DateDue")."</td><td>";
print Form::select_date($object->date_ech, 'ech', 0, 0, 0, 'charge', 1); print Form::selectDate($object->date_ech, 'ech', 0, 0, 0, 'charge', 1);
print "</td></tr>"; print "</td></tr>";
} }
else { else {

View File

@ -150,7 +150,7 @@ if ($modecompta=="CREANCES-DETTES") {
$calcmode=$langs->trans("CalcModeDebt"); $calcmode=$langs->trans("CalcModeDebt");
$calcmode.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=RECETTES-DEPENSES">','</a>').')'; $calcmode.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=RECETTES-DEPENSES">','</a>').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
$description=$langs->trans("RulesCADue"); $description=$langs->trans("RulesCADue");
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) { if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
@ -164,7 +164,7 @@ if ($modecompta=="CREANCES-DETTES") {
$calcmode=$langs->trans("CalcModeEngagement"); $calcmode=$langs->trans("CalcModeEngagement");
$calcmode.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')'; $calcmode.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
$description=$langs->trans("RulesCAIn"); $description=$langs->trans("RulesCAIn");
$description.= $langs->trans("DepositsAreIncluded"); $description.= $langs->trans("DepositsAreIncluded");

View File

@ -139,7 +139,7 @@ if ($modecompta=="CREANCES-DETTES") {
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice"); $nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice");
$calcmode=$langs->trans("CalcModeDebt"); $calcmode=$langs->trans("CalcModeDebt");
$calcmode.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=RECETTES-DEPENSES">','</a>').')'; $calcmode.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=RECETTES-DEPENSES">','</a>').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
//$periodlink="<a href='".$_SERVER["PHP_SELF"]."?year=".($year-1)."&modecompta=".$modecompta."'>".img_previous()."</a> <a href='".$_SERVER["PHP_SELF"]."?year=".($year+1)."&modecompta=".$modecompta."'>".img_next()."</a>"; //$periodlink="<a href='".$_SERVER["PHP_SELF"]."?year=".($year-1)."&modecompta=".$modecompta."'>".img_previous()."</a> <a href='".$_SERVER["PHP_SELF"]."?year=".($year+1)."&modecompta=".$modecompta."'>".img_next()."</a>";
$description=$langs->trans("RulesCADue"); $description=$langs->trans("RulesCADue");
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded"); if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded");
@ -150,7 +150,7 @@ if ($modecompta=="CREANCES-DETTES") {
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice"); $nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice");
$calcmode=$langs->trans("CalcModeEngagement"); $calcmode=$langs->trans("CalcModeEngagement");
$calcmode.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')'; $calcmode.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
//$periodlink="<a href='".$_SERVER["PHP_SELF"]."?year=".($year-1)."&modecompta=".$modecompta."'>".img_previous()."</a> <a href='".$_SERVER["PHP_SELF"]."?year=".($year+1)."&modecompta=".$modecompta."'>".img_next()."</a>"; //$periodlink="<a href='".$_SERVER["PHP_SELF"]."?year=".($year-1)."&modecompta=".$modecompta."'>".img_previous()."</a> <a href='".$_SERVER["PHP_SELF"]."?year=".($year+1)."&modecompta=".$modecompta."'>".img_next()."</a>";
$description=$langs->trans("RulesCAIn"); $description=$langs->trans("RulesCAIn");
$description.= $langs->trans("DepositsAreIncluded"); $description.= $langs->trans("DepositsAreIncluded");

View File

@ -155,7 +155,7 @@ if ($modecompta=="CREANCES-DETTES")
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties"); $nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties");
$calcmode=$langs->trans("CalcModeDebt"); $calcmode=$langs->trans("CalcModeDebt");
$calcmode.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=RECETTES-DEPENSES">','</a>').')'; $calcmode.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=RECETTES-DEPENSES">','</a>').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
//$periodlink='<a href="'.$_SERVER["PHP_SELF"].'?year='.($year-1).'&modecompta='.$modecompta.'">'.img_previous().'</a> <a href="'.$_SERVER["PHP_SELF"].'?year='.($year+1).'&modecompta='.$modecompta.'">'.img_next().'</a>'; //$periodlink='<a href="'.$_SERVER["PHP_SELF"].'?year='.($year-1).'&modecompta='.$modecompta.'">'.img_previous().'</a> <a href="'.$_SERVER["PHP_SELF"].'?year='.($year+1).'&modecompta='.$modecompta.'">'.img_next().'</a>';
$description=$langs->trans("RulesCADue"); $description=$langs->trans("RulesCADue");
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded"); if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded");
@ -166,7 +166,7 @@ if ($modecompta=="CREANCES-DETTES")
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties"); $nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties");
$calcmode=$langs->trans("CalcModeEngagement"); $calcmode=$langs->trans("CalcModeEngagement");
$calcmode.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')'; $calcmode.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
//$periodlink='<a href="'.$_SERVER["PHP_SELF"].'?year='.($year-1).'&modecompta='.$modecompta.'">'.img_previous().'</a> <a href="'.$_SERVER["PHP_SELF"].'?year='.($year+1).'&modecompta='.$modecompta.'">'.img_next().'</a>'; //$periodlink='<a href="'.$_SERVER["PHP_SELF"].'?year='.($year-1).'&modecompta='.$modecompta.'">'.img_previous().'</a> <a href="'.$_SERVER["PHP_SELF"].'?year='.($year+1).'&modecompta='.$modecompta.'">'.img_next().'</a>';
$description=$langs->trans("RulesCAIn"); $description=$langs->trans("RulesCAIn");
$description.= $langs->trans("DepositsAreIncluded"); $description.= $langs->trans("DepositsAreIncluded");

View File

@ -234,11 +234,11 @@ if ($action == 'create')
print "<tr>"; print "<tr>";
print '<td class="fieldrequired">'.$langs->trans("DatePayment").'</td><td>'; print '<td class="fieldrequired">'.$langs->trans("DatePayment").'</td><td>';
print Form::select_date($datep,"datep",'','','','add',1,1); print Form::selectDate($datep,"datep",'','','','add',1,1);
print '</td></tr>'; print '</td></tr>';
print '<tr><td class="fieldrequired">'.$langs->trans("DateValue").'</td><td>'; print '<tr><td class="fieldrequired">'.$langs->trans("DateValue").'</td><td>';
print Form::select_date($datev,"datev",'','','','add',1,1); print Form::selectDate($datev,"datev",'','','','add',1,1);
print '</td></tr>'; print '</td></tr>';
// Label // Label

View File

@ -140,7 +140,7 @@ if ($modetax==1) { // Calculate on invoice for goods and services
$calcmode=$langs->trans("CalcModeVATDebt"); $calcmode=$langs->trans("CalcModeVATDebt");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')';
//$name.='<br>('.$langs->trans("SeeVATReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year_start.'&modetax=0">','</a>').')'; //$name.='<br>('.$langs->trans("SeeVATReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year_start.'&modetax=0">','</a>').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
//$periodlink=($year_start?"<a href='".$_SERVER["PHP_SELF"]."?year=".($year_start-1)."&modetax=".$modetax."'>".img_previous()."</a> <a href='".$_SERVER["PHP_SELF"]."?year=".($year_start+1)."&modetax=".$modetax."'>".img_next()."</a>":""); //$periodlink=($year_start?"<a href='".$_SERVER["PHP_SELF"]."?year=".($year_start-1)."&modetax=".$modetax."'>".img_previous()."</a> <a href='".$_SERVER["PHP_SELF"]."?year=".($year_start+1)."&modetax=".$modetax."'>".img_next()."</a>":"");
$description=$langs->trans("RulesVATDueServices"); $description=$langs->trans("RulesVATDueServices");
$description.='<br>'; $description.='<br>';
@ -183,7 +183,7 @@ if ($modetax==0) { // Invoice for goods, payment for services
$calcmode=$langs->trans("CalcModeVATEngagement"); $calcmode=$langs->trans("CalcModeVATEngagement");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')';
//$name.='<br>('.$langs->trans("SeeVATReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year_start.'&modetax=1">','</a>').')'; //$name.='<br>('.$langs->trans("SeeVATReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year_start.'&modetax=1">','</a>').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
//$periodlink=($year_start?"<a href='".$_SERVER["PHP_SELF"]."?year=".($year_start-1)."&modetax=".$modetax."'>".img_previous()."</a> <a href='".$_SERVER["PHP_SELF"]."?year=".($year_start+1)."&modetax=".$modetax."'>".img_next()."</a>":""); //$periodlink=($year_start?"<a href='".$_SERVER["PHP_SELF"]."?year=".($year_start-1)."&modetax=".$modetax."'>".img_previous()."</a> <a href='".$_SERVER["PHP_SELF"]."?year=".($year_start+1)."&modetax=".$modetax."'>".img_next()."</a>":"");
$description=$langs->trans("RulesVATInServices"); $description=$langs->trans("RulesVATInServices");
$description.=' '.$langs->trans("DepositsAreIncluded"); $description.=' '.$langs->trans("DepositsAreIncluded");

View File

@ -130,7 +130,7 @@ if ($modetax==1) // Calculate on invoice for goods and services
$nom=$langs->trans("VATReportByQuartersInDueDebtMode"); $nom=$langs->trans("VATReportByQuartersInDueDebtMode");
$calcmode=$langs->trans("CalcModeVATDebt"); $calcmode=$langs->trans("CalcModeVATDebt");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
$prevyear=$year_start; $prevquarter=$q; $prevyear=$year_start; $prevquarter=$q;
if ($prevquarter > 1) $prevquarter--; if ($prevquarter > 1) $prevquarter--;
else { $prevquarter=4; $prevyear--; } else { $prevquarter=4; $prevyear--; }
@ -165,7 +165,7 @@ if ($modetax==0) // Invoice for goods, payment for services
$nom=$langs->trans("VATReportByQuartersInInputOutputMode"); $nom=$langs->trans("VATReportByQuartersInInputOutputMode");
$calcmode=$langs->trans("CalcModeVATEngagement"); $calcmode=$langs->trans("CalcModeVATEngagement");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
$prevyear=$year_start; $prevquarter=$q; $prevyear=$year_start; $prevquarter=$q;
if ($prevquarter > 1) $prevquarter--; if ($prevquarter > 1) $prevquarter--;
else { $prevquarter=4; $prevyear--; } else { $prevquarter=4; $prevyear--; }

View File

@ -149,7 +149,7 @@ if ($modetax==1) { // Calculate on invoice for goods and services
$nom=$langs->trans("VATReportByQuartersInDueDebtMode"); $nom=$langs->trans("VATReportByQuartersInDueDebtMode");
$calcmode=$langs->trans("CalcModeVATDebt"); $calcmode=$langs->trans("CalcModeVATDebt");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
$prevyear=$year_start; $prevquarter=$q; $prevyear=$year_start; $prevquarter=$q;
if ($prevquarter > 1) { if ($prevquarter > 1) {
$prevquarter--; $prevquarter--;
@ -198,7 +198,7 @@ if ($modetax==0) { // Invoice for goods, payment for services
$nom=$langs->trans("VATReportByQuartersInInputOutputMode"); $nom=$langs->trans("VATReportByQuartersInInputOutputMode");
$calcmode=$langs->trans("CalcModeVATEngagement"); $calcmode=$langs->trans("CalcModeVATEngagement");
$calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')'; $calcmode.='<br>('.$langs->trans("TaxModuleSetupToModifyRules",DOL_URL_ROOT.'/admin/taxes.php').')';
$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,1).' - '.Form::selectDate($date_end,'date_end',0,0,0,'',1,0,1);
$prevyear=$year_start; $prevquarter=$q; $prevyear=$year_start; $prevquarter=$q;
if ($prevquarter > 1) { if ($prevquarter > 1) {
$prevquarter--; $prevquarter--;

View File

@ -688,11 +688,11 @@ else
$form=new Form($db); $form=new Form($db);
if ($object->birthday) if ($object->birthday)
{ {
print Form::select_date($object->birthday,'birthday',0,0,0,"perso", 1, 0, 1); print Form::selectDate($object->birthday,'birthday',0,0,0,"perso", 1, 0, 1);
} }
else else
{ {
print Form::select_date('','birthday',0,0,1,"perso", 1, 0, 1); print Form::selectDate('','birthday',0,0,1,"perso", 1, 0, 1);
} }
print '</td>'; print '</td>';

View File

@ -130,7 +130,7 @@ if ($action == 'edit')
// Date To Birth // Date To Birth
print '<tr><td>'.$langs->trans("DateToBirth").'</td><td>'; print '<tr><td>'.$langs->trans("DateToBirth").'</td><td>';
$form=new Form($db); $form=new Form($db);
print Form::select_date($object->birthday,'birthday',0,0,1,"perso", 1,0,1); print Form::selectDate($object->birthday,'birthday',0,0,1,"perso", 1,0,1);
print '</td>'; print '</td>';
print '<td colspan="2">'.$langs->trans("Alert").': '; print '<td colspan="2">'.$langs->trans("Alert").': ';

View File

@ -1148,7 +1148,7 @@ if ($action == 'create')
print '</td></tr>'; print '</td></tr>';
print '<tr><td><span class="fieldrequired">'.$langs->trans("Date").'</span></td><td>'; print '<tr><td><span class="fieldrequired">'.$langs->trans("Date").'</span></td><td>';
Form::select_date($datecontrat,'',0,0,'',"contrat"); Form::selectDate($datecontrat,'',0,0,'',"contrat");
print "</td></tr>"; print "</td></tr>";
// Project // Project
@ -1651,9 +1651,9 @@ else
print "<tr ".$bc[$var].">"; print "<tr ".$bc[$var].">";
print '<td colspan="'.$colspan.'">'; print '<td colspan="'.$colspan.'">';
print $langs->trans("DateStartPlanned").' '; print $langs->trans("DateStartPlanned").' ';
Form::select_date($db->jdate($objp->date_debut),"date_start_update",$usehm,$usehm,($db->jdate($objp->date_debut)>0?0:1),"update"); Form::selectDate($db->jdate($objp->date_debut),"date_start_update",$usehm,$usehm,($db->jdate($objp->date_debut)>0?0:1),"update");
print ' &nbsp;&nbsp;'.$langs->trans("DateEndPlanned").' '; print ' &nbsp;&nbsp;'.$langs->trans("DateEndPlanned").' ';
Form::select_date($db->jdate($objp->date_fin),"date_end_update",$usehm,$usehm,($db->jdate($objp->date_fin)>0?0:1),"update"); Form::selectDate($db->jdate($objp->date_fin),"date_end_update",$usehm,$usehm,($db->jdate($objp->date_fin)>0?0:1),"update");
print '</td>'; print '</td>';
if (is_array($extralabelslines) && count($extralabelslines)>0) { if (is_array($extralabelslines) && count($extralabelslines)>0) {
@ -1824,11 +1824,11 @@ else
print '<tr '.$bc[$var].'>'; print '<tr '.$bc[$var].'>';
print '<td class="nohover">'.$langs->trans("DateServiceActivate").'</td><td class="nohover">'; print '<td class="nohover">'.$langs->trans("DateServiceActivate").'</td><td class="nohover">';
print Form::select_date($dateactstart,'',$usehm,$usehm,'',"active",1,0,1); print Form::selectDate($dateactstart,'',$usehm,$usehm,'',"active",1,0,1);
print '</td>'; print '</td>';
print '<td class="nohover">'.$langs->trans("DateEndPlanned").'</td><td class="nohover">'; print '<td class="nohover">'.$langs->trans("DateEndPlanned").'</td><td class="nohover">';
print Form::select_date($dateactend,"end",$usehm,$usehm,'',"active",1,0,1); print Form::selectDate($dateactend,"end",$usehm,$usehm,'',"active",1,0,1);
print '</td>'; print '</td>';
print '<td align="center nohover" rowspan="2" valign="middle" class="nohover">'; print '<td align="center nohover" rowspan="2" valign="middle" class="nohover">';
@ -1881,7 +1881,7 @@ else
if ($objp->statut == 4) if ($objp->statut == 4)
{ {
print $langs->trans("DateEndReal").' '; print $langs->trans("DateEndReal").' ';
print Form::select_date($dateactend,"end",$usehm,$usehm,($objp->date_fin_reelle>0?0:1),"closeline",1,1,1); print Form::selectDate($dateactend,"end",$usehm,$usehm,($objp->date_fin_reelle>0?0:1),"closeline",1,1,1);
} }
} }
print '</td>'; print '</td>';

View File

@ -219,14 +219,14 @@ if ($resql)
print Form::selectarray('filter_op1',$arrayofoperators,$filter_op1,1); print Form::selectarray('filter_op1',$arrayofoperators,$filter_op1,1);
print ' '; print ' ';
$filter_date1=dol_mktime(0,0,0,$op1month,$op1day,$op1year); $filter_date1=dol_mktime(0,0,0,$op1month,$op1day,$op1year);
print Form::select_date($filter_date1,'op1',0,0,1,'',1,0,1); print Form::selectDate($filter_date1,'op1',0,0,1,'',1,0,1);
print '</td>'; print '</td>';
print '<td class="liste_titre" align="center">'; print '<td class="liste_titre" align="center">';
$arrayofoperators=array('<'=>'<','>'=>'>'); $arrayofoperators=array('<'=>'<','>'=>'>');
print Form::selectarray('filter_op2',$arrayofoperators,$filter_op2,1); print Form::selectarray('filter_op2',$arrayofoperators,$filter_op2,1);
print ' '; print ' ';
$filter_date2=dol_mktime(0,0,0,$op2month,$op2day,$op2year); $filter_date2=dol_mktime(0,0,0,$op2month,$op2day,$op2year);
print Form::select_date($filter_date2,'op2',0,0,1,'',1,0,1); print Form::selectDate($filter_date2,'op2',0,0,1,'',1,0,1);
print '</td>'; print '</td>';
print '<td align="right">'; print '<td align="right">';
$arrayofstatus=array( $arrayofstatus=array(

View File

@ -694,7 +694,7 @@ class ExtraFields
$showtime = in_array($type,array('datetime')) ? 1 : 0; $showtime = in_array($type,array('datetime')) ? 1 : 0;
// Do not show current date when field not required (see select_date() method) // Do not show current date when field not required (see selectDate() method)
if (!$required && $value == '') $value = '-1'; if (!$required && $value == '') $value = '-1';
require_once DOL_DOCUMENT_ROOT.'/core/class/html.form.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.form.class.php';
@ -702,7 +702,7 @@ class ExtraFields
if (! is_object($form)) $form=new Form($this->db); if (! is_object($form)) $form=new Form($this->db);
// TODO Must also support $moreparam // TODO Must also support $moreparam
$out = Form::select_date($value, $keysuffix.'options_'.$key.$keyprefix, $showtime, $showtime, $required, '', 1, 1, 1, 0, 1); $out = Form::selectDate($value, $keysuffix.'options_'.$key.$keyprefix, $showtime, $showtime, $required, '', 1, 1, 1, 0, 1);
} }
elseif (in_array($type,array('int'))) elseif (in_array($type,array('int')))
{ {

View File

@ -171,11 +171,11 @@ class Form
} }
else if ($typeofdata == 'day' || $typeofdata == 'datepicker') else if ($typeofdata == 'day' || $typeofdata == 'datepicker')
{ {
$ret.=self::select_date($value,$htmlname,0,0,1,'form'.$htmlname,1,0,1); $ret.=self::selectDate($value,$htmlname,0,0,1,'form'.$htmlname,1,0,1);
} }
else if ($typeofdata == 'dayhour' || $typeofdata == 'datehourpicker') else if ($typeofdata == 'dayhour' || $typeofdata == 'datehourpicker')
{ {
$ret.=self::select_date($value,$htmlname,1,1,1,'form'.$htmlname,1,0,1); $ret.=self::selectDate($value,$htmlname,1,1,1,'form'.$htmlname,1,0,1);
} }
else if (preg_match('/^select;/',$typeofdata)) else if (preg_match('/^select;/',$typeofdata))
{ {
@ -3264,7 +3264,7 @@ class Form
{ {
$more.='<tr><td>'.$input['label'].'</td>'; $more.='<tr><td>'.$input['label'].'</td>';
$more.='<td colspan="2" align="left">'; $more.='<td colspan="2" align="left">';
$more.=self::select_date($input['value'],$input['name'],0,0,0,'',1,0,1); $more.=self::selectDate($input['value'],$input['name'],0,0,0,'',1,0,1);
$more.='</td></tr>'."\n"; $more.='</td></tr>'."\n";
$formquestion[] = array('name'=>$input['name'].'day'); $formquestion[] = array('name'=>$input['name'].'day');
$formquestion[] = array('name'=>$input['name'].'month'); $formquestion[] = array('name'=>$input['name'].'month');
@ -3614,9 +3614,9 @@ class Form
* @param int $displaymin Display minutes selector * @param int $displaymin Display minutes selector
* @param int $nooutput 1=No print output, return string * @param int $nooutput 1=No print output, return string
* @return void * @return void
* @see select_date * @see selectDate
*/ */
public static function form_date($page, $selected, $htmlname, $displayhour=0, $displaymin=0, $nooutput=0) public static function formDate($page, $selected, $htmlname, $displayhour=0, $displaymin=0, $nooutput=0)
{ {
global $langs; global $langs;
@ -3629,7 +3629,7 @@ class Form
$ret.='<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">'; $ret.='<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
$ret.='<table class="nobordernopadding" cellpadding="0" cellspacing="0">'; $ret.='<table class="nobordernopadding" cellpadding="0" cellspacing="0">';
$ret.='<tr><td>'; $ret.='<tr><td>';
$ret.=self::select_date($selected,$htmlname,$displayhour,$displaymin,1,'form'.$htmlname,1,0,1); $ret.=self::selectDate($selected,$htmlname,$displayhour,$displaymin,1,'form'.$htmlname,1,0,1);
$ret.='</td>'; $ret.='</td>';
$ret.='<td align="left"><input type="submit" class="button" value="'.$langs->trans("Modify").'"></td>'; $ret.='<td align="left"><input type="submit" class="button" value="'.$langs->trans("Modify").'"></td>';
$ret.='</tr></table></form>'; $ret.='</tr></table></form>';
@ -4252,12 +4252,12 @@ class Form
* @param int $nooutput Do not output html string but return it * @param int $nooutput Do not output html string but return it
* @param int $disabled Disable input fields * @param int $disabled Disable input fields
* @param int $fullday When a checkbox with this html name is on, hour and day are set with 00:00 or 23:59 * @param int $fullday When a checkbox with this html name is on, hour and day are set with 00:00 or 23:59
* @param string $addplusone Add a link "+1 hour". Value must be name of another select_date field. * @param string $addplusone Add a link "+1 hour". Value must be name of another selectDate field.
* @param datetime $adddateof Add a link "Date of invoice" using the following date. * @param datetime $adddateof Add a link "Date of invoice" using the following date.
* @return mixed Nothing or string if nooutput is 1 * @return mixed Nothing or string if nooutput is 1
* @see form_date * @see formDate
*/ */
public static function select_date($set_time='', $prefix='re', $h=0, $m=0, $empty=0, $form_name="", $d=1, $addnowlink=0, $nooutput=0, $disabled=0, $fullday='', $addplusone='', $adddateof='') public static function selectDate($set_time='', $prefix='re', $h=0, $m=0, $empty=0, $form_name="", $d=1, $addnowlink=0, $nooutput=0, $disabled=0, $fullday='', $addplusone='', $adddateof='')
{ {
global $conf,$langs; global $conf,$langs;

View File

@ -9,7 +9,7 @@
* Copyright (C) 2012-2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr> * Copyright (C) 2012-2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
* Copyright (C) 2014 Cedric GROSS <c.gross@kreiz-it.fr> * Copyright (C) 2014 Cedric GROSS <c.gross@kreiz-it.fr>
* Copyright (C) 2014 Teddy Andreotti <125155@supinfo.com> * Copyright (C) 2014 Teddy Andreotti <125155@supinfo.com>
* Copyright (C) 2015 Marcos García <marcosgdf@gmail.com> * Copyright (C) 2015-2016 Marcos García <marcosgdf@gmail.com>
* *
* This program is free software; you can redistribute it and/or modify * 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 * it under the terms of the GNU General Public License as published by
@ -39,7 +39,7 @@
* @param Translate $outputlangs Output lang to use to autodetect output format if setup not done * @param Translate $outputlangs Output lang to use to autodetect output format if setup not done
* @return array Array('width'=>w,'height'=>h,'unit'=>u); * @return array Array('width'=>w,'height'=>h,'unit'=>u);
*/ */
function pdf_getFormat($outputlangs='') function pdf_getFormat(Translate $outputlangs = null)
{ {
global $conf,$db; global $conf,$db;
@ -77,7 +77,7 @@ function pdf_getFormat($outputlangs='')
* @param string $format Array(width,height). Keep empty to use default setup. * @param string $format Array(width,height). Keep empty to use default setup.
* @param string $metric Unit of format ('mm') * @param string $metric Unit of format ('mm')
* @param string $pagetype 'P' or 'l' * @param string $pagetype 'P' or 'l'
* @return TPDF PDF object * @return TCPDF PDF object
*/ */
function pdf_getInstance($format='',$metric='mm',$pagetype='P') function pdf_getInstance($format='',$metric='mm',$pagetype='P')
{ {
@ -230,7 +230,7 @@ function pdf_getInstance($format='',$metric='mm',$pagetype='P')
* @param Translate $outputlangs Output langs object * @param Translate $outputlangs Output langs object
* @return string Name of font to use * @return string Name of font to use
*/ */
function pdf_getPDFFont($outputlangs) function pdf_getPDFFont(Translate $outputlangs)
{ {
global $conf; global $conf;
@ -253,7 +253,7 @@ function pdf_getPDFFont($outputlangs)
* @param Translate $outputlangs Output langs object * @param Translate $outputlangs Output langs object
* @return int Size of font to use * @return int Size of font to use
*/ */
function pdf_getPDFFontSize($outputlangs) function pdf_getPDFFontSize(Translate $outputlangs)
{ {
$size=10; // By default, for FPDI or ISO language on TCPDF $size=10; // By default, for FPDI or ISO language on TCPDF
if (class_exists('TCPDF')) // If TCPDF on, we can use an UTF8 one like DejaVuSans if required (slower) if (class_exists('TCPDF')) // If TCPDF on, we can use an UTF8 one like DejaVuSans if required (slower)
@ -295,9 +295,10 @@ function pdf_getHeightForLogo($logo, $url = false)
* *
* @param TCPDF $pdf PDF initialized object * @param TCPDF $pdf PDF initialized object
* @param string $htmlcontent HTML Contect * @param string $htmlcontent HTML Contect
* @return int
* @see getStringHeight * @see getStringHeight
*/ */
function pdfGetHeightForHtmlContent(&$pdf, $htmlcontent) function pdfGetHeightForHtmlContent(TCPDF $pdf, $htmlcontent)
{ {
// store current object // store current object
$pdf->startTransaction(); $pdf->startTransaction();
@ -377,7 +378,7 @@ function pdfBuildThirdpartyName($thirdparty, Translate $outputlangs, $includeali
* @param Object $object Object we want to build document for * @param Object $object Object we want to build document for
* @return string String with full address * @return string String with full address
*/ */
function pdf_build_address($outputlangs,$sourcecompany,$targetcompany='',$targetcontact='',$usecontact=0,$mode='source',$object=null) function pdf_build_address(Translate $outputlangs, Societe $sourcecompany,$targetcompany='',$targetcontact='',$usecontact=0,$mode='source',$object=null)
{ {
global $conf, $hookmanager; global $conf, $hookmanager;
@ -530,12 +531,12 @@ function pdf_build_address($outputlangs,$sourcecompany,$targetcompany='',$target
/** /**
* Show header of page for PDF generation * Show header of page for PDF generation
* *
* @param PDF $pdf Object PDF * @param TCPDF $pdf Object PDF
* @param Translate $outputlangs Object lang for output * @param Translate $outputlangs Object lang for output
* @param int $page_height Height of page * @param int $page_height Height of page
* @return void * @return void
*/ */
function pdf_pagehead(&$pdf,$outputlangs,$page_height) function pdf_pagehead(TCPDF $pdf, Translate $outputlangs,$page_height)
{ {
global $conf; global $conf;
@ -551,7 +552,7 @@ function pdf_pagehead(&$pdf,$outputlangs,$page_height)
/** /**
* Add a draft watermark on PDF files * Add a draft watermark on PDF files
* *
* @param PDF $pdf Object PDF * @param TCPDF $pdf Object PDF
* @param Translate $outputlangs Object lang * @param Translate $outputlangs Object lang
* @param int $h Height of PDF * @param int $h Height of PDF
* @param int $w Width of PDF * @param int $w Width of PDF
@ -559,7 +560,7 @@ function pdf_pagehead(&$pdf,$outputlangs,$page_height)
* @param string $text Text to show * @param string $text Text to show
* @return void * @return void
*/ */
function pdf_watermark(&$pdf, $outputlangs, $h, $w, $unit, $text) function pdf_watermark(TCPDF $pdf, Translate $outputlangs, $h, $w, $unit, $text)
{ {
// Print Draft Watermark // Print Draft Watermark
if ($unit=='pt') $k=1; if ($unit=='pt') $k=1;
@ -591,7 +592,7 @@ function pdf_watermark(&$pdf, $outputlangs, $h, $w, $unit, $text)
/** /**
* Show bank informations for PDF generation * Show bank informations for PDF generation
* *
* @param PDF $pdf Object PDF * @param TCPDF $pdf Object PDF
* @param Translate $outputlangs Object lang * @param Translate $outputlangs Object lang
* @param int $curx X * @param int $curx X
* @param int $cury Y * @param int $cury Y
@ -600,7 +601,7 @@ function pdf_watermark(&$pdf, $outputlangs, $h, $w, $unit, $text)
* @param int $default_font_size Default font size * @param int $default_font_size Default font size
* @return float The Y PDF position * @return float The Y PDF position
*/ */
function pdf_bank(&$pdf,$outputlangs,$curx,$cury,$account,$onlynumber=0,$default_font_size=10) function pdf_bank(TCPDF $pdf, Translate $outputlangs,$curx,$cury, Account $account,$onlynumber=0,$default_font_size=10)
{ {
global $mysoc, $conf; global $mysoc, $conf;
@ -783,19 +784,19 @@ function pdf_bank(&$pdf,$outputlangs,$curx,$cury,$account,$onlynumber=0,$default
/** /**
* Show footer of page for PDF generation * Show footer of page for PDF generation
* *
* @param PDF $pdf The PDF factory * @param TCPDF $pdf The PDF factory
* @param Translate $outputlangs Object lang for output * @param Translate $outputlangs Object lang for output
* @param string $paramfreetext Constant name of free text * @param string $paramfreetext Constant name of free text
* @param Societe $fromcompany Object company * @param Societe $fromcompany Object company
* @param int $marge_basse Margin bottom we use for the autobreak * @param int $marge_basse Margin bottom we use for the autobreak
* @param int $marge_gauche Margin left (no more used) * @param int $marge_gauche Margin left (no more used)
* @param int $page_hauteur Page height (no more used) * @param int $page_hauteur Page height (no more used)
* @param Object $object Object shown in PDF * @param object $object Object shown in PDF
* @param int $showdetails Show company details into footer. This param seems to not be used by standard version. (1=Show address, 2=Show managers, 3=Both) * @param int $showdetails Show company details into footer. This param seems to not be used by standard version. (1=Show address, 2=Show managers, 3=Both)
* @param int $hidefreetext 1=Hide free text, 0=Show free text * @param int $hidefreetext 1=Hide free text, 0=Show free text
* @return int Return height of bottom margin including footer text * @return int Return height of bottom margin including footer text
*/ */
function pdf_pagefoot(&$pdf,$outputlangs,$paramfreetext,$fromcompany,$marge_basse,$marge_gauche,$page_hauteur,$object,$showdetails=0,$hidefreetext=0) function pdf_pagefoot(TCPDF $pdf, Translate $outputlangs,$paramfreetext, Societe $fromcompany,$marge_basse,$marge_gauche,$page_hauteur,$object,$showdetails=0,$hidefreetext=0)
{ {
global $conf,$user; global $conf,$user;
@ -1015,7 +1016,7 @@ function pdf_pagefoot(&$pdf,$outputlangs,$paramfreetext,$fromcompany,$marge_bass
/** /**
* Show linked objects for PDF generation * Show linked objects for PDF generation
* *
* @param PDF $pdf Object PDF * @param TCPDF $pdf Object PDF
* @param object $object Object * @param object $object Object
* @param Translate $outputlangs Object lang * @param Translate $outputlangs Object lang
* @param int $posx X * @param int $posx X
@ -1026,7 +1027,7 @@ function pdf_pagefoot(&$pdf,$outputlangs,$paramfreetext,$fromcompany,$marge_bass
* @param string $default_font_size Font size * @param string $default_font_size Font size
* @return float The Y PDF position * @return float The Y PDF position
*/ */
function pdf_writeLinkedObjects(&$pdf,$object,$outputlangs,$posx,$posy,$w,$h,$align,$default_font_size) function pdf_writeLinkedObjects(TCPDF $pdf,$object, Translate $outputlangs,$posx,$posy,$w,$h,$align,$default_font_size)
{ {
$linkedobjects = pdf_getLinkedObjects($object,$outputlangs); $linkedobjects = pdf_getLinkedObjects($object,$outputlangs);
if (! empty($linkedobjects)) if (! empty($linkedobjects))
@ -1052,8 +1053,8 @@ function pdf_writeLinkedObjects(&$pdf,$object,$outputlangs,$posx,$posy,$w,$h,$al
/** /**
* Output line description into PDF * Output line description into PDF
* *
* @param PDF $pdf PDF object * @param TCPDF $pdf PDF object
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object lang for output * @param Translate $outputlangs Object lang for output
* @param int $w Width * @param int $w Width
@ -1065,7 +1066,7 @@ function pdf_writeLinkedObjects(&$pdf,$object,$outputlangs,$posx,$posy,$w,$h,$al
* @param int $issupplierline Is it a line for a supplier object ? * @param int $issupplierline Is it a line for a supplier object ?
* @return string * @return string
*/ */
function pdf_writelinedesc(&$pdf,$object,$i,$outputlangs,$w,$h,$posx,$posy,$hideref=0,$hidedesc=0,$issupplierline=0) function pdf_writelinedesc(TCPDF $pdf,$object,$i, Translate $outputlangs,$w,$h,$posx,$posy,$hideref=0,$hidedesc=0,$issupplierline=0)
{ {
global $db, $conf, $langs, $hookmanager; global $db, $conf, $langs, $hookmanager;
@ -1095,7 +1096,7 @@ function pdf_writelinedesc(&$pdf,$object,$i,$outputlangs,$w,$h,$posx,$posy,$hide
/** /**
* Return line description translated in outputlangs and encoded into htmlentities and with <br> * Return line description translated in outputlangs and encoded into htmlentities and with <br>
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number (0 = first line, 1 = second line, ...) * @param int $i Current line number (0 = first line, 1 = second line, ...)
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hideref Hide reference * @param int $hideref Hide reference
@ -1103,7 +1104,7 @@ function pdf_writelinedesc(&$pdf,$object,$i,$outputlangs,$w,$h,$posx,$posy,$hide
* @param int $issupplierline Is it a line for a supplier object ? * @param int $issupplierline Is it a line for a supplier object ?
* @return string String with line * @return string String with line
*/ */
function pdf_getlinedesc($object,$i,$outputlangs,$hideref=0,$hidedesc=0,$issupplierline=0) function pdf_getlinedesc($object,$i, Translate $outputlangs,$hideref=0,$hidedesc=0,$issupplierline=0)
{ {
global $db, $conf, $langs; global $db, $conf, $langs;
@ -1282,13 +1283,13 @@ function pdf_getlinedesc($object,$i,$outputlangs,$hideref=0,$hidedesc=0,$issuppl
/** /**
* Return line num * Return line num
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlinenum($object,$i,$outputlangs,$hidedetails=0) function pdf_getlinenum($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1315,13 +1316,13 @@ function pdf_getlinenum($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line product ref * Return line product ref
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlineref($object,$i,$outputlangs,$hidedetails=0) function pdf_getlineref($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1347,13 +1348,13 @@ function pdf_getlineref($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line ref_supplier * Return line ref_supplier
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlineref_supplier($object,$i,$outputlangs,$hidedetails=0) function pdf_getlineref_supplier($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1379,13 +1380,13 @@ function pdf_getlineref_supplier($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line vat rate * Return line vat rate
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlinevatrate($object,$i,$outputlangs,$hidedetails=0) function pdf_getlinevatrate($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1412,13 +1413,13 @@ function pdf_getlinevatrate($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line unit price excluding tax * Return line unit price excluding tax
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlineupexcltax($object,$i,$outputlangs,$hidedetails=0) function pdf_getlineupexcltax($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $conf, $hookmanager; global $conf, $hookmanager;
@ -1452,13 +1453,13 @@ function pdf_getlineupexcltax($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line unit price including tax * Return line unit price including tax
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide value (0 = no, 1 = yes, 2 = just special lines) * @param int $hidedetails Hide value (0 = no, 1 = yes, 2 = just special lines)
* @return string * @return string
*/ */
function pdf_getlineupwithtax($object,$i,$outputlangs,$hidedetails=0) function pdf_getlineupwithtax($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1485,13 +1486,13 @@ function pdf_getlineupwithtax($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line quantity * Return line quantity
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlineqty($object,$i,$outputlangs,$hidedetails=0) function pdf_getlineqty($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1519,13 +1520,13 @@ function pdf_getlineqty($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line quantity asked * Return line quantity asked
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlineqty_asked($object,$i,$outputlangs,$hidedetails=0) function pdf_getlineqty_asked($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1553,13 +1554,13 @@ function pdf_getlineqty_asked($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line quantity shipped * Return line quantity shipped
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlineqty_shipped($object,$i,$outputlangs,$hidedetails=0) function pdf_getlineqty_shipped($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1587,13 +1588,13 @@ function pdf_getlineqty_shipped($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line keep to ship quantity * Return line keep to ship quantity
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlineqty_keeptoship($object,$i,$outputlangs,$hidedetails=0) function pdf_getlineqty_keeptoship($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1621,14 +1622,14 @@ function pdf_getlineqty_keeptoship($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line unit * Return line unit
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @param HookManager $hookmanager Hook manager instance * @param HookManager $hookmanager Hook manager instance
* @return void * @return void
*/ */
function pdf_getlineunit($object, $i, $outputlangs, $hidedetails = 0, $hookmanager = false) function pdf_getlineunit($object, $i, Translate $outputlangs, $hidedetails = 0, $hookmanager = false)
{ {
global $langs; global $langs;
@ -1664,13 +1665,13 @@ function pdf_getlineunit($object, $i, $outputlangs, $hidedetails = 0, $hookmanag
/** /**
* Return line remise percent * Return line remise percent
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string * @return string
*/ */
function pdf_getlineremisepercent($object,$i,$outputlangs,$hidedetails=0) function pdf_getlineremisepercent($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1700,14 +1701,14 @@ function pdf_getlineremisepercent($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line percent * Return line percent
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @param HookManager $hookmanager Hook manager instance * @param HookManager $hookmanager Hook manager instance
* @return string * @return string
*/ */
function pdf_getlineprogress($object, $i, $outputlangs, $hidedetails = 0, $hookmanager = null) function pdf_getlineprogress($object, $i, Translate $outputlangs, $hidedetails = 0, HookManager $hookmanager = null)
{ {
$reshook=0; $reshook=0;
$result=''; $result='';
@ -1733,13 +1734,13 @@ function pdf_getlineprogress($object, $i, $outputlangs, $hidedetails = 0, $hookm
/** /**
* Return line total excluding tax * Return line total excluding tax
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines) * @param int $hidedetails Hide details (0=no, 1=yes, 2=just special lines)
* @return string Return total of line excl tax * @return string Return total of line excl tax
*/ */
function pdf_getlinetotalexcltax($object,$i,$outputlangs,$hidedetails=0) function pdf_getlinetotalexcltax($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $conf, $hookmanager; global $conf, $hookmanager;
@ -1777,13 +1778,13 @@ function pdf_getlinetotalexcltax($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return line total including tax * Return line total including tax
* *
* @param Object $object Object * @param object $object Object
* @param int $i Current line number * @param int $i Current line number
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @param int $hidedetails Hide value (0 = no, 1 = yes, 2 = just special lines) * @param int $hidedetails Hide value (0 = no, 1 = yes, 2 = just special lines)
* @return string Return total of line incl tax * @return string Return total of line incl tax
*/ */
function pdf_getlinetotalwithtax($object,$i,$outputlangs,$hidedetails=0) function pdf_getlinetotalwithtax($object,$i, Translate $outputlangs,$hidedetails=0)
{ {
global $hookmanager; global $hookmanager;
@ -1814,12 +1815,12 @@ function pdf_getlinetotalwithtax($object,$i,$outputlangs,$hidedetails=0)
/** /**
* Return total quantity of products and/or services * Return total quantity of products and/or services
* *
* @param Object $object Object * @param object $object Object
* @param string $type Type * @param string $type Type
* @param Translate $outputlangs Object langs for output * @param Translate $outputlangs Object langs for output
* @return integer * @return integer
*/ */
function pdf_getTotalQty($object,$type,$outputlangs) function pdf_getTotalQty($object,$type, Translate $outputlangs)
{ {
global $hookmanager; global $hookmanager;
@ -1866,7 +1867,7 @@ function pdf_getTotalQty($object,$type,$outputlangs)
* @param Translate $outputlangs Object lang for output * @param Translate $outputlangs Object lang for output
* @return array Linked objects * @return array Linked objects
*/ */
function pdf_getLinkedObjects($object,$outputlangs) function pdf_getLinkedObjects($object, Translate $outputlangs)
{ {
global $hookmanager; global $hookmanager;

View File

@ -636,7 +636,7 @@ function projectLinesPerDay(&$inc, $parent, $lines, &$level, &$projectsrole, &$t
// Form to add new time // Form to add new time
print '<td class="nowrap" align="center">'; print '<td class="nowrap" align="center">';
$tableCell=Form::select_date($preselectedday,$lines[$i]->id,1,1,2,"addtime",0,0,1,$disabledtask); $tableCell=Form::selectDate($preselectedday,$lines[$i]->id,1,1,2,"addtime",0,0,1,$disabledtask);
print $tableCell; print $tableCell;
print '</td><td align="right">'; print '</td><td align="right">';

View File

@ -154,9 +154,9 @@ class mailing_fraise extends MailingTargets
$s.='</select>'; $s.='</select>';
$s.='<br>'; $s.='<br>';
$s.=$langs->trans("DateEndSubscription").': &nbsp;'; $s.=$langs->trans("DateEndSubscription").': &nbsp;';
$s.=$langs->trans("After").' > '.Form::select_date(-1,'subscriptionafter',0,0,1,'fraise',1,0,1,0); $s.=$langs->trans("After").' > '.Form::selectDate(-1,'subscriptionafter',0,0,1,'fraise',1,0,1,0);
$s.=' &nbsp; '; $s.=' &nbsp; ';
$s.=$langs->trans("Before").' < '.Form::select_date(-1,'subscriptionbefore',0,0,1,'fraise',1,0,1,0); $s.=$langs->trans("Before").' < '.Form::selectDate(-1,'subscriptionbefore',0,0,1,'fraise',1,0,1,0);
return $s; return $s;
} }

View File

@ -382,16 +382,16 @@ if ((! empty($conf->service->enabled) || ($object->element == 'contrat')) && $da
if (! empty($object->element) && $object->element == 'contrat') if (! empty($object->element) && $object->element == 'contrat')
{ {
print $langs->trans("DateStartPlanned").' '; print $langs->trans("DateStartPlanned").' ';
Form::select_date($date_start,"date_start",$usehm,$usehm,1,"addproduct"); Form::selectDate($date_start,"date_start",$usehm,$usehm,1,"addproduct");
print ' &nbsp; '.$langs->trans("DateEndPlanned").' '; print ' &nbsp; '.$langs->trans("DateEndPlanned").' ';
Form::select_date($date_end,"date_end",$usehm,$usehm,1,"addproduct"); Form::selectDate($date_end,"date_end",$usehm,$usehm,1,"addproduct");
} }
else else
{ {
echo $langs->trans('ServiceLimitedDuration').' '.$langs->trans('From').' '; echo $langs->trans('ServiceLimitedDuration').' '.$langs->trans('From').' ';
echo Form::select_date($date_start,'date_start',empty($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?0:1,empty($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?0:1,1,"addproduct",1,0,1); echo Form::selectDate($date_start,'date_start',empty($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?0:1,empty($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?0:1,1,"addproduct",1,0,1);
echo ' '.$langs->trans('to').' '; echo ' '.$langs->trans('to').' ';
echo Form::select_date($date_end,'date_end',empty($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?0:1,empty($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?0:1,1,"addproduct",1,0,1); echo Form::selectDate($date_end,'date_end',empty($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?0:1,empty($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?0:1,1,"addproduct",1,0,1);
}; };
print '<script type="text/javascript">'; print '<script type="text/javascript">';
if (!$date_start) { if (!$date_start) {

View File

@ -226,9 +226,9 @@ $coldisplay=-1; // We remove first td
<td colspan="11"><?php echo $langs->trans('ServiceLimitedDuration').' '.$langs->trans('From').' '; ?> <td colspan="11"><?php echo $langs->trans('ServiceLimitedDuration').' '.$langs->trans('From').' '; ?>
<?php <?php
$hourmin=(isset($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE:''); $hourmin=(isset($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE)?$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE:'');
echo Form::select_date($line->date_start,'date_start',$hourmin,$hourmin,$line->date_start?0:1,"updateligne",1,0,1); echo Form::selectDate($line->date_start,'date_start',$hourmin,$hourmin,$line->date_start?0:1,"updateligne",1,0,1);
echo ' '.$langs->trans('to').' '; echo ' '.$langs->trans('to').' ';
echo Form::select_date($line->date_end,'date_end',$hourmin,$hourmin,$line->date_end?0:1,"updateligne",1,0,1); echo Form::selectDate($line->date_end,'date_end',$hourmin,$hourmin,$line->date_end?0:1,"updateligne",1,0,1);
print '<script type="text/javascript">'; print '<script type="text/javascript">';
if (!$line->date_start) { if (!$line->date_start) {
if (isset($conf->global->MAIN_DEFAULT_DATE_START_HOUR)) { if (isset($conf->global->MAIN_DEFAULT_DATE_START_HOUR)) {

View File

@ -460,11 +460,11 @@ if (($action=="create") || ($action=="edit"))
print $langs->trans('CronDtStart')."</td><td>"; print $langs->trans('CronDtStart')."</td><td>";
if(!empty($object->datestart)) if(!empty($object->datestart))
{ {
Form::select_date($object->datestart,'datestart',1,1,'',"cronform"); Form::selectDate($object->datestart,'datestart',1,1,'',"cronform");
} }
else else
{ {
Form::select_date('','datestart',1,1,'',"cronform"); Form::selectDate('','datestart',1,1,'',"cronform");
} }
print "</td>"; print "</td>";
print "<td>"; print "<td>";
@ -474,10 +474,10 @@ if (($action=="create") || ($action=="edit"))
print "<tr><td>"; print "<tr><td>";
print $langs->trans('CronDtEnd')."</td><td>"; print $langs->trans('CronDtEnd')."</td><td>";
if(!empty($object->dateend)){ if(!empty($object->dateend)){
Form::select_date($object->dateend,'dateend',1,1,'',"cronform"); Form::selectDate($object->dateend,'dateend',1,1,'',"cronform");
} }
else{ else{
Form::select_date(-1,'dateend',1,1,1,"cronform"); Form::selectDate(-1,'dateend',1,1,1,"cronform");
} }
print "</td>"; print "</td>";
print "<td>"; print "<td>";
@ -514,11 +514,11 @@ if (($action=="create") || ($action=="edit"))
print "</td><td>"; print "</td><td>";
if(!empty($object->datenextrun)) if(!empty($object->datenextrun))
{ {
Form::select_date($object->datenextrun,'datenextrun',1,1,'',"cronform"); Form::selectDate($object->datenextrun,'datenextrun',1,1,'',"cronform");
} }
else else
{ {
Form::select_date(-1,'datenextrun',1,1,'',"cronform"); Form::selectDate(-1,'datenextrun',1,1,'',"cronform");
} }
print "</td>"; print "</td>";
print "<td>"; print "<td>";

View File

@ -308,7 +308,7 @@ if ($action == 'create')
// Date // Date
print '<tr><td class="fieldrequired" width="25%">'.$langs->trans("Date").'</td><td>'; print '<tr><td class="fieldrequired" width="25%">'.$langs->trans("Date").'</td><td>';
Form::select_date($donation_date?$donation_date:-1,'','','','',"add",1,1); Form::selectDate($donation_date?$donation_date:-1,'','','','',"add",1,1);
print '</td>'; print '</td>';
// Amount // Amount
@ -430,7 +430,7 @@ if (! empty($id) && $action == 'edit')
// Date // Date
print "<tr>".'<td width="25%" class="fieldrequired">'.$langs->trans("Date").'</td><td>'; print "<tr>".'<td width="25%" class="fieldrequired">'.$langs->trans("Date").'</td><td>';
Form::select_date($object->date,'','','','',"update"); Form::selectDate($object->date,'','','','',"update");
print '</td>'; print '</td>';
// Amount // Amount

View File

@ -205,7 +205,7 @@ if (GETPOST("action") == 'create')
print '<tr><td class="fieldrequired">'.$langs->trans("Date").'</td><td colspan="2">'; print '<tr><td class="fieldrequired">'.$langs->trans("Date").'</td><td colspan="2">';
$datepaid = dol_mktime(12, 0, 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]); $datepaid = dol_mktime(12, 0, 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]);
$datepayment=empty($conf->global->MAIN_AUTOFILL_DATE)?(empty($_POST["remonth"])?-1:$datepaid):0; $datepayment=empty($conf->global->MAIN_AUTOFILL_DATE)?(empty($_POST["remonth"])?-1:$datepaid):0;
Form::select_date($datepayment,'','','','',"add_payment",1,1); Form::selectDate($datepayment,'','','','',"add_payment",1,1);
print "</td>"; print "</td>";
print '</tr>'; print '</tr>';

View File

@ -638,7 +638,7 @@ if ($action == 'create')
print '<td colspan="3">'; print '<td colspan="3">';
//print dol_print_date($object->date_livraison,"day"); // date_livraison come from order and will be stored into date_delivery planed. //print dol_print_date($object->date_livraison,"day"); // date_livraison come from order and will be stored into date_delivery planed.
$date_delivery = ($date_delivery?$date_delivery:$object->date_livraison); // $date_delivery comes from GETPOST $date_delivery = ($date_delivery?$date_delivery:$object->date_livraison); // $date_delivery comes from GETPOST
print Form::select_date($date_delivery?$date_delivery:-1,'date_delivery',1,1,1); print Form::selectDate($date_delivery?$date_delivery:-1,'date_delivery',1,1,1);
print "</td>\n"; print "</td>\n";
print '</tr>'; print '</tr>';
@ -1321,7 +1321,7 @@ else if ($id || $ref)
print '<form name="setdate_livraison" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="post">'; print '<form name="setdate_livraison" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="post">';
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">'; print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
print '<input type="hidden" name="action" value="setdate_livraison">'; print '<input type="hidden" name="action" value="setdate_livraison">';
print Form::select_date($object->date_delivery?$object->date_delivery:-1,'liv_',1,1,'',"setdate_livraison",1,0,1); print Form::selectDate($object->date_delivery?$object->date_delivery:-1,'liv_',1,1,'',"setdate_livraison",1,0,1);
print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">'; print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">';
print '</form>'; print '</form>';
} }

View File

@ -287,7 +287,7 @@ if ($id > 0 || ! empty($ref))
print '<form name="setdate_livraison" action="'.$_SERVER["PHP_SELF"].'?id='.$commande->id.'" method="post">'; print '<form name="setdate_livraison" action="'.$_SERVER["PHP_SELF"].'?id='.$commande->id.'" method="post">';
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">'; print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
print '<input type="hidden" name="action" value="setdatedelivery">'; print '<input type="hidden" name="action" value="setdatedelivery">';
Form::select_date($commande->date_livraison>0?$commande->date_livraison:-1,'liv_','','','',"setdatedelivery"); Form::selectDate($commande->date_livraison>0?$commande->date_livraison:-1,'liv_','','','',"setdatedelivery");
print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">'; print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">';
print '</form>'; print '</form>';
} }

View File

@ -1117,13 +1117,13 @@ if ($action == 'create')
print '<tr>'; print '<tr>';
print '<td class="fieldrequired">'.$langs->trans("DateStart").'</td>'; print '<td class="fieldrequired">'.$langs->trans("DateStart").'</td>';
print '<td>'; print '<td>';
Form::select_date($date_start?$date_start:-1,'date_debut',0,0,0,'',1,1); Form::selectDate($date_start?$date_start:-1,'date_debut',0,0,0,'',1,1);
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';
print '<tr>'; print '<tr>';
print '<td class="fieldrequired">'.$langs->trans("DateEnd").'</td>'; print '<td class="fieldrequired">'.$langs->trans("DateEnd").'</td>';
print '<td>'; print '<td>';
Form::select_date($date_end?$date_end:-1,'date_fin',0,0,0,'',1,1); Form::selectDate($date_end?$date_end:-1,'date_fin',0,0,0,'',1,1);
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';
print '<tr>'; print '<tr>';
@ -1237,13 +1237,13 @@ else
print '<tr>'; print '<tr>';
print '<td>'.$langs->trans("DateStart").'</td>'; print '<td>'.$langs->trans("DateStart").'</td>';
print '<td>'; print '<td>';
Form::select_date($object->date_debut,'date_debut'); Form::selectDate($object->date_debut,'date_debut');
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';
print '<tr>'; print '<tr>';
print '<td>'.$langs->trans("DateEnd").'</td>'; print '<td>'.$langs->trans("DateEnd").'</td>';
print '<td>'; print '<td>';
Form::select_date($object->date_fin,'date_fin'); Form::selectDate($object->date_fin,'date_fin');
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';
@ -1728,7 +1728,7 @@ else
// Select date // Select date
print '<td style="text-align:center;">'; print '<td style="text-align:center;">';
Form::select_date($objp->date,'date'); Form::selectDate($objp->date,'date');
print '</td>'; print '</td>';
// Select project // Select project
@ -1812,7 +1812,7 @@ else
// Select date // Select date
print '<td style="text-align:center;">'; print '<td style="text-align:center;">';
Form::select_date($date?$date:-1,'date'); Form::selectDate($date?$date:-1,'date');
print '</td>'; print '</td>';
// Select project // Select project

View File

@ -210,7 +210,7 @@ if (GETPOST("action") == 'create')
print '<tr><td class="fieldrequired">'.$langs->trans("Date").'</td><td colspan="2">'; print '<tr><td class="fieldrequired">'.$langs->trans("Date").'</td><td colspan="2">';
$datepaid = dol_mktime(12, 0, 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]); $datepaid = dol_mktime(12, 0, 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]);
$datepayment=empty($conf->global->MAIN_AUTOFILL_DATE)?(empty($_POST["remonth"])?-1:$datepaid):0; $datepayment=empty($conf->global->MAIN_AUTOFILL_DATE)?(empty($_POST["remonth"])?-1:$datepaid):0;
Form::select_date($datepayment,'','','','',"add_payment",1,1); Form::selectDate($datepayment,'','','','',"add_payment",1,1);
print "</td>"; print "</td>";
print '</tr>'; print '</tr>';

View File

@ -1549,7 +1549,7 @@ else if ($id > 0 || ! empty($ref))
// Date d'intervention // Date d'intervention
print '<td align="center" class="nowrap">'; print '<td align="center" class="nowrap">';
Form::select_date($db->jdate($objp->date_intervention),'di',1,1,0,"date_intervention"); Form::selectDate($db->jdate($objp->date_intervention),'di',1,1,0,"date_intervention");
print '</td>'; print '</td>';
// Duration // Duration
@ -1616,7 +1616,7 @@ else if ($id > 0 || ! empty($ref))
$timearray=dol_getdate($now); $timearray=dol_getdate($now);
if (! GETPOST('diday','int')) $timewithnohour=dol_mktime(0,0,0,$timearray['mon'],$timearray['mday'],$timearray['year']); if (! GETPOST('diday','int')) $timewithnohour=dol_mktime(0,0,0,$timearray['mon'],$timearray['mday'],$timearray['year']);
else $timewithnohour=dol_mktime(GETPOST('dihour','int'),GETPOST('dimin','int'), 0,GETPOST('dimonth','int'),GETPOST('diday','int'),GETPOST('diyear','int')); else $timewithnohour=dol_mktime(GETPOST('dihour','int'),GETPOST('dimin','int'), 0,GETPOST('dimonth','int'),GETPOST('diday','int'),GETPOST('diyear','int'));
Form::select_date($timewithnohour,'di',1,1,0,"addinter"); Form::selectDate($timewithnohour,'di',1,1,0,"addinter");
print '</td>'; print '</td>';
// Duration // Duration

View File

@ -1596,7 +1596,7 @@ if ($action=='create')
print '<td>'; print '<td>';
$usehourmin=0; $usehourmin=0;
if (! empty($conf->global->SUPPLIER_ORDER_USE_HOUR_FOR_DELIVERY_DATE)) $usehourmin=1; if (! empty($conf->global->SUPPLIER_ORDER_USE_HOUR_FOR_DELIVERY_DATE)) $usehourmin=1;
Form::select_date($datelivraison?$datelivraison:-1,'liv_',$usehourmin,$usehourmin,'',"set"); Form::selectDate($datelivraison?$datelivraison:-1,'liv_',$usehourmin,$usehourmin,'',"set");
print '</td></tr>'; print '</td></tr>';
// Bank Account // Bank Account
@ -2042,7 +2042,7 @@ elseif (! empty($object->id))
print '<input type="hidden" name="action" value="setdate_livraison">'; print '<input type="hidden" name="action" value="setdate_livraison">';
$usehourmin=0; $usehourmin=0;
if (! empty($conf->global->SUPPLIER_ORDER_USE_HOUR_FOR_DELIVERY_DATE)) $usehourmin=1; if (! empty($conf->global->SUPPLIER_ORDER_USE_HOUR_FOR_DELIVERY_DATE)) $usehourmin=1;
Form::select_date($object->date_livraison?$object->date_livraison:-1,'liv_',$usehourmin,$usehourmin,'',"setdate_livraison"); Form::selectDate($object->date_livraison?$object->date_livraison:-1,'liv_',$usehourmin,$usehourmin,'',"setdate_livraison");
print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">'; print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">';
print '</form>'; print '</form>';
} }
@ -2364,9 +2364,9 @@ elseif (! empty($object->id))
print '<br>'; print '<br>';
print $langs->trans('ServiceLimitedDuration').' '.$langs->trans('From').' '; print $langs->trans('ServiceLimitedDuration').' '.$langs->trans('From').' ';
print Form::select_date($date_start,'date_start'.$date_pf,$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE,$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE,1,'',1,0,1); print Form::selectDate($date_start,'date_start'.$date_pf,$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE,$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE,1,'',1,0,1);
print ' '.$langs->trans('to').' '; print ' '.$langs->trans('to').' ';
print Form::select_date($date_end,'date_end'.$date_pf,$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE,$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE,1,'',1,0,1); print Form::selectDate($date_end,'date_end'.$date_pf,$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE,$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE,1,'',1,0,1);
print '</td>'; print '</td>';
print '<td>'; print '<td>';
@ -2978,7 +2978,7 @@ elseif (! empty($object->id))
//print '<tr class="liste_titre"><td colspan="2">'.$langs->trans("ToOrder").'</td></tr>'; //print '<tr class="liste_titre"><td colspan="2">'.$langs->trans("ToOrder").'</td></tr>';
print '<tr><td>'.$langs->trans("OrderDate").'</td><td>'; print '<tr><td>'.$langs->trans("OrderDate").'</td><td>';
$date_com = dol_mktime(0, 0, 0, GETPOST('remonth'), GETPOST('reday'), GETPOST('reyear')); $date_com = dol_mktime(0, 0, 0, GETPOST('remonth'), GETPOST('reday'), GETPOST('reyear'));
print Form::select_date($date_com,'',1,1,'',"commande",1,0,1); print Form::selectDate($date_com,'',1,1,'',"commande",1,0,1);
print '</td></tr>'; print '</td></tr>';
print '<tr><td>'.$langs->trans("OrderMode").'</td><td>'; print '<tr><td>'.$langs->trans("OrderMode").'</td><td>';
@ -3005,7 +3005,7 @@ elseif (! empty($object->id))
print '<table class="border" width="100%">'; print '<table class="border" width="100%">';
//print '<tr class="liste_titre"><td colspan="2">'.$langs->trans("Receive").'</td></tr>'; //print '<tr class="liste_titre"><td colspan="2">'.$langs->trans("Receive").'</td></tr>';
print '<tr><td>'.$langs->trans("DeliveryDate").'</td><td>'; print '<tr><td>'.$langs->trans("DeliveryDate").'</td><td>';
print Form::select_date('','',1,1,'',"commande",1,0,1); print Form::selectDate('','',1,1,'',"commande",1,0,1);
print "</td></tr>\n"; print "</td></tr>\n";
print "<tr><td>".$langs->trans("Delivery")."</td><td>\n"; print "<tr><td>".$langs->trans("Delivery")."</td><td>\n";

View File

@ -510,11 +510,11 @@ if ($id > 0 || ! empty($ref))
print '</td>'; print '</td>';
print '<td>'; print '<td>';
$dlcdatesuffix=dol_mktime(0, 0, 0, GETPOST('dlc'.$suffix.'month'), GETPOST('dlc'.$suffix.'day'), GETPOST('dlc'.$suffix.'year')); $dlcdatesuffix=dol_mktime(0, 0, 0, GETPOST('dlc'.$suffix.'month'), GETPOST('dlc'.$suffix.'day'), GETPOST('dlc'.$suffix.'year'));
Form::select_date($dlcdatesuffix,'dlc'.$suffix,'','',1,""); Form::selectDate($dlcdatesuffix,'dlc'.$suffix,'','',1,"");
print '</td>'; print '</td>';
print '<td>'; print '<td>';
$dluodatesuffix=dol_mktime(0, 0, 0, GETPOST('dluo'.$suffix.'month'), GETPOST('dluo'.$suffix.'day'), GETPOST('dluo'.$suffix.'year')); $dluodatesuffix=dol_mktime(0, 0, 0, GETPOST('dluo'.$suffix.'month'), GETPOST('dluo'.$suffix.'day'), GETPOST('dluo'.$suffix.'year'));
Form::select_date($dluodatesuffix,'dluo'.$suffix,'','',1,""); Form::selectDate($dluodatesuffix,'dluo'.$suffix,'','',1,"");
print '</td>'; print '</td>';
print '<td colspan="2">&nbsp</td>'; // Qty ordered + qty already dispatached print '<td colspan="2">&nbsp</td>'; // Qty ordered + qty already dispatached
} }

View File

@ -323,7 +323,7 @@ if ($action == 'create' && !$error) {
// Date invoice // Date invoice
print '<tr><td class="fieldrequired">' . $langs->trans('Date') . '</td><td colspan="2">'; print '<tr><td class="fieldrequired">' . $langs->trans('Date') . '</td><td colspan="2">';
Form::select_date('', '', '', '', '', "add", 1, 1); Form::selectDate('', '', '', '', '', "add", 1, 1);
print '</td></tr>'; print '</td></tr>';
// Payment term // Payment term
print '<tr><td class="nowrap">' . $langs->trans('PaymentConditionsShort') . '</td><td colspan="2">'; print '<tr><td class="nowrap">' . $langs->trans('PaymentConditionsShort') . '</td><td colspan="2">';
@ -469,8 +469,8 @@ if (($action != 'create' && $action != 'add') && !$error) {
$num = $db->num_rows($resql); $num = $db->num_rows($resql);
print load_fiche_titre($title); print load_fiche_titre($title);
$i = 0; $i = 0;
$period = Form::select_date($date_start, 'date_start', 0, 0, 1, '', 1, 0, 1) . ' - ' . Form::select_date($date_end, 'date_end', 0, 0, 1, '', 1, 0, 1); $period = Form::selectDate($date_start, 'date_start', 0, 0, 1, '', 1, 0, 1) . ' - ' . Form::selectDate($date_end, 'date_end', 0, 0, 1, '', 1, 0, 1);
$periodely = Form::select_date($date_starty, 'date_start_dely', 0, 0, 1, '', 1, 0, 1) . ' - ' . Form::select_date($date_endy, 'date_end_dely', 0, 0, 1, '', 1, 0, 1); $periodely = Form::selectDate($date_starty, 'date_start_dely', 0, 0, 1, '', 1, 0, 1) . ' - ' . Form::selectDate($date_endy, 'date_end_dely', 0, 0, 1, '', 1, 0, 1);
if (! empty($socid)) { if (! empty($socid)) {
// Company // Company

View File

@ -1483,12 +1483,12 @@ if ($action == 'create')
// Date invoice // Date invoice
print '<tr><td class="fieldrequired">'.$langs->trans('DateInvoice').'</td><td>'; print '<tr><td class="fieldrequired">'.$langs->trans('DateInvoice').'</td><td>';
Form::select_date($dateinvoice,'','','','',"add",1,1); Form::selectDate($dateinvoice,'','','','',"add",1,1);
print '</td></tr>'; print '</td></tr>';
// Due date // Due date
print '<tr><td>'.$langs->trans('DateMaxPayment').'</td><td>'; print '<tr><td>'.$langs->trans('DateMaxPayment').'</td><td>';
Form::select_date($datedue,'ech','','','',"add",1,1); Form::selectDate($datedue,'ech','','','',"add",1,1);
print '</td></tr>'; print '</td></tr>';
// Payment term // Payment term

View File

@ -355,7 +355,7 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie
print $supplierstatic->getNomUrl(1,'supplier'); print $supplierstatic->getNomUrl(1,'supplier');
print '</td></tr>'; print '</td></tr>';
print '<tr><td class="fieldrequired">'.$langs->trans('Date').'</td><td>'; print '<tr><td class="fieldrequired">'.$langs->trans('Date').'</td><td>';
Form::select_date($dateinvoice,'','','','',"addpaiement",1,1,0,0,'','',$object->date); Form::selectDate($dateinvoice,'','','','',"addpaiement",1,1,0,0,'','',$object->date);
print '</td>'; print '</td>';
print '<td>'.$langs->trans('Comments').'</td></tr>'; print '<td>'.$langs->trans('Comments').'</td></tr>';
print '<tr><td class="fieldrequired">'.$langs->trans('PaymentMode').'</td><td>'; print '<tr><td class="fieldrequired">'.$langs->trans('PaymentMode').'</td><td>';

View File

@ -823,10 +823,10 @@ if (empty($id) || $action == 'add' || $action == 'request' || $action == 'create
print '<td>'; print '<td>';
// Si la demande ne vient pas de l'agenda // Si la demande ne vient pas de l'agenda
if (! GETPOST('date_debut_')) { if (! GETPOST('date_debut_')) {
Form::select_date(-1,'date_debut_'); Form::selectDate(-1,'date_debut_');
} else { } else {
$tmpdate = dol_mktime(0, 0, 0, GETPOST('date_debut_month'), GETPOST('date_debut_day'), GETPOST('date_debut_year')); $tmpdate = dol_mktime(0, 0, 0, GETPOST('date_debut_month'), GETPOST('date_debut_day'), GETPOST('date_debut_year'));
Form::select_date($tmpdate,'date_debut_'); Form::selectDate($tmpdate,'date_debut_');
} }
print ' &nbsp; &nbsp; '; print ' &nbsp; &nbsp; ';
print Form::selectarray('starthalfday', $listhalfday, (GETPOST('starthalfday')?GETPOST('starthalfday'):'morning')); print Form::selectarray('starthalfday', $listhalfday, (GETPOST('starthalfday')?GETPOST('starthalfday'):'morning'));
@ -839,10 +839,10 @@ if (empty($id) || $action == 'add' || $action == 'request' || $action == 'create
print '<td>'; print '<td>';
// Si la demande ne vient pas de l'agenda // Si la demande ne vient pas de l'agenda
if (! GETPOST('date_fin_')) { if (! GETPOST('date_fin_')) {
Form::select_date(-1,'date_fin_'); Form::selectDate(-1,'date_fin_');
} else { } else {
$tmpdate = dol_mktime(0, 0, 0, GETPOST('date_fin_month'), GETPOST('date_fin_day'), GETPOST('date_fin_year')); $tmpdate = dol_mktime(0, 0, 0, GETPOST('date_fin_month'), GETPOST('date_fin_day'), GETPOST('date_fin_year'));
Form::select_date($tmpdate,'date_fin_'); Form::selectDate($tmpdate,'date_fin_');
} }
print ' &nbsp; &nbsp; '; print ' &nbsp; &nbsp; ';
print Form::selectarray('endhalfday', $listhalfday, (GETPOST('endhalfday')?GETPOST('endhalfday'):'afternoon')); print Form::selectarray('endhalfday', $listhalfday, (GETPOST('endhalfday')?GETPOST('endhalfday'):'afternoon'));
@ -1035,7 +1035,7 @@ else
print '<tr>'; print '<tr>';
print '<td>'.$langs->trans('DateDebCP').' ('.$langs->trans("FirstDayOfHoliday").')</td>'; print '<td>'.$langs->trans('DateDebCP').' ('.$langs->trans("FirstDayOfHoliday").')</td>';
print '<td>'; print '<td>';
Form::select_date($cp->date_debut,'date_debut_'); Form::selectDate($cp->date_debut,'date_debut_');
print ' &nbsp; &nbsp; '; print ' &nbsp; &nbsp; ';
print Form::selectarray('starthalfday', $listhalfday, (GETPOST('starthalfday')?GETPOST('starthalfday'):$starthalfday)); print Form::selectarray('starthalfday', $listhalfday, (GETPOST('starthalfday')?GETPOST('starthalfday'):$starthalfday));
print '</td>'; print '</td>';
@ -1057,7 +1057,7 @@ else
print '<tr>'; print '<tr>';
print '<td>'.$langs->trans('DateFinCP').' ('.$langs->trans("LastDayOfHoliday").')</td>'; print '<td>'.$langs->trans('DateFinCP').' ('.$langs->trans("LastDayOfHoliday").')</td>';
print '<td>'; print '<td>';
Form::select_date($cp->date_fin,'date_fin_'); Form::selectDate($cp->date_fin,'date_fin_');
print ' &nbsp; &nbsp; '; print ' &nbsp; &nbsp; ';
print Form::selectarray('endhalfday', $listhalfday, (GETPOST('endhalfday')?GETPOST('endhalfday'):$endhalfday)); print Form::selectarray('endhalfday', $listhalfday, (GETPOST('endhalfday')?GETPOST('endhalfday'):$endhalfday));
print '</td>'; print '</td>';

View File

@ -151,7 +151,7 @@ if ($object->id)
print '<tr>'; print '<tr>';
print '<td>'.$langs->trans('DateDebCP').' ('.$langs->trans("FirstDayOfHoliday").')</td>'; print '<td>'.$langs->trans('DateDebCP').' ('.$langs->trans("FirstDayOfHoliday").')</td>';
print '<td>'; print '<td>';
Form::select_date($object->date_debut,'date_debut_'); Form::selectDate($object->date_debut,'date_debut_');
print ' &nbsp; &nbsp; '; print ' &nbsp; &nbsp; ';
print Form::selectarray('starthalfday', $listhalfday, (GETPOST('starthalfday')?GETPOST('starthalfday'):$starthalfday)); print Form::selectarray('starthalfday', $listhalfday, (GETPOST('starthalfday')?GETPOST('starthalfday'):$starthalfday));
print '</td>'; print '</td>';
@ -173,7 +173,7 @@ if ($object->id)
print '<tr>'; print '<tr>';
print '<td>'.$langs->trans('DateFinCP').' ('.$langs->trans("LastDayOfHoliday").')</td>'; print '<td>'.$langs->trans('DateFinCP').' ('.$langs->trans("LastDayOfHoliday").')</td>';
print '<td>'; print '<td>';
Form::select_date($object->date_fin,'date_fin_'); Form::selectDate($object->date_fin,'date_fin_');
print ' &nbsp; &nbsp; '; print ' &nbsp; &nbsp; ';
print Form::selectarray('endhalfday', $listhalfday, (GETPOST('endhalfday')?GETPOST('endhalfday'):$endhalfday)); print Form::selectarray('endhalfday', $listhalfday, (GETPOST('endhalfday')?GETPOST('endhalfday'):$endhalfday));
print '</td>'; print '</td>';

View File

@ -647,7 +647,7 @@ else
print '<form name="setdate_livraison" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="post">'; print '<form name="setdate_livraison" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="post">';
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">'; print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
print '<input type="hidden" name="action" value="setdate_livraison">'; print '<input type="hidden" name="action" value="setdate_livraison">';
Form::select_date($object->date_delivery?$object->date_delivery:-1,'liv_',1,1,'',"setdate_livraison"); Form::selectDate($object->date_delivery?$object->date_delivery:-1,'liv_',1,1,'',"setdate_livraison");
print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">'; print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">';
print '</form>'; print '</form>';
} }

View File

@ -218,13 +218,13 @@ if ($action == 'create')
// Date Start // Date Start
print "<tr>"; print "<tr>";
print '<td class="fieldrequired">'.$langs->trans("DateStart").'</td><td>'; print '<td class="fieldrequired">'.$langs->trans("DateStart").'</td><td>';
print Form::select_date($datestart?$datestart:-1,'start','','','','add',1,1,1); print Form::selectDate($datestart?$datestart:-1,'start','','','','add',1,1,1);
print '</td></tr>'; print '</td></tr>';
// Date End // Date End
print "<tr>"; print "<tr>";
print '<td class="fieldrequired">'.$langs->trans("DateEnd").'</td><td>'; print '<td class="fieldrequired">'.$langs->trans("DateEnd").'</td><td>';
print Form::select_date($dateend?$dateend:-1,'end','','','','add',1,1,1); print Form::selectDate($dateend?$dateend:-1,'end','','','','add',1,1,1);
print '</td></tr>'; print '</td></tr>';
// Number of terms // Number of terms
@ -356,7 +356,7 @@ if ($id > 0)
print "<td>"; print "<td>";
if ($action == 'edit') if ($action == 'edit')
{ {
print Form::select_date($object->datestart, 'start', 0, 0, 0, 'update', 1, 0, 1); print Form::selectDate($object->datestart, 'start', 0, 0, 0, 'update', 1, 0, 1);
} }
else else
{ {
@ -369,7 +369,7 @@ if ($id > 0)
print "<td>"; print "<td>";
if ($action == 'edit') if ($action == 'edit')
{ {
print Form::select_date($object->dateend, 'end', 0, 0, 0, 'update', 1, 0, 1); print Form::selectDate($object->dateend, 'end', 0, 0, 0, 'update', 1, 0, 1);
} }
else else
{ {

View File

@ -123,7 +123,7 @@ if ($object->id)
print "<td>"; print "<td>";
if ($action == 'edit') if ($action == 'edit')
{ {
print Form::select_date($object->datestart, 'start', 0, 0, 0, 'loan', 1, 0, 1); print Form::selectDate($object->datestart, 'start', 0, 0, 0, 'loan', 1, 0, 1);
} }
else else
{ {
@ -137,7 +137,7 @@ if ($object->id)
print "<td>"; print "<td>";
if ($action == 'edit') if ($action == 'edit')
{ {
print Form::select_date($object->dateend, 'end', 0, 0, 0, 'loan', 1, 0, 1); print Form::selectDate($object->dateend, 'end', 0, 0, 0, 'loan', 1, 0, 1);
} }
else else
{ {

View File

@ -200,7 +200,7 @@ if ($_GET["action"] == 'create')
print '<tr><td width="25%" class="fieldrequired">'.$langs->trans("Date").'</td><td colspan="2">'; print '<tr><td width="25%" class="fieldrequired">'.$langs->trans("Date").'</td><td colspan="2">';
$datepaid = dol_mktime(12, 0, 0, GETPOST('remonth', 'int'), GETPOST('reday', 'int'), GETPOST('reyear', 'int')); $datepaid = dol_mktime(12, 0, 0, GETPOST('remonth', 'int'), GETPOST('reday', 'int'), GETPOST('reyear', 'int'));
$datepayment = empty($conf->global->MAIN_AUTOFILL_DATE)?(empty($_POST["remonth"])?-1:$datepaye):0; $datepayment = empty($conf->global->MAIN_AUTOFILL_DATE)?(empty($_POST["remonth"])?-1:$datepaye):0;
Form::select_date($datepayment, '', '', '', '', "add_payment", 1, 1); Form::selectDate($datepayment, '', '', '', '', "add_payment", 1, 1);
print "</td>"; print "</td>";
print '</tr>'; print '</tr>';

View File

@ -101,11 +101,11 @@ if ($user->rights->margins->read->all) {
// Start date // Start date
print '<td>'.$langs->trans('StartDate').' ('.$langs->trans("DateValidation").')</td>'; print '<td>'.$langs->trans('StartDate').' ('.$langs->trans("DateValidation").')</td>';
print '<td width="20%">'; print '<td width="20%">';
Form::select_date($startdate,'startdate','','',1,"sel",1,1); Form::selectDate($startdate,'startdate','','',1,"sel",1,1);
print '</td>'; print '</td>';
print '<td width="20%">'.$langs->trans('EndDate').' ('.$langs->trans("DateValidation").')</td>'; print '<td width="20%">'.$langs->trans('EndDate').' ('.$langs->trans("DateValidation").')</td>';
print '<td width="20%">'; print '<td width="20%">';
Form::select_date($enddate,'enddate','','',1,"sel",1,1); Form::selectDate($enddate,'enddate','','',1,"sel",1,1);
print '</td>'; print '</td>';
print '<td style="text-align: center;">'; print '<td style="text-align: center;">';
print '<input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans('Launch')).'" />'; print '<input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans('Launch')).'" />';

View File

@ -126,11 +126,11 @@ print '<table class="border" width="100%">';
// Start date // Start date
print '<td>' . $langs->trans('StartDate') . ' (' . $langs->trans("DateValidation") . ')</td>'; print '<td>' . $langs->trans('StartDate') . ' (' . $langs->trans("DateValidation") . ')</td>';
print '<td width="20%">'; print '<td width="20%">';
Form::select_date($startdate, 'startdate', '', '', 1, "sel", 1, 1); Form::selectDate($startdate, 'startdate', '', '', 1, "sel", 1, 1);
print '</td>'; print '</td>';
print '<td width="20%">' . $langs->trans('EndDate') . ' (' . $langs->trans("DateValidation") . ')</td>'; print '<td width="20%">' . $langs->trans('EndDate') . ' (' . $langs->trans("DateValidation") . ')</td>';
print '<td width="20%">'; print '<td width="20%">';
Form::select_date($enddate, 'enddate', '', '', 1, "sel", 1, 1); Form::selectDate($enddate, 'enddate', '', '', 1, "sel", 1, 1);
print '</td>'; print '</td>';
print '<td style="text-align: center;">'; print '<td style="text-align: center;">';
print '<input type="submit" class="button" value="' . dol_escape_htmltag($langs->trans('Launch')) . '" name="button_search" />'; print '<input type="submit" class="button" value="' . dol_escape_htmltag($langs->trans('Launch')) . '" name="button_search" />';

View File

@ -122,11 +122,11 @@ if (! $sortfield)
// Start date // Start date
print '<td>'.$langs->trans('StartDate').' ('.$langs->trans("DateValidation").')</td>'; print '<td>'.$langs->trans('StartDate').' ('.$langs->trans("DateValidation").')</td>';
print '<td width="20%">'; print '<td width="20%">';
Form::select_date($startdate,'startdate','','',1,"sel",1,1); Form::selectDate($startdate,'startdate','','',1,"sel",1,1);
print '</td>'; print '</td>';
print '<td width="20%">'.$langs->trans('EndDate').' ('.$langs->trans("DateValidation").')</td>'; print '<td width="20%">'.$langs->trans('EndDate').' ('.$langs->trans("DateValidation").')</td>';
print '<td width="20%">'; print '<td width="20%">';
Form::select_date($enddate,'enddate','','',1,"sel",1,1); Form::selectDate($enddate,'enddate','','',1,"sel",1,1);
print '</td>'; print '</td>';
print '<td style="text-align: center;">'; print '<td style="text-align: center;">';
print '<input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans('Launch')).'" />'; print '<input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans('Launch')).'" />';

View File

@ -124,11 +124,11 @@ else {
// Start date // Start date
print '<td>'.$langs->trans('StartDate').' ('.$langs->trans("DateValidation").')</td>'; print '<td>'.$langs->trans('StartDate').' ('.$langs->trans("DateValidation").')</td>';
print '<td width="20%">'; print '<td width="20%">';
Form::select_date($startdate,'startdate','','',1,"sel",1,1); Form::selectDate($startdate,'startdate','','',1,"sel",1,1);
print '</td>'; print '</td>';
print '<td width="20%">'.$langs->trans('EndDate').' ('.$langs->trans("DateValidation").')</td>'; print '<td width="20%">'.$langs->trans('EndDate').' ('.$langs->trans("DateValidation").')</td>';
print '<td width="20%">'; print '<td width="20%">';
Form::select_date($enddate,'enddate','','',1,"sel",1,1); Form::selectDate($enddate,'enddate','','',1,"sel",1,1);
print '</td>'; print '</td>';
print '<td style="text-align: center;">'; print '<td style="text-align: center;">';
print '<input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans('Launch')).'" />'; print '<input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans('Launch')).'" />';

View File

@ -282,7 +282,7 @@ print '</td></tr>';
// Expire date // Expire date
print '<tr><td>'.$langs->trans('ExpireDate').'</td><td colspan="2">'; print '<tr><td>'.$langs->trans('ExpireDate').'</td><td colspan="2">';
if ($action == 'edit') print Form::select_date($expiredate?$expiredate:$object->date_fin,'expire',0,0,0,'',1,0,1); if ($action == 'edit') print Form::selectDate($expiredate?$expiredate:$object->date_fin,'expire',0,0,0,'',1,0,1);
else print dol_print_date($object->date_fin,'day'); else print dol_print_date($object->date_fin,'day');
print '</td></tr>'; print '</td></tr>';

View File

@ -457,7 +457,7 @@ print '</td></tr>';
// Expire date // Expire date
print '<tr><td>'.$langs->trans('ExpireDate').'</td><td colspan="2">'; print '<tr><td>'.$langs->trans('ExpireDate').'</td><td colspan="2">';
if ($action == 'edit') print Form::select_date($expiredate?$expiredate:$object->date_fin,'expire',0,0,0,'',1,0,1); if ($action == 'edit') print Form::selectDate($expiredate?$expiredate:$object->date_fin,'expire',0,0,0,'',1,0,1);
else print dol_print_date($object->date_fin,'day'); else print dol_print_date($object->date_fin,'day');
print '</td></tr>'; print '</td></tr>';

View File

@ -156,7 +156,7 @@ print '</tr>'."\n";
print '<tr><td class="fieldrequired">'. $langs->trans("ExpireDate") .'</td><td>'; print '<tr><td class="fieldrequired">'. $langs->trans("ExpireDate") .'</td><td>';
print Form::select_date($champdatefin?$champdatefin:-1,'champdatefin','','','',"add",1,0,1); print Form::selectDate($champdatefin?$champdatefin:-1,'champdatefin','','','',"add",1,0,1);
print '</tr>'."\n"; print '</tr>'."\n";
print '</table>'."\n"; print '</table>'."\n";

View File

@ -737,10 +737,10 @@ if ($resql)
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST"><input type="hidden" name="pdluoid" value="'.$pdluo->id.'"><input type="hidden" name="action" value="updateline"><input type="hidden" name="id" value="'.$id.'"><table class="noborder" width="100%"><tr><td width="10%"></td>'; print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST"><input type="hidden" name="pdluoid" value="'.$pdluo->id.'"><input type="hidden" name="action" value="updateline"><input type="hidden" name="id" value="'.$id.'"><table class="noborder" width="100%"><tr><td width="10%"></td>';
print '<td align="right" width="10%"><input type="text" name="batch_number" value="'.$pdluo->batch.'"></td>'; print '<td align="right" width="10%"><input type="text" name="batch_number" value="'.$pdluo->batch.'"></td>';
print '<td align="center" width="10%">'; print '<td align="center" width="10%">';
Form::select_date($pdluo->eatby,'eatby','','',1,'',1,0,1); Form::selectDate($pdluo->eatby,'eatby','','',1,'',1,0,1);
print '</td>'; print '</td>';
print '<td align="center" width="10%">'; print '<td align="center" width="10%">';
Form::select_date($pdluo->sellby,'sellby','','',1,'',1,0,1); Form::selectDate($pdluo->sellby,'sellby','','',1,'',1,0,1);
print '</td>'; print '</td>';
print '<td align="right" width="10%">'.$pdluo->qty.($pdluo->qty<0?' '.img_warning():'').'</td>'; print '<td align="right" width="10%">'.$pdluo->qty.($pdluo->qty<0?' '.img_warning():'').'</td>';
print '<td colspan="4"><input type="submit" class="button" id="savelinebutton" name="save" value="'.$langs->trans("Save").'">'; print '<td colspan="4"><input type="submit" class="button" id="savelinebutton" name="save" value="'.$langs->trans("Save").'">';

View File

@ -239,7 +239,7 @@ if ($resql)
'<input type="text" class="flat" name="search_ttc" value="' . $sttc . '">'. '<input type="text" class="flat" name="search_ttc" value="' . $sttc . '">'.
'</td>'. '</td>'.
'<td class="liste_titre">'. '<td class="liste_titre">'.
Form::select_date('', 'search_date', 0, 0, 1, '', 1, 0, 1, 0, ''). Form::selectDate('', 'search_date', 0, 0, 1, '', 1, 0, 1, 0, '').
'</td>'. '</td>'.
'<td class="liste_titre" align="right">'; '<td class="liste_titre" align="right">';
$src = DOL_URL_ROOT . '/theme/' . $conf->theme . '/img/search.png'; $src = DOL_URL_ROOT . '/theme/' . $conf->theme . '/img/search.png';

View File

@ -93,12 +93,12 @@
print '</tr><tr>'; print '</tr><tr>';
print '<td colspan="2">'.$langs->trans("l_eatby").'</td><td>'; print '<td colspan="2">'.$langs->trans("l_eatby").'</td><td>';
$eatbyselected=dol_mktime(0, 0, 0, GETPOST('eatbymonth'), GETPOST('eatbyday'), GETPOST('eatbyyear')); $eatbyselected=dol_mktime(0, 0, 0, GETPOST('eatbymonth'), GETPOST('eatbyday'), GETPOST('eatbyyear'));
Form::select_date($eatbyselected,'eatby','','',1,""); Form::selectDate($eatbyselected,'eatby','','',1,"");
print '</td>'; print '</td>';
print '<td></td>'; print '<td></td>';
print '<td>'.$langs->trans("l_sellby").'</td><td>'; print '<td>'.$langs->trans("l_sellby").'</td><td>';
$sellbyselected=dol_mktime(0, 0, 0, GETPOST('sellbymonth'), GETPOST('sellbyday'), GETPOST('sellbyyear')); $sellbyselected=dol_mktime(0, 0, 0, GETPOST('sellbymonth'), GETPOST('sellbyday'), GETPOST('sellbyyear'));
Form::select_date($sellbyselected,'sellby','','',1,""); Form::selectDate($sellbyselected,'sellby','','',1,"");
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';
} }

View File

@ -92,10 +92,10 @@
print '</td>'; print '</td>';
print '</tr><tr>'; print '</tr><tr>';
print '<td>'.$langs->trans("l_eatby").'</td><td>'; print '<td>'.$langs->trans("l_eatby").'</td><td>';
print Form::select_date(($d_eatby?$d_eatby:$pdluo->eatby),'eatby','','',1,"", 1, 0, 1, ($pdluoid > 0 ? 1 : 0)); // If form was opened for a specific pdluoid, field is disabled print Form::selectDate(($d_eatby?$d_eatby:$pdluo->eatby),'eatby','','',1,"", 1, 0, 1, ($pdluoid > 0 ? 1 : 0)); // If form was opened for a specific pdluoid, field is disabled
print '</td>'; print '</td>';
print '<td>'.$langs->trans("l_sellby").'</td><td>'; print '<td>'.$langs->trans("l_sellby").'</td><td>';
print Form::select_date(($d_sellby?$d_sellby:$pdluo->sellby),'sellby','','',1,"", 1, 0, 1, ($pdluoid > 0 ? 1 : 0)); // If form was opened for a specific pdluoid, field is disabled print Form::selectDate(($d_sellby?$d_sellby:$pdluo->sellby),'sellby','','',1,"", 1, 0, 1, ($pdluoid > 0 ? 1 : 0)); // If form was opened for a specific pdluoid, field is disabled
print '</td>'; print '</td>';
print '<td colspan="2"></td>'; print '<td colspan="2"></td>';
print '</tr>'; print '</tr>';

View File

@ -296,7 +296,7 @@ $nav ="<a href=\"?year=".$prev_year."&amp;month=".$prev_month."&amp;day=".$prev_
$nav.=" <span id=\"month_name\">".dol_print_date(dol_mktime(0,0,0,$month,$day,$year),"day")." </span>\n"; $nav.=" <span id=\"month_name\">".dol_print_date(dol_mktime(0,0,0,$month,$day,$year),"day")." </span>\n";
$nav.="<a href=\"?year=".$next_year."&amp;month=".$next_month."&amp;day=".$next_day.$param."\">".img_next($langs->trans("Next"))."</a>\n"; $nav.="<a href=\"?year=".$next_year."&amp;month=".$next_month."&amp;day=".$next_day.$param."\">".img_next($langs->trans("Next"))."</a>\n";
$nav.=" &nbsp; (<a href=\"?year=".$nowyear."&amp;month=".$nowmonth."&amp;day=".$nowday.$param."\">".$langs->trans("Today")."</a>)"; $nav.=" &nbsp; (<a href=\"?year=".$nowyear."&amp;month=".$nowmonth."&amp;day=".$nowday.$param."\">".$langs->trans("Today")."</a>)";
$nav.='<br>'.Form::select_date(-1,'',0,0,2,"addtime",1,0,1).' '; $nav.='<br>'.Form::selectDate(-1,'',0,0,2,"addtime",1,0,1).' ';
$nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">'; $nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">';
$picto='calendarweek'; $picto='calendarweek';

View File

@ -274,7 +274,7 @@ $nav ="<a href=\"?year=".$prev_year."&amp;month=".$prev_month."&amp;day=".$prev_
$nav.=" <span id=\"month_name\">".dol_print_date(dol_mktime(0,0,0,$first_month,$first_day,$first_year),"%Y").", ".$langs->trans("Week")." ".$week." </span>\n"; $nav.=" <span id=\"month_name\">".dol_print_date(dol_mktime(0,0,0,$first_month,$first_day,$first_year),"%Y").", ".$langs->trans("Week")." ".$week." </span>\n";
$nav.="<a href=\"?year=".$next_year."&amp;month=".$next_month."&amp;day=".$next_day.$param."\">".img_next($langs->trans("Next"))."</a>\n"; $nav.="<a href=\"?year=".$next_year."&amp;month=".$next_month."&amp;day=".$next_day.$param."\">".img_next($langs->trans("Next"))."</a>\n";
$nav.=" &nbsp; (<a href=\"?year=".$nowyear."&amp;month=".$nowmonth."&amp;day=".$nowday.$param."\">".$langs->trans("Today")."</a>)"; $nav.=" &nbsp; (<a href=\"?year=".$nowyear."&amp;month=".$nowmonth."&amp;day=".$nowday.$param."\">".$langs->trans("Today")."</a>)";
$nav.='<br>'.Form::select_date(-1,'',0,0,2,"addtime",1,0,1).' '; $nav.='<br>'.Form::selectDate(-1,'',0,0,2,"addtime",1,0,1).' ';
$nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">'; $nav.=' <input type="submit" name="submitdateselect" class="button" value="'.$langs->trans("Refresh").'">';
$picto='calendarweek'; $picto='calendarweek';

View File

@ -492,12 +492,12 @@ if ($action == 'create' && $user->rights->projet->creer)
// Date start // Date start
print '<tr><td>'.$langs->trans("DateStart").'</td><td>'; print '<tr><td>'.$langs->trans("DateStart").'</td><td>';
print Form::select_date(($date_start?$date_start:''),'projectstart',0,0,0,'',1,0,1); print Form::selectDate(($date_start?$date_start:''),'projectstart',0,0,0,'',1,0,1);
print '</td></tr>'; print '</td></tr>';
// Date end // Date end
print '<tr><td>'.$langs->trans("DateEnd").'</td><td>'; print '<tr><td>'.$langs->trans("DateEnd").'</td><td>';
print Form::select_date(($date_end?$date_end:-1),'projectend',0,0,0,'',1,0,1); print Form::selectDate(($date_end?$date_end:-1),'projectend',0,0,0,'',1,0,1);
print '</td></tr>'; print '</td></tr>';
if (! empty($conf->global->PROJECT_USE_OPPORTUNITIES)) if (! empty($conf->global->PROJECT_USE_OPPORTUNITIES))
@ -676,7 +676,7 @@ else
// Date start // Date start
print '<tr><td>'.$langs->trans("DateStart").'</td><td>'; print '<tr><td>'.$langs->trans("DateStart").'</td><td>';
print Form::select_date($object->date_start?$object->date_start:-1,'projectstart',0,0,0,'',1,0,1); print Form::selectDate($object->date_start?$object->date_start:-1,'projectstart',0,0,0,'',1,0,1);
print ' &nbsp; &nbsp; <input type="checkbox" name="reportdate" value="yes" '; print ' &nbsp; &nbsp; <input type="checkbox" name="reportdate" value="yes" ';
if ($comefromclone){print ' checked ';} if ($comefromclone){print ' checked ';}
print '/> '. $langs->trans("ProjectReportDate"); print '/> '. $langs->trans("ProjectReportDate");
@ -684,7 +684,7 @@ else
// Date end // Date end
print '<tr><td>'.$langs->trans("DateEnd").'</td><td>'; print '<tr><td>'.$langs->trans("DateEnd").'</td><td>';
print Form::select_date($object->date_end?$object->date_end:-1,'projectend',0,0,0,'',1,0,1); print Form::selectDate($object->date_end?$object->date_end:-1,'projectend',0,0,0,'',1,0,1);
print '</td></tr>'; print '</td></tr>';
if (! empty($conf->global->PROJECT_USE_OPPORTUNITIES)) if (! empty($conf->global->PROJECT_USE_OPPORTUNITIES))

View File

@ -324,10 +324,10 @@ if (! $showdatefilter)
print '<input type="hidden" name="action" value="view">'; print '<input type="hidden" name="action" value="view">';
print '<table><tr>'; print '<table><tr>';
print '<td>'.$langs->trans("From").' '; print '<td>'.$langs->trans("From").' ';
print Form::select_date($dates,'dates',0,0,1,'',1,0,1); print Form::selectDate($dates,'dates',0,0,1,'',1,0,1);
print '</td>'; print '</td>';
print '<td>'.$langs->trans("to").' '; print '<td>'.$langs->trans("to").' ';
print Form::select_date($datee,'datee',0,0,1,'',1,0,1); print Form::selectDate($datee,'datee',0,0,1,'',1,0,1);
print '</td>'; print '</td>';
print '<td>'; print '<td>';
print '<input type="submit" name="refresh" value="'.$langs->trans("Refresh").'" class="button">'; print '<input type="submit" name="refresh" value="'.$langs->trans("Refresh").'" class="button">';

View File

@ -317,12 +317,12 @@ if ($action == 'create' && $user->rights->projet->creer && (empty($object->third
// Date start // Date start
print '<tr><td>'.$langs->trans("DateStart").'</td><td>'; print '<tr><td>'.$langs->trans("DateStart").'</td><td>';
print Form::select_date(($date_start?$date_start:''),'dateo',1,1,0,'',1,1,1); print Form::selectDate(($date_start?$date_start:''),'dateo',1,1,0,'',1,1,1);
print '</td></tr>'; print '</td></tr>';
// Date end // Date end
print '<tr><td>'.$langs->trans("DateEnd").'</td><td>'; print '<tr><td>'.$langs->trans("DateEnd").'</td><td>';
print Form::select_date(($date_end?$date_end:-1),'datee',1,1,0,'',1,1,1); print Form::selectDate(($date_end?$date_end:-1),'datee',1,1,0,'',1,1,1);
print '</td></tr>'; print '</td></tr>';
// planned workload // planned workload

View File

@ -338,12 +338,12 @@ if ($id > 0 || ! empty($ref))
// Date start // Date start
print '<tr><td>'.$langs->trans("DateStart").'</td><td>'; print '<tr><td>'.$langs->trans("DateStart").'</td><td>';
print Form::select_date($object->date_start,'dateo',1,1,0,'',1,0,1); print Form::selectDate($object->date_start,'dateo',1,1,0,'',1,0,1);
print '</td></tr>'; print '</td></tr>';
// Date end // Date end
print '<tr><td>'.$langs->trans("DateEnd").'</td><td>'; print '<tr><td>'.$langs->trans("DateEnd").'</td><td>';
print Form::select_date($object->date_end?$object->date_end:-1,'datee',1,1,0,'',1,0,1); print Form::selectDate($object->date_end?$object->date_end:-1,'datee',1,1,0,'',1,0,1);
print '</td></tr>'; print '</td></tr>';
// Planned workload // Planned workload

View File

@ -431,7 +431,7 @@ if (($id > 0 || ! empty($ref)) || $projectidforalltimes > 0)
print '<td class="nowrap">'; print '<td class="nowrap">';
//$newdate=dol_mktime(12,0,0,$_POST["timemonth"],$_POST["timeday"],$_POST["timeyear"]); //$newdate=dol_mktime(12,0,0,$_POST["timemonth"],$_POST["timeday"],$_POST["timeyear"]);
$newdate=''; $newdate='';
print Form::select_date($newdate,'time',1,1,2,"timespent_date",1,0,1); print Form::selectDate($newdate,'time',1,1,2,"timespent_date",1,0,1);
print '</td>'; print '</td>';
// Contributor // Contributor
@ -551,7 +551,7 @@ if (($id > 0 || ! empty($ref)) || $projectidforalltimes > 0)
print '<td class="nowrap">'; print '<td class="nowrap">';
if ($_GET['action'] == 'editline' && $_GET['lineid'] == $task_time->rowid) if ($_GET['action'] == 'editline' && $_GET['lineid'] == $task_time->rowid)
{ {
print Form::select_date(($date2?$date2:$date1),'timeline',1,1,2,"timespent_date",1,0,1); print Form::selectDate(($date2?$date2:$date1),'timeline',1,1,2,"timespent_date",1,0,1);
} }
else else
{ {

View File

@ -504,7 +504,7 @@ if (empty($conf->global->ADHERENT_LOGIN_NOT_REQUIRED))
} }
// Birthday // Birthday
print '<tr id="trbirth" class="trbirth"><td>'.$langs->trans("DateToBirth").'</td><td>'; print '<tr id="trbirth" class="trbirth"><td>'.$langs->trans("DateToBirth").'</td><td>';
print Form::select_date($birthday,'birth',0,0,1,"newmember",1,0,1); print Form::selectDate($birthday,'birth',0,0,1,"newmember",1,0,1);
print '</td></tr>'."\n"; print '</td></tr>'."\n";
// Photo // Photo
print '<tr><td>'.$langs->trans("URLPhoto").'</td><td><input type="text" name="photo" size="40" value="'.dol_escape_htmltag(GETPOST('photo')).'"></td></tr>'."\n"; print '<tr><td>'.$langs->trans("URLPhoto").'</td><td><input type="text" name="photo" size="40" value="'.dol_escape_htmltag(GETPOST('photo')).'"></td></tr>'."\n";

Some files were not shown because too many files have changed in this diff Show More