Skip to content

Action notifications

This ticket adds new notification generators org.gringlobal.notification.AccessionActionNotifications, org.gringlobal.notification.InventoryActionNotifications and org.gringlobal.notification.OrderRequestNotifications that send the relevant action schedules to the subscribers. The scheduling is described in #470 (closed) and subscriber list in #472 (closed).

AccessionActionNotifications will use accession-schedule.mustache template and look like:

@ScheduledNotification(value = "sendWeeklyAccessionSchedule")
@Transactional(readOnly = true)
public void generateWeeklyAccessionSchedule() {
 // Load AccessionActions for next 7 days (from today at 00:00 - to today+8days at 00:00)
 // Use accession-schedule.mustache to generate the body
}

@ScheduledNotification(value = "sendMonthlyAccessionSchedule")
@Transactional(readOnly = true)
public void generateMonthlyAccessionSchedule() {
 // Load AccessionActions for this month (from 1st of this month at 00:00 - to 1st of next month at 00:00)
 // Use accession-schedule.mustache to generate the body
}

The default templates should generate a table of actions similar to that in the UI:

Accession action schedule {{fromInstant}} to {{toInstant}}

View it in GGCE +Link to GGCE UI

image

Template customization follows the logic in #469 (closed)

Edited by Matija Obreza
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information