service

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2025 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CategoryService

type CategoryService struct {
}

func (*CategoryService) GetList

func (cs *CategoryService) GetList(req request.CategoryList) (list interface{}, total int64, err error)

type ConfigService added in v1.1.0

type ConfigService struct {
}

func (*ConfigService) Get added in v1.1.0

func (cs *ConfigService) Get()

func (*ConfigService) GetInitStep added in v1.1.0

func (cs *ConfigService) GetInitStep() (res response.InitStepValue, errCode error)

GetInitStep @description: 获取初始化步骤 @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/29 10:01 @success:

func (*ConfigService) GetRunDate added in v1.1.0

func (cs *ConfigService) GetRunDate() (res response.SysRunDate, errCode error)

GetRunDate @description: 获取系统运行时长 @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/28 11:36 @success:

func (*ConfigService) GetValueStr added in v1.1.0

func (cs *ConfigService) GetValueStr(k string) (v string, errCode error)

GetValueStr @description: 根据k获取v @param: k string @author: GJing @email: gjing1st@gmail.com @date: 2022/12/27 11:08 @success:

func (*ConfigService) SetCacheValue added in v1.1.0

func (cs *ConfigService) SetCacheValue(k, v interface{}) (errCode error)

SetCacheValue @description: 设置缓存 @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/27 15:27 @success:

func (*ConfigService) SetValue added in v1.1.0

func (cs *ConfigService) SetValue(k string, v interface{}) (errCode error)

SetValue @description: 设置k-v值,先持久化再更新缓存 @param: @author: GJing @email: gjing1st@gmail.com @date: 2023/2/15 14:01 @success:

func (*ConfigService) SysReset added in v1.1.0

func (cs *ConfigService) SysReset() (err error)

SysReset @description: 恢复出厂设置 @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/30 13:48 @success:

func (*ConfigService) VersionInfo added in v1.1.0

func (cs *ConfigService) VersionInfo() (res response.VersionInfo)

VersionInfo @description: 获取当前版本信息 @param: @author: GJing @email: gjing1st@gmail.com @date: 2023/1/4 9:35 @success:

type SysService added in v1.1.0

type SysService struct {
}

func (*SysService) Reboot added in v1.1.0

func (ss *SysService) Reboot() (errCode error)

Reboot @description: 服务器重启 @param: @author: GJing @email: gjing1st@gmail.com @date: 2023/2/11 16:30 @success:

func (*SysService) ServerStatus added in v1.1.0

func (ss *SysService) ServerStatus() (res response.ServerStatus, errCode error)

ServerStatus @description: 设备运行状态 @param: @author: GJing @email: gjing1st@gmail.com @date: 2023/2/9 20:29 @success:

type TokenService added in v1.1.0

type TokenService struct {
}

func (TokenService) GenerateToken added in v1.1.0

func (td TokenService) GenerateToken(u *entity.UserTokenInfo) (token string, errCode error)

GenerateToken @description: 生成token @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/4/15 14:37 @success:

func (TokenService) GetInfo added in v1.1.0

func (td TokenService) GetInfo(token string) (u entity.UserTokenInfo, errCode error)

GetInfo @description: 获取token对应的信息 @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/27 18:22 @success:

func (TokenService) RemoveToken added in v1.1.0

func (td TokenService) RemoveToken(token string) bool

type UserService added in v1.1.0

type UserService struct {
}

func (*UserService) ChangePasswd added in v1.1.0

func (us *UserService) ChangePasswd(req *request.ChangePasswd, username string, loginType int) error

ChangePasswd @Description 修改用户名口令密码 @params @contact.name GJing @contact.email gjing1st@gmail.com @date 2023/6/8 9:39

func (*UserService) Create added in v1.1.0

func (us *UserService) Create(req *request.UserCreate) (err error)

Create @description: 创建管理员 @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/27 15:58 @success:

func (*UserService) CreateUser added in v1.1.0

func (us *UserService) CreateUser(req *request.UserCreate) (errCode error)

CreateUser @description: 创建用户 @param: @author: GJing @email: gjing1st@gmail.com @date: 2023/3/17 14:26 @success:

func (*UserService) DeleteById added in v1.1.0

func (us *UserService) DeleteById(userid int) (errCode error)

DeleteById @description: 删除指定id @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/30 11:26 @success:

func (*UserService) DeleteUser added in v1.1.0

func (us *UserService) DeleteUser(req *request.UserDelete) (errCode error)

DeleteUser @description: 删除管理员 @param: @author: GJing @email: gjing1st@gmail.com @date: 2023/3/17 16:18 @success:

func (*UserService) InfoByName added in v1.1.0

func (us *UserService) InfoByName(name string) (list interface{}, total int64, errCode error)

InfoByName @description: 操作员查询管理员列表 @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/29 20:19 @success:

func (*UserService) List added in v1.1.0

func (us *UserService) List(req *request.UserList) (list interface{}, total int64, errCode error)

List @description: 用户列表 @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/28 17:25 @success:

func (*UserService) Login added in v1.1.0

func (us *UserService) Login(req *request.UserLogin) (res response.UserLogin, err error)

Login @description: 管理员登录 @param: @author: GJing @email: gjing1st@gmail.com @date: 2022/12/27 17:05 @success:

Jump to

Keyboard shortcuts

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