Documentation
¶
Index ¶
- type AdminSearchPagedResourcesReq
- type AdminSearchStructureModelVO
- type AdminSearchStructureReq
- type AdminSearchStructureTenantVO
- type CreateResourceRelationReq
- type CreateResourceReq
- type DeleteResourceRelationReq
- type DeleteResourceReq
- type DetailResourceReq
- type FindSecureReq
- type GraphModel
- type Handler
- func (h *Handler) AdminSearchStructure(ctx *ginx.Context, req AdminSearchStructureReq) (ginx.Result, error)
- func (h *Handler) CreateResource(ctx *ginx.Context, req CreateResourceReq) (ginx.Result, error)
- func (h *Handler) CreateResourceRelation(ctx *ginx.Context, req CreateResourceRelationReq) (ginx.Result, error)
- func (h *Handler) DeleteResource(ctx *ginx.Context, req DeleteResourceReq) (ginx.Result, error)
- func (h *Handler) DeleteResourceRelation(ctx *ginx.Context, req DeleteResourceRelationReq) (ginx.Result, error)
- func (h *Handler) DetailResource(ctx *ginx.Context, req DetailResourceReq) (ginx.Result, error)
- func (h *Handler) FindAllGraph(ctx *ginx.Context, req ListDiagramReq) (ginx.Result, error)
- func (h *Handler) FindLeftGraph(ctx *ginx.Context, req ListDiagramReq) (ginx.Result, error)
- func (h *Handler) FindRightGraph(ctx *ginx.Context, req ListDiagramReq) (ginx.Result, error)
- func (h *Handler) FindSecureData(ctx *ginx.Context, req FindSecureReq) (ginx.Result, error)
- func (h *Handler) IdentifyRoutes(_ *gin.Engine)
- func (h *Handler) ListAllAggregated(ctx *ginx.Context, req ListResourceDiagramReq) (ginx.Result, error)
- func (h *Handler) ListCanBeFilterRelated(ctx *ginx.Context, req ListCanBeRelatedReqByModel) (ginx.Result, error)
- func (h *Handler) ListResource(ctx *ginx.Context, req ListResourceReq) (ginx.Result, error)
- func (h *Handler) ListResourceByIds(ctx *ginx.Context, req ListResourceByIdsReq) (ginx.Result, error)
- func (h *Handler) PrivateRoutes(server *gin.Engine)
- func (h *Handler) PublicRoutes(_ *gin.Engine)
- func (h *Handler) SearchPagedResources(ctx *ginx.Context, req SearchPagedResourcesReq) (ginx.Result, error)
- func (h *Handler) SearchStructure(ctx *ginx.Context, req SearchStructureReq) (ginx.Result, error)
- func (h *Handler) SetCustomField(ctx *ginx.Context, req SetCustomFieldReq) (ginx.Result, error)
- func (h *Handler) UpdateResource(ctx *ginx.Context, req UpdateResourceReq) (ginx.Result, error)
- type Line
- type ListCanBeRelatedReqByModel
- type ListDiagramReq
- type ListResourceByIdsReq
- type ListResourceDiagramReq
- type ListResourceReq
- type Node
- type Page
- type Resource
- type RetrieveAdminSearchStructure
- type RetrieveAggregatedAssets
- type RetrieveGraph
- type RetrieveResources
- type RetrieveSearchStructure
- type SearchPagedResourcesReq
- type SearchStructureReq
- type SetCustomFieldReq
- type UpdateResourceReq
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdminSearchPagedResourcesReq ¶ added in v1.11.4
type AdminSearchPagedResourcesReq = SearchPagedResourcesReq
type AdminSearchStructureModelVO ¶ added in v1.11.4
type AdminSearchStructureModelVO struct {
ModelUID string `json:"model_uid"`
ModelName string `json:"model_name"`
Total int `json:"total"`
}
AdminSearchStructureModelVO 单个模型 Tab 的统计与名称
type AdminSearchStructureReq ¶ added in v1.11.4
type AdminSearchStructureReq struct {
Text string `json:"text"`
}
type AdminSearchStructureTenantVO ¶ added in v1.11.4
type AdminSearchStructureTenantVO struct {
TenantID int64 `json:"tenant_id"`
TenantType string `json:"tenant_type"`
Total int `json:"total"`
Models []AdminSearchStructureModelVO `json:"models"`
}
AdminSearchStructureTenantVO 租户维度统计与下属模型 Tabs
type CreateResourceReq ¶
type DeleteResourceReq ¶
type DeleteResourceReq struct {
Id int64 `json:"id"`
}
type DetailResourceReq ¶
type FindSecureReq ¶
type GraphModel ¶
type GraphModel struct {
ModelUID string `json:"model_uid"`
ModelName string `json:"model_name"`
Icon string `json:"icon,omitempty"`
}
GraphModel 拓扑图模型图例元数据
type Handler ¶
type Handler struct {
capability.IRegistry
// contains filtered or unexported fields
}
func NewHandler ¶
func NewHandler(svc service.EncryptedSvc, attributeSvc attributeservice.Service, modelSvc modelservice.Service, rrSvc relationservice.RelationResourceService) *Handler
func (*Handler) AdminSearchStructure ¶ added in v1.11.4
func (h *Handler) AdminSearchStructure(ctx *ginx.Context, req AdminSearchStructureReq) (ginx.Result, error)
AdminSearchStructure 跨租户全局大盘结构与导航检索 NOTE: 纯数值聚合,不拉取资产 data 实体,10ms 极速画出左侧租户树与右侧模型 Tabs
func (*Handler) CreateResource ¶
func (*Handler) CreateResourceRelation ¶
func (*Handler) DeleteResource ¶
func (*Handler) DeleteResourceRelation ¶
func (*Handler) DetailResource ¶
func (*Handler) FindAllGraph ¶
func (*Handler) FindLeftGraph ¶
func (*Handler) FindRightGraph ¶
func (*Handler) FindSecureData ¶
func (*Handler) IdentifyRoutes ¶ added in v1.11.2
func (*Handler) ListAllAggregated ¶
func (*Handler) ListCanBeFilterRelated ¶
func (*Handler) ListResource ¶
func (*Handler) ListResourceByIds ¶
func (*Handler) PrivateRoutes ¶
PrivateRoutes 注册资源管理模块需要中心化登录及权限判定(由 EIAM SDK 统一拦截承载)的私有路由
func (*Handler) PublicRoutes ¶ added in v1.11.2
func (*Handler) SearchPagedResources ¶ added in v1.11.4
func (h *Handler) SearchPagedResources(ctx *ginx.Context, req SearchPagedResourcesReq) (ginx.Result, error)
SearchPagedResources 模型资产物理分页检索(支持指定租户或默认租户上下文)
func (*Handler) SearchStructure ¶ added in v1.11.4
SearchStructure 单租户检索模型 Tabs 概览(两阶段模式:阶段一)
func (*Handler) SetCustomField ¶
func (*Handler) UpdateResource ¶
type ListCanBeRelatedReqByModel ¶
type ListCanBeRelatedReqByModel struct {
Page
ResourceId int64 `json:"resource_id"` // 当前资源ID
ModelUid string `json:"model_uid"` // 目标模型ID
RelationName string `json:"relation_name"` // 关联类型,以方便推断是数据正向 OR 反向
FilterName string `json:"filter_name"` // 过滤名称
FilterCondition string `json:"filter_condition"` // 过滤条件
FilterInput string `json:"filter_input"` // 过滤输入
}
type ListDiagramReq ¶
type ListResourceByIdsReq ¶
type ListResourceDiagramReq ¶
type ListResourceReq ¶
type Node ¶
type Node struct {
ID string `json:"id"`
Text string `json:"text"`
ExpandHolderPosition string `json:"expandHolderPosition,omitempty"`
Expanded bool `json:"expanded"`
Data map[string]any `json:"data,omitempty"`
}
Node 拓扑图单个节点
type Resource ¶
type Resource struct {
ID int64 `json:"id"`
Name string `json:"name"`
ModelUID string `json:"model_uid"`
Data mongox.MapStr `json:"data"`
}
Resource 单个资产对象展示视图
type RetrieveAdminSearchStructure ¶ added in v1.11.4
type RetrieveAdminSearchStructure struct {
Total int `json:"total"`
Organizations []AdminSearchStructureTenantVO `json:"organizations"`
Personals []AdminSearchStructureTenantVO `json:"personals"`
}
RetrieveAdminSearchStructure 全局大盘结构与导航响应(支撑左侧租户树 + 右侧模型Tabs)
type RetrieveAggregatedAssets ¶
type RetrieveAggregatedAssets struct {
RelationName string `json:"relation_name"`
ModelUid string `json:"model_uid"`
Total int `json:"total"`
ResourceIds []int64 `json:"resource_ids"`
}
RetrieveAggregatedAssets 资产关联关系聚合统计视图
type RetrieveGraph ¶
type RetrieveGraph struct {
RootId string `json:"rootId"`
Nodes []Node `json:"nodes"`
Lines []Line `json:"lines"`
Models []GraphModel `json:"models,omitempty"`
}
RetrieveGraph 资产关联拓扑图全貌视图
type RetrieveResources ¶
type RetrieveResources struct {
Resources []Resource `json:"resources"`
Total int64 `json:"total"`
}
RetrieveResources 资产列表查询结果
type RetrieveSearchStructure ¶ added in v1.11.4
type RetrieveSearchStructure struct {
Total int `json:"total"`
Models []AdminSearchStructureModelVO `json:"models"`
}
RetrieveSearchStructure 单租户检索模型 Tabs 概览响应
type SearchPagedResourcesReq ¶ added in v1.11.4
type SearchStructureReq ¶ added in v1.11.4
type SearchStructureReq struct {
Text string `json:"text"`
}