LP#1879983: new table and seed data for curbside
authorMike Rylander <mrylander@gmail.com>
Tue, 19 May 2020 19:08:32 +0000 (15:08 -0400)
committerGalen Charlton <gmc@equinoxinitiative.org>
Wed, 10 Jun 2020 17:28:21 +0000 (13:28 -0400)
commite7f9fccc7c1c9987690622dadf7c86dbfd3a3f72
treebad6c459cc412a7f4d3ff55383e1a13027a64ae5
parenta9fafc4bf42fd3d9c5ecd5539b95b3bcec6a9e52
LP#1879983: new table and seed data for curbside

This patch adds a new database table, action.curbside, for
tracking appointments to pick up on-shelf hold requests:

 id             - ID
 patron         - patron that the appoint is for
 org            - pickup library that the appointment is for
 slot           - date and time of appointment
 staged         - whethers for appointment have been staged
 stage_staff    - staff member responsible for staging the items
 arrival        - whether patron has arrived to pick up the items
 delivered      - whether items have been checked out to patron
 delivery_staff - staff member responsible for checking out the items
 notes          - notes about the appointment, e.g., the color
                  of the patron's vehicle

It also adds three new library settings:

* circ.curbside: whether to enable curbside appointments for
  picking up available hold requests. This default to off.

* circ.curbside.granularity: interval between appointment slots. This
  defaults to 15 minutes.

* circ.curbside.max_concurrent: how many appointments to permit per
  time slot.  This defaults to 10.

It also adds two Action Trigger hooks:

* hold.offer_curbside: to trigger notifications offering a patron the
  opportunity to set an appointment time; this is invoked if the
  CurbsideSlot A/T reactor is used to create appointment slots when
  holds become available.

* hold.confim_curbside: fired when a curbside pickup appointment is
  created or updated.

It also adds seed data for the Curbside A/T validator and CurbsideSlot A/T
reactor.

Finally, it adds sample A/T event definitions:

* Curbside offer Email notification
* Curbside offer SMS notification
* Curbside confirmation Email notification
* Curbside confirmation SMS notification

These event definitions are disabled by default.

In addition to Mike Rylander, significant contributions to this
patch were made by Jason Boyer and Galen Charlton.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Jason Boyer <jboyer@equinoxinitiative.org>
Open-ILS/examples/fm_IDL.xml
Open-ILS/src/sql/Pg/upgrade/XXXX.schema.curbside.sql [new file with mode: 0644]