การแจ้งเตือน
Passes ทั่วไปรองรับการแจ้งเตือน 2 ประเภท โดยจะกำหนดค่าดังต่อไปนี้ได้
- การแจ้งเตือนที่กำลังจะมีขึ้น
- การแจ้งเตือนการหมดอายุ
การแจ้งเตือนที่กำลังจะมีขึ้น
การแจ้งเตือนที่กำลังจะมีขึ้นจะแสดงต่อผู้ใช้ 24 ชั่วโมงก่อนช่วงเวลาจะเริ่มขึ้น
เมื่อกำหนดค่าการแจ้งเตือนที่กำลังจะมาถึงแล้ว การแจ้งเตือนที่มีชื่อว่า "genericObject.cardTitle
พร้อมใช้งานแล้ว" และคำบรรยาย "ดูบัตร" จะปรากฏต่อผู้ใช้
หากต้องการกำหนดค่าการแจ้งเตือนที่กำลังจะมาถึง ให้ตั้งค่าบูลีน UpcomingNotification.enabledNotification เป็น true
การแจ้งเตือนการหมดอายุ
การแจ้งเตือนวันหมดอายุจะปรากฏ 48 ชั่วโมงก่อนสิ้นสุดช่วงเวลานี้
เมื่อกำหนดค่าการแจ้งเตือนแล้ว การแจ้งเตือนที่มีชื่อ "genericObject.cardTitle
จะหมดอายุใน [x] วัน" และคำบรรยาย "ดูบัตร" จะปรากฏต่อผู้ใช้
หากต้องการกำหนดค่าการแจ้งเตือนที่กำลังจะมาถึง ให้ตั้งค่าบูลีน ExpiryNotification.enabledNotification เป็น true
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-02-28 UTC
[null,null,["อัปเดตล่าสุด 2025-02-28 UTC"],[[["Generic passes offer two notification types: upcoming and expiry, allowing users to receive timely alerts."],["Upcoming notifications, triggered 24 hours before a specified time interval, inform users that their generic object is available."],["Expiry notifications, appearing 48 hours prior to the end of a time interval, remind users of the impending expiration of their generic object."],["Both notification types can be easily enabled by setting the respective boolean value (`enabledNotification`) to `true` in the pass configuration."]]],["Generic Passes offer upcoming and expiry notifications. Upcoming notifications, appearing 24 hours before the start time, display the pass's card title and \"View pass\" as the subtitle, enabled by setting `UpcomingNotification.enabledNotification` to `true`. Expiry notifications, appearing 48 hours before the end time, show the card title and an \"expires in [x] days\" message with a \"View pass\" subtitle, enabled by setting `ExpiryNotification.enabledNotification` to `true`.\n"]]