僅對Rails [Date, Time]擴展顯示功能
Add this line to your application's Gemfile:
gem 'roc_date_convert', :git => 'https://github.com/twbcs/roc_date_convert.git', :branch => 'master'
And then execute:
$ bundle
instance method
Date roc_date "105年12月8日"
Time roc_date "105年12月8日"
roc_time "105年12月8日 11:55"
ex:
a = Time.new
a.roc_date => "105年12月8日"
a.roc_date("民國") => "民國105年12月8日"
Bug reports and pull requests are welcome on GitHub at https://github.com/twbcs/roc_date_convert.
The gem is available as open source under the terms of the MIT License.