Skip to content

Commit 7f48f4d

Browse files
committed
Merge branch '2024_rc' into 2024
2 parents b2d04a8 + 4795328 commit 7f48f4d

14 files changed

+167
-43
lines changed

.easya_info.json

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
2-
"dol_min": 18,
3-
"dol_max": 19,
4-
"php_min": 7
2+
"dlb_min_version": 18,
3+
"dlb_max_version": 18,
4+
"php_min_version": 7.0,
5+
"php_max_version": 8.2
56
}

CHANGELOG.md

+10
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,15 @@
11
## Changelog ##
22

3+
### Version 3.0.5 - Compatibility 14.0.x - 20.0.x (2024/09/01)
4+
- Fix Z-index with option FIX_AREAREF_TABACTION activated
5+
- Add Use specific landing page to home menu entry (Thanks Christophe from Altairis)
6+
- Fix display of new dropdown action button
7+
8+
### Version 3.0.4 - Compatibility 14.0.x - 20.0.x (2024/07/03)
9+
- Add CSS for drag & drop card feature
10+
- Fix menu orders (customer and supplier), problem on search_billed
11+
- If Easya version detected, force json information for dlb_min_version & php_min_version
12+
313
### Version 3.0.3 - Compatibility 14.0.x - 20-alpha (2024/05/24)
414
- Fix Contract expired services menu link (From Dolibarr 18.0.x)
515
- FIX can not show group when MULTICOMPANY_TRANSVERSE_MODE

VERSION

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.0.3
1+
3.0.5

admin/colors.php

