Documentation ¶
Index ¶
- type AccountAPI
- func (sAPI *AccountAPI) Add(ctx *gin.Context)
- func (sAPI *AccountAPI) Delete(ctx *gin.Context)
- func (sAPI *AccountAPI) Get(ctx *gin.Context)
- func (sAPI *AccountAPI) LoginAccount(ctx *gin.Context)
- func (sAPI *AccountAPI) Update(ctx *gin.Context)
- func (sAPI *AccountAPI) UpdatePassword(ctx *gin.Context)
- type AccountDatabase
- type AuxFunAPI
- type AuxFunDatabase
- type ClientAPI
- type ClientDatabase
- type DiagnosisAPI
- type DiagnosisDatabase
- type FaultAPI
- type FaultDatabase
- type HostAPI
- type HostDatabase
- type IssueAPI
- type IssueDatabase
- type LayoutAPI
- type LayoutDatabase
- type LocationAPI
- type LocationDatabase
- type MoldAPI
- type MoldDatabase
- type MoldFunAPI
- type MoldFunDatabase
- type MonitorAPI
- type MonitorDatabase
- type NoticeAPI
- type NoticeDatabase
- type NoticeFunAPI
- type NoticeFunDatabase
- type PPLogsAPI
- type PPLogsDatabase
- type PermissionsAPI
- type PermissionsDatabase
- type RoleAPI
- type RoleDatabase
- type SigninAPI
- type SigninDatabase
- type StudentAPI
- type StudentDatabase
- type SurveyAPI
- type SurveyDatabase
- type TerminalAPI
- type TerminalDatabase
- type UniversityAPI
- type UniversityDatabase
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccountAPI ¶
type AccountAPI struct {
DB AccountDatabase
}
The AccountAPI provides handlers for managing Account.
func (*AccountAPI) Delete ¶
func (sAPI *AccountAPI) Delete(ctx *gin.Context)
Delete deletes the Account by id
func (*AccountAPI) LoginAccount ¶
func (sAPI *AccountAPI) LoginAccount(ctx *gin.Context)
LoginAccount returns the Account by the given account and password or nil.
func (*AccountAPI) Update ¶
func (sAPI *AccountAPI) Update(ctx *gin.Context)
Update is updates a Account
func (*AccountAPI) UpdatePassword ¶
func (sAPI *AccountAPI) UpdatePassword(ctx *gin.Context)
UpdatePassword is updates a Account's Password
type AccountDatabase ¶
type AccountDatabase interface { AddAccount(lT *model.Account) *model.Account CountAccount() string DeleteAccount(uid primitive.ObjectID) error GetAccount() []*model.Account LoginAccount(account string, password string) *model.Account InitAccount() error UpdateAccount(lT *model.Account) *model.Account UpdateAccountPassword(lT *model.Account) *model.Account }
The AccountDatabase interface for encapsulating database access.
type AuxFunAPI ¶
type AuxFunAPI struct {
DB AuxFunDatabase
}
The AuxFunAPI provides handlers for managing AuxFun.
type AuxFunDatabase ¶
type AuxFunDatabase interface { AddAuxFun(lA *model.AuxFun) *model.AuxFun CountAuxFun() string DeleteAuxFun(uid primitive.ObjectID) error GetAuxFun() []*model.AuxFun InitAuxFun() error UpdateAuxFun(lA *model.AuxFun) *model.AuxFun }
The AuxFunDatabase interface for encapsulating database access.
type ClientAPI ¶
type ClientAPI struct {
DB ClientDatabase
}
The ClientAPI provides handlers for managing Client.
type ClientDatabase ¶
type ClientDatabase interface { AddClient(lA *model.Client) *model.Client CountClient() string DeleteClient(uid primitive.ObjectID) error GetClient() []*model.Client UpdateClient(lA *model.Client) *model.Client }
The ClientDatabase interface for encapsulating database access.
type DiagnosisAPI ¶
type DiagnosisAPI struct {
DB DiagnosisDatabase
}
The DiagnosisAPI provides handlers for managing Diagnosis.
func (*DiagnosisAPI) Delete ¶
func (sAPI *DiagnosisAPI) Delete(ctx *gin.Context)
Delete deletes a Diagnosis by uid
func (*DiagnosisAPI) Get ¶
func (sAPI *DiagnosisAPI) Get(ctx *gin.Context)
Get returns all the Diagnosis
func (*DiagnosisAPI) Update ¶
func (sAPI *DiagnosisAPI) Update(ctx *gin.Context)
Update is updates the Diagnosis
type DiagnosisDatabase ¶
type DiagnosisDatabase interface { AddDiagnosis(lA *model.Diagnosis) *model.Diagnosis CountDiagnosis() string DeleteDiagnosis(uid primitive.ObjectID) error GetDiagnosis() []*model.Diagnosis InitDiagnosis() error UpdateDiagnosis(lA *model.Diagnosis) *model.Diagnosis }
The DiagnosisDatabase interface for encapsulating database access.
type FaultAPI ¶
type FaultAPI struct {
DB FaultDatabase
}
The FaultAPI provides handlers for managing Fault.
type FaultDatabase ¶
type FaultDatabase interface { AddFault(lA *model.Fault) *model.Fault CountFault() string DeleteFault(uid primitive.ObjectID) error GetFault() []*model.Fault UpdateFault(lA *model.Fault) *model.Fault }
The FaultDatabase interface for encapsulating database access.
type HostAPI ¶
type HostAPI struct {
DB HostDatabase
}
The HostAPI provides handlers for managing Host.
type HostDatabase ¶
type HostDatabase interface { AddHost(lA *model.Host) *model.Host CountHost() string DeleteHost(uid primitive.ObjectID) error GetHost() []*model.Host InitHost() error UpdateHost(lA *model.Host) *model.Host }
The HostDatabase interface for encapsulating database access.
type IssueAPI ¶
type IssueAPI struct {
DB IssueDatabase
}
The IssueAPI provides handlers for managing Issue.
type IssueDatabase ¶
type IssueDatabase interface { AddIssue(lA *model.Issue) *model.Issue CountIssue() string DeleteIssue(uid primitive.ObjectID) error GetIssue() []*model.Issue InitIssue() error UpdateIssue(lA *model.Issue) *model.Issue }
The IssueDatabase interface for encapsulating database access.
type LayoutAPI ¶
type LayoutAPI struct {
DB LayoutDatabase
}
The LayoutAPI provides handlers for managing Layout.
type LayoutDatabase ¶
type LayoutDatabase interface { AddLayout(lA *model.Layout) *model.Layout CountLayout() string DeleteLayout(uid primitive.ObjectID) error GetLayout() []*model.Layout InitLayout() error UpdateLayout(lA *model.Layout) *model.Layout }
The LayoutDatabase interface for encapsulating database access.
type LocationAPI ¶
type LocationAPI struct {
DB LocationDatabase
}
The LocationAPI provides handlers for managing Location.
func (*LocationAPI) Delete ¶
func (sAPI *LocationAPI) Delete(ctx *gin.Context)
Delete deletes a Location by uid
func (*LocationAPI) Get ¶
func (sAPI *LocationAPI) Get(ctx *gin.Context)
Get returns all the Location
func (*LocationAPI) Update ¶
func (sAPI *LocationAPI) Update(ctx *gin.Context)
Update is updates the Location
type LocationDatabase ¶
type LocationDatabase interface { AddLocation(lA *model.Location) *model.Location CountLocation() string DeleteLocation(uid primitive.ObjectID) error GetLocation() []*model.Location UpdateLocation(lA *model.Location) *model.Location }
The LocationDatabase interface for encapsulating database access.
type MoldAPI ¶
type MoldAPI struct {
DB MoldDatabase
}
The MoldAPI provides handlers for managing Mold.
type MoldDatabase ¶
type MoldDatabase interface { AddMold(lA *model.Mold) *model.Mold CountMold() string DeleteMold(uid primitive.ObjectID) error GetMold() []*model.Mold InitMold() error UpdateMold(lA *model.Mold) *model.Mold }
The MoldDatabase interface for encapsulating database access.
type MoldFunAPI ¶
type MoldFunAPI struct {
DB MoldFunDatabase
}
The MoldFunAPI provides handlers for managing MoldFun.
func (*MoldFunAPI) Delete ¶
func (sAPI *MoldFunAPI) Delete(ctx *gin.Context)
Delete deletes a MoldFun by uid
func (*MoldFunAPI) Update ¶
func (sAPI *MoldFunAPI) Update(ctx *gin.Context)
Update is updates the MoldFun
type MoldFunDatabase ¶
type MoldFunDatabase interface { AddMoldFun(lA *model.MoldFun) *model.MoldFun CountMoldFun() string DeleteMoldFun(uid primitive.ObjectID) error GetMoldFun() []*model.MoldFun InitMoldFun() error UpdateMoldFun(lA *model.MoldFun) *model.MoldFun }
The MoldFunDatabase interface for encapsulating database access.
type MonitorAPI ¶
type MonitorAPI struct {
DB MonitorDatabase
}
The MonitorAPI provides handlers for managing Monitor.
func (*MonitorAPI) Delete ¶
func (sAPI *MonitorAPI) Delete(ctx *gin.Context)
Delete deletes a Monitor by uid
func (*MonitorAPI) Update ¶
func (sAPI *MonitorAPI) Update(ctx *gin.Context)
Update is updates the Monitor
type MonitorDatabase ¶
type MonitorDatabase interface { AddMonitor(lA *model.Monitor) *model.Monitor CountMonitor() string DeleteMonitor(uid primitive.ObjectID) error GetMonitor() []*model.Monitor UpdateMonitor(lA *model.Monitor) *model.Monitor }
The MonitorDatabase interface for encapsulating database access.
type NoticeAPI ¶
type NoticeAPI struct {
DB NoticeDatabase
}
The NoticeAPI provides handlers for managing Notice.
type NoticeDatabase ¶
type NoticeDatabase interface { AddNotice(lA *model.Notice) *model.Notice CountNotice() string DeleteNotice(uid primitive.ObjectID) error GetNotice() []*model.Notice InitNotice() error UpdateNotice(lA *model.Notice) *model.Notice }
The NoticeDatabase interface for encapsulating database access.
type NoticeFunAPI ¶
type NoticeFunAPI struct {
DB NoticeFunDatabase
}
The NoticeFunAPI provides handlers for managing NoticeFun.
func (*NoticeFunAPI) Delete ¶
func (sAPI *NoticeFunAPI) Delete(ctx *gin.Context)
Delete deletes a NoticeFun by uid
func (*NoticeFunAPI) Get ¶
func (sAPI *NoticeFunAPI) Get(ctx *gin.Context)
Get returns all the NoticeFun
func (*NoticeFunAPI) Update ¶
func (sAPI *NoticeFunAPI) Update(ctx *gin.Context)
Update is updates the NoticeFun
type NoticeFunDatabase ¶
type NoticeFunDatabase interface { AddNoticeFun(lA *model.NoticeFun) *model.NoticeFun CountNoticeFun() string DeleteNoticeFun(uid primitive.ObjectID) error GetNoticeFun() []*model.NoticeFun InitNoticeFun() error UpdateNoticeFun(lA *model.NoticeFun) *model.NoticeFun }
The NoticeFunDatabase interface for encapsulating database access.
type PPLogsAPI ¶
type PPLogsAPI struct {
DB PPLogsDatabase
}
The PPLogsAPI provides handlers for managing PPLogs.
type PPLogsDatabase ¶
type PPLogsDatabase interface { AddPPLogs(lA *model.PPLogs) *model.PPLogs CountPPLogs() string DeletePPLogs(uid primitive.ObjectID) error GetPPLogs() []*model.PPLogs UpdatePPLogs(lA *model.PPLogs) *model.PPLogs }
The PPLogsDatabase interface for encapsulating database access.
type PermissionsAPI ¶
type PermissionsAPI struct {
DB PermissionsDatabase
}
The PermissionsAPI provides handlers for managing Permissions.
func (*PermissionsAPI) Add ¶
func (sAPI *PermissionsAPI) Add(ctx *gin.Context)
Add creates a Permissions.
func (*PermissionsAPI) Delete ¶
func (sAPI *PermissionsAPI) Delete(ctx *gin.Context)
Delete deletes a Permissions by uid
func (*PermissionsAPI) Get ¶
func (sAPI *PermissionsAPI) Get(ctx *gin.Context)
Get returns all the Permissions
func (*PermissionsAPI) Update ¶
func (sAPI *PermissionsAPI) Update(ctx *gin.Context)
Update is updates the Permissions
type PermissionsDatabase ¶
type PermissionsDatabase interface { AddPermissions(lA *model.Permissions) *model.Permissions CountPermissions() string DeletePermissions(uid primitive.ObjectID) error GetPermissions() []*model.Permissions InitPermissions() error UpdatePermissions(lA *model.Permissions) *model.Permissions }
The PermissionsDatabase interface for encapsulating database access.
type RoleAPI ¶
type RoleAPI struct {
DB RoleDatabase
}
The RoleAPI provides handlers for managing Role.
type RoleDatabase ¶
type RoleDatabase interface { AddRole(lA *model.Role) *model.Role CountRole() string DeleteRole(uid primitive.ObjectID) error GetRole() []*model.Role FindRole(Auth uint) *model.Role InitRole() error UpdateRole(lA *model.Role) *model.Role }
The RoleDatabase interface for encapsulating database access.
type SigninAPI ¶
type SigninAPI struct {
DB SigninDatabase
}
The SigninAPI provides handlers for managing Signin.
type SigninDatabase ¶
type SigninDatabase interface { AddSignin(lA *model.Signin) *model.Signin CountSignin() string DeleteSignin(uid primitive.ObjectID) error GetSignin() []*model.Signin Signout(uid primitive.ObjectID) error }
The SigninDatabase interface for encapsulating database access.
type StudentAPI ¶
type StudentAPI struct {
DB StudentDatabase
}
The StudentAPI provides handlers for managing Student.
func (*StudentAPI) Delete ¶
func (sAPI *StudentAPI) Delete(ctx *gin.Context)
Delete deletes a Student by uid
func (*StudentAPI) LoginStudent ¶
func (sAPI *StudentAPI) LoginStudent(ctx *gin.Context)
LoginStudent returns the Student by the given SNo and Password or nil.
func (*StudentAPI) Update ¶
func (sAPI *StudentAPI) Update(ctx *gin.Context)
Update is updates the Student
type StudentDatabase ¶
type StudentDatabase interface { AddStudent(lA *model.Student) *model.Student CountStudent() string DeleteStudent(uid primitive.ObjectID) error GetStudent() []*model.Student ImportStudent(lA []model.Student) []*model.Student LoginStudent(SNo string, Password string) *model.Student UpdateStudent(lA *model.Student) *model.Student }
The StudentDatabase interface for encapsulating database access.
type SurveyAPI ¶
type SurveyAPI struct {
DB SurveyDatabase
}
The SurveyAPI provides handlers for managing Survey.
type SurveyDatabase ¶
type SurveyDatabase interface { AddSurvey(lA *model.Survey) *model.Survey CountSurvey() string DeleteSurvey(uid primitive.ObjectID) error GetSurvey() []*model.Survey InitSurvey() error UpdateSurvey(lA *model.Survey) *model.Survey }
The SurveyDatabase interface for encapsulating database access.
type TerminalAPI ¶
type TerminalAPI struct {
DB TerminalDatabase
}
The TerminalAPI provides handlers for managing Terminal.
func (*TerminalAPI) Delete ¶
func (sAPI *TerminalAPI) Delete(ctx *gin.Context)
Delete deletes a Terminal by uid
func (*TerminalAPI) Get ¶
func (sAPI *TerminalAPI) Get(ctx *gin.Context)
Get returns all the Terminal
func (*TerminalAPI) LoginTerminal ¶
func (sAPI *TerminalAPI) LoginTerminal(ctx *gin.Context)
LoginTerminal returns the Terminal by the given label and ip or nil.
func (*TerminalAPI) Update ¶
func (sAPI *TerminalAPI) Update(ctx *gin.Context)
Update is updates the Terminal
type TerminalDatabase ¶
type TerminalDatabase interface { AddTerminal(lA *model.Terminal) *model.Terminal CountTerminal() string DeleteTerminal(uid primitive.ObjectID) error GetTerminal() []*model.Terminal LoginTerminal(label string, ip string) *model.Terminal UpdateTerminal(lA *model.Terminal) *model.Terminal }
The TerminalDatabase interface for encapsulating database access.
type UniversityAPI ¶
type UniversityAPI struct {
DB UniversityDatabase
}
The UniversityAPI provides handlers for managing University.
func (*UniversityAPI) Add ¶
func (sAPI *UniversityAPI) Add(ctx *gin.Context)
Add creates a University.
func (*UniversityAPI) Delete ¶
func (sAPI *UniversityAPI) Delete(ctx *gin.Context)
Delete deletes a University by uid
func (*UniversityAPI) Get ¶
func (sAPI *UniversityAPI) Get(ctx *gin.Context)
Get returns all the University
func (*UniversityAPI) Update ¶
func (sAPI *UniversityAPI) Update(ctx *gin.Context)
Update is updates the University
type UniversityDatabase ¶
type UniversityDatabase interface { AddUniversity(lA *model.University) *model.University CountUniversity() string DeleteUniversity(uid primitive.ObjectID) error GetUniversity() []*model.University UpdateUniversity(lA *model.University) *model.University }
The UniversityDatabase interface for encapsulating database access.