diff options
author | Unknwon <u@gogs.io> | 2015-08-14 02:43:40 +0800 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2015-08-14 02:43:40 +0800 |
commit | 817b48ed1e083b5291afd339bda573cba14bba8d (patch) | |
tree | 52a38a2c63c49afb45d45ac3fc06b3c730aa9cca /models/issue.go | |
parent | 1fb53067f478414302096d5d976a3db85df9e2eb (diff) | |
download | gitea-817b48ed1e083b5291afd339bda573cba14bba8d.tar.gz gitea-817b48ed1e083b5291afd339bda573cba14bba8d.zip |
Show owner/poster tags of comments and fix #1312
Diffstat (limited to 'models/issue.go')
-rw-r--r-- | models/issue.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/models/issue.go b/models/issue.go index 174e3102d9..7f16f936a3 100644 --- a/models/issue.go +++ b/models/issue.go @@ -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. |