web

package
v1.11.1 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateModelGroupReq

type CreateModelGroupReq struct {
	Name string `json:"name"`
}

type CreateModelRelationReq

type CreateModelRelationReq struct {
	SourceModelUID  string `json:"source_model_uid"`
	TargetModelUID  string `json:"target_model_uid"`
	RelationTypeUID string `json:"relation_type_uid"`
	Mapping         string `json:"mapping"`
}

type CreateModelReq

type CreateModelReq struct {
	Name    string `json:"name"`
	GroupId int64  `json:"group_id"`
	UID     string `json:"uid"`
	Icon    string `json:"icon"`
}

type DeleteModelByUidReq

type DeleteModelByUidReq struct {
	ModelUid string `json:"model_uid"`
}

type DeleteModelGroup

type DeleteModelGroup struct {
	ID int64 `json:"id"`
}

type DeleteModelRelationReq

type DeleteModelRelationReq struct {
	Id int64 `json:"id"`
}

type DetailModelReq

type DetailModelReq struct {
	ID int64 `json:"id"`
}

type GetByUidsReq

type GetByUidsReq struct {
	Uids []string `json:"uids"`
}

type Handler

type Handler struct {
	RMSvc relationservice.RelationModelService
	capability.IRegistry
	// contains filtered or unexported fields
}

func (*Handler) CreateModel

func (h *Handler) CreateModel(ctx *gin.Context, req CreateModelReq) (ginx.Result, error)

func (*Handler) CreateModelGroup

func (h *Handler) CreateModelGroup(ctx *gin.Context, req CreateModelGroupReq) (ginx.Result, error)

func (*Handler) CreateModelRelation

func (h *Handler) CreateModelRelation(ctx *gin.Context, req CreateModelRelationReq) (ginx.Result, error)

func (*Handler) DeleteModelByUid

func (h *Handler) DeleteModelByUid(ctx *gin.Context, req DeleteModelByUidReq) (ginx.Result, error)

func (*Handler) DeleteModelGroup

func (h *Handler) DeleteModelGroup(ctx *gin.Context, req DeleteModelGroup) (ginx.Result, error)

func (*Handler) DeleteModelRelation

func (h *Handler) DeleteModelRelation(ctx *gin.Context, req DeleteModelRelationReq) (ginx.Result, error)

func (*Handler) DetailModel

func (h *Handler) DetailModel(ctx *gin.Context) (ginx.Result, error)

func (*Handler) FindModelsGraph

func (h *Handler) FindModelsGraph(ctx *gin.Context, req Page) (ginx.Result, error)

FindModelsGraph 查询模型拓扑图

func (*Handler) GetByUids

func (h *Handler) GetByUids(ctx *gin.Context, req GetByUidsReq) (ginx.Result, error)

func (*Handler) ListModelGroups

func (h *Handler) ListModelGroups(ctx *gin.Context, req Page) (ginx.Result, error)

func (*Handler) ListModelUIDRelation

func (h *Handler) ListModelUIDRelation(ctx *gin.Context, req ListModelRelationReq) (ginx.Result, error)

ListModelUIDRelation 根据模型唯一索引名称,查询所有关联信息

func (*Handler) ListModels

func (h *Handler) ListModels(ctx *gin.Context, req Page) (ginx.Result, error)

func (*Handler) ListModelsByGroup

func (h *Handler) ListModelsByGroup(ctx *gin.Context, req Page) (ginx.Result, error)

func (*Handler) PrivateRoutes

func (h *Handler) PrivateRoutes(server *gin.Engine)

PrivateRoutes 注册模型管理模块需要中心化登录及权限判定(由 EIAM SDK 统一拦截承载)的私有路由

func (*Handler) RenameModelGroup

func (h *Handler) RenameModelGroup(ctx *gin.Context, req RenameModelGroupReq) (ginx.Result, error)

func (*Handler) UpdateModelRelation

func (h *Handler) UpdateModelRelation(ctx *gin.Context, req UpdateModelRelationReq) (ginx.Result, error)

type ListModelRelationReq

type ListModelRelationReq struct {
	Page
	ModelUid string `json:"model_uid"`
}

type Model

type Model struct {
	Id   int64  `json:"id"`
	Name string `json:"name"`
	UID  string `json:"uid"`
	Icon string `json:"icon"`
	// 记录模型下面有多少资产
	Total   int    `json:"total"`
	Ctime   string `json:"ctime"`
	Utime   string `json:"utime"`
	Builtin bool   `json:"builtin"`
}

type ModelGroup

type ModelGroup struct {
	Id   int64  `json:"id"`
	Name string `json:"name"`
}

type ModelGroupItem

type ModelGroupItem struct {
	GroupID   int64    `json:"group_id"`
	GroupName string   `json:"group_name"`
	ModelUIDs []string `json:"model_uids"`
}

type ModelLine

type ModelLine struct {
	From string `json:"from"`
	To   string `json:"to"`
	Text string `json:"text"`
}

type ModelNode

type ModelNode struct {
	ID   string            `json:"id"`
	Text string            `json:"text"`
	Data map[string]string `json:"data,omitempty"`
}

type ModelRelation

type ModelRelation struct {
	ID              int64  `json:"id"`
	SourceModelUID  string `json:"source_model_uid"`
	TargetModelUID  string `json:"target_model_uid"`
	RelationTypeUID string `json:"relation_type_uid"`
	RelationName    string `json:"relation_name"`
	Mapping         string `json:"mapping"`
}

type ModelSummaryVO

type ModelSummaryVO struct {
	ID            int64  `json:"id"`
	GroupID       int64  `json:"group_id"`
	Name          string `json:"name"`
	UID           string `json:"uid"`
	Icon          string `json:"icon"`
	ResourceCount int    `json:"resource_count"`
	Builtin       bool   `json:"builtin"`
}

type Page

type Page struct {
	Offset int64 `json:"offset,omitempty"`
	Limit  int64 `json:"limit,omitempty"`
}

type RenameModelGroupReq

type RenameModelGroupReq struct {
	ID   int64  `json:"id"`
	Name string `json:"name"`
}

type RetrieveModelGroupedListResp

type RetrieveModelGroupedListResp struct {
	Total  int64            `json:"total"`
	Groups []ModelGroupItem `json:"groups"`
	Models []ModelSummaryVO `json:"models"`
}

type RetrieveModelGroupsListResp

type RetrieveModelGroupsListResp struct {
	Total int64        `json:"total,omitempty"`
	Mgs   []ModelGroup `json:"model_groups,omitempty"`
}

type RetrieveModelsListResp

type RetrieveModelsListResp struct {
	Total  int64   `json:"total,omitempty"`
	Models []Model `json:"models,omitempty"`
}

type RetrieveRelationModelGraph

type RetrieveRelationModelGraph struct {
	RootId string      `json:"rootId"`
	Nodes  []ModelNode `json:"nodes"`
	Lines  []ModelLine `json:"lines"`
}

type RetrieveRelationModels

type RetrieveRelationModels struct {
	Total          int64           `json:"total,omitempty"`
	ModelRelations []ModelRelation `json:"model_relations,omitempty"`
}

type UpdateModelRelationReq

type UpdateModelRelationReq struct {
	ID              int64  `json:"id"`
	SourceModelUID  string `json:"source_model_uid"`
	TargetModelUID  string `json:"target_model_uid"`
	RelationTypeUID string `json:"relation_type_uid"`
	Mapping         string `json:"mapping"`
}

Jump to

Keyboard shortcuts

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