Merge "Fix the name of Bare Metal Nodes"
This commit is contained in:
commit
22df7b15e6
@ -150,7 +150,8 @@ export class Create extends StepAction {
|
||||
body[key] = newValue;
|
||||
}
|
||||
} else {
|
||||
body[key] = values[key];
|
||||
const isEmptyName = key === 'name' && values[key] === '';
|
||||
body[key] = isEmptyName ? null : values[key];
|
||||
}
|
||||
});
|
||||
body.driver_info = driverInfo;
|
||||
@ -186,10 +187,15 @@ export class Create extends StepAction {
|
||||
} else {
|
||||
const oldValue = originData[key];
|
||||
if (!isEqual(oldValue, value) && (oldValue || value)) {
|
||||
if (key === 'name' && value === '') {
|
||||
obj.op = 'remove';
|
||||
dels.push(obj);
|
||||
} else {
|
||||
obj.op = 'replace';
|
||||
replaces.push(obj);
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
const {
|
||||
adds: pAdds,
|
||||
|
Loading…
Reference in New Issue
Block a user