controllers

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetLoggedName

func GetLoggedName(c *gin.Context) string

Types

type AppController

type AppController struct {
	// contains filtered or unexported fields
}

func NewAppController

func NewAppController(appModel models.AppModel, appServer *appserver.AppServer, config config.Config) *AppController

Create a new controller object

func (*AppController) DeleteApp

func (ctl *AppController) DeleteApp() gin.HandlerFunc

Controller function to delete a R app

func (*AppController) GetApp

func (ctl *AppController) GetApp() gin.HandlerFunc

Render an app details page

func (*AppController) GetApps

func (ctl *AppController) GetApps() gin.HandlerFunc

Render apps page

func (*AppController) UpdateApp

func (ctl *AppController) UpdateApp() gin.HandlerFunc

Update or create an app

type AppSettings

type AppSettings struct {
	Name           string   `form:"appname" binding:"required"`
	Path           string   `form:"path" binding:"required"`
	Properties     []string `form:"properties[]"`
	RestrictAccess int      `form:"restrictaccess"`
	AllowedGroups  []string `form:"allowedgroups"`
	AppSource      string   `form:"appsource"`
	AppDir         string   `form:"appdir"`
	Workers        int      `form:"workers"`
}

Form bindings for apps settings

type AuthController

type AuthController struct {
	// contains filtered or unexported fields
}

func NewAuthController

func NewAuthController(userModel models.UserModel) *AuthController

func (*AuthController) DoLogin

func (ctl *AuthController) DoLogin() gin.HandlerFunc

func (*AuthController) DoLogout

func (ctl *AuthController) DoLogout() gin.HandlerFunc

func (*AuthController) DoSignup

func (ctl *AuthController) DoSignup() gin.HandlerFunc

type GroupController

type GroupController struct {
	// contains filtered or unexported fields
}

func NewGroupController

func NewGroupController(groupModel models.GroupModel) *GroupController

func (*GroupController) AddGroupMember

func (ctl *GroupController) AddGroupMember() gin.HandlerFunc

func (*GroupController) DeleteGroup

func (ctl *GroupController) DeleteGroup() gin.HandlerFunc

func (*GroupController) GetGroup

func (ctl *GroupController) GetGroup() gin.HandlerFunc

func (*GroupController) GetGroups

func (ctl *GroupController) GetGroups() gin.HandlerFunc

func (*GroupController) RemoveGroupMember

func (ctl *GroupController) RemoveGroupMember() gin.HandlerFunc

func (*GroupController) UpdateGroup

func (ctl *GroupController) UpdateGroup() gin.HandlerFunc

type GroupPayload

type GroupPayload struct {
	GroupName string `form:"groupname" binding:"required"`
}

type UserController

type UserController struct {
	// contains filtered or unexported fields
}

func NewUserController

func NewUserController(userModel models.UserModel) *UserController

func (*UserController) AdminUpdateUser

func (userCtl *UserController) AdminUpdateUser() gin.HandlerFunc

func (*UserController) DeleteUser

func (userCtl *UserController) DeleteUser() gin.HandlerFunc

func (*UserController) GetUser

func (userCtl *UserController) GetUser() gin.HandlerFunc

func (*UserController) GetUsers

func (userCtl *UserController) GetUsers() gin.HandlerFunc

Get all users

Jump to

Keyboard shortcuts

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