✨(component): release 1.4.4
This commit is contained in:
parent
0b05559d87
commit
98c4327000
@ -294,11 +294,20 @@ watch(
|
||||
if (unWatch) {
|
||||
return;
|
||||
}
|
||||
let initModelValue = props.range && props.modelValue ? (props.modelValue as string[])[0] || "" : (props.modelValue as string);
|
||||
let initModelValue =
|
||||
props.range && props.modelValue
|
||||
? (props.modelValue as string[])[0] || ""
|
||||
: (props.modelValue as string);
|
||||
|
||||
hms.value.hh = isNaN(dayjs(initModelValue).hour()) ? 0 : dayjs(initModelValue).hour();
|
||||
hms.value.mm = isNaN(dayjs(initModelValue).minute()) ? 0 : dayjs(initModelValue).minute();
|
||||
hms.value.ss = isNaN(dayjs(initModelValue).second()) ? 0 : dayjs(initModelValue).second();
|
||||
hms.value.hh = isNaN(dayjs(initModelValue).hour())
|
||||
? 0
|
||||
: dayjs(initModelValue).hour();
|
||||
hms.value.mm = isNaN(dayjs(initModelValue).minute())
|
||||
? 0
|
||||
: dayjs(initModelValue).minute();
|
||||
hms.value.ss = isNaN(dayjs(initModelValue).second())
|
||||
? 0
|
||||
: dayjs(initModelValue).second();
|
||||
|
||||
if (initModelValue.length === 8 && props.type === "time") {
|
||||
let modelValue = initModelValue;
|
||||
|
Loading…
Reference in New Issue
Block a user