ish_models 0.0.33.231 → 0.0.33.233
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ish/email_campaign.rb +9 -12
- data/lib/ish/email_context.rb +2 -0
- data/lib/office/email_filter.rb +1 -0
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 15ca1b54b0bc7435631e46a9a59f46827dfced47e491adac105d3dd67fed7663
|
4
|
+
data.tar.gz: 9b41c652d834af17efd2d36ed3f582352e0cdf445271dcde32c692820c12c4fd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3f4d47b3b918592d081f7219b85df89e57823018286db1ec22f7f976216ba2207a5495a18958d6a5fa6781464ff7acd5f0c1da117c450e4c5a2d6be76309c621
|
7
|
+
data.tar.gz: 343987b37ddc718162080702113a746f8a202f08136c5f228d9f3b9ae948cf8fce17b2c88be84e8731bb0146e61682210baac7c43c950aacf476b416419b49c7
|
data/lib/ish/email_campaign.rb
CHANGED
@@ -7,30 +7,27 @@
|
|
7
7
|
class Ish::EmailCampaign
|
8
8
|
include Mongoid::Document
|
9
9
|
include Mongoid::Timestamps
|
10
|
+
store_in collection: 'ish_email_campaigns'
|
10
11
|
|
11
|
-
field :
|
12
|
-
|
13
|
-
title
|
14
|
-
end
|
12
|
+
field :slug
|
13
|
+
validates_uniqueness_of :slug, allow_nil: true
|
15
14
|
|
16
15
|
PAGE_PARAM_NAME = 'email_contexts_page'
|
17
16
|
|
18
|
-
FROM_EMAILS = %w|
|
19
|
-
piousbox@gmail.com hello@piousbox.com
|
20
|
-
admin@wasya.co
|
17
|
+
FROM_EMAILS = %w| hello@infiniteshelter.com no-reply@infiniteshelter.com
|
18
|
+
piousbox@gmail.com hello@piousbox.com no-reply@piousbox.com victor@piousbox.com
|
19
|
+
admin@wasya.co hello@wasya.co no-reply@wasya.co victor@wasya.co |
|
21
20
|
field :from_email
|
22
21
|
validates_presence_of :from_email
|
23
22
|
def self.from_email_list
|
24
23
|
[ [nil, nil] ] + FROM_EMAILS.map { |i| [i, i] }
|
25
24
|
end
|
26
25
|
|
27
|
-
|
28
|
-
|
26
|
+
belongs_to :email_template
|
27
|
+
def tmpl; email_template; end
|
29
28
|
|
29
|
+
field :subject
|
30
30
|
field :body
|
31
|
-
# validates_presence_of :body
|
32
|
-
|
33
|
-
belongs_to :email_template
|
34
31
|
|
35
32
|
field :sent_at, type: DateTime
|
36
33
|
field :send_at, type: DateTime
|
data/lib/ish/email_context.rb
CHANGED
@@ -43,6 +43,8 @@ class ::Ish::EmailContext
|
|
43
43
|
belongs_to :scheduled_email_action, class_name: '::Office::ScheduledEmailAction', optional: true
|
44
44
|
def sch; scheduled_email_action; end
|
45
45
|
|
46
|
+
belongs_to :email_campaign, class_name: 'Ish::EmailCampaign', optional: true
|
47
|
+
|
46
48
|
field :rendered_str
|
47
49
|
|
48
50
|
field :sent_at, type: DateTime
|
data/lib/office/email_filter.rb
CHANGED