comment

package
v1.0.18 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const APIPath_CreateComment = "/open_api/:project_key/work_item/:work_item_type_key/:work_item_id/comment/create"
View Source
const APIPath_CreateFileComment = "/open_api/:project_key/work_item/:work_item_type_key/:work_item_id/file_comment/create"
View Source
const APIPath_DeleteComment = "/open_api/:project_key/work_item/:work_item_type_key/:work_item_id/comment/:comment_id"
View Source
const APIPath_ListComments = "/open_api/:project_key/work_item/:work_item_type_key/:work_item_id/comments"
View Source
const APIPath_ListFileComments = "/open_api/:project_key/work_item/:work_item_type_key/:work_item_id/file_comments"
View Source
const APIPath_UpdateComment = "/open_api/:project_key/work_item/:work_item_type_key/:work_item_id/comment/:comment_id"

Variables

This section is empty.

Functions

This section is empty.

Types

type CommentForOpenAPI

type CommentForOpenAPI struct {
	ID *int64 `json:"id,omitempty"`

	WorkItemID *int64 `json:"work_item_id,omitempty"`

	WorkItemTypeKey *string `json:"work_item_type_key,omitempty"`

	CreatedAt *int64 `json:"created_at,omitempty"`

	Operator *string `json:"operator,omitempty"`

	Content *string `json:"content,omitempty"`

	DocRichText *DocTypeRichText `json:"doc_rich_text,omitempty"`
}

type CommentService

type CommentService struct {
	// contains filtered or unexported fields
}

func NewService

func NewService(config *core.Config) *CommentService

func (*CommentService) CreateComment

func (a *CommentService) CreateComment(ctx context.Context, req *CreateCommentReq, options ...core.RequestOptionFunc) (*CreateCommentResp, error)
  • comment openapi接口

@name:APICreateCommentForOpen

  • @desc:OpenAPI,创建评论接口

func (*CommentService) CreateFileComment added in v1.0.18

func (a *CommentService) CreateFileComment(ctx context.Context, req *CreateFileCommentReq, options ...core.RequestOptionFunc) (*CreateFileCommentResp, error)

* @name:OAPICreateFileComment * @desc:OpenAPI,创建附件评论接口

func (*CommentService) DeleteComment

func (a *CommentService) DeleteComment(ctx context.Context, req *DeleteCommentReq, options ...core.RequestOptionFunc) (*DeleteCommentResp, error)

* @name:APIDeleteCommentForOpen * @desc:OpenAPI,删除评论接口

func (*CommentService) ListComments

func (a *CommentService) ListComments(ctx context.Context, req *ListCommentsReq, options ...core.RequestOptionFunc) (*ListCommentsResp, error)

* @name:APIListCommentsForOpen * @desc:OpenAPI,分页查询评论接口

func (*CommentService) ListFileComments added in v1.0.18

func (a *CommentService) ListFileComments(ctx context.Context, req *ListFileCommentsReq, options ...core.RequestOptionFunc) (*ListFileCommentsResp, error)

* @name:OAPIListFileComments * @desc:OpenAPI,分页查询附件评论接口

func (*CommentService) UpdateComment

func (a *CommentService) UpdateComment(ctx context.Context, req *UpdateCommentReq, options ...core.RequestOptionFunc) (*UpdateCommentResp, error)

* @name:APIUpdateCommentForOpen * @desc:OpenAPI,更新评论接口

type CreateCommentReq

type CreateCommentReq struct {
	// contains filtered or unexported fields
}

type CreateCommentReqBody

type CreateCommentReqBody struct {
	Content     *string          `json:"content,omitempty"`
	RichText    interface{}      `json:"rich_text,omitempty"`
	DocRichText *DocTypeRichText `json:"doc_rich_text,omitempty"`
}

type CreateCommentReqBuilder

type CreateCommentReqBuilder struct {
	// contains filtered or unexported fields
}

func NewCreateCommentReqBuilder

func NewCreateCommentReqBuilder() *CreateCommentReqBuilder

func (*CreateCommentReqBuilder) Build

func (builder *CreateCommentReqBuilder) Build() *CreateCommentReq

func (*CreateCommentReqBuilder) Content

func (builder *CreateCommentReqBuilder) Content(content string) *CreateCommentReqBuilder

func (*CreateCommentReqBuilder) DocRichText added in v1.0.18

func (builder *CreateCommentReqBuilder) DocRichText(docRichText *DocTypeRichText) *CreateCommentReqBuilder

func (*CreateCommentReqBuilder) ProjectKey

func (builder *CreateCommentReqBuilder) ProjectKey(projectKey string) *CreateCommentReqBuilder

func (*CreateCommentReqBuilder) RichText

func (builder *CreateCommentReqBuilder) RichText(richText interface{}) *CreateCommentReqBuilder

func (*CreateCommentReqBuilder) WorkItemID

func (builder *CreateCommentReqBuilder) WorkItemID(workItemID int64) *CreateCommentReqBuilder

func (*CreateCommentReqBuilder) WorkItemTypeKey

