From 11483c6f6bb3cf8d14be5c5dad1fa9c67e4d97bb Mon Sep 17 00:00:00 2001 From: sandarudr Date: Thu, 21 Nov 2019 18:49:39 +0530 Subject: [PATCH] Add COSU profile configuration to enable/disable the always-on display. --- .../public/js/operation-mod.js | 3 +++ .../public/templates/android-policy-edit.hbs | 15 +++++++++++++++ .../public/templates/android-policy-view.hbs | 15 +++++++++++++++ .../templates/android-policy-operations.hbs | 15 +++++++++++++++ 4 files changed, 48 insertions(+) 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.operation-mod/public/js/operation-mod.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.operation-mod/public/js/operation-mod.js index c0a1268b3..599d9f33e 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.operation-mod/public/js/operation-mod.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.operation-mod/public/js/operation-mod.js @@ -235,6 +235,8 @@ var androidOperationModule = function () { payload["kioskLogoImage"] = deviceGlobalConfigurations["kioskLogoImage"]; payload["kioskAppName"] = deviceGlobalConfigurations["kioskAppName"]; payload["isSingleModeApp"] = deviceGlobalConfigurations["isSingleModeApp"]; + payload["keepDisplayAwake"] = deviceGlobalConfigurations["keepDisplayAwake"]; + if (payload["isSingleModeApp"] === true) { payload["isSingleModeAppBuiltForKiosk"] = deviceGlobalConfigurations["isSingleModeAppBuiltForKiosk"]; @@ -589,6 +591,7 @@ var androidOperationModule = function () { operationData["isSingleModeAppBuiltForKiosk"]; } deviceGlobalConfigurations["isIdleGraphicsEnabled"] = operationData["isIdleGraphicsEnabled"]; + deviceGlobalConfigurations["keepDisplayAwake"] = operationData["keepDisplayAwake"]; if (operationData["idleTimeout"]) { deviceGlobalConfigurations["idleTimeout"] = operationData["idleTimeout"]; } 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.policy-edit/public/templates/android-policy-edit.hbs 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.policy-edit/public/templates/android-policy-edit.hbs index e82c1132a..804be22ba 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.policy-edit/public/templates/android-policy-edit.hbs +++ 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.policy-edit/public/templates/android-policy-edit.hbs @@ -2241,6 +2241,21 @@ + +
+
+ Keep display awake + + +
+
+ +
+
+ Keep display awake + + +
+
+ +
+
+ Keep display awake + + +
+