We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
v2.8.18
table有一栏是date数据,用radio来控制是否可以编辑,初始页面没有checked的时候,date栏位是受控的,没有弹出laydate,当选中某一行radio的时候,对应栏位可以弹出laydate,但是之后再选中其它行的时候,之前选中过的也可以弹出,并不受radio控制,跟踪了代码走向,前面的控制都是受控的,没有走到,直接跑进laydate.render里了。
table.on('tool(table)', function(obj) { if (checked_id == obj.data.oid) { table_on_tool(obj, that); } }); table.on('radio(table)', function(obj) { checked_id = obj.data.oid; }); function table_on_tool(obj, that) { let layEvent = obj.event; let data = obj.data; let field = $(that).data('field'); //这里加log,也没执行到 if (layEvent === 'updateDate') { laydate.render({ elem: that.firstChild, show: true, closeStop: that, calendar: true, value: data[field], done: function(value, date, endDate) { //这里加log,修改日期会跑到 data[field] = value; obj.update(data); let updateItem = field, updateValue = data[field]; update_data(table, updateItem, updateValue, obj); } }); } }
Chrome 120.0.6099.129
No response
The text was updated successfully, but these errors were encountered:
在 radio 事件中,使用 laydate.unbind(id) 解绑非选中项实例。或者给非选中项设置禁用状态。
Sorry, something went wrong.
@len200 你好,Issue 只接受「Bug 报告」和「功能请求」,而你的议题涉及到如何使用、功能疑惑或其他业务相关的问题,这并不适合作为 Issue 讨论。建议你通过以下方式寻求解决方案:
详见:🍀 Layui Issue 贡献指南
No branches or pull requests
议题条件
议题类型
疑是 BUG
使用版本
v2.8.18
问题描述
table有一栏是date数据,用radio来控制是否可以编辑,初始页面没有checked的时候,date栏位是受控的,没有弹出laydate,当选中某一行radio的时候,对应栏位可以弹出laydate,但是之后再选中其它行的时候,之前选中过的也可以弹出,并不受radio控制,跟踪了代码走向,前面的控制都是受控的,没有走到,直接跑进laydate.render里了。
业务代码
截图补充
浏览器
Chrome 120.0.6099.129
演示地址
No response
友好承诺
The text was updated successfully, but these errors were encountered: