You signed in with another tab or window.
Reload
to refresh your session.
You signed out in another tab or window.
Reload
to refresh your session.
You switched accounts on another tab or window.
Reload
to refresh your session.
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
I have searched the
issues
of this repository and believe that this is not a duplicate.
What problem does this feature solve?
个人感觉Select的onChange加一个(value,item)比较好 item是是选中项的对象
form提交的时候保存数据要保存选中项的除id外的其他数据,
form提交取值也不用a.b a.c之类
form回显的时候只需要一个value就可以显示默认值,不用拼接对象信息,
What does the proposed API look like?
onChange变成(value,item)和table的全选,单选一样(选中的ID,选中的集合)
list:[{id:1,name:'莉莉',key:'deli',mark:'AD0003'},{id:1,name:'莉莉',key:'deli',mark:'AD0003'}]
onChange(value,item){
*value:1
*item:{id:1,name:'莉莉',key:'deli',mark:'AD0003'}
labelInValue 的使用只有 key 和 value
因为key穿object 并不返回object而是字符串'[object] [object]'
提交的时候需要重新赋值提交(一般提交都是{id:1,name:'222'}而不是id:{key:1,label:'222'})
而且回显的时候需要拼接对象回显
使用并不方便
如果只使用这个key,value 个人感觉目前版本中onChange(value,arr)更便捷
但是这两种方式其他数据获取不到,如果需要其他数据,则还是要循环自取