Sha256: 8fee59006127b3109b8c6a219bdd28b0896317c47adb63d2e2db834590ee0ed4

Contents?: true

Size: 1.39 KB

Versions: 15

Compression:

Stored size: 1.39 KB

Contents

- content_for :main do 

  %h1.ads_icon Advertisment Dashboard

  #preview(style="width: 730px; height: 600px; overflow: hidden; border: thin #AAA solid; text-align: center;")
    Ad Preview

  %h3 Unapproved Ads
  %table.loosen
    %tr
      %th Name
      %th User
      %th Zones
      %th Start
      %th End
      %th Paid
      %th Approve

    - @ads.each do |ad|
      %tr(class="ad_details" rel="#{ad.id}")
        %td
          = link_to ad.name, [:admin, ad]
          %div(id="preview_#{ad.id}" style="display: none;")
            = kit_ad(ad.id)
        %td= link_to truncate(ad.user.email, :length=>30), "/admin/user/#{ad.user_id}"
        %td= ad.ad_zones.collect { |zone| link_to zone.name, [:admin, zone] }.join(',').html_safe
        %td= ad.start_date.to_formatted_s(:short)
        %td= ad.end_date.to_formatted_s(:short)
        %td= ad.paid_at.to_formatted_s(:short) if ad.paid_at
        %td= link_to "Approve", "/admin/ad/#{ad.id}/activate/approve", :class=>"action", :method=>:post if ad.approved_by_id == nil
  .field_help
    Hover for preview

  %h3 Setup
  = icon_to "Ad Units", "/admin/ad_units"
  →
  = icon_to "Ad Zones", "/admin/ad_zones"
  →
  = icon_to "Ads", "/admin/ads"

  %script(type='text/javascript')
    $(document).ready(function() {
    $(".ad_details").on('mouseenter', function() {
    $('#preview').html($('#preview_' + $(this).attr('rel')).html()); 
    });
    });

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
kit_cms-2.3.22 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.20 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.19 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.18 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.17 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.16 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.15 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.14 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.13 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.11 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.10 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.9 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.8 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.7 app/views/admin/advertisments/index.html.haml
kit_cms-2.3.6 app/views/admin/advertisments/index.html.haml