fix: Editor:当删除静态展示框的默认值时同时清除历史残余的value值

This commit is contained in:
jinye 2024-01-02 20:41:31 +08:00
parent d9fb3ddb75
commit 0f1d23628d

View File

@ -328,7 +328,13 @@ export class StaticControlPlugin extends BasePlugin {
getSchemaTpl('label'), getSchemaTpl('label'),
// getSchemaTpl('value'), // getSchemaTpl('value'),
getSchemaTpl('valueFormula', { getSchemaTpl('valueFormula', {
name: 'tpl' name: 'tpl',
onChange: (value: any, oldValue: any, item: any, form: any) => {
value === '' &&
form.setValues({
value: undefined
});
}
// rendererSchema: { // rendererSchema: {
// ...context?.schema, // ...context?.schema,
// type: 'textarea', // 改用多行文本编辑 // type: 'textarea', // 改用多行文本编辑