models

package
v0.0.0-...-346be84 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 27, 2024 License: BSD-2-Clause Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Login

type Login struct {
	Email    string `bson:"email" json:"email" validate:"required,email"`
	Password string `bson:"password" json:"password" validate:"required"`
	UserDevice
}

type TransactionLog

type TransactionLog struct {
	UserID      primitive.ObjectID `bson:"userId"`
	Action      string             `bson:"action"`
	CreatedDate time.Time          `bson:"createdDate"`
	CreatedByID string             `bson:"createdById"`
	UpdatedDate time.Time          `bson:"updatedDate"`
	UpdatedByID string             `bson:"updatedById"`
}

type User

type User struct {
	IsEnabled         bool               `bson:"isEnabled"`
	UserID            primitive.ObjectID `bson:"_id,omitempty"`
	VerifiedBy        primitive.ObjectID `bson:"verifiedBy"`
	IsEnabledByID     primitive.ObjectID `bson:"isEnabledByID"`
	UpdatedByID       primitive.ObjectID `bson:"updatedById"`
	CreatedDate       time.Time          `bson:"createdDate"`
	DateOfBirth       time.Time          `bson:"dateOfBirth" json:"dateOfBirth"`
	UpdatedDate       time.Time          `bson:"updatedDate"`
	VerifiedDate      time.Time          `bson:"verifiedDate"`
	IsEnabledByDate   time.Time          `bson:"isEnabledByDate"`
	Gender            string             `bson:"gender"`
	LastName          string             `bson:"lastName" json:"lastName" binding:"required"`
	CreatedByID       string             `bson:"createdById"`
	VerificationToken string             `bson:"verificationToken"`
	Email             string             `bson:"email" json:"email" binding:"required,email"`
	Password          string             `bson:"password" json:"password" validate:"password_complexity"`
	Role              string             `bson:"role"`
	FirstName         string             `bson:"firstName" json:"firstName" binding:"required"`
	MiddleName        string             `bson:"middleName" json:"middleName"`
}

type UserDevice

type UserDevice struct {
	DeviceID    primitive.ObjectID `bson:"_id"`
	UserID      primitive.ObjectID `bson:"userID"`
	DeviceOS    string             `bson:"deviceOS,omitempty" json:"dos" validate:"required" binding:"required"`
	UserAgent   string             `bsong:"userAgent,omitempty" json:"ua" validate:"required" binding:"required"`
	DeviceGenID string             `bson:"deviceGenID,omitempty" json:"dgid" validate:"required" binding:"required"`
	Browser     string             `bson:"browser,omitempty" json:"navigator" validate:"required" binding:"required"`
	DeviceIP    string             `bson:"DeviceIP,omitempty" json:"dip" validate:"required" binding:"required"`
	CreatedDate time.Time          `bson:"createdDate"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL