Class: AlchemyCrm::Admin::NewslettersController

Inherits:
BaseController
  • Object
show all
Defined in:
app/controllers/alchemy_crm/admin/newsletters_controller.rb

Instance Method Summary collapse

Methods included from I18nHelpers

#alchemy_crm_t, #i18n_t, included, #translate_model_attribute

Instance Method Details

#updateObject



8
9
10
11
12
13
# File 'app/controllers/alchemy_crm/admin/newsletters_controller.rb', line 8

def update
  params[:newsletter][:contact_group_ids] ||= []
  @newsletter = Newsletter.find(params[:id])
  @newsletter.update_attributes(params[:newsletter])
  render_errors_or_redirect @newsletter, admin_newsletters_path, alchemy_crm_t(:successfully_updated_newsletter)
end