From 2b559931b5983504ee7bfb9f5cceb675c5f2c2c1 Mon Sep 17 00:00:00 2001 From: "Julien C." Date: Fri, 25 Apr 2025 15:38:36 +0200 Subject: [PATCH 1/3] new8menustest --- core/api/mobile.api.php | 6 +++--- core/class/mobile.class.php | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/core/api/mobile.api.php b/core/api/mobile.api.php index 8ca714c9..b5d451c5 100755 --- a/core/api/mobile.api.php +++ b/core/api/mobile.api.php @@ -35,7 +35,7 @@ if (mobile::whoIsIq($params['Iq']) == 'mobile non detecte') { //createMobile($params, 3); log::add('mobile', 'debug', '| [WARNING] mobile non detecté !'); - createMobile($params, 3); + createMobile($params, 8); } else { log::add('mobile', 'debug', '| Mobile demandeur > ' . mobile::whoIsIq($params['Iq'])); } @@ -50,7 +50,7 @@ * @param array * @return new object */ -function createMobile($params, $nbIcones = 3) +function createMobile($params, $nbIcones = 8) { $configs = $params['configs']; $notification = $configs['notification']; @@ -137,7 +137,7 @@ function saveMenuFromAppV2($menu, $mobile) $mobile = eqLogic::byLogicalId($params['Iq'], 'mobile'); } if (!is_object($mobile)) { - $mobile = createMobile($params, 3); + $mobile = createMobile($params,8); } $mobile->setConfiguration('type_mobile', $notification['platform']); if (isset($notification['token'])) { diff --git a/core/class/mobile.class.php b/core/class/mobile.class.php index beb3f28d..5dadc234 100755 --- a/core/class/mobile.class.php +++ b/core/class/mobile.class.php @@ -423,11 +423,11 @@ public static function createCmdGeoLocV2($Iq, $geolocs) * Get menu default whitout "tab" * @return array */ - public static function getMenuDefaultV2($nbIcones = 3) + public static function getMenuDefaultV2($nbIcones = 8) { - $namesMenus = ['home', 'overview', 'health', 'home']; - $renamesIcons = ['Accueil', 'Synthese', 'Santé', 'Accueil']; - $spanIcons = ['icon jeedomapp-in', 'fab fa-hubspot', 'fas fa-medkit', 'icon jeedomapp-in']; + $namesMenus = ['home', 'overview', 'health', 'home', 'home', 'home', 'home', 'home']; + $renamesIcons = ['Accueil', 'Synthese', 'Santé', 'Accueil', 'Accueil', 'Accueil', 'Accueil', 'Accueil']; + $spanIcons = ['icon jeedomapp-in', 'fab fa-hubspot', 'fas fa-medkit', 'icon jeedomapp-in', 'icon jeedomapp-in', 'icon jeedomapp-in', 'icon jeedomapp-in', 'icon jeedomapp-in']; $urlUsers = ['none', 'none', 'none', 'none']; $j = 0; $menuCustomArray = []; @@ -546,7 +546,7 @@ public static function generateTypeObject($pluginPanelMobile, $menuCustomArray) $tabUrl = "/index.php?v={$webviewUrl}&p=dashboard&object_id={$objectId}"; break; case 'plan': - $tabUrl = "/index.php?v={$webviewUrl}&p=plan&plan_id={$objectId}"; + $tabUrl = "/index.php?v={$webviewUrl}&p=plan&fullscreen=1&plan_id={$objectId}"; break; case 'panel': $tabUrl = (isset($pluginPanelMobile[$objectId]) && $pluginPanelMobile[$objectId] == $objectId) ? "/index.php?v=m&p={$objectId}" : "/index.php?v=m&p={$objectId}&app_mode=1"; @@ -676,7 +676,7 @@ public function configMenuCustom() $arrayElements = array(); $j = 0; $count = 1; - for ($i = 1; $i < 5; $i++) { + for ($i = 1; $i < 9; $i++) { // GENERATE TAB ICON LIBRARY AND RENAME BY USER $resultTabIcon = self::generateTabIcon($menuCustomArray, $i); From cc31c0b1d42d1a3e49e2a19a9849a145cb610cbd Mon Sep 17 00:00:00 2001 From: "Julien C." Date: Fri, 25 Apr 2025 15:52:04 +0200 Subject: [PATCH 2/3] add for8icons --- core/api/mobile.api.php | 6 +++--- core/class/mobile.class.php | 10 +++++++--- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/core/api/mobile.api.php b/core/api/mobile.api.php index b5d451c5..0d8721c4 100755 --- a/core/api/mobile.api.php +++ b/core/api/mobile.api.php @@ -35,7 +35,7 @@ if (mobile::whoIsIq($params['Iq']) == 'mobile non detecte') { //createMobile($params, 3); log::add('mobile', 'debug', '| [WARNING] mobile non detecté !'); - createMobile($params, 8); + createMobile($params, 3); } else { log::add('mobile', 'debug', '| Mobile demandeur > ' . mobile::whoIsIq($params['Iq'])); } @@ -50,7 +50,7 @@ * @param array * @return new object */ -function createMobile($params, $nbIcones = 8) +function createMobile($params, $nbIcones = 3) { $configs = $params['configs']; $notification = $configs['notification']; @@ -137,7 +137,7 @@ function saveMenuFromAppV2($menu, $mobile) $mobile = eqLogic::byLogicalId($params['Iq'], 'mobile'); } if (!is_object($mobile)) { - $mobile = createMobile($params,8); + $mobile = createMobile($params,3); } $mobile->setConfiguration('type_mobile', $notification['platform']); if (isset($notification['token'])) { diff --git a/core/class/mobile.class.php b/core/class/mobile.class.php index 5dadc234..04a0bdda 100755 --- a/core/class/mobile.class.php +++ b/core/class/mobile.class.php @@ -423,12 +423,12 @@ public static function createCmdGeoLocV2($Iq, $geolocs) * Get menu default whitout "tab" * @return array */ - public static function getMenuDefaultV2($nbIcones = 8) + public static function getMenuDefaultV2($nbIcones = 3) { $namesMenus = ['home', 'overview', 'health', 'home', 'home', 'home', 'home', 'home']; $renamesIcons = ['Accueil', 'Synthese', 'Santé', 'Accueil', 'Accueil', 'Accueil', 'Accueil', 'Accueil']; $spanIcons = ['icon jeedomapp-in', 'fab fa-hubspot', 'fas fa-medkit', 'icon jeedomapp-in', 'icon jeedomapp-in', 'icon jeedomapp-in', 'icon jeedomapp-in', 'icon jeedomapp-in']; - $urlUsers = ['none', 'none', 'none', 'none']; + $urlUsers = ['none', 'none', 'none', 'none', 'none', 'none', 'none', 'none']; $j = 0; $menuCustomArray = []; for ($i = 1; $i <= $nbIcones; $i++) { @@ -450,7 +450,11 @@ public static function getMenuDefaultTab() $defaultMenuJson = '{"tab0":{"active":true,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&p=home"},"type":"WebviewApp"}, "tab1":{"active":true,"icon":{"name":"hubspot","type":"fa"},"name":"Synthese","options":{"uri":"\/index.php?v=m&p=overview"},"type":"WebviewApp"}, "tab2":{"active":true"icon":{"name":"medkit","type":"fa"},"name":"Sant\u00e9","options":{"uri":"\/index.php?v=m&p=health"},"type":"WebviewApp"}, - "tab3":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}}'; + "tab3":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}}, + "tab4":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}}, + "tab5":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}}, + "tab6":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}}, + "tab7":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}}'; return json_encode($defaultMenuJson); } From e739a837b95b56a1d6d4dec78990aebc15134742 Mon Sep 17 00:00:00 2001 From: "Julien C." Date: Fri, 25 Apr 2025 16:07:35 +0200 Subject: [PATCH 3/3] Update changelog.md --- docs/fr_FR/changelog.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/fr_FR/changelog.md b/docs/fr_FR/changelog.md index b9647c33..cf0a2c84 100755 --- a/docs/fr_FR/changelog.md +++ b/docs/fr_FR/changelog.md @@ -5,6 +5,11 @@ > Pour rappel s'il n'y a pas d'information sur la mise à jour, c'est que celle-ci concerne uniquement de la mise à jour de documentation, de traduction ou de texte +# 25/04/2025 + +- Ajout pour Max 8 Icones sur le menuCustom + + # 24/04/2025 - Ajout Commande Notifications Silencieuses pour Builds : IOS 491 et Android 875