summaryrefslogtreecommitdiffstats
path: root/routers/web/org/org_labels.go
diff options
context:
space:
mode:
Diffstat (limited to 'routers/web/org/org_labels.go')
-rw-r--r--routers/web/org/org_labels.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/routers/web/org/org_labels.go b/routers/web/org/org_labels.go
index 26e232bcc9..08457d4f8e 100644
--- a/routers/web/org/org_labels.go
+++ b/routers/web/org/org_labels.go
@@ -15,7 +15,7 @@ import (
// RetrieveLabels find all the labels of an organization
func RetrieveLabels(ctx *context.Context) {
- labels, err := models.GetLabelsByOrgID(ctx.Org.Organization.ID, ctx.Query("sort"), models.ListOptions{})
+ labels, err := models.GetLabelsByOrgID(ctx.Org.Organization.ID, ctx.Form("sort"), models.ListOptions{})
if err != nil {
ctx.ServerError("RetrieveLabels.GetLabels", err)
return
@@ -25,7 +25,7 @@ func RetrieveLabels(ctx *context.Context) {
}
ctx.Data["Labels"] = labels
ctx.Data["NumLabels"] = len(labels)
- ctx.Data["SortType"] = ctx.Query("sort")
+ ctx.Data["SortType"] = ctx.Form("sort")
}
// NewLabel create new label for organization
@@ -79,7 +79,7 @@ func UpdateLabel(ctx *context.Context) {
// DeleteLabel delete a label
func DeleteLabel(ctx *context.Context) {
- if err := models.DeleteLabel(ctx.Org.Organization.ID, ctx.QueryInt64("id")); err != nil {
+ if err := models.DeleteLabel(ctx.Org.Organization.ID, ctx.FormInt64("id")); err != nil {
ctx.Flash.Error("DeleteLabel: " + err.Error())
} else {
ctx.Flash.Success(ctx.Tr("repo.issues.label_deletion_success"))