# Controller to direct to basic pages
class PagesController < ApplicationController
  def home
    @last_sermon = Sermon.last
    @last_newsletter = Newsletter.last
    @upcoming_events = Event.upcoming
  end

  def beliefs
    @title = 'Beliefs'
  end

  def history
    @title = 'History'
  end

  def contact
    @title = 'Contact'
  end

  def letsencrypt
    render text: "#{params[:id]}.8irEjcOIniTce4WuxcUwZtD9I8faf7-2HkDE5UsG6UM"
  end
end

# Controller to direct to basic pages
class PagesController < ApplicationController
  def home
    @last_sermon = Sermon.last
    @last_newsletter = Newsletter.last
    @upcoming_events = Event.upcoming

    flash[:warning] = "To protect the health of our members and the public during the pandemic, " + 
                      "we are cancelling normal services. However, you can continue to worship "  +
                      "with us: on Sunday morning at 11AM each week, we will stream service on Facebook Live."
  end

  def beliefs
    @title = 'Beliefs'
  end

  def history
    @title = 'History'
  end

  def contact
    @title = 'Contact'
  end

  def letsencrypt
    render text: "#{params[:id]}.8irEjcOIniTce4WuxcUwZtD9I8faf7-2HkDE5UsG6UM"
  end
end

Add Covid-19 announcement in flash message to home
Add Covid-19 announcement in flash message to home

Need to go ahead and put this announcement in place for now. Later, this should be made into generic functionality: add a section to admin page to create/update announcements.
