1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-22 18:28:37 +00:00

Show owner/poster tags of comments and fix #1312

This commit is contained in:
Unknwon
2015-08-14 02:43:40 +08:00
parent 1fb53067f4
commit 817b48ed1e
16 changed files with 164 additions and 57 deletions

View File

@@ -1231,6 +1231,15 @@ const (
COMMENT_TYPE_PULL_REF
)
type CommentTag int
const (
COMMENT_TAG_NONE CommentTag = iota
COMMENT_TAG_POSTER
COMMENT_TAG_ADMIN
COMMENT_TAG_OWNER
)
// Comment represents a comment in commit and issue page.
type Comment struct {
ID int64 `xorm:"pk autoincr"`
@@ -1245,6 +1254,9 @@ type Comment struct {
Created time.Time `xorm:"CREATED"`
Attachments []*Attachment `xorm:"-"`
// For view issue page.
ShowTag CommentTag `xorm:"-"`
}
// HashTag returns unique hash tag for comment.