Merge pull request #743 from rasika/filter-features

Adding filters for the android features
revert-dabc3590
Kamidu Sachith Punchihewa 7 years ago committed by GitHub
commit a601482e66

@ -36,7 +36,7 @@
}
</style>
{{#each controlOperations}}
<a {{#unless isDisabled}} href="javascript:operationSelect('{{operation}}')" {{else}} href="javascript:void(0)" class="op-disabled"{{/unless}}>
<a {{#unless isDisabled}} href="javascript:operationSelect('{{operation}}')" {{else}} href="javascript:void(0)" class="op-disabled" title="{{disabledText}}" data-toggle="tooltip" {{/unless}}>
{{#if iconFont}}
<i class="fw {{iconFont}}"></i>
{{else}}

@ -24,7 +24,7 @@ function onRequest(context) {
var device = context.unit.params.device;
var autoCompleteParams = context.unit.params.autoCompleteParams;
var encodedFeaturePayloads = context.unit.params.encodedFeaturePayloads;
var allControlOps = operationModule.getControlOperations(device.type);
var allControlOps = operationModule.getControlOperations(device);
var filteredControlOps = [];
var queryParams = [];
var formParams = [];

@ -68,12 +68,12 @@
},
"DEVICE_REBOOT": {
"icon": "fw-refresh",
"isDisabled" : true,
"filter" : {"property" : "ownership", "value" : "COPE", "text": "This feature is only available in COPE/COSU"},
"permission": "/device-mgt/devices/owning-device/operations/android/reboot"
},
"UPGRADE_FIRMWARE": {
"icon": "fw-hardware",
"isDisabled" : true,
"filter" : {"property" : "ownership", "value" : "COPE", "text": "This feature is only available in COPE/COSU"},
"formParams": [
{
"type": "checkbox",

@ -22,7 +22,7 @@ function onRequest(context) {
var device = context.unit.params.device;
var autoCompleteParams = context.unit.params.autoCompleteParams;
var encodedFeaturePayloads=context.unit.params.encodedFeaturePayloads;
var controlOperations = operationModule.getControlOperations(device.type);
var controlOperations = operationModule.getControlOperations(device);
var queryParams = [];
var formParams = [];
var pathParams = [];

Loading…
Cancel
Save