Fix: [ bug #1373 ] Required type of payment input is not visible
This commit is contained in:
parent
a5ccc538c8
commit
f36b9effe8
@ -79,6 +79,11 @@ if ($action == 'add' && $_POST["cancel"] <> $langs->trans("Cancel"))
|
|||||||
$sal->type_payment=GETPOST("paymenttype");
|
$sal->type_payment=GETPOST("paymenttype");
|
||||||
$sal->num_payment=GETPOST("num_payment");
|
$sal->num_payment=GETPOST("num_payment");
|
||||||
|
|
||||||
|
if (empty($datep) || empty($datesp) || empty($dateep))
|
||||||
|
{
|
||||||
|
setEventMessage($langs->trans("ErrorFieldRequired",$langs->transnoentitiesnoconv("Date")),'errors');
|
||||||
|
$error++;
|
||||||
|
}
|
||||||
if (empty($sal->fk_user) || $sal->fk_user < 0)
|
if (empty($sal->fk_user) || $sal->fk_user < 0)
|
||||||
{
|
{
|
||||||
setEventMessage($langs->trans("ErrorFieldRequired",$langs->transnoentitiesnoconv("Employee")),'errors');
|
setEventMessage($langs->trans("ErrorFieldRequired",$langs->transnoentitiesnoconv("Employee")),'errors');
|
||||||
@ -210,11 +215,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');
|
print $form->select_date((empty($datep)?-1:$datep),"datep",'','','','add');
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans("DateValue").'</td><td>';
|
print '<tr><td>'.$langs->trans("DateValue").'</td><td>';
|
||||||
print $form->select_date($datev,"datev",'','','','add');
|
print $form->select_date((empty($datev)?-1:$datev),"datev",'','','','add');
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Employee
|
// Employee
|
||||||
@ -244,6 +249,7 @@ if ($action == 'create')
|
|||||||
print '<tr><td class="fieldrequired">'.$langs->trans("Account").'</td><td>';
|
print '<tr><td class="fieldrequired">'.$langs->trans("Account").'</td><td>';
|
||||||
$form->select_comptes($_POST["accountid"],"accountid",0,"courant=1",1); // Affiche liste des comptes courant
|
$form->select_comptes($_POST["accountid"],"accountid",0,"courant=1",1); // Affiche liste des comptes courant
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
}
|
||||||
|
|
||||||
// Type payment
|
// Type payment
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans("PaymentMode").'</td><td>';
|
print '<tr><td class="fieldrequired">'.$langs->trans("PaymentMode").'</td><td>';
|
||||||
@ -251,6 +257,8 @@ if ($action == 'create')
|
|||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>";
|
print "</tr>";
|
||||||
|
|
||||||
|
if (! empty($conf->banque->enabled))
|
||||||
|
{
|
||||||
// Number
|
// Number
|
||||||
print '<tr><td>'.$langs->trans('Numero');
|
print '<tr><td>'.$langs->trans('Numero');
|
||||||
print ' <em>('.$langs->trans("ChequeOrTransferNumber").')</em>';
|
print ' <em>('.$langs->trans("ChequeOrTransferNumber").')</em>';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user