From 547b74a6d8492ef10c32ae749fd376cc03cecb3f Mon Sep 17 00:00:00 2001 From: Pranav C Date: Mon, 7 Nov 2022 13:34:22 +0530 Subject: [PATCH] fix(gui): JSON stringify attachment data Signed-off-by: Pranav C --- packages/nc-gui/components/cell/attachment/index.vue | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/packages/nc-gui/components/cell/attachment/index.vue b/packages/nc-gui/components/cell/attachment/index.vue index 4732c1899c..b3875eb0a2 100644 --- a/packages/nc-gui/components/cell/attachment/index.vue +++ b/packages/nc-gui/components/cell/attachment/index.vue @@ -120,7 +120,7 @@ watch( /** updates attachments array for autosave */ function updateModelValue(data: string | Record[]) { - emits('update:modelValue', data) + emits('update:modelValue', typeof data === 'string' ? data : JSON.stringify(data)) } /** Close modal on escape press, disable dropzone as well */ @@ -152,7 +152,8 @@ watch( :target="currentCellRef" class="nc-attachment-cell-dropzone text-white text-lg ring ring-accent ring-opacity-100 bg-gray-700/75 flex items-center justify-center gap-2 backdrop-blur-xl" > - Drop here + + Drop here @@ -166,7 +167,7 @@ watch( - +
- +