|
|
@ -1,4 +1,5 @@ |
|
|
|
// Copyright 2016 The Gogs Authors. All rights reserved.
|
|
|
|
// Copyright 2016 The Gogs Authors. All rights reserved.
|
|
|
|
|
|
|
|
// Copyright 2019 The Gitea Authors. All rights reserved.
|
|
|
|
// Use of this source code is governed by a MIT-style
|
|
|
|
// Use of this source code is governed by a MIT-style
|
|
|
|
// license that can be found in the LICENSE file.
|
|
|
|
// license that can be found in the LICENSE file.
|
|
|
|
|
|
|
|
|
|
|
@ -11,6 +12,7 @@ type Label struct { |
|
|
|
Name string `json:"name"` |
|
|
|
Name string `json:"name"` |
|
|
|
// example: 00aabb
|
|
|
|
// example: 00aabb
|
|
|
|
Color string `json:"color"` |
|
|
|
Color string `json:"color"` |
|
|
|
|
|
|
|
Description string `json:"description"` |
|
|
|
URL string `json:"url"` |
|
|
|
URL string `json:"url"` |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -21,12 +23,14 @@ type CreateLabelOption struct { |
|
|
|
// required:true
|
|
|
|
// required:true
|
|
|
|
// example: #00aabb
|
|
|
|
// example: #00aabb
|
|
|
|
Color string `json:"color" binding:"Required;Size(7)"` |
|
|
|
Color string `json:"color" binding:"Required;Size(7)"` |
|
|
|
|
|
|
|
Description string `json:"description"` |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// EditLabelOption options for editing a label
|
|
|
|
// EditLabelOption options for editing a label
|
|
|
|
type EditLabelOption struct { |
|
|
|
type EditLabelOption struct { |
|
|
|
Name *string `json:"name"` |
|
|
|
Name *string `json:"name"` |
|
|
|
Color *string `json:"color"` |
|
|
|
Color *string `json:"color"` |
|
|
|
|
|
|
|
Description *string `json:"description"` |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// IssueLabelsOption a collection of labels
|
|
|
|
// IssueLabelsOption a collection of labels
|
|
|
|