diff --git a/htdocs/contrat/card.php b/htdocs/contrat/card.php index 5aba990c14f..bd360a7e481 100644 --- a/htdocs/contrat/card.php +++ b/htdocs/contrat/card.php @@ -1202,12 +1202,8 @@ if ($action == 'create') { } print "\n"; -} else /* *************************************************************************** */ -/* */ -/* Mode vue et edition */ -/* */ -/* *************************************************************************** */ -{ +} else { + // View and edit mode $now = dol_now(); if ($object->id > 0) { diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index 48774c0fe66..fc83af67851 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -4727,7 +4727,7 @@ class Form foreach ($formquestion as $key => $input) { if (is_array($input) && !empty($input)) { if ($input['type'] == 'hidden') { - $more .= ''."\n"; + $more .= ''."\n"; } } } @@ -4742,9 +4742,21 @@ class Form $morecss = (!empty($input['morecss']) ? ' '.$input['morecss'] : ''); if ($input['type'] == 'text') { - $more .= '
'.$input['label'].'
'."\n"; + $more .= '
'.$input['label'].'
'."\n"; } elseif ($input['type'] == 'password') { - $more .= '
'.$input['label'].'
'."\n"; + $more .= '
'.$input['label'].'
'."\n"; + } elseif ($input['type'] == 'textarea') { + /*$more .= '
'.$input['label'].'
'; + $more .= ''; + $more .= '
'."\n";*/ + $moreonecolumn .= '
'; + $moreonecolumn .= $input['label'].'
'; + $moreonecolumn .= ''; + $moreonecolumn .= '
'; } elseif ($input['type'] == 'select') { if (empty($morecss)) { $morecss = 'minwidth100'; @@ -4767,7 +4779,7 @@ class Form } elseif ($input['type'] == 'checkbox') { $more .= '
'; $more .= '
'.$input['label'].'
'; - $more .= ' 
'; } - $more .= '
'.$selval.''; + $more .= ''; $more .= '
'."\n"; $i++; } @@ -4921,7 +4933,7 @@ class Form inputvalue = $("#" + inputname + more).val(); } if (typeof inputvalue == "undefined") { inputvalue=""; } - console.log("check inputname="+inputname+" inputvalue="+inputvalue); + console.log("formconfirm check inputname="+inputname+" inputvalue="+inputvalue); options += "&" + inputname + "=" + encodeURIComponent(inputvalue); }); } diff --git a/htdocs/core/tpl/admin_extrafields_view.tpl.php b/htdocs/core/tpl/admin_extrafields_view.tpl.php index 284407383d4..2f1c113fcf5 100644 --- a/htdocs/core/tpl/admin_extrafields_view.tpl.php +++ b/htdocs/core/tpl/admin_extrafields_view.tpl.php @@ -84,18 +84,31 @@ if (isset($extrafields->attributes[$elementtype]['type']) && is_array($extrafiel } print ''; - print "".$extrafields->attributes[$elementtype]['pos'][$key]."\n"; - print "".$extrafields->attributes[$elementtype]['label'][$key]."\n"; // We don't translate here, we want admin to know what is the key not translated value - print "".$langs->trans($extrafields->attributes[$elementtype]['label'][$key])."\n"; - print "".$key."\n"; - print "".$type2label[$extrafields->attributes[$elementtype]['type'][$key]]."\n"; - print ''.$extrafields->attributes[$elementtype]['size'][$key]."\n"; - print ''.dol_trunc($extrafields->attributes[$elementtype]['computed'][$key], 20)."\n"; + // Position + print "".dol_escape_htmltag($extrafields->attributes[$elementtype]['pos'][$key])."\n"; + // Label + print "".dol_escape_htmltag($extrafields->attributes[$elementtype]['label'][$key])."\n"; // We don't translate here, we want admin to know what is the key not translated value + // Label translated + print ''.dol_escape_htmltag($langs->transnoentitiesnoconv($extrafields->attributes[$elementtype]['label'][$key]))."\n"; + // Key + print "".dol_escape_htmltag($key)."\n"; + // Type + print "".dol_escape_htmltag($type2label[$extrafields->attributes[$elementtype]['type'][$key]])."\n"; + // Size + print ''.dol_escape_htmltag($extrafields->attributes[$elementtype]['size'][$key])."\n"; + // Computed field + print ''.dol_escape_htmltag($extrafields->attributes[$elementtype]['computed'][$key])."\n"; + // Is unique ? print ''.yn($extrafields->attributes[$elementtype]['unique'][$key])."\n"; + // Is mandatory ? print ''.yn($extrafields->attributes[$elementtype]['required'][$key])."\n"; + // Can always be editable ? print ''.yn($extrafields->attributes[$elementtype]['alwayseditable'][$key])."\n"; - print ''.$extrafields->attributes[$elementtype]['list'][$key]."\n"; - print ''.$extrafields->attributes[$elementtype]['printable'][$key]."\n"; + // Visible + print ''.dol_escape_htmltag($extrafields->attributes[$elementtype]['list'][$key])."\n"; + // Print on PDF + print ''.dol_escape_htmltag($extrafields->attributes[$elementtype]['printable'][$key])."\n"; + // Summable print ''.yn($extrafields->attributes[$elementtype]['totalizable'][$key])."\n"; if (!empty($conf->multicompany->enabled)) { print ''; @@ -116,8 +129,8 @@ if (isset($extrafields->attributes[$elementtype]['type']) && is_array($extrafiel print ''; } print ''; - print ''.img_edit().''; - print '  '.img_delete().''; + print ''.img_edit().''; + print '  '.img_delete().''; print ''."\n"; print ""; } diff --git a/htdocs/langs/en_US/admin.lang b/htdocs/langs/en_US/admin.lang index 76dd117dbd8..eb1ce338864 100644 --- a/htdocs/langs/en_US/admin.lang +++ b/htdocs/langs/en_US/admin.lang @@ -2163,4 +2163,5 @@ APIsAreNotEnabled=APIs modules are not enabled YouShouldSetThisToOff=You should set this to 0 or off InstallAndUpgradeLockedBy=Install and upgrades are locked by the file %s OldImplementation=Old implementation -PDF_SHOW_LINK_TO_ONLINE_PAYMENT=If some online payment modules are enabled (Paypal, Stripe, ...), add a link on the PDF to make the online payment \ No newline at end of file +PDF_SHOW_LINK_TO_ONLINE_PAYMENT=If some online payment modules are enabled (Paypal, Stripe, ...), add a link on the PDF to make the online payment +EnabledCondition=Condition to have field enabled (if not enabled, visibility will always be off) \ No newline at end of file diff --git a/htdocs/langs/en_US/contracts.lang b/htdocs/langs/en_US/contracts.lang index 49a65fdb39d..937c5a7397b 100644 --- a/htdocs/langs/en_US/contracts.lang +++ b/htdocs/langs/en_US/contracts.lang @@ -36,7 +36,7 @@ CloseAContract=Close a contract ConfirmDeleteAContract=Are you sure you want to delete this contract and all its services? ConfirmValidateContract=Are you sure you want to validate this contract under name %s? ConfirmActivateAllOnContract=This will open all services (not yet active). Are you sure you want to open all services? -ConfirmCloseContract=This will close all services (active or not). Are you sure you want to close this contract? +ConfirmCloseContract=This will close all services (expired or not). Are you sure you want to close this contract? ConfirmCloseService=Are you sure you want to close this service with date %s? ValidateAContract=Validate a contract ActivateService=Activate service diff --git a/htdocs/salaries/paiement_salary.php b/htdocs/salaries/paiement_salary.php index 895226d0207..9f9a1ae7b50 100644 --- a/htdocs/salaries/paiement_salary.php +++ b/htdocs/salaries/paiement_salary.php @@ -313,10 +313,13 @@ if ($action == 'create') { } print ""; + + print '
'; + // Bouton Save payment print '
'; - print ' '.$langs->trans("ClosePaidSalaryAutomatically"); - print $form->buttonsSaveCancel("Save", "Cancel", '', true); + print '
'; + print $form->buttonsSaveCancel("ToMakePayment", "Cancel", '', true); print '
';