diff options
author | Jimmy Praet <jimmy.praet@telenet.be> | 2021-01-08 22:49:55 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-08 23:49:55 +0200 |
commit | bcb7f352215be12368de937fc0faa91cdb3d639a (patch) | |
tree | fa981e5c0110df8a094d7f3e3ba0ffdf2469c194 /modules/auth | |
parent | ce43d38b4ffa40255cc8f859c5b31f59351f827c (diff) | |
download | gitea-bcb7f352215be12368de937fc0faa91cdb3d639a.tar.gz gitea-bcb7f352215be12368de937fc0faa91cdb3d639a.zip |
Do not reload page after adding comments in Pull Request reviews (#13877)
Fixed #8861
* use ajax on PR review page
* handle review comments
* extract duplicate code
FetchCodeCommentsByLine was initially more or less copied from fetchCodeCommentsByReview. Now they both use a common findCodeComments function instead
* use the Engine that was passed into the method
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Lauris BH <lauris@nix.lv>
Diffstat (limited to 'modules/auth')
-rw-r--r-- | modules/auth/repo_form.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/auth/repo_form.go b/modules/auth/repo_form.go index 87f2a53510..78b2197a2d 100644 --- a/modules/auth/repo_form.go +++ b/modules/auth/repo_form.go @@ -548,6 +548,7 @@ func (f *MergePullRequestForm) Validate(ctx *macaron.Context, errs binding.Error // CodeCommentForm form for adding code comments for PRs type CodeCommentForm struct { + Origin string `binding:"Required;In(timeline,diff)"` Content string `binding:"Required"` Side string `binding:"Required;In(previous,proposed)"` Line int64 |