Module: FrenchToast::Helper
- Defined in:
- app/helpers/french_toast/helper.rb
Instance Method Summary collapse
- #french_toast ⇒ Object
- #french_toast_content ⇒ Object
- #french_toast_content? ⇒ Boolean
- #french_toast_notification ⇒ Object
Instance Method Details
#french_toast ⇒ Object
3 4 5 |
# File 'app/helpers/french_toast/helper.rb', line 3 def french_toast render "application/french_toast_template" end |
#french_toast_content ⇒ Object
18 19 20 |
# File 'app/helpers/french_toast/helper.rb', line 18 def french_toast_content french_toast_notification.data end |
#french_toast_content? ⇒ Boolean
14 15 16 |
# File 'app/helpers/french_toast/helper.rb', line 14 def french_toast_content? french_toast_notification.data? end |
#french_toast_notification ⇒ Object
7 8 9 10 11 12 |
# File 'app/helpers/french_toast/helper.rb', line 7 def french_toast_notification @french_toast_notification ||= FrenchToast::LastNotification.find_or_create_by( session: [:key], ).tap(&:destroy) end |