From 78bd78ca3d5a5f5a9f06ae9124a55164570b4aa3 Mon Sep 17 00:00:00 2001 From: katherinehhh Date: Thu, 23 Nov 2023 11:50:34 +0800 Subject: [PATCH] fix: view collection json field rendering error (#3077) --- .../collection-manager/templates/components/PreviewTable.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/client/src/collection-manager/templates/components/PreviewTable.tsx b/packages/core/client/src/collection-manager/templates/components/PreviewTable.tsx index 8be105ed0..a3cfbb9ea 100644 --- a/packages/core/client/src/collection-manager/templates/components/PreviewTable.tsx +++ b/packages/core/client/src/collection-manager/templates/components/PreviewTable.tsx @@ -70,7 +70,7 @@ export const PreviewTable = (props) => { 'x-component': schema && fieldSource ? 'CollectionField' : 'Input', 'x-read-pretty': true, 'x-collection-field': fieldSource?.join('.'), - default: content, + default: JSON.stringify(content), }, }, };