merge-requests/1/head
dilanua 8 years ago
parent 4947664b4b
commit a92070f16e

@ -163,6 +163,7 @@
<h4 class="remove-margin"><i class="icon fw fw-info"></i>Not available yet</h4> <h4 class="remove-margin"><i class="icon fw fw-info"></i>Not available yet</h4>
</div> </div>
{{/equal}} {{/equal}}
{{#if device.viewModel.deviceInfo}}
{{#if device.viewModel.BatteryLevel}} {{#if device.viewModel.BatteryLevel}}
<div class="col-xs-12 col-sm-6 col-md-6 col-lg-6"> <div class="col-xs-12 col-sm-6 col-md-6 col-lg-6">
<div class="col-md-12"> <div class="col-md-12">
@ -178,21 +179,21 @@
</div> </div>
</div> </div>
{{/if}} {{/if}}
{{#if device.viewModel.cpuUsage}} <!--{{#if device.viewModel.cpuUsage}}-->
<div class="col-xs-12 col-sm-6 col-md-6 col-lg-6"> <!--<div class="col-xs-12 col-sm-6 col-md-6 col-lg-6">-->
<div class="col-md-12"> <!--<div class="col-md-12">-->
<div class="wr-stats-board-tile"> <!--<div class="wr-stats-board-tile">-->
<div class="tile-name">CPU Usage</div> <!--<div class="tile-name">CPU Usage</div>-->
<div> <!--<div>-->
<div class="tile-icon"><i class="fw fw-dashboard"></i></div> <!--<div class="tile-icon"><i class="fw fw-dashboard"></i></div>-->
<div class="tile-stats"> <!--<div class="tile-stats">-->
{{device.viewModel.cpuUsage.value}} % <!--{{device.viewModel.cpuUsage.value}} %-->
</div> <!--</div>-->
</div> <!--</div>-->
</div> <!--</div>-->
</div> <!--</div>-->
</div> <!--</div>-->
{{/if}} <!--{{/if}}-->
{{#if device.viewModel.ramUsage}} {{#if device.viewModel.ramUsage}}
<div class="col-xs-12 col-sm-6 col-md-6 col-lg-6"> <div class="col-xs-12 col-sm-6 col-md-6 col-lg-6">
<div class="col-md-12"> <div class="col-md-12">
@ -244,6 +245,14 @@
</div> </div>
</div> </div>
{{/if}} {{/if}}
{{else}}
<div class="message message-info">
<h4 class="remove-margin">
<i class="icon fw fw-info"></i>
Battery, RAM and Storage related information is not available yet.
</h4>
</div>
{{/if}}
</div> </div>
</div> </div>
</div> </div>

@ -76,6 +76,8 @@ function onRequest(context) {
deviceInfo = info; deviceInfo = info;
if (device["deviceInfo"]) { if (device["deviceInfo"]) {
viewModel["deviceInfo"] = true;
viewModel["model"] = device["deviceInfo"]["deviceModel"]; viewModel["model"] = device["deviceInfo"]["deviceModel"];
viewModel["vendor"] = device["deviceInfo"]["vendor"]; viewModel["vendor"] = device["deviceInfo"]["vendor"];
viewModel["lastUpdatedTime"] = device["deviceInfo"]["updatedTime"]. viewModel["lastUpdatedTime"] = device["deviceInfo"]["updatedTime"].
@ -117,6 +119,8 @@ function onRequest(context) {
} else { } else {
viewModel["externalMemory"]["usage"] = 0; viewModel["externalMemory"]["usage"] = 0;
} }
} else {
viewModel["deviceInfo"] = false;
} }
} else if (device["type"] == "windows") { } else if (device["type"] == "windows") {
viewModel["imei"] = device["properties"]["IMEI"]; viewModel["imei"] = device["properties"]["IMEI"];

Loading…
Cancel
Save