ish_models 0.0.33.133 → 0.0.33.134

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/gallery.rb +3 -0
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2d50f29ed3d0a85e7d16177bd79b9fe6c3271ad17b4cb888c81c44b451a1f28d
4
- data.tar.gz: 8ab4c58c78a5967a2096d9aacc58a0568442ea1ff3477d353cbe8a42f3ce5ded
3
+ metadata.gz: 3d922df26e696ac770c512266ee8b46206cb27068acba43df008250e3d1f3a62
4
+ data.tar.gz: 3fbc130546d38392d78fef959448eea0642a70cb76cdd9194f3924867877d204
5
5
  SHA512:
6
- metadata.gz: 1e53ea5ade3eaec46a41f2469c27ff60bf4feaf8e989cc1091173e16d4788e4f262150f5b84045c3d717fadd4f4fad09e982474d11fddd0b2f7bf5b1a0abeffc
7
- data.tar.gz: 6c618c59a51c4a05dec7725cf21211bf5ce9b5f35dea634ed83f1f1db98a5252f00199096de651ae75ec1199ae36a0295d2a993fcc564c0a80c8ee3d2ba66d27
6
+ metadata.gz: 98cebce56b2f8a979808d1e1e2bff952601fb7322bcbde228d8ec643656da4b665849782a4a1a5e30eabc36c747b70b57d9d950b1cd544d63444bf93ca5d79e9
7
+ data.tar.gz: 73c95a9da8539641a6f5f9d14a2d0c27721f713cad23223727927aa5eb2e422b464007a277810262b20fd6a052882ecd4f79fe1faaf24c83093a7152af198ad2
data/lib/gallery.rb CHANGED
@@ -39,6 +39,9 @@ class Gallery
39
39
 
40
40
  field :galleryname
41
41
  index({ :galleryname => -1 }, { :unique => true })
42
+ def slug
43
+ galleryname
44
+ end
42
45
  embeds_many :gallery_names, :class_name => '::Ish::GalleryName'
43
46
  def self.find_by_slug slug
44
47
  ::Gallery.where( galleryname: slug ).first
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ish_models
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.33.133
4
+ version: 0.0.33.134
5
5
  platform: ruby
6
6
  authors:
7
7
  - piousbox