fsc: load the oscap profile when available.
When the user has selected a profile to customize their distribution, the FSC step now shows immediately the manual configuration opened up with the partitions coming from the profile already filled in. If the user goes back to the Compliance step and changes anything, the FSC step is going to be reinitialized. HMS-2077
This commit is contained in:
parent
18cc74cf6b
commit
7c55190ac3
4 changed files with 112 additions and 19 deletions
|
|
@ -15,6 +15,11 @@ import StepTemplate from './stepTemplate';
|
|||
|
||||
import FileSystemConfigButtons from '../formComponents/FileSystemConfigButtons';
|
||||
|
||||
export const reinitFileSystemConfiguratioStep = (change) => {
|
||||
change('file-system-configuration', undefined);
|
||||
change('file-system-config-radio', 'automatic');
|
||||
};
|
||||
|
||||
const fileSystemConfigurationStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-systemconfiguration-filesystem',
|
||||
|
|
@ -63,6 +68,10 @@ const fileSystemConfigurationStep = {
|
|||
className: 'pf-u-mt-sm',
|
||||
},
|
||||
],
|
||||
condition: {
|
||||
when: 'oscap-policy',
|
||||
is: undefined,
|
||||
},
|
||||
},
|
||||
{
|
||||
component: 'file-system-configuration',
|
||||
|
|
@ -73,8 +82,13 @@ const fileSystemConfigurationStep = {
|
|||
{ type: validatorTypes.REQUIRED },
|
||||
],
|
||||
condition: {
|
||||
when: 'file-system-config-radio',
|
||||
is: 'manual',
|
||||
or: [
|
||||
{
|
||||
when: 'file-system-config-radio',
|
||||
is: 'manual',
|
||||
},
|
||||
{ not: [{ when: 'oscap-policy', is: undefined }] },
|
||||
],
|
||||
},
|
||||
},
|
||||
{
|
||||
|
|
@ -111,7 +125,10 @@ const fileSystemConfigurationStep = {
|
|||
</TextContent>
|
||||
),
|
||||
condition: {
|
||||
or: [{ when: 'file-system-config-radio', is: 'automatic' }],
|
||||
or: [
|
||||
{ when: 'file-system-config-radio', is: 'automatic' },
|
||||
{ when: 'oscap-policy', is: undefined },
|
||||
],
|
||||
},
|
||||
},
|
||||
],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue