Sha256: 6f2352b376af0fa8fe1731fd1901664b7338025083de4e3e8db1bb43e2b6c205

Contents?: true

Size: 847 Bytes

Versions: 8

Compression:

Stored size: 847 Bytes

Contents

jQuery ->
  # Some fields should be shown only for blog posts, others only for static content pages
  if $('input#page_for_blog:checked').length>0
    $('#page-short-title').hide()
    $('#parent-page-title').hide()
  else
    $('#page-tag-list').hide()

  # Toggle fields to be shown when user changes page to/from static content to/from blog post
  $("input#page_for_blog").change ->
    if $('input#page_for_blog:checked').length>0
      $('#page-short-title').hide(450)
      $('#parent-page-title').hide(450)
      $('#page-tag-list').show(450)
    else
      $('#page-tag-list').hide(450)
      $('#page-short-title').show(450)
      $('#parent-page-title').show(450)

  # Typeahead form field for autocomplete associations
  $('#page_author_name').typeahead(
    name: 'page_author_name',
    local: $('#page_author_name').data('source') )

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
tkh_admin_panel-0.9.10 app/assets/javascripts/admin/pages.js.coffee
tkh_admin_panel-0.9.9 app/assets/javascripts/admin/pages.js.coffee
tkh_admin_panel-0.9.8 app/assets/javascripts/admin/pages.js.coffee
tkh_admin_panel-0.9.7 app/assets/javascripts/admin/pages.js.coffee
tkh_admin_panel-0.9.6 app/assets/javascripts/admin/pages.js.coffee
tkh_admin_panel-0.9.5 app/assets/javascripts/admin/pages.js.coffee
tkh_admin_panel-0.9.4 app/assets/javascripts/admin/pages.js.coffee
tkh_admin_panel-0.9.3 app/assets/javascripts/admin/pages.js.coffee