From bf567ec42603c4a53c8574359464fe603c4135d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CVeLiTi=E2=80=9D?= <“info@veliti.nl”> Date: Wed, 2 Oct 2024 16:57:01 +0200 Subject: [PATCH] CM69 - Bugfix graph cartest, CMXX - Healthindex update --- account.php | 7 + api/v1/get/equipment_data.php | 6 +- api/v2/get/equipment_data.php | 7 +- api/v2/get/equipment_healthindex.php | 194 +++++++++++++++++++ assets/functions.php | 110 +++++++---- assets/readdevice.js | 203 ++++++++++++++------ buildtool.php | 1 + equipment.php | 23 +-- equipment_data.php | 114 +++++++++++ report_healthindex.php | 219 ++++++++++++++++++++++ settings/settingsmenu.php | 8 +- settings/translations/translations_DE.php | 3 +- settings/translations/translations_NL.php | 3 +- settings/translations/translations_US.php | 3 +- 14 files changed, 776 insertions(+), 125 deletions(-) create mode 100644 api/v2/get/equipment_healthindex.php create mode 100644 equipment_data.php create mode 100644 report_healthindex.php diff --git a/account.php b/account.php index 212a49c..5959e2e 100644 --- a/account.php +++ b/account.php @@ -23,6 +23,7 @@ if (isAllowed($page,$_SESSION['profile'],$_SESSION['permission'],'R') === 0){ $update_allowed = isAllowed($page ,$_SESSION['profile'],$_SESSION['permission'],'U'); $delete_allowed = isAllowed($page ,$_SESSION['profile'],$_SESSION['permission'],'D'); $create_allowed = isAllowed($page ,$_SESSION['profile'],$_SESSION['permission'],'C'); +$healthindex_allowed = isAllowed('report_healthindex' ,$_SESSION['profile'],$_SESSION['permission'],'R'); //GET Details from URL $GET_VALUES = urlGETdetails($_GET) ?? ''; @@ -248,6 +249,11 @@ if ($_SESSION['permission'] == 3 || $_SESSION['permission'] == 4){ $view_users = ' '.$button_partner_assigned_users.''; } +$healthindex =''; +if ($healthindex_allowed === 1){ + $healthindex = ''.$view_asset_data_ranking.''; +} + $view .= '
| '.$view_asset_data_ranking.' | +'.$equipment_label1.' | +'.$equipment_label2.' | +'.$equipment_label3.' | +'.$equipment_label4.' | ++ | '.$general_soldto.' | +'.$general_shipto.' | +'.$view_asset_actions.' | +
|---|---|---|---|---|---|---|---|---|
| '.$message_no_assets.' | +||||||||
| '.$response->healthindex.' | +'.$indicators.' | +'.$response->serialnumber.' | +'.$$status_text.' | +'.$response->productcode.'-'.$response->productname.' | '; +$view .= '';
+ if (!empty($picture)){
+ $view .='
+ |
+ '.$soldto.' | +'.$shipto.' | +'.$general_view .' | +