block-accounting/backend/internal/pkg/models/tx.go

41 lines
592 B
Go
Raw Normal View History

2024-05-24 17:44:24 +00:00
package models
import (
"time"
"github.com/google/uuid"
)
type Transaction struct {
Id uuid.UUID
Description string
OrganizationId uuid.UUID
CreatedBy *OrganizationUser
Amount float64
ToAddr []byte
MaxFeeAllowed float64
Deadline time.Time
Status int
CreatedAt time.Time
UpdatedAt time.Time
ConfirmedAt time.Time
CancelledAt time.Time
CommitedAt time.Time
}
type TransactionConfirmation struct {
TxId uuid.UUID
User *User
OrganizationId uuid.UUID
CreatedAt time.Time
UpdatedAt time.Time
Confirmed bool
}