alpha
Login
or
Join now
dunkirk.sh
/
core
forked from
tangled.org/core
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
This repository has no description
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Overview
Issues
Pulls
Pipelines
allow collaborators to close issues
author
Akshay
date
1 year ago
(Mar 14, 2025, 12:12 AM UTC)
commit
be76b447
be76b4474eb35a45f0575d4ab6797c3f93bf0a96
parent
48d7106e
48d7106e64ec57797f1792b0e7fbdb773f5907e8
+12
-5
2 changed files
Expand all
Collapse all
Unified
Split
appview
pages
pages.go
templates
repo
issues
issue.html
+9
-4
appview/pages/pages.go
Reviewed
···
231
231
return slices.Contains(r.Roles, "repo:owner")
232
232
}
233
233
234
234
+
func (r RolesInRepo) IsCollaborator() bool {
235
235
+
return slices.Contains(r.Roles, "repo:collaborator")
236
236
+
}
237
237
+
234
238
func (r RepoInfo) OwnerWithAt() string {
235
239
if r.OwnerHandle != "" {
236
240
return fmt.Sprintf("@%s", r.OwnerHandle)
···
441
445
}
442
446
443
447
type RepoSettingsParams struct {
444
444
-
LoggedInUser *auth.User
445
445
-
RepoInfo RepoInfo
446
446
-
Collaborators []Collaborator
447
447
-
Active string
448
448
+
LoggedInUser *auth.User
449
449
+
RepoInfo RepoInfo
450
450
+
Collaborators []Collaborator
451
451
+
Active string
452
452
+
// TODO: use repoinfo.roles
448
453
IsCollaboratorInviteAllowed bool
449
454
}
450
455
+3
-1
appview/pages/templates/repo/issues/issue.html
Reviewed
···
101
101
</form>
102
102
{{ end }}
103
103
104
104
-
{{ if eq .LoggedInUser.Did .Issue.OwnerDid }}
104
104
+
{{ $isIssueAuthor := eq .LoggedInUser.Did .Issue.OwnerDid }}
105
105
+
{{ $isRepoCollaborator := .RepoInfo.Roles.IsCollaborator }}
106
106
+
{{ if or $isIssueAuthor $isRepoCollaborator }}
105
107
{{ $action := "close" }}
106
108
{{ $icon := "circle-x" }}
107
109
{{ $hoverColor := "red" }}