Merge branch 'pr1049' into origin-master

# Conflicts:
#	modules/distribution/src/core/samples/connectedcup/component/ui/src/main/resources/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.connectedcup.device-view/device-view.hbs
application-manager-new
sinthuja 8 years ago
commit 2803ba29e7

@ -1,3 +1,21 @@
{{!
Copyright (c) 2017, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
WSO2 Inc. licenses this file to you under the Apache License,
Version 2.0 (the "License"); you may not use this file except
in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
}}
{{#zone "topCss"}}
<style>
.thumbnail.icon:before {
@ -40,7 +58,7 @@
<h4>Device Operations</h4>
</div>
<div class="buttons">
<a class="btn-operations" target="_blank"
<a class="btn-operations" target="_blank"
href="{{../device.ip}}/connected-cup-agent/index.jsp?deviceOwner={{@user.username}}&tenantDomain={{@user.domain}}&deviceId={{../device.deviceIdentifier}}&token={{../device.accessToken}}" >
Go To Device
</a>

@ -36,7 +36,7 @@ function onRequest(context) {
token = tokenPair.accessToken;
}
websocketEndpoint = websocketEndpoint + "/secured-websocket/org.wso2.iot.devices.temperature/1.0.0?"
+ "deviceId=" + device.deviceIdentifier + "&deviceType=" + device.type;
+ "deviceId=" + device.deviceIdentifier + "&deviceType=" + device.type+ "&websocketToken=" + token;
var websocketToken= {'name':'websocket-token','value': token, 'path':'/', "maxAge":18000};
response.addCookie(websocketToken);
}

@ -138,7 +138,7 @@ function doAction(data) {
window.location = '/devicemgt/login';
});
showPopup();
} else if (data == 403) {
} else if (data.status == 403) {
$(modalPopupContent).html($('#device-403-content').html());
$('#device-403-link').click(function () {
window.location = '/devicemgt/login';

Loading…
Cancel
Save