From 0b1bedf1321025199bf3ccb51ca6e2cdad194891 Mon Sep 17 00:00:00 2001 From: Steven Nguyen Date: Wed, 17 Jan 2024 02:24:35 +0000 Subject: [PATCH 1/3] Ensure messages table re-renders on filter --- src/routes/console/project-[project]/messaging/+page.svelte | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/routes/console/project-[project]/messaging/+page.svelte b/src/routes/console/project-[project]/messaging/+page.svelte index 35558ebe46..4a19613ca0 100644 --- a/src/routes/console/project-[project]/messaging/+page.svelte +++ b/src/routes/console/project-[project]/messaging/+page.svelte @@ -98,7 +98,7 @@ {/each} - {#each data.messages.messages as message} + {#each data.messages.messages as message (message.$id)} From 8b16f3da8392e0409c5c85cbd9b1223a72d2a521 Mon Sep 17 00:00:00 2001 From: Steven Nguyen Date: Wed, 17 Jan 2024 02:26:11 +0000 Subject: [PATCH 2/3] Don't allow filtering on message Message is nested in data and isn't an attribute so it can't be queried. --- src/routes/console/project-[project]/messaging/store.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/routes/console/project-[project]/messaging/store.ts b/src/routes/console/project-[project]/messaging/store.ts index 839c0526b2..6c14fb41e7 100644 --- a/src/routes/console/project-[project]/messaging/store.ts +++ b/src/routes/console/project-[project]/messaging/store.ts @@ -8,7 +8,7 @@ export const showCreate = writable(false); export const columns = writable([ { id: '$id', title: 'Message ID', type: 'string', show: true, width: 140 }, { id: 'description', title: 'Description', type: 'string', show: true, width: 140 }, - { id: 'message', title: 'Message', type: 'string', show: false, width: 140 }, + { id: 'message', title: 'Message', type: 'string', show: false, filter: false, width: 140 }, { id: 'providerType', title: 'Type', type: 'string', show: true, width: 100 }, { id: 'status', title: 'Status', type: 'string', show: true, width: 120 }, { id: 'scheduledAt', title: 'Scheduled at', type: 'datetime', show: true, width: 120 }, From fc21321cae94e9fe77c266ccac0d5867ab0ac567 Mon Sep 17 00:00:00 2001 From: Steven Nguyen Date: Wed, 17 Jan 2024 02:48:35 +0000 Subject: [PATCH 3/3] Update messages search placeholder --- .../console/project-[project]/messaging/+page.svelte | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/routes/console/project-[project]/messaging/+page.svelte b/src/routes/console/project-[project]/messaging/+page.svelte index 4a19613ca0..03d9e36429 100644 --- a/src/routes/console/project-[project]/messaging/+page.svelte +++ b/src/routes/console/project-[project]/messaging/+page.svelte @@ -12,6 +12,7 @@ SearchQuery, ViewSelector } from '$lib/components'; + import { Filters, hasPageQueries } from '$lib/components/filters'; import { Button } from '$lib/elements/forms'; import { TableBody, @@ -27,12 +28,11 @@ import { toLocaleDateTime } from '$lib/helpers/date'; import { Container } from '$lib/layout'; import type { PageData } from './$types'; - import { columns, showCreate } from './store'; - import MessageStatusPill from './messageStatusPill.svelte'; import CreateMessageDropdown from './createMessageDropdown.svelte'; - import ProviderType, { ProviderTypes } from './providerType.svelte'; - import { Filters, hasPageQueries } from '$lib/components/filters'; import FailedModal from './failedModal.svelte'; + import MessageStatusPill from './messageStatusPill.svelte'; + import ProviderType, { ProviderTypes } from './providerType.svelte'; + import { columns, showCreate } from './store'; export let data: PageData; let selected: string[] = []; @@ -55,7 +55,9 @@ - +