Skip to content

Commit 021ee20

Browse files
authored
Add doc for new Opt-In Setting Type (#5)
* Add doc for new Opt-In Setting Type * Tweak label to use title case
1 parent 8602a5a commit 021ee20

File tree

1 file changed

+21
-7
lines changed

1 file changed

+21
-7
lines changed

docs/pn-setup-guide/configure-evergreen.md

+21-7
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@ This guide is for the Evergreen Administrator.
88
It will help you set up your Evergreen (EG) server for sending a push notifications with an action trigger. It assumes that your System Administrator has already installed the `hemlock-sendmsg` daemon, and it's listening on `localhost:8842`.
99

1010
The process is:
11-
* Create a User Setting Type
11+
* Create User Setting Types
1212
* Create an Action Trigger
1313

14-
## Create a User Setting Type
14+
## Create User Setting Types
1515

16-
This procedure creates a new User Setting Type for the app to store its push notification token. This token uniquely identifies the app installation, and is required to send a push notification to a specific patron account.
16+
This procedure creates two new User Setting Types for the app to store its push notification token and an enabled flag. The token uniquely identifies the app installation, and is required to send a push notification to a specific patron account. The boolean flag can be used as an opt-in setting type on any action triggers that send push notifications.
1717

1818
As an EG admin, login to the Staff client and go to Server Administration >> User Setting Types.
1919

@@ -24,11 +24,23 @@ Procedure:
2424
| Label | Value |
2525
| ------------------- | ---------------------------------------------------------------------------------- |
2626
| Datatype | string |
27-
| Description | Data stored by the Hemlock app for patrons that have opted into push notifications |
28-
| Label | Hemlock Push Notification data |
27+
| Description | Used by the Hemlock app to store a patron's push notification token |
28+
| Label | Hemlock Push Notification Data |
2929
| Name | hemlock.push_notification_data |
3030
| OPAC/Patron Visible | checked |
3131

32+
* Click `Save`
33+
* Click `New User Setting Type`
34+
* Set the following form values:
35+
36+
| Label | Value |
37+
| ------------------- | ---------------------------------------------------------------------------------- |
38+
| Datatype | bool |
39+
| Description | Used by the Hemlock app to flag that a patron has a push notification token |
40+
| Label | Hemlock Push Notification Enabled |
41+
| Name | hemlock.push_notification_enabled |
42+
| OPAC/Patron Visible | checked |
43+
3244
* Click `Save`
3345

3446
## Create an Action Trigger
@@ -73,8 +85,10 @@ This example event definition is for a courtesy notice. Some details may need to
7385
| Processing Group Context Field | usr |
7486
| Reactor | CallHTTP |
7587
| Validator | CircIsOpen |
76-
| Event Repeatability Delay | 00:00:00 |
88+
| Event Repeatability Delay | 00:00:30 |
7789
| Max Event Validity Delay | -300 days |
90+
| Opt-In Setting Type | hemlock.push_notification_enabled |
91+
| Opt-In User Field | usr |
7892
| Retention Interval | 6 mons |
7993
| Template | [(see below)](#sample-template) |
8094
| Context Bib Path | target_copy.call_number.record |
@@ -115,4 +129,4 @@ url http://localhost:8842/send
115129
debug 1
116130
</Parameters>
117131
```
118-
* Click `Save`
132+
* Click `Save`

0 commit comments

Comments
 (0)