{"action":"created","issue":{"url":"https://api.github.com/repos/patchthecode/JTAppleCalendar/issues/437","repository_url":"https://api.github.com/repos/patchthecode/JTAppleCalendar","labels_url":"https://api.github.com/repos/patchthecode/JTAppleCalendar/issues/437/labels{/name}","comments_url":"https://api.github.com/repos/patchthecode/JTAppleCalendar/issues/437/comments","events_url":"https://api.github.com/repos/patchthecode/JTAppleCalendar/issues/437/events","html_url":"https://github.com/patchthecode/JTAppleCalendar/issues/437","id":233482859,"number":437,"title":"Selecting dates on 7.0.3","user":{"login":"bigfish2001","id":16386582,"avatar_url":"https://avatars1.githubusercontent.com/u/16386582?v=3","gravatar_id":"","url":"https://api.github.com/users/bigfish2001","html_url":"https://github.com/bigfish2001","followers_url":"https://api.github.com/users/bigfish2001/followers","following_url":"https://api.github.com/users/bigfish2001/following{/other_user}","gists_url":"https://api.github.com/users/bigfish2001/gists{/gist_id}","starred_url":"https://api.github.com/users/bigfish2001/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bigfish2001/subscriptions","organizations_url":"https://api.github.com/users/bigfish2001/orgs","repos_url":"https://api.github.com/users/bigfish2001/repos","events_url":"https://api.github.com/users/bigfish2001/events{/privacy}","received_events_url":"https://api.github.com/users/bigfish2001/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2017-06-05T02:58:21Z","updated_at":"2017-06-05T15:01:37Z","closed_at":null,"body":"Love this library, so much better than using Date Picker.  Wondered if there are any breaking changes from 7.0.2 to 7.0.3.  I had some code in viewDidLoad to select initial dates on the calendar that works fine in 7.0.2, but does not select anything in 7.0.3.\r\n\r\nHere is the code:\r\n```swift\r\n    override func viewDidLoad() {\r\n        super.viewDidLoad()\r\n        if let season = season {\r\n            seasonNameTextField.text = season.desc\r\n            selection = .end\r\n            selectionInstructions.text = \"Select the end date\"\r\n        }\r\n\r\n        monthLabel.alpha = 0.0\r\n        selectedDateLabel.text = \"\"\r\n        setupCalendarView()\r\n\r\n        if let season = season {\r\n            calendarView.selectDates(from: season.startDate, to: season.endDate, triggerSelectionDelegate: false, keepSelectionIfMultiSelectionAllowed: false)\r\n        }\r\n\r\n    }\r\n\r\n    func setupCalendarView() {\r\n        calendarView.minimumLineSpacing = 0\r\n        calendarView.minimumInteritemSpacing = 0\r\n        calendarView.contentInset = UIEdgeInsets(top: 0, left: 0, bottom: 0, right: 0)\r\n        calendarView.isRangeSelectionUsed = true\r\n        calendarView.allowsMultipleSelection = true\r\n        calendarView.visibleDates { (visibleDates) in\r\n            self.setupCalendarLabels(visibleDates: visibleDates)\r\n            self.updateSelectedDateLabel()\r\n            if self.selection == .end {\r\n                self.calendarView.scrollToDate(self.season?.endDate ?? Date())\r\n            } else {\r\n                self.calendarView.scrollToDate(Date())\r\n            }\r\n        }\r\n    }\r\n```\r\n\r\nThanks,\r\nBruce\r\n"},"comment":{"url":"https://api.github.com/repos/patchthecode/JTAppleCalendar/issues/comments/306210602","html_url":"https://github.com/patchthecode/JTAppleCalendar/issues/437#issuecomment-306210602","issue_url":"https://api.github.com/repos/patchthecode/JTAppleCalendar/issues/437","id":306210602,"user":{"login":"patchthecode","id":2439146,"avatar_url":"https://avatars3.githubusercontent.com/u/2439146?v=3","gravatar_id":"","url":"https://api.github.com/users/patchthecode","html_url":"https://github.com/patchthecode","followers_url":"https://api.github.com/users/patchthecode/followers","following_url":"https://api.github.com/users/patchthecode/following{/other_user}","gists_url":"https://api.github.com/users/patchthecode/gists{/gist_id}","starred_url":"https://api.github.com/users/patchthecode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/patchthecode/subscriptions","organizations_url":"https://api.github.com/users/patchthecode/orgs","repos_url":"https://api.github.com/users/patchthecode/repos","events_url":"https://api.github.com/users/patchthecode/events{/privacy}","received_events_url":"https://api.github.com/users/patchthecode/received_events","type":"User","site_admin":false},"created_at":"2017-06-05T15:01:37Z","updated_at":"2017-06-05T15:01:37Z","body":"hmm. Selection works on my sample app.\r\nCan you let me know if you have implemented the function `shouldSelectDate` ?\r\n\r\nThis upgrade has been made in version 7.0.3\r\nThe `shouldSelectDate` funciton is now called with programmatic selection. This was not being done before."}}
{"actor":{"display_login":"patchthecode"}}