Sha256: 35d1ac260fe374c8c47662f29403852e050e5c7167641d3bb37c79b086fcc481

Contents?: true

Size: 626 Bytes

Versions: 4

Compression:

Stored size: 626 Bytes

Contents

@Ants ||= {}

Ants.redirectsConfig = ->
  showWithParent: true

  onViewShow: (view) ->
    if view.object
      view.$linkBtn =$ "<a href='#{ view.object.path_from }' class='link open' target='_blank'>Open</a>"
      view.$header.append view.$linkBtn

  arrayStore: new RailsArrayStore({
    resource:    'redirect'
    path:        '/admin/redirects'
    sortBy:      'path_from'
    searchable:  true
  })

  formSchema:
    path_from: { type: 'string', label: 'From', placeholder: '/redirect-from-path', required: true }
    path_to:   { type: 'url',    label: 'To',   placeholder: '/redirect-to-path',   required: true }

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
ants-0.2.2 app/assets/javascripts/chr/redirects.coffee
ants-0.2.1 app/assets/javascripts/chr/redirects.coffee
ants-0.2.0 app/assets/javascripts/chr/redirects.coffee
ants-0.1.4 app/assets/javascripts/chr/redirects.coffee