8000 formItem不支持监听其他formItem改变后触发自身校验 · Issue #11956 · baidu/amis · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

formItem不支持监听其他formItem改变后触发自身校验 #11956

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
thinkingc opened this issue May 6, 2025 · 1 comment
Open

formItem不支持监听其他formItem改变后触发自身校验 #11956

thinkingc opened this issue May 6, 2025 · 1 comment

Comments

@thinkingc
Copy link
Contributor

描述问题:

formItem不支持监听其他formItem改变后触发自身校验

截图或视频:

Image

如何复现(请务必完整填写下面内容):

  1. 你是如何使用 amis 的?
    sdknpm其他...

  2. amis 版本是什么?请先在最新 beta 版本测试问题是否存在

  3. 粘贴有问题的完整 amis schema 代码:

{
  "type": "page",
  "body": {
    "type": "form",
    "body": [
      {
        "type": "group",
        "mode": "horizontal",
        "label": "区间",
        "body": [
          {
            "type": "input-number",
            "name": "callDurationStart",
            "clearable": true,
            "placeholder": "请输入",
            "strictMode": false,
            "min": 1,
            "validateOnChange": true,
            "validations": {
              "lt": "${callDurationEnd}"
            },
            "validationErrors": {
              "lt": "请输入小于右区间的数字"
            }
          },
          {
            "type": "input-number",
            "name": "callDurationEnd",
            "clearable": true,
            "placeholder": "请输入",
            "min": 1,
            "strictMode": false,
            "validateOnChange": true,
            "validations": {
              "gt": "${callDurationStart}"
            },
            "validationErrors": {
              "gt": "请输入大于左区间的数字"
            }
          }
        ]
      }
    ],
    "actions": [
      {
        "type": "reset",
        "label": "重 置"
      },
      {
        "type": "submit",
        "level": "primary",
        "label": "查 询"
      }
    ]
  }
}
  1. 操作步骤
    1、先在左边输入8
    2、在右边输入12
    3、希望左边的校验信息消失
@lhtuling
Copy link
Contributor

Image

事件动作可以实现,给文档过一遍,大概对各个功能和组件有个印象,用的时候可能就想起来了

欢迎加入最大的,人数最多的,含佬量极高的社区群
Amis社区交流群【QQ1群】:717791727
Amis社区交流群【QQ2群】:721182449

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants
0