Skip to content
This repository has been archived by the owner on Oct 4, 2024. It is now read-only.

Commit

Permalink
Merge pull request #44 from OPEN-DSI/2024_rc
Browse files Browse the repository at this point in the history
2024 rc
  • Loading branch information
kkhelifa-opendsi authored Aug 19, 2024
2 parents 170484f + 5431e9f commit a08cdee
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 16 deletions.
9 changes: 8 additions & 1 deletion ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@ Le format du fichier est basé sur [Tenez un ChangeLog](http://keepachangelog.co

## [Non Distribué]

## [14.0.6] - 13-08-2024
- Correction de la perenité du trie des listes lors des actions ajout/modification/suppressions ...
- Correction de l'uniformité d'affichage du bouton 'Ajouter'
- Correction des titres de liste sticky (Oblyon), affichage des liste sorti de l'onglet
- Correction de l'action en masse du changement de l'entité des lignes de dictionnaire selectionnées

## [14.0.5] - 20-06-2024
- L'entité 1 n'est plus l'entité globale
- Rajout de l'entité 0 comme entité globale (affichage dans les listes et action en masse)
Expand Down Expand Up @@ -258,7 +264,8 @@ Le format du fichier est basé sur [Tenez un ChangeLog](http://keepachangelog.co
## [4.0.0] - 16-07-2018
- Version initial.

[Non Distribué]: https://github.com/OPEN-DSI/dolibarr_module_advancedictionaries/compare/14.0.5...HEAD
[Non Distribué]: https://github.com/OPEN-DSI/dolibarr_module_advancedictionaries/compare/14.0.6...HEAD
[14.0.6]: https://github.com/OPEN-DSI/dolibarr_module_advancedictionaries/commits/14.0.6
[14.0.5]: https://github.com/OPEN-DSI/dolibarr_module_advancedictionaries/commits/14.0.5
[14.0.4]: https://github.com/OPEN-DSI/dolibarr_module_advancedictionaries/commits/14.0.4
[14.0.3]: https://github.com/OPEN-DSI/dolibarr_module_advancedictionaries/commits/14.0.3
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
14.0.5
14.0.6
2 changes: 0 additions & 2 deletions admin/dictionaries.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,6 @@

require dol_buildpath('/advancedictionaries/core/tpl/dictionaries.tpl.php');

print dol_get_fiche_end();

llxFooter();

$db->close();
8 changes: 6 additions & 2 deletions class/dictionary.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -4944,8 +4944,12 @@ public function showInputFieldAD($fieldName, $value=null, $keyprefix='', $keysuf
}
break;
case 'int':
$tmp = explode(',', $size);
$newsize = $tmp[0] + 1 + ($tmp[1] ?? 0);
if (empty($size)) {
$newsize = 10;
} else {
$tmp = explode(',', $size);
$newsize = $tmp[0] + 1 + ($tmp[1] ?? 0);
}
$out = '<input type="text" class="flat' . $moreClasses . ' maxwidthonsmartphone" id="' . $fieldHtmlName . '" name="' . $fieldHtmlName . '" maxlength="' . $newsize . '" value="' . $value . '"' . $moreAttributes . '>';
break;
case 'float':
Expand Down
12 changes: 6 additions & 6 deletions core/actions_dictionaries.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@

if ($dictionary->addLine($fieldsValue, $user) > 0) {
setEventMessage($langs->transnoentities("RecordSaved"));
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param2);
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param3);
exit;
} else {
setEventMessages($dictionary->error, $dictionary->errors, 'errors');
Expand All @@ -190,7 +190,7 @@

if ($dictionary->updateLine($rowid, $fieldsValue, $user) > 0) {
setEventMessage($langs->transnoentities("RecordSaved"));
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param2 . '#rowid-' . $rowid);
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param3 . '#rowid-' . $rowid);
exit;
} else {
setEventMessages($dictionary->error, $dictionary->errors, 'errors');
Expand All @@ -201,7 +201,7 @@
elseif ($action == 'confirm_delete_line' && $confirm == 'yes' && $dictionary->lineCanBeDeleted && $canDelete) {
if ($dictionary->deleteLine($rowid, $user) > 0) {
setEventMessage($langs->transnoentities("RecordDeleted"));
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param2 . '#rowid-' . $prevrowid);
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param3 . '#rowid-' . $prevrowid);
exit;
} else {
setEventMessages($dictionary->error, $dictionary->errors, 'errors');
Expand All @@ -212,7 +212,7 @@
$res = $dictionary->activeLine($rowid, 1, $user);
if ($res > 0) {
setEventMessage($langs->transnoentities("RecordSaved"));
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param2 . '#rowid-' . $rowid);
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param3 . '#rowid-' . $rowid);
exit;
} elseif ($res < 0) {
setEventMessages($dictionary->error, $dictionary->errors, 'errors');
Expand All @@ -223,7 +223,7 @@
$res = $dictionary->activeLine($rowid, 0, $user);
if ($res > 0) {
setEventMessage($langs->transnoentities("RecordSaved"));
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param2 . '#rowid-' . $rowid);
header('Location: ' . $_SERVER['PHP_SELF'] . '?' . $param3 . '#rowid-' . $rowid);
exit;
} elseif ($res < 0) {
setEventMessages($dictionary->error, $dictionary->errors, 'errors');
Expand All @@ -245,7 +245,7 @@

$db->begin();

$objecttmp = new $objectclass($db);
$objecttmp = $dictionary->getNewDictionaryLine();
$nbok = 0;
foreach ($toselect as $toselectid) {
$result = $objecttmp->fetch($toselectid);
Expand Down
8 changes: 4 additions & 4 deletions core/tpl/dictionaries.tpl.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,9 @@
print $langs->trans("DictionaryDesc");
print " ".$langs->trans("OnlyActiveElementsAreShown")."<br>\n";
}
if (!empty($head)) {
print dol_get_fiche_end();
}

//------------------------------------------------------------------------------------------------------------------
// Confirm box
Expand Down Expand Up @@ -193,10 +196,7 @@

$addButton = '';
if ($dictionary->lineCanBeAdded && $canCreate) {
$addButton = '<a href="' . $_SERVER['PHP_SELF'] . '?' . ltrim($param3, '&') . '&action=add_line&module=' . urlencode($dictionary->module) . '&name=' . urlencode($dictionary->name) . '&token='. newToken() .'&'.$now.'="' . ((float)DOL_VERSION >= 8.0 ? 'class=" butActionNew"' : '') . '>';
$addButton .= $langs->trans("Add");
if ((float)DOL_VERSION >= 8.0) $addButton .= '<span class="'.$class_fa.' fa-plus-circle valignmiddle"></span>';
$addButton .= '</a>';
$addButton .= dolGetButtonTitle($langs->trans('Add'), '', 'fa fa-plus-circle', $_SERVER['PHP_SELF'] . '?' . ltrim($param3, '&') . '&action=add_line&module=' . urlencode($dictionary->module) . '&name=' . urlencode($dictionary->name) . '&token='. newToken() .'&'.$now.'=', '', $dictionary->lineCanBeAdded && $canCreate);
}

$arrayofselected = is_array($toselect) ? $toselect : array();
Expand Down

0 comments on commit a08cdee

Please sign in to comment.