Sha256: 9e08613b1b4b4ea208c1912ad85544ef2409d64b45b602227e51faa2cc8cbb6f

Contents?: true

Size: 822 Bytes

Versions: 9

Compression:

Stored size: 822 Bytes

Contents

id = called_from_landing_page? ? "edit_contact" : dom_id(@contact)

if @contact.errors.empty?
  if called_from_landing_page?
    page.call "crm.flip_form", :edit_contact
    page.call "crm.set_title", :edit_contact, @contact.full_name
    page << refresh_sidebar(:show, :summary)
  else
    page[id].replace :partial => "contact", :collection => [ @contact ]
    page[id].visual_effect :highlight, :duration => 1.0
    if called_from_index_page?
      page << refresh_sidebar(:index)
    else
      page[:recently].replace :partial => "shared/recently"
    end
  end
else  
  page[id].replace_html :partial => "edit"
  page.call "crm.create_or_select_account", request.referer =~ /\/accounts\// || @account.id.blank?
  page[id].visual_effect :shake, :duration => 0.25, :distance => 6
  page[:contact_first_name].focus
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
fat_free_crm-0.12.3 app/views/contacts/update.js.rjs
fat_free_crm-0.12.2 app/views/contacts/update.js.rjs
fat_free_crm-0.12.1 app/views/contacts/update.js.rjs
fat_free_crm-0.12.0 app/views/contacts/update.js.rjs
fat_free_crm-0.11.4 app/views/contacts/update.js.rjs
fat_free_crm-0.11.3 app/views/contacts/update.js.rjs
fat_free_crm-0.11.2 app/views/contacts/update.js.rjs
fat_free_crm-0.11.1 app/views/contacts/update.js.rjs
fat_free_crm-0.11.0 app/views/contacts/update.js.rjs