##// END OF EJS Templates
Import some of the files from Select2 3.5.0 Javascript system....
Import some of the files from Select2 3.5.0 Javascript system. RhodeCode 2.2.5 used a version of Select2. Herein, we bring into Kallithea only a few files directly from Select2 3.5.0 (6ef7155) upstream, using the commands indicated below: (cd /tmp; \ git clone https://github.com/ivaynberg/select2.git; \ cd select2; \ git checkout 3.5.0 \ ) mkdir rhodecode/public/js/select2 cp -pa /tmp/select2/select2.{js,css,png} rhodecode/public/js/select2/ cp -pa /tmp/select2/select2x2.png rhodecode/public/js/select2/ cp -pa /tmp/select2/select2-spinner.gif rhodecode/public/js/select2/ hg add rhodecode/public/js/select2/

File last commit:

r4116:ffd45b18 rhodecode-2.2.5-gpl
r4128:bbbb013a rhodecode-2.2.5-gpl
Show More
_dt_elements.html
219 lines | 8.7 KiB | text/html | HtmlLexer
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304 ## DATA TABLE RE USABLE ELEMENTS
## usage:
## <%namespace name="dt" file="/data_table/_dt_elements.html"/>
<%def name="quick_menu(repo_name)">
<ul class="menu_items hidden">
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 ##<ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu">
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304 <li style="border-top:1px solid #003367;margin-left:18px;padding-left:-99px"></li>
<li>
<a title="${_('Summary')}" href="${h.url('summary_home',repo_name=repo_name)}">
<span class="icon">
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <i class="icon-file-text"></i>
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304 </span>
<span>${_('Summary')}</span>
</a>
</li>
<li>
<a title="${_('Changelog')}" href="${h.url('changelog_home',repo_name=repo_name)}">
<span class="icon">
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <i class="icon-list-alt"></i>
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304 </span>
<span>${_('Changelog')}</span>
</a>
</li>
<li>
<a title="${_('Files')}" href="${h.url('files_home',repo_name=repo_name)}">
<span class="icon">
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <i class="icon-file-alt"></i>
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304 </span>
<span>${_('Files')}</span>
</a>
</li>
<li>
<a title="${_('Fork')}" href="${h.url('repo_fork_home',repo_name=repo_name)}">
<span class="icon">
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <i class="icon-code-fork"></i>
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304 </span>
<span>${_('Fork')}</span>
</a>
</li>
</ul>
</%def>
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <%def name="repo_name(name,rtype,rstate,private,fork_of,short_name=False,admin=False)">
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304 <%
def get_name(name,short_name=short_name):
if short_name:
return name.split('/')[-1]
else:
return name
%>
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <div style="white-space: nowrap; ${'opacity: 0.5' if rstate == 'repo_state_pending' else ''}}">
##NAME
%if admin:
<a href="${h.url('edit_repo',repo_name=name)}">
%else:
<a href="${h.url('summary_home',repo_name=name)}">
%endif
##TYPE OF REPO
%if h.is_hg(rtype):
<span title="${_('Mercurial repository')}"><i class="icon-hg" style="color: #316293; font-size: 14px;"></i></span>
%elif h.is_git(rtype):
<span title="${_('Git repository')}"><i class="icon-git" style="color: #e85634; font-size: 14px;"></i></span>
%endif
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 ##PRIVATE/PUBLIC
%if private and c.visual.show_private_icon:
<i class="icon-lock" style="color: #e85634; font-size: 16px; vertical-align: -2px; margin: 0px 1px 0px 3px" title="${_('Private repository')}"></i>
%elif not private and c.visual.show_public_icon:
<i class="icon-unlock-alt" style="color: #999999; font-size: 16px; vertical-align: -2px; margin: 0px 1px 0px 3px" title="${_('Public repository')}"></i>
%else:
<span style="margin: 0px 8px 0px 8px"></span>
%endif
${get_name(name)}
</a>
%if fork_of:
<a href="${h.url('summary_home',repo_name=fork_of.repo_name)}"><i class="icon-code-fork"></i></a>
%endif
%if rstate == 'repo_state_pending':
<i class="icon-cogs" style="color: #036185;" title="${_('Repository creating in progress...')}"></i>
%endif
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304 </div>
</%def>
Update last_change from VCS data on request....
r2937 <%def name="last_change(last_change)">
<span class="tooltip" date="${last_change}" title="${h.tooltip(h.fmt_date(last_change))}">${h.age(last_change)}</span>
</%def>
Vincent Duvert
Renaming template directory _data_table to data_table so it can be scanned by extract_messages
r2304
<%def name="revision(name,rev,tip,author,last_msg)">
<div>
%if rev >= 0:
<pre><a title="${h.tooltip('%s:\n\n%s' % (author,last_msg))}" class="tooltip" href="${h.url('changeset_home',repo_name=name,revision=tip)}">${'r%s:%s' % (rev,h.short_id(tip))}</a></pre>
%else:
${_('No changesets yet')}
%endif
</div>
</%def>
No more raw html inside users controller....
r2663
Added lightweight dashboard option. ref #500
r2936 <%def name="rss(name)">
%if c.rhodecode_user.username != 'default':
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <a title="${_('Subscribe to %s rss feed')% name}" href="${h.url('rss_feed_home',repo_name=name,api_key=c.rhodecode_user.api_key)}"><i class="icon-rss-sign" style="color: #fa9b39"></i></a>
Added lightweight dashboard option. ref #500
r2936 %else:
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <a title="${_('Subscribe to %s rss feed')% name}" href="${h.url('rss_feed_home',repo_name=name)}"><i class="icon-rss-sign" style="color: #fa9b39"></i></a>
Added lightweight dashboard option. ref #500
r2936 %endif
</%def>
<%def name="atom(name)">
%if c.rhodecode_user.username != 'default':
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <a title="${_('Subscribe to %s atom feed')% name}" href="${h.url('atom_feed_home',repo_name=name,api_key=c.rhodecode_user.api_key)}"><i class="icon-rss-sign" style="color: #fa9b39"></i></a>
Added lightweight dashboard option. ref #500
r2936 %else:
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <a title="${_('Subscribe to %s atom feed')% name}" href="${h.url('atom_feed_home',repo_name=name)}"><i class="icon-rss-sign" style="color: #fa9b39"></i></a>
Added lightweight dashboard option. ref #500
r2936 %endif
</%def>
No more raw html inside users controller....
r2663 <%def name="user_gravatar(email, size=24)">
<div class="gravatar"><img alt="gravatar" src="${h.gravatar_url(email, size)}"/> </div>
</%def>
fixes issue #739 Delete/Edit repositories should only point to admin links if the user is an super admin.
r3245 <%def name="repo_actions(repo_name, super_user=True)">
Use common function for generation of grid data...
r3154 <div>
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <div style="float:left; margin-right:5px;" class="grid_edit">
fixes issue #739 Delete/Edit repositories should only point to admin links if the user is an super admin.
r3245 <a href="${h.url('edit_repo',repo_name=repo_name)}" title="${_('edit')}">
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <i class="icon-pencil"></i> ${h.submit('edit_%s' % repo_name,_('edit'),class_="action_button")}
fixes issue #739 Delete/Edit repositories should only point to admin links if the user is an super admin.
r3245 </a>
Use common function for generation of grid data...
r3154 </div>
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <div style="float:left" class="grid_delete">
fixes issue #739 Delete/Edit repositories should only point to admin links if the user is an super admin.
r3245 ${h.form(h.url('repo', repo_name=repo_name),method='delete')}
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <i class="icon-remove-sign" style="color:#FF4444"></i>
${h.submit('remove_%s' % repo_name,_('delete'),class_="action_button",
onclick="return confirm('"+_('Confirm to delete this repository: %s') % repo_name+"');")}
fixes issue #739 Delete/Edit repositories should only point to admin links if the user is an super admin.
r3245 ${h.end_form()}
Use common function for generation of grid data...
r3154 </div>
whitespace cleanup
r3168 </div>
Use common function for generation of grid data...
r3154 </%def>
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <%def name="repo_state(repo_state)">
<div>
%if repo_state == 'repo_state_pending':
<div class="btn btn-mini btn-info disabled">${_('Creating')}</div>
%elif repo_state == 'repo_state_created':
<div class="btn btn-mini btn-success disabled">${_('Created')}</div>
%else:
<div class="btn btn-mini btn-danger disabled" title="${repo_state}">invalid</div>
%endif
</div>
</%def>
No more raw html inside users controller....
r2663 <%def name="user_actions(user_id, username)">
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <div style="float:left" class="grid_edit">
make user listing have edit button to be consistent...
r3800 <a href="${h.url('edit_user',id=user_id)}" title="${_('edit')}">
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <i class="icon-pencil"></i> ${h.submit('edit_%s' % username,_('edit'),class_="action_button")}
make user listing have edit button to be consistent...
r3800 </a>
</div>
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <div style="float:left" class="grid_delete">
No more raw html inside users controller....
r2663 ${h.form(h.url('delete_user', id=user_id),method='delete')}
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <i class="icon-remove-sign" style="color:#FF4444"></i>
${h.submit('remove_',_('delete'),id="remove_user_%s" % user_id, class_="action_button",
onclick="return confirm('"+_('Confirm to delete this user: %s') % username+"');")}
No more raw html inside users controller....
r2663 ${h.end_form()}
make user listing have edit button to be consistent...
r3800 </div>
No more raw html inside users controller....
r2663 </%def>
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <%def name="user_group_actions(user_group_id, user_group_name)">
<div style="float:left" class="grid_edit">
<a href="${h.url('edit_users_group', id=user_group_id)}" title="${_('Edit')}">
<i class="icon-pencil"></i>
${h.submit('edit_%s' % user_group_name,_('edit'),class_="action_button", id_="submit_user_group_edit")}
</a>
</div>
<div style="float:left" class="grid_delete">
${h.form(h.url('users_group', id=user_group_id),method='delete')}
<i class="icon-remove-sign" style="color:#FF4444"></i>
${h.submit('remove_',_('delete'),id="remove_group_%s" % user_group_id, class_="action_button",
onclick="return confirm('"+_('Confirm to delete this user group: %s') % user_group_name+"');")}
${h.end_form()}
</div>
</%def>
<%def name="repo_group_actions(repo_group_id, repo_group_name, gr_count)">
<div style="float:left" class="grid_edit">
<a href="${h.url('edit_repo_group',group_name=repo_group_name)}" title="${_('Edit')}">
<i class="icon-pencil"></i>
${h.submit('edit_%s' % repo_group_name, _('edit'),class_="action_button")}
</a>
</div>
<div style="float:left" class="grid_delete">
${h.form(h.url('repos_group', group_name=repo_group_name),method='delete')}
<i class="icon-remove-sign" style="color:#FF4444"></i>
${h.submit('remove_%s' % repo_group_name,_('delete'),class_="action_button",
onclick="return confirm('"+ungettext('Confirm to delete this group: %s with %s repository','Confirm to delete this group: %s with %s repositories',gr_count) % (repo_group_name, gr_count)+"');")}
${h.end_form()}
</div>
</%def>
No more raw html inside users controller....
r2663 <%def name="user_name(user_id, username)">
${h.link_to(username,h.url('edit_user', id=user_id))}
</%def>
Use common function for generation of grid data...
r3154
Bradley M. Kuhn
Imported some of the GPLv3'd changes from RhodeCode v2.2.5....
r4116 <%def name="repo_group_name(repo_group_name, children_groups)">
<div style="white-space: nowrap">
<a href="${h.url('repos_group_home',group_name=repo_group_name)}">
<i class="icon-folder-close" title="${_('Repository group')}"></i> ${h.literal(' &raquo; '.join(children_groups))}</a>
</div>
</%def>
<%def name="user_group_name(user_group_id, user_group_name)">
<div style="white-space: nowrap">
<a href="${h.url('edit_users_group', id=user_group_id)}">
<i class="icon-group" title="${_('User group')}"></i> ${user_group_name}</a>
</div>
</%def>
Use common function for generation of grid data...
r3154 <%def name="toggle_follow(repo_id)">
<span id="follow_toggle_${repo_id}" class="following" title="${_('Stop following this repository')}"
onclick="javascript:toggleFollowingRepo(this, ${repo_id},'${str(h.get_token())}')">
</span>
</%def>