Skip to content

Commit

Permalink
fix: 自定义条件过滤系统变量,自定义条件弹窗大小调整 (baidu#10480)
Browse files Browse the repository at this point in the history
* fix: 自定义条件过滤系统变量,自定义条件弹窗大小调整

* fix: 自定义条件过滤系统变量,自定义条件弹窗大小调整

---------

Co-authored-by: hezhihang <[email protected]>
  • Loading branch information
hzh11012 and hezhihang authored Jun 19, 2024
1 parent f910ae9 commit 46aef7e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
4 changes: 2 additions & 2 deletions packages/amis-editor/src/renderer/ConditionFormulaControl.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import {
import cx from 'classnames';
import {FormItem, Button, PickerContainer, ConditionBuilderFields} from 'amis';
import {reaction} from 'mobx';
import {getVariables} from 'amis-editor-core';
import {getQuickVariables} from 'amis-editor-core';

interface ConditionFormulaControlProps extends FormControlProps {
/**
Expand Down Expand Up @@ -99,7 +99,7 @@ export default class ConditionFormulaControl extends React.Component<
let fieldsArr: ConditionBuilderFields = [];
const {requiredDataPropsFields, fields} = this.props;
if (requiredDataPropsFields) {
const variablesArr = await getVariables(this);
const variablesArr = await getQuickVariables(this);

// 自身字段
const selfName = this.props?.data?.name;
Expand Down
1 change: 0 additions & 1 deletion packages/amis-editor/src/renderer/StatusControl.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,6 @@ export class StatusControl extends React.Component<
getSchemaTpl('conditionFormulaControl', {
label: '条件设置',
name: 'condition',
modalSize: 'xs',
visibleOn: 'this.statusType === 3'
})
]
Expand Down
8 changes: 3 additions & 5 deletions packages/amis-editor/src/renderer/ValidationControl.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,8 @@ import {ConditionBuilderFields, FormItem, flattenTree} from 'amis';

import {
autobind,
getSchemaTpl,
getVariables,
isObjectShallowModified,
tipedLabel
getQuickVariables,
isObjectShallowModified
} from 'amis-editor-core';
import ValidationItem, {ValidatorData} from './ValidationItem';

Expand Down Expand Up @@ -89,7 +87,7 @@ export default class ValidationControl extends React.Component<

@autobind
async buildFieldsData() {
const variablesArr = await getVariables(this);
const variablesArr = await getQuickVariables(this);
// 自身字段
const selfName = this.props.data.name;

Expand Down

0 comments on commit 46aef7e

Please sign in to comment.