add trads on form fields

This commit is contained in:
jpb 2022-06-13 08:36:17 +02:00
parent 606b887fee
commit 0e72085be6
2 changed files with 9 additions and 4 deletions

View File

@ -209,8 +209,9 @@ if (empty($reshook)) {
}
// If no groups and no users
if (empty($groups) && empty($users)) {
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("User")), null, 'errors');
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Group")), null, 'errors');
setEventMessages($langs->trans("ErrorFieldRequiredUserOrGroup"), null, 'errors');
//setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("UserOrGroup")), null, 'errors');
//setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Group")), null, 'errors');
$error++;
$action = 'create';
}
@ -486,7 +487,8 @@ if ((empty($id) && empty($ref)) || $action == 'create' || $action == 'add') {
// groupe
print '<tr>';
print '<td class="titlefield fieldrequired">'.$langs->trans("groups");
print '<td class="titlefield fieldrequired">';
print $form->textwithpicto($langs->trans("groups"), $langs->trans("fusionGroupsUsers"));
print '</td>';
@ -505,7 +507,8 @@ if ((empty($id) && empty($ref)) || $action == 'create' || $action == 'add') {
// users
print '<tr>';
print '<td class="titlefield fieldrequired">'.$langs->trans("users").'</td>';
print '<td class="titlefield fieldrequired">';
print $form->textwithpicto($langs->trans("users"), $langs->trans("fusionGroupsUsers"));
print '<td>';
$sql = ' SELECT DISTINCT u.rowid,u.lastname,u.firstname from '.MAIN_DB_PREFIX.'user as u';

View File

@ -80,6 +80,8 @@ MotifCP=Reason
UserCP=User
ErrorAddEventToUserCP=An error occurred while adding the exceptional leave.
AddEventToUserOkCP=The addition of the exceptional leave has been completed.
ErrorFieldRequiredUserOrGroup=The "group" field or the "user" field must be filled in
fusionGroupsUsers=The groups field and the user field will be merged
MenuLogCP=View change logs
LogCP=Log of all updates made to "Balance of Leave"
ActionByCP=Updated by