mirror of
https://github.com/ansible/awx.git
synced 2026-02-26 07:26:03 -03:30
Disable checkbox while job is running in project and inventory source lists (#11841)
This commit is contained in:
@@ -13,6 +13,7 @@ import { ActionsTd, ActionItem, TdBreakWord } from 'components/PaginatedTable';
|
|||||||
import StatusLabel from 'components/StatusLabel';
|
import StatusLabel from 'components/StatusLabel';
|
||||||
import JobCancelButton from 'components/JobCancelButton';
|
import JobCancelButton from 'components/JobCancelButton';
|
||||||
import { formatDateString } from 'util/dates';
|
import { formatDateString } from 'util/dates';
|
||||||
|
import { isJobRunning } from 'util/jobs';
|
||||||
import InventorySourceSyncButton from '../shared/InventorySourceSyncButton';
|
import InventorySourceSyncButton from '../shared/InventorySourceSyncButton';
|
||||||
|
|
||||||
const ExclamationTriangleIcon = styled(PFExclamationTriangleIcon)`
|
const ExclamationTriangleIcon = styled(PFExclamationTriangleIcon)`
|
||||||
@@ -64,6 +65,7 @@ function InventorySourceListItem({
|
|||||||
rowIndex,
|
rowIndex,
|
||||||
isSelected,
|
isSelected,
|
||||||
onSelect,
|
onSelect,
|
||||||
|
disable: isJobRunning(source.status),
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
<TdBreakWord dataLabel={t`Name`}>
|
<TdBreakWord dataLabel={t`Name`}>
|
||||||
|
|||||||
@@ -172,6 +172,7 @@ function ProjectListItem({
|
|||||||
rowIndex,
|
rowIndex,
|
||||||
isSelected,
|
isSelected,
|
||||||
onSelect,
|
onSelect,
|
||||||
|
disable: isJobRunning(job?.status),
|
||||||
}}
|
}}
|
||||||
dataLabel={t`Selected`}
|
dataLabel={t`Selected`}
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user