CreateImageWizard: move org id to custom component
Loading the organization ID is now done in the registration step. This prevents the entire wizard from waiting on the org id and prevents the wizard from remounting when the async getUser() completes.
This commit is contained in:
parent
e368b5051e
commit
919919173d
5 changed files with 64 additions and 43 deletions
|
|
@ -12,7 +12,7 @@ export const registerValues = {
|
|||
}
|
||||
};
|
||||
|
||||
export default (user) => ({
|
||||
export default {
|
||||
title: 'Registration',
|
||||
name: 'registration',
|
||||
nextStep: 'packages',
|
||||
|
|
@ -34,13 +34,9 @@ export default (user) => ({
|
|||
}))
|
||||
},
|
||||
{
|
||||
component: componentTypes.TEXT_FIELD,
|
||||
component: 'organization-id',
|
||||
name: 'subscription-organization',
|
||||
type: 'text',
|
||||
'data-testid': 'organization-id',
|
||||
label: 'Organization ID',
|
||||
initialValue: Number(user?.identity?.internal?.org_id),
|
||||
isDisabled: true,
|
||||
condition: {
|
||||
or: [
|
||||
{ when: 'register-system', is: 'subscribe-now-radio' },
|
||||
|
|
@ -67,4 +63,4 @@ export default (user) => ({
|
|||
],
|
||||
}
|
||||
]
|
||||
});
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue