mirror of
https://github.com/rjNemo/rentease.git
synced 2026-06-06 10:46:50 +00:00
32 lines
638 B
Go
32 lines
638 B
Go
package booking
|
|
|
|
import (
|
|
"time"
|
|
|
|
"gorm.io/gorm"
|
|
)
|
|
|
|
type Booking struct {
|
|
gorm.Model
|
|
Id int
|
|
Name string `gorm:"column:customer_name"`
|
|
PhoneNumber string
|
|
CustomerNumber int `gorm:"column:customers"`
|
|
Email string
|
|
From time.Time
|
|
To time.Time
|
|
Platform string
|
|
PlatformFees float64 `gorm:"type:decimal(10,2)"`
|
|
Items []Item
|
|
}
|
|
|
|
type Item struct {
|
|
gorm.Model
|
|
Id int
|
|
BookingId int
|
|
Item string
|
|
Quantity int
|
|
Price float64 `gorm:"type:decimal(10,2)"`
|
|
PaymentMethod string
|
|
PaymentStatus string `gorm:"default:Pending"`
|
|
}
|