view rhodecode/templates/changelog/changelog_summary_data.html @ 3765:5a8918aba869 beta

show comments in summary changelog overview
author Marcin Kuzminski <marcin@python-works.com>
date Tue, 16 Apr 2013 00:59:14 +0200
parents c7970889c5c0
children 458fd829aa20
line wrap: on
line source

## -*- coding: utf-8 -*-
%if c.repo_changesets:
<table class="table_disp">
    <tr>
        <th class="left">${_('Revision')}</th>
        <th class="left">${_('Commit message')}</th>
        <th class="left">${_('Age')}</th>
        <th class="left">${_('Author')}</th>
        <th class="left">${_('Refs')}</th>
    </tr>
%for cnt,cs in enumerate(c.repo_changesets):
    <tr class="parity${cnt%2}">
        <td>
          <div>
            <div class="changeset-status-container">
              %if c.comments.get(cs.raw_id,[]):
               <div class="comments-container">
                   <div class="comments-cnt" title="${('comments')}">
                       <a href="${h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id,anchor='comment-%s' % c.comments[cs.raw_id][0].comment_id)}">
                           ${len(c.comments[cs.raw_id])}
                       </a>
                   </div>
               </div>
              %endif
              %if c.statuses.get(cs.raw_id):
                <div class="changeset-status-ico">
                %if c.statuses.get(cs.raw_id)[2]:
                  <a class="tooltip" title="${_('Click to open associated pull request #%s' % c.statuses.get(cs.raw_id)[2])}" href="${h.url('pullrequest_show',repo_name=c.statuses.get(cs.raw_id)[3],pull_request_id=c.statuses.get(cs.raw_id)[2])}">
                    <img src="${h.url('/images/icons/flag_status_%s.png' % c.statuses.get(cs.raw_id)[0])}" />
                  </a>
                %else:
                  <img src="${h.url('/images/icons/flag_status_%s.png' % c.statuses.get(cs.raw_id)[0])}" />
                %endif
                </div>
              %endif
            </div>
            <pre><a href="${h.url('files_home',repo_name=c.repo_name,revision=cs.raw_id)}">${h.show_id(cs)}</a></pre>
         </div>
        </td>
        <td>
            ${h.urlify_commit(h.truncate(cs.message,50),c.repo_name, h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id))}
        </td>
        <td><span class="tooltip" title="${h.tooltip(h.fmt_date(cs.date))}">
                      ${h.age(cs.date)}</span>
        </td>
        <td title="${cs.author}">${h.person(cs.author)}</td>
        <td>
            %if h.is_hg(c.rhodecode_repo):
                %for book in cs.bookmarks:
                    <div class="booktag" title="${_('Bookmark %s') % book}">
                        ${h.link_to(h.shorter(book),h.url('files_home',repo_name=c.repo_name,revision=cs.raw_id))}
                    </div>
                %endfor
            %endif
            %for tag in cs.tags:
             <div class="tagtag" title="${_('Tag %s') % tag}">
                 ${h.link_to(h.shorter(tag),h.url('files_home',repo_name=c.repo_name,revision=cs.raw_id))}
             </div>
            %endfor
            %if cs.branch:
             <div class="branchtag" title="${_('Branch %s' % cs.branch)}">
                 ${h.link_to(h.shorter(cs.branch),h.url('changelog_home',repo_name=c.repo_name,branch=cs.branch))}
             </div>
            %endif
        </td>
    </tr>
%endfor

</table>

<script type="text/javascript">
  YUE.onDOMReady(function(){
    YUE.delegate("shortlog_data","click",function(e, matchedEl, container){
        ypjax(e.target.href,"shortlog_data",function(){tooltip_activate();});
        YUE.preventDefault(e);
    },'.pager_link');
  });
</script>

<div class="pagination-wh pagination-left">
${c.repo_changesets.pager('$link_previous ~2~ $link_next')}
</div>
%else:

%if h.HasRepoPermissionAny('repository.write','repository.admin')(c.repo_name):
<h4>${_('Add or upload files directly via RhodeCode')}</h4>
<div style="margin: 20px 30px;">
  <div id="add_node_id" class="add_node">
      <a class="ui-btn" href="${h.url('files_add_home',repo_name=c.repo_name,revision=0,f_path='')}">${_('Add new file')}</a>
  </div>
</div>
%endif


<h4>${_('Push new repo')}</h4>
<pre>
    ${c.rhodecode_repo.alias} clone ${c.clone_repo_url}
    ${c.rhodecode_repo.alias} add README # add first file
    ${c.rhodecode_repo.alias} commit -m "Initial" # commit with message
    ${c.rhodecode_repo.alias} push ${'origin master' if h.is_git(c.rhodecode_repo) else ''} # push changes back
</pre>

<h4>${_('Existing repository?')}</h4>
<pre>
%if h.is_git(c.rhodecode_repo):
    git remote add origin ${c.clone_repo_url}
    git push -u origin master
%else:
    hg push ${c.clone_repo_url}
%endif
</pre>
%endif