renamed home page table headers and added filter table link to the completed instances page w/ burnettk
This commit is contained in:
parent
2084befdb0
commit
22138e1bf1
|
@ -1,16 +0,0 @@
|
||||||
import ProcessInstanceListTable from './ProcessInstanceListTable';
|
|
||||||
|
|
||||||
const paginationQueryParamPrefix = 'my_completed_instances';
|
|
||||||
|
|
||||||
export default function MyCompletedInstances() {
|
|
||||||
return (
|
|
||||||
<ProcessInstanceListTable
|
|
||||||
filtersEnabled={false}
|
|
||||||
paginationQueryParamPrefix={paginationQueryParamPrefix}
|
|
||||||
perPageOptions={[2, 5, 25]}
|
|
||||||
reportIdentifier="system_report_completed_instances_initiated_by_me"
|
|
||||||
showReports={false}
|
|
||||||
showActionsColumn
|
|
||||||
/>
|
|
||||||
);
|
|
||||||
}
|
|
|
@ -1704,7 +1704,7 @@ export default function ProcessInstanceListTable({
|
||||||
}
|
}
|
||||||
return (
|
return (
|
||||||
<Grid fullWidth condensed>
|
<Grid fullWidth condensed>
|
||||||
<Column sm={{ span: 3 }} md={{ span: 4 }} lg={{ span: 3 }}>
|
<Column sm={{ span: 3 }} md={{ span: 7 }} lg={{ span: 15 }}>
|
||||||
{headerElement}
|
{headerElement}
|
||||||
</Column>
|
</Column>
|
||||||
{filterButtonLink}
|
{filterButtonLink}
|
||||||
|
|
|
@ -19,43 +19,54 @@ export default function CompletedInstances() {
|
||||||
|
|
||||||
return userGroups.map((userGroup: string) => {
|
return userGroups.map((userGroup: string) => {
|
||||||
const titleText = `This is a list of instances with tasks that were completed by the ${userGroup} group.`;
|
const titleText = `This is a list of instances with tasks that were completed by the ${userGroup} group.`;
|
||||||
|
const headerElement = (
|
||||||
|
<h2 title={titleText} className="process-instance-table-header">
|
||||||
|
Instances with tasks completed by <strong>{userGroup}</strong>
|
||||||
|
</h2>
|
||||||
|
);
|
||||||
return (
|
return (
|
||||||
<>
|
<ProcessInstanceListTable
|
||||||
<h2 title={titleText} className="process-instance-table-header">
|
headerElement={headerElement}
|
||||||
With tasks completed by <strong>{userGroup}</strong>
|
showLinkToReport
|
||||||
</h2>
|
filtersEnabled={false}
|
||||||
<ProcessInstanceListTable
|
paginationQueryParamPrefix="group_completed_instances"
|
||||||
filtersEnabled={false}
|
paginationClassName="with-large-bottom-margin"
|
||||||
paginationQueryParamPrefix="group_completed_instances"
|
perPageOptions={[2, 5, 25]}
|
||||||
paginationClassName="with-large-bottom-margin"
|
reportIdentifier="system_report_completed_instances"
|
||||||
perPageOptions={[2, 5, 25]}
|
showReports={false}
|
||||||
reportIdentifier="system_report_completed_instances"
|
textToShowIfEmpty="This group has no completed instances at this time."
|
||||||
showReports={false}
|
additionalReportFilters={[
|
||||||
textToShowIfEmpty="This group has no completed instances at this time."
|
{ field_name: 'user_group_identifier', field_value: userGroup },
|
||||||
additionalReportFilters={[
|
]}
|
||||||
{ field_name: 'user_group_identifier', field_value: userGroup },
|
showActionsColumn
|
||||||
]}
|
/>
|
||||||
showActionsColumn
|
|
||||||
/>
|
|
||||||
</>
|
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const startedByMeTitleText =
|
const startedByMeTitleText =
|
||||||
'This is a list of instances you started that are now complete.';
|
'This is a list of instances you started that are now complete.';
|
||||||
|
const startedByMeHeaderElement = (
|
||||||
|
<h2 title={startedByMeTitleText} className="process-instance-table-header">
|
||||||
|
Started by me
|
||||||
|
</h2>
|
||||||
|
);
|
||||||
const withTasksCompletedByMeTitleText =
|
const withTasksCompletedByMeTitleText =
|
||||||
'This is a list of instances where you have completed tasks.';
|
'This is a list of instances where you have completed tasks.';
|
||||||
|
const withTasksHeaderElement = (
|
||||||
|
<h2
|
||||||
|
title={withTasksCompletedByMeTitleText}
|
||||||
|
className="process-instance-table-header"
|
||||||
|
>
|
||||||
|
Instances with tasks completed by me
|
||||||
|
</h2>
|
||||||
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<h2
|
|
||||||
title={startedByMeTitleText}
|
|
||||||
className="process-instance-table-header"
|
|
||||||
>
|
|
||||||
Started by me
|
|
||||||
</h2>
|
|
||||||
<ProcessInstanceListTable
|
<ProcessInstanceListTable
|
||||||
|
headerElement={startedByMeHeaderElement}
|
||||||
|
showLinkToReport
|
||||||
filtersEnabled={false}
|
filtersEnabled={false}
|
||||||
paginationQueryParamPrefix="my_completed_instances"
|
paginationQueryParamPrefix="my_completed_instances"
|
||||||
perPageOptions={[2, 5, 25]}
|
perPageOptions={[2, 5, 25]}
|
||||||
|
@ -66,13 +77,9 @@ export default function CompletedInstances() {
|
||||||
autoReload
|
autoReload
|
||||||
showActionsColumn
|
showActionsColumn
|
||||||
/>
|
/>
|
||||||
<h2
|
|
||||||
title={withTasksCompletedByMeTitleText}
|
|
||||||
className="process-instance-table-header"
|
|
||||||
>
|
|
||||||
With tasks completed by me
|
|
||||||
</h2>
|
|
||||||
<ProcessInstanceListTable
|
<ProcessInstanceListTable
|
||||||
|
headerElement={withTasksHeaderElement}
|
||||||
|
showLinkToReport
|
||||||
filtersEnabled={false}
|
filtersEnabled={false}
|
||||||
paginationQueryParamPrefix="my_completed_tasks"
|
paginationQueryParamPrefix="my_completed_tasks"
|
||||||
perPageOptions={[2, 5, 25]}
|
perPageOptions={[2, 5, 25]}
|
||||||
|
|
|
@ -22,7 +22,7 @@ export default function InProgressInstances() {
|
||||||
const titleText = `This is a list of instances with tasks that are waiting for the ${userGroup} group.`;
|
const titleText = `This is a list of instances with tasks that are waiting for the ${userGroup} group.`;
|
||||||
const headerElement = (
|
const headerElement = (
|
||||||
<h2 title={titleText} className="process-instance-table-header">
|
<h2 title={titleText} className="process-instance-table-header">
|
||||||
Waiting for <strong>{userGroup}</strong>
|
Instances with tasks waiting for <strong>{userGroup}</strong>
|
||||||
</h2>
|
</h2>
|
||||||
);
|
);
|
||||||
return (
|
return (
|
||||||
|
@ -61,7 +61,7 @@ export default function InProgressInstances() {
|
||||||
'This is a list of instances that have tasks that you can complete.';
|
'This is a list of instances that have tasks that you can complete.';
|
||||||
const waitingForMeHeaderElement = (
|
const waitingForMeHeaderElement = (
|
||||||
<h2 title={waitingForMeTitleText} className="process-instance-table-header">
|
<h2 title={waitingForMeTitleText} className="process-instance-table-header">
|
||||||
Waiting for me
|
Instances with tasks waiting for me
|
||||||
</h2>
|
</h2>
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue