Skip to content
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

🐛 [BUG]EditorFormRef.current?.setRowData方法不生效 #10886

Closed
lyck40012 opened this issue Aug 14, 2023 · 3 comments
Closed

🐛 [BUG]EditorFormRef.current?.setRowData方法不生效 #10886

lyck40012 opened this issue Aug 14, 2023 · 3 comments

Comments

@lyck40012
Copy link

🐛 bug 描述

我编辑商品编码的时候,想要设置商品名称的值,目前我发现setRowData是不生效的
{
title: '商品编码',
dataIndex: 'mateSku',
width: 120,
align:"center",
fieldProps: (form, config) => {
return {
options: goodsList,
onChange:(val)=>{
editorFormRef.current?.setRowData?.(config.rowIndex,{
mateSkuName:123123
})
},
}
}
},
{
title: (

<span style={{color: 'red'}}>*商品名称

),
dataIndex: 'mateSkuName',
width: 200,
align:"center",
formItemProps: () => {
return {
rules: [{required: true, message: '此项为必填项'}],
};
},
},

🏞 期望结果 | Expected results

💻 复现代码 | Recurrence code

© 版本信息

"@ant-design/pro-components": "^2.3.57",
"antd": "^5.6.3",

  • umi 4
  • 浏览器环境
  • Chrome

🚑 其他信息

@github-actions
Copy link

当前 Issue 未检测到标题,请规范填写,谢谢!

The title of the current issue is not detected, please fill in according to the specifications, thank you!

@lyck40012 lyck40012 changed the title 🐛 [BUG] 🐛 [BUG]EditorFormRef.current?.setRowData方法不生效 Aug 14, 2023
@markdashi
Copy link

没有解决,为什么关闭呢?

@lyck40012
Copy link
Author

没有解决,为什么关闭呢?
我一共发了两个可能重复了吧

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

No branches or pull requests

2 participants