Fix public org members displayed too many informations (#20403)

tokarchuk/v1.18
Lunny Xiao 2 years ago committed by GitHub
parent 4c7e51ee3a
commit d6779c7ad3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      routers/web/org/members.go
  2. 2
      templates/org/member/members.tmpl

@ -45,6 +45,7 @@ func Members(ctx *context.Context) {
} }
opts.PublicOnly = !isMember && !ctx.Doer.IsAdmin opts.PublicOnly = !isMember && !ctx.Doer.IsAdmin
} }
ctx.Data["PublicOnly"] = opts.PublicOnly
total, err := organization.CountOrgMembers(opts) total, err := organization.CountOrgMembers(opts)
if err != nil { if err != nil {

@ -29,6 +29,7 @@
{{end}} {{end}}
</div> </div>
</div> </div>
{{if not .PublicOnly}}
<div class="ui three wide column center"> <div class="ui three wide column center">
<div class="meta"> <div class="meta">
{{$.locale.Tr "org.members.member_role"}} {{$.locale.Tr "org.members.member_role"}}
@ -51,6 +52,7 @@
</strong> </strong>
</div> </div>
</div> </div>
{{end}}
<div class="ui three wide column"> <div class="ui three wide column">
<div class="text right"> <div class="text right">
{{if eq $.SignedUser.ID .ID}} {{if eq $.SignedUser.ID .ID}}

Loading…
Cancel
Save