Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update directive.js #13

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Update directive.js #13

wants to merge 2 commits into from

Conversation

NobleMule
Copy link

Return the custom date object rather than a javascript date object in the checkDate function. Add months in order rather than reversed. Update the original model on date change. Allow for a calculation in the "startYear" attribute.

My Angular skills are limited as I am new to this but the fixes implemented resolve my personal needs - maybe someone smarter can fix this properly.

There is also a bug on line 38 where "!date.month" will evaluate to true in the event that month is 0 (which it will be if January is selected) and that will cause the checkDate function to return false. I will resolve this shortly.

Return the custom date object rather than a javascript date object in the checkDate function. Add months in order rather than reversed. Update the original model on date change. Allow for a calculation in the "startYear" attribute.

My Angular skills are limited as I am new to this but the fixes implemented resolve my personal needs - maybe someone smarter can fix this properly.

There is also a bug on line 38 where "!date.month" will evaluate to true in the event that month is 0 (which it will be if January is selected) and that will cause the checkDate function to return false. I will resolve this shortly.
Additional update to fix checkDate bug where January would return an invalid date
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant