Browse Source

minor fix on template

tags/v1.2.0-rc1
Unknwon 10 years ago
parent
commit
9b57a08cdb
4 changed files with 2 additions and 6 deletions
  1. +1
    -1
      modules/auth/org.go
  2. +1
    -1
      routers/repo/repo.go
  3. +0
    -2
      templates/repo/create.tmpl
  4. +0
    -2
      templates/repo/migrate.tmpl

+ 1
- 1
modules/auth/org.go View File

@@ -17,7 +17,7 @@ import (
// \/ /_____/ \/ \/ \/ \/ \/

type CreateOrgForm struct {
OrgName string `binding:"Required;AlphaDashDot;MaxSize(30)"`
OrgName string `binding:"Required;AlphaDashDot;MaxSize(30)" locale:"org.org_name_holder"`
}

func (f *CreateOrgForm) Validate(ctx *macaron.Context, errs binding.Errors) binding.Errors {


+ 1
- 1
routers/repo/repo.go View File

@@ -30,7 +30,7 @@ const (
func checkContextUser(ctx *middleware.Context, uid int64) *models.User {
orgs, err := models.GetOwnedOrgsByUserIDDesc(ctx.User.Id, "updated")
if err != nil {
ctx.Handle(500, "GetOwnedOrganizationsByUserIDDesc", err)
ctx.Handle(500, "GetOwnedOrgsByUserIDDesc", err)
return nil
}
ctx.Data["Orgs"] = orgs


+ 0
- 2
templates/repo/create.tmpl View File

@@ -24,13 +24,11 @@
{{.SignedUser.Name}}
</div>
{{range .Orgs}}
{{if .IsOwnedBy $.SignedUser.Id}}
<div class="item" data-value="{{.Id}}">
<img class="ui mini image" src="{{.AvatarLink}}">
{{.Name}}
</div>
{{end}}
{{end}}
</div>
</div>
</div>


+ 0
- 2
templates/repo/migrate.tmpl View File

@@ -49,13 +49,11 @@
{{.SignedUser.Name}}
</div>
{{range .Orgs}}
{{if .IsOwnedBy $.SignedUser.Id}}
<div class="item" data-value="{{.Id}}">
<img class="ui mini image" src="{{.AvatarLink}}">
{{.Name}}
</div>
{{end}}
{{end}}
</div>
</div>
</div>


Loading…
Cancel
Save