Skip to content

Commit e0c613a

Browse files
committed
add checkApiState
1 parent 4cc48dd commit e0c613a

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

core/class/mobile.class.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ public static function getConfigForCommunity()
4848
$res .= 'OS : ' . $distrib . ' on ' . $hw;
4949
$res .= ' - PHP : ' . phpversion() . '<br>```';
5050
$res .= '<br/><br/>';
51+
$res .= 'Etat Clé Api : '.config::byKey('api::mobile::mode');
52+
$res .= '<br/><br/>';
5153
$res .= '[details="Equipement(s)"]<br/>';
5254
$res .= '|Id | LogicalId | Type | App | defaultIdMobile | Profil | hideMenuGeoloc | hideMenuCustom|<br>';
5355
$res .= '|--- | --- | --- | --- | --- | --- | --- | ---|<br>';

desktop/php/mobile.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@
1414
array_push($eqLogicsV1, $eqLogic);
1515
}
1616
}
17+
$isApi = config::byKey('api::mobile::mode');
18+
if($isApi == 'whiteip' || $isApi == 'disable'){
19+
message::add('mobile', 'L\'API mobile est désactivée ou en mode whitelist IP');
20+
}
1721
?>
1822

1923
<div class="row row-overflow">

0 commit comments

Comments
 (0)