Add a new section named development in issue view sidebar to interact with branch/pr#31899
Add a new section named development in issue view sidebar to interact with branch/pr#31899lunny wants to merge 96 commits intogo-gitea:mainfrom
Conversation
|
I think this is ready to review again. |
| } | ||
|
|
||
| // add dev links | ||
| if pr.Flow == issues_model.PullRequestFlowGithub { |
There was a problem hiding this comment.
Why GitHub-only ? Agit PR can't be used to close an issue?
There was a problem hiding this comment.
Agit PR have no real head branch. So that branch, err := git_model.GetBranch(ctx, pr.HeadRepoID, pr.HeadBranch) will fail.
There was a problem hiding this comment.
Is it really reasonable?
Here you are creating "IssueDevLinkTypePullRequest" dev-links.
You mean that AGit PR can't be used to link to an issue and close the related issue?
| <a class="tw-mt-1 fluid ui show-modal" data-modal="#create_branch">{{ctx.Locale.Tr "repo.branch.new_branch"}}</a> | ||
| </div> | ||
| {{end}} | ||
| {{range .DevLinks}} |
There was a problem hiding this comment.
Please don't use the data from root template data.
Most side bar parts have been refactored to use their own "struct" types to make code stable.
I don't. |
|
@lunny updates on that? |
Updated. |
|
I just downloaded this branch to play around with the development sidebar in its current state, to test the edge cases that wxiaoguang mentioned earlier. The rename and delete branch scenarios behave very differently from the described GitHub behavior. This is not necessarily a bad thing, though:
|
Partially Resolve #20226
This PR add a new section on the sidebar of issue named
Development. It supports creating one or multiple branches and pull requests from the sidebar.No related branch or PR

Create new branch from the issue
Prefill title and content when creating pull request from the issue development link

Realted PR created

Related PR merged

Mayge fixed near the issue title
