You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
2.0 KiB

9 years ago
  1. <div class="ui six wide column">
  2. <h4 class="ui top attached header">
  3. <strong>{{.Team.Name}}</strong>
  4. <div class="ui right">
  5. {{if .Team.IsMember $.SignedUser.ID}}
  6. <a class="ui red tiny button" href="{{.OrgLink}}/teams/{{.Team.LowerName}}/action/leave?uid={{$.SignedUser.ID}}&page=home">{{$.i18n.Tr "org.teams.leave"}}</a>
  7. {{else if .IsOrganizationOwner}}
  8. <a class="ui blue tiny button" href="{{.OrgLink}}/teams/{{.Team.LowerName}}/action/join?uid={{$.SignedUser.ID}}&page=team">{{$.i18n.Tr "org.teams.join"}}</a>
  9. {{end}}
  10. </div>
  11. </h4>
  12. <div class="ui attached table segment detail">
  13. <div class="item">
  14. {{if .Team.Description}}
  15. {{.Team.Description}}
  16. {{else}}
  17. <span class="text grey italic">{{.i18n.Tr "org.teams.no_desc"}}</span>
  18. {{end}}
  19. </div>
  20. <div class="item">
  21. {{if eq .Team.LowerName "owners"}}
  22. {{.i18n.Tr "org.teams.owners_permission_desc" | Str2html}}
  23. {{else if (eq .Team.Authorize 1)}}
  24. {{if .Team.IncludesAllRepositories}}
  25. {{.i18n.Tr "org.teams.all_repositories_read_permission_desc" | Str2html}}
  26. {{else}}
  27. {{.i18n.Tr "org.teams.read_permission_desc" | Str2html}}
  28. {{end}}
  29. {{else if (eq .Team.Authorize 2)}}
  30. {{if .Team.IncludesAllRepositories}}
  31. {{.i18n.Tr "org.teams.all_repositories_write_permission_desc" | Str2html}}
  32. {{else}}
  33. {{.i18n.Tr "org.teams.write_permission_desc" | Str2html}}
  34. {{end}}
  35. {{else if (eq .Team.Authorize 3)}}
  36. {{if .Team.IncludesAllRepositories}}
  37. {{.i18n.Tr "org.teams.all_repositories_admin_permission_desc" | Str2html}}
  38. {{else}}
  39. {{.i18n.Tr "org.teams.admin_permission_desc" | Str2html}}
  40. {{end}}
  41. {{end}}
  42. {{if .Team.CanCreateOrgRepo}}
  43. <br><br>{{.i18n.Tr "org.teams.create_repo_permission_desc" | Str2html}}
  44. {{end}}
  45. </div>
  46. </div>
  47. {{if .IsOrganizationOwner}}
  48. <div class="ui bottom attached segment">
  49. <a class="ui teal small button" href="{{.OrgLink}}/teams/{{.Team.LowerName}}/edit"><span class="octicon octicon-gear"></span> {{$.i18n.Tr "org.teams.settings"}}</a>
  50. </div>
  51. {{end}}
  52. </div>