diff --git a/awx/ui_next/src/screens/Organization/OrganizationList/OrganizationList.jsx b/awx/ui_next/src/screens/Organization/OrganizationList/OrganizationList.jsx index 06e83022b8..d0031cb30e 100644 --- a/awx/ui_next/src/screens/Organization/OrganizationList/OrganizationList.jsx +++ b/awx/ui_next/src/screens/Organization/OrganizationList/OrganizationList.jsx @@ -18,7 +18,7 @@ import OrganizationListItem from './OrganizationListItem'; const QS_CONFIG = getQSConfig('organization', { page: 1, - page_size: 5, + page_size: 20, order_by: 'name', }); diff --git a/awx/ui_next/src/screens/Project/Project.jsx b/awx/ui_next/src/screens/Project/Project.jsx index 1b509992cd..03f0fae85e 100644 --- a/awx/ui_next/src/screens/Project/Project.jsx +++ b/awx/ui_next/src/screens/Project/Project.jsx @@ -127,31 +127,32 @@ class Project extends Component { (me.is_system_auditor || isAuditorOfThisOrg || isAdminOfThisOrg); const tabsArray = [ - { name: i18n._(t`Details`), link: `${match.url}/details`, id: 0 }, - { name: i18n._(t`Access`), link: `${match.url}/access`, id: 1 }, + { name: i18n._(t`Details`), link: `${match.url}/details` }, + { name: i18n._(t`Access`), link: `${match.url}/access` }, ]; if (canSeeNotificationsTab) { tabsArray.push({ name: i18n._(t`Notifications`), link: `${match.url}/notifications`, - id: 2, }); } tabsArray.push( { name: i18n._(t`Job Templates`), - link: '/job_templates', - id: canSeeNotificationsTab ? 3 : 2, + link: `${match.url}/job_templates`, }, { name: i18n._(t`Schedules`), - link: '/schedules', - id: canSeeNotificationsTab ? 4 : 3, + link: `${match.url}/schedules`, } ); + tabsArray.forEach((tab, n) => { + tab.id = n; + }); + const CardHeader = styled(PFCardHeader)` --pf-c-card--first-child--PaddingTop: 0; --pf-c-card--child--PaddingLeft: 0; diff --git a/awx/ui_next/src/screens/Project/ProjectList/ProjectList.jsx b/awx/ui_next/src/screens/Project/ProjectList/ProjectList.jsx index 384ed67fd7..1e46ce6760 100644 --- a/awx/ui_next/src/screens/Project/ProjectList/ProjectList.jsx +++ b/awx/ui_next/src/screens/Project/ProjectList/ProjectList.jsx @@ -18,7 +18,7 @@ import ProjectListItem from './ProjectListItem'; const QS_CONFIG = getQSConfig('project', { page: 1, - page_size: 5, + page_size: 20, order_by: 'name', }); @@ -38,7 +38,7 @@ class ProjectsList extends Component { this.handleSelectAll = this.handleSelectAll.bind(this); this.handleSelect = this.handleSelect.bind(this); - this.handleOrgDelete = this.handleOrgDelete.bind(this); + this.handleProjectDelete = this.handleProjectDelete.bind(this); this.handleDeleteErrorClose = this.handleDeleteErrorClose.bind(this); this.loadProjects = this.loadProjects.bind(this); } @@ -75,12 +75,14 @@ class ProjectsList extends Component { this.setState({ deletionError: null }); } - async handleOrgDelete() { + async handleProjectDelete() { const { selected } = this.state; this.setState({ hasContentLoading: true }); try { - await Promise.all(selected.map(org => ProjectsAPI.destroy(org.id))); + await Promise.all( + selected.map(project => ProjectsAPI.destroy(project.id)) + ); } catch (err) { this.setState({ deletionError: err }); } finally { @@ -150,7 +152,7 @@ class ProjectsList extends Component { hasContentLoading={hasContentLoading} items={projects} itemCount={itemCount} - pluralizedItemName="Projects" + pluralizedItemName={i18n._(t`Projects`)} qsConfig={QS_CONFIG} toolbarColumns={[ { @@ -182,9 +184,9 @@ class ProjectsList extends Component { additionalControls={[ , canAdd ? ( diff --git a/awx/ui_next/src/screens/Template/Template.jsx b/awx/ui_next/src/screens/Template/Template.jsx index 414abdb6f7..408bc11dcf 100644 --- a/awx/ui_next/src/screens/Template/Template.jsx +++ b/awx/ui_next/src/screens/Template/Template.jsx @@ -89,15 +89,14 @@ class Template extends Component { const canSeeNotificationsTab = me.is_system_auditor || isNotifAdmin; const tabsArray = [ - { name: i18n._(t`Details`), link: `${match.url}/details`, id: 0 }, - { name: i18n._(t`Access`), link: '/home', id: 1 }, + { name: i18n._(t`Details`), link: `${match.url}/details` }, + { name: i18n._(t`Access`), link: '/home' }, ]; if (canSeeNotificationsTab) { tabsArray.push({ name: i18n._(t`Notifications`), link: `${match.url}/notifications`, - id: 2, }); } @@ -105,20 +104,21 @@ class Template extends Component { { name: i18n._(t`Schedules`), link: '/home', - id: canSeeNotificationsTab ? 3 : 2, }, { name: i18n._(t`Completed Jobs`), link: '/home', - id: canSeeNotificationsTab ? 4 : 3, }, { name: i18n._(t`Survey`), link: '/home', - id: canSeeNotificationsTab ? 5 : 4, } ); + tabsArray.forEach((tab, n) => { + tab.id = n; + }); + let cardHeader = hasContentLoading ? null : ( diff --git a/awx/ui_next/src/screens/Template/TemplateList/TemplateList.jsx b/awx/ui_next/src/screens/Template/TemplateList/TemplateList.jsx index 432e8f105f..3560516d14 100644 --- a/awx/ui_next/src/screens/Template/TemplateList/TemplateList.jsx +++ b/awx/ui_next/src/screens/Template/TemplateList/TemplateList.jsx @@ -27,7 +27,7 @@ import TemplateListItem from './TemplateListItem'; // workflow_job_template so the params sent to the API match what the api expects. const QS_CONFIG = getQSConfig('template', { page: 1, - page_size: 5, + page_size: 20, order_by: 'name', type: 'job_template,workflow_job_template', });