Feature #4620: Disable pci passthrough in nic-attach

This commit is contained in:
Carlos Martín committed 2016-07-18 16:22:08 +02:00
1 parent 3fd36b7160
commit f0a38bfcf5
2 files changed
+12 -2

No files matched your search

@@ -81,8 +81,18 @@ define(function(require) {
this.vnetsTable.refreshResourceTableSelect();
}
function _setup(context) {
/**
* @param {Object} context jquery selector
* @param {Object} options
* options.hide_pci {bool} true to disable the pci checkbox
*/
function _setup(context, options) {
var that = this;
if (options != undefined && options.hide_pci == true){
$("input.pci-type-nic", context).attr('disabled', 'disabled');
}
that.vnetsTable.initialize({
'selectOptions': {
'select_callback': function(aData, options) {
@@ -69,7 +69,7 @@ define(function(require) {
function _setup(context) {
var that = this;
that.nicTab.setup(context);
that.nicTab.setup(context, {hide_pci: true});
Tips.setup(context);