From 11927d2340feae13d70f8cc6c68ba51822c7e525 Mon Sep 17 00:00:00 2001 From: Martin McKeaveney Date: Thu, 15 Oct 2020 10:48:57 +0100 Subject: [PATCH] adding sum and count functionality, preventing user from doing bad filters --- .../BlockList/AutomationBlock.svelte | 4 +++- .../automation/SetupPanel/SetupPanel.svelte | 5 +++- .../components/backend/DataTable/Table.svelte | 3 +-- .../backend/DataTable/TablePagination.svelte | 17 +++++++------ .../backend/DataTable/ViewDataTable.svelte | 9 +++---- .../popovers/CalculatePopover.svelte | 24 ++++++++++++++----- .../Notification/NotificationDisplay.svelte | 4 +++- .../components/settings/Integration.svelte | 4 +++- .../src/components/settings/tabs/Users.svelte | 4 ++-- .../src/components/start/AppCard.svelte | 4 +--- .../src/components/start/AppList.svelte | 4 ++-- .../src/components/start/TemplateList.svelte | 11 +++++---- .../ComponentDropdownMenu.svelte | 4 +++- .../EventsEditor/StateBindingCascader.svelte | 4 +++- .../IconSelect/IconSelect.svelte | 4 +++- .../userInterface/ItemTab/Item.svelte | 4 +++- .../src/pages/[application]/_reset.svelte | 4 ++-- .../table/[selectedTable]/index.svelte | 4 +++- .../[application]/backend/table/index.svelte | 4 +++- .../backend/view/[selectedView]/index.svelte | 4 +++- packages/server/src/api/controllers/row.js | 24 ++++++++++++++----- .../src/api/controllers/view/viewBuilder.js | 12 ++++++++-- packages/standard-components/src/Card.svelte | 4 +++- .../src/CardHorizontal.svelte | 4 +++- .../src/DataGrid/AttachmentCell/Button.svelte | 13 +++++++++- .../src/DataGrid/Component.svelte | 6 ++--- packages/standard-components/src/Login.svelte | 4 +++- .../standard-components/src/Navigation.svelte | 4 +++- .../src/Test/TestApp.svelte | 2 +- packages/standard-components/src/Text.svelte | 4 +++- .../src/attachments/AttachmentList.svelte | 4 +++- 31 files changed, 140 insertions(+), 66 deletions(-) diff --git a/packages/builder/src/components/automation/AutomationPanel/BlockList/AutomationBlock.svelte b/packages/builder/src/components/automation/AutomationPanel/BlockList/AutomationBlock.svelte index 2419999475..b8ac6638ae 100644 --- a/packages/builder/src/components/automation/AutomationPanel/BlockList/AutomationBlock.svelte +++ b/packages/builder/src/components/automation/AutomationPanel/BlockList/AutomationBlock.svelte @@ -23,7 +23,9 @@ class="automation-block hoverable" on:click={addBlockToAutomation} data-cy={stepId}> -
+
+ +

{blockDefinition.name}

{blockDefinition.description}

diff --git a/packages/builder/src/components/automation/SetupPanel/SetupPanel.svelte b/packages/builder/src/components/automation/SetupPanel/SetupPanel.svelte index 37ca1f2252..f2b7a8b711 100644 --- a/packages/builder/src/components/automation/SetupPanel/SetupPanel.svelte +++ b/packages/builder/src/components/automation/SetupPanel/SetupPanel.svelte @@ -62,7 +62,10 @@ {#if $automationStore.selectedBlock} {:else if $automationStore.selectedAutomation} -
Automation {automation.name}
+
+ Automation + {automation.name} +
{/if}
diff --git a/packages/builder/src/components/backend/DataTable/Table.svelte b/packages/builder/src/components/backend/DataTable/Table.svelte index 4c0dc06d39..dde114a76c 100644 --- a/packages/builder/src/components/backend/DataTable/Table.svelte +++ b/packages/builder/src/components/backend/DataTable/Table.svelte @@ -108,8 +108,7 @@
selectRelationship(row, header)}> - {row[header] ? row[header].length : 0} - related row(s) + {row[header] ? row[header].length : 0} related row(s)
{:else if schema[header].type === 'attachment'} diff --git a/packages/builder/src/components/backend/DataTable/TablePagination.svelte b/packages/builder/src/components/backend/DataTable/TablePagination.svelte index ca5a58700d..ccb7d0fc4c 100644 --- a/packages/builder/src/components/backend/DataTable/TablePagination.svelte +++ b/packages/builder/src/components/backend/DataTable/TablePagination.svelte @@ -49,7 +49,9 @@ - {#if currentPage > 3}{/if} + {#if currentPage > 3} + + {/if} {#each pagesAroundCurrent as idx} {/if} + {#if currentPage < numPages - 4} + + {/if}