mirror of
https://github.com/ansible/awx.git
synced 2026-04-14 14:39:26 -02:30
Cleanup UI linting, tests, and import
Cleans up UI linting errors Fix broken UI unit tests Adds missing LabelsMixin import
This commit is contained in:
@@ -1,9 +1,7 @@
|
|||||||
import React, { useState, useCallback, useEffect } from 'react';
|
import React, { useState, useCallback, useEffect } from 'react';
|
||||||
import { useHistory } from 'react-router-dom';
|
import { useHistory } from 'react-router-dom';
|
||||||
|
|
||||||
import { Card, PageSection } from '@patternfly/react-core';
|
import { Card, PageSection } from '@patternfly/react-core';
|
||||||
import { CardBody } from 'components/Card';
|
import { CardBody } from 'components/Card';
|
||||||
|
|
||||||
import { WorkflowJobTemplatesAPI, OrganizationsAPI, UsersAPI } from 'api';
|
import { WorkflowJobTemplatesAPI, OrganizationsAPI, UsersAPI } from 'api';
|
||||||
import { useConfig } from 'contexts/Config';
|
import { useConfig } from 'contexts/Config';
|
||||||
import useRequest from 'hooks/useRequest';
|
import useRequest from 'hooks/useRequest';
|
||||||
|
|||||||
@@ -186,11 +186,14 @@ function WorkflowJobTemplateForm({
|
|||||||
aria-label={t`source control branch`}
|
aria-label={t`source control branch`}
|
||||||
/>
|
/>
|
||||||
</FieldWithPrompt>
|
</FieldWithPrompt>
|
||||||
|
</FormColumnLayout>
|
||||||
|
<FormFullWidthLayout>
|
||||||
<FieldWithPrompt
|
<FieldWithPrompt
|
||||||
label={t`Labels`}
|
|
||||||
fieldId="template-labels"
|
fieldId="template-labels"
|
||||||
|
label={t`Labels`}
|
||||||
promptId="template-ask-labels-on-launch"
|
promptId="template-ask-labels-on-launch"
|
||||||
promptName="ask_labels_on_launch"
|
promptName="ask_labels_on_launch"
|
||||||
|
tooltip={helpText.labels}
|
||||||
>
|
>
|
||||||
<LabelSelect
|
<LabelSelect
|
||||||
value={labelsField.value}
|
value={labelsField.value}
|
||||||
@@ -199,29 +202,29 @@ function WorkflowJobTemplateForm({
|
|||||||
createText={t`Create`}
|
createText={t`Create`}
|
||||||
/>
|
/>
|
||||||
</FieldWithPrompt>
|
</FieldWithPrompt>
|
||||||
<FormFullWidthLayout>
|
</FormFullWidthLayout>
|
||||||
<VariablesField
|
<FormFullWidthLayout>
|
||||||
id="wfjt-variables"
|
<VariablesField
|
||||||
name="extra_vars"
|
id="wfjt-variables"
|
||||||
label={t`Variables`}
|
name="extra_vars"
|
||||||
promptId="template-ask-variables-on-launch"
|
label={t`Variables`}
|
||||||
tooltip={helpText.variables}
|
promptId="template-ask-variables-on-launch"
|
||||||
|
tooltip={helpText.variables}
|
||||||
|
/>
|
||||||
|
</FormFullWidthLayout>
|
||||||
|
<FormColumnLayout>
|
||||||
|
<FieldWithPrompt
|
||||||
|
fieldId="template-tags"
|
||||||
|
label={t`Job Tags`}
|
||||||
|
promptId="template-ask-tags-on-launch"
|
||||||
|
promptName="ask_tags_on_launch"
|
||||||
|
tooltip={helpText.jobTags}
|
||||||
|
>
|
||||||
|
<TagMultiSelect
|
||||||
|
value={jobTagsField.value}
|
||||||
|
onChange={(value) => jobTagsHelpers.setValue(value)}
|
||||||
/>
|
/>
|
||||||
</FormFullWidthLayout>
|
</FieldWithPrompt>
|
||||||
<FormColumnLayout>
|
|
||||||
<FieldWithPrompt
|
|
||||||
fieldId="template-tags"
|
|
||||||
label={t`Job Tags`}
|
|
||||||
promptId="template-ask-tags-on-launch"
|
|
||||||
promptName="ask_tags_on_launch"
|
|
||||||
tooltip={helpText.jobTags}
|
|
||||||
>
|
|
||||||
<TagMultiSelect
|
|
||||||
value={jobTagsField.value}
|
|
||||||
onChange={(value) => jobTagsHelpers.setValue(value)}
|
|
||||||
/>
|
|
||||||
</FieldWithPrompt>
|
|
||||||
</FormColumnLayout>
|
|
||||||
<FieldWithPrompt
|
<FieldWithPrompt
|
||||||
fieldId="template-skip-tags"
|
fieldId="template-skip-tags"
|
||||||
label={t`Skip Tags`}
|
label={t`Skip Tags`}
|
||||||
|
|||||||
Reference in New Issue
Block a user