heya 0.5.2 → 0.5.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/README.md +22 -0
- data/app/mailers/heya/campaign_mailer.rb +2 -0
- data/lib/heya/campaigns/actions/email.rb +1 -1
- data/lib/heya/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 971ee7f9d958554bbed7093180fd8af86e12f24c00a526be4e0361ab07657fe3
|
4
|
+
data.tar.gz: f0d0f2e54f9bea9f93f095a14f19844213347989f19b881e30fa3f46cc76825c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b8da212577467f530326619471c1deb418bb71ed7109a105c47005a409ce008e1c211baa5e2e6b718dbda009efae940d282ddfb0b151d9ddb951c4dc732728a8
|
7
|
+
data.tar.gz: a6d53345cde9565b492dd7a99621db3e5762c1fd2ae8af8e565c3b69b19d887561dbb7fba32fafb74c7500c29e249e3e9f96ceb664e69cb8e5521f6693a5ae79
|
data/CHANGELOG.md
CHANGED
@@ -5,6 +5,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
5
5
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
6
6
|
|
7
7
|
## [Unreleased]
|
8
|
+
### Added
|
9
|
+
- Create `bcc:` optional parameter for steps; use case is quality control
|
10
|
+
|
11
|
+
## [0.5.2] - 2021-08-11
|
8
12
|
### Fixed
|
9
13
|
- Fix typo in initializer (#139, @800a7b32)
|
10
14
|
|
data/README.md
CHANGED
@@ -266,6 +266,28 @@ class OnboardingCampaign < ApplicationCampaign
|
|
266
266
|
end
|
267
267
|
```
|
268
268
|
|
269
|
+
#### Quality control option
|
270
|
+
|
271
|
+
You may wish to apply quality control to individual steps of a campaign. For example, when adding a new step to an existing campaign it is
|
272
|
+
a good idea to inspect real-time results in production. You can do this by using the `bcc:` step option, which would look like this:
|
273
|
+
|
274
|
+
```ruby
|
275
|
+
class OnboardingCampaign < ApplicationCampaign
|
276
|
+
default wait: 1.day,
|
277
|
+
queue: "onboarding",
|
278
|
+
from: "support@example.com"
|
279
|
+
|
280
|
+
# Will still be sent after one day from the
|
281
|
+
# email address support@example.com
|
282
|
+
step :welcome,
|
283
|
+
subject: "Welcome to my app!"
|
284
|
+
|
285
|
+
step :added_two_months_later,
|
286
|
+
subject: "We now have something new to say!",
|
287
|
+
bcc: 'quality_control@example.com'
|
288
|
+
end
|
289
|
+
```
|
290
|
+
|
269
291
|
#### Customizing email subjects for each user
|
270
292
|
|
271
293
|
The subject can be customized for each user by using a `lambda` instead of a `String`:
|
@@ -10,6 +10,7 @@ module Heya
|
|
10
10
|
step_name = step.name.underscore
|
11
11
|
|
12
12
|
from = step.params.fetch("from")
|
13
|
+
bcc = step.params.fetch("bcc", nil)
|
13
14
|
reply_to = step.params.fetch("reply_to", nil)
|
14
15
|
|
15
16
|
subject = step.params.fetch("subject") {
|
@@ -22,6 +23,7 @@ module Heya
|
|
22
23
|
|
23
24
|
mail(
|
24
25
|
from: from,
|
26
|
+
bcc: bcc,
|
25
27
|
reply_to: reply_to,
|
26
28
|
to: user.email,
|
27
29
|
subject: subject,
|
data/lib/heya/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: heya
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Joshua Wood
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-08-
|
11
|
+
date: 2021-08-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|