models

package
v0.0.0-...-cbf5b65 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Article

type Article struct {
	Id            primitive.ObjectID `bson:"_id,omitempty" json:"id"`
	Aid           int                `bson:"aid" json:"aid"`
	Link          string             `bson:"link" json:"link"`
	Title         string             `bson:"title" json:"title"`
	SubscribedIDs []string           `bson:"subscribed_ids" json:"subscribed_ids"`
	CreatedAt     primitive.DateTime `bson:"created_at" json:"created_at"`
	UpdatedAt     primitive.DateTime `bson:"updated_at" json:"updated_at"`
}
type Cookie struct {
	Id        primitive.ObjectID `bson:"_id,omitempty" json:"id"`
	Username  string             `bson:"username" json:"username" validate:"required"`
	Cookies   []string           `bson:"cookies" json:"cookies"`
	CreatedAt primitive.DateTime `bson:"created_at" json:"created_at"`
	UpdatedAt primitive.DateTime `bson:"updated_at" json:"updated_at"`
}

type ExamSchedules

type ExamSchedules struct {
	Id        primitive.ObjectID   `bson:"_id,omitempty" json:"id"`
	Username  string               `bson:"username" json:"username" validate:"required"`
	Subjects  []types.ExamSchedule `bson:"subjects" json:"subjects"`
	CreatedAt primitive.DateTime   `bson:"created_at" json:"created_at"`
	UpdatedAt primitive.DateTime   `bson:"updated_at" json:"updated_at"`
}

type LoginRequest

type LoginRequest struct {
	Id       string `json:"id" validate:"required"`
	Username string `json:"username" validate:"required"`
	Password string `json:"password" validate:"required"`
}

type Provider

type Provider string

type User

type User struct {
	Id                  primitive.ObjectID `bson:"_id,omitempty" json:"id"`
	Username            string             `bson:"username" json:"username" validate:"required"`
	Password            string             `bson:"password" json:"password" validate:"required"`
	SubscribedID        string             `bson:"subscribed_id" json:"subscribed_id" validate:"required"`
	SubjectHTML         string             `bson:"subject_html" json:"subject_html"`
	IsSubscribedSubject bool               `bson:"is_subscribed_subject" json:"is_subscribed_subject"`
	IsTrackTimetable    bool               `bson:"is_track_timetable" json:"is_track_timetable"`
	IsExamDay           bool               `bson:"is_exam_day" json:"is_exam_day"`
	IsDeleted           bool               `bson:"is_deleted" json:"is_deleted" default:"false"`
	IsDisabled          bool               `bson:"is_disabled" json:"is_disabled" default:"false"`
	CreatedAt           primitive.DateTime `bson:"created_at" json:"created_at"`
	UpdatedAt           primitive.DateTime `bson:"updated_at" json:"updated_at"`
	LoginProvider       Provider           `bson:"login_provider" json:"login_provider"`
	SessionId           string             `bson:"session_id" json:"session_id"`
	AspxAuth            string             `bson:"aspx_auth" json:"aspx_auth"`
	IS_VIP              bool               `bson:"is_vip" json:"is_vip"`
}

Jump to

Keyboard shortcuts

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