From 9c95b917de62c2440b55247a97eef5b49ca7e680 Mon Sep 17 00:00:00 2001 From: mertsincan Date: Mon, 8 Jul 2019 14:46:02 +0300 Subject: [PATCH] Month View shows a redundant week on the calendar --- src/components/calendar/Calendar.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/calendar/Calendar.vue b/src/components/calendar/Calendar.vue index 24863a66b..fb8d4520e 100644 --- a/src/components/calendar/Calendar.vue +++ b/src/components/calendar/Calendar.vue @@ -1579,8 +1579,10 @@ export default { let dayNo = 1; let today = new Date(); let weekNumbers = []; + let monthRows = Math.ceil((daysLength + firstDay) / 7); + - for (let i = 0; i < 6; i++) { + for (let i = 0; i < monthRows; i++) { let week = []; if (i == 0) {