Sha256: cb6cb3a546eff8a4933aaa17ea502b76bbaf65c2054a420f6b088e29499a8c25

Contents?: true

Size: 1.4 KB

Versions: 15

Compression:

Stored size: 1.4 KB

Contents

# == Schema Information
#
# Table name: users
#
#  id                  :integer         not null, primary key
#  login               :string(255)
#  email               :string(255)
#  first_name          :string(255)
#  last_name           :string(255)
#  crypted_password    :string(255)
#  password_salt       :string(255)
#  persistence_token   :string(255)     not null
#  single_access_token :string(255)     not null
#  perishable_token    :string(255)     not null
#  login_count         :integer         default(0), not null
#  failed_login_count  :integer         default(0), not null
#  last_request_at     :datetime
#  current_login_at    :datetime
#  last_login_at       :datetime
#  current_login_ip    :string(255)
#  last_login_ip       :string(255)
#  terms_of_service    :boolean         not null
#  time_zone           :string(255)     default("UTC")
#  disabled_at         :datetime
#  created_at          :datetime
#  activated_at        :datetime
#  updated_at          :datetime
#  identity_url        :string(255)
#  url_key             :string(255)
#

class User < ActiveRecord::Base
  acts_as_authentic do |c|
    c.crypto_provider = Authlogic::CryptoProviders::BCrypt
  end
  acts_as_muck_user
  has_activities
  has_many :uploads, :as => :uploadable, :order => 'created_at desc', :dependent => :destroy 
  
  def can_add_root_content?
    admin?
  end
  
  def can_upload?(check_user)
    true
  end
  
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
muck-contents-0.2.27 test/rails_root/app/models/user.rb
muck-contents-0.2.26 test/rails_root/app/models/user.rb
muck-contents-0.2.25 test/rails_root/app/models/user.rb
muck-contents-0.2.24 test/rails_root/app/models/user.rb
muck-contents-0.2.23 test/rails_root/app/models/user.rb
muck-contents-0.2.22 test/rails_root/app/models/user.rb
muck-contents-0.2.21 test/rails_root/app/models/user.rb
muck-contents-0.2.20 test/rails_root/app/models/user.rb
muck-contents-0.2.18 test/rails_root/app/models/user.rb
muck-contents-0.2.17 test/rails_root/app/models/user.rb
muck-contents-0.2.16 test/rails_root/app/models/user.rb
muck-contents-0.2.15 test/rails_root/app/models/user.rb
muck-contents-0.2.14 test/rails_root/app/models/user.rb
muck-contents-0.2.13 test/rails_root/app/models/user.rb
muck-contents-0.2.12 test/rails_root/app/models/user.rb