Last active
August 29, 2015 14:27
-
-
Save debborafernandess/7f91812f68375391afe9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>> 30.days.from_now | |
=> Sun, 13 Sep 2015 17:39:30 BRT -03:00 | |
>> 30.days.from_now.class | |
=> ActiveSupport::TimeWithZone | |
>> Date.today + 30 | |
=> Sun, 13 Sep 2015 | |
>> (Date.today + 30).class | |
=> Date | |
Beginning of Month | |
>> (Date.today + 30).beginning_of_month | |
=> Tue, 01 Sep 2015 | |
>> 30.days.from_now.beginning_of_month | |
=> Tue, 01 Sep 2015 00:00:00 BRT -03:00 | |
End of Month | |
>> (Date.today + 30).end_of_month | |
=> Wed, 30 Sep 2015 | |
>> 30.days.from_now.end_of_month | |
=> Wed, 30 Sep 2015 23:59:59 BRT -03:00 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment