ish_models 0.0.33.30 → 0.0.33.31

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
  SHA1:
3
- metadata.gz: 18e2d060b87ef7f3e205c311cced79d53bb683d7
4
- data.tar.gz: 5a2b534699640c8b2f081f7a040a0ecfb834bfd7
3
+ metadata.gz: 8bc52706ccbe2c0f4eea769079e009ae0b8b12f3
4
+ data.tar.gz: 7d1b2f63e0a8c7532f5e15a91807b947db5dd47f
5
5
  SHA512:
6
- metadata.gz: edc4b39b41f83a9d63796633f8ddf51161df6bc43373237c9cc62af51ed5e138dfadfc6323054023615a38148a6ce8abbec61fb9ea2e8a4571bbf363926385d2
7
- data.tar.gz: 5229eec376e6937f3f65fbf5d794c4e5bcb620e698ddc06eaccf60e293a16e441c44367948a578756eebfe521e3c46d8e42eb7b0dd68b34290023fc6364b7209
6
+ metadata.gz: 2f4f0a06c7561bbbdae6dc0b1abb194e97318573cb9c9ec02ffa844e552ecbe9e912cfc9aa65289ba3a3b505fa7633508dc7e1a429b8677a0b066e5d100c5e37
7
+ data.tar.gz: 372c31c04a48c7e2ebf0575d013a5b8335ef35d06df548997719af0ffcb4d1bbe7182eb3bbbdf84c7b9efd61bd86985b0d36b2011e785439ab2d5aa6aca26cd8
@@ -5,11 +5,20 @@ class IshModels::StockWatch
5
5
 
6
6
  field :ticker
7
7
 
8
- NOTIFICATION_TYPES = [ :EMAIL, :SMS, :NONE ]
8
+ NOTIFICATION_TYPES = [ :NONE, :EMAIL, :SMS ]
9
+ NOTIFICATION_NONE = :NONE
9
10
  NOTIFICATION_EMAIL = :EMAIL
10
11
  NOTIFICATION_SMS = :SMS
11
- NOTIFICATION_NONE = :NONE
12
- field :notification_type, :type => Symbol
12
+ ACTIONS = NOTIFICATION_TYPES
13
+ field :notification_type, :type => Symbol, :as => :action
14
+ =begin
15
+ def action
16
+ return notification_type
17
+ end
18
+ def action= which
19
+ notification_type = which
20
+ end
21
+ =end
13
22
 
14
23
  field :price, :type => Float
15
24
 
@@ -18,4 +27,6 @@ class IshModels::StockWatch
18
27
  DIRECTION_BELOW = :BELOW
19
28
  field :direction, :type => Symbol
20
29
 
30
+ belongs_to :profile, :class_name => 'IshModels::UserProfile'
31
+
21
32
  end
@@ -32,6 +32,8 @@ class IshModels::UserProfile
32
32
  has_many :videos
33
33
  has_many :photos
34
34
 
35
+ has_many :stocks, :class_name => 'IshModels::StockWatch'
36
+
35
37
  #
36
38
  # preferences
37
39
  #
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.30
4
+ version: 0.0.33.31
5
5
  platform: ruby
6
6
  authors:
7
7
  - piousbox