xaboy / form-create

:fire::fire::fire: 强大的动态表单生成器,通过数据驱动表单渲染,支持可视化设计。提高开发者对表单的开发效率。目前在OA系统、ERP系统、电商系统、流程管理等系统中已稳定应用。

Home Page:https://www.form-create.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

全局设置disabled 下 ,upload不生效

1025946443 opened this issue · comments

大佬 formcreate 全局设置disabled 为true下,upload子组件disabled不生效,其他子组件disabled生效
单独为upload中props下设置disabled=true可以生效

微信图片_20240218173203

 {
                "type": "col",
                "props": {
                    "span": 24
                },
                "children": [
                    {
                        "type": "input",
                        "field": "residentialAddress",
                        "title": "居住地址",
                        "value": null,
                        "_fc_drag_tag": "input",
                        "hidden": false,
                        "display": true,
                        "props": {
                            "type": "textarea",
                            "placeholder": "请输入居住地址",
                        },
                        "$required": "居住地址不能为空",
                    }
                ],
                "_fc_drag_tag": "col",
                "hidden": false,
                "display": true
            },
            {
                type: "upload",
                field: "attachment",
                title: "图片上传",
                value: [],
                info: "",
                props: {
                    action: fileUrl,
                    limit: 80,
                    onSuccess: (res, file) => {
                        file[file.length - 1].url = res.response.data
                    },
                    syncDisabled: true,
                },
                itemMounted: (api) => {
                    console.log(api)
                }
            }

微信图片_20240218173528

formcreate 全局设置disabled 为true下 upload子组件不能点击+上传图片

formCreate组件没有disabled这个配置, 可以通过api.disabled方法操作禁用状态

感谢