[Eg-newdevs] Follow up on action trigger filter example

Gina Monti gmonti at biblio.org
Fri Dec 6 11:27:19 EST 2024


Hi All!

Just as a follow up, we haven't figured out the filters yet but at least
have some more information to work off of.  It was recommended that we use
the user setting type field within the AT form in the GUI, and we found
that the setting for hemlock is a string datatype and not a bool datatype
that the other user settings types typically have when placed in an AT.

I'll have more of an update hopefully at the next New Dev in January.

On Tue, Nov 26, 2024 at 12:48 PM Gina Monti <gmonti at biblio.org> wrote:

> Hey All,
>
> I don't believe the filter and feature for Hemlock is making use of the
> opt-in feature.
>
> This is what we have tested before in regards to the checkout,due.hemlock
> hook created.  Based on the example you sent, Josh, it seems to be using
> that kind of syntax from the Trigger.PM file you shared.
>
> "checkout.due.hemlock": {
> "context_org": "circ_lib",
> "filter": {
> "-exists": {
> "from": "aus",
> "select": [
> "name",
> "usr"
> ],
> "where": {
> "name": "hemlock.push_notification_data",
> "usr": {
> "=": {
> "+circ": "usr"
>
> But I am still a novice at understanding the filters.  Please let me know
> if I'm missing something!
>
>
> On Thu, Nov 21, 2024 at 3:01 PM Morgan, Michele via Eg-newdevs <
> eg-newdevs at list.evergreen-ils.org> wrote:
>
>> Josh,
>>
>> Thanks for the reminder about the opt-in user settings in action
>> triggers! We use the opt-in in a few triggers, and I am now thinking that
>> Gina actually doesn't need a filter, but needs to fill in the following
>> fields in the trigger event definition to limit events to just the users
>> that have that setting:
>>
>> Opt-in User Field = usr
>> Opt-in Setting Type = hemlock.push_notification_data
>>
>> Hope this works!
>>
>> Michele
>> --
>> Michele M. Morgan, Systems Support Specialist
>> North of Boston Library Exchange, Danvers Massachusetts
>> mmorgan at noblenet.org
>>
>>
>>
>> On Thu, Nov 21, 2024 at 12:36 PM Josh Stompro via Eg-newdevs <
>> eg-newdevs at list.evergreen-ils.org> wrote:
>>
>>> Is the action_trigger definition for this making use of the opt-in user
>>> setting feature?
>>>
>>> I have this memory of running into problems in that case because the
>>> opt-in feature overwrites any existing "-exists" clause.  But I haven't
>>> looked into that since 2016, and didn't get any responses so I may have
>>> been mistaken about having multiple "-exists" being a problem.
>>>
>>>
>>> http://list.evergreen-ils.org/pipermail/open-ils-dev/2016-October/010239.html
>>>
>>> Here is where the opt in setting info gets merged into the json filter.
>>>
>>> https://git.evergreen-ils.org/?p=Evergreen.git;a=blob;f=Open-ILS/src/perlmods/lib/OpenILS/Application/Trigger.pm;hb=HEAD#l489
>>>
>>>
>>> Josh
>>>
>>> On Wed, Nov 20, 2024 at 4:01 PM Terran McCanna via Eg-newdevs <
>>> eg-newdevs at list.evergreen-ils.org> wrote:
>>>
>>>> Attached is the example that Gina provided that isn't working properly.
>>>>
>>>> I'm trying to puzzle through the logic, but in fm_IDL.xml the "name"
>>>> field in the "aus" class is a link, so would the where clause need to be
>>>> the id of the "hemlock.push_notification_data" user setting? (eg, "name":
>>>> "33")
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> [image: logo with link to Georgia Public Library Service website]
>>>> <https://georgialibraries.org/>
>>>>
>>>> Terran McCanna, PINES Program Manager
>>>>
>>>> ------------------------------
>>>>
>>>> Georgia Public Library Service
>>>>
>>>> 2872 Woodcock Blvd, Suite 250 | Atlanta, GA 30341
>>>>
>>>> (404) 235-7138 | tmccanna at georgialibraries.org
>>>>
>>>> https://help.georgialibraries.org | help at georgialibraries.org
>>>>
>>>> [image: logo with link to Georgia Public Library Service Facebook page]
>>>> <https://www.facebook.com/georgialibraries>[image: logo with link to
>>>> Georgia Public Library Service Instagram page]
>>>> <https://www.instagram.com/georgialibraries/>[image: logo with link to
>>>> Georgia Public Library Service LinkedIn page]
>>>> <https://www.linkedin.com/company/georgia-public-library-service/>[image:
>>>> logo with link to Georgia Public Library Service Threads page]
>>>> <https://www.threads.net/@georgialibraries>
>>>>
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> Eg-newdevs mailing list
>>>> Eg-newdevs at list.evergreen-ils.org
>>>> http://list.evergreen-ils.org/cgi-bin/mailman/listinfo/eg-newdevs
>>>>
>>> _______________________________________________
>>> Eg-newdevs mailing list
>>> Eg-newdevs at list.evergreen-ils.org
>>> http://list.evergreen-ils.org/cgi-bin/mailman/listinfo/eg-newdevs
>>>
>> _______________________________________________
>> Eg-newdevs mailing list
>> Eg-newdevs at list.evergreen-ils.org
>> http://list.evergreen-ils.org/cgi-bin/mailman/listinfo/eg-newdevs
>>
>
>
> --
>
> Gina Monti (she/her)
> Evergreen Systems Manager
> Bibliomation, Inc.
> (203) 577-4070 ext. 109
> English, American Sign Language
>


-- 

Gina Monti (she/her)
Evergreen Systems Manager
Bibliomation, Inc.
(203) 577-4070 ext. 109
English, American Sign Language
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.evergreen-ils.org/pipermail/eg-newdevs/attachments/20241206/b3b53c12/attachment.htm>


More information about the Eg-newdevs mailing list