Files
iotlcm/admin-svr/server/internal/model/agent_role.go

70 lines
2.7 KiB
Go

package model
import "github.com/gogf/gf/v2/os/gtime"
type AgentRoleSyncMessage struct {
TemplateRole bool `json:"templateRole,omitempty"`
Superseded bool `json:"superseded,omitempty"`
TaskId string `json:"taskId,omitempty"`
TotalCount int `json:"totalCount,omitempty"`
SuccessCount int `json:"successCount,omitempty"`
FailedCount int `json:"failedCount,omitempty"`
TenantId string `json:"tenantId"`
SourceRoleId int64 `json:"sourceRoleId"`
SourceDeptId int64 `json:"sourceDeptId"`
ActorId int64 `json:"actorId"`
RetryCount int `json:"retryCount"`
ChildDeptIds []int64 `json:"childDeptIds,omitempty"`
}
type AgentRoleSyncDeadLetterMessage struct {
Message AgentRoleSyncMessage `json:"message"`
Error string `json:"error"`
FailedAt string `json:"failedAt"`
}
type AgentRoleListParam struct {
RoleName string `json:"roleName"`
RoleKey string `json:"roleKey"`
Status string `json:"status"`
CreatedAt []string `json:"createdAt"`
}
type AgentRoleListModel struct {
RoleId int64 `json:"roleId" orm:"role_id"`
TenantId string `json:"tenantId" orm:"tenant_id"`
DeptId int64 `json:"deptId" orm:"dept_id"`
RoleName string `json:"roleName" orm:"role_name"`
RoleKey string `json:"roleKey" orm:"role_key"`
Status string `json:"status" orm:"status"`
IsPass int `json:"isPass" orm:"is_pass"`
SourceRoleId int64 `json:"sourceRoleId" orm:"source_role_id"`
SourceDeptId int64 `json:"sourceDeptId" orm:"source_dept_id"`
CreatedAt *gtime.Time `json:"createdAt" orm:"created_at"`
Remark string `json:"remark" orm:"remark"`
IsDefaultRole bool `json:"isDefaultRole"`
}
type AgentRoleSaveParam struct {
RoleId int64 `json:"roleId"`
DeptId int64 `json:"deptId"`
RoleName string `json:"roleName"`
RoleKey string `json:"roleKey"`
RoleSort int `json:"roleSort"`
DataScope string `json:"dataScope"`
MenuCheckStrictly int `json:"menuCheckStrictly"`
DeptCheckStrictly int `json:"deptCheckStrictly"`
Status string `json:"status"`
IsPass int `json:"isPass"`
Remark string `json:"remark"`
MenuIds []int64 `json:"menuIds"`
CreatedAt *gtime.Time `json:"createdAt"`
}
type AgentRoleViewModel struct {
SysRoleViewModel
AllowedMenuIds []int64 `json:"allowedMenuIds"`
MenuTree []*SysMenuTreeModel `json:"menuTree"`
IsDefaultRole bool `json:"isDefaultRole"`
}