Skip to content

Commit cc31c0b

Browse files
committed
add for8icons
1 parent 2b55993 commit cc31c0b

2 files changed

Lines changed: 10 additions & 6 deletions

File tree

core/api/mobile.api.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
if (mobile::whoIsIq($params['Iq']) == 'mobile non detecte') {
3636
//createMobile($params, 3);
3737
log::add('mobile', 'debug', '| [WARNING] mobile non detecté !');
38-
createMobile($params, 8);
38+
createMobile($params, 3);
3939
} else {
4040
log::add('mobile', 'debug', '| Mobile demandeur > ' . mobile::whoIsIq($params['Iq']));
4141
}
@@ -50,7 +50,7 @@
5050
* @param array
5151
* @return new object
5252
*/
53-
function createMobile($params, $nbIcones = 8)
53+
function createMobile($params, $nbIcones = 3)
5454
{
5555
$configs = $params['configs'];
5656
$notification = $configs['notification'];
@@ -137,7 +137,7 @@ function saveMenuFromAppV2($menu, $mobile)
137137
$mobile = eqLogic::byLogicalId($params['Iq'], 'mobile');
138138
}
139139
if (!is_object($mobile)) {
140-
$mobile = createMobile($params,8);
140+
$mobile = createMobile($params,3);
141141
}
142142
$mobile->setConfiguration('type_mobile', $notification['platform']);
143143
if (isset($notification['token'])) {

core/class/mobile.class.php

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -423,12 +423,12 @@ public static function createCmdGeoLocV2($Iq, $geolocs)
423423
* Get menu default whitout "tab"
424424
* @return array
425425
*/
426-
public static function getMenuDefaultV2($nbIcones = 8)
426+
public static function getMenuDefaultV2($nbIcones = 3)
427427
{
428428
$namesMenus = ['home', 'overview', 'health', 'home', 'home', 'home', 'home', 'home'];
429429
$renamesIcons = ['Accueil', 'Synthese', 'Santé', 'Accueil', 'Accueil', 'Accueil', 'Accueil', 'Accueil'];
430430
$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'];
431-
$urlUsers = ['none', 'none', 'none', 'none'];
431+
$urlUsers = ['none', 'none', 'none', 'none', 'none', 'none', 'none', 'none'];
432432
$j = 0;
433433
$menuCustomArray = [];
434434
for ($i = 1; $i <= $nbIcones; $i++) {
@@ -450,7 +450,11 @@ public static function getMenuDefaultTab()
450450
$defaultMenuJson = '{"tab0":{"active":true,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&p=home"},"type":"WebviewApp"},
451451
"tab1":{"active":true,"icon":{"name":"hubspot","type":"fa"},"name":"Synthese","options":{"uri":"\/index.php?v=m&p=overview"},"type":"WebviewApp"},
452452
"tab2":{"active":true"icon":{"name":"medkit","type":"fa"},"name":"Sant\u00e9","options":{"uri":"\/index.php?v=m&p=health"},"type":"WebviewApp"},
453-
"tab3":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}}';
453+
"tab3":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}},
454+
"tab4":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}},
455+
"tab5":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}},
456+
"tab6":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}},
457+
"tab7":{"active":false,"icon":{"name":"in","type":"jeedomapp"},"name":"Accueil","options":{"uri":"\/index.php?v=m&app_mode=1"},"type":"WebviewApp"}}';
454458
return json_encode($defaultMenuJson);
455459
}
456460

0 commit comments

Comments
 (0)