ActionController::Dispatcher.to_prepare do
  
  # Extend :account model to add :issues association.
  Account.send(:include, AccountServiceRequestAssociations)

  # Make issues observable.
  ActivityObserver.instance.send :add_observer!, ServiceRequest

  # Add :issues plugin helpers.
  ActionView::Base.send(:include, ServiceRequestsHelper)

end

# Make the issues commentable.
CommentsController.commentables = CommentsController.commentables + %w(service_request_id)