Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在 time_tag 中,我想显示时间的上午或下午。如何自定义助手。由于默认时间标签显示为2012 年 4 月 15 日 10:55
%p 是显示 AM/PM 的格式标记
time_tag(time, :format=>'%B %d, %Y %l:%M %p')