Conversation

tyroneyeh

Reopening PR due to branch rename
Close #30381 #12974 #27984 #30163

Add my test results video Gitea Multiple Projects Feature Test Steps

@GiteaBotGiteaBot added the lgtm/need 2This PR needs two approvals by maintainers to be considered for merging.label May 7, 2025
@github-actions-actions bot added modifies/apiThis PR adds API routes or modifies themmodifies/goPull requests that update Go codemodifies/templatesThis PR modifies the template fileslabels May 7, 2025
@lunnylunny added this to the 1.25.0 milestone May 7, 2025
@tyroneyeh

Hi @lunny

Could you please review and confirm the issue on db-tests?

@lunny
  • db-tests / test-unit (pull_request)

The test failure is related. This one has been added to my review list.

@tyroneyeh

Fixed unit test issues

@tyroneyeh

Add my test results video Gitea Multiple Projects Feature Test Steps

@tyroneyeh

Any questions?

@GiteaBotGiteaBot added lgtm/need 1This PR needs approval from one additional maintainer to be merged.and removed lgtm/need 2This PR needs two approvals by maintainers to be considered for merging.labels May 20, 2025
return 0
func (issue *Issue) projectIDs(ctx context.Context) []int64 {
var ids []int64
if err := db.GetEngine(ctx).Table("project_issue").Where("issue_id=?", issue.ID).Select("project_id").Find(&ids); err != nil {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's not safe to ignore the err, in case the SQL would be wrong.

@@ -96,71 +90,88 @@ func LoadIssuesFromColumn(ctx context.Context, b *project_model.Column, opts *Is

// IssueAssignOrRemoveProject changes the project associated with an issue
// If newProjectID is 0, the issue is removed from the project
func IssueAssignOrRemoveProject(ctx context.Context, issue *Issue, doer *user_model.User, newProjectID, newColumnID int64) error {
func IssueAssignOrRemoveProject(ctx context.Context, issue *Issue, doer *user_model.User, newProjectIDs []int64, newColumnID int64) error {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How could it be right?

Why newColumnID could apply to all newProjectIDs?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Default to uncategorized

@@ -30,7 +30,7 @@ type IndexerData struct {
LabelIDs []int64 `json:"label_ids"`
NoLabel bool `json:"no_label"` // True if LabelIDs is empty
MilestoneID int64 `json:"milestone_id"`
ProjectID int64 `json:"project_id"`
ProjectIDs []int64 `json:"project_id"`
Copy link
Contributor

@wxiaoguang wxiaoguang May 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not think the change is right for indexers, I am pretty sure it breaks existing indexers and the JSON field type doesn't match.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@wxiaoguang Can you help me fix this problem?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I would get some time (but I can't promise at the moment)

Sign up for free to join this conversation on . Already have an account? Sign in to comment
lgtm/need 1This PR needs approval from one additional maintainer to be merged.modifies/apiThis PR adds API routes or modifies themmodifies/goPull requests that update Go codemodifies/templatesThis PR modifies the template files
None yet

Successfully merging this pull request may close these issues.