package models

import "time"

type WalletTransaction struct {
	ID              uint      `gorm:"primaryKey;autoIncrement" json:"id"`
	UserID          uint      `gorm:"column:userId;not null;index" json:"userId"`
	AstrologerID    uint      `gorm:"column:astrologerId;not null;index" json:"astrologerId"`
	Amount          float64   `gorm:"column:amount"`
	TransactionType string    `gorm:"column:transactionType"`
	OrderID         uint      `gorm:"column:orderId"`
	IsCredit        bool      `gorm:"column:isCredit"`
	CreatedAt       time.Time `gorm:"column:created_at;autoCreateTime" json:"createdAt"`
	UpdatedAt       time.Time `gorm:"column:updated_at;autoUpdateTime" json:"updatedAt"`
	CreatedBy       uint      `gorm:"column:createdBy"`
	ModifiedBy      uint      `gorm:"column:modifiedBy"`
}

func (WalletTransaction) TableName() string {
	return "wallettransaction"
}
