diff --git a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.android.platform.configuration/public/js/platform-configuration.js b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.android.platform.configuration/public/js/platform-configuration.js index 4ad5d5341..a179701e5 100644 --- a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.android.platform.configuration/public/js/platform-configuration.js +++ b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.android.platform.configuration/public/js/platform-configuration.js @@ -227,11 +227,8 @@ $(document).ready(function () { addConfigAPI, addConfigFormData, function (data, textStatus, jqXHR) { - data = JSON.parse(data); - if (jqXHR.status == 201) { - $("#config-save-form").addClass("hidden"); - $("#record-created-msg").removeClass("hidden"); - } + $("#config-save-form").addClass("hidden"); + $("#record-created-msg").removeClass("hidden"); }, function (data) { if (data.status == 500) { diff --git a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/units/mdm.unit.device.view/public/js/device-detail.js b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/units/mdm.unit.device.view/public/js/device-detail.js index f56ba9556..dd53bc04e 100644 --- a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/units/mdm.unit.device.view/public/js/device-detail.js +++ b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/units/mdm.unit.device.view/public/js/device-detail.js @@ -185,17 +185,17 @@ var InitiateViewOption = null; $("#applications-list-container").html(content); } else { $("#applications-list-container"). - html("

No applications found.

" + - "

Please try refreshing the list in a while.

"); + html("

No applications found.

" + + "

Please try refreshing the list in a while.

"); } } }, // error-callback function () { $("#applications-list-container"). - html("

 Loading application list " + - "was not successful. please try refreshing the list in a while.

"); - }); + html("

 Loading application list " + + "was not successful. please try refreshing the list in a while.

"); + }); }); } @@ -251,50 +251,50 @@ var InitiateViewOption = null; // error-callback function () { $("#policy-list-container"). - html("
" + - "

" + - "" + - "Loading policy compliance related data " + - "was not successful. please try refreshing in a while." + - "

" + - "
" + - "

" + - "

" + - "

" - ); + html("
" + + "

" + + "" + + "Loading policy compliance related data " + + "was not successful. please try refreshing in a while." + + "

" + + "
" + + "

" + + "

" + + "

" + ); } ); } } else if ((jqXHR.status == 200 && !data)) { $("#policy-spinner").addClass("hidden"); $("#policy-list-container"). - html("
" + - "

" + - "" + - "There is currently no effective policy applied for this device." + - "

" + - "
" + - "

" + - "

" + - "

" - ); + html("
" + + "

" + + "" + + "There is currently no effective policy applied for this device." + + "

" + + "
" + + "

" + + "

" + + "

" + ); } }, // error-callback function () { $("#policy-spinner").addClass("hidden"); $("#policy-list-container"). - html("
" + - "

" + - "" + - "Loading policy compliance related data " + - "was not successful. please try refreshing in a while." + - "

" + - "
" + - "

" + - "

" + - "

" - ); + html("
" + + "

" + + "" + + "Loading policy compliance related data " + + "was not successful. please try refreshing in a while." + + "

" + + "
" + + "

" + + "

" + + "

" + ); } ); } @@ -309,6 +309,10 @@ var InitiateViewOption = null; loadApplicationsList(); loadPolicyCompliance(); + if ($("#device_details_tab").length == 0) { + $(".device-detail-body").addClass("hidden"); + } + $("#refresh-policy").click(function () { $("#policy-spinner").removeClass("hidden"); loadPolicyCompliance(); diff --git a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/units/mdm.unit.device.view/view.hbs b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/units/mdm.unit.device.view/view.hbs index d44d94957..5d1470c11 100644 --- a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/units/mdm.unit.device.view/view.hbs +++ b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/units/mdm.unit.device.view/view.hbs @@ -6,7 +6,8 @@ {{#if deviceFound}} {{#if isAuthorized}}

+ data-deviceid="{{deviceView.deviceIdentifier}}" data-type="{{deviceView.deviceType}}" + data-ownership="{{deviceView.ownership}}"> Device {{deviceView.name}} {{#if deviceView.model}} @@ -15,413 +16,463 @@ {{/if}}

-
-
-
-
-
-
Device Overview
- {{#defineZone "device-detail-properties"}} - - - {{#if deviceView.deviceIdentifier}} - - - - - {{/if}} - {{#if deviceView.name}} - - - - - {{/if}} - {{#if deviceView.vendor}} - {{#if deviceView.model}} +
+
+
+
+
+
Device + Overview +
+ {{#defineZone "device-detail-properties"}} +
Device ID{{deviceView.deviceIdentifier}}
Name{{deviceView.name}}
+ + {{#if deviceView.deviceIdentifier}} - - + + {{/if}} - {{/if}} - {{#if deviceView.status}} - - - - - {{/if}} - {{#if deviceView.owner}} - - - - - {{/if}} - {{#if deviceView.ownership}} - - - - - {{/if}} - {{#if deviceView.imei}} - - - - - {{/if}} - {{#if deviceView.udid}} - - - - - {{/if}} - {{#if deviceView.osBuildDate}} - - - - - {{/if}} - {{#if deviceView.phoneNumber}} - - - - - {{/if}} - {{#if deviceView.lastUpdatedTime}} - - - - - {{/if}} - -
Model{{deviceView.vendor}} {{deviceView.model}}Device ID{{deviceView.deviceIdentifier}}
Status - {{#equal deviceView.status "ACTIVE"}}  Active{{/equal}} - {{#equal deviceView.status "INACTIVE"}}  Inactive{{/equal}} - {{#equal deviceView.status "BLOCKED"}}  Blocked{{/equal}} - {{#equal deviceView.status "REMOVED"}}  Removed{{/equal}} -
Owner{{deviceView.owner}}
Ownership{{deviceView.ownership}}
IMEI{{deviceView.imei}}
UDID{{deviceView.udid}}
Firmware Build Date{{deviceView.osBuildDate}}
Phone Number{{deviceView.phoneNumber}}
Last Update{{deviceView.lastUpdatedTime}}
- {{/defineZone}} -
Operations
-
- {{unit "mdm.unit.device.operation-bar" deviceType=deviceView.deviceType ownership=deviceView.ownership}} -
-
-
-
- - {{#defineZone "device-detail-properties"}} -
-
- - -
- - -
-
-
- - {{#equal deviceView.deviceType "windows"}} -
-

Not available yet

-
- {{/equal}} - {{#if deviceView.deviceInfoAvailable}} - {{#if deviceView.BatteryLevel}} -
-
-
-
BATTERY
-
-
-
- {{deviceView.BatteryLevel.value}} % -
-
-
-
-
- {{/if}} - - - - - - - - - - - - - - - - {{#if deviceView.ramUsage}} -
-
-
-
RAM Usage
-
-
-
- {{deviceView.ramUsage.value}} % -
-
-
-
-
- {{/if}} - {{#if deviceView.internalMemory}} -
-
-
-
Local Storage
-
-
-
- {{deviceView.internalMemory.usage}} % - - TOTAL OF {{deviceView.internalMemory.total}} GB - -
-
-
-
-
- {{/if}} - {{#if deviceView.externalMemory}} -
-
-
-
External Storage
-
-
-
- {{deviceView.externalMemory.usage}} % - - TOTAL OF {{deviceView.externalMemory.total}} GB - -
-
-
-
-
- {{/if}} - {{else}} -
-

- - Battery, RAM and Storage related information are not available yet. -

-
+ {{#if deviceView.name}} + + Name + {{deviceView.name}} + {{/if}} -
+ {{#if deviceView.vendor}} + {{#if deviceView.model}} + + Model + {{deviceView.vendor}} {{deviceView.model}} + + {{/if}} + {{/if}} + {{#if deviceView.status}} + + Status + + {{#equal deviceView.status "ACTIVE"}}  Active{{/equal}} + {{#equal deviceView.status "INACTIVE"}}  Inactive{{/equal}} + {{#equal deviceView.status "BLOCKED"}}  Blocked{{/equal}} + {{#equal deviceView.status "REMOVED"}}  Removed{{/equal}} + + + {{/if}} + {{#if deviceView.owner}} + + Owner + {{deviceView.owner}} + + {{/if}} + {{#if deviceView.ownership}} + + Ownership + {{deviceView.ownership}} + + {{/if}} + {{#if deviceView.imei}} + + IMEI + {{deviceView.imei}} + + {{/if}} + {{#if deviceView.udid}} + + UDID + {{deviceView.udid}} + + {{/if}} + {{#if deviceView.osBuildDate}} + + Firmware Build + Date + + {{deviceView.osBuildDate}} + + {{/if}} + {{#if deviceView.phoneNumber}} + + Phone Number + {{deviceView.phoneNumber}} + + {{/if}} + {{#if deviceView.lastUpdatedTime}} + + Last Update + {{deviceView.lastUpdatedTime}} + + {{/if}} + + + {{/defineZone}} +
+ Operations {{deviceView.isNotWindows}} +
+
+ {{unit "mdm.unit.device.operation-bar" deviceType=deviceView.deviceType ownership=deviceView.ownership}}
-
-