Sha256: b158092526e81c246e5ae3e373ca1e63b6d50edf2453425385229a7b6703e972

Contents?: true

Size: 356 Bytes

Versions: 18

Compression:

Stored size: 356 Bytes

Contents

namespace :concen do
  namespace :page do
    desc "Reset publish_month for all the pages. Should be used when time zone is changed."
    task :reset_publish_month => :environment do
      Time.zone = Rails::Application.config.time_zone
      for page in Concen::Page.all
        page.send(:set_publish_month)
        page.save
      end
    end
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
concen-0.2.9 lib/concen/railties/page.rake
concen-0.2.8 lib/concen/railties/page.rake
concen-0.2.7 lib/concen/railties/page.rake
concen-0.2.6 lib/concen/railties/page.rake
concen-0.2.5 lib/concen/railties/page.rake
concen-0.2.4 lib/concen/railties/page.rake
concen-0.2.3 lib/concen/railties/page.rake
concen-0.2.2 lib/concen/railties/page.rake
concen-0.2.1 lib/concen/railties/page.rake
concen-0.2.0 lib/concen/railties/page.rake
concen-0.1.7 lib/concen/railties/page.rake
concen-0.1.6 lib/concen/railties/page.rake
concen-0.1.5 lib/concen/railties/page.rake
concen-0.1.4 lib/concen/railties/page.rake
concen-0.1.3 lib/concen/railties/page.rake
concen-0.1.2 lib/concen/railties/page.rake
concen-0.1.1 lib/concen/railties/page.rake
concen-0.1 lib/concen/railties/page.rake