Skip to content

Commit

Permalink
feat: 默认时间调整成 00:00:00
Browse files Browse the repository at this point in the history
  • Loading branch information
honkinglin committed Sep 13, 2022
1 parent 1706a76 commit 2b2fb7e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/date-picker/DatePicker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ export default defineComponent({
watch(popupVisible, (visible) => {
// 面板展开重置数据
if (visible) {
year.value = parseToDayjs(value.value || new Date(), formatRef.value.format).year();
month.value = parseToDayjs(value.value || new Date(), formatRef.value.format).month();
time.value = formatTime(value.value || new Date(), formatRef.value.timeFormat);
year.value = parseToDayjs(value.value, formatRef.value.format).year();
month.value = parseToDayjs(value.value, formatRef.value.format).month();
time.value = formatTime(value.value, formatRef.value.timeFormat);
if (value.value) {
cacheValue.value = formatDate(value.value, {
format: formatRef.value.format,
Expand Down

0 comments on commit 2b2fb7e

Please sign in to comment.