summaryrefslogtreecommitdiffstats
path: root/models/issues
Commit message (Collapse)AuthorAgeFilesLines
* Modify milestone search keywords to be case insensitive (#20266) (#20498)Tyrone Yeh2022-07-271-1/+6
| | | | | | | | | * Modify milestone search keywords to be case insensitive (#20266) Milestone search keywords are now sensitive, this modification is changed to insensitive * Modify for #18437 Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* Dismiss prior pull reviews if done via web in review dismiss (#20197) (#20407)65432022-07-191-0/+30
|
* Fix org label open count, including close count issue (#20364)Tyrone Yeh2022-07-141-0/+2
|
* Fix checks in PR for empty commits (#20290) (#20352)Ing. Jaroslav Šafka2022-07-131-0/+6
| | | | | | | | | | | | Backport #20290 * Fix #19603 * fill HeadCommitID in PullRequest * compare real commits ID as check for merging Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Andrew Thornton <art27@cantab.net>
* Check if project has the same repository id with issue when assign project ↵Lunny Xiao2022-07-012-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | | to issue (#20133) (#20188) * Check if project has the same repository id with issue when assign project to issue * Check if issue's repository id match project's repository id * Add more permission checking * Remove invalid argument * Fix errors * Add generic check * Remove duplicated check * Return error + add check for new issues * Apply suggestions from code review Co-authored-by: Gusted <williamzijl7@hotmail.com> Co-authored-by: KN4CK3R <admin@oldschoolhack.me> Co-authored-by: 6543 <6543@obermui.de>
* Fix CountOrphanedLabels in orphan check (#20009)zeripath2022-06-171-1/+1
| | | | | | gitea doctor --run check-db-consistency is currently broken due to an incorrect and old use of Count() with a string. Signed-off-by: Andrew Thornton <art27@cantab.net>
* In code search, get code unit accessible repos in one (main) query (#19764)Hugo Hoitink2022-06-161-2/+2
| | | | | | | | | | * When non-admin users use code search, get code unit accessible repos in one main query * Modified some comments to match the changes * Removed unnecessary check for Access Mode in Collaboration table Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: Lauris BH <lauris@nix.lv>
* Move tests as seperate sub packages to reduce duplicated file names (#19951)Lunny Xiao2022-06-151-3/+4
|
* Move issues related files into models/issues (#19931)Lunny Xiao2022-06-1337-103/+12291
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Move access and repo permission to models/perm/access * fix test * fix git test * Move functions sequence * Some improvements per @KN4CK3R and @delvh * Move issues related code to models/issues * Move some issues related sub package * Merge * Fix test * Fix test * Fix test * Fix test * Rename some files
* Move almost all functions' parameter db.Engine to context.Context (#19748)Lunny Xiao2022-05-204-33/+31
| | | | * Move almost all functions' parameter db.Engine to context.Context * remove some unnecessary wrap functions
* Use a struct as test options (#19393)Lunny Xiao2022-04-141-6/+9
| | | | | | | * Use a struct as test options * Fix name * Fix test
* Move milestone to models/issues/ (#19278)Lunny Xiao2022-04-083-0/+938
| | | | | | | | | | | * Move milestone to models/issues/ * Fix lint * Fix test * Fix lint * Fix lint
* Move reaction to models/issues/ (#19264)Lunny Xiao2022-03-313-1/+562
| | | | | | | | | | | | | | | * Move reaction to models/issues/ * Fix test * move the function * improve code * Update models/issues/reaction.go Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Show fullname on issue edits and gpg/ssh signing info (#18827)Wim2022-02-202-3/+5
| | | | | Show missing full names when configured to do so Co-authored-by: zeripath <art27@cantab.net>
* format with gofumpt (#18184)65432022-01-201-1/+0
| | | | | | | | | | | * gofumpt -w -l . * gofumpt -w -l -extra . * Add linter * manual fix * change make fmt
* Simplify parameter types (#18006)Gusted2021-12-201-2/+2
| | | Remove repeated type declarations in function definitions.
* Improvements to content history (#17746)Jimmy Praet2021-11-222-7/+25
| | | | | | | | | | | * Improvements to content history * initialize content history when making an edit to an old item created before the introduction of content history * show edit history for code comments on pull request files tab * Fix a flaw in keepLimitedContentHistory Fix a flaw in keepLimitedContentHistory, the first and the last should never be deleted * Remove obsolete eager initialization of content history
* Decouple unit test code from business code (#17623)wxiaoguang2021-11-122-3/+4
|
* Fix history count failure (#17351)Lunny Xiao2021-10-211-1/+1
| | | Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Save and view issue/comment content history (#16909)wxiaoguang2021-10-103-0/+320
* issue content history * Use timeutil.TimeStampNow() for content history time instead of issue/comment.UpdatedUnix (which are not updated in time) * i18n for frontend * refactor * clean up * fix refactor * re-format * temp refactor * follow db refactor * rename IssueContentHistory to ContentHistory, remove empty model tags * fix html * use avatar refactor to generate avatar url * add unit test, keep at most 20 history revisions. * re-format * syntax nit * Add issue content history table * Update models/migrations/v197.go Co-authored-by: 6543 <6543@obermui.de> * fix merge Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: Lauris BH <lauris@nix.lv>