Fix for link in ad banner
This commit is contained in:
parent
92f3be3200
commit
a7d1cdbb75
|
@ -2,8 +2,8 @@ module FrontHelper
|
|||
|
||||
def ad_image_link(ad_image)
|
||||
link = ad_image.out_link
|
||||
link =front_show_inner_ad_image_path(:id=> ad_image.id) if link.blank? && !ad_image.context.blank?
|
||||
|
||||
link = front_show_inner_ad_image_path(:id=> ad_image.id) if link.blank? && !ad_image.context.blank?
|
||||
link
|
||||
end
|
||||
|
||||
end
|
|
@ -19,7 +19,7 @@
|
|||
<div id='slideshow-<%= @ad_banner.title.dehumanize %>' class='slideshow'>
|
||||
<% (images = @ad_banner.ad_images).shuffle.each do |ad_image| %>
|
||||
<% if ad_image.display? %>
|
||||
<img src='<%= ad_image.file %>' alt='<%= ad_image.title || ' ' %>' title='<%= ad_image.title || ' ' %>' time_to_next='<%= @ad_banner.transition_msec %>' link_open='<%= ad_image.link_open %>' link_url='<%= ad_image_link(ad_image)%>' style=' <%= 'cursor:pointer;' if !ad_image.out_link.blank? %>'/>
|
||||
<img src='<%= ad_image.file %>' alt='<%= ad_image.title || ' ' %>' title='<%= ad_image.title || ' ' %>' time_to_next='<%= @ad_banner.transition_msec %>' link_open='<%= ad_image.link_open %>' link_url='<%= ad_image_link(ad_image) %>' style=' <%= 'cursor:pointer;' if !ad_image_link(ad_image).blank? %>'/>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue