summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorOscar Costa <oscarcosta@gmail.com>2019-12-06 18:13:19 -0800
committertechknowlogick <techknowlogick@gitea.io>2019-12-06 21:13:19 -0500
commit1583c48e3a89fcb9aeb81a57295982ee64d5859f (patch)
tree00018c9c4ad684572b923d3750773fa12f0cd17a /templates
parenteba816e8269b6a4ad141da0d399a5613796a348e (diff)
downloadgitea-1583c48e3a89fcb9aeb81a57295982ee64d5859f.tar.gz
gitea-1583c48e3a89fcb9aeb81a57295982ee64d5859f.zip
Show label list on label set (#9251)
* Showing the list of labels of template files #7812 * Returning and logging errors when loading labels * Commenting public method * Change log level in case of error loading labels.
Diffstat (limited to 'templates')
-rw-r--r--templates/repo/create.tmpl4
-rw-r--r--templates/repo/issue/labels.tmpl4
2 files changed, 4 insertions, 4 deletions
diff --git a/templates/repo/create.tmpl b/templates/repo/create.tmpl
index c71c3ab5a6..b63af09cec 100644
--- a/templates/repo/create.tmpl
+++ b/templates/repo/create.tmpl
@@ -109,8 +109,8 @@
<div class="default text">{{.i18n.Tr "repo.issue_labels_helper"}}</div>
<div class="menu">
<div class="item" data-value="">{{.i18n.Tr "repo.issue_labels_helper"}}</div>
- {{range .LabelTemplates}}
- <div class="item" data-value="{{.}}">{{.}}</div>
+ {{range $template, $labels := .LabelTemplates}}
+ <div class="item" data-value="{{$template}}">{{$template}}<br/><i>({{$labels}})</i></div>
{{end}}
</div>
</div>
diff --git a/templates/repo/issue/labels.tmpl b/templates/repo/issue/labels.tmpl
index c3bfc9ccc6..32a5c2a4ef 100644
--- a/templates/repo/issue/labels.tmpl
+++ b/templates/repo/issue/labels.tmpl
@@ -79,8 +79,8 @@
<input type="hidden" name="template_name" value="Default">
<div class="default text">{{.i18n.Tr "repo.issues.label_templates.helper"}}</div>
<div class="menu">
- {{range .LabelTemplates}}
- <div class="item" data-value="{{.}}">{{.}}</div>
+ {{range $template, $labels := .LabelTemplates}}
+ <div class="item" data-value="{{$template}}">{{$template}}<br/><i>({{$labels}})</i></div>
{{end}}
</div>
</div>