forked from community/device-mgt-core
Merge branch 'release-2.0.x' of https://github.com/wso2/carbon-device-mgt into mutual_ssl_feature
commit
8e2432c47b
@ -0,0 +1,57 @@
|
||||
/*
|
||||
* Copyright (c) 2016, 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.
|
||||
*/
|
||||
|
||||
package org.wso2.carbon.device.mgt.common;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* This class holds configurations for Operation Monitoring Task.
|
||||
*/
|
||||
public class OperationMonitoringTaskConfig {
|
||||
|
||||
private boolean isEnabled;
|
||||
private int frequency;
|
||||
private List<MonitoringOperation> monitoringOperation = new ArrayList<>();
|
||||
|
||||
public boolean isEnabled() {
|
||||
return isEnabled;
|
||||
}
|
||||
|
||||
public void setEnabled(boolean enabled) {
|
||||
isEnabled = enabled;
|
||||
}
|
||||
|
||||
public int getFrequency() {
|
||||
return frequency;
|
||||
}
|
||||
|
||||
public void setFrequency(int frequency) {
|
||||
this.frequency = frequency;
|
||||
}
|
||||
|
||||
public List<MonitoringOperation> getMonitoringOperation() {
|
||||
return monitoringOperation;
|
||||
}
|
||||
|
||||
public void setMonitoringOperation(List<MonitoringOperation> monitoringOperation) {
|
||||
this.monitoringOperation = monitoringOperation;
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,48 @@
|
||||
/*
|
||||
* Copyright (c) 2014, 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.
|
||||
*/
|
||||
|
||||
package org.wso2.carbon.device.mgt.core.internal;
|
||||
|
||||
import org.wso2.carbon.device.mgt.common.OperationMonitoringTaskConfig;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public class DeviceMonitoringOperationDataHolder {
|
||||
|
||||
private static DeviceMonitoringOperationDataHolder thisInstance = new DeviceMonitoringOperationDataHolder();
|
||||
private Map<String, OperationMonitoringTaskConfig> OperationConfigMap = Collections.synchronizedMap(
|
||||
new HashMap<String, OperationMonitoringTaskConfig>());
|
||||
|
||||
|
||||
public static DeviceMonitoringOperationDataHolder getInstance() {
|
||||
return thisInstance;
|
||||
}
|
||||
|
||||
public void addOperationMonitoringConfigToMap(String deviceType, OperationMonitoringTaskConfig OperationConfig) {
|
||||
this.OperationConfigMap.put(deviceType, OperationConfig);
|
||||
}
|
||||
|
||||
public Map<String, OperationMonitoringTaskConfig> getOperationMonitoringConfigFromMap(){
|
||||
return this.OperationConfigMap;
|
||||
}
|
||||
}
|
@ -1,44 +0,0 @@
|
||||
/*
|
||||
Copyright (c) 2016, 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.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Returns the dynamic state to be populated by add-user page.
|
||||
*
|
||||
* @param context Object that gets updated with the dynamic state of this page to be presented
|
||||
* @returns {*} A context object that returns the dynamic state of this page to be presented
|
||||
*/
|
||||
function onRequest(context) {
|
||||
var log = new Log("units/user-create/certificate-create.js");
|
||||
var userModule = require("/app/modules/business-controllers/user.js")["userModule"];
|
||||
var response = userModule.getRolesByUserStore();
|
||||
var mdmProps = require("/app/modules/conf-reader/main.js")["conf"];
|
||||
if (response["status"] == "success") {
|
||||
context["roles"] = response["content"];
|
||||
}
|
||||
|
||||
context["charLimit"] = mdmProps["usernameLength"];
|
||||
context["usernameJSRegEx"] = mdmProps["userValidationConfig"]["usernameJSRegEx"];
|
||||
context["usernameHelpText"] = mdmProps["userValidationConfig"]["usernameHelpMsg"];
|
||||
context["usernameRegExViolationErrorMsg"] = mdmProps["userValidationConfig"]["usernameRegExViolationErrorMsg"];
|
||||
context["firstnameJSRegEx"] = mdmProps["userValidationConfig"]["firstnameJSRegEx"];
|
||||
context["firstnameRegExViolationErrorMsg"] = mdmProps["userValidationConfig"]["firstnameRegExViolationErrorMsg"];
|
||||
context["lastnameJSRegEx"] = mdmProps["userValidationConfig"]["lastnameJSRegEx"];
|
||||
context["lastnameRegExViolationErrorMsg"] = mdmProps["userValidationConfig"]["lastnameRegExViolationErrorMsg"];
|
||||
|
||||
return context;
|
||||
}
|
@ -1,534 +0,0 @@
|
||||
/*
|
||||
*
|
||||
* 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.
|
||||
*/
|
||||
|
||||
var validateStep = {};
|
||||
var stepForwardFrom = {};
|
||||
var stepBackFrom = {};
|
||||
var policy = {};
|
||||
var configuredOperations = [];
|
||||
var validateInline = {};
|
||||
var clearInline = {};
|
||||
|
||||
var enableInlineError = function (inputField, errorMsg, errorSign) {
|
||||
var fieldIdentifier = "#" + inputField;
|
||||
var errorMsgIdentifier = "#" + inputField + " ." + errorMsg;
|
||||
var errorSignIdentifier = "#" + inputField + " ." + errorSign;
|
||||
|
||||
if (inputField) {
|
||||
$(fieldIdentifier).addClass(" has-error has-feedback");
|
||||
}
|
||||
|
||||
if (errorMsg) {
|
||||
$(errorMsgIdentifier).removeClass(" hidden");
|
||||
}
|
||||
|
||||
if (errorSign) {
|
||||
$(errorSignIdentifier).removeClass(" hidden");
|
||||
}
|
||||
};
|
||||
|
||||
var disableInlineError = function (inputField, errorMsg, errorSign) {
|
||||
var fieldIdentifier = "#" + inputField;
|
||||
var errorMsgIdentifier = "#" + inputField + " ." + errorMsg;
|
||||
var errorSignIdentifier = "#" + inputField + " ." + errorSign;
|
||||
|
||||
if (inputField) {
|
||||
$(fieldIdentifier).removeClass(" has-error has-feedback");
|
||||
}
|
||||
|
||||
if (errorMsg) {
|
||||
$(errorMsgIdentifier).addClass(" hidden");
|
||||
}
|
||||
|
||||
if (errorSign) {
|
||||
$(errorSignIdentifier).addClass(" hidden");
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
*clear inline validation messages.
|
||||
*/
|
||||
clearInline["policy-name"] = function () {
|
||||
disableInlineError("policyNameField", "nameEmpty", "nameError");
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Validate if provided policy name is valid against RegEx configures.
|
||||
*/
|
||||
validateInline["policy-name"] = function () {
|
||||
var policyName = $("input#policy-name-input").val();
|
||||
if (policyName && inputIsValidAgainstLength(policyName, 1, 30)) {
|
||||
disableInlineError("policyNameField", "nameEmpty", "nameError");
|
||||
} else {
|
||||
enableInlineError("policyNameField", "nameEmpty", "nameError");
|
||||
}
|
||||
};
|
||||
|
||||
$("#policy-name-input").focus(function(){
|
||||
clearInline["policy-name"]();
|
||||
}).blur(function(){
|
||||
validateInline["policy-name"]();
|
||||
});
|
||||
|
||||
stepForwardFrom["policy-platform"] = function (actionButton) {
|
||||
policy["platform"] = $(actionButton).data("platform");
|
||||
policy["platformId"] = $(actionButton).data("platform-type");
|
||||
// updating next-page wizard title with selected platform
|
||||
$("#policy-profile-page-wizard-title").text("ADD " + policy["platform"] + " POLICY");
|
||||
|
||||
var deviceType = policy["platform"];
|
||||
var policyOperationsTemplateSrc = context + '/public/cdmf.unit.device.type.' + deviceType +
|
||||
'.policy-wizard/templates/' + deviceType + '-policy-operations.hbs';
|
||||
var policyOperationsScriptSrc = context + '/public/cdmf.unit.device.type.' + deviceType +
|
||||
'.policy-wizard/js/' + deviceType + '-policy-operations.js';
|
||||
var policyOperationsStylesSrc = context + '/public/cdmf.unit.device.type.' + deviceType +
|
||||
'.policy-wizard/css/' + deviceType + '-policy-operations.css';
|
||||
var policyOperationsTemplateCacheKey = deviceType + '-policy-operations';
|
||||
|
||||
$.isResourceExists(policyOperationsTemplateSrc, function (status) {
|
||||
if (status) {
|
||||
$.template(policyOperationsTemplateCacheKey, policyOperationsTemplateSrc, function (template) {
|
||||
var content = template();
|
||||
$(".wr-advance-operations").html(content);
|
||||
$(".policy-platform").addClass("hidden");
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
$.isResourceExists(policyOperationsScriptSrc, function (status) {
|
||||
if (status) {
|
||||
var script = document.createElement('script');
|
||||
script.type = 'text/javascript';
|
||||
script.src = policyOperationsScriptSrc;
|
||||
$(".wr-advance-operations").prepend(script);
|
||||
}
|
||||
});
|
||||
|
||||
$.isResourceExists(policyOperationsStylesSrc, function (status) {
|
||||
if (status) {
|
||||
var style = document.createElement('link');
|
||||
style.type = 'text/css';
|
||||
style.rel = 'stylesheet';
|
||||
style.href = policyOperationsStylesSrc;
|
||||
$(".wr-advance-operations").prepend(style);
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
stepForwardFrom["policy-profile"] = function () {
|
||||
policy["profile"] = operationModule.generateProfile(policy["platform"], configuredOperations);
|
||||
// updating next-page wizard title with selected platform
|
||||
$("#policy-criteria-page-wizard-title").text("ADD " + policy["platform"] + " POLICY");
|
||||
};
|
||||
|
||||
stepBackFrom["policy-profile"] = function () {
|
||||
// reinitialize configuredOperations
|
||||
configuredOperations = [];
|
||||
// clearing already-loaded platform specific hidden-operations html content from the relevant div
|
||||
// so that, the wrong content would not be shown at the first glance, in case
|
||||
// the user selects a different platform
|
||||
$(".wr-advance-operations").html(
|
||||
"<div class='wr-advance-operations-init'>" +
|
||||
"<br>" +
|
||||
"<i class='fw fw-settings fw-spin fw-2x'></i>" +
|
||||
"Loading Platform Features . . ." +
|
||||
"<br>" +
|
||||
"<br>" +
|
||||
"</div>"
|
||||
);
|
||||
};
|
||||
|
||||
stepForwardFrom["policy-criteria"] = function () {
|
||||
$("input[type='radio'].select-users-radio").each(function () {
|
||||
if ($(this).is(':radio')) {
|
||||
if ($(this).is(":checked")) {
|
||||
if ($(this).attr("id") == "users-radio-btn") {
|
||||
policy["selectedUsers"] = $("#users-input").val();
|
||||
policy["selectedUserRoles"] = null;
|
||||
} else if ($(this).attr("id") == "user-roles-radio-btn") {
|
||||
policy["selectedUsers"] = null;
|
||||
policy["selectedUserRoles"] = $("#user-roles-input").val();
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
policy["selectedNonCompliantAction"] = $("#action-input").find(":selected").data("action");
|
||||
policy["selectedOwnership"] = $("#ownership-input").val();
|
||||
//updating next-page wizard title with selected platform
|
||||
$("#policy-naming-page-wizard-title").text("ADD " + policy["platform"] + " POLICY");
|
||||
};
|
||||
|
||||
/**
|
||||
* Checks if provided input is valid against provided length range.
|
||||
*
|
||||
* @param input Alphanumeric or non-alphanumeric input
|
||||
* @param minLength Minimum Required Length
|
||||
* @param maxLength Maximum Required Length
|
||||
* @returns {boolean} Returns true if input matches the provided minimum length and maximum length
|
||||
*/
|
||||
var inputIsValidAgainstLength = function (input, minLength, maxLength) {
|
||||
var length = input.length;
|
||||
return (length == minLength || (length > minLength && length < maxLength) || length == maxLength);
|
||||
};
|
||||
|
||||
validateStep["policy-criteria"] = function () {
|
||||
var validationStatus = {};
|
||||
var selectedAssignees;
|
||||
var selectedField = "Role(s)";
|
||||
|
||||
$("input[type='radio'].select-users-radio").each(function () {
|
||||
if ($(this).is(":checked")) {
|
||||
if ($(this).attr("id") == "users-radio-btn") {
|
||||
selectedAssignees = $("#users-input").val();
|
||||
selectedField = "User(s)";
|
||||
} else if ($(this).attr("id") == "user-roles-radio-btn") {
|
||||
selectedAssignees = $("#user-roles-input").val();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
if (selectedAssignees) {
|
||||
validationStatus["error"] = false;
|
||||
} else {
|
||||
validationStatus["error"] = true;
|
||||
validationStatus["mainErrorMsg"] = selectedField + " is a required field. It cannot be empty";
|
||||
}
|
||||
|
||||
var wizardIsToBeContinued;
|
||||
if (validationStatus["error"]) {
|
||||
wizardIsToBeContinued = false;
|
||||
var mainErrorMsgWrapper = "#policy-criteria-main-error-msg";
|
||||
var mainErrorMsg = mainErrorMsgWrapper + " span";
|
||||
$(mainErrorMsg).text(validationStatus["mainErrorMsg"]);
|
||||
$(mainErrorMsgWrapper).removeClass("hidden");
|
||||
} else {
|
||||
wizardIsToBeContinued = true;
|
||||
}
|
||||
|
||||
return wizardIsToBeContinued;
|
||||
};
|
||||
|
||||
validateStep["policy-naming"] = function () {
|
||||
var validationStatus = {};
|
||||
|
||||
// taking values of inputs to be validated
|
||||
var policyName = $("input#policy-name-input").val();
|
||||
// starting validation process and updating validationStatus
|
||||
if (!policyName) {
|
||||
validationStatus["error"] = true;
|
||||
validationStatus["mainErrorMsg"] = "Policy name is empty. You cannot proceed.";
|
||||
} else if (!inputIsValidAgainstLength(policyName, 1, 30)) {
|
||||
validationStatus["error"] = true;
|
||||
validationStatus["mainErrorMsg"] =
|
||||
"Policy name exceeds maximum allowed length.";
|
||||
} else {
|
||||
validationStatus["error"] = false;
|
||||
}
|
||||
// ending validation process
|
||||
|
||||
// start taking specific actions upon validation
|
||||
var wizardIsToBeContinued;
|
||||
if (validationStatus["error"]) {
|
||||
wizardIsToBeContinued = false;
|
||||
var mainErrorMsgWrapper = "#policy-naming-main-error-msg";
|
||||
var mainErrorMsg = mainErrorMsgWrapper + " span";
|
||||
$(mainErrorMsg).text(validationStatus["mainErrorMsg"]);
|
||||
$(mainErrorMsgWrapper).removeClass("hidden");
|
||||
} else {
|
||||
wizardIsToBeContinued = true;
|
||||
}
|
||||
|
||||
return wizardIsToBeContinued;
|
||||
};
|
||||
|
||||
validateStep["policy-platform"] = function () {
|
||||
return false;
|
||||
};
|
||||
|
||||
validateStep["policy-naming-publish"] = function () {
|
||||
var validationStatus = {};
|
||||
|
||||
// taking values of inputs to be validated
|
||||
var policyName = $("input#policy-name-input").val();
|
||||
// starting validation process and updating validationStatus
|
||||
if (!policyName) {
|
||||
validationStatus["error"] = true;
|
||||
validationStatus["mainErrorMsg"] = "Policy name is empty. You cannot proceed.";
|
||||
} else if (!inputIsValidAgainstLength(policyName, 1, 30)) {
|
||||
validationStatus["error"] = true;
|
||||
validationStatus["mainErrorMsg"] =
|
||||
"Policy name exceeds maximum allowed length.";
|
||||
} else {
|
||||
validationStatus["error"] = false;
|
||||
}
|
||||
// ending validation process
|
||||
|
||||
// start taking specific actions upon validation
|
||||
var wizardIsToBeContinued;
|
||||
if (validationStatus["error"]) {
|
||||
wizardIsToBeContinued = false;
|
||||
var mainErrorMsgWrapper = "#policy-naming-main-error-msg";
|
||||
var mainErrorMsg = mainErrorMsgWrapper + " span";
|
||||
$(mainErrorMsg).text(validationStatus["mainErrorMsg"]);
|
||||
$(mainErrorMsgWrapper).removeClass("hidden");
|
||||
} else {
|
||||
wizardIsToBeContinued = true;
|
||||
}
|
||||
|
||||
return wizardIsToBeContinued;
|
||||
};
|
||||
|
||||
stepForwardFrom["policy-naming-publish"] = function () {
|
||||
policy["policyName"] = $("#policy-name-input").val();
|
||||
policy["description"] = $("#policy-description-input").val();
|
||||
//All data is collected. Policy can now be updated.
|
||||
savePolicy(policy, true, "/api/device-mgt/v1.0/policies/");
|
||||
};
|
||||
|
||||
stepForwardFrom["policy-naming"] = function () {
|
||||
policy["policyName"] = $("#policy-name-input").val();
|
||||
policy["description"] = $("#policy-description-input").val();
|
||||
//All data is collected. Policy can now be updated.
|
||||
savePolicy(policy, false, "/api/device-mgt/v1.0/policies/");
|
||||
};
|
||||
|
||||
var savePolicy = function (policy, isActive, serviceURL) {
|
||||
var profilePayloads = [];
|
||||
// traverses key by key in policy["profile"]
|
||||
var key;
|
||||
for (key in policy["profile"]) {
|
||||
if (policy["profile"].hasOwnProperty(key)) {
|
||||
profilePayloads.push({
|
||||
"featureCode": key,
|
||||
"deviceType": policy["platform"],
|
||||
"content": policy["profile"][key]
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
$.each(profilePayloads, function (i, item) {
|
||||
$.each(item.content, function (key, value) {
|
||||
//cannot add a true check since it will catch value = false as well
|
||||
if (value === null || value === undefined || value === "") {
|
||||
item.content[key] = null;
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
var payload = {
|
||||
"policyName": policy["policyName"],
|
||||
"description": policy["description"],
|
||||
"compliance": policy["selectedNonCompliantAction"],
|
||||
"ownershipType": policy["selectedOwnership"],
|
||||
"active": isActive,
|
||||
"profile": {
|
||||
"profileName": policy["policyName"],
|
||||
"deviceType": policy["platform"],
|
||||
"profileFeaturesList": profilePayloads
|
||||
}
|
||||
};
|
||||
|
||||
if (policy["selectedUsers"]) {
|
||||
payload["users"] = policy["selectedUsers"];
|
||||
} else if (policy["selectedUserRoles"]) {
|
||||
payload["roles"] = policy["selectedUserRoles"];
|
||||
} else {
|
||||
payload["users"] = [];
|
||||
payload["roles"] = [];
|
||||
}
|
||||
|
||||
invokerUtil.post(
|
||||
serviceURL,
|
||||
payload,
|
||||
function () {
|
||||
$(".add-policy").addClass("hidden");
|
||||
$(".policy-naming").addClass("hidden");
|
||||
$(".policy-message").removeClass("hidden");
|
||||
},
|
||||
function (data) {
|
||||
}
|
||||
);
|
||||
};
|
||||
|
||||
function formatRepo(user) {
|
||||
if (user.loading) {
|
||||
return user.text;
|
||||
}
|
||||
if (!user.username) {
|
||||
return;
|
||||
}
|
||||
var markup = '<div class="clearfix">' +
|
||||
'<div clas="col-sm-8">' +
|
||||
'<div class="clearfix">' +
|
||||
'<div class="col-sm-3">' + user.username + '</div>';
|
||||
if (user.firstname) {
|
||||
markup += '<div class="col-sm-3"><i class="fa fa-code-fork"></i> ' + user.firstname + '</div>';
|
||||
}
|
||||
if (user.emailAddress) {
|
||||
markup += '<div class="col-sm-2"><i class="fa fa-star"></i> ' + user.emailAddress + '</div></div>';
|
||||
}
|
||||
markup += '</div></div>';
|
||||
return markup;
|
||||
}
|
||||
|
||||
function formatRepoSelection(user) {
|
||||
return user.username || user.text;
|
||||
}
|
||||
|
||||
// End of functions related to grid-input-view
|
||||
|
||||
|
||||
$(document).ready(function () {
|
||||
$("#users-input").select2({
|
||||
multiple: true,
|
||||
tags: false,
|
||||
ajax: {
|
||||
url: context + "/api/invoker/execute/",
|
||||
method: "POST",
|
||||
dataType: 'json',
|
||||
delay: 250,
|
||||
id: function (user) {
|
||||
return user.username;
|
||||
},
|
||||
data: function (params) {
|
||||
var postData = {};
|
||||
postData.requestMethod = "GET";
|
||||
postData.requestURL = "/api/device-mgt/v1.0/users/search/usernames?filter=" + params.term;
|
||||
postData.requestPayload = null;
|
||||
return JSON.stringify(postData);
|
||||
},
|
||||
processResults: function (data) {
|
||||
var newData = [];
|
||||
$.each(data, function (index, value) {
|
||||
value.id = value.username;
|
||||
newData.push(value);
|
||||
});
|
||||
return {
|
||||
results: newData
|
||||
};
|
||||
},
|
||||
cache: true
|
||||
},
|
||||
escapeMarkup: function (markup) {
|
||||
return markup;
|
||||
}, // let our custom formatter work
|
||||
minimumInputLength: 1,
|
||||
templateResult: formatRepo, // omitted for brevity, see the source of this page
|
||||
templateSelection: formatRepoSelection // omitted for brevity, see the source of this page
|
||||
});
|
||||
|
||||
$("#loading-content").remove();
|
||||
$(".policy-platform").removeClass("hidden");
|
||||
// Adding initial state of wizard-steps.
|
||||
$("#policy-platform-wizard-steps").html($(".wr-steps").html());
|
||||
|
||||
$("select.select2[multiple=multiple]").select2({
|
||||
"tags": false
|
||||
});
|
||||
|
||||
$("#users-select-field").hide();
|
||||
$("#user-roles-select-field").show();
|
||||
|
||||
$("input[type='radio'].select-users-radio").change(function () {
|
||||
if ($("#users-radio-btn").is(":checked")) {
|
||||
$("#user-roles-select-field").hide();
|
||||
$("#users-select-field").show();
|
||||
}
|
||||
if ($("#user-roles-radio-btn").is(":checked")) {
|
||||
$("#users-select-field").hide();
|
||||
$("#user-roles-select-field").show();
|
||||
}
|
||||
});
|
||||
|
||||
// Support for special input type "ANY" on user(s) & user-role(s) selection
|
||||
$("#user-roles-input").select2({
|
||||
"tags": false
|
||||
}).on("select2:select", function (e) {
|
||||
if (e.params.data.id == "ANY") {
|
||||
$(this).val("ANY").trigger("change");
|
||||
} else {
|
||||
$("option[value=ANY]", this).prop("selected", false).parent().trigger("change");
|
||||
}
|
||||
});
|
||||
|
||||
//Policy wizard stepper
|
||||
$(".wizard-stepper").click(function () {
|
||||
// button clicked here can be either a continue button or a back button.
|
||||
var currentStep = $(this).data("current");
|
||||
var validationIsRequired = $(this).data("validate");
|
||||
var wizardIsToBeContinued;
|
||||
|
||||
if (validationIsRequired) {
|
||||
wizardIsToBeContinued = validateStep[currentStep]();
|
||||
} else {
|
||||
wizardIsToBeContinued = true;
|
||||
}
|
||||
|
||||
if (wizardIsToBeContinued) {
|
||||
// When moving back and forth, following code segment will
|
||||
// remove if there are any visible error-messages.
|
||||
var errorMsgWrappers = ".alert.alert-danger";
|
||||
$(errorMsgWrappers).each(
|
||||
function () {
|
||||
if (!$(this).hasClass("hidden")) {
|
||||
$(this).addClass("hidden");
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
var nextStep = $(this).data("next");
|
||||
var isBackBtn = $(this).data("is-back-btn");
|
||||
|
||||
// if current button is a continuation...
|
||||
if (!isBackBtn) {
|
||||
// initiate stepForwardFrom[*] functions to gather form data.
|
||||
if (stepForwardFrom[currentStep]) {
|
||||
stepForwardFrom[currentStep](this);
|
||||
}
|
||||
} else {
|
||||
// initiate stepBackFrom[*] functions to rollback.
|
||||
if (stepBackFrom[currentStep]) {
|
||||
stepBackFrom[currentStep]();
|
||||
}
|
||||
}
|
||||
|
||||
// following step occurs only at the last stage of the wizard.
|
||||
if (!nextStep) {
|
||||
window.location.href = $(this).data("direct");
|
||||
}
|
||||
|
||||
// updating next wizard step as current.
|
||||
$(".itm-wiz").each(function () {
|
||||
var step = $(this).data("step");
|
||||
if (step == nextStep) {
|
||||
$(this).addClass("itm-wiz-current");
|
||||
} else {
|
||||
$(this).removeClass("itm-wiz-current");
|
||||
}
|
||||
});
|
||||
|
||||
// adding next update of wizard-steps.
|
||||
$("#" + nextStep + "-wizard-steps").html($(".wr-steps").html());
|
||||
|
||||
// hiding current section of the wizard and showing next section.
|
||||
$("." + currentStep).addClass("hidden");
|
||||
$("." + nextStep).removeClass("hidden");
|
||||
}
|
||||
});
|
||||
});
|
@ -1,244 +0,0 @@
|
||||
<span id="platform" class="hidden" data-platform="{{type.name}}" data-platform-label="{{type.label}}"
|
||||
data-username="{{username}}"></span>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="container col-centered wr-content policy-message hidden">
|
||||
<div class="wr-form">
|
||||
<h1 id="policy-message-page-wizard-title" class="page-sub-title">Policy creation is
|
||||
successful.</h1>
|
||||
<br>Please click <b>"Add Another Policy"</b>, if you wish to add another policy or
|
||||
click
|
||||
<b>"View policy list"</b> to complete the process and go back to the policy list.
|
||||
<hr>
|
||||
<button class="wr-btn wizard-stepper" data-current="policy-message"
|
||||
data-direct="{{@app.context}}/policies">
|
||||
View policy list
|
||||
</button>
|
||||
<a href="{{@app.context}}/policy/add" class="cu-btn-inner">
|
||||
<span class="fw-stack">
|
||||
<i class="fw fw-ring fw-stack-2x"></i>
|
||||
<i class="fw fw-add fw-stack-1x"></i>
|
||||
</span>
|
||||
Add another policy
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container col-centered wr-content policy-naming hidden">
|
||||
<div class="wr-form">
|
||||
<h1 id="policy-naming-page-wizard-title" class="page-sub-title">ADD POLICY</h1>
|
||||
<hr>
|
||||
<div id="policy-naming-wizard-steps" class="row wr-wizard"></div>
|
||||
<hr>
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<h4>Step 4: Publish to devices</h4>
|
||||
<br>
|
||||
|
||||
<div id="policy-naming-main-error-msg" class="alert alert-danger hidden"
|
||||
role="alert">
|
||||
<i class="icon fw fw-error"></i><span></span>
|
||||
</div>
|
||||
<div>
|
||||
<label class="wr-input-label">
|
||||
Set a Name to your Policy *<br>
|
||||
( should be 1-to-30 characters long )
|
||||
</label>
|
||||
|
||||
<div class="wr-input-control">
|
||||
<div class="cus-col-50">
|
||||
<input id="policy-name-input" class="form-control" type="text"
|
||||
value="" placeholder="[ Required field ]"/>
|
||||
</div>
|
||||
<br class="c-both"/>
|
||||
</div>
|
||||
<label class="wr-input-label">
|
||||
Add a description
|
||||
</label>
|
||||
|
||||
<div class="wr-input-control">
|
||||
<div class="cus-col-50">
|
||||
<textarea id="policy-description-input" class="form-control"
|
||||
rows="10" placeholder="[ Optional field ]"></textarea>
|
||||
</div>
|
||||
<br class="c-both"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-12">
|
||||
<div class="wr-input-control wr-btn-grp">
|
||||
<a href="javascript:void(0)" class="wr-btn wizard-stepper"
|
||||
data-is-back-btn="true" data-current="policy-naming"
|
||||
data-next="policy-criteria">
|
||||
Back
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="wr-btn wizard-stepper"
|
||||
data-current="policy-naming-publish" data-next="policy-message"
|
||||
data-validate="true">
|
||||
Save & Publish
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="wr-btn wizard-stepper"
|
||||
data-current="policy-naming" data-next="policy-message"
|
||||
data-validate="true">
|
||||
Save
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container col-centered wr-content policy-criteria hidden">
|
||||
<div class="wr-form">
|
||||
<h1 id="policy-criteria-page-wizard-title" class="page-sub-title">ADD POLICY</h1>
|
||||
<hr>
|
||||
<div id="policy-criteria-wizard-steps" class="row wr-wizard"></div>
|
||||
<hr>
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<h4>Step 3: Assign</h4>
|
||||
<br>
|
||||
|
||||
<div>
|
||||
<div class="wr-input-control">
|
||||
{{#if permissions.LIST_ROLES}}
|
||||
<label class="wr-input-control radio light">
|
||||
<input id="user-roles-radio-btn" type="radio"
|
||||
name="select-users-radio-btn" class="select-users-radio"
|
||||
checked/>
|
||||
<span class="helper"> Set user role(s)</span>
|
||||
</label>
|
||||
{{/if}}
|
||||
{{#if permissions.LIST_USERS}}
|
||||
<label class="wr-input-control radio light" rel="assetfilter">
|
||||
<input id="users-radio-btn" type="radio"
|
||||
name="select-users-radio-btn"
|
||||
class="select-users-radio"/>
|
||||
<span class="helper"> Set user(s)</span>
|
||||
</label>
|
||||
{{/if}}
|
||||
<!--
|
||||
{{#if permissions.LIST_GROUPS}}
|
||||
<label class="wr-input-control radio light" rel="assetfilter">
|
||||
<input id="groups-radio-btn" type="radio"
|
||||
name="select-users-radio-btn"
|
||||
class="select-users-radio"/>
|
||||
<span class="helper"> Set groups(s)</span>
|
||||
</label>
|
||||
{{/if}}
|
||||
-->
|
||||
</div>
|
||||
{{#if permissions.LIST_ROLES}}
|
||||
<div id="user-roles-select-field" class="select-users">
|
||||
<div class="wr-input-control">
|
||||
<div class="cus-col-50">
|
||||
<select id="user-roles-input" class="form-control select2"
|
||||
multiple="multiple">
|
||||
<option value="ANY" selected>ANY</option>
|
||||
{{#each roles}}
|
||||
<option>{{this}}</option>
|
||||
{{/each}}
|
||||
</select>
|
||||
</div>
|
||||
<br class="c-both"/>
|
||||
</div>
|
||||
</div>
|
||||
{{/if}}
|
||||
{{#if permissions.LIST_USERS}}
|
||||
<div id="users-select-field" class="select-users">
|
||||
<div class="wr-input-control">
|
||||
<div class="cus-col-50">
|
||||
<select id="users-input" class="form-control select2"
|
||||
multiple="multiple">
|
||||
</select>
|
||||
</div>
|
||||
<br class="c-both"/>
|
||||
</div>
|
||||
</div>
|
||||
{{/if}}
|
||||
<!--
|
||||
{{#if permissions.LIST_GROUPS}}
|
||||
<div id="groups-select-field" class="select-users">
|
||||
<div class="wr-input-control">
|
||||
<div class="cus-col-50">
|
||||
<select id="groups-input" class="form-control select2"
|
||||
multiple="multiple">
|
||||
</select>
|
||||
</div>
|
||||
<br class="c-both"/>
|
||||
</div>
|
||||
</div>
|
||||
{{/if}}
|
||||
-->
|
||||
<br>
|
||||
<label class="wr-input-label" title="">
|
||||
Set an action upon non-compliance
|
||||
</label>
|
||||
|
||||
<div class="wr-input-control">
|
||||
<div class="cus-col-50">
|
||||
<select id="action-input" class="form-control">
|
||||
<option data-action="enforce" selected>Enforce</option>
|
||||
<option data-action="warn">Warn</option>
|
||||
<option data-action="monitor">Monitor</option>
|
||||
</select>
|
||||
</div>
|
||||
<br class="c-both"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="wr-input-control wr-btn-grp">
|
||||
<a href="javascript:void(0)" class="wr-btn wizard-stepper"
|
||||
data-is-back-btn="true" data-current="policy-criteria"
|
||||
data-next="policy-profile">
|
||||
Back
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="wr-btn wizard-stepper"
|
||||
data-current="policy-criteria" data-next="policy-naming"
|
||||
data-validate="false">
|
||||
Continue
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container col-centered wr-content policy-profile">
|
||||
<div class="wr-form">
|
||||
<h1 id="policy-profile-page-wizard-title" class="page-sub-title">ADD POLICY</h1>
|
||||
<hr>
|
||||
<div id="policy-profile-wizard-steps" class="row wr-wizard"></div>
|
||||
<hr>
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<h4>Step 2: Configure profile</h4>
|
||||
<br>
|
||||
<label class="wr-input-label">
|
||||
Set device specific configuration instructions
|
||||
</label>
|
||||
<div class="wr-advance-operations">
|
||||
{{unit "cdmf.unit.device.type.generic.policy-wizard"}}
|
||||
</div>
|
||||
<div class="wr-input-control wr-btn-grp">
|
||||
<a href="javascript:window.history.back()"
|
||||
class="wr-btn wizard-stepper" data-is-back-btn="true"
|
||||
data-current="policy-profile" data-next="policy-platform">
|
||||
Back
|
||||
</a>
|
||||
<a href="javascript:void(0)" class="wr-btn wizard-stepper"
|
||||
data-current="policy-profile" data-next="policy-criteria"
|
||||
data-validate="true">
|
||||
Continue
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- content -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
{{#zone "bottomJs"}}
|
||||
{{js "js/policy-create.js"}}
|
||||
{{/zone}}
|
@ -1,47 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2016, 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.
|
||||
*/
|
||||
|
||||
function onRequest(context) {
|
||||
// var log = new Log("wizard.js");
|
||||
var constants = require("/app/modules/constants.js");
|
||||
var DTYPE_CONF_DEVICE_TYPE_KEY = "deviceType";
|
||||
var DTYPE_CONF_DEVICE_TYPE_LABEL_KEY = "label";
|
||||
|
||||
var userModule = require("/app/modules/business-controllers/user.js")["userModule"];
|
||||
var utility = require('/app/modules/utility.js').utility;
|
||||
var response = userModule.getRoles();
|
||||
var wizardPage = {};
|
||||
if (response["status"] == "success") {
|
||||
wizardPage["roles"] = response["content"];
|
||||
}
|
||||
var deviceType = context.uriParams.deviceType;
|
||||
var typesListResponse = userModule.getPlatforms();
|
||||
if (typesListResponse["status"] == "success") {
|
||||
wizardPage["type"] = {};
|
||||
for (var type in typesListResponse["content"]["deviceTypes"]) {
|
||||
if (deviceType == typesListResponse["content"]["deviceTypes"][type]) {
|
||||
wizardPage["type"]["name"] = deviceType;
|
||||
wizardPage["type"]["label"] = deviceType;
|
||||
}
|
||||
}
|
||||
}
|
||||
var user = session.get(constants.USER_SESSION_KEY);
|
||||
wizardPage.username = user.username;
|
||||
wizardPage.permissions = userModule.getUIPermissions();
|
||||
return wizardPage;
|
||||
}
|
@ -1,3 +0,0 @@
|
||||
{
|
||||
"version" : "1.0.0"
|
||||
}
|
@ -0,0 +1,33 @@
|
||||
<!--
|
||||
~ Copyright 2016 WSO2, Inc. (http://wso2.com)
|
||||
~
|
||||
~ Licensed 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.
|
||||
-->
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Bad request - Error 400</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="description" content="">
|
||||
<meta name="author" content="">
|
||||
</head>
|
||||
<body>
|
||||
<i class="icon-unlink error-icon"></i>
|
||||
<h1>Error 400</h1>
|
||||
<h3>We are unable to understand the request and process it. Please re-check your request.</h3>
|
||||
<h4 id="link"><a href="/devicemgt">Go to IoT Home</a></h4>
|
||||
</body>
|
||||
</html>
|
||||
|
@ -0,0 +1,33 @@
|
||||
<!--
|
||||
~ Copyright 2016 WSO2, Inc. (http://wso2.com)
|
||||
~
|
||||
~ Licensed 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.
|
||||
-->
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Unauthorized - Error 401</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="description" content="">
|
||||
<meta name="author" content="">
|
||||
</head>
|
||||
<body>
|
||||
<i class="icon-unlink error-icon"></i>
|
||||
<h1>Error 401</h1>
|
||||
<h3>You do not have permission to access this page.Please contact your administrator and request permission.</h3>
|
||||
<h4 id="link"><a href="/devicemgt">Go to IoT Home</a></h4>
|
||||
</body>
|
||||
</html>
|
||||
|
@ -0,0 +1,34 @@
|
||||
<!--
|
||||
~ Copyright 2016 WSO2, Inc. (http://wso2.com)
|
||||
~
|
||||
~ Licensed 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.
|
||||
-->
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Forbidden - Error 403</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="description" content="">
|
||||
<meta name="author" content="">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<i class="icon-unlink error-icon"></i>
|
||||
<h1>Error 403</h1>
|
||||
<h3>We cannot process this request.</h3>
|
||||
<h4 id="link"><a href="/devicemgt">Go to IoT Home</a></h4>
|
||||
</body>
|
||||
</html>
|
||||
|
@ -0,0 +1,33 @@
|
||||
<!--
|
||||
~ Copyright 2016 WSO2, Inc. (http://wso2.com)
|
||||
~
|
||||
~ Licensed 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.
|
||||
-->
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Page not found - Error 404</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="description" content="">
|
||||
<meta name="author" content="">
|
||||
</head>
|
||||
<body>
|
||||
<i class="icon-unlink error-icon"></i>
|
||||
<h1>Error 404</h1>
|
||||
<h3>We can't find what you are looking for.</h3>
|
||||
<h4 id="link"><a href="/devicemgt">Go to IoT Home</a></h4>
|
||||
</body>
|
||||
</html>
|
||||
|
@ -0,0 +1,33 @@
|
||||
<!--
|
||||
~ Copyright 2016 WSO2, Inc. (http://wso2.com)
|
||||
~
|
||||
~ Licensed 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.
|
||||
-->
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Method not allowed - Error 405</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="description" content="">
|
||||
<meta name="author" content="">
|
||||
</head>
|
||||
<body>
|
||||
<i class="icon-unlink error-icon"></i>
|
||||
<h1>Error 405</h1>
|
||||
<h3>Method not allowed.</h3>
|
||||
<h4 id="link"><a href="/devicemgt">Go to IoT Home</a></h4>
|
||||
</body>
|
||||
</html>
|
||||
|
@ -0,0 +1,32 @@
|
||||
<!--
|
||||
~ Copyright 2016 WSO2, Inc. (http://wso2.com)
|
||||
~
|
||||
~ Licensed 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.
|
||||
-->
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Internal Server Error - Error 500</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="description" content="">
|
||||
<meta name="author" content="">
|
||||
<body>
|
||||
<i class="icon-ambulance error-icon"></i>
|
||||
<h1>Error 500</h1>
|
||||
<h3>Something went wrong and we're trying to fix it.</h3>
|
||||
<h4 id="link"><a href="/devicemgt">Go to IoT Home</a></h4>
|
||||
</body>
|
||||
</html>
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue