api

package
v0.0.0-...-870d972 Latest Latest
Warning

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

Go to latest
Published: Sep 24, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrorResponse

func ErrorResponse(c *gin.Context, status int, message string)

ErrorResponse 返回错误的 JSON 响应

func GetTaskStatus

func GetTaskStatus(c *gin.Context)

func LoginHandler

func LoginHandler(c *gin.Context)

LoginHandler 处理登录请求并生成 JWT Token

func SuccessResponse

func SuccessResponse(c *gin.Context, data interface{})

SuccessResponse 返回成功的 JSON 响应

Types

type EnvHandler

type EnvHandler struct {
	EnvService *services.EnvService
}

func NewEnvHandler

func NewEnvHandler(envService *services.EnvService) *EnvHandler

在初始化时创建 Handler 实例

func (*EnvHandler) CheckPyenvInstalledHandler

func (h *EnvHandler) CheckPyenvInstalledHandler(c *gin.Context)

CheckPyenvInstalledHandler 检查 pyenv 是否安装

func (*EnvHandler) CreateVirtualenvHandler

func (h *EnvHandler) CreateVirtualenvHandler(c *gin.Context)

func (*EnvHandler) DeletePythonVersionHandler

func (h *EnvHandler) DeletePythonVersionHandler(c *gin.Context)

func (*EnvHandler) DeleteVirtualenvHandler

func (h *EnvHandler) DeleteVirtualenvHandler(c *gin.Context)

func (*EnvHandler) GetPackageVersionsHandler

func (h *EnvHandler) GetPackageVersionsHandler(c *gin.Context)

func (*EnvHandler) GetPyenvPythonVersionHandler

func (h *EnvHandler) GetPyenvPythonVersionHandler(c *gin.Context)

func (*EnvHandler) GetRemotePythonVersionHandler

func (h *EnvHandler) GetRemotePythonVersionHandler(c *gin.Context)

func (*EnvHandler) GetVirtualenvByNameHandler

func (h *EnvHandler) GetVirtualenvByNameHandler(c *gin.Context)

func (*EnvHandler) InstallPackageHandler

func (h *EnvHandler) InstallPackageHandler(c *gin.Context)

func (*EnvHandler) InstallPythonHandler

func (h *EnvHandler) InstallPythonHandler(c *gin.Context)

func (*EnvHandler) InstallRequirementsHandler

func (h *EnvHandler) InstallRequirementsHandler(c *gin.Context)

func (*EnvHandler) SetVersionGlobalHandler

func (h *EnvHandler) SetVersionGlobalHandler(c *gin.Context)

func (*EnvHandler) UninstallPackageHandler

func (h *EnvHandler) UninstallPackageHandler(c *gin.Context)

func (*EnvHandler) VirtualenvPipInstallPackagesHandler

func (h *EnvHandler) VirtualenvPipInstallPackagesHandler(c *gin.Context)

type GitHandler

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

func NewGitHandler

func NewGitHandler(gitService *services.GitService, projectService *services.ProjectService) *GitHandler

func (GitHandler) BranchPullHandler

func (g GitHandler) BranchPullHandler(c *gin.Context)

func (GitHandler) CreateGitConfigHandler

func (g GitHandler) CreateGitConfigHandler(c *gin.Context)

func (GitHandler) GitByProjectIdHandler

func (g GitHandler) GitByProjectIdHandler(c *gin.Context)

func (GitHandler) RemoteBranchCommitsHandler

func (g GitHandler) RemoteBranchCommitsHandler(c *gin.Context)

func (GitHandler) RemoteBranchesHandler

func (g GitHandler) RemoteBranchesHandler(c *gin.Context)

type JWTClaims

type JWTClaims struct {
	Username string `json:"username"`
	jwt.StandardClaims
}

type ProjectHandler

type ProjectHandler struct {
	ProjectService *services.ProjectService
}

func NewProjectHandler

func NewProjectHandler(projectService *services.ProjectService) *ProjectHandler

func (*ProjectHandler) AddProjectHandler

func (p *ProjectHandler) AddProjectHandler(c *gin.Context)

func (*ProjectHandler) DeleteProjectHandler

func (p *ProjectHandler) DeleteProjectHandler(c *gin.Context)

func (*ProjectHandler) GetAllProjectsHandler

func (p *ProjectHandler) GetAllProjectsHandler(c *gin.Context)

func (*ProjectHandler) GetFolderContentsHandler

func (p *ProjectHandler) GetFolderContentsHandler(c *gin.Context)

func (*ProjectHandler) ProjectByIdHandler

func (p *ProjectHandler) ProjectByIdHandler(c *gin.Context)

func (*ProjectHandler) ProjectsByVersionHandler

func (p *ProjectHandler) ProjectsByVersionHandler(c *gin.Context)

func (*ProjectHandler) ReUploadHandler

func (p *ProjectHandler) ReUploadHandler(c *gin.Context)

func (*ProjectHandler) ReadFileHandler

func (p *ProjectHandler) ReadFileHandler(c *gin.Context)

func (*ProjectHandler) SaveFileHandler

func (p *ProjectHandler) SaveFileHandler(c *gin.Context)

Jump to

Keyboard shortcuts

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