Fix meta of a new bond
Closes-bug: #1653058 Change-Id: Ic8bcb7c6c2e0b197895bce879472b7b58cf50900
This commit is contained in:
parent
e568a1cb1b
commit
35395ffded
|
@ -364,7 +364,6 @@ var EditNodeInterfacesScreen = React.createClass({
|
|||
});
|
||||
this.updateWithLimitations(updatedIfc, ifc);
|
||||
});
|
||||
|
||||
return Backbone.sync('update', node.interfaces, {url: _.result(node, 'url') + '/interfaces'});
|
||||
}))
|
||||
.then(
|
||||
|
@ -453,6 +452,14 @@ var EditNodeInterfacesScreen = React.createClass({
|
|||
)
|
||||
});
|
||||
|
||||
var bondMeta = {
|
||||
dpdk: {
|
||||
available: _.every(interfaces,
|
||||
(ifc) => ((ifc.get('meta') || {}).dpdk || {}).available !== false
|
||||
)
|
||||
}
|
||||
};
|
||||
|
||||
// populate bond attributes with first slave values
|
||||
var firstSlaveAttributes = interfaces[0].get('attributes');
|
||||
_.each(bondAttributes.attributes, (section, sectionName) => {
|
||||
|
@ -474,7 +481,8 @@ var EditNodeInterfacesScreen = React.createClass({
|
|||
assigned_networks: new models.InterfaceNetworks(),
|
||||
slaves: _.invokeMap(interfaces, 'pick', 'name'),
|
||||
state: 'down',
|
||||
attributes: bondAttributes
|
||||
attributes: bondAttributes,
|
||||
meta: bondMeta
|
||||
});
|
||||
this.updateBondOffloading(bond, interfaces);
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue