From 36d4c7dfcbfe26ddb826a8be542ee0e5998f4be0 Mon Sep 17 00:00:00 2001 From: dilanua Date: Thu, 22 Sep 2016 18:35:13 +0530 Subject: [PATCH] Updating emm device listing - UI --- .../public/js/device-listing.js | 33 ++----------------- 1 file changed, 3 insertions(+), 30 deletions(-) diff --git a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/mdm.page.devices/public/js/device-listing.js b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/mdm.page.devices/public/js/device-listing.js index d8c1aa2ed..9d1e6e7fc 100644 --- a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/mdm.page.devices/public/js/device-listing.js +++ b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/mdm.page.devices/public/js/device-listing.js @@ -149,7 +149,8 @@ function loadDevices() { url = "device/" + deviceType + "?id=" + deviceIdentifier; } return '
' + - '
' + '' + + '' } }, { @@ -219,7 +220,6 @@ function loadDevices() { function () { $(".icon .text").res_text(0.2); $('#device-grid').removeClass('hidden'); - $("#loading-content").remove(); }, { "placeholder" : "Search By Device Name", "searchKey" : "name" @@ -244,38 +244,11 @@ function loadDevices() { // }); //} -function initPage() { -// var currentUser = $("#device-listing").data("currentUser"); -// var serviceURL = "/api/device-mgt/v1.0/devices"; -// -// invokerUtil.get( -// serviceURL, -// function (data) { -// if (data) { -// data = JSON.parse(data); -// if (data["count"] > 0) { -// $(".bulk-action-row").removeClass('hidden'); -// $("#device-table").removeClass('hidden'); -// loadDevices(); -// } else { -// $("#enroll-btn").addClass('hidden'); -// $("#advanced-search-btn").addClass('hidden'); -// $("#device-table").addClass('hidden'); -// $("#no-device-view").removeClass('hidden'); -// } -// } -// }, function () { -// initPage(); -// } -// ); - loadDevices(); -} - /* * DOM ready functions. */ $(document).ready(function () { - initPage(); + loadDevices(); /* Adding selected class for selected devices */ $(deviceCheckbox).each(function () {