You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gitea/templates/repo/issue
sillyguodong bfecf3bd89
Fix internal sever error when visiting a PR that bound to the deleted team (#24127)
Close: #23738

The actual cause of `500 Internal Server Error` in the issue is not what
is descirbed in the issue.

The actual cause is that after deleting team, if there is a PR which has
requested reivew from the deleted team, the comment could not match with
the deleted team by `assgin_team_id`. So the value of `.AssigneeTeam`
(see below code block) is `nil` which cause `500 error`.


1c8bc4081a/templates/repo/issue/view_content/comments.tmpl (L691-L695)

To fix this bug, there are the following problems to be resolved:

- [x] 1. ~~Stroe the name of the team in `content` column when inserting
`comment` into DB in case that we cannot get the name of team after it
is deleted. But for comments that already exist, just display "Unknown
Team"~~ Just display "Ghost Team" in the comment if the assgined team is
deleted.
- [x] 2. Delete the PR&team binding (the row of which `review_team_id =
${team_id} ` in table `review`) when deleting team.
- [x] 3.For already exist and undeleted binding rows in in table
`review`, ~~we can delete these rows when executing migrations.~~ they
do not affect the function, so won't delete them.
2 years ago
..
fields Introduce GitHub markdown editor, keep EasyMDE as fallback (#23876) 2 years ago
labels Remove "inverted" class on creating new label and cancel buttons (#24030) 2 years ago
view_content Fix internal sever error when visiting a PR that bound to the deleted team (#24127) 2 years ago
branch_selector_field.tmpl Refactor hiding-methods, remove jQuery show/hide, remove `.hide` class, remove inline style=display:none (#22950) 2 years ago
choose.tmpl Implement Issue Config (#20956) 2 years ago
comment_tab.tmpl Improve markdown editor: width, height, preferred (#23895) 2 years ago
label_precolors.tmpl Fix purple color in suggested label colors (#18241) 3 years ago
labels.tmpl Convert `<div class="button">` to `<button class="button">` (#23337) 2 years ago
list.tmpl Merge template functions "dict/Dict/mergeinto" (#23932) 2 years ago
milestone_issues.tmpl Localize milestone related time strings (#24051) 2 years ago
milestone_new.tmpl Add main landmark to templates and adjust titles (#22670) 2 years ago
milestones.tmpl Refactor locale number (#24134) 2 years ago
navbar.tmpl Add some headings to repo views (#22869) 2 years ago
new.tmpl Add main landmark to templates and adjust titles (#22670) 2 years ago
new_form.tmpl Merge template functions "dict/Dict/mergeinto" (#23932) 2 years ago
openclose.tmpl Refactor locale number (#24134) 2 years ago
search.tmpl Remove incorrect HTML self close tag (#23748) 2 years ago
view.tmpl Add main landmark to templates and adjust titles (#22670) 2 years ago
view_content.tmpl Group template helper functions, remove `Printf`, improve template error messages (#23982) 2 years ago
view_title.tmpl Use data-tooltip-content for tippy tooltip (#23649) 2 years ago