2012-04-25 09:17:04 +00:00
|
|
|
|
<div class="tab-pane fade <%= "active in" if ad_banner_tab==@active%>" id=<%= ad_banner_tab.title.dehumanize %>>
|
2012-05-15 08:39:23 +00:00
|
|
|
|
<% if at_least_module_manager || sub_manager?(ad_banner_tab)%>
|
2012-04-01 15:39:49 +00:00
|
|
|
|
<%= form_for ad_banner_tab,:url=> admin_ad_banner_path(ad_banner_tab),:method => :put,:class=>"input-medium" do |f| -%>
|
2012-04-25 08:26:27 +00:00
|
|
|
|
<div class="adbanner-setup well">
|
|
|
|
|
<!--<p><%#= t("admin.ad.banner_best_size") %>:</p>-->
|
|
|
|
|
<%= f.label :ad_fx, t('admin.ad.ab_fx') %>
|
|
|
|
|
<%= f.select :ad_fx ,AdBanner::FX_TYPES %>
|
|
|
|
|
<%= f.label :transition_sec, t('admin.ad.transition_sec') %>
|
2012-04-25 08:39:26 +00:00
|
|
|
|
<%= f.text_field :transition_sec,:placeholder=>t('admin.ad.sec_place_holder'),:class=> "span3" %> <%= t("admin.ad.trans_unit_sec") %>
|
2012-05-18 02:50:53 +00:00
|
|
|
|
<%if at_least_module_manager%>
|
|
|
|
|
<%= f.label :best_size, t('admin.ad.best_size') %>
|
|
|
|
|
<%= f.text_field :best_size %> Ex: 500px x 300px
|
|
|
|
|
<% end -%>
|
2012-04-25 08:26:27 +00:00
|
|
|
|
<br>
|
|
|
|
|
<%= f.submit t("admin.ad.update_banner"), :class => 'btn' %>
|
|
|
|
|
<%= f.submit t("cancel"),:type=>'reset', :class => 'btn' %>
|
|
|
|
|
</div>
|
2012-05-15 08:39:23 +00:00
|
|
|
|
<% end -%>
|
|
|
|
|
<% end -%>
|
|
|
|
|
<h3><%= t("admin.ad.picture_list")%></h3>
|
2012-04-25 08:26:27 +00:00
|
|
|
|
<div class="adbanner-list">
|
2012-05-15 10:55:16 +00:00
|
|
|
|
<%if (at_least_module_manager || ad_banner_tab.cur_user_is_sub_manager_of(:edit) )%>
|
2012-05-15 08:39:23 +00:00
|
|
|
|
<%= content_tag :div ,:class=>'adbanner-action' do%>
|
|
|
|
|
<%= link_to t("admin.ad.new_image"),new_admin_ad_banner_ad_image_path(ad_banner_tab) ,:class => "btn btn-primary"%>
|
|
|
|
|
<%= link_to t("modal.preview"), admin_realtime_preview_ad_banner_path(ad_banner_tab.id) , :class=>'preview_trigger btn btn-success'%>
|
|
|
|
|
<% end -%>
|
|
|
|
|
<% end -%>
|
2012-04-25 08:26:27 +00:00
|
|
|
|
<ul class="clear">
|
|
|
|
|
<%= render :partial => "ad_image_update", :collection => ad_banner_tab.ad_images,:as => :ad_image,:locals=>{:ad_banner => ad_banner_tab} %>
|
|
|
|
|
</ul>
|
2012-05-15 08:39:23 +00:00
|
|
|
|
<% if at_least_module_manager %>
|
2012-05-15 01:57:05 +00:00
|
|
|
|
<%= show_ad_banner_permission_link ad_banner_tab%>
|
2012-05-16 08:42:43 +00:00
|
|
|
|
<%= link_to t('admin.ad.delete_banner'),admin_ad_banner_path(ad_banner_tab),:class => 'btn',:method => :delete,:confirm => t('sure?') %>
|
2012-05-15 01:57:05 +00:00
|
|
|
|
<% end -%>
|
2012-05-16 08:42:43 +00:00
|
|
|
|
|
2012-04-25 08:26:27 +00:00
|
|
|
|
<%#= render :partial => 'new_add_banner_file', :object => ad_banner_tab.ad_images.build, :locals => { :field_name => "new_ad_images[]", :f => f, :classes => "r_destroy" } %>
|
2012-04-23 18:37:51 +00:00
|
|
|
|
</div>
|
2012-04-17 03:34:25 +00:00
|
|
|
|
<%#= render :partial => 'preview_block',:locals=> {:ad_banner =>ad_banner_tab} %>
|
2012-04-01 15:39:49 +00:00
|
|
|
|
</div>
|