Fixed issue 145, code reviews don't show up in the timeline.
This commit is contained in:
18
src/IDF/templates/idf/review/feedfragment.xml
Normal file
18
src/IDF/templates/idf/review/feedfragment.xml
Normal file
@@ -0,0 +1,18 @@
|
||||
<entry>
|
||||
<title>{$title} - {$review.get_status}</title>
|
||||
<link href="{$url}"/>
|
||||
<id>{$url}</id>
|
||||
<updated>{$date}</updated>
|
||||
<author>{$author}</author>
|
||||
<content type="xhtml"><div xmlns="http://www.w3.org/1999/xhtml">
|
||||
{if $c}
|
||||
<pre>{issuetext $c.content, $request}</pre>
|
||||
{if $c.changes}
|
||||
{foreach $c.changes as $w => $v}
|
||||
<strong>{if $w == 'su'}{trans 'Summary:'}{/if}{if $w == 'st'}{trans 'Status:'}{/if}{if $w == 'ow'}{trans 'Owner:'}{/if}{if $w == 'lb'}{trans 'Labels:'}{/if}</strong> {if $w == 'lb'}{assign $l = implode(', ', $v)}{$l}{else}{$v}{/if}<br />
|
||||
{/foreach}
|
||||
{/if}{else}
|
||||
<pre>{issuetext $p.description, $request}</pre>
|
||||
{/if}
|
||||
</div></content>
|
||||
</entry>
|
@@ -10,7 +10,13 @@
|
||||
{assign $tags = $review.get_tags_list()}{if $tags.count()}{trans 'Labels:'}
|
||||
{foreach $tags as $tag} {$tag.class|safe}:{$tag.name|safe}
|
||||
{/foreach}
|
||||
{/if}{trans 'Comments (last first):'}
|
||||
{/if}{trans 'General comments (last first):'}
|
||||
|
||||
{foreach $gcomments as $c}{assign $who = $c.get_submitter()}# {blocktrans}By {$who|safe}, {$c.creation_dtime|date}:{/blocktrans}
|
||||
{$c.content|safe}
|
||||
|
||||
{/foreach}
|
||||
{trans 'Detailed file comments (last first):'}
|
||||
|
||||
{foreach $comments as $c}{assign $who = $c.get_comment().get_submitter()}# {blocktrans}By {$who|safe}, {$c.creation_dtime|date}, on file:
|
||||
{$c.cfile|safe}
|
||||
|
@@ -78,10 +78,10 @@ to propose more contributions</strong>.
|
||||
{$def[0]}
|
||||
</tbody>
|
||||
</table>
|
||||
{assign $comments = $def[2]}
|
||||
{assign $nc = $comments.count()}
|
||||
{assign $fcomments = $def[2]}
|
||||
{assign $nc = $fcomments.count()}
|
||||
{assign $i = 1}
|
||||
{foreach $comments as $c}
|
||||
{foreach $fcomments as $c}
|
||||
<div class="issue-comment{if $i == 1} issue-comment-first{/if}{if $i == $nc} issue-comment-last{/if}" id="ic{$c.id}">{assign $who = $c.get_comment().get_submitter()}{aurl 'whourl', 'IDF_Views_User::view', array($who.login)}
|
||||
{aurl 'url', 'IDF_Views_Review::view', array($project.shortname, $review.id)}
|
||||
{assign $id = $c.id}
|
||||
@@ -100,9 +100,60 @@ to propose more contributions</strong>.
|
||||
</td>
|
||||
</tr></table>{/if}
|
||||
{/foreach}
|
||||
|
||||
{assign $i = 1}
|
||||
{assign $nc = $comments.count()}
|
||||
{if $nc}<hr align="left" class="attach" />
|
||||
<h2>{trans 'General Comments'}</h2>
|
||||
{/if}
|
||||
{foreach $comments as $c}{ashowuser 'submitter', $c.get_submitter(), $request}{assign $who = $c.get_submitter()}
|
||||
<div class="issue-comment{if $i == 1} issue-comment-first{/if}{if $i == ($nc)} issue-comment-last{/if}" id="ic{$c.id}"><img style="float:right; position: relative;" src="http://www.gravatar.com/avatar/{$who.email|md5}.jpg?s=60&d={media}/idf/img/spacer.gif" alt=" " />
|
||||
{aurl 'url', 'IDF_Views_Review::view', array($project.shortname, $review.id)}
|
||||
{assign $id = $c.id}
|
||||
{assign $url = $url~'#ic'~$c.id}
|
||||
<p>{blocktrans}Comment <a href="{$url}">{$i}</a> by {$submitter}, {$c.creation_dtime|date}{/blocktrans}</p>
|
||||
|
||||
|
||||
|
||||
{if strlen($c.content) > 0}<pre class="issue-comment-text">{issuetext $c.content, $request}</pre>{/if}
|
||||
|
||||
{if $c.changedReview()}
|
||||
<div class="issue-changes">
|
||||
{foreach $c.changes as $w => $v}
|
||||
<strong>{if $w == 'su'}{trans 'Summary:'}{/if}{if $w == 'st'}{trans 'Status:'}{/if}</strong> {$v}<br />
|
||||
{/foreach}
|
||||
</div>
|
||||
{/if}
|
||||
</div>{assign $i = $i + 1}{if $i == $nc+1 and $user.isAnonymous()}
|
||||
<div class="issue-comment-signin">
|
||||
{aurl 'url', 'IDF_Views::login'}{blocktrans}<a href="{$url}">Sign in</a> to participate in the review.{/blocktrans}
|
||||
</div>
|
||||
{/if}
|
||||
{/foreach}
|
||||
|
||||
{if !$user.isAnonymous()}
|
||||
{if !$nc}<hr align="left" class="attach" />{/if}
|
||||
<table class="form" summary=" ">
|
||||
<tr>
|
||||
<th><strong>{$form.f.content.labelTag}:</strong></th>
|
||||
<td>{if $form.f.content.errors}{$form.f.content.fieldErrors}{/if}
|
||||
{$form.f.content|unsafe}
|
||||
</td>
|
||||
</tr>
|
||||
{if $isOwner or $isMember}
|
||||
<tr>
|
||||
<th><strong>{$form.f.summary.labelTag}:</strong></th>
|
||||
<td>{if $form.f.summary.errors}{$form.f.summary.fieldErrors}{/if}
|
||||
{$form.f.summary|unsafe}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><strong>{$form.f.status.labelTag}:</strong></th>
|
||||
<td>{if $form.f.status.errors}{$form.f.status.fieldErrors}{/if}
|
||||
{$form.f.status|unsafe}
|
||||
</td>
|
||||
</tr>{/if}
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td><input type="submit" value="{trans 'Submit Code Review'}" name="submit" /> | <a href="{url 'IDF_Views_Review::index', array($project.shortname)}">{trans 'Cancel'}</a>
|
||||
</td>
|
||||
@@ -110,10 +161,11 @@ to propose more contributions</strong>.
|
||||
{/if}
|
||||
</form>
|
||||
{/block}
|
||||
u
|
||||
|
||||
{block javascript}
|
||||
<script type="text/javascript" src="{media '/idf/js/prettify.js'}"></script>
|
||||
<script type="text/javascript">
|
||||
prettyPrint();
|
||||
</script>
|
||||
{if $isOwner or $isMember}{include 'idf/issues/js-autocomplete.html'}{/if}
|
||||
{/block}
|
||||
|
Reference in New Issue
Block a user