diff --git a/app/assets/javascripts/ad_banner.js b/app/assets/javascripts/ad_banner.js index bab55a67..57176a1c 100644 --- a/app/assets/javascripts/ad_banner.js +++ b/app/assets/javascripts/ad_banner.js @@ -15,4 +15,4 @@ $('a.remove_mark').live("click",function(){ $(this).next().remove(); $(this).remove(); return false; -}); +}); \ No newline at end of file diff --git a/app/models/ad_banner.rb b/app/models/ad_banner.rb index e7bffea4..368c7081 100644 --- a/app/models/ad_banner.rb +++ b/app/models/ad_banner.rb @@ -16,15 +16,6 @@ class AdBanner embeds_many :ad_images, :cascade_callbacks => true - FX_TYPES = ["blindX","blindY","blindZ","cover","curtainX","curtainY","fade","fadeZoom","growX","growY","scrollUp","scrollDown","scrollLeft","scrollRight","scrollHorz","scrollVert","shuffle","slideX","slideY","toss","turnUp","turnDown","turnLeft","turnRight","uncover","wipe","zoom"] - - def display? - if (self.post_date <= Date.today && (self.unpost_date.nil? || self.unpost_date>= Date.today)) - return true - end - return false - end - def new_ad_images=(*attrs) attrs[0].each do |attr| #Loop by JSs,Themes,Imgs unless attr[:file].nil? diff --git a/app/models/ad_image.rb b/app/models/ad_image.rb index 308ae3ac..dc8eab8b 100644 --- a/app/models/ad_image.rb +++ b/app/models/ad_image.rb @@ -13,13 +13,4 @@ class AdImage embedded_in :ad_banner - def get_delay_time - time = '' - if self.time_to_next.nil? - time = '1000' - else - time = (self.time_to_next.to_i * 1000).to_s - end - time - end end diff --git a/app/views/admin/ad_banners/_form.html.erb b/app/views/admin/ad_banners/_form.html.erb index 2c42fa3b..ff19e513 100644 --- a/app/views/admin/ad_banners/_form.html.erb +++ b/app/views/admin/ad_banners/_form.html.erb @@ -24,7 +24,6 @@ <%= f.label :unpost_date, t('admin.unpost_date') %> <%= f.date_select :unpost_date, :order => [:year, :month, :day], :use_month_numbers => true %> - <%= f.date_select :unpost_date, :order => [:year, :month, :day], :use_month_numbers => true,:prompt => { :day => t('form.date_unlimited'), :month => t('form.date_unlimited'), :year => t('form.date_unlimited') } %>
<%= f.label :context, t('admin.context') %> diff --git a/app/views/admin/ad_banners/index.html.erb b/app/views/admin/ad_banners/index.html.erb index 30683cda..54217140 100644 --- a/app/views/admin/ad_banners/index.html.erb +++ b/app/views/admin/ad_banners/index.html.erb @@ -20,7 +20,6 @@