diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Accelerometer.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Accelerometer.car index 8de93cc85b..53fee67825 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Accelerometer.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Accelerometer.car differ diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Battery.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Battery.car index 2d55b17941..a927a63578 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Battery.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Battery.car differ diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/GPS.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/GPS.car index fa95452126..f553e93c60 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/GPS.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/GPS.car differ diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Gravity.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Gravity.car index 2ffae76978..4c3ba876a2 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Gravity.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Gravity.car differ diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Gyroscope.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Gyroscope.car index 961cece6eb..2764f24771 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Gyroscope.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Gyroscope.car differ diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Light.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Light.car index f0d6f8381e..01a89bb48b 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Light.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Light.car differ diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Magnetic.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Magnetic.car index 2fd072e005..c6edb55a05 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Magnetic.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Magnetic.car differ diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Pressure.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Pressure.car index 7db5214b15..d7805ee3a7 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Pressure.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Pressure.car differ diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Proximity.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Proximity.car index 6bf842b7e7..239c62e5e9 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Proximity.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Proximity.car differ diff --git a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Rotation.car b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Rotation.car index fb52029c3e..cc6a7548bf 100644 Binary files a/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Rotation.car and b/features/device-mgt-iot-androidsense-feature/org.wso2.carbon.device.mgt.iot.androidsense.feature/src/main/resources/carbonapps/Rotation.car differ diff --git a/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/conf/app-conf.json b/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/conf/app-conf.json new file mode 100644 index 0000000000..bcd99b6c73 --- /dev/null +++ b/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/conf/app-conf.json @@ -0,0 +1,32 @@ +{ + "appName": "IoT Server", + "cachingEnabled": true, + "debuggingEnabled": false, + "permissionRoot": "/", + "loginUri": "${app.context}/login", + "adminServicesUrl": "https://${server.ip}:${server.https_port}/admin/services/", + "authModule": { + "enabled": true, + "login": { + "onSuccess": { + "script": "/app/modules/login.js", + "page": "cdmf.page.dashboard" + }, + "onFail": { + "script": "/app/modules/login.js", + "page": "cdmf.page.sign-in" + } + }, + "logout": { + "onSuccess": { + "page": "cdmf.page.sign-in" + }, + "onFail": { + "page": "cdmf.page.dashboard" + } + }, + "sso": { + "enabled": false + } + } +} \ No newline at end of file diff --git a/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/pages/iot.page.register/register.json b/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/pages/iot.page.register/register.json index 13a1bda7e0..58346ba14a 100644 --- a/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/pages/iot.page.register/register.json +++ b/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/pages/iot.page.register/register.json @@ -1,5 +1,6 @@ { "version": "1.0.0", "uri": "/register", + "isAnonymous": true, "layout": "uuf.layout.sign-in" } \ No newline at end of file diff --git a/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.ui.header.logo/logo.hbs b/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.ui.header.logo/logo.hbs index 6444d9e643..b1841e1864 100644 --- a/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.ui.header.logo/logo.hbs +++ b/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.ui.header.logo/logo.hbs @@ -1 +1 @@ -{{#zone "productName"}}IoT Server{{/zone}} \ No newline at end of file +{{#zone "productName"}}{{@app.conf.appName}}{{/zone}} \ No newline at end of file diff --git a/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.user.sign-in/public/js/login.js b/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.user.sign-in/public/js/login.js deleted file mode 100644 index 1feefb379b..0000000000 --- a/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.user.sign-in/public/js/login.js +++ /dev/null @@ -1,50 +0,0 @@ -function post(path, method) { - method = method || "post"; // Set method to post by default if not specified. - form.submit(); -} - - -$( document ).ready(function() { - var currentHash = window.location.hash, - submitPath = $("#signInForm").attr("action"); - if(currentHash=="#auth-failed") { - $('.wr-validation-summary p').text("Sorry!, Please make sure to enter correct username and password"); - $('.wr-validation-summary').removeClass("hidden"); - }else if(currentHash=="#error"){ - $('.wr-validation-summary p').text("Sorry!, Error occured"); - $('.wr-validation-summary').removeClass("hidden"); - } - $('#signIn').click(function(){ - var username = $("input#username").val(), - password = $("input#password").val(); - - if (!username) { - $('.wr-validation-summary p').text("Sorry!, Username cannot be empty."); - $('.wr-validation-summary').removeClass("hidden"); - } else if (!password){ - $('.wr-validation-summary p').text("Sorry!, Password cannot be empty."); - $('.wr-validation-summary').removeClass("hidden"); - } else { - post(submitPath,"POST"); - } - }); -}); - - -function submitLoginForm() { - var submitPath = $("#signInForm").attr("action"); - $('form input').keypress(function() { - if(e.which == 10 || e.which == 13) { - if (!username) { - alert() - $('.wr-validation-summary p').text("Sorry!, Username cannot be empty."); - $('.wr-validation-summary').removeClass("hidden"); - } else if (!password){ - $('.wr-validation-summary p').text("Sorry!, Password cannot be empty."); - $('.wr-validation-summary').removeClass("hidden"); - } else { - post(submitPath,"POST"); - } - } - }); -} diff --git a/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.user.sign-in/sign-in.hbs b/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.user.sign-in/sign-in.hbs index 9792da2d52..4ab4ff871b 100644 --- a/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.user.sign-in/sign-in.hbs +++ b/features/device-mgt-iot-feature/org.wso2.carbon.device.mgt.iot.feature/src/main/resources/jaggeryapps/devicemgt/app/units/iot.unit.user.sign-in/sign-in.hbs @@ -1,44 +1,5 @@ -
-{{#zone "bottomLoginJs"}} - {{js "js/login.js" }} {{/zone}} diff --git a/features/device-mgt-iot-virtualfirealarm-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/carbonapps/Temperature_Sensor.car b/features/device-mgt-iot-virtualfirealarm-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/carbonapps/Temperature_Sensor.car index 6ad7c09162..ce38a8c545 100644 Binary files a/features/device-mgt-iot-virtualfirealarm-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/carbonapps/Temperature_Sensor.car and b/features/device-mgt-iot-virtualfirealarm-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/carbonapps/Temperature_Sensor.car differ