From 20e7dd9e86f1ebe82eabfcf5d5ac826a1705a395 Mon Sep 17 00:00:00 2001 From: ayyoob Date: Thu, 17 Nov 2016 23:33:04 +0530 Subject: [PATCH] picked icon from features config --- .../devicemgt/app/modules/business-controllers/operation.js | 2 +- .../cdmf.unit.device.operation-bar/public/js/operation-bar.js | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/modules/business-controllers/operation.js b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/modules/business-controllers/operation.js index fd85d978f67..f072a27d5bc 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/modules/business-controllers/operation.js +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/modules/business-controllers/operation.js @@ -73,7 +73,7 @@ var operationModule = function () { var features = utility.getDeviceTypeConfig(deviceType).deviceType.features; for (var op in operations) { var iconIdentifier = operations[op].operation; - if (features[iconIdentifier]) { + if (features && features[iconIdentifier]) { var icon = features[iconIdentifier].icon; if (icon) { operations[op]["iconFont"] = icon; diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.device.operation-bar/public/js/operation-bar.js b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.device.operation-bar/public/js/operation-bar.js index f577f90545f..386e837d762 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.device.operation-bar/public/js/operation-bar.js +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.device.operation-bar/public/js/operation-bar.js @@ -59,7 +59,6 @@ function submitForm(formId) { contentType = "application/x-www-form-urlencoded"; payload = uriencodedFormStr; } - alert(featurePayload); //setting responses callbacks var defaultStatusClasses = "fw fw-stack-1x"; var content = $("#operation-response-template").find(".content");