0
0
mirror of https://github.com/go-gitea/gitea.git synced 2025-02-21 00:34:26 +01:00
gitea/models
Lunny Xiao 72518a8dab
Rework suggestion backend (#33538)
Fix #33522 

The suggestion backend logic now is

- If the keyword is empty, returned the latest 5 issues/prs with index
desc order
- If the keyword is digital, find all issues/prs which `index` has a
prefix with that, with index asc order
- If the keyword is non-digital or if the queried records less than 5,
searching issues/prs title with a `like`, with index desc order

## Empty keyword
<img width="310" alt="image"
src="https://github.com/user-attachments/assets/1912c634-0d98-4eeb-8542-d54240901f77"
/>

## Digital
<img width="479" alt="image"
src="https://github.com/user-attachments/assets/0356a936-7110-4a24-b21e-7400201bf9b8"
/>

## Digital and title contains the digital
<img width="363" alt="image"
src="https://github.com/user-attachments/assets/6e12f908-28fe-48de-8ccc-09cbeab024d4"
/>

## non-Digital
<img width="435" alt="image"
src="https://github.com/user-attachments/assets/2722bb53-baa2-4d67-a224-522a65f73856"
/>
<img width="477" alt="image"
src="https://github.com/user-attachments/assets/06708dd9-80d1-4a88-b32b-d29072dd1ba6"
/>

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2025-02-10 16:24:05 +00:00
..
actions Refactor RefName (#33234) 2025-01-13 14:01:53 +08:00
activities Add missed auto merge feed message on dashboard (#33309) 2025-01-26 18:33:05 +00:00
admin Fix javascript error when an anonymous user visiting migration page (#32144) 2024-10-02 04:37:16 +00:00
asymkey Use ProtonMail/go-crypto to replace keybase/go-crypto (#33402) 2025-01-27 09:14:08 +08:00
auth Refactor tests (#33021) 2024-12-29 01:05:56 +00:00
avatars
db Refactor context flash msg and global variables (#33375) 2025-01-25 14:36:47 +00:00
dbfs
fixtures Support choose email when creating a commit via web UI (more) (#33445) 2025-01-31 02:36:18 +00:00
git Improve sync fork behavior (#33319) 2025-01-20 15:17:47 +08:00
issues Rework suggestion backend (#33538) 2025-02-10 16:24:05 +00:00
migrations Automerge supports deleting branch automatically after merging (#32343) 2025-01-10 03:51:03 +08:00
organization Worktime tracking for the organization level (#19808) 2025-02-03 01:51:12 +08:00
packages Refactor maven package registry (#33049) 2024-12-31 05:30:52 +00:00
perm Support public code/issue access for private repositories (#33127) 2025-01-14 01:53:34 +00:00
project Add alphabetical project sorting (#33504) 2025-02-05 19:09:43 +00:00
pull Automerge supports deleting branch automatically after merging (#32343) 2025-01-10 03:51:03 +08:00
renderhelper Refactor render system (orgmode) (#32671) 2024-11-29 16:08:29 +08:00
repo Refactor repository transfer (#33211) 2025-01-30 05:40:44 +00:00
secret Clarify Actions resources ownership (#31724) 2024-08-01 09:04:04 +00:00
shared/types
system chore: fix some trivial problems and TODOs (#33473) 2025-02-02 18:16:56 +00:00
unit Add DEFAULT_MIRROR_REPO_UNITS and DEFAULT_TEMPLATE_REPO_UNITS options (#32416) 2024-11-11 00:11:00 +00:00
unittest Refactor ref type (#33242) 2025-01-14 15:35:34 +08:00
user Add a option "--user-type bot" to admin user create, improve role display (#27885) 2025-02-07 08:41:55 +00:00
webhook Refactor webhook events (#33337) 2025-01-23 18:53:06 +00:00
main_test.go
repo_test.go Fix issue comment number (#30556) 2024-12-30 14:35:46 -08:00
repo.go Fix issue comment number (#30556) 2024-12-30 14:35:46 -08:00