81 lines
1.6 KiB
Go
81 lines
1.6 KiB
Go
package domain
|
|
|
|
import "time"
|
|
|
|
type Wallet struct {
|
|
ID int64
|
|
Balance Currency
|
|
Currency IntCurrency
|
|
IsWithdraw bool
|
|
IsBettable bool
|
|
IsTransferable bool
|
|
IsActive bool
|
|
UserID int64
|
|
UpdatedAt time.Time
|
|
CreatedAt time.Time
|
|
}
|
|
|
|
type WalletFilter struct {
|
|
IsActive ValidBool
|
|
Query ValidString
|
|
CreatedBefore ValidTime
|
|
CreatedAfter ValidTime
|
|
}
|
|
|
|
type CustomerWallet struct {
|
|
ID int64
|
|
RegularID int64
|
|
StaticID int64
|
|
CustomerID int64
|
|
}
|
|
type GetCustomerWallet struct {
|
|
ID int64
|
|
RegularID int64
|
|
RegularBalance Currency
|
|
StaticID int64
|
|
StaticBalance Currency
|
|
CustomerID int64
|
|
RegularIsActive bool
|
|
StaticIsActive bool
|
|
RegularUpdatedAt time.Time
|
|
StaticUpdatedAt time.Time
|
|
CreatedAt time.Time
|
|
FirstName string
|
|
LastName string
|
|
PhoneNumber string
|
|
}
|
|
|
|
type BranchWallet struct {
|
|
ID int64
|
|
Balance Currency
|
|
IsActive bool
|
|
Name string
|
|
Location string
|
|
BranchManagerID int64
|
|
CompanyID int64
|
|
IsSelfOwned bool
|
|
UpdatedAt time.Time
|
|
CreatedAt time.Time
|
|
}
|
|
|
|
type CreateWallet struct {
|
|
IsWithdraw bool
|
|
IsBettable bool
|
|
IsTransferable bool
|
|
UserID int64
|
|
}
|
|
|
|
type CreateCustomerWallet struct {
|
|
CustomerID int64
|
|
RegularWalletID int64
|
|
StaticWalletID int64
|
|
}
|
|
|
|
type WalletType string
|
|
|
|
const (
|
|
CustomerWalletType WalletType = "customer_wallet"
|
|
BranchWalletType WalletType = "branch_wallet"
|
|
CompanyWalletType WalletType = "company_wallet"
|
|
)
|