func (builder *CreateCommentReqBuilder) WorkItemTypeKey(workItemTypeKey string) *CreateCommentReqBuilder

type CreateCommentResp

type CreateCommentResp struct {
	*core.APIResp `json:"-"`
	core.CodeError
	Data *int64 `json:"data"`
}

type CreateFileCommentReq added in v1.0.18

type CreateFileCommentReq struct {
	// contains filtered or unexported fields
}

type CreateFileCommentReqBody added in v1.0.18

type CreateFileCommentReqBody struct {
	FileToken *string `json:"file_token,omitempty"`
}

type CreateFileCommentReqBuilder added in v1.0.18

type CreateFileCommentReqBuilder struct {
	// contains filtered or unexported fields
}

func NewCreateFileCommentReqBuilder added in v1.0.18

func NewCreateFileCommentReqBuilder() *CreateFileCommentReqBuilder

func (*CreateFileCommentReqBuilder) Build added in v1.0.18

func (*CreateFileCommentReqBuilder) FileToken added in v1.0.18

func (builder *CreateFileCommentReqBuilder) FileToken(fileToken string) *CreateFileCommentReqBuilder

func (*CreateFileCommentReqBuilder) ProjectKey added in v1.0.18

func (builder *CreateFileCommentReqBuilder) ProjectKey(projectKey string) *CreateFileCommentReqBuilder

func (*CreateFileCommentReqBuilder) WorkItemID added in v1.0.18

func (builder *CreateFileCommentReqBuilder) WorkItemID(workItemID int64) *CreateFileCommentReqBuilder

func (*CreateFileCommentReqBuilder) WorkItemTypeKey added in v1.0.18

func (builder *CreateFileCommentReqBuilder) WorkItemTypeKey(workItemTypeKey string) *CreateFileCommentReqBuilder

type CreateFileCommentResp added in v1.0.18

type CreateFileCommentResp struct {
	*core.APIResp `json:"-"`
	core.CodeError
	Data *int64 `json:"data"`
}

type DeleteCommentReq

type DeleteCommentReq struct {
	// contains filtered or unexported fields
}

type DeleteCommentReqBuilder

type DeleteCommentReqBuilder struct {
	// contains filtered or unexported fields
}

func NewDeleteCommentReqBuilder

func NewDeleteCommentReqBuilder() *DeleteCommentReqBuilder

func (*DeleteCommentReqBuilder) Build

func (builder *DeleteCommentReqBuilder) Build() *DeleteCommentReq

func (*DeleteCommentReqBuilder) CommentID

func (builder *DeleteCommentReqBuilder) CommentID(commentID int64) *DeleteCommentReqBuilder

func (*DeleteCommentReqBuilder) ProjectKey

func (builder *DeleteCommentReqBuilder) ProjectKey(projectKey string) *DeleteCommentReqBuilder

func (*DeleteCommentReqBuilder) WorkItemID

func (builder *DeleteCommentReqBuilder) WorkItemID(workItemID int64) *DeleteCommentReqBuilder

func (*DeleteCommentReqBuilder) WorkItemTypeKey

func (builder *DeleteCommentReqBuilder) WorkItemTypeKey(workItemTypeKey string) *DeleteCommentReqBuilder

type DeleteCommentResp

type DeleteCommentResp struct {
	*core.APIResp `json:"-"`
	core.CodeError
}

type DocTypeRichText added in v1.0.18

type DocTypeRichText struct {
	Doc *string `json:"doc,omitempty"`

	DocText *string `json:"doc_text,omitempty"`

	DocHTML *string `json:"doc_html,omitempty"`

	DocImg []string `json:"doc_img,omitempty"`

	IsEmpty *bool `json:"is_empty,omitempty"`
}

type FileCommentForOpenAPI added in v1.0.18

type FileCommentForOpenAPI struct {
	ID *int64 `json:"id,omitempty"`

	WorkItemID *int64 `json:"work_item_id,omitempty"`

	WorkItemTypeKey *string `json:"work_item_type_key,omitempty"`

	CreatedAt *int64 `json:"created_at,omitempty"`

	Operator *string `json:"operator,omitempty"`

	CommentFile *FileDetail `json:"comment_file,omitempty"`
}

type FileDetail added in v1.0.18

type FileDetail struct {
	FileToken *string `json:"file_token,omitempty"`

	FileName *string `json:"file_name,omitempty"`

	FileSize *int64 `json:"file_size,omitempty"`

	FileType *string `json:"file_type,omitempty"`

	FileUrl *string `json:"file_url,omitempty"`
}

type ListCommentsReq

type ListCommentsReq struct {
	// contains filtered or unexported fields
}

type ListCommentsReqBuilder

type ListCommentsReqBuilder struct {
	// contains filtered or unexported fields
}

func NewListCommentsReqBuilder

func NewListCommentsReqBuilder() *ListCommentsReqBuilder

func (*ListCommentsReqBuilder) Build

func (builder *ListCommentsReqBuilder) Build() *ListCommentsReq

