aboutsummaryrefslogtreecommitdiffstats
path: root/services/convert
diff options
context:
space:
mode:
author6543 <6543@obermui.de>2024-11-27 05:41:06 +0100
committerGitHub <noreply@github.com>2024-11-27 05:41:06 +0100
commit846f6187168c807e1353d46d5d2260bf077b43cd (patch)
treec3c36ad22c01cdaeaa71fd5e7e9fd0cb7738538f /services/convert
parent3fc1bbe971db0b1591d32c4f561fdccc9c34daf4 (diff)
downloadgitea-846f6187168c807e1353d46d5d2260bf077b43cd.tar.gz
gitea-846f6187168c807e1353d46d5d2260bf077b43cd.zip
Add priority to protected branch (#32286)
## Solves Currently for rules to re-order them you have to alter the creation date. so you basicly have to delete and recreate them in the right order. This is more than just inconvinient ... ## Solution Add a new col for prioritization ## Demo WebUI Video https://github.com/user-attachments/assets/92182a31-9705-4ac5-b6e3-9bb74108cbd1 --- *Sponsored by Kithara Software GmbH*
Diffstat (limited to 'services/convert')
-rw-r--r--services/convert/convert.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/services/convert/convert.go b/services/convert/convert.go
index 8dc311dae9..c8cad2a2ad 100644
--- a/services/convert/convert.go
+++ b/services/convert/convert.go
@@ -158,6 +158,7 @@ func ToBranchProtection(ctx context.Context, bp *git_model.ProtectedBranch, repo
return &api.BranchProtection{
BranchName: branchName,
RuleName: bp.RuleName,
+ Priority: bp.Priority,
EnablePush: bp.CanPush,
EnablePushWhitelist: bp.EnableWhitelist,
PushWhitelistUsernames: pushWhitelistUsernames,