[RM-32230]: <BU> ตรวจสอบอีเมล Suggestion เนื่องจากรายการซึ่งได้ Reject แต่ email ยังมีสถานะ Pending

Viewed 2

Problem Summary

From Redmine:
วันนี้เข้าไปตรวจสอบรายการซึ่งได้ Reject รายการที่ผู้ใช้สั่งซื้อเข้ามา เนื่องจาก สินค้าหมด ซึ่งทำไปเมื่อวานค่ะ แต่ email ยังมีสถานะ Pending อยู่ค่ะ

ลองยืม-คืนตั้งแต่ 17 ก.ย. email ก็ยังขึ้น pending นะคะ 

Root Cause Analysis

  1. มีการแก้ไข Exclude email ที่มี letter_code=AVAILABLE (Suggestion available) แล้วทำให้ CRON ไม่ทำงาน
  2. ที่ CRON ไม่ทำงานเพราะว่า parameter --where ของ script /usr/share/koha/bin/cronjobs/process_message_queue.pl
    ไม่สามาารถใช้ได้ผ่าน koha-foreach โดยที่ไม่แจ้ง error
1 Answers

Solution / Workaround

ทำการ fork script นี้และย้ายไปไว้ที่ /etc/cron.d/punsarn-koha โดย call /srv/punsarn/site/misc/process_message_queue.pl แทน

Verification Steps

ให้ทดสอบยืมคืน จะมี email แจ้งเตือนภายใน 15 นาที