Wishlist: Ability to send action trigger email notices based on circulation modifier or shelving location

Bug #1822164 reported by Jennifer Pringle on 2019-03-28
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Evergreen
Undecided
Unassigned

Bug Description

Evergreen 3.1.7

It would be useful to be able to send out overdue notices based on the circulation modifier or shelving location used by the item.

For example we have a library that loans out laptops and headphones who would like to be able to send a 1 day overdue notice for those items but doesn't want the notice to go out for every single item that is currently 1 day overdue.

Revision history for this message
Remington Steed (rjs7) wrote :

Could this be accomplished using the "--custom-filters" parameter for action_trigger_runner.pl? Possibly by using different files for different cron jobs.

action_trigger_runner.pl --process-hooks --hooks=... --custom-filters=[defaults to action_trigger_filters.json if exists]

http://docs.evergreen-ils.org/3.2/_processing_action_triggers.html

Revision history for this message
Josh Stompro (u-launchpad-stompro-org) wrote :

When I looked into this sort of thing a while back, I couldn't figure out how to create a custom filter expression that could join in other tables. It seems like you can only effect the where clause, which can only act on data in the event target table. So for overdues that would be the action.circulation data.

So if you wanted to target the circulation modifier you cannot, since that exists only in the asset.copy table.

But the checkout does contain the copy_location data. So if you wanted to limit to just one shelving location (with id 123) you could use something like.

{
"checkout.due" :
    { "context_org" : "circ_lib",
      "copy_location" : 123,
      "filter" :
            { "checkin_time" : null,
              "-or" :
                    [ { "stop_fines" : ["MAXFINES"] },
                      { "stop_fines" : null }
                    ]
            }
    }
}

If there is a way to add in joins I would love to see an example of that.

Otherwise I've used pre-processing sql scripts that go through all the events for a specific event definition and delete/cancel events that match/don't match extra criteria, such as circ_mod. And then run all the pending events after they have been cleaned up.

Josh

tags: added: wishlist
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers