1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-22 18:28:37 +00:00

Add delete route for attachments, remove upload buttons from issues/comments

This commit is contained in:
Justin Nuß
2014-07-24 09:04:09 +02:00
parent 34304e6a0c
commit 3c025b3950
5 changed files with 132 additions and 8 deletions

View File

@@ -238,9 +238,14 @@ func runWeb(*cli.Context) {
r.Post("/:index/label", repo.UpdateIssueLabel)
r.Post("/:index/milestone", repo.UpdateIssueMilestone)
r.Post("/:index/assignee", repo.UpdateAssignee)
r.Post("/:index/attachment", repo.IssuePostAttachment)
r.Post("/:index/attachment/:id", repo.IssuePostAttachment)
r.Get("/:index/attachment/:id", repo.IssueGetAttachment)
m.Group("/:index/attachment", func(r martini.Router) {
r.Get("/:id", repo.IssueGetAttachment)
r.Post("/", repo.IssuePostAttachment)
r.Post("/:comment", repo.IssuePostAttachment)
r.Delete("/:comment/:id", repo.IssueDeleteAttachment)
})
r.Post("/labels/new", bindIgnErr(auth.CreateLabelForm{}), repo.NewLabel)
r.Post("/labels/edit", bindIgnErr(auth.CreateLabelForm{}), repo.UpdateLabel)
r.Post("/labels/delete", repo.DeleteLabel)