vue-vben-admin
vue-vben-admin copied to clipboard
perf(util): remove handleInputNumberValue
fix:https://github.com/vbenjs/vue-vben-admin/issues/3805
General
✏️ Mark the necessary items without changing the structure of the PR template.
- [x] Pull request template structure not broken
Pull request template structure not broken
历史遗留问题
当初这个函数的提出是为了解决这个默认值的bug( https://github.com/vbenjs/vue-vben-admin/issues/3274 ),但是默认值的问题没有彻底解决
直到 https://github.com/vbenjs/vue-vben-admin/pull/3287 之后才把这个问题大体解决了(定位问题是在isEmpty的使用上面,而跟这个函数没有什么关系)。这时handleInputNumberValue这个函数不仅没发挥到应有的作用,并且导致了input系列组件输入输出类型不一致的问题 。例如输入number,string,其他的数据都会变成string
最近 https://github.com/vbenjs/vue-vben-admin/pull/3802 pr提过之后,目前的行为是 number变成number,然后其他的都变成string,但是仍然导致了 null 和 undefined等其他类型 会被设置成 string类型。
看下ci 有类型问题
看下ci 有类型问题
okok,已解决