提交 f6bcdc50 编写于 作者: S shaowenchen

feature: add annotations to pipelines for getting syncstatus

Signed-off-by: Nshaowenchen <mail@chenshaowen.com>
上级 000d3097
...@@ -19,6 +19,7 @@ bin/ ...@@ -19,6 +19,7 @@ bin/
# Vscode files # Vscode files
.vscode/ .vscode/
__debug_bin
# OSX trash # OSX trash
.DS_Store .DS_Store
......
...@@ -112,7 +112,8 @@ func (h *ProjectPipelineHandler) ListPipelines(req *restful.Request, resp *restf ...@@ -112,7 +112,8 @@ func (h *ProjectPipelineHandler) ListPipelines(req *restful.Request, resp *restf
} else { } else {
pipelineMap[pipeline.Name] = i pipelineMap[pipeline.Name] = i
pipelineList.Items[i] = clientDevOps.Pipeline{ pipelineList.Items[i] = clientDevOps.Pipeline{
Name: pipeline.Name, Name: pipeline.Name,
Annotations: pipeline.Annotations,
} }
} }
} }
......
...@@ -31,8 +31,9 @@ type PipelineList struct { ...@@ -31,8 +31,9 @@ type PipelineList struct {
// GetPipeline & SearchPipelines // GetPipeline & SearchPipelines
type Pipeline struct { type Pipeline struct {
Class string `json:"_class,omitempty" description:"It’s a fully qualified name and is an identifier of the producer of this resource's capability." ` Annotations map[string]string `json:"annotations,omitempty" description:"Add annotations from crd" `
Links struct { Class string `json:"_class,omitempty" description:"It’s a fully qualified name and is an identifier of the producer of this resource's capability." `
Links struct {
Self struct { Self struct {
Class string `json:"_class,omitempty"` Class string `json:"_class,omitempty"`
Href string `json:"href,omitempty"` Href string `json:"href,omitempty"`
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册