mirror of
https://gitee.com/vant-contrib/vant-weapp.git
synced 2025-04-06 03:58:05 +08:00
fix(datetime-picker): 修复year-month 选择字段校验报错 (#3783)
This commit is contained in:
parent
166ba61c0f
commit
c254b3d073
@ -27,6 +27,9 @@ function times(n: number, iteratee: (index: number) => string): string[] {
|
||||
}
|
||||
|
||||
function getTrueValue(formattedValue: string) {
|
||||
if (formattedValue === undefined) {
|
||||
formattedValue = '1';
|
||||
}
|
||||
while (isNaN(parseInt(formattedValue, 10))) {
|
||||
formattedValue = formattedValue.slice(1);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user