ish_models 0.0.33.118 → 0.0.33.119

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 121558953571ec7ddccd7fa69e5fc6ac7ae66fb854bf3c3af7a6e863c081d7ef
4
- data.tar.gz: cd512a1f08541937604d4271331f37f08b0612a294ee87b58bc340bc0a8826de
3
+ metadata.gz: 29c1520c5fc6a0d4d621ed6240c77a00b9cf879e4f31b188383eeebdde7b0f24
4
+ data.tar.gz: 2f0c0b4b9f30333aa370b82634bb4f428583109386664e0ce09f7db24c04468f
5
5
  SHA512:
6
- metadata.gz: 6d45ea857448f205f82ee8f3a26b8c758781595ad919ae7befd4bd142744d0806ae0d463abfe5fb591c9cf893bb589d5e3ae3979392eeb3962b3e635c5457b4e
7
- data.tar.gz: ae1f643f25fe548a4dd733f888801373a5e9512e42f6f5e7766c2326114b48510d3658a6ad87e0779c53ac57616cb5ba2d53d4481f5e813e06daeeef4706991e
6
+ metadata.gz: 7d8516841d633e40b2e9158c073e19d5e13c547fab4d9b2b20e8402955958e82f853f99c8424779d27244eb3d83ac12a8835af31d1b3b5349bdb116fdc41b724
7
+ data.tar.gz: 9ed78769aa53818df64028f2fc52460a141e135a8d6dd61520bce73c366b71846d3f1fa4c70930c3d56762a76ed88780c76c70552a59a786e788d7f2450b69e1
@@ -4,6 +4,8 @@ class Gallery
4
4
  include ::Mongoid::Document
5
5
  include ::Mongoid::Timestamps
6
6
 
7
+ PER_PAGE = 6
8
+
7
9
  field :is_public, type: Boolean, default: false
8
10
  field :is_trash, type: Boolean, default: false
9
11
 
@@ -31,6 +31,8 @@ class Newsitem
31
31
  field :downvoting_users, :type => Array, :default => []
32
32
  field :is_feature, :type => Boolean, :default => false
33
33
 
34
+ PER_PAGE = 6
35
+
34
36
  default_scope ->{ order_by({ :created_at => :desc }) }
35
37
 
36
38
  def self.from_params item
@@ -43,6 +43,8 @@ class Venue
43
43
  embeds_many :newsitems
44
44
  embeds_many :features
45
45
 
46
+ PER_PAGE = 6
47
+
46
48
  def self.list conditions = { :is_trash => false }
47
49
  out = self.where( conditions).order_by( :name => :asc )
48
50
  [['', nil]] + out.map { |item| [ item.name, item.id ] }
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.118
4
+ version: 0.0.33.119
5
5
  platform: ruby
6
6
  authors:
7
7
  - piousbox