fix broken ad_banner

This commit is contained in:
Matthew K. Fu JuYuan 2012-05-01 18:23:42 +08:00
parent 7a5d3ecae3
commit de457e7dfc
2 changed files with 2 additions and 2 deletions

View File

@ -15,7 +15,7 @@
<div class="adbanner-list">
<div class="adbanner-action">
<%= 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.title) , :class=>'preview_trigger btn btn-success'%>
<%= link_to t("modal.preview"), admin_realtime_preview_ad_banner_path(ad_banner_tab.id) , :class=>'preview_trigger btn btn-success'%>
</div>
<ul class="clear">
<%= render :partial => "ad_image_update", :collection => ad_banner_tab.ad_images,:as => :ad_image,:locals=>{:ad_banner => ad_banner_tab} %>

View File

@ -25,7 +25,7 @@ Orbit::Application.routes.draw do
end
match 'ad_banner/:id/preview' => 'ad_banners#realtime_preview',:as => :realtime_preview_ad_banner,:via => :put
match 'ad_banners/:id/preview' => 'ad_banners#realtime_preview',:as => :realtime_preview_ad_banner,:via => :put
resources :ad_banners do
collection do
match 'new_ad_image' => 'ad_images#new',:as => :new_ad_image,:via => :get