+15-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/************************************************
3-
* Copyright (C) 2015-2022 Alexandre Spangaro <alexandre@inovea-conseil.com>
4-
* Copyright (C) 2023 Sylvain Legrand <contact@infras.fr>
3+
* Copyright (C) 2015-2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
4+
* Copyright (C) 2023-2024 Sylvain Legrand <contact@infras.fr>
55
*
66
* This program is free software: you can redistribute it and/or modify
77
* it under the terms of the GNU General Public License as published by
@@ -86,7 +86,9 @@
8686
'OBLYON_COLOR_FLINE_HOVER',
8787
'OBLYON_COLOR_FDATE_DEFAULT',
8888
'OBLYON_COLOR_TEXTTABACTIVE',
89-
'OBLYON_COLOR_INPUT_BCKGRD'
89+
'OBLYON_COLOR_INPUT_BCKGRD',
90+
'OBLYON_COLOR_INFOBOX_BCKGRD1',
91+
'OBLYON_COLOR_INFOBOX_BCKGRD2'
9092
),
9193
'eldy' => array('THEME_ELDY_TOPBORDER_TITLE1',
9294
'THEME_ELDY_BACKTITLE1',
@@ -145,6 +147,8 @@
145147
'OBLYON_COLOR_FDATE_DEFAULT' => '#FF0000',
146148
'OBLYON_COLOR_TEXTTABACTIVE' => '#222222',
147149
'OBLYON_COLOR_INPUT_BCKGRD' => '#FFFFFF',
150+
'OBLYON_COLOR_INFOBOX_BCKGRD1' => '#444444',
151+
'OBLYON_COLOR_INFOBOX_BCKGRD2' => '#E4EFE8',
148152
'THEME_INVERT_RATIO_FILTER' => '0',
149153
'THEME_ELDY_TOPBORDER_TITLE1' => '#FFFFFF',
150154
'THEME_ELDY_BACKTITLE1' => '#E9EAED',
@@ -202,6 +206,8 @@
202206
'OBLYON_COLOR_FDATE_DEFAULT' => '#FF0000',
203207
'OBLYON_COLOR_TEXTTABACTIVE' => '#222222',
204208
'OBLYON_COLOR_INPUT_BCKGRD' => '#FFFFFF',
209+
'OBLYON_COLOR_INFOBOX_BCKGRD1' => '#444444',
210+
'OBLYON_COLOR_INFOBOX_BCKGRD2' => '#E4EFE8',
205211
'THEME_INVERT_RATIO_FILTER' => '80',
206212
'THEME_ELDY_TOPBORDER_TITLE1' => '#FFFFFF',
207213
'THEME_ELDY_BACKTITLE1' => '#E9EAED',
@@ -259,6 +265,8 @@
259265
'OBLYON_COLOR_FDATE_DEFAULT' => '#FF0000',
260266
'OBLYON_COLOR_TEXTTABACTIVE' => '#222222',
261267
'OBLYON_COLOR_INPUT_BCKGRD' => '#FFFFFF',
268+
'OBLYON_COLOR_INFOBOX_BCKGRD1' => '#444444',
269+
'OBLYON_COLOR_INFOBOX_BCKGRD2' => '#E4EFE8',
262270
'THEME_INVERT_RATIO_FILTER' => '0',
263271
'THEME_ELDY_TOPBORDER_TITLE1' => '#FFFFFF',
264272
'THEME_ELDY_BACKTITLE1' => '#E9EAED',
@@ -316,6 +324,8 @@
316324
'OBLYON_COLOR_FDATE_DEFAULT' => '#FF0000',
317325
'OBLYON_COLOR_TEXTTABACTIVE' => '#222222',
318326
'OBLYON_COLOR_INPUT_BCKGRD' => '#DEDEDE',
327+
'OBLYON_COLOR_INFOBOX_BCKGRD1' => '#444444',
328+
'OBLYON_COLOR_INFOBOX_BCKGRD2' => '#E4EFE8',
319329
'THEME_INVERT_RATIO_FILTER' => '0',
320330
'THEME_ELDY_TOPBORDER_TITLE1' => '#FFFFFF',
321331
'THEME_ELDY_BACKTITLE1' => '#E9EAED',
@@ -373,6 +383,8 @@
373383
'OBLYON_COLOR_FDATE_DEFAULT' => '#FF0000',
374384
'OBLYON_COLOR_TEXTTABACTIVE' => '#222222',
375385
'OBLYON_COLOR_INPUT_BCKGRD' => '#F4F4F4',
386+
'OBLYON_COLOR_INFOBOX_BCKGRD1' => '#444444',
387+
'OBLYON_COLOR_INFOBOX_BCKGRD2' => '#E4EFE8',
376388
'THEME_INVERT_RATIO_FILTER' => '0',
377389
'THEME_ELDY_TOPBORDER_TITLE1' => '#FFFFFF',
378390
'THEME_ELDY_BACKTITLE1' => '#E9EAED',

core/menus/standard/oblyon.lib.php

+22-7
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,13 @@ function print_oblyon_menu($db, $atarget, $type_user = 0, &$tabMenu, &$menu, $no
5050
$mainmenu = (empty($_SESSION["mainmenu"]) ? '' : $_SESSION["mainmenu"]);
5151
$leftmenu = (empty($_SESSION["leftmenu"]) ? '' : $_SESSION["leftmenu"]);
5252

53+
$landingpage = (!getDolUserString('MAIN_LANDING_PAGE') ? (!getDolGlobalString('MAIN_LANDING_PAGE') ? '' : getDolGlobalString('MAIN_LANDING_PAGE')) : getDolUserString('MAIN_LANDING_PAGE'));
54+
if (! empty($landingpage)) {
55+
$landingpage = dol_buildpath($landingpage, 1);
56+
} else {
57+
$landingpage = DOL_URL_ROOT . '/index.php?mainmenu=home&amp;leftmenu=home';
58+
}
59+
5360
$id = 'mainmenu';
5461
$listofmodulesforexternal = explode(',', $conf->global->MAIN_MODULES_FOR_EXTERNAL);
5562

@@ -84,7 +91,7 @@ function print_oblyon_menu($db, $atarget, $type_user = 0, &$tabMenu, &$menu, $no
8491

8592

8693
print '<div class="center backgroundforcompanylogo menulogocontainer">';
87-
print '<a href="'.DOL_URL_ROOT.'" alt="'.dol_escape_htmltag($title).'" title="'.dol_escape_htmltag($title).'">';
94+
print '<a href="' . DOL_URL_ROOT . $landingpage . '" alt="'.dol_escape_htmltag($title).'" title="'.dol_escape_htmltag($title).'">';
8895
print '<img class="mycompany" title="'.dol_escape_htmltag($title).'" alt="" src="'.$urllogo.'" style="max-width: 100px; height: 32px;">';
8996
print '</a>'."\n";
9097
print '</div>'."\n";
@@ -146,9 +153,9 @@ function print_oblyon_menu($db, $atarget, $type_user = 0, &$tabMenu, &$menu, $no
146153
$chaine=$langs->trans("Home");
147154

148155
if (empty($noout)) print_start_menu_entry($idsel,$itemsel,$showmode);
149-
if (empty($noout)) print_text_menu_entry($chaine, 1, DOL_URL_ROOT.'/index.php?mainmenu=home&amp;leftmenu=', $id, $idsel, $atarget);
156+
if (empty($noout)) print_text_menu_entry($chaine, 1, $landingpage, $id, $idsel, $atarget);
150157
if (empty($noout)) print_end_menu_entry($showmode);
151-
$menu->add('/index.php?mainmenu=home&amp;leftmenu=', $chaine, 0, $showmode, $atarget, "home", '');
158+
$menu->add($landingpage, $chaine, 0, $showmode, $atarget, "home", '');
152159

153160
// Members
154161
$tmpentry = array(
@@ -714,6 +721,14 @@ function print_left_oblyon_menu($db, $menu_array_before, $menu_array_after, &$ta
714721
print '<div class="pushy-btn" title="'.$langs->trans("ShowLeftMenu").'">&#8801;</div>';
715722
}
716723

724+
// get landing page
725+
$landingpage = (empty($user->conf->MAIN_LANDING_PAGE) ? (!getDolGlobalString('MAIN_LANDING_PAGE') ? '' : $conf->global->MAIN_LANDING_PAGE) : $user->conf->MAIN_LANDING_PAGE);
726+
if (! empty($landingpage)) {
727+
$landingpage = str_replace(DOL_URL_ROOT, '', dol_buildpath($landingpage, 1));
728+
} else {
729+
$landingpage = '/index.php?mainmenu=home&amp;leftmenu=home';
730+
}
731+
717732
// Show logo company
718733
if (! empty($menu_invert) && empty($noout) && ! empty($conf->global->MAIN_SHOW_LOGO)) {
719734
//$mysoc->logo_mini=(empty($conf->global->MAIN_INFO_SOCIETE_LOGO_MINI)?'':$conf->global->MAIN_INFO_SOCIETE_LOGO_MINI);
@@ -737,7 +752,7 @@ function print_left_oblyon_menu($db, $menu_array_before, $menu_array_after, &$ta
737752
print "\n".'<!-- Show logo on menu -->'."\n";
738753

739754
print '<div class="menu_contenu db-menu__society center backgroundforcompanylogo menulogocontainer">';
740-
print '<a href="'.DOL_URL_ROOT.'" alt="'.dol_escape_htmltag($title).'" title="'.dol_escape_htmltag($title).'">';
755+
print '<a href="' . DOL_URL_ROOT . $landingpage . '" alt="'.dol_escape_htmltag($title).'" title="'.dol_escape_htmltag($title).'">';
741756
print '<img class="mycompany" title="'.dol_escape_htmltag($title).'" alt="" src="'.$urllogo.'" style="max-width: 100px; height: 32px;">';
742757
print '</a>'."\n";
743758
print '</div>'."\n";
@@ -785,7 +800,7 @@ function print_left_oblyon_menu($db, $menu_array_before, $menu_array_after, &$ta
785800
$langs->load("users");
786801

787802
// Home - dashboard
788-
$newmenu->add("/index.php?mainmenu=home&amp;leftmenu=home", $langs->trans("MyDashboard"), 0, 1, '', $mainmenu, 'home');
803+
$newmenu->add($landingpage, $langs->trans("MyDashboard"), 0, 1, '', $mainmenu, 'home');
789804

790805
// Setup
791806
$newmenu->add("/admin/index.php?mainmenu=home&amp;leftmenu=setup", $langs->trans("Setup"), 0, $user->admin, '', $mainmenu, 'setup');
@@ -1184,7 +1199,7 @@ function print_left_oblyon_menu($db, $menu_array_before, $menu_array_after, &$ta
11841199
if (!empty($conf->commande->enabled)) {
11851200
$langs->load("orders");
11861201
if (!empty($conf->facture->enabled)) {
1187-
$newmenu->add("/commande/list.php?leftmenu=orders&amp;search_status=-3&amp;billed=0&amp;contextpage=billableorders", $langs->trans("MenuOrdersToBill2"), 0, $user->rights->commande->lire, '', $mainmenu, 'orders', 0);
1202+
$newmenu->add("/commande/list.php?leftmenu=orders&amp;search_status=-3&amp;search_billed=0&amp;contextpage=billableorders", $langs->trans("MenuOrdersToBill2"), 0, $user->rights->commande->lire, '', $mainmenu, 'orders', 0);
11881203
}
11891204
//if ($usemenuhider || empty($leftmenu) || $leftmenu=="orders") $newmenu->add("/commande/", $langs->trans("StatusOrderToBill"), 1, $user->rights->commande->lire);
11901205
}
@@ -1193,7 +1208,7 @@ function print_left_oblyon_menu($db, $menu_array_before, $menu_array_after, &$ta
11931208
if (!empty($conf->supplier_invoice->enabled)) {
11941209
if (!empty($conf->global->SUPPLIER_MENU_ORDER_RECEIVED_INTO_INVOICE)) {
11951210
$langs->load("supplier");
1196-
$newmenu->add("/fourn/commande/list.php?leftmenu=orders&amp;search_status=5&amp;billed=0", $langs->trans("MenuOrdersSupplierToBill"), 0, $user->rights->commande->lire, '', $mainmenu, 'orders', 0);
1211+
$newmenu->add("/fourn/commande/list.php?leftmenu=orders&amp;search_status=5&amp;search_billed=0", $langs->trans("MenuOrdersSupplierToBill"), 0, $user->rights->commande->lire, '', $mainmenu, 'orders', 0);
11971212
//if ($usemenuhider || empty($leftmenu) || $leftmenu=="orders") $newmenu->add("/commande/", $langs->trans("StatusOrderToBill"), 1, $user->rights->commande->lire);
11981213
}
11991214
}

core/modules/modOblyon.class.php

+11-2
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,9 @@ function __construct($db)
4242
global $langs, $conf;
4343

4444
$langs->loadLangs(array('oblyon@oblyon', 'inovea@oblyon'));
45+
46+
$easyaVersion = (float) !empty($conf->global->EASYA_VERSION) ? $conf->global->EASYA_VERSION : '';
47+
4548
$this->db = $db;
4649
$this->numero = 432573; // Unique Id for module
4750
$this->name = preg_replace('/^mod/i', '', get_class($this)); // Module label (no space allowed)
@@ -72,12 +75,18 @@ function __construct($db)
7275
$this->depends = array(); // List of modules id that must be enabled if this module is enabled
7376
$this->requiredby = array(); // List of modules id to disable if this one is disabled
7477
$this->conflictwith = array(); // List of modules id this module is in conflict with
75-
$this->phpmin = array(7, 4); // Minimum version of PHP required by module
78+
$this->phpmin = array(7, 1); // Minimum version of PHP required by module
7679
$this->need_dolibarr_version = array(14,0); // Minimum version of Dolibarr required by module
80+
if ($easyaVersion >= '2024') {
81+
$easya_info = json_decode(file_get_contents(__DIR__ . '/../../.easya_info.json'));
82+
$this->phpmin = explode('.', $easya_info->php_min_version); // Minimum version of PHP required by module
83+
$this->need_dolibarr_version = explode('.', $easya_info->dlb_min_version); // Minimum version of Dolibarr required by module
84+
}
7785
$this->langfiles = array($this->name.'@'.$this->name);
7886
$this->const = array(); // List of particular constants to add when module is enabled
87+
7988
// WIP - Remove classic Dolibarr tabs to avoid a theme change problem (Only available > 15.0.x)
80-
$easyaVersion = (float) !empty($conf->global->EASYA_VERSION) ? $conf->global->EASYA_VERSION : '';
89+
8190
if ($easyaVersion >= '2022.5.2' || (float) DOL_VERSION >= 16.0) {
8291
$this->tabs = array(
8392
//'ihm_admin:-template',

langs/en_US/oblyon.lang

+2
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,8 @@ OBLYON_COLOR_NOTIF_ERROR_BCKGRD = Color background on notification error mess
121121
OBLYON_COLOR_NOTIF_ERROR_TEXT = Color text on notification error message
122122
OBLYON_COLOR_TEXTTABACTIVE = Color text of active tabs
123123
OBLYON_COLOR_INPUT_BCKGRD = Background color of inputs
124+
OBLYON_COLOR_INFOBOX_BCKGRD1 = Background color 1 of active kanban cards (applications / modules)
125+
OBLYON_COLOR_INFOBOX_BCKGRD2 = Background color 2 of active kanban cards (applications / modules)
124126
InvertRatioDesc = Color Inversion Filter Ratio (Applicable to icons based on PNG image files)
125127
Eldys = Basic colors
126128
THEME_ELDY_TOPBORDER_TITLE1 = Title border color

langs/fr_FR/oblyon.lang

+2
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,8 @@ OBLYON_COLOR_NOTIF_ERROR_BCKGRD = Couleur de fond des notifications d'erreur
129129
OBLYON_COLOR_NOTIF_ERROR_TEXT = Couleur de texte des notifications d'erreur
130130
OBLYON_COLOR_TEXTTABACTIVE = Couleur de texte des onglets actifs
131131
OBLYON_COLOR_INPUT_BCKGRD = Couleur de fond des zones de saisie
132+
OBLYON_COLOR_INFOBOX_BCKGRD1 = Couleur de fond 1 des cartes kanban active (applications / modules)
133+
OBLYON_COLOR_INFOBOX_BCKGRD2 = Couleur de fond 2 des cartes kanban active (applications / modules)
132134
InvertRatioDesc = Ratio du filtre d'inversion des couleurs (Applicable aux icones basées sur des fichiers images PNG)
133135
Eldys = Couleurs de base
134136
THEME_ELDY_TOPBORDER_TITLE1 = Couleur des bordures de titre

sql/data.sql

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
-- /************************************************
2-
-- * Copyright (C) 2015-2022 Alexandre Spangaro <alexandre@inovea-conseil.com>
3-
-- * Copyright (C) 2022 Sylvain Legrand <contact@infras.fr>
2+
-- * Copyright (C) 2015-2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
3+
-- * Copyright (C) 2022-2024 Sylvain Legrand <contact@infras.fr>
44
-- *
55
-- * This program is free software: you can redistribute it and/or modify
66
-- * it under the terms of the GNU General Public License as published by
@@ -96,6 +96,8 @@ INSERT INTO llx_const (name, entity, value, type, visible, note) VALUES ('OBLYON
9696
INSERT INTO llx_const (name, entity, value, type, visible, note) VALUES ('OBLYON_COLOR_FDATE_DEFAULT', '__ENTITY__', '#FF0000', 'chaine', '0', 'Oblyon text default date (today) color');
9797
INSERT INTO llx_const (name, entity, value, type, visible, note) VALUES ('OBLYON_COLOR_TEXTTABACTIVE', '__ENTITY__', '#222222', 'chaine', '0', 'Oblyon text tab active');
9898
INSERT INTO llx_const (name, entity, value, type, visible, note) VALUES ('OBLYON_COLOR_INPUT_BCKGRD', '__ENTITY__', '#FFFFFF', 'chaine', '0', 'Oblyon background imput color');
99+
INSERT INTO llx_const (name, entity, value, type, visible, note) VALUES ('OBLYON_COLOR_INFOBOX_BCKGRD1', '__ENTITY__', '#444444', 'chaine', '0', 'Oblyon Background color 1 of active kanban cards');
100+
INSERT INTO llx_const (name, entity, value, type, visible, note) VALUES ('OBLYON_COLOR_INFOBOX_BCKGRD2', '__ENTITY__', '#E4EFE8', 'chaine', '0', 'Oblyon Background color 1 of active kanban cards');
99101
INSERT INTO llx_const (name, entity, value, type, visible, note) VALUES ('THEME_INVERT_RATIO_FILTER', '__ENTITY__', '0', 'chaine', '0', 'Oblyon Ratio for invert filter');
100102
-- Color - Default Eldy values
101103
INSERT INTO llx_const (name, entity, value, type, visible, note) VALUES ('THEME_ELDY_TOPBORDER_TITLE1', '__ENTITY__', '#D4D4D4', 'chaine', '0', 'Oblyon module');

0 commit comments

Comments
 (0)