From a97708eedfd9246aa2cef5ce3b5fd3fdf4e5aa68 Mon Sep 17 00:00:00 2001 From: Arman Date: Wed, 12 Apr 2023 14:59:52 +0200 Subject: [PATCH] fix: data maitained in doc creation navigation --- .../document-[document]/attributes/relationship.svelte | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/routes/console/project-[project]/databases/database-[database]/collection-[collection]/document-[document]/attributes/relationship.svelte b/src/routes/console/project-[project]/databases/database-[database]/collection-[collection]/document-[document]/attributes/relationship.svelte index 8ff8e3867..c12654564 100644 --- a/src/routes/console/project-[project]/databases/database-[database]/collection-[collection]/document-[document]/attributes/relationship.svelte +++ b/src/routes/console/project-[project]/databases/database-[database]/collection-[collection]/document-[document]/attributes/relationship.svelte @@ -30,6 +30,13 @@ let offset = 0; onMount(async () => { + if (value) { + if (isRelationshipToMany(attribute)) { + relatedList = value as string[]; + } else { + singleRel = value as string; + } + } documentList = await getDocuments(); if (editing && $doc?.[attribute.key]) {