Return Payment Status
This commit is contained in:
@@ -137,6 +137,18 @@ type HistoryOrder struct {
|
||||
Source string `gorm:"type:numeric;column:source"`
|
||||
}
|
||||
|
||||
func (h *HistoryOrder) GetPaymentStatus() string {
|
||||
if h.Status == "PAID" {
|
||||
return "E-TICKET TELAH TERBIT"
|
||||
}
|
||||
|
||||
if h.Status == "PENDING" {
|
||||
return "MENUNGGU PEMBAYARAN"
|
||||
}
|
||||
|
||||
return ""
|
||||
}
|
||||
|
||||
type HistoryOrderDB struct {
|
||||
HistoryOrder
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user