summaryrefslogtreecommitdiffstats
path: root/templates/issue/view.tmpl
diff options
context:
space:
mode:
authorUnknown <joe2010xtmf@163.com>2014-05-24 02:31:58 -0400
committerUnknown <joe2010xtmf@163.com>2014-05-24 02:31:58 -0400
commitb1bdbd7f948b0598e69355ba8312a50c74bc04a7 (patch)
tree1bf401b1d334fab67f72a69a3ff4d2c310cb14c6 /templates/issue/view.tmpl
parent50ba08e2c602993fc283b2d868639820aba57528 (diff)
downloadgitea-b1bdbd7f948b0598e69355ba8312a50c74bc04a7.tar.gz
gitea-b1bdbd7f948b0598e69355ba8312a50c74bc04a7.zip
Almost done issue label #200
Diffstat (limited to 'templates/issue/view.tmpl')
-rw-r--r--templates/issue/view.tmpl35
1 files changed, 15 insertions, 20 deletions
diff --git a/templates/issue/view.tmpl b/templates/issue/view.tmpl
index ea5777cb15..ba1fe16b79 100644
--- a/templates/issue/view.tmpl
+++ b/templates/issue/view.tmpl
@@ -118,7 +118,7 @@
</div>
<div class="issue-bar col-md-2">
- <div class="labels" data-ajax="{url}">
+ <div class="labels" data-ajax="{{.Issue.Index}}/label">
<div class="pull-right action">
<button class="btn btn-default btn-sm" data-toggle="dropdown">
<i class="fa fa-tags"></i>
@@ -126,26 +126,24 @@
</button>
<div class="dropdown-menu dropdown-menu-right no">
<ul class="list-unstyled">
- <li class="checked" data-id="1">
- <span class="check pull-left"><i class="fa fa-check"></i></span>
- <span class="color" style="background-color: #f59e00"></span>
- <span class="name">bug</span>
- </li>
- <li class="no-checked" data-id="2">
- <span class="color" style="background-color: #f59e00"></span>
- <span class="name">bug</span>
- </li>
- <li class="no-checked" data-id="3">
- <span class="color" style="background-color: #f59e00"></span>
- <span class="name">bug</span>
+ {{range .Labels}}
+ <li class="{{if not .IsChecked}}no-{{end}}checked" data-id="{{.Id}}">
+ {{if .IsChecked}}<span class="check pull-left"><i class="fa fa-check"></i></span>{{end}}
+ <span class="color" style="background-color: {{.Color}}"></span>
+ <span class="name">{{.Name}}</span>
</li>
+ {{end}}
</ul>
</div>
</div>
<h4>Labels</h4>
- <p id="label-1" class="label-item label-white" style="background-color: #e75316"><strong>bug</strong></p>
- <p id="label-2" class="label-item label-white" style="background-color: #e8f0ff"><strong>bug</strong></p>
- <p>Not yet</p>
+ {{if .Issue.Labels}}
+ {{range .Issue.Labels}}
+ <p id="label-{{.Id}}" class="label-item label-white" style="background-color: {{.Color}}"><strong>{{.Name}}</strong></p>
+ {{end}}
+ {{else}}
+ <p>None yet</p>
+ {{end}}
</div>
<div class="milestone" data-milestone="{{.Milestone.Id}}" data-ajax="{{.Issue.Index}}/milestone">
<div class="pull-right action">
@@ -223,10 +221,7 @@
<h4>Assignee</h4>
<p>{{if .Issue.Assignee}}<img src="{{.Issue.Assignee.AvatarLink}}"><strong>{{.Issue.Assignee.Name}}</strong>{{else}}No one assigned{{end}}</p>
</div>
- </div><!--
- <div class="col-md-3">
- label dashboard
- </div>-->
+ </div>
</div>
</div>
</div>