Closed circlewang closed 5 years ago
如图,点击了回到今天按钮,今天的日期没有被选中,选中状态还停留在上一次点击过得日期,然后打印this.$refs.calendar.setToday()返回undefined,我点击您发的浏览器端,返回今天只会在别的月份返回到今天所在的月份,也不是选中今天,希望可以得到回答
我解决了,利用value来选中今天的日期
setToday 方法只会返回到今日的日期视图,不会修改value,如果要选中需要手动操作
setToday
value
如图,点击了回到今天按钮,今天的日期没有被选中,选中状态还停留在上一次点击过得日期,然后打印this.$refs.calendar.setToday()返回undefined,我点击您发的浏览器端,返回今天只会在别的月份返回到今天所在的月份,也不是选中今天,希望可以得到回答