|
|
@ -1125,6 +1125,9 @@ func registerRoutes(m *web.Route) { |
|
|
|
// user/org home, including rss feeds
|
|
|
|
// user/org home, including rss feeds
|
|
|
|
m.Get("/{username}/{reponame}", ignSignIn, context.RepoAssignment, context.RepoRef(), repo.SetEditorconfigIfExists, repo.Home) |
|
|
|
m.Get("/{username}/{reponame}", ignSignIn, context.RepoAssignment, context.RepoRef(), repo.SetEditorconfigIfExists, repo.Home) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// TODO: maybe it should relax the permission to allow "any access"
|
|
|
|
|
|
|
|
m.Post("/{username}/{reponame}/markup", ignSignIn, context.RepoAssignment, context.RequireRepoReaderOr(unit.TypeCode, unit.TypeIssues, unit.TypePullRequests, unit.TypeReleases, unit.TypeWiki), web.Bind(structs.MarkupOption{}), misc.Markup) |
|
|
|
|
|
|
|
|
|
|
|
m.Group("/{username}/{reponame}", func() { |
|
|
|
m.Group("/{username}/{reponame}", func() { |
|
|
|
m.Get("/find/*", repo.FindFiles) |
|
|
|
m.Get("/find/*", repo.FindFiles) |
|
|
|
m.Group("/tree-list", func() { |
|
|
|
m.Group("/tree-list", func() { |
|
|
@ -1236,8 +1239,6 @@ func registerRoutes(m *web.Route) { |
|
|
|
m.Post("/reactions/{action}", web.Bind(forms.ReactionForm{}), repo.ChangeCommentReaction) |
|
|
|
m.Post("/reactions/{action}", web.Bind(forms.ReactionForm{}), repo.ChangeCommentReaction) |
|
|
|
}, context.RepoMustNotBeArchived()) |
|
|
|
}, context.RepoMustNotBeArchived()) |
|
|
|
|
|
|
|
|
|
|
|
m.Post("/markup", web.Bind(structs.MarkupOption{}), misc.Markup) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
m.Group("/labels", func() { |
|
|
|
m.Group("/labels", func() { |
|
|
|
m.Post("/new", web.Bind(forms.CreateLabelForm{}), repo.NewLabel) |
|
|
|
m.Post("/new", web.Bind(forms.CreateLabelForm{}), repo.NewLabel) |
|
|
|
m.Post("/edit", web.Bind(forms.CreateLabelForm{}), repo.UpdateLabel) |
|
|
|
m.Post("/edit", web.Bind(forms.CreateLabelForm{}), repo.UpdateLabel) |
|
|
|