One step in a voucher's life, recording that it moved to a given status, when, by whom and from which IP address. A voucher accumulates a row here each time its status changes, typically pending to allocated to redeemed, so this is the voucher's audit trail rather than its current state. The profile is optional because a voucher can be redeemed anonymously, and because there is one row per attempt this is also the record fraud rules count against when looking for repeated redemptions from the same IP address.
Group: Database Entities
Implements: Serializable
Properties
| Property | Returns | Description |
|---|---|---|
| changeBy | Profile | The profile who made the change. Optional, because a voucher can be redeemed anonymously, so do not rely on it being present. |
| changeDate | Date | When the status changed. Nullable in the schema, but expected to be set on any record written by the platform. |
| id | long | The database-assigned unique identifier for this status change. |
| ipAddress | String | The client IP this status change was made from. Recorded so that fraud rules can ask how many redemptions have come from one address recently - this record, rather than the voucher, is the right home for it, because a voucher has one row here per redemption attempt. |
| notes | String | Free text explaining the change, for example why a voucher was cancelled. Usually null. |
| status | String | The status the voucher moved to, held as a single letter code: R for redeemed, A for allocated and P for pending. |
| voucher | Voucher | The voucher this change happened to. Always set. |
Methods
getId()
Returns: long
The database-assigned unique identifier for this status change.
getVoucher()
Returns: Voucher
The voucher this change happened to. Always set.
getChangeDate()
Returns: Date
When the status changed. Nullable in the schema, but expected to be set on any record written by the platform.
getChangeBy()
Returns: Profile
The profile who made the change. Optional, because a voucher can be redeemed anonymously, so do not rely on it being present.
getStatus()
Returns: String
The status the voucher moved to, held as a single letter code: R for redeemed, A for allocated and P for pending.
getNotes()
Returns: String
Free text explaining the change, for example why a voucher was cancelled. Usually null.
getIpAddress()
Returns: String
The client IP this status change was made from. Recorded so that fraud rules can ask how many redemptions have come from one address recently - this record, rather than the voucher, is the right home for it, because a voucher has one row here per redemption attempt.