mirror of https://github.com/rancher/ui.git
Remove pre populated namespace
This commit is contained in:
parent
6948525c19
commit
fcf07da943
|
|
@ -175,7 +175,12 @@ export default Route.extend({
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!ns) {
|
if (!ns) {
|
||||||
ns = clusterStore.getById('namespace', get(this, `prefs.${C.PREFS.LAST_NAMESPACE}`));
|
const project = window.l('route:application').modelFor('authenticated.project').get('project');
|
||||||
|
const projectId = project.get('id');
|
||||||
|
const lastNamespace = clusterStore.getById('namespace', get(this, `prefs.${C.PREFS.LAST_NAMESPACE}`));
|
||||||
|
if ( lastNamespace && get(lastNamespace, 'projectId') === projectId ) {
|
||||||
|
ns = lastNamespace;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let namespaceId = null;
|
let namespaceId = null;
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,6 @@ export default Component.extend({
|
||||||
} else {
|
} else {
|
||||||
next(() => {
|
next(() => {
|
||||||
set(this, 'mode', CREATE);
|
set(this, 'mode', CREATE);
|
||||||
set(this, 'createNamespace.name', 'default')
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue