mirror of
https://github.com/ansible/awx.git
synced 2026-01-19 05:31:22 -03:30
Merge pull request #10741 from AlexSCorey/10495-ActionBtnOnEmptyState
Improves empty state messages for improve UX
This commit is contained in:
commit
07a4683f08
@ -159,6 +159,7 @@ function JobList({ defaultParams, showTypeColumn = false }) {
|
||||
hasContentLoading={isLoading || isDeleteLoading || isCancelLoading}
|
||||
items={jobs}
|
||||
itemCount={count}
|
||||
emptyContentMessage={t`Please run a job to populate this list.`}
|
||||
pluralizedItemName={t`Jobs`}
|
||||
qsConfig={qsConfig}
|
||||
toolbarSearchColumns={[
|
||||
|
||||
@ -10,7 +10,6 @@ import { useKebabifiedMenu } from 'contexts/Kebabified';
|
||||
function ToolbarAddButton({
|
||||
linkTo,
|
||||
onClick,
|
||||
|
||||
isDisabled,
|
||||
defaultLabel = t`Add`,
|
||||
showToggleIndicator,
|
||||
|
||||
@ -147,6 +147,11 @@ function ScheduleList({
|
||||
}
|
||||
return missingValues && t`This schedule is missing required survey values`;
|
||||
};
|
||||
let emptyContentMessage = t`Please add a Schedule to populate this list.`;
|
||||
|
||||
if (location.pathname.startsWith('/schedules')) {
|
||||
emptyContentMessage = t`Please add a Schedule to populate this list. Schedules can be added to a Template, Project, or Inventory Source.`;
|
||||
}
|
||||
|
||||
return (
|
||||
<>
|
||||
@ -156,6 +161,8 @@ function ScheduleList({
|
||||
items={schedules}
|
||||
itemCount={itemCount}
|
||||
qsConfig={QS_CONFIG}
|
||||
pluralizedItemName={t`Schedules`}
|
||||
emptyContentMessage={emptyContentMessage}
|
||||
onRowClick={handleSelect}
|
||||
headerRow={
|
||||
<HeaderRow qsConfig={QS_CONFIG}>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user