22 lines
777 B
Go
22 lines
777 B
Go
|
package usermngmt
|
||
|
|
||
|
import (
|
||
|
"time"
|
||
|
|
||
|
"go.mongodb.org/mongo-driver/bson/primitive"
|
||
|
)
|
||
|
|
||
|
// User ...
|
||
|
type User struct {
|
||
|
ID primitive.ObjectID `bson:"_id" json:"_id"`
|
||
|
Name string `bson:"name" json:"name"`
|
||
|
Phone string `bson:"phone" json:"phone"` // unique
|
||
|
Email string `bson:"email" json:"email"` // unique
|
||
|
HashPassword string `bson:"hashPassword" json:"hashPassword"`
|
||
|
Status string `bson:"status" json:"status"`
|
||
|
RoleID primitive.ObjectID `bson:"roleID" json:"roleId"`
|
||
|
Other string `bson:"other" json:"other"`
|
||
|
CreatedAt time.Time `bson:"createdAt" json:"createdAt"`
|
||
|
UpdatedAt time.Time `bson:"updatedAt" json:"updatedAt"`
|
||
|
}
|