mirror of https://github.com/rancher/ui.git
Fix issue with saving catalog and vm options when not needed
This commit is contained in:
parent
7d87df2735
commit
6c0b9d5c6c
|
|
@ -35,21 +35,27 @@ export default Ember.Controller.extend({
|
|||
return;
|
||||
}
|
||||
|
||||
Object.keys(model).forEach((item) => {
|
||||
switch (item) {
|
||||
case 'host':
|
||||
propsOut[C.SETTING.API_HOST] = model[item];
|
||||
break;
|
||||
case 'catalog':
|
||||
propsOut[C.SETTING.CATALOG_URL] = model[item];
|
||||
break;
|
||||
case 'vm':
|
||||
propsOut[C.SETTING.VM_ENABLED] = model[item];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
});
|
||||
if (this.get('backToAdd')) {
|
||||
|
||||
propsOut[C.SETTING.API_HOST] = model.host;
|
||||
} else {
|
||||
|
||||
Object.keys(model).forEach((item) => {
|
||||
switch (item) {
|
||||
case 'host':
|
||||
propsOut[C.SETTING.API_HOST] = model[item];
|
||||
break;
|
||||
case 'catalog':
|
||||
propsOut[C.SETTING.CATALOG_URL] = model[item];
|
||||
break;
|
||||
case 'vm':
|
||||
propsOut[C.SETTING.VM_ENABLED] = model[item];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
this.set('saving', true);
|
||||
this.get('settings').setProperties(propsOut).one('settingsPromisesResolved', () => {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "ui",
|
||||
"version": "0.74.0",
|
||||
"version": "0.75.0",
|
||||
"private": true,
|
||||
"directories": {
|
||||
"doc": "doc",
|
||||
|
|
|
|||
Loading…
Reference in New Issue