Sha256: bfc7284eaaa6fb8903f9986f28a34b5952610cc519e4b8408126d1f6a2b509cb

Contents?: true

Size: 567 Bytes

Versions: 9

Compression:

Stored size: 567 Bytes

Contents

namespace :fae do
  desc "Seeds the parent app with Fae's defaults"
  task :seed_db => :environment do
    if Fae::Role.first.blank?
      Fae::Role.create(name: 'super admin', position: 0)
      Fae::Role.create(name: 'admin', position: 1)
      Fae::Role.create(name: 'user', position: 2)
    end

    if Fae::Option.first.blank?
      option = Fae::Option.new({
        title: 'My FINE Admin',
        singleton_guard: 0,
        time_zone: 'Pacific Time (US & Canada)',
        live_url: 'http://www.wearefine.com'
        })
      option.save!
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
fae-rails-1.6.0 spec/dummy/lib/tasks/fae_tasks.rake
fae-rails-1.5.1 spec/dummy/lib/tasks/fae_tasks.rake
fae-rails-1.5.0 spec/dummy/lib/tasks/fae_tasks.rake
fae-rails-1.4.1 spec/dummy/lib/tasks/fae_tasks.rake
fae-rails-1.4.0 spec/dummy/lib/tasks/fae_tasks.rake
fae-rails-1.3.1 spec/dummy/lib/tasks/fae_tasks.rake
fae-rails-1.3.0 spec/dummy/lib/tasks/fae_tasks.rake
fae-rails-1.2.5 spec/dummy/lib/tasks/fae_tasks.rake
fae-rails-1.2.4 spec/dummy/lib/tasks/fae_tasks.rake