func (*ListCommentsReqBuilder) PageNum

func (builder *ListCommentsReqBuilder) PageNum(pageNum int64) *ListCommentsReqBuilder

func (*ListCommentsReqBuilder) PageSize

func (builder *ListCommentsReqBuilder) PageSize(pageSize int64) *ListCommentsReqBuilder

func (*ListCommentsReqBuilder) ProjectKey

func (builder *ListCommentsReqBuilder) ProjectKey(projectKey string) *ListCommentsReqBuilder

func (*ListCommentsReqBuilder) WorkItemID

func (builder *ListCommentsReqBuilder) WorkItemID(workItemID int64) *ListCommentsReqBuilder

func (*ListCommentsReqBuilder) WorkItemTypeKey

func (builder *ListCommentsReqBuilder) WorkItemTypeKey(workItemTypeKey string) *ListCommentsReqBuilder

type ListCommentsResp

type ListCommentsResp struct {
	*core.APIResp `json:"-"`
	core.CodeError
	Data []CommentForOpenAPI `json:"data"`

	Pagination *Pagination `json:"pagination"`
}

type ListFileCommentsReq added in v1.0.18

type ListFileCommentsReq struct {
	// contains filtered or unexported fields
}

type ListFileCommentsReqBuilder added in v1.0.18

type ListFileCommentsReqBuilder struct {
	// contains filtered or unexported fields
}

func NewListFileCommentsReqBuilder added in v1.0.18

func NewListFileCommentsReqBuilder() *ListFileCommentsReqBuilder

func (*ListFileCommentsReqBuilder) Build added in v1.0.18

func (*ListFileCommentsReqBuilder) PageNum added in v1.0.18

func (builder *ListFileCommentsReqBuilder) PageNum(pageNum int64) *ListFileCommentsReqBuilder

func (*ListFileCommentsReqBuilder) PageSize added in v1.0.18

func (builder *ListFileCommentsReqBuilder) PageSize(pageSize int64) *ListFileCommentsReqBuilder

func (*ListFileCommentsReqBuilder) ProjectKey added in v1.0.18

func (builder *ListFileCommentsReqBuilder) ProjectKey(projectKey string) *ListFileCommentsReqBuilder

func (*ListFileCommentsReqBuilder) WorkItemID added in v1.0.18

func (builder *ListFileCommentsReqBuilder) WorkItemID(workItemID int64) *ListFileCommentsReqBuilder

func (*ListFileCommentsReqBuilder) WorkItemTypeKey added in v1.0.18

func (builder *ListFileCommentsReqBuilder) WorkItemTypeKey(workItemTypeKey string) *ListFileCommentsReqBuilder

type ListFileCommentsResp added in v1.0.18

type ListFileCommentsResp struct {
	*core.APIResp `json:"-"`
	core.CodeError
	Data []FileCommentForOpenAPI `json:"data"`

	Pagination *Pagination `json:"pagination"`
}

type Pagination

type Pagination struct {
	PageNum *int64 `json:"page_num,omitempty"`

	PageSize *int64 `json:"page_size,omitempty"`

	Total *int64 `json:"total,omitempty"`
}

type UpdateCommentReq

type UpdateCommentReq struct {
	// contains filtered or unexported fields
}

type UpdateCommentReqBody

type UpdateCommentReqBody struct {
	Content  *string     `json:"content,omitempty"`
	RichText interface{} `json:"rich_text,omitempty"`
}

type UpdateCommentReqBuilder

type UpdateCommentReqBuilder struct {
	// contains filtered or unexported fields
}

func NewUpdateCommentReqBuilder

func NewUpdateCommentReqBuilder() *UpdateCommentReqBuilder

func (*UpdateCommentReqBuilder) Build

func (builder *UpdateCommentReqBuilder) Build() *UpdateCommentReq

func (*UpdateCommentReqBuilder) CommentID

func (builder *UpdateCommentReqBuilder) CommentID(commentID int64) *UpdateCommentReqBuilder

func (*UpdateCommentReqBuilder) Content

func (builder *UpdateCommentReqBuilder) Content(content string) *UpdateCommentReqBuilder

func (*UpdateCommentReqBuilder) ProjectKey

func (builder *UpdateCommentReqBuilder) ProjectKey(projectKey string) *UpdateCommentReqBuilder

func (*UpdateCommentReqBuilder) RichText

func (builder *UpdateCommentReqBuilder) RichText(richText interface{}) *UpdateCommentReqBuilder

func (*UpdateCommentReqBuilder) WorkItemID

func (builder *UpdateCommentReqBuilder) WorkItemID(workItemID int64) *UpdateCommentReqBuilder

func (*UpdateCommentReqBuilder) WorkItemTypeKey

func (builder *UpdateCommentReqBuilder) WorkItemTypeKey(workItemTypeKey string) *UpdateCommentReqBuilder

type UpdateCommentResp

type UpdateCommentResp struct {
	*core.APIResp `json:"-"`
	core.CodeError
}

Jump to

Keyboard shortcuts

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