mirror of
https://gitee.com/dromara/mayfly-go
synced 2025-12-09 09:20:25 +08:00
refactor: 初步提交全局授权凭证-资源多账号改造
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
package form
|
||||
|
||||
import tagentity "mayfly-go/internal/tag/domain/entity"
|
||||
|
||||
type MachineForm struct {
|
||||
Id uint64 `json:"id"`
|
||||
Protocol int `json:"protocol" binding:"required"`
|
||||
@@ -8,11 +10,8 @@ type MachineForm struct {
|
||||
Ip string `json:"ip" binding:"required"` // IP地址
|
||||
Port int `json:"port" binding:"required"` // 端口号
|
||||
|
||||
// 资产授权凭证信息列表
|
||||
AuthCertId int `json:"authCertId"`
|
||||
TagId []uint64 `json:"tagId" binding:"required"`
|
||||
Username string `json:"username"`
|
||||
Password string `json:"password"`
|
||||
TagId []uint64 `json:"tagId" binding:"required"`
|
||||
AuthCerts []*tagentity.ResourceAuthCert // 资产授权凭证信息列表
|
||||
|
||||
Remark string `json:"remark"`
|
||||
SshTunnelMachineId int `json:"sshTunnelMachineId"` // ssh隧道机器id
|
||||
@@ -24,14 +23,6 @@ type MachineRunForm struct {
|
||||
Cmd string `json:"cmd" binding:"required"`
|
||||
}
|
||||
|
||||
type MachineFileForm struct {
|
||||
Id uint64 `json:"id"`
|
||||
Name string `json:"name" binding:"required"`
|
||||
MachineId uint64 `json:"machineId" binding:"required"`
|
||||
Type int `json:"type" binding:"required"`
|
||||
Path string `json:"path" binding:"required"`
|
||||
}
|
||||
|
||||
type MachineScriptForm struct {
|
||||
Id uint64 `json:"id"`
|
||||
Name string `json:"name" binding:"required"`
|
||||
@@ -42,39 +33,6 @@ type MachineScriptForm struct {
|
||||
Script string `json:"script" binding:"required"`
|
||||
}
|
||||
|
||||
type ServerFileOptionForm struct {
|
||||
MachineId uint64 `form:"machineId"`
|
||||
Protocol int `form:"protocol"`
|
||||
Path string `form:"path"`
|
||||
Type string `form:"type"`
|
||||
Content string `form:"content"`
|
||||
Id uint64 `form:"id"`
|
||||
FileId uint64 `form:"fileId"`
|
||||
}
|
||||
|
||||
type MachineFileUpdateForm struct {
|
||||
Content string `json:"content" binding:"required"`
|
||||
Id uint64 `json:"id" binding:"required"`
|
||||
Path string `json:"path" binding:"required"`
|
||||
}
|
||||
|
||||
type MachineFileOpForm struct {
|
||||
Path []string `json:"path" binding:"required"`
|
||||
ToPath string `json:"toPath"`
|
||||
MachineId uint64 `json:"machineId" binding:"required"`
|
||||
Protocol int `json:"protocol" binding:"required"`
|
||||
FileId uint64 `json:"fileId" binding:"required"`
|
||||
}
|
||||
|
||||
type MachineFileRename struct {
|
||||
MachineId uint64 `json:"machineId" binding:"required"`
|
||||
Protocol int `json:"protocol" binding:"required"`
|
||||
FileId uint64 `json:"fileId" binding:"required"`
|
||||
|
||||
Oldname string `json:"oldname" binding:"required"`
|
||||
Newname string `json:"newname" binding:"required"`
|
||||
}
|
||||
|
||||
// 授权凭证
|
||||
type AuthCertForm struct {
|
||||
Id uint64 `json:"id"`
|
||||
|
||||
Reference in New Issue
Block a user