model

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 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 Credential

type Credential struct {
	Status  bool   `json:"status" bson:"status"`
	Token   string `json:"token,omitempty" bson:"token,omitempty"`
	Message string `json:"message,omitempty" bson:"message,omitempty"`
	Data    User   `bson:"data,omitempty" json:"data,omitempty"`
}

type Payload added in v0.0.3

type Payload struct {
	Id   primitive.ObjectID `json:"id"`
	Role string             `json:"role"`
	Exp  time.Time          `json:"exp"`
	Iat  time.Time          `json:"iat"`
	Nbf  time.Time          `json:"nbf"`
}

type Registrasi

type Registrasi struct {
	ID           primitive.ObjectID `bson:"_id,omitempty" json:"_id,omitempty"`
	NamaLengkap  string             `bson:"namalengkap,omitempty" json:"namalengkap,omitempty"`
	NomorHP      string             `bson:"nomorhp,omitempty" json:"nomorhp,omitempty"`
	TanggalLahir string             `bson:"tanggallahir,omitempty" json:"tanggallahir,omitempty"`
	Alamat       string             `bson:"alamat,omitempty" json:"alamat,omitempty"`
	NIM          string             `bson:"nim,omitempty" json:"nim,omitempty"`
}

type Reservasi

type Reservasi struct {
	ID      primitive.ObjectID `bson:"_id,omitempty" json:"_id,omitempty"`
	Nama    string             `bson:"nama,omitempty" json:"nama,omitempty"`
	Notelp  string             `bson:"notelp,omitempty" json:"notelp,omitempty"`
	TTL     string             `bson:"ttl,omitempty" json:"ttl,omitempty"`
	Status  string             `bson:"status,omitempty" json:"status,omitempty"`
	Keluhan string             `bson:"keluhan,omitempty" json:"keluhan,omitempty"`
}

type ReservasiResponse

type ReservasiResponse struct {
	Status  bool      `json:"status" bson:"status"`
	Message string    `json:"message,omitempty" bson:"message,omitempty"`
	Data    Reservasi `json:"data" bson:"data"`
}

type Response

type Response struct {
	Status  bool   `json:"status" bson:"status"`
	Message string `json:"message,omitempty" bson:"message,omitempty"`
}

type User

type User struct {
	ID       primitive.ObjectID `bson:"_id,omitempty" json:"_id,omitempty"`
	Username string             `bson:"Username,omitempty" json:"Username,omitempty"`
	Password string             `bson:"password,omitempty" json:"password,omitempty"`
	Role     string             `bson:"role,omitempty" json:"role,omitempty"`
}

Jump to

Keyboard shortcuts

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