Sha256: 43dd8cd6b1455a3f8cc288ec455a6820e52785f0de9cdf3d0831f6ea6bda2b78

Contents?: true

Size: 219 Bytes

Versions: 15

Compression:

Stored size: 219 Bytes

Contents

class User
  include Mongoid::Document
  extend WulffeldSlug::Slug

  field :login
  field :name

  has_slug :slug_fields, :mongo => true, :case => :preserve
  
  def slug_fields
    [ self.login, self.name ]
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
wulffeld_slug-0.0.29 spec/app/models/user.rb
wulffeld_slug-0.0.28 spec/app/models/user.rb
wulffeld_slug-0.0.27 spec/app/models/user.rb
wulffeld_slug-0.0.26 spec/app/models/user.rb
wulffeld_slug-0.0.25 spec/app/models/user.rb
wulffeld_slug-0.0.24 spec/app/models/user.rb
wulffeld_slug-0.0.23 spec/app/models/user.rb
wulffeld_slug-0.0.22 spec/app/models/user.rb
wulffeld_slug-0.0.21 spec/app/models/user.rb
wulffeld_slug-0.0.20 spec/app/models/user.rb
wulffeld_slug-0.0.19 spec/app/models/user.rb
wulffeld_slug-0.0.18 spec/app/models/user.rb
wulffeld_slug-0.0.17 spec/app/models/user.rb
wulffeld_slug-0.0.16 spec/app/models/user.rb
wulffeld_slug-0.0.15 spec/app/models/user.rb