Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

fix(SlideBox): Fix the slide box sometimes opening the wrong cell.

  • Loading branch information...
Matt Lewis
Matt Lewis committed Nov 23, 2015
1 parent 0b91ed7 commit aa7bcba91f65f5057857d15701bcf83a1ac7dc0f
Showing with 4 additions and 4 deletions.
  1. +2 −2 src/directives/mwlCalendarMonth.js
  2. +2 −2 src/directives/mwlCalendarYear.js
@@ -21,8 +21,8 @@ angular
}

//Auto open the calendar to the current day if set
vm.openDayIndex = null;
if (vm.cellIsOpen) {
if (vm.cellIsOpen && !vm.openRowIndex) {
vm.openDayIndex = null;
vm.view.forEach(function(day) {
if (day.inMonth && moment(vm.currentDay).startOf('day').isSame(day.date)) {
vm.dayClicked(day, true);
@@ -12,8 +12,8 @@ angular
vm.view = calendarHelper.getYearView(vm.events, vm.currentDay, vm.cellModifier);

//Auto open the calendar to the current day if set
vm.openMonthIndex = null;
if (vm.cellIsOpen) {
if (vm.cellIsOpen && !vm.openMonthIndex) {
vm.openMonthIndex = null;
vm.view.forEach(function(month) {
if (moment(vm.currentDay).startOf('month').isSame(month.date)) {
vm.monthClicked(month, true);

0 comments on commit aa7bcba

Please sign in to comment.
You can’t perform that action at this time.