fix(client): detail block should support save as block template (#3303)

* fix: detail block should support save as block template

* test: detail block setting test
This commit is contained in:
katherinehhh 2024-01-02 22:24:17 +08:00 committed by GitHub
parent 64e0659f7b
commit 4dbac496be
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 3 deletions

View File

@ -21,7 +21,7 @@ test.describe('multi data details block schema settings', () => {
'Edit block title',
'Set the data scope',
'Set default sorting rules',
'Save as block template',
'Save as template',
'Delete',
],
});

View File

@ -14,6 +14,7 @@ import {
SchemaSettingsFormItemTemplate,
SchemaSettingsDataScope,
SchemaSettingsBlockTitleItem,
SchemaSettingsTemplate,
} from '../../../schema-settings';
export const formSettings = new SchemaSettings({
@ -277,8 +278,8 @@ export const formDetailsSettings = new SchemaSettings({
},
},
{
name: 'formItemTemplate',
Component: SchemaSettingsFormItemTemplate,
name: 'template',
Component: SchemaSettingsTemplate,
useComponentProps() {
const { name } = useCollection();
const fieldSchema = useFieldSchema();