(refs #27)Display assigned user on issue list.

This commit is contained in:
takezoe
2013-07-10 21:09:21 +09:00
parent 9d61f73e22
commit 70761f4ac1
4 changed files with 16 additions and 7 deletions

View File

@@ -1,4 +1,8 @@
@(userName: String, size: Int, styles: String = "")(implicit context: app.Context) @(userName: String, size: Int, tooltip: Boolean = false, styles: String = "")(implicit context: app.Context)
@import context._ @import context._
@import view.helpers._ @import view.helpers._
<img src="@url(userName)/_avatar" class="avatar" style="width: @(size)px; height: @(size)px; @styles"/> @if(tooltip){
<img src="@url(userName)/_avatar" data-toggle="tooltip" title="@userName" class="avatar" style="width: @(size)px; height: @(size)px; @styles"/>
} else {
<img src="@url(userName)/_avatar" class="avatar" style="width: @(size)px; height: @(size)px; @styles"/>
}

View File

@@ -217,7 +217,12 @@
@labels.map { label => @labels.map { label =>
<span class="label-color small" style="background-color: #@label.color; color: #@label.fontColor; padding-left: 4px; padding-right: 4px">@label.labelName</span> <span class="label-color small" style="background-color: #@label.color; color: #@label.fontColor; padding-left: 4px; padding-right: 4px">@label.labelName</span>
} }
<span class="pull-right muted">#@issue.issueId</span> <span class="pull-right muted">
@issue.assignedUserName.map { userName =>
@helper.html.avatar(userName, 20, true)
}
#@issue.issueId
</span>
<div class="small muted"> <div class="small muted">
Opened by <a href="@url(issue.openedUserName)" class="username">@issue.openedUserName</a> @datetime(issue.registeredDate)&nbsp; Opened by <a href="@url(issue.openedUserName)" class="username">@issue.openedUserName</a> @datetime(issue.registeredDate)&nbsp;
@if(commentCount > 0){ @if(commentCount > 0){

View File

@@ -38,7 +38,7 @@
<a href="@url(repository)/tree/@commit.id" class="small">Browse code</a> <a href="@url(repository)/tree/@commit.id" class="small">Browse code</a>
</div> </div>
<div> <div>
@helper.html.avatar(commit.committer, 40, "float: left; margin-right: 4px;") @helper.html.avatar(commit.committer, 40, styles = "float: left; margin-right: 4px;")
<a href="@url(repository)/commit/@commit.id" class="commit-message" style="font-weight: bold;">@link(commit.summary, repository)</a> <a href="@url(repository)/commit/@commit.id" class="commit-message" style="font-weight: bold;">@link(commit.summary, repository)</a>
@if(commit.description.isDefined){ @if(commit.description.isDefined){
<a href="javascript:void(0)" onclick="$('#description-@commit.id').toggle();" class="omit">...</a> <a href="javascript:void(0)" onclick="$('#description-@commit.id').toggle();" class="omit">...</a>

View File

@@ -1,11 +1,11 @@
$(function(){ $(function(){
$.ajaxSetup({ $.ajaxSetup({ cache: false });
cache: false
});
$('#repository-url').click(function(){ $('#repository-url').click(function(){
this.select(0, this.value.length); this.select(0, this.value.length);
}); });
$('img[data-toggle=tooltip]').tooltip();
prettyPrint(); prettyPrint();
}); });