Changeset - b7654d1675da
[Not reviewed]
default
! ! !
domruf - 9 years ago 2016-09-18 19:39:36
dominikruf@gmail.com
style: in preparation for bootstrap, use bootstrap compatible button class names

Give all buttons a styling (default, success, danger, warning) and rename the sizes to sm and xs.

This is a subset of a bigger changeset. The subset was extracted by Mads Kiilerich, mostly by:

sed -i \
-e 's,btn btn-small,btn btn-default btn-sm,g' \
-e 's,btn btn-mini,btn btn-default btn-xs,g' \
-e 's,btn-default btn-\(xs\|sm\) btn-\(success\|danger\|warning\),btn-\2 btn-\1,g' \
-e 's,class_="btn",class_="btn btn-default",g' \
`hg mani`
77 files changed with 181 insertions and 181 deletions:
0 comments (0 inline, 0 general)
kallithea/public/css/style.css
Show inline comments
 
@@ -3160,29 +3160,29 @@ input.btn {
 
    padding: 0;
 
}
 

	
 
.btn.badge {
 
    cursor: default !important;
 
}
 

	
 
input[disabled].btn,
 
.btn.disabled {
 
    color: #999;
 
}
 

	
 
.btn.btn-small {
 
.btn.btn-sm {
 
    padding: 2px 6px;
 
}
 

	
 
.btn.btn-mini {
 
.btn.btn-xs {
 
    padding: 0px 4px;
 
}
 

	
 
.btn:focus {
 
    outline: none;
 
}
 
.btn:hover {
 
    text-decoration: none;
 
    color: #515151;
 
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25), 0 0 3px #FFFFFF !important;
 
}
 
.btn.badge:hover {
kallithea/public/js/base.js
Show inline comments
 
@@ -662,25 +662,25 @@ function comment_div_state($comment_div,
 
    $forms.remove();
 
    $buttonrow.remove();
 
    if (show_form) {
 
        _comment_div_append_form($comment_div, f_path, line_no);
 
    } else if ($comments.length) {
 
        _comment_div_append_add($comment_div, f_path, line_no);
 
    }
 
}
 

	
 
// append an Add button to $comment_div and hook it up to show form
 
function _comment_div_append_add($comment_div, f_path, line_no) {
 
    var addlabel = TRANSLATION_MAP['Add Another Comment'];
 
    var $add = $('<div class="add-button-row"><span class="btn btn-mini add-button">{0}</span></div>'.format(addlabel));
 
    var $add = $('<div class="add-button-row"><span class="btn btn-default btn-xs add-button">{0}</span></div>'.format(addlabel));
 
    $comment_div.append($add);
 
    $add.children('.add-button').click(function(e) {
 
        comment_div_state($comment_div, f_path, line_no, true);
 
    });
 
}
 

	
 
// append a comment form to $comment_div
 
function _comment_div_append_form($comment_div, f_path, line_no) {
 
    var $form_div = $('#comment-inline-form-template').children()
 
        .clone()
 
        .addClass('comment-inline-form');
 
    $comment_div.append($form_div);
kallithea/templates/admin/admin.html
Show inline comments
 
## -*- coding: utf-8 -*-
 
<%inherit file="/base/base.html"/>
 

	
 
<%block name="title">
 
    ${_('Admin Journal')}
 
</%block>
 

	
 
<%def name="breadcrumbs_links()">
 
    <form id="filter_form">
 
    <input class="q_filter_box ${'' if c.search_term else 'initial'}" id="j_filter" size="15" type="text" name="filter" value="${c.search_term or _('journal filter...')}"/>
 
    <span class="tooltip" title="${h.journal_filter_help()}">?</span>
 
    <input type='submit' value="${_('Filter')}" class="btn btn-mini" style="padding:0px 2px 0px 2px;margin:0px"/>
 
    <input type='submit' value="${_('Filter')}" class="btn btn-default btn-xs" style="padding:0px 2px 0px 2px;margin:0px"/>
 
    ${_('Admin Journal')} - ${ungettext('%s Entry', '%s Entries', c.users_log.item_count) % (c.users_log.item_count)}
 
    </form>
 
    ${h.end_form()}
 
</%def>
 

	
 
<%block name="header_menu">
 
    ${self.menu('admin')}
 
</%block>
 
<%def name="main()">
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
kallithea/templates/admin/auth/auth_settings.html
Show inline comments
 
@@ -27,25 +27,25 @@
 
    ## enabled auth plugins
 
    <h1>${_('Authentication Plugins')}</h1>
 
    <div class="fields">
 
       <div class="field">
 
           <div class="label"><label for="auth_plugins">${_("Enabled Plugins")}</label></div>
 
           <div class="input">${h.text("auth_plugins", class_='large')}
 
           <span class="help-block">${_('Comma-separated list of plugins; Kallithea will try user authentication in plugin order')}</span>
 
               <div style="padding:10px 0px 10px 0px;font-weight: bold">${_('Available built-in plugins')}</div>
 
               <ul>
 
               %for plugin_path in c.available_plugins:
 
                    <li>
 
                      <div style="padding:3px 0px 3px 0px">
 
                          <span style="margin: 0px 10px 0px 0px" plugin_id="${plugin_path}" class="toggle-plugin btn btn-mini ${'active' if plugin_path in c.enabled_plugins else ''}">
 
                          <span style="margin: 0px 10px 0px 0px" plugin_id="${plugin_path}" class="toggle-plugin btn btn-default btn-xs ${'active' if plugin_path in c.enabled_plugins else ''}">
 
                          ${_('Enabled') if plugin_path in c.enabled_plugins else _('Disabled')}</span>${plugin_path}
 
                      </div>
 
                    </li>
 
               %endfor
 
               </ul>
 
           </div>
 
       </div>
 
    </div>
 

	
 
    %for cnt, module in enumerate(c.enabled_plugins):
 
        <% pluginName = c.plugin_shortnames[module] %>
 
        <h1>${_('Plugin')}: ${pluginName}</h1>
 
@@ -89,25 +89,25 @@
 
            %else:
 
            <div class="field">
 
                <div class="label"><label for="${fullsetting}">${_(displayname)}</label></div>
 
                <div class="input">This field is of type ${setting['type']}, which cannot be displayed. Must be one of [string|int|bool|select].</div>
 
                <span class="help-block">${setting["description"]}</span>
 
            </div>
 
            %endif
 
        %endfor
 
        </div>
 
    %endfor
 
        <div class="fields">
 
            <div class="buttons">
 
                ${h.submit('save',_('Save'),class_="btn")}
 
                ${h.submit('save',_('Save'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
 

	
 
<script>
 
    $('.toggle-plugin').click(function(e){
 
        var $auth_plugins_input = $('#auth_plugins');
 
        var notEmpty = function(element, index, array) {
 
            return (element != "");
 
        }
kallithea/templates/admin/defaults/defaults.html
Show inline comments
 
@@ -70,22 +70,22 @@
 

	
 
            <div class="field">
 
                <div class="label label-checkbox">
 
                    <label for="default_repo_enable_locking">${_('Enable locking')}:</label>
 
                </div>
 
                <div class="checkboxes">
 
                    ${h.checkbox('default_repo_enable_locking',value="True")}
 
                    <span class="help-block">${_('Enable lock-by-pulling on repository.')}</span>
 
                </div>
 
            </div>
 

	
 
            <div class="buttons">
 
            ${h.submit('save',_('Save'),class_="btn")}
 
            ${h.submit('save',_('Save'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 

	
 
    ##<h3>${_('Groups defaults')}</h3>
 

	
 
</div>
 
</%def>
kallithea/templates/admin/gists/edit.html
Show inline comments
 
@@ -132,26 +132,26 @@
 
                        var detected_mode = CodeMirror.findModeByExtension("${file.extension}");
 

	
 
                        if (detected_mode){
 
                            setCodeMirrorMode(myCodeMirror, detected_mode);
 
                            $mimetype_select.val(detected_mode.mime);
 
                        }
 
                    });
 
                </script>
 

	
 
            %endfor
 

	
 
            <div style="padding-top: 5px">
 
            ${h.submit('update',_('Update Gist'),class_="btn btn-mini btn-success")}
 
            <a class="btn btn-mini" href="${h.url('gist', gist_id=c.gist.gist_access_id)}">${_('Cancel')}</a>
 
            ${h.submit('update',_('Update Gist'),class_="btn btn-success btn-xs")}
 
            <a class="btn btn-default btn-xs" href="${h.url('gist', gist_id=c.gist.gist_access_id)}">${_('Cancel')}</a>
 
            </div>
 
          ${h.end_form()}
 
          <script>
 
              $('#update').on('click', function(e){
 
                  e.preventDefault();
 

	
 
                  // check for newer version.
 
                  $.ajax({
 
                    url: "${h.url('edit_gist_check_revision', gist_id=c.gist.gist_access_id)}",
 
                    data: {'revision': '${c.file_changeset.raw_id}', '_authentication_token': _authentication_token},
 
                    dataType: 'json',
 
                    type: 'POST',
kallithea/templates/admin/gists/index.html
Show inline comments
 
@@ -25,25 +25,25 @@
 
<%block name="header_menu">
 
    ${self.menu('gists')}
 
</%block>
 

	
 
<%def name="main()">
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
        %if c.authuser.username != 'default':
 
        <ul class="links">
 
          <li>
 
             <a href="${h.url('new_gist')}" class="btn btn-small btn-success"><i class="icon-plus"></i> ${_('Create New Gist')}</a>
 
             <a href="${h.url('new_gist')}" class="btn btn-success btn-sm"><i class="icon-plus"></i> ${_('Create New Gist')}</a>
 
          </li>
 
        </ul>
 
        %endif
 
    </div>
 
    %if c.gists_pager.item_count>0:
 
        % for gist in c.gists_pager:
 
          <div class="gist-item" style="padding:10px 20px 10px 15px">
 

	
 
            ${h.gravatar_div(gist.owner.email, size=28)}
 
            <div title="${gist.owner.full_contact}" class="user" style="font-size: 16px">
 
                <b>${h.person(gist.owner.full_contact)}</b> /
 
                <b><a href="${h.url('gist',gist_id=gist.gist_access_id)}">gist: ${gist.gist_access_id}</a></b>
kallithea/templates/admin/gists/new.html
Show inline comments
 
@@ -42,27 +42,27 @@
 
            </div>
 
            <div id="body" class="codeblock">
 
                <div style="padding: 10px 10px 10px 26px;color:#666666">
 
                    ${h.text('filename', size=30, placeholder=_('name this file...'))}
 
                    <select id="mimetype" name="mimetype"/>
 
                </div>
 
                <div id="editor_container">
 
                    <pre id="editor_pre"></pre>
 
                    <textarea id="editor" name="content" style="display:none"></textarea>
 
                </div>
 
            </div>
 
            <div style="padding-top: 5px">
 
            ${h.submit('private',_('Create Private Gist'),class_="btn btn-mini btn-success")}
 
            ${h.submit('public',_('Create Public Gist'),class_="btn btn-mini")}
 
            ${h.reset('reset',_('Reset'),class_="btn btn-mini")}
 
            ${h.submit('private',_('Create Private Gist'),class_="btn btn-success btn-xs")}
 
            ${h.submit('public',_('Create Public Gist'),class_="btn btn-default btn-xs")}
 
            ${h.reset('reset',_('Reset'),class_="btn btn-default btn-xs")}
 
            </div>
 
          ${h.end_form()}
 
          <script type="text/javascript">
 
            $(document).ready(function(){
 
                var myCodeMirror = initCodeMirror('editor', "${request.script_name}", '');
 

	
 
                //inject new modes
 
                var $mimetype_select = $('#mimetype');
 
                $mimetype_select.each(function(){
 
                    var modes_select = this;
 
                    var index = 1;
 
                    for(var i=0;i<CodeMirror.modeInfo.length;i++) {
kallithea/templates/admin/gists/show.html
Show inline comments
 
@@ -13,84 +13,84 @@
 
<%block name="header_menu">
 
    ${self.menu('gists')}
 
</%block>
 

	
 
<%def name="main()">
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
        %if c.authuser.username != 'default':
 
        <ul class="links">
 
          <li>
 
              <a href="${h.url('new_gist')}" class="btn btn-small btn-success"><i class="icon-plus"></i> ${_('Create New Gist')}</a>
 
              <a href="${h.url('new_gist')}" class="btn btn-success btn-sm"><i class="icon-plus"></i> ${_('Create New Gist')}</a>
 
          </li>
 
        </ul>
 
        %endif
 
    </div>
 
    <div class="table">
 
        <div id="files_data">
 
            <div id="body" class="codeblock">
 
                <div class="code-header">
 
                    <div class="stats">
 
                        <div class="left" style="margin: -4px 0px 0px 0px">
 
                          %if c.gist.gist_type == 'public':
 
                            <div class="btn btn-mini btn-success disabled">${_('Public Gist')}</div>
 
                            <div class="btn btn-success btn-xs disabled">${_('Public Gist')}</div>
 
                          %else:
 
                            <div class="btn btn-mini btn-warning disabled">${_('Private Gist')}</div>
 
                            <div class="btn btn-warning btn-xs disabled">${_('Private Gist')}</div>
 
                          %endif
 
                        </div>
 
                        <div class="left item">
 
                            ${c.gist.gist_description}
 
                        </div>
 
                        <div class="left item last" style="color: #AAA">
 
                         %if c.gist.gist_expires == -1:
 
                          ${_('Expires')}: ${_('Never')}
 
                         %else:
 
                          ${_('Expires')}: ${h.age(h.time_to_datetime(c.gist.gist_expires))}
 
                         %endif
 
                       </div>
 

	
 
                       %if h.HasPermissionAny('hg.admin')() or c.gist.gist_owner == c.authuser.user_id:
 
                        <div style="float:right">
 
                            ${h.form(url('gist_delete', gist_id=c.gist.gist_id))}
 
                                ${h.submit('remove_gist', _('Delete'),class_="btn btn-mini btn-danger",onclick="return confirm('"+_('Confirm to delete this Gist')+"');")}
 
                                ${h.submit('remove_gist', _('Delete'),class_="btn btn-danger btn-xs",onclick="return confirm('"+_('Confirm to delete this Gist')+"');")}
 
                            ${h.end_form()}
 
                        </div>
 
                       %endif
 
                        <div class="buttons">
 
                          ## only owner should see that
 
                          %if h.HasPermissionAny('hg.admin')() or c.gist.gist_owner == c.authuser.user_id:
 
                            ${h.link_to(_('Edit'),h.url('edit_gist', gist_id=c.gist.gist_access_id),class_="btn btn-mini")}
 
                            ${h.link_to(_('Edit'),h.url('edit_gist', gist_id=c.gist.gist_access_id),class_="btn btn-default btn-xs")}
 
                          %endif
 
                          ${h.link_to(_('Show as Raw'),h.url('formatted_gist', gist_id=c.gist.gist_access_id, format='raw'),class_="btn btn-mini")}
 
                          ${h.link_to(_('Show as Raw'),h.url('formatted_gist', gist_id=c.gist.gist_access_id, format='raw'),class_="btn btn-default btn-xs")}
 
                        </div>
 
                    </div>
 

	
 
                    <div class="author">
 
                        ${h.gravatar_div(h.email_or_none(c.file_changeset.author), size=16)}
 
                        <div title="${c.file_changeset.author}" class="user">${h.person(c.file_changeset.author)} - ${_('created')} ${h.age(c.file_changeset.date)}</div>
 
                    </div>
 
                    <div class="commit">${h.urlify_text(c.file_changeset.message,c.repo_name)}</div>
 
                </div>
 
            </div>
 

	
 
               ## iterate over the files
 
               % for file in c.files:
 
               <div style="border: 1px solid #EEE;margin-top:20px">
 
                <div id="${h.FID('G', file.path)}" class="stats" style="border-bottom: 1px solid #DDD;padding: 8px 14px;">
 
                    <a href="${c.gist.gist_url()}">¶</a>
 
                    <b style="margin:0px 0px 0px 4px">${h.safe_unicode(file.path)}</b>
 
                    <div style="float:right; margin: -5px">
 
                       ${h.link_to(_('Show as raw'),h.url('formatted_gist_file', gist_id=c.gist.gist_access_id, format='raw', revision=file.changeset.raw_id, f_path=h.safe_unicode(file.path)),class_="btn btn-mini")}
 
                       ${h.link_to(_('Show as raw'),h.url('formatted_gist_file', gist_id=c.gist.gist_access_id, format='raw', revision=file.changeset.raw_id, f_path=h.safe_unicode(file.path)),class_="btn btn-default btn-xs")}
 
                    </div>
 
                </div>
 
                <div class="code-body">
 
                    ${h.pygmentize(file,linenos=True,anchorlinenos=True,lineanchors='L',cssclass="code-highlight")}
 
                </div>
 
              </div>
 
               %endfor
 
        </div>
 
    </div>
 

	
 

	
 
</div>
kallithea/templates/admin/my_account/my_account_api_keys.html
Show inline comments
 
<div class="apikeys_wrap">
 
  <table class="noborder">
 
    <tr>
 
        <td style="width: 450px"><div class="truncate autoexpand" style="width:120px;font-size:16px;font-family: monospace">${c.user.api_key}</div></td>
 
        <td>
 
            <span class="btn btn-mini btn-success disabled">${_('Built-in')}</span>
 
            <span class="btn btn-success btn-xs disabled">${_('Built-in')}</span>
 
        </td>
 
        <td>${_('Expires')}: ${_('Never')}</td>
 
        <td>
 
            ${h.form(url('my_account_api_keys_delete'))}
 
                ${h.hidden('del_api_key',c.user.api_key)}
 
                ${h.hidden('del_api_key_builtin',1)}
 
                <button class="btn btn-mini btn-danger" type="submit"
 
                <button class="btn btn-danger btn-xs" type="submit"
 
                        onclick="return confirm('${_('Confirm to reset this API key: %s') % c.user.api_key}');">
 
                    ${_('Reset')}
 
                </button>
 
            ${h.end_form()}
 
        </td>
 
    </tr>
 
    %if c.user_api_keys:
 
        %for api_key in c.user_api_keys:
 
          <tr class="${'expired' if api_key.expired else ''}">
 
            <td style="width: 450px"><div class="truncate autoexpand" style="width:120px;font-size:16px;font-family: monospace">${api_key.api_key}</div></td>
 
            <td>${api_key.description}</td>
 
            <td style="min-width: 80px">
 
@@ -27,25 +27,25 @@
 
                  ${_('Expires')}: ${_('Never')}
 
                 %else:
 
                    %if api_key.expired:
 
                        ${_('Expired')}: ${h.age(h.time_to_datetime(api_key.expires))}
 
                    %else:
 
                        ${_('Expires')}: ${h.age(h.time_to_datetime(api_key.expires))}
 
                    %endif
 
                 %endif
 
            </td>
 
            <td>
 
                ${h.form(url('my_account_api_keys_delete'))}
 
                    ${h.hidden('del_api_key',api_key.api_key)}
 
                    <button class="btn btn-mini btn-danger" type="submit"
 
                    <button class="btn btn-danger btn-xs" type="submit"
 
                            onclick="return confirm('${_('Confirm to remove this API key: %s') % api_key.api_key}');">
 
                        <i class="icon-minus-circled"></i>
 
                        ${_('Remove')}
 
                    </button>
 
                ${h.end_form()}
 
            </td>
 
          </tr>
 
        %endfor
 
    %else:
 
    <tr><td><div class="ip">${_('No additional API keys specified')}</div></td></tr>
 
    %endif
 
  </table>
 
@@ -57,26 +57,26 @@
 
        <!-- fields -->
 
        <div class="fields">
 
             <div class="field">
 
                <div class="label">
 
                    <label for="description">${_('New API key')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('description', class_='medium', placeholder=_('Description'))}
 
                    ${h.select('lifetime', '', c.lifetime_options)}
 
                </div>
 
             </div>
 
            <div class="buttons">
 
              ${h.submit('save',_('Add'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Add'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
 

	
 
<script>
 
    $(document).ready(function(){
 
        $("#lifetime").select2({
 
            'dropdownAutoWidth': true
 
        });
 
    });
kallithea/templates/admin/my_account/my_account_emails.html
Show inline comments
 
<div class="emails_wrap">
 
  <table class="noborder">
 
    <tr>
 
    %if c.visual.use_gravatar:
 
    <td>${h.gravatar_div(c.user.email, size=16)}</td>
 
    %endif
 
    <td><div class="email">${c.user.email}</div></td>
 
    <td>
 
        <span class="btn btn-mini btn-success disabled">${_('Primary')}</span>
 
        <span class="btn btn-success btn-xs disabled">${_('Primary')}</span>
 
    </td>
 
    </tr>
 
    %if c.user_email_map:
 
        %for em in c.user_email_map:
 
          <tr>
 
            %if c.visual.use_gravatar:
 
            <td>${h.gravatar_div(em.email, size=16)}</td>
 
            %endif
 
            <td><div class="email">${em.email}</div></td>
 
            <td>
 
                ${h.form(url('my_account_emails_delete'))}
 
                    ${h.hidden('del_email_id',em.email_id)}
 
@@ -37,19 +37,19 @@
 
    <div class="form">
 
        <!-- fields -->
 
        <div class="fields">
 
             <div class="field">
 
                <div class="label">
 
                    <label for="new_email">${_('New email address')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('new_email', class_='medium')}
 
                </div>
 
             </div>
 
            <div class="buttons">
 
              ${h.submit('save',_('Add'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Add'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
kallithea/templates/admin/my_account/my_account_password.html
Show inline comments
 
@@ -24,24 +24,24 @@ ${h.form(url('my_account_password'), met
 
     </div>
 

	
 
     <div class="field">
 
        <div class="label">
 
            <label for="new_password_confirmation">${_('Confirm new password')}:</label>
 
        </div>
 
        <div class="input">
 
            ${h.password('new_password_confirmation',class_='medium')}
 
        </div>
 
     </div>
 

	
 
        <div class="buttons">
 
          ${h.submit('save',_('Save'),class_="btn")}
 
          ${h.reset('reset',_('Reset'),class_="btn")}
 
          ${h.submit('save',_('Save'),class_="btn btn-default")}
 
          ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
        </div>
 
    </div>
 
</div>
 
${h.end_form()}
 

	
 
%else:
 

	
 
${_('This account is managed with %s and the password cannot be changed here') % c.user.extern_type}
 

	
 
%endif
kallithea/templates/admin/my_account/my_account_profile.html
Show inline comments
 
@@ -46,18 +46,18 @@ ${h.form(url('my_account'), method='post
 
             </div>
 

	
 
             <div class="field">
 
                <div class="label">
 
                    <label for="email">${_('Email')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('email',class_="medium", readonly=c.readonly('email'))}
 
                </div>
 
             </div>
 

	
 
            <div class="buttons">
 
              ${h.submit('save',_('Save'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Save'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
${h.end_form()}
kallithea/templates/admin/notifications/notifications.html
Show inline comments
 
@@ -12,31 +12,31 @@
 
<%block name="header_menu">
 
    ${self.menu('admin')}
 
</%block>
 

	
 
<%def name="main()">
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
    </div>
 

	
 
      <div style="padding:14px 18px;text-align: right;float:left">
 
      <span id='all' class="btn btn-small"><a href="${h.url.current()}">${_('All')}</a></span>
 
      <span id='comment' class="btn btn-small"><a href="${h.url.current(type=c.comment_type)}">${_('Comments')}</a></span>
 
      <span id='pull_request' class="btn btn-small"><a href="${h.url.current(type=c.pull_request_type)}">${_('Pull Requests')}</a></span>
 
      <span id='all' class="btn btn-default btn-sm"><a href="${h.url.current()}">${_('All')}</a></span>
 
      <span id='comment' class="btn btn-default btn-sm"><a href="${h.url.current(type=c.comment_type)}">${_('Comments')}</a></span>
 
      <span id='pull_request' class="btn btn-default btn-sm"><a href="${h.url.current(type=c.pull_request_type)}">${_('Pull Requests')}</a></span>
 
      </div>
 
      %if c.notifications:
 
      <div style="padding:14px 18px;text-align: right;float:right">
 
      <span id='mark_all_read' class="btn btn-small">${_('Mark All Read')}</span>
 
      <span id='mark_all_read' class="btn btn-default btn-sm">${_('Mark All Read')}</span>
 
      </div>
 
      %endif
 
  <div id='notification_data'>
 
    <%include file='notifications_data.html'/>
 
  </div>
 
</div>
 
<script type="text/javascript">
 
var url_delete = "${url('notification_delete', notification_id='__NOTIFICATION_ID__')}";
 
var url_read = "${url('notification_update', notification_id='__NOTIFICATION_ID__')}";
 
var run = function(){
 
  $('.delete-notification').click(function(e){
 
    var notification_id = e.currentTarget.id;
kallithea/templates/admin/permissions/permissions_globals.html
Show inline comments
 
@@ -100,18 +100,18 @@ ${h.form(url('admin_permissions'), metho
 
                    ${h.select('default_register','',c.register_choices)}
 
                </div>
 
             </div>
 
             <div class="field">
 
                <div class="label">
 
                    <label for="default_extern_activate">${_('External auth account activation')}:</label>
 
                </div>
 
                <div class="select">
 
                    ${h.select('default_extern_activate','',c.extern_activate_choices)}
 
                </div>
 
             </div>
 
            <div class="buttons">
 
              ${h.submit('save',_('Save'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Save'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
${h.end_form()}
kallithea/templates/admin/permissions/permissions_ips.html
Show inline comments
 
@@ -26,18 +26,18 @@ ${h.form(url('edit_user_ips_update', id=
 
        <!-- fields -->
 
        <div class="fields">
 
             <div class="field">
 
                <div class="label">
 
                    <label for="new_ip">${_('New IP address')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.hidden('default_user', 'True')}
 
                    ${h.text('new_ip', class_='medium')}
 
                </div>
 
             </div>
 
            <div class="buttons">
 
              ${h.submit('save',_('Add'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Add'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
${h.end_form()}
kallithea/templates/admin/repo_groups/repo_group_add.html
Show inline comments
 
@@ -57,25 +57,25 @@
 

	
 
            <div id="copy_perms" class="field">
 
                <div class="label label-checkbox">
 
                    <label for="group_copy_permissions">${_('Copy parent group permissions')}:</label>
 
                </div>
 
                <div class="checkboxes">
 
                    ${h.checkbox('group_copy_permissions',value="True")}
 
                    <span class="help-block">${_('Copy permission set from parent repository group.')}</span>
 
                </div>
 
            </div>
 

	
 
            <div class="buttons">
 
              ${h.submit('save',_('Save'),class_="btn")}
 
              ${h.submit('save',_('Save'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
 
<script>
 
    $(document).ready(function(){
 
        var setCopyPermsOption = function(group_val){
 
            if(group_val != "-1"){
 
                $('#copy_perms').show();
 
            }
 
            else{
kallithea/templates/admin/repo_groups/repo_group_edit.html
Show inline comments
 
@@ -9,25 +9,25 @@
 
    ${h.link_to(_('Admin'),h.url('admin_home'))}
 
    &raquo;
 
    ${h.link_to(_('Repository Groups'),h.url('repos_groups'))}
 
    %if c.repo_group.parent_group:
 
        &raquo; ${h.link_to(c.repo_group.parent_group.name,h.url('repos_group_home',group_name=c.repo_group.parent_group.group_name))}
 
    %endif
 
    &raquo; ${h.link_to(c.repo_group.name,h.url('repos_group_home',group_name=c.repo_group.group_name))}
 
</%def>
 

	
 
<%def name="breadcrumbs_side_links()">
 
    <ul class="links">
 
      <li>
 
          <a href="${h.url('new_repos_group', parent_group=c.repo_group.group_id)}" class="btn btn-small btn-success"><i class="icon-plus"></i> ${_('Add Child Group')}</a>
 
          <a href="${h.url('new_repos_group', parent_group=c.repo_group.group_id)}" class="btn btn-success btn-sm"><i class="icon-plus"></i> ${_('Add Child Group')}</a>
 
      </li>
 
    </ul>
 
</%def>
 

	
 
<%block name="header_menu">
 
    ${self.menu('admin')}
 
</%block>
 

	
 
<%def name="main()">
 
<div class="box" style="overflow:auto">
 
    <div class="title">
 
        ${self.breadcrumbs()}
kallithea/templates/admin/repo_groups/repo_group_edit_advanced.html
Show inline comments
 
@@ -8,20 +8,20 @@
 
    (_('Children groups'), c.repo_group.children.count(), ''),
 
    (_('Created on'), h.fmt_date(c.repo_group.created_on), ''),
 
    (_('Owner'), h.person(c.repo_group.owner), ''),
 
 ]
 
%>
 
%for dt, dd, tt in elems:
 
  <dt style="width:150px; text-align: left">${dt}:</dt>
 
  <dd style="margin-left: 160px" title="${tt}">${dd}</dd>
 
%endfor
 
</dl>
 

	
 
${h.form(h.url('delete_repos_group', group_name=c.repo_group.group_name))}
 
    <button class="btn btn-small btn-danger" type="submit"
 
    <button class="btn btn-danger btn-sm" type="submit"
 
            onclick="return confirm('${ungettext('Confirm to delete this group: %s with %s repository',
 
          'Confirm to delete this group: %s with %s repositories',
 
 c.repo_group.repositories_recursive_count) % (c.repo_group.group_name, c.repo_group.repositories_recursive_count)}');">
 
        <i class="icon-minus-circled"></i>
 
        ${_('Delete this repository group')}
 
    </button>
 
${h.end_form()}
kallithea/templates/admin/repo_groups/repo_group_edit_perms.html
Show inline comments
 
@@ -102,26 +102,26 @@ ${h.form(url('edit_repo_group_perms', gr
 
                    <td colspan="6">
 
                       ${_('Apply to children')}:
 
                       ${h.radio('recursive', 'none', label=_('None'), checked="checked")}
 
                       ${h.radio('recursive', 'groups', label=_('Repository Groups'))}
 
                       ${h.radio('recursive', 'repos', label=_('Repositories'))}
 
                       ${h.radio('recursive', 'all', label=_('Both'))}
 
                       <span class="help-block">${_('Set or revoke permission to all children of that group, including non-private repositories and other groups if selected.')}</span>
 
                    </td>
 
                </tr>
 
            </table>
 
        </div>
 
        <div class="buttons">
 
          ${h.submit('save',_('Save'),class_="btn")}
 
          ${h.reset('reset',_('Reset'),class_="btn")}
 
          ${h.submit('save',_('Save'),class_="btn btn-default")}
 
          ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
        </div>
 
   </div>
 
</div>
 
${h.end_form()}
 

	
 
<script type="text/javascript">
 
    function ajaxActionRevoke(obj_id, obj_type, field_id, obj_name) {
 
        url = "${h.url('edit_repo_group_perms_delete', group_name=c.repo_group.group_name)}";
 
        var revoke_msg = _TM['Confirm to revoke permission for {0}: {1} ?'].format(obj_type.replace('_', ' '), obj_name);
 
        if (confirm(revoke_msg)){
 
            var recursive = $('input[name=recursive]:checked').val();
 
            ajaxActionRevokePermission(url, obj_id, obj_type, field_id, {recursive:recursive});
kallithea/templates/admin/repo_groups/repo_group_edit_settings.html
Show inline comments
 
@@ -30,26 +30,26 @@ ${h.form(url('update_repos_group',group_
 
            </div>
 
        </div>
 
        <div class="field">
 
            <div class="label label-checkbox">
 
                <label for="enable_locking">${_('Enable locking')}:</label>
 
            </div>
 
            <div class="checkboxes">
 
                ${h.checkbox('enable_locking',value="True")}
 
                <span class="help-block">${_('Enable lock-by-pulling on group. This option will be applied to all other groups and repositories inside')}</span>
 
            </div>
 
        </div>
 
        <div class="buttons">
 
          ${h.submit('save',_('Save'),class_="btn")}
 
          ${h.reset('reset',_('Reset'),class_="btn")}
 
          ${h.submit('save',_('Save'),class_="btn btn-default")}
 
          ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
        </div>
 
    </div>
 
</div>
 
${h.end_form()}
 

	
 
${h.form(url('delete_repo_group', group_name=c.repo_group.group_name))}
 
<div class="form">
 
    <div class="fields">
 
        <div class="field" style="border:none;color:#888">
 
            ${h.submit('remove_%s' % c.repo_group.group_name,_('Remove this group'),class_="btn red",onclick="return confirm('"+_('Confirm to delete this group')+"');")}
 
        </div>
 
    </div>
kallithea/templates/admin/repo_groups/repo_groups.html
Show inline comments
 
@@ -13,25 +13,25 @@
 
<%block name="header_menu">
 
    ${self.menu('admin')}
 
</%block>
 

	
 
<%def name="main()">
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
        <ul class="links">
 
            %if h.HasPermissionAny('hg.admin')():
 
             <li>
 
               <a href="${h.url('new_repos_group')}" class="btn btn-small btn-success"><i class="icon-plus"></i> ${_('Add Repository Group')}</a>
 
               <a href="${h.url('new_repos_group')}" class="btn btn-success btn-sm"><i class="icon-plus"></i> ${_('Add Repository Group')}</a>
 
             </li>
 
            %endif
 
        </ul>
 
    </div>
 
    <!-- end box / title -->
 
    <div class="table">
 
        <table id="datatable_list_wrap"></table>
 
    </div>
 
</div>
 
<script>
 
  var data = ${c.data|n};
 
  var myDataTable = $("#datatable_list_wrap").DataTable({
kallithea/templates/admin/repos/repo_add_base.html
Show inline comments
 
@@ -69,25 +69,25 @@ ${h.form(url('repos'))}
 
            </div>
 
        </div>
 
        <div class="field">
 
            <div class="label label-checkbox">
 
                <label for="repo_private">${_('Private repository')}:</label>
 
            </div>
 
            <div class="checkboxes">
 
                ${h.checkbox('repo_private',value="True")}
 
                <span class="help-block">${_('Private repositories are only visible to people explicitly added as collaborators.')}</span>
 
            </div>
 
        </div>
 
        <div class="buttons">
 
          ${h.submit('add',_('Add'),class_="btn")}
 
          ${h.submit('add',_('Add'),class_="btn btn-default")}
 
        </div>
 
    </div>
 
</div>
 
<script>
 
    $(document).ready(function(){
 
        var setCopyPermsOption = function(group_val){
 
            if(group_val != "-1"){
 
                $('#copy_perms').show();
 
            }
 
            else{
 
                $('#copy_perms').hide();
 
            }
kallithea/templates/admin/repos/repo_edit_advanced.html
Show inline comments
 
<h3>${_('Parent')}</h3>
 
${h.form(url('edit_repo_advanced_fork', repo_name=c.repo_info.repo_name))}
 
<div class="form">
 
       ${h.select('id_fork_of','',c.repos_list,class_="medium")}
 
       ${h.submit('set_as_fork_%s' % c.repo_info.repo_name,_('Set'),class_="btn btn-small")}
 
       ${h.submit('set_as_fork_%s' % c.repo_info.repo_name,_('Set'),class_="btn btn-default btn-sm")}
 
       <div class="field" style="border:none;color:#888">
 
       <ul>
 
            <li>${_('''Manually set this repository as a fork of another from the list.''')}</li>
 
       </ul>
 
       </div>
 
</div>
 
${h.end_form()}
 

	
 
<script>
 
    $(document).ready(function(){
 
        $("#id_fork_of").select2({
 
            'dropdownAutoWidth': true
 
        });
 
    });
 
</script>
 

	
 
<h3>${_('Public Journal Visibility')}</h3>
 
${h.form(url('edit_repo_advanced_journal', repo_name=c.repo_info.repo_name))}
 
<div class="form">
 
  <div class="field">
 
  %if c.in_public_journal:
 
    <button class="btn btn-small" type="submit">
 
    <button class="btn btn-default btn-sm" type="submit">
 
        <i class="icon-minus"></i>
 
        ${_('Remove from public journal')}
 
    </button>
 
  %else:
 
    <button class="btn btn-small" type="submit">
 
    <button class="btn btn-default btn-sm" type="submit">
 
        <i class="icon-plus"></i>
 
        ${_('Add to Public Journal')}
 
    </button>
 
  %endif
 
  </div>
 
 <div class="field" style="border:none;color:#888">
 
 <ul>
 
      <li>${_('All actions done in this repository will be visible to everyone in the public journal.')}</li>
 
 </ul>
 
 </div>
 
</div>
 
${h.end_form()}
 

	
 
<h3>${_('Change Locking')}</h3>
 
${h.form(url('edit_repo_advanced_locking', repo_name=c.repo_info.repo_name))}
 
<div class="form">
 
      %if c.repo_info.locked[0]:
 
        ${h.hidden('set_unlock', '1')}
 
        <button class="btn btn-small" type="submit"
 
        <button class="btn btn-default btn-sm" type="submit"
 
                onclick="return confirm('${_('Confirm to unlock repository.')}');">
 
            <i class="icon-lock-open-alt"></i>
 
            ${_('Unlock Repository')}
 
        </button>
 
       ${_('Locked by %s on %s') % (h.person_by_id(c.repo_info.locked[0]),h.fmt_date(h.time_to_datetime(c.repo_info.locked[1])))}
 
      %else:
 
        ${h.hidden('set_lock', '1')}
 
        <button class="btn btn-small" type="submit"
 
        <button class="btn btn-default btn-sm" type="submit"
 
                onclick="return confirm('${_('Confirm to lock repository.')}');">
 
            <i class="icon-lock"></i>
 
            ${_('Lock Repository')}
 
        </button>
 
        ${_('Repository is not locked')}
 
      %endif
 
   <div class="field" style="border:none;color:#888">
 
   <ul>
 
        <li>${_('Force locking on the repository. Works only when anonymous access is disabled. Triggering a pull locks the repository.  The user who is pulling locks the repository; only the user who pulled and locked it can unlock it by doing a push.')}
 
        </li>
 
   </ul>
 
   </div>
 
</div>
 
${h.end_form()}
 

	
 
<h3>${_('Delete')}</h3>
 
${h.form(url('delete_repo', repo_name=c.repo_name))}
 
<div class="form">
 
    <button class="btn btn-small btn-danger" type="submit"
 
    <button class="btn btn-danger btn-sm" type="submit"
 
            onclick="return confirm('${_('Confirm to delete this repository: %s') % c.repo_name}');">
 
        <i class="icon-minus-circled"></i>
 
        ${_('Delete this Repository')}
 
    </button>
 
    %if c.repo_info.forks.count():
 
        ${ungettext('This repository has %s fork', 'This repository has %s forks', c.repo_info.forks.count()) % c.repo_info.forks.count()}
 
        <input type="radio" name="forks" value="detach_forks" checked="checked"/> <label for="forks">${_('Detach forks')}</label>
 
        <input type="radio" name="forks" value="delete_forks" /> <label for="forks">${_('Delete forks')}</label>
 
    %endif
 
    <div class="field" style="border:none;color:#888">
 
        <ul>
 
        <li>${_('The deleted repository will be moved away and hidden until the administrator expires it. The administrator can both permanently delete it or restore it.')}</li>
kallithea/templates/admin/repos/repo_edit_caches.html
Show inline comments
 
${h.form(url('update_repo_caches', repo_name=c.repo_name))}
 
<div class="form">
 
   <div class="fields">
 
       ${h.submit('reset_cache_%s' % c.repo_info.repo_name,_('Invalidate Repository Cache'),class_="btn btn-small")}
 
       ${h.submit('reset_cache_%s' % c.repo_info.repo_name,_('Invalidate Repository Cache'),class_="btn btn-default btn-sm")}
 
      <div class="field" style="border:none;color:#888">
 
      <ul>
 
          <li>${_('Manually invalidate cache for this repository. On first access, the repository will be cached again.')}
 
          </li>
 
      </ul>
 
      </div>
 
      <div class="field" style="border:none;">
 
        ${_('List of Cached Values')}
 
           <table>
 
           <tr>
 
            <th>${_('Prefix')}</th>
 
            <th>${_('Key')}</th>
kallithea/templates/admin/repos/repo_edit_fields.html
Show inline comments
 
@@ -46,23 +46,23 @@
 
             </div>
 

	
 
             <div class="field">
 
                <div class="label">
 
                    <label for="new_field_desc">${_('New field description')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('new_field_desc', class_='small', placeholder=_('Enter description of a field'))}
 
                </div>
 
             </div>
 

	
 
            <div class="buttons">
 
              ${h.submit('save',_('Add'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Add'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
%else:
 
  <div style="font-size: 20px">
 
    ${_('Extra fields are disabled.')}
 
  </div>
 
%endif
kallithea/templates/admin/repos/repo_edit_permissions.html
Show inline comments
 
@@ -89,26 +89,26 @@ ${h.form(url('edit_repo_perms_update', r
 
                ## ADD HERE DYNAMICALLY NEW INPUTS FROM THE '_tmpl'
 
                <tr class="new_members last_new_member" id="add_perm_input"></tr>
 
                <tr>
 
                    <td colspan="6">
 
                        <span id="add_perm" style="cursor: pointer;">
 
                            <i class="icon-plus"></i> ${_('Add new')}
 
                        </span>
 
                    </td>
 
                </tr>
 
            </table>
 
        </div>
 
        <div class="buttons">
 
          ${h.submit('save',_('Save'),class_="btn")}
 
          ${h.reset('reset',_('Reset'),class_="btn")}
 
          ${h.submit('save',_('Save'),class_="btn btn-default")}
 
          ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
        </div>
 
   </div>
 
</div>
 
${h.end_form()}
 

	
 
<script type="text/javascript">
 
    function ajaxActionRevoke(obj_id, obj_type, field_id, obj_name) {
 
        url = "${h.url('edit_repo_perms_revoke',repo_name=c.repo_name)}";
 
        var revoke_msg = _TM['Confirm to revoke permission for {0}: {1} ?'].format(obj_type.replace('_', ' '), obj_name);
 
        if (confirm(revoke_msg)){
 
            ajaxActionRevokePermission(url, obj_id, obj_type, field_id);
 
        }
kallithea/templates/admin/repos/repo_edit_remote.html
Show inline comments
 
%if c.repo_info.clone_uri:
 
<div style="font-size: 20px; padding: 0px 0px 10px 0px">
 
   ${_('Remote repository URL')}: <a href="${c.repo_info.clone_uri}">${c.repo_info.clone_uri_hidden}</a></li>
 
</div>
 
${h.form(url('edit_repo_remote_update', repo_name=c.repo_name))}
 
<div class="form">
 
    <div class="fields">
 
        ${h.submit('remote_pull_%s' % c.repo_info.repo_name,
 
            _('Pull Changes from Remote Repository'),
 
            class_="btn btn-small",
 
            class_="btn btn-default btn-sm",
 
            onclick="return confirm('"+_('Confirm to pull changes from remote repository.')+"');")}
 
    </div>
 
</div>
 
${h.end_form()}
 
%else:
 
  <div style="font-size: 20px">
 
    ${_('This repository does not have a remote repository URL.')}
 
  </div>
 
%endif
kallithea/templates/admin/repos/repo_edit_settings.html
Show inline comments
 
@@ -115,26 +115,26 @@ ${h.form(url('update_repo', repo_name=c.
 
                        <label for="${field.field_key_prefixed}">${field.field_label} (${field.field_key}):</label>
 
                    </div>
 
                    <div class="input input-medium">
 
                        ${h.text(field.field_key_prefixed, field.field_value, class_='medium')}
 
                        %if field.field_desc:
 
                          <span class="help-block">${field.field_desc}</span>
 
                        %endif
 
                    </div>
 
                 </div>
 
              %endfor
 
            %endif
 
            <div class="buttons">
 
              ${h.submit('save',_('Save'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Save'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 

	
 
<script>
 
    $(document).ready(function(){
 
        $('#show_more_clone_id').on('click', function(e){
 
            $('#clone_id').show();
 
            e.preventDefault();
 
        });
 

	
kallithea/templates/admin/repos/repo_edit_statistics.html
Show inline comments
 
${h.form(url('edit_repo_statistics_update', repo_name=c.repo_info.repo_name))}
 
<div class="form">
 
    <div class="fields">
 
       <div class="field" style="border:none;color:#888">
 
        <ul>
 
            <li>${_('Processed commits')}: ${c.stats_revision}/${c.repo_last_rev}</li>
 
            <li>${_('Processed progress')}: ${c.stats_percentage}%</li>
 
        </ul>
 
       </div>
 
        ${h.submit('reset_stats_%s' % c.repo_info.repo_name,_('Reset Statistics'),class_="btn btn-small",onclick="return confirm('"+_('Confirm to remove current statistics.')+"');")}
 
        ${h.submit('reset_stats_%s' % c.repo_info.repo_name,_('Reset Statistics'),class_="btn btn-default btn-sm",onclick="return confirm('"+_('Confirm to remove current statistics.')+"');")}
 
   </div>
 
</div>
 
${h.end_form()}
kallithea/templates/admin/repos/repos.html
Show inline comments
 
@@ -10,25 +10,25 @@
 
</%def>
 
<%block name="header_menu">
 
    ${self.menu('admin')}
 
</%block>
 
<%def name="main()">
 
<div class="box">
 

	
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
        <ul class="links">
 
         %if h.HasPermissionAny('hg.admin','hg.create.repository')():
 
          <li>
 
            <a href="${h.url('new_repo')}" class="btn btn-small btn-success"><i class="icon-plus"></i> ${_('Add Repository')}</a>
 
            <a href="${h.url('new_repo')}" class="btn btn-success btn-sm"><i class="icon-plus"></i> ${_('Add Repository')}</a>
 
          </li>
 
         %endif
 
        </ul>
 
    </div>
 
    <div class="table">
 
        <table id="datatable_list_wrap"></table>
 
    </div>
 

	
 
</div>
 
<script>
 
  var data = ${c.data|n};
 
  var myDataTable = $("#datatable_list_wrap").DataTable({
kallithea/templates/admin/settings/settings_email.html
Show inline comments
 
@@ -3,17 +3,17 @@ ${h.form(url('admin_settings_email'), me
 

	
 
        <div class="fields">
 
            <div class="field">
 
                <div class="label">
 
                    <label for="test_email">${_('Send test email to')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('test_email',size=30)}
 
                </div>
 
            </div>
 

	
 
            <div class="buttons">
 
            ${h.submit('send',_('Send'),class_="btn")}
 
            ${h.submit('send',_('Send'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
${h.end_form()}
kallithea/templates/admin/settings/settings_global.html
Show inline comments
 
@@ -49,18 +49,18 @@ ${h.form(url('admin_settings_global'), m
 

	
 
            <div class="field">
 
                <div class="label">
 
                    <label for="captcha_private_key">${_('ReCaptcha private key')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('captcha_private_key',size=60)}
 
                    <span class="help-block">${_('Private key for reCaptcha system. Setting this value will enable captcha on registration.')}</span>
 
                </div>
 
            </div>
 

	
 
            <div class="buttons">
 
                ${h.submit('save',_('Save Settings'),class_="btn")}
 
                ${h.reset('reset',_('Reset'),class_="btn")}
 
                ${h.submit('save',_('Save Settings'),class_="btn btn-default")}
 
                ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
           </div>
 
        </div>
 
    </div>
 
${h.end_form()}
kallithea/templates/admin/settings/settings_hooks.html
Show inline comments
 
@@ -41,25 +41,25 @@ ${h.form(url('admin_settings_hooks'), me
 

	
 
      <div class="field">
 
        <div class="input" style="margin-left:-135px;position: absolute;">
 
          <div class="input">
 
             ${h.text('new_hook_ui_key',size=20)}
 
          </div>
 
        </div>
 
        <div class="input" style="margin-left:280px">
 
            ${h.text('new_hook_ui_value',size=60)}
 
        </div>
 
      </div>
 
      <div class="buttons" style="margin-left:280px">
 
         ${h.submit('save',_('Save'),class_="btn")}
 
         ${h.submit('save',_('Save'),class_="btn btn-default")}
 
      </div>
 
    </div>
 
</div>
 
${h.end_form()}
 
% endif
 

	
 
<script type="text/javascript">
 
function delete_hook(hook_id, field_id) {
 
    var sUrl = "${h.url('admin_settings_hooks_delete')}";
 
    var success = function (o) {
 
            $('#' + field_id).remove();
 
        };
kallithea/templates/admin/settings/settings_mapping.html
Show inline comments
 
@@ -23,17 +23,17 @@ ${h.form(url('admin_settings_mapping'), 
 
                        <label for="hooks"> ${_('Install Git hooks')} </label>
 
                    </div>
 
                    <span class="help-block">${_("Verify if Kallithea's Git hooks are installed for each repository. Current hooks will be updated to the latest version.")}</span>
 
                    <div class="checkbox">
 
                        ${h.checkbox('hooks_overwrite', True)}
 
                        <label for="hooks_overwrite"> ${_('Overwrite existing Git hooks')}</label>
 
                    </div>
 
                    <span class="help-block">${_("If installing Git hooks, overwrite any existing hooks, even if they do not seem to come from Kallithea. WARNING: This operation will destroy any custom git hooks you may have deployed by hand!")}</span>
 
                </div>
 
            </div>
 

	
 
            <div class="buttons">
 
            ${h.submit('rescan',_('Rescan Repositories'),class_="btn")}
 
            ${h.submit('rescan',_('Rescan Repositories'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
${h.end_form()}
kallithea/templates/admin/settings/settings_search.html
Show inline comments
 
@@ -9,17 +9,17 @@ ${h.form(url('admin_settings_search'), m
 
                <div class="checkboxes">
 
                    <div class="checkbox">
 
                        ${h.checkbox('full_index',True)}
 
                        <label for="full_index">${_('Build from scratch')}</label>
 

	
 
                    </div>
 
                    <span class="help-block">${_('This option completely reindexeses all of the repositories for proper fulltext search capabilities.')}</span>
 

	
 
                </div>
 
            </div>
 

	
 
            <div class="buttons">
 
            ${h.submit('reindex',_('Reindex'),class_="btn")}
 
            ${h.submit('reindex',_('Reindex'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
${h.end_form()}
kallithea/templates/admin/settings/settings_vcs.html
Show inline comments
 
@@ -45,36 +45,36 @@ ${h.form(url('admin_settings'), method='
 
                    ##<span class="help-block">${_('Requires hg-git library to be installed. Enables cloning of remote Git repositories while converting them to Mercurial.')}</span>
 
                </div>
 
            </div>
 
            %if c.visual.allow_repo_location_change:
 
            <div class="field">
 
                <div class="label">
 
                    <label for="paths_root_path">${_('Location of repositories')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('paths_root_path',size=60,readonly="readonly")}
 
                    <span id="path_unlock" class="tooltip" style="cursor: pointer"
 
                            title="${_('Click to unlock. You must restart Kallithea in order to make this setting take effect.')}">
 
                        <div class="btn btn-small"><i id="path_unlock_icon" class="icon-lock"></i></div>
 
                        <div class="btn btn-default btn-sm"><i id="path_unlock_icon" class="icon-lock"></i></div>
 
                    </span>
 
                    <span class="help-block">${_('Filesystem location where repositories are stored. After changing this value, a restart and rescan of the repository folder are both required.')}</span>
 
                </div>
 
            </div>
 
            %else:
 
            ## form still requires this but we cannot internally change it anyway
 
            ${h.hidden('paths_root_path',size=30,readonly="readonly")}
 
            %endif
 
            <div class="buttons">
 
                ${h.submit('save',_('Save Settings'),class_="btn")}
 
                ${h.reset('reset',_('Reset'),class_="btn")}
 
                ${h.submit('save',_('Save Settings'),class_="btn btn-default")}
 
                ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
           </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 

	
 
    <script type="text/javascript">
 
        $(document).ready(function(){
 
            $('#path_unlock').on('click', function(e){
 
                $('#path_unlock_icon').removeClass('icon-lock');
 
                $('#path_unlock_icon').addClass('icon-lock-open-alt');
 
                $('#paths_root_path').removeAttr('readonly');
 
            });
kallithea/templates/admin/settings/settings_visual.html
Show inline comments
 
@@ -107,19 +107,19 @@ ${h.form(url('admin_settings_visual'), m
 
                            <li>[lang =&gt; lang] <span class="metatag" tag="lang" >lang</span></li>
 
                            <li>[license =&gt; License] <span class="metatag" tag="license"><a href="http://www.opensource.org/licenses/License" >License</a></span></li>
 
                            <li>[requires =&gt; Repo] <span class="metatag" tag="requires" >requires =&gt; <a href="#" >Repo</a></span></li>
 
                            <li>[recommends =&gt; Repo] <span class="metatag" tag="recommends" >recommends =&gt; <a href="#" >Repo</a></span></li>
 
                            <li>[see =&gt; URI] <span class="metatag" tag="see">see =&gt; <a href="#">URI</a> </span></li>
 
                        </ul>
 
                    </div>
 
                    <span class="help-block">${_('Parses meta tags from the repository description field and turns them into colored tags.')}</span>
 
                 </div>
 
             </div>
 

	
 
             <div class="buttons">
 
                 ${h.submit('save',_('Save Settings'),class_="btn")}
 
                 ${h.reset('reset',_('Reset'),class_="btn")}
 
                 ${h.submit('save',_('Save Settings'),class_="btn btn-default")}
 
                 ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
             </div>
 

	
 
        </div>
 
    </div>
 
${h.end_form()}
kallithea/templates/admin/user_groups/user_group_add.html
Show inline comments
 
@@ -45,25 +45,25 @@
 
                </div>
 
             </div>
 
             <div class="field">
 
                <div class="label label-checkbox">
 
                    <label for="users_group_active">${_('Active')}:</label>
 
                </div>
 
                <div class="checkboxes">
 
                    ${h.checkbox('users_group_active',value=True, checked='checked')}
 
                </div>
 
             </div>
 

	
 
            <div class="buttons">
 
              ${h.submit('save',_('Save'),class_="btn")}
 
              ${h.submit('save',_('Save'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
 

	
 
<script>
 
    $(document).ready(function(){
 
        $('#users_group_name').focus();
 
    });
 
</script>
 
</%def>
kallithea/templates/admin/user_groups/user_group_edit_advanced.html
Show inline comments
 
@@ -6,18 +6,18 @@
 
    (_('Members'), len(c.group_members_obj), ''),
 
    (_('Created on'), h.fmt_date(c.user_group.created_on), ''),
 
    (_('Owner'), h.person(c.user_group.owner), ''),
 
    ]
 
%>
 
%for dt, dd, tt in elems:
 
  <dt style="width:150px; text-align: left">${dt}:</dt>
 
  <dd style="margin-left: 160px" title="${tt}">${dd}</dd>
 
%endfor
 
</dl>
 

	
 
${h.form(h.url('delete_users_group', id=c.user_group.users_group_id))}
 
    <button class="btn btn-small btn-danger" type="submit"
 
    <button class="btn btn-danger btn-sm" type="submit"
 
            onclick="return confirm('${_('Confirm to delete this user group: %s') % c.user_group.users_group_name}');">
 
        <i class="icon-minus-circled"></i>
 
        ${_('Delete this user group')}
 
    </button>
 
${h.end_form()}
kallithea/templates/admin/user_groups/user_group_edit_perms.html
Show inline comments
 
@@ -92,26 +92,26 @@ ${h.form(url('edit_user_group_perms_upda
 
                ## ADD HERE DYNAMICALLY NEW INPUTS FROM THE '_tmpl'
 
                <tr class="new_members last_new_member" id="add_perm_input"></tr>
 
                <tr>
 
                    <td colspan="6">
 
                        <span id="add_perm" style="cursor: pointer;">
 
                            <i class="icon-plus"></i> ${_('Add new')}
 
                        </span>
 
                    </td>
 
                </tr>
 
            </table>
 
        </div>
 
        <div class="buttons">
 
          ${h.submit('save',_('Save'),class_="btn")}
 
          ${h.reset('reset',_('Reset'),class_="btn")}
 
          ${h.submit('save',_('Save'),class_="btn btn-default")}
 
          ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
        </div>
 
   </div>
 
</div>
 
${h.end_form()}
 

	
 
<script type="text/javascript">
 
    function ajaxActionRevoke(obj_id, obj_type, field_id, obj_name) {
 
        url = "${h.url('edit_user_group_perms_delete', id=c.user_group.users_group_id)}";
 
        var revoke_msg = _TM['Confirm to revoke permission for {0}: {1} ?'].format(obj_type.replace('_', ' '), obj_name);
 
        if (confirm(revoke_msg)){
 
            ajaxActionRevokePermission(url, obj_id, obj_type, field_id);
 
        }
kallithea/templates/admin/user_groups/user_group_edit_settings.html
Show inline comments
 
@@ -48,20 +48,20 @@ ${h.form(url('update_users_group', id=c.
 
                                            <div style="float:left">
 
                                                 <div class="text" style="padding: 0px 0px 6px;">${_('Available members')}</div>
 
                                                 ${h.select('available_members',[],c.available_members,multiple=True,size=8,style="min-width:210px")}
 
                                            </div>
 
                                        </div>
 
                                    </td>
 
                                </tr>
 
                        </table>
 
                    </div>
 

	
 
                </div>
 
                <div class="buttons">
 
                  ${h.submit('Save',_('Save'),class_="btn")}
 
                  ${h.submit('Save',_('Save'),class_="btn btn-default")}
 
                </div>
 
            </div>
 
    </div>
 
${h.end_form()}
 
<script type="text/javascript">
 
  MultiSelectWidget('users_group_members','available_members','edit_users_group');
 
</script>
kallithea/templates/admin/user_groups/user_groups.html
Show inline comments
 
@@ -13,25 +13,25 @@
 
<%block name="header_menu">
 
    ${self.menu('admin')}
 
</%block>
 

	
 
<%def name="main()">
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
        <ul class="links">
 
        %if h.HasPermissionAny('hg.admin', 'hg.usergroup.create.true')():
 
          <li>
 
            <a href="${h.url('new_users_group')}" class="btn btn-small btn-success"><i class="icon-plus"></i> ${_('Add User Group')}</a>
 
            <a href="${h.url('new_users_group')}" class="btn btn-success btn-sm"><i class="icon-plus"></i> ${_('Add User Group')}</a>
 
          </li>
 
        %endif
 
        </ul>
 
    </div>
 
    <!-- end box / title -->
 
    <div class="table">
 
        <table id="datatable_list_wrap"></table>
 
    </div>
 
</div>
 
<script>
 
    var data = ${c.data|n};
 
    var $dataTable = $("#datatable_list_wrap").DataTable({
kallithea/templates/admin/users/user_add.html
Show inline comments
 
@@ -84,25 +84,25 @@
 
             <div class="field">
 
                <div class="label label-checkbox">
 
                    <label for="active">${_('Active')}:</label>
 
                </div>
 
                <div class="checkboxes">
 
                    ${h.checkbox('active',value=True,checked='checked')}
 
                </div>
 
             </div>
 

	
 
            ${h.hidden('extern_type', c.default_extern_type)}
 
            ${h.hidden('extern_name', c.default_extern_name)}
 
            <div class="buttons">
 
              ${h.submit('save',_('Save'),class_="btn")}
 
              ${h.submit('save',_('Save'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
 

	
 
<script>
 
    $(document).ready(function(){
 
        $('#username').focus();
 
    });
 
</script>
 
</%def>
kallithea/templates/admin/users/user_edit_advanced.html
Show inline comments
 
@@ -8,18 +8,18 @@
 
    (_('Created on'), h.fmt_date(c.user.created_on), ''),
 
    (_('Last Login'), c.user.last_login or '-', ''),
 
    (_('Member of User Groups'), len(c.user.group_member), ', '.join((x.users_group.users_group_name for x in c.user.group_member))),
 
 ]
 
%>
 
%for dt, dd, tt in elems:
 
  <dt style="width:150px; text-align: left">${dt}:</dt>
 
  <dd style="margin-left: 160px" title="${tt}">${dd}</dd>
 
%endfor
 
</dl>
 

	
 
${h.form(h.url('delete_user', id=c.user.user_id))}
 
    <button class="btn btn-small btn-danger" type="submit"
 
    <button class="btn btn-danger btn-sm" type="submit"
 
            onclick="return confirm('${_('Confirm to delete this user: %s') % c.user.username}');">
 
        <i class="icon-minus-circled"></i>
 
        ${_('Delete this user')}
 
    </button>
 
${h.end_form()}
kallithea/templates/admin/users/user_edit_api_keys.html
Show inline comments
 
<div class="apikeys_wrap">
 
  <table class="noborder">
 
    <tr>
 
        <td style="width: 450px"><div class="truncate autoexpand" style="width:120px;font-size:16px;font-family: monospace">${c.user.api_key}</div></td>
 
        <td>
 
            <span class="btn btn-mini btn-success disabled">${_('Built-in')}</span>
 
            <span class="btn btn-success btn-xs disabled">${_('Built-in')}</span>
 
        </td>
 
        <td>${_('Expires')}: ${_('Never')}</td>
 
        <td>
 
            ${h.form(url('edit_user_api_keys_delete', id=c.user.user_id))}
 
                ${h.hidden('del_api_key',c.user.api_key)}
 
                ${h.hidden('del_api_key_builtin',1)}
 
                <button class="btn btn-mini btn-danger" type="submit"
 
                <button class="btn btn-danger btn-xs" type="submit"
 
                        onclick="return confirm('${_('Confirm to reset this API key: %s') % c.user.api_key}');">
 
                    ${_('Reset')}
 
                </button>
 
            ${h.end_form()}
 
        </td>
 
    </tr>
 
    %if c.user_api_keys:
 
        %for api_key in c.user_api_keys:
 
          <tr class="${'expired' if api_key.expired else ''}">
 
            <td style="width: 450px"><div class="truncate autoexpand" style="width:120px;font-size:16px;font-family: monospace">${api_key.api_key}</div></td>
 
            <td>${api_key.description}</td>
 
            <td style="min-width: 80px">
 
@@ -27,25 +27,25 @@
 
                  ${_('Expires')}: ${_('Never')}
 
                 %else:
 
                    %if api_key.expired:
 
                        ${_('Expired')}: ${h.age(h.time_to_datetime(api_key.expires))}
 
                    %else:
 
                        ${_('Expires')}: ${h.age(h.time_to_datetime(api_key.expires))}
 
                    %endif
 
                 %endif
 
            </td>
 
            <td>
 
                ${h.form(url('edit_user_api_keys_delete', id=c.user.user_id))}
 
                    ${h.hidden('del_api_key',api_key.api_key)}
 
                    <button class="btn btn-mini btn-danger" type="submit"
 
                    <button class="btn btn-danger btn-xs" type="submit"
 
                            onclick="return confirm('${_('Confirm to remove this API key: %s') % api_key.api_key}');">
 
                        <i class="icon-minus-circled"></i>
 
                        ${_('Remove')}
 
                    </button>
 
                ${h.end_form()}
 
            </td>
 
          </tr>
 
        %endfor
 
    %else:
 
    <tr><td><div class="ip">${_('No additional API keys specified')}</div></td></tr>
 
    %endif
 
  </table>
 
@@ -57,26 +57,26 @@
 
        <!-- fields -->
 
        <div class="fields">
 
             <div class="field">
 
                <div class="label">
 
                    <label for="description">${_('New API key')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('description', class_='medium', placeholder=_('Description'))}
 
                    ${h.select('lifetime', '', c.lifetime_options)}
 
                </div>
 
             </div>
 
            <div class="buttons">
 
              ${h.submit('save',_('Add'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Add'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
 

	
 
<script>
 
    $(document).ready(function(){
 
        $("#lifetime").select2({
 
            'dropdownAutoWidth': true
 
        });
 
    });
kallithea/templates/admin/users/user_edit_emails.html
Show inline comments
 
<div class="emails_wrap">
 
  <table class="noborder">
 
    <tr>
 
    %if c.visual.use_gravatar:
 
    <td>${h.gravatar_div(c.user.email, size=16)}</td>
 
    %endif
 
    <td><div class="email">${c.user.email}</div></td>
 
    <td>
 
        <span class="btn btn-mini btn-success disabled">${_('Primary')}</span>
 
        <span class="btn btn-success btn-xs disabled">${_('Primary')}</span>
 
    </td>
 
    </tr>
 
    %if c.user_email_map:
 
        %for em in c.user_email_map:
 
          <tr>
 
            %if c.visual.use_gravatar:
 
            <td>${h.gravatar_div(c.user.email, size=16)}</td>
 
            %endif
 
            <td><div class="email">${em.email}</div></td>
 
            <td>
 
                ${h.form(url('edit_user_emails_delete', id=c.user.user_id))}
 
                    ${h.hidden('del_email_id',em.email_id)}
 
@@ -37,19 +37,19 @@
 
    <div class="form">
 
        <!-- fields -->
 
        <div class="fields">
 
             <div class="field">
 
                <div class="label">
 
                    <label for="new_email">${_('New email address')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('new_email', class_='medium')}
 
                </div>
 
             </div>
 
            <div class="buttons">
 
              ${h.submit('save',_('Add'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Add'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
kallithea/templates/admin/users/user_edit_ips.html
Show inline comments
 
@@ -37,19 +37,19 @@
 
    <div class="form">
 
        <!-- fields -->
 
        <div class="fields">
 
             <div class="field">
 
                <div class="label">
 
                    <label for="new_ip">${_('New IP address')}:</label>
 
                </div>
 
                <div class="input">
 
                    ${h.text('new_ip', class_='medium')}
 
                </div>
 
             </div>
 
            <div class="buttons">
 
              ${h.submit('save',_('Add'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Add'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
kallithea/templates/admin/users/user_edit_profile.html
Show inline comments
 
@@ -101,18 +101,18 @@ ${h.form(url('update_user', id=c.user.us
 
             </div>
 

	
 
             <div class="field">
 
                <div class="label label-checkbox">
 
                    <label for="admin">${_('Admin')}:</label>
 
                </div>
 
                <div class="checkboxes">
 
                    ${h.checkbox('admin',value=True, readonly=c.readonly('admin'))}
 
                </div>
 
             </div>
 

	
 
            <div class="buttons">
 
              ${h.submit('save',_('Save'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Save'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
</div>
 
${h.end_form()}
kallithea/templates/admin/users/users.html
Show inline comments
 
@@ -11,25 +11,25 @@
 

	
 
<%block name="header_menu">
 
    ${self.menu('admin')}
 
</%block>
 

	
 
<%def name="main()">
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
        <ul class="links">
 
          <li>
 
            <a href="${h.url('new_user')}" class="btn btn-small btn-success"><i class="icon-plus"></i> ${_('Add User')}</a>
 
            <a href="${h.url('new_user')}" class="btn btn-success btn-sm"><i class="icon-plus"></i> ${_('Add User')}</a>
 
          </li>
 
        </ul>
 
    </div>
 
    <!-- end box / title -->
 
    <div class="table">
 
        <table id="datatable_list_wrap"></table>
 
    </div>
 
</div>
 

	
 
<script>
 
    var data = ${c.data|n};
 
    var $dataTable = $("#datatable_list_wrap").DataTable({
kallithea/templates/base/base.html
Show inline comments
 
@@ -400,25 +400,25 @@
 
                            ${h.password('password',class_='focus')}
 
                        </div>
 

	
 
                    </div>
 
                    <div class="buttons">
 
                        <div class="password_forgoten">${h.link_to(_('Forgot password ?'),h.url('reset_password'))}</div>
 
                        <div class="register">
 
                        %if h.HasPermissionAny('hg.admin', 'hg.register.auto_activate', 'hg.register.manual_activate')():
 
                         ${h.link_to(_("Don't have an account ?"),h.url('register'))}
 
                        %endif
 
                        </div>
 
                        <div class="submit">
 
                            ${h.submit('sign_in',_('Log In'),class_="btn btn-mini")}
 
                            ${h.submit('sign_in',_('Log In'),class_="btn btn-default btn-xs")}
 
                        </div>
 
                    </div>
 
                </div>
 
            </div>
 
            ${h.end_form()}
 
          %else:
 
            <div class="links_left">
 
                ${h.gravatar_div(c.authuser.email, size=48, div_class="big_gravatar")}
 
                <div class="full_name">${c.authuser.full_name_or_username}</div>
 
                <div class="email">${c.authuser.email}</div>
 
            </div>
 
            <div class="links_right">
kallithea/templates/base/default_perms_box.html
Show inline comments
 
@@ -52,26 +52,26 @@ ${h.form(form_url)}
 
                    <label for="fork_repo_perm">${_('Fork repositories')}:</label>
 
                </div>
 
                <div class="checkboxes">
 
                    ${h.checkbox('fork_repo_perm',value=True)}
 
                    <span class="help-block">
 
                        ${h.literal(_('Select this option to allow repository forking for this user'))}
 
                    </span>
 
                </div>
 
             </div>
 

	
 
            </div>
 
            <div class="buttons">
 
              ${h.submit('save',_('Save'),class_="btn")}
 
              ${h.reset('reset',_('Reset'),class_="btn")}
 
              ${h.submit('save',_('Save'),class_="btn btn-default")}
 
              ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
${h.end_form()}
 

	
 
## JS
 
<script>
 
$(document).ready(function(e){
 
    var show_custom_perms = function(inherit_default){
 
        if(inherit_default){
 
            $('#inherit_overlay').hide();
 
        }else{
kallithea/templates/changelog/changelog.html
Show inline comments
 
@@ -30,48 +30,48 @@ ${self.repo_context_bar('changelog', c.f
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
    </div>
 
    <div class="table">
 
        % if c.pagination:
 
            <div>
 
                <div style="overflow:auto; ${'display:none' if c.changelog_for_path else ''}">
 
                    <div class="container_header">
 
                        <div style="float:left; margin-left:20px;">
 
                          ${h.form(h.url.current(),method='get',style="display:inline")}
 
                            ${h.submit('set',_('Show'),class_="btn btn-small")}
 
                            ${h.submit('set',_('Show'),class_="btn btn-default btn-sm")}
 
                            ${h.text('size',size=3,value=c.size)}
 
                            ${_('revisions')}
 
                            %if c.branch_name:
 
                            ${h.hidden('branch', c.branch_name)}
 
                            %endif
 
                          ${h.end_form()}
 
                          <a href="#" class="btn btn-small" id="rev_range_clear" style="display:none">${_('Clear selection')}</a>
 
                          <a href="#" class="btn btn-default btn-sm" id="rev_range_clear" style="display:none">${_('Clear selection')}</a>
 
                        </div>
 
                        <div style="float: right; margin: 0px 0px 0px 4px">
 
                            <a href="#" class="btn btn-small" id="rev_range_container" style="display:none"></a>
 
                            <a href="#" class="btn btn-default btn-sm" id="rev_range_container" style="display:none"></a>
 
                            %if c.revision:
 
                                <a class="btn btn-small" href="${h.url('changelog_home', repo_name=c.repo_name)}">
 
                                <a class="btn btn-default btn-sm" href="${h.url('changelog_home', repo_name=c.repo_name)}">
 
                                    ${_('Go to tip of repository')}
 
                                </a>
 
                            %endif
 
                            %if c.db_repo.fork:
 
                                <a id="compare_fork"
 
                                   title="${_('Compare fork with %s' % c.db_repo.fork.repo_name)}"
 
                                   href="${h.url('compare_url',repo_name=c.db_repo.fork.repo_name,org_ref_type=c.db_repo.landing_rev[0],org_ref_name=c.db_repo.landing_rev[1],other_repo=c.repo_name,other_ref_type='branch' if request.GET.get('branch') else c.db_repo.landing_rev[0],other_ref_name=request.GET.get('branch') or c.db_repo.landing_rev[1], merge=1)}"
 
                                   class="btn btn-small"><i class="icon-git-compare"></i> ${_('Compare fork with parent repository (%s)' % c.db_repo.fork.repo_name)}</a>
 
                                   class="btn btn-default btn-sm"><i class="icon-git-compare"></i> ${_('Compare fork with parent repository (%s)' % c.db_repo.fork.repo_name)}</a>
 
                            %endif
 
                            ## text and href of open_new_pr is controlled from javascript
 
                            <a id="open_new_pr" class="btn btn-small"></a>
 
                            <a id="open_new_pr" class="btn btn-default btn-sm"></a>
 
                            ${_("Branch filter:")} ${h.select('branch_filter',c.branch_name,c.branch_filters)}
 
                        </div>
 
                    </div>
 
                </div>
 

	
 
                <div id="changelog" style="clear:both">
 

	
 
                <div id="graph_nodes">
 
                    <canvas id="graph_canvas" style="width:0"></canvas>
 
                </div>
 
                <div id="graph_content" style="${'margin: 0px' if c.changelog_for_path else ''}">
 

	
kallithea/templates/changelog/changelog_summary_data.html
Show inline comments
 
@@ -75,25 +75,25 @@
 

	
 
</table>
 

	
 
<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 Kallithea')}</h4>
 
<div style="margin: 20px 30px;">
 
  <div id="add_node_id" class="add_node">
 
      <a class="btn btn-mini" href="${h.url('files_add_home',repo_name=c.repo_name,revision=0,f_path='', anchor='edit')}">${_('Add New File')}</a>
 
      <a class="btn btn-default btn-xs" href="${h.url('files_add_home',repo_name=c.repo_name,revision=0,f_path='', anchor='edit')}">${_('Add New File')}</a>
 
  </div>
 
</div>
 
%endif
 

	
 

	
 
<h4>${_('Push new repository')}</h4>
 
<pre>
 
    ${c.db_repo_scm_instance.alias} clone ${c.clone_repo_url}
 
    ${c.db_repo_scm_instance.alias} add README # add first file
 
    ${c.db_repo_scm_instance.alias} commit -m "Initial" # commit with message
 
    ${c.db_repo_scm_instance.alias} push ${'origin master' if h.is_git(c.db_repo_scm_instance) else ''} # push changes back
 
</pre>
kallithea/templates/changeset/changeset_file_comment.html
Show inline comments
 
@@ -17,25 +17,25 @@
 
              ${h.age(co.modified_at)}
 
              %if co.pull_request:
 
                ${_('on pull request')}
 
                <a href="${co.pull_request.url()}">"${co.pull_request.title or _("No title")}"</a>
 
              %else:
 
                ${_('on this changeset')}
 
              %endif
 
              <a class="permalink" href="${co.url()}">&para;</a>
 
          </span>
 

	
 
          %if co.author_id == c.authuser.user_id or h.HasRepoPermissionAny('repository.admin')(c.repo_name):
 
            %if co.deletable():
 
              <div onClick="confirm('${_("Delete comment?")}') && deleteComment(${co.comment_id})" class="buttons delete-comment btn btn-mini" style="margin:0 5px">${_('Delete')}</div>
 
              <div onClick="confirm('${_("Delete comment?")}') && deleteComment(${co.comment_id})" class="buttons delete-comment btn btn-default btn-xs" style="margin:0 5px">${_('Delete')}</div>
 
            %endif
 
          %endif
 
      </div>
 
      <div class="text">
 
        %if co.status_change:
 
           <div class="automatic-comment">
 
             <p>
 
               <span title="${_('Changeset status')}" class="changeset-status-lbl">${_("Status change")}: ${co.status_change[0].status_lbl}</span>
 
               <span class="changeset-status-ico"><i class="icon-circle changeset-status-${co.status_change[0].status}"></i></span>
 
             </p>
 
           </div>
 
        %endif
 
@@ -90,37 +90,37 @@
 
                  </label>
 
                  <label>
 
                    <input id="save_delete" type="checkbox" name="save_delete" value="delete">
 
                    ${_("Delete")}
 
                  </label>
 
                </div>
 
                %endif
 
        </div>
 

	
 
      </div>
 
      <div class="comment-button">
 
        <div class="submitting-overlay">${_('Submitting ...')}</div>
 
        ${h.submit('save', _('Comment'), class_='btn btn-small save-inline-form')}
 
        ${h.reset('hide-inline-form', _('Cancel'), class_='btn btn-small hide-inline-form')}
 
        ${h.submit('save', _('Comment'), class_='btn btn-default btn-sm save-inline-form')}
 
        ${h.reset('hide-inline-form', _('Cancel'), class_='btn btn-default btn-sm hide-inline-form')}
 
      </div>
 
    ${h.end_form()}
 
  %else:
 
      ${h.form('')}
 
      <div class="clearfix">
 
          <div class="comment-help">
 
            ${_('You need to be logged in to comment.')} <a href="${h.url('login_home', came_from=request.path_qs)}">${_('Login now')}</a>
 
          </div>
 
      </div>
 
      <div class="comment-button">
 
      ${h.reset('hide-inline-form', _('Hide'), class_='btn btn-small hide-inline-form')}
 
      ${h.reset('hide-inline-form', _('Hide'), class_='btn btn-default btn-sm hide-inline-form')}
 
      </div>
 
      ${h.end_form()}
 
  %endif
 
  </div>
 
</div>
 
</%def>
 

	
 

	
 
## show comment count as "x comments (y inline, z general)"
 
<%def name="comment_count(inline_cnt, general_cnt)">
 
    ${'%s (%s, %s)' % (
 
        ungettext("%d comment", "%d comments", inline_cnt + general_cnt) % (inline_cnt + general_cnt),
kallithea/templates/changeset/changeset_range.html
Show inline comments
 
@@ -21,25 +21,25 @@ ${self.repo_context_bar('changelog')}
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
    </div>
 
    <div class="table">
 
        <div id="body" class="diffblock">
 
            <div class="code-header">
 
                <div>
 
                    ${h.show_id(c.cs_ranges[0])}
 
                    <i class="icon-right"></i>
 
                    ${h.show_id(c.cs_ranges[-1])}
 
                    <a style="font-weight: bold" href="${h.url('compare_url',repo_name=c.repo_name,org_ref_type='rev',org_ref_name=getattr(c.cs_ranges[0].parents[0] if c.cs_ranges[0].parents else h.EmptyChangeset(),'raw_id'),other_ref_type='rev',other_ref_name=c.cs_ranges[-1].raw_id)}" class="btn btn-small"><i class="icon-git-compare"></i> Compare Revisions</a>
 
                    <a style="font-weight: bold" href="${h.url('compare_url',repo_name=c.repo_name,org_ref_type='rev',org_ref_name=getattr(c.cs_ranges[0].parents[0] if c.cs_ranges[0].parents else h.EmptyChangeset(),'raw_id'),other_ref_type='rev',other_ref_name=c.cs_ranges[-1].raw_id)}" class="btn btn-default btn-sm"><i class="icon-git-compare"></i> Compare Revisions</a>
 
                </div>
 
            </div>
 
        </div>
 
        <div id="changeset_compare_view_content">
 
            <div class="container">
 
            <table class="compare_view_commits noborder">
 
            %for cnt,cs in enumerate(c.cs_ranges):
 
                <tr>
 
                %if c.visual.use_gravatar:
 
                <td>${h.gravatar_div(h.email_or_none(cs.author), size=14)}</td>
 
                %endif
 
                <td>${h.link_to('r%s:%s' % (cs.revision,h.short_id(cs.raw_id)),h.url('changeset_home',repo_name=c.cs_repo.repo_name,revision=cs.raw_id))}</td>
kallithea/templates/compare/compare_diff.html
Show inline comments
 
@@ -27,27 +27,27 @@ ${self.repo_context_bar('changelog')}
 
    <div class="table">
 
        <div id="body" class="diffblock">
 
            <div class="compare-revision-selector">
 
                ## divs are "inline-block" and cannot have whitespace between them.
 
                <div>
 
                    ${h.hidden('compare_org')}
 
                </div><div>
 
                    <i class="icon-right"></i>
 
                </div><div>
 
                    ${h.hidden('compare_other')}
 
                </div><div>
 
                    %if not c.compare_home:
 
                        <a class="btn btn-small" href="${c.swap_url}"><i class="icon-arrows-cw"></i> ${_('Swap')}</a>
 
                        <a class="btn btn-default btn-sm" href="${c.swap_url}"><i class="icon-arrows-cw"></i> ${_('Swap')}</a>
 
                    %endif
 
                    <div id="compare_revs" class="btn btn-small"><i class="icon-git-compare"></i> ${_('Compare Revisions')}</div>
 
                    <div id="compare_revs" class="btn btn-default btn-sm"><i class="icon-git-compare"></i> ${_('Compare Revisions')}</div>
 
                </div>
 
            </div>
 
        </div>
 

	
 
    %if c.compare_home:
 
        <div id="changeset_compare_view_content">
 
         <div style="color:#999;font-size: 18px">${_('Compare revisions, branches, bookmarks, or tags.')}</div>
 
        </div>
 
    %else:
 
        <div id="changeset_compare_view_content">
 
                ##CS
 
                <div style="font-size:1.1em;font-weight: bold;clear:both;padding-top:10px">${ungettext('Showing %s commit','Showing %s commits', len(c.cs_ranges)) % len(c.cs_ranges)}</div>
kallithea/templates/data_table/_dt_elements.html
Show inline comments
 
@@ -127,29 +127,29 @@
 
      ${h.form(h.url('delete_repo', repo_name=repo_name))}
 
        <i class="icon-minus-circled" 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+"');")}
 
      ${h.end_form()}
 
    </div>
 
  </div>
 
</%def>
 

	
 
<%def name="repo_state(repo_state)">
 
  <div>
 
    %if repo_state == u'repo_state_pending':
 
        <div class="btn btn-mini btn-info disabled">${_('Creating')}</div>
 
        <div class="btn btn-default btn-xs btn-info disabled">${_('Creating')}</div>
 
    %elif repo_state == u'repo_state_created':
 
        <div class="btn btn-mini btn-success disabled">${_('Created')}</div>
 
        <div class="btn btn-success btn-xs disabled">${_('Created')}</div>
 
    %else:
 
        <div class="btn btn-mini btn-danger disabled" title="${repo_state}">invalid</div>
 
        <div class="btn btn-danger btn-xs disabled" title="${repo_state}">invalid</div>
 
    %endif
 
  </div>
 
</%def>
 

	
 
<%def name="user_actions(user_id, username)">
 
 <div style="float:left" class="grid_edit">
 
   <a href="${h.url('edit_user',id=user_id)}" title="${_('Edit')}">
 
     <i class="icon-pencil"></i> ${h.submit('edit_%s' % username,_('Edit'),class_="action_button")}
 
   </a>
 
 </div>
 
 <div style="float:left" class="grid_delete">
 
  ${h.form(h.url('delete_user', id=user_id))}
kallithea/templates/files/files_add.html
Show inline comments
 
@@ -32,46 +32,46 @@ ${self.repo_context_bar('files')}
 
              <span><a href="#">${_('Branch')}: ${c.cs.branch}</a></span>
 
            </li>
 
        </ul>
 
    </div>
 
    <div class="table" id="edit">
 
        <div id="files_data">
 
          ${h.form(h.url.current(),method='post',id='eform',enctype="multipart/form-data", class_="form-horizontal")}
 
          <h3 class="files_location">
 
            ${_('Location')}: ${h.files_breadcrumbs(c.repo_name,c.cs.raw_id,c.f_path)} /
 
              <span id="filename_container" class="file reviewer_ac">
 
                  <input class="input-small" type="text" value="" size="30" name="filename" id="filename" placeholder="${_('Enter filename...')}">
 
                  <input type="hidden" value="${c.f_path}" size="30" name="location" id="location">
 
                  ${_('or')} <div class="btn btn-small" id="upload_file_enable">${_('Upload File')}</div>
 
                  ${_('or')} <div class="btn btn-default btn-sm" id="upload_file_enable">${_('Upload File')}</div>
 
              </span>
 
              <span id="upload_file_container" class="reviewer_ac" style="display:none">
 
                  <input type="file" size="20" name="upload_file" id="upload_file">
 
                  ${_('or')} <div class="btn btn-small" id="file_enable">${_('Create New File')}</div>
 
                  ${_('or')} <div class="btn btn-default btn-sm" id="file_enable">${_('Create New File')}</div>
 
              </span>
 
          </h3>
 
            <div id="body" class="codeblock">
 
            <div class="code-header" id="mimetype_header">
 
                <label class="commit" for="mimetype">${_('New file type')}</label>
 
                <select id="mimetype" name="mimetype"/>
 
            </div>
 
                <div id="editor_container">
 
                    <pre id="editor_pre"></pre>
 
                    <textarea id="editor" name="content" style="display:none"></textarea>
 
                </div>
 
                <div style="padding: 10px;color:#666666">${_('Commit Message')}</div>
 
                <textarea id="commit" name="message" style="height: 100px;width: 99%;margin-left:4px" placeholder="${c.default_message}"></textarea>
 
            </div>
 
            <div style="text-align: left;padding-top: 5px">
 
            ${h.submit('commit',_('Commit Changes'),class_="btn btn-small btn-success")}
 
            ${h.reset('reset',_('Reset'),class_="btn btn-small")}
 
            ${h.submit('commit',_('Commit Changes'),class_="btn btn-success btn-sm")}
 
            ${h.reset('reset',_('Reset'),class_="btn btn-default btn-sm")}
 
            </div>
 
            ${h.end_form()}
 
            <script type="text/javascript">
 
                $(document).ready(function(){
 
                    var reset_url = "${h.url('files_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path)}";
 
                    var myCodeMirror = initCodeMirror('editor', "${request.script_name}", reset_url);
 

	
 
                    //inject new modes, based on codeMirrors modeInfo object
 
                    var $mimetype_select = $('#mimetype');
 
                    $mimetype_select.each(function(){
 
                        var modes_select = this;
 
                        var index = 1;
kallithea/templates/files/files_browser.html
Show inline comments
 
@@ -21,36 +21,36 @@
 
            c = "icon-doc"
 
        elif node.is_submodule():
 
            c = "icon-file-submodule"
 
    %>
 
    <%return h.literal('<i class="%s"></i><span>%s</span>' % (c, h.escape(node.name)))%>
 
</%def>
 
<div id="body" class="browserblock">
 
    <div class="browser-header">
 
        <div class="browser-nav">
 
            ${h.form(h.url.current())}
 
            <div class="info_box">
 
              <div class="info_box_elem rev">${_('Revision')}</div>
 
              <div class="info_box_elem"><a class="btn btn-mini ypjax-link" href="${c.url_prev}" title="${_('Previous revision')}"><i class="icon-left-open"></i></a></div>
 
              <div class="info_box_elem"><a class="btn btn-default btn-xs ypjax-link" href="${c.url_prev}" title="${_('Previous revision')}"><i class="icon-left-open"></i></a></div>
 
              <div class="info_box_elem">${h.text('at_rev',value=c.changeset.revision,size=5)}</div>
 
              <div class="info_box_elem"><a class="btn btn-mini ypjax-link" href="${c.url_next}" title="${_('Next revision')}"><i class="icon-right-open"></i></a></div>
 
              <div class="info_box_elem"><a class="btn btn-default btn-xs ypjax-link" href="${c.url_next}" title="${_('Next revision')}"><i class="icon-right-open"></i></a></div>
 
            </div>
 
            ${h.end_form()}
 
        </div>
 
        <div class="browser-branch">
 
           ${h.checkbox('stay_at_branch',c.changeset.branch,c.changeset.branch==c.branch)}
 
           <label>${_('Follow current branch')}</label>
 
        </div>
 
        <div id="search_activate_id" class="search_activate">
 
           <a class="btn btn-mini" id="filter_activate" href="#">${_('Search File List')}</a>
 
           <a class="btn btn-default btn-xs" id="filter_activate" href="#">${_('Search File List')}</a>
 
        </div>
 
        <div class="browser-search">
 
            <div>
 
                <div id="node_filter_box_loading" style="display:none">${_('Loading file list...')}</div>
 
                <div id="node_filter_box" style="display:none">
 
                ${h.files_breadcrumbs(c.repo_name,c.changeset.raw_id,c.file.path)}/<input class="init" type="text" value="type to search..." name="filter" size="25" id="node_filter">
 
                </div>
 
            </div>
 
        </div>
 
    </div>
 

	
 
    <div class="browser-body">
kallithea/templates/files/files_delete.html
Show inline comments
 
@@ -31,20 +31,20 @@ ${self.repo_context_bar('files')}
 
                ${_('Delete file')}: ${h.files_breadcrumbs(c.repo_name,c.cs.raw_id,c.f_path)}
 
            </h3>
 

	
 
            <div id="body" class="codeblock">
 
                <div id="editor_container">
 
                    <pre id="editor_pre"></pre>
 
                    <textarea id="editor" name="content" style="display:none"></textarea>
 
                </div>
 
                <div style="padding: 10px;color:#666666">${_('Commit Message')}</div>
 
                <textarea id="commit" name="message" style="height: 100px;width: 99%;margin-left:4px" placeholder="${c.default_message}"></textarea>
 
            </div>
 
            <div style="text-align: left;padding-top: 5px">
 
                ${h.submit('commit',_('Commit Changes'),class_="btn btn-small btn-success")}
 
                ${h.reset('reset',_('Reset'),class_="btn btn-small")}
 
                ${h.submit('commit',_('Commit Changes'),class_="btn btn-success btn-sm")}
 
                ${h.reset('reset',_('Reset'),class_="btn btn-default btn-sm")}
 
            </div>
 
            ${h.end_form()}
 
        </div>
 
    </div>
 
</div>
 
</%def>
kallithea/templates/files/files_edit.html
Show inline comments
 
@@ -36,45 +36,45 @@ ${self.repo_context_bar('files')}
 
    <div class="table" id="edit">
 
        <div id="files_data">
 
            <h3 class="files_location">${_('Location')}: ${h.files_breadcrumbs(c.repo_name,c.cs.raw_id,c.file.path)}</h3>
 
            ${h.form(h.url.current(),method='post',id='eform')}
 
            <div id="body" class="codeblock">
 
            <div class="code-header">
 
                <div class="stats">
 
                    <div class="left"><i class="icon-doc-inv"></i></div>
 
                    <div class="left item">${h.link_to(h.show_id(c.file.changeset),h.url('changeset_home',repo_name=c.repo_name,revision=c.file.changeset.raw_id))}</div>
 
                    <div class="left item">${h.format_byte_size(c.file.size,binary=True)}</div>
 
                    <div class="left item last">${c.file.mimetype}</div>
 
                    <div class="buttons">
 
                      ${h.link_to(_('Show Annotation'),h.url('files_annotate_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path),class_="btn btn-mini")}
 
                      ${h.link_to(_('Show as Raw'),h.url('files_raw_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path),class_="btn btn-mini")}
 
                      ${h.link_to(_('Download as Raw'),h.url('files_rawfile_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path),class_="btn btn-mini")}
 
                      ${h.link_to(_('Show Annotation'),h.url('files_annotate_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path),class_="btn btn-default btn-xs")}
 
                      ${h.link_to(_('Show as Raw'),h.url('files_raw_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path),class_="btn btn-default btn-xs")}
 
                      ${h.link_to(_('Download as Raw'),h.url('files_rawfile_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path),class_="btn btn-default btn-xs")}
 
                      % if h.HasRepoPermissionAny('repository.write','repository.admin')(c.repo_name):
 
                       % if not c.file.is_binary:
 
                        ${h.link_to(_('Source'),h.url('files_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path),class_="btn btn-mini")}
 
                        ${h.link_to(_('Source'),h.url('files_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.f_path),class_="btn btn-default btn-xs")}
 
                       % endif
 
                      % endif
 
                    </div>
 
                </div>
 
                <label class="commit" for="mimetype">${_('Editing file')}: ${c.file.unicode_path}</label>
 
                <select id="mimetype" name="mimetype"/>
 
            </div>
 
                <pre id="editor_pre"></pre>
 
                <textarea id="editor" name="content" style="display:none">${h.escape(c.file.content)|n}</textarea>
 
                <div style="padding: 10px;color:#666666">${_('Commit Message')}</div>
 
                <textarea id="commit" name="message" style="height: 60px;width: 99%;margin-left:4px" placeholder="${c.default_message}"></textarea>
 
            </div>
 
            <div style="text-align: left;padding-top: 5px">
 
            ${h.submit('commit',_('Commit Changes'),class_="btn btn-small btn-success")}
 
            ${h.reset('reset',_('Reset'),class_="btn btn-small")}
 
            ${h.submit('commit',_('Commit Changes'),class_="btn btn-success btn-sm")}
 
            ${h.reset('reset',_('Reset'),class_="btn btn-default btn-sm")}
 
            </div>
 
            ${h.end_form()}
 
        </div>
 
    </div>
 
</div>
 

	
 
<script type="text/javascript">
 
    $(document).ready(function(){
 
        var reset_url = "${h.url('files_home',repo_name=c.repo_name,revision=c.cs.raw_id,f_path=c.file.path)}";
 
        var myCodeMirror = initCodeMirror('editor', "${request.script_name}", reset_url);
 

	
 
       //inject new modes, based on codeMirrors modeInfo object
kallithea/templates/files/files_source.html
Show inline comments
 
<div id="node_history" style="padding: 0px 0px 10px 0px">
 
    <div>
 
        <div style="float:left">
 
        ${h.form(h.url('files_diff_home',repo_name=c.repo_name,f_path=c.f_path),method='get')}
 
        ${h.hidden('diff2',c.changeset.raw_id)}
 
        ${h.hidden('diff1')}
 
        ${h.submit('diff',_('Diff to Revision'),class_="btn btn-small")}
 
        ${h.submit('show_rev',_('Show at Revision'),class_="btn btn-small")}
 
        ${h.submit('diff',_('Diff to Revision'),class_="btn btn-default btn-sm")}
 
        ${h.submit('show_rev',_('Show at Revision'),class_="btn btn-default btn-sm")}
 
        ${h.hidden('annotate', c.annotate)}
 
        ${h.link_to(_('Show Full History'),h.url('changelog_file_home',repo_name=c.repo_name, revision=c.changeset.raw_id, f_path=c.f_path),class_="btn btn-small")}
 
        ${h.link_to(_('Show Authors'),'#',class_="btn btn-small" ,id="show_authors")}
 
        ${h.link_to(_('Show Full History'),h.url('changelog_file_home',repo_name=c.repo_name, revision=c.changeset.raw_id, f_path=c.f_path),class_="btn btn-default btn-sm")}
 
        ${h.link_to(_('Show Authors'),'#',class_="btn btn-default btn-sm" ,id="show_authors")}
 

	
 
        ${h.end_form()}
 
        </div>
 
        <div id="file_authors" class="file_author" style="clear:both; display: none"></div>
 
    </div>
 
    <div style="clear:both"></div>
 
</div>
 

	
 

	
 
<div id="body" class="codeblock">
 
    <div class="code-header">
 
        <div class="stats">
 
            <div class="left img"><i class="icon-doc-inv"></i></div>
 
            <div class="left item"><pre class="tooltip" title="${h.fmt_date(c.changeset.date)}">${h.link_to(h.show_id(c.changeset),h.url('changeset_home',repo_name=c.repo_name,revision=c.changeset.raw_id))}</pre></div>
 
            <div class="left item"><pre>${h.format_byte_size(c.file.size,binary=True)}</pre></div>
 
            <div class="left item last"><pre>${c.file.mimetype}</pre></div>
 
            <div class="buttons">
 
              %if c.annotate:
 
                ${h.link_to(_('Show Source'),    h.url('files_home',         repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path),class_="btn btn-mini")}
 
                ${h.link_to(_('Show Source'),    h.url('files_home',         repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path),class_="btn btn-default btn-xs")}
 
              %else:
 
                ${h.link_to(_('Show Annotation'),h.url('files_annotate_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path),class_="btn btn-mini")}
 
                ${h.link_to(_('Show Annotation'),h.url('files_annotate_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path),class_="btn btn-default btn-xs")}
 
              %endif
 
              ${h.link_to(_('Show as Raw'),h.url('files_raw_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path),class_="btn btn-mini")}
 
              ${h.link_to(_('Download as Raw'),h.url('files_rawfile_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path),class_="btn btn-mini")}
 
              ${h.link_to(_('Show as Raw'),h.url('files_raw_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path),class_="btn btn-default btn-xs")}
 
              ${h.link_to(_('Download as Raw'),h.url('files_rawfile_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path),class_="btn btn-default btn-xs")}
 
              % if h.HasRepoPermissionAny('repository.write','repository.admin')(c.repo_name):
 
               %if c.on_branch_head and not c.file.is_binary:
 
                ${h.link_to(_('Edit on Branch: %s') % c.changeset.branch, h.url('files_edit_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path, anchor='edit'),class_="btn btn-mini")}
 
                ${h.link_to(_('Delete'), h.url('files_delete_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path, anchor='edit'),class_="btn btn-mini btn-danger")}
 
                ${h.link_to(_('Edit on Branch: %s') % c.changeset.branch, h.url('files_edit_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path, anchor='edit'),class_="btn btn-default btn-xs")}
 
                ${h.link_to(_('Delete'), h.url('files_delete_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path, anchor='edit'),class_="btn btn-danger btn-xs")}
 
               %elif c.on_branch_head and c.file.is_binary:
 
                ${h.link_to(_('Edit'), '#', class_="btn btn-mini disabled tooltip", title=_('Editing binary files not allowed'))}
 
                ${h.link_to(_('Delete'), h.url('files_delete_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path, anchor='edit'),class_="btn btn-mini btn-danger")}
 
                ${h.link_to(_('Edit'), '#', class_="btn btn-default btn-xs disabled tooltip", title=_('Editing binary files not allowed'))}
 
                ${h.link_to(_('Delete'), h.url('files_delete_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.f_path, anchor='edit'),class_="btn btn-danger btn-xs")}
 
               %else:
 
                ${h.link_to(_('Edit'), '#', class_="btn btn-mini disabled tooltip", title=_('Editing files allowed only when on branch head revision'))}
 
                ${h.link_to(_('Delete'), '#', class_="btn btn-mini btn-danger disabled tooltip", title=_('Deleting files allowed only when on branch head revision'))}
 
                ${h.link_to(_('Edit'), '#', class_="btn btn-default btn-xs disabled tooltip", title=_('Editing files allowed only when on branch head revision'))}
 
                ${h.link_to(_('Delete'), '#', class_="btn btn-danger btn-xs disabled tooltip", title=_('Deleting files allowed only when on branch head revision'))}
 
               % endif
 
              % endif
 
            </div>
 
        </div>
 
        <div class="author">
 
            ${h.gravatar_div(h.email_or_none(c.changeset.author), size=16)}
 
            <div title="${c.changeset.author}" class="user">${h.person(c.changeset.author)}</div>
 
        </div>
 
        <div class="commit">${h.urlify_text(c.changeset.message,c.repo_name)}</div>
 
    </div>
 
    <div class="code-body">
 
      %if c.file.is_browser_compatible_image():
kallithea/templates/forks/fork.html
Show inline comments
 
@@ -84,25 +84,25 @@ ${self.repo_context_bar('createfork')}
 
            %if c.can_update:
 
            <div class="field">
 
                <div class="label label-checkbox">
 
                    <label for="private">${_('Update after clone')}:</label>
 
                </div>
 
                <div class="checkboxes">
 
                    ${h.checkbox('update_after_clone',value="True")}
 
                    <span class="help-block">${_('Checkout source after making a clone')}</span>
 
                </div>
 
            </div>
 
            %endif
 
            <div class="buttons">
 
                ${h.submit('',_('Fork this Repository'),class_="btn")}
 
                ${h.submit('',_('Fork this Repository'),class_="btn btn-default")}
 
            </div>
 
        </div>
 
    </div>
 
    ${h.end_form()}
 
</div>
 
<script>
 
    $(document).ready(function(){
 
        $("#repo_group").select2({
 
            'dropdownAutoWidth': true
 
        });
 
        $("#landing_rev").select2({
 
            'minimumResultsForSearch': -1
kallithea/templates/forks/forks_data.html
Show inline comments
 
@@ -7,23 +7,23 @@
 
                ${h.gravatar_div(f.owner.email, size=24)}
 
                <span style="font-size: 20px">
 
                 <b>${f.owner.username}</b> (${f.owner.name} ${f.owner.lastname}) /
 
                  ${h.link_to(f.repo_name,h.url('summary_home',repo_name=f.repo_name))}
 
                </span>
 
                <div style="padding:5px 3px 3px 42px;">${f.description}</div>
 
            </div>
 
            <div style="clear:both;padding-top: 10px"></div>
 
            <div class="follower_date">${_('Forked')} -
 
                <span class="tooltip" title="${h.fmt_date(f.created_on)}"> ${h.age(f.created_on)}</span>
 
                <a title="${_('Compare fork with %s') % c.repo_name}"
 
                   href="${h.url('compare_url',repo_name=c.repo_name, org_ref_type=c.db_repo.landing_rev[0],org_ref_name=c.db_repo.landing_rev[1],other_repo=f.repo_name,other_ref_type=c.db_repo.landing_rev[0],other_ref_name=c.db_repo.landing_rev[1], merge=1)}"
 
                   class="btn btn-small"><i class="icon-git-compare"></i> ${_('Compare Fork')}</a>
 
                   class="btn btn-default btn-sm"><i class="icon-git-compare"></i> ${_('Compare Fork')}</a>
 
            </div>
 
            <div style="border-bottom: 1px solid #DDD;margin:10px 0px 10px 0px"></div>
 
        </div>
 
    % endfor
 
  <div class="pagination-wh pagination-left">
 
  ${c.forks_pager.pager('$link_previous ~2~ $link_next')}
 
  </div>
 
% else:
 
    ${_('There are no forks yet')}
 
% endif
kallithea/templates/index_base.html
Show inline comments
 
@@ -5,37 +5,37 @@
 
            %if c.authuser.username != 'default':
 
              <ul class="links">
 
                <li>
 
                <%
 
                    gr_name = c.group.group_name if c.group else None
 
                    # create repositories with write permission on group is set to true
 
                    create_on_write = h.HasPermissionAny('hg.create.write_on_repogroup.true')()
 
                    group_admin = h.HasRepoGroupPermissionAny('group.admin')(gr_name, 'can write into group index page')
 
                    group_write = h.HasRepoGroupPermissionAny('group.write')(gr_name, 'can write into group index page')
 
                %>
 
                %if h.HasPermissionAny('hg.admin','hg.create.repository')() or (group_admin or (group_write and create_on_write)):
 
                  %if c.group:
 
                        <a href="${h.url('new_repo',parent_group=c.group.group_id)}" class="btn btn-small"><i class="icon-plus"></i> ${_('Add Repository')}</a>
 
                        <a href="${h.url('new_repo',parent_group=c.group.group_id)}" class="btn btn-default btn-sm"><i class="icon-plus"></i> ${_('Add Repository')}</a>
 
                        %if h.HasPermissionAny('hg.admin')() or h.HasRepoGroupPermissionAny('group.admin')(c.group.group_name):
 
                            <a href="${h.url('new_repos_group', parent_group=c.group.group_id)}" class="btn btn-small"><i class="icon-plus"></i> ${_('Add Repository Group')}</a>
 
                            <a href="${h.url('new_repos_group', parent_group=c.group.group_id)}" class="btn btn-default btn-sm"><i class="icon-plus"></i> ${_('Add Repository Group')}</a>
 
                        %endif
 
                  %else:
 
                    <a href="${h.url('new_repo')}" class="btn btn-small"><i class="icon-plus"></i> ${_('Add Repository')}</a>
 
                    <a href="${h.url('new_repo')}" class="btn btn-default btn-sm"><i class="icon-plus"></i> ${_('Add Repository')}</a>
 
                    %if h.HasPermissionAny('hg.admin')():
 
                        <a href="${h.url('new_repos_group')}" class="btn btn-small"><i class="icon-plus"></i> ${_('Add Repository Group')}</a>
 
                        <a href="${h.url('new_repos_group')}" class="btn btn-default btn-sm"><i class="icon-plus"></i> ${_('Add Repository Group')}</a>
 
                    %endif
 
                  %endif
 
                %endif
 
                %if c.group and h.HasRepoGroupPermissionAny('group.admin')(c.group.group_name):
 
                    <a href="${h.url('edit_repo_group',group_name=c.group.group_name)}" title="${_('You have admin right to this group, and can edit it')}" class="btn btn-small"><i class="icon-pencil"></i> ${_('Edit Repository Group')}</a>
 
                    <a href="${h.url('edit_repo_group',group_name=c.group.group_name)}" title="${_('You have admin right to this group, and can edit it')}" class="btn btn-default btn-sm"><i class="icon-pencil"></i> ${_('Edit Repository Group')}</a>
 
                %endif
 
                </li>
 
              </ul>
 
            %endif
 
        </div>
 
        <!-- end box / title -->
 
        <div class="table">
 
           % if c.groups:
 
            <div id='groups_list_wrap'>
 
              <table id="groups_list">
 
                  <thead>
 
                      <tr>
kallithea/templates/journal/journal.html
Show inline comments
 
## -*- coding: utf-8 -*-
 
<%inherit file="/base/base.html"/>
 
<%block name="title">
 
    ${_('Journal')}
 
</%block>
 
<%def name="breadcrumbs()">
 
    <h5>
 
    <form id="filter_form">
 
    <input class="q_filter_box ${'' if c.search_term else 'initial'}" id="j_filter" size="15" type="text" name="filter" value="${c.search_term or _('quick filter...')}"/>
 
    <span class="tooltip" title="${h.journal_filter_help()}">?</span>
 
    <input type='submit' value="${_('Filter')}" class="btn btn-small" style="padding:0px 2px 0px 2px;margin:0px"/>
 
    <input type='submit' value="${_('Filter')}" class="btn btn-default btn-sm" style="padding:0px 2px 0px 2px;margin:0px"/>
 
    ${_('Journal')} - ${ungettext('%s Entry', '%s Entries', c.journal_pager.item_count) % (c.journal_pager.item_count)}
 
    </form>
 
    ${h.end_form()}
 
    </h5>
 
</%def>
 
<%block name="header_menu">
 
    ${self.menu('journal')}
 
</%block>
 
<%block name="head_extra">
 
  <link href="${h.url('journal_atom', api_key=c.authuser.api_key)}" rel="alternate" title="${_('ATOM journal feed')}" type="application/atom+xml" />
 
  <link href="${h.url('journal_rss', api_key=c.authuser.api_key)}" rel="alternate" title="${_('RSS journal feed')}" type="application/rss+xml" />
 
</%block>
kallithea/templates/password_reset.html
Show inline comments
 
@@ -34,25 +34,25 @@
 
                    <div class="label">
 
                        <label for="email">${_('Captcha')}:</label>
 
                    </div>
 
                    <div class="input">
 
                        ${h.hidden('recaptcha_field')}
 
                        <div id="recaptcha"></div>
 
                    </div>
 
                </div>
 
                %endif
 

	
 
                <div class="buttons">
 
                    <div class="nohighlight">
 
                      ${h.submit('send',_('Send Password Reset Email'),class_="btn")}
 
                      ${h.submit('send',_('Send Password Reset Email'),class_="btn btn-default")}
 
                          <div class="activation_msg">${_('A password reset link will be sent to the specified email address if it is registered in the system.')}</div>
 
                    </div>
 
                </div>
 
            </div>
 
        </div>
 
        ${h.end_form()}
 
        %if c.captcha_active:
 
        <script type="text/javascript" src="https://www.google.com/recaptcha/api/js/recaptcha_ajax.js"></script>
 
        %endif
 
        <script type="text/javascript">
 
         $(document).ready(function(){
 
            $('#email').focus();
kallithea/templates/password_reset_confirmation.html
Show inline comments
 
@@ -44,20 +44,20 @@
 
                 </div>
 

	
 
                 <div class="field">
 
                    <div class="label">
 
                        <label for="password_confirm">${_('Confirm New Password')}:</label>
 
                    </div>
 
                    <div class="input">
 
                        ${h.password('password_confirm',class_='focus')}
 
                    </div>
 
                 </div>
 
                <div class="buttons">
 
                    <div class="nohighlight">
 
                      ${h.submit('send',_('Confirm'),class_="btn")}
 
                      ${h.submit('send',_('Confirm'),class_="btn btn-default")}
 
                    </div>
 
                </div>
 
            </div>
 
        </div>
 
        ${h.end_form()}
 
    </div>
 
   </div>
kallithea/templates/pullrequests/pullrequest.html
Show inline comments
 
@@ -76,26 +76,26 @@ ${self.repo_context_bar('showpullrequest
 
                            </div>
 
                            <div style="padding:5px 3px 3px 3px;">
 
                            <b>${_('Revision')}:</b> <span id="other_rev_span">-</span>
 
                            </div>
 
                        </div>
 
                    </div>
 
                    <div style="clear:both"></div>
 
                </div>
 
            </div>
 

	
 
            <div class="field">
 
                <div class="buttons">
 
                    ${h.submit('save',_('Create Pull Request'),class_="btn")}
 
                    ${h.reset('reset',_('Reset'),class_="btn")}
 
                    ${h.submit('save',_('Create Pull Request'),class_="btn btn-default")}
 
                    ${h.reset('reset',_('Reset'),class_="btn btn-default")}
 
               </div>
 
            </div>
 

	
 
        </div>
 

	
 
        <div style="clear:both;padding: 0 0 30px 0;"></div>
 

	
 
        <h4>${_('Changesets')}</h4>
 
        <div style="float:left;padding:0px 30px 30px 30px">
 
           ## overview pulled by ajax
 
           <div style="float:left" id="pull_request_overview"></div>
 
        </div>
kallithea/templates/pullrequests/pullrequest_show.html
Show inline comments
 
@@ -29,25 +29,25 @@ ${self.repo_context_bar('showpullrequest
 
          ${_('Title')}: ${c.pull_request.title}
 
          %if c.pull_request.is_closed():
 
              (${_('Closed')})
 
          %endif
 
      </div>
 
      <div id="pr-summary" class="fields">
 

	
 
        <div class="field pr-not-edit" style="min-height:37px">
 
          <div class="label-summary">
 
            <label>${_('Description')}:</label>
 
            %if editable:
 
            <div style="margin: 5px">
 
              <a class="btn btn-small" onclick="$('.pr-do-edit').show();$('.pr-not-edit').hide()">${_("Edit")}</a>
 
              <a class="btn btn-default btn-sm" onclick="$('.pr-do-edit').show();$('.pr-not-edit').hide()">${_("Edit")}</a>
 
            </div>
 
            %endif
 
          </div>
 
          <div class="input">
 
            <div class="formatted-fixed">${h.urlify_text(c.pull_request.description, c.pull_request.org_repo.repo_name)}</div>
 
          </div>
 
        </div>
 

	
 
        %if editable:
 
        <div class="pr-do-edit" style="display:none">
 
          <div class="field">
 
              <div class="label-summary">
 
@@ -281,27 +281,27 @@ ${self.repo_context_bar('showpullrequest
 
                  gravatar_size="14"
 
                  title="Click to add reviewer to the list, then Save Changes.">${u.full_name}</a>
 
              </li>
 
            %endfor
 
          </ul>
 
        </div>
 
        %endif
 
    </div>
 
    <div class="form" style="clear:both">
 
      <div class="fields">
 
        %if editable:
 
          <div class="buttons">
 
            ${h.submit('pr-form-save',_('Save Changes'),class_="btn btn-small")}
 
            ${h.submit('pr-form-clone',_('Create New Iteration with Changes'),class_="btn btn-small",disabled='disabled')}
 
            ${h.reset('pr-form-reset',_('Cancel Changes'),class_="btn btn-small")}
 
            ${h.submit('pr-form-save',_('Save Changes'),class_="btn btn-default btn-sm")}
 
            ${h.submit('pr-form-clone',_('Create New Iteration with Changes'),class_="btn btn-default btn-sm",disabled='disabled')}
 
            ${h.reset('pr-form-reset',_('Cancel Changes'),class_="btn btn-default btn-sm")}
 
          </div>
 
        %endif
 
      </div>
 
    </div>
 
  ${h.end_form()}
 
</div>
 

	
 
<div class="box">
 
    <div class="title">
 
      <div class="breadcrumbs">${_('Pull Request Content')}</div>
 
    </div>
 
    <div class="table">
kallithea/templates/pullrequests/pullrequest_show_all.html
Show inline comments
 
@@ -20,32 +20,32 @@
 

	
 
<%def name="main()">
 
${self.repo_context_bar('showpullrequest')}
 

	
 
<div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
        <ul class="links">
 
          <li>
 
             %if c.authuser.username != 'default':
 
              <span>
 
                  <a id="open_new_pr" class="btn btn-small btn-success" href="${h.url('pullrequest_home',repo_name=c.repo_name)}"><i class="icon-plus"></i> ${_('Open New Pull Request')}</a>
 
                  <a id="open_new_pr" class="btn btn-success btn-sm" href="${h.url('pullrequest_home',repo_name=c.repo_name)}"><i class="icon-plus"></i> ${_('Open New Pull Request')}</a>
 
              </span>
 
             %endif
 
              <span>
 
                %if c.from_:
 
                    <a class="btn btn-small" href="${h.url('pullrequest_show_all',repo_name=c.repo_name,closed=c.closed)}"><i class="icon-git-compare"></i> ${_('Show Pull Requests to %s') % c.repo_name}</a>
 
                    <a class="btn btn-default btn-sm" href="${h.url('pullrequest_show_all',repo_name=c.repo_name,closed=c.closed)}"><i class="icon-git-compare"></i> ${_('Show Pull Requests to %s') % c.repo_name}</a>
 
                %else:
 
                    <a class="btn btn-small" href="${h.url('pullrequest_show_all',repo_name=c.repo_name,closed=c.closed,from_=1)}"><i class="icon-git-compare"></i> ${_("Show Pull Requests from '%s'") % c.repo_name}</a>
 
                    <a class="btn btn-default btn-sm" href="${h.url('pullrequest_show_all',repo_name=c.repo_name,closed=c.closed,from_=1)}"><i class="icon-git-compare"></i> ${_("Show Pull Requests from '%s'") % c.repo_name}</a>
 
                %endif
 
              </span>
 
          </li>
 
        </ul>
 
    </div>
 

	
 
    <div class="normal-indent">
 
        <div>
 
        %if c.closed:
 
            ${h.link_to(_('Hide closed pull requests (only show open pull requests)'), h.url('pullrequest_show_all',repo_name=c.repo_name,from_=c.from_))}
 
        %else:
 
            ${h.link_to(_('Show closed pull requests (in addition to open pull requests)'), h.url('pullrequest_show_all',repo_name=c.repo_name,from_=c.from_,closed=1))}
kallithea/templates/register.html
Show inline comments
 
@@ -78,25 +78,25 @@
 
                    <div class="label">
 
                        <label for="email">${_('Captcha')}:</label>
 
                    </div>
 
                    <div class="input">
 
                        ${h.hidden('recaptcha_field')}
 
                        <div id="recaptcha"></div>
 
                    </div>
 
                </div>
 
                %endif
 

	
 
                <div class="buttons">
 
                    <div class="nohighlight">
 
                      ${h.submit('sign_up',_('Sign Up'),class_="btn")}
 
                      ${h.submit('sign_up',_('Sign Up'),class_="btn btn-default")}
 
                      %if c.auto_active:
 
                          <div class="activation_msg">${_('Registered accounts are ready to use and need no further action.')}</div>
 
                      %else:
 
                          <div class="activation_msg">${_('Please wait for an administrator to activate your account.')}</div>
 
                      %endif
 
                    </div>
 
                </div>
 
            </div>
 
        </div>
 
        ${h.end_form()}
 
        %if c.captcha_active:
 
        <script type="text/javascript" src="https://www.google.com/recaptcha/api/js/recaptcha_ajax.js"></script>
kallithea/templates/summary/statistics.html
Show inline comments
 
@@ -24,25 +24,25 @@ ${self.repo_context_bar('summary')}
 
    %>
 
    <div class="box">
 
    <!-- box / title -->
 
    <div class="title">
 
        ${self.breadcrumbs()}
 
    </div>
 

	
 
    <div class="graph">
 
         <div style="padding:0 10px 10px 17px;">
 
         %if c.no_data:
 
           ${c.no_data_msg}
 
           %if h.HasPermissionAny('hg.admin')('enable stats on from summary'):
 
                ${h.link_to(_('Enable'),h.url('edit_repo',repo_name=c.repo_name),class_="btn btn-mini")}
 
                ${h.link_to(_('Enable'),h.url('edit_repo',repo_name=c.repo_name),class_="btn btn-default btn-xs")}
 
           %endif
 
        %else:
 
            ${_('Stats gathered: ')} ${c.stats_percentage}%
 
        %endif
 
        </div>
 
        <div id="commit_history" style="width:450px;height:300px;float:left"></div>
 

	
 
        <div id="legend_data" style="float: left;">
 
            <div id="legend_container"></div>
 
            <div id="legend_choices">
 
                <table id="legend_choices_tables" class="noborder" style="font-size:smaller;color:#545454"></table>
 
            </div>
kallithea/templates/summary/summary.html
Show inline comments
 
@@ -66,67 +66,67 @@ summary = lambda n:{False:'summary-short
 
    </div>
 
    <!-- end box / title -->
 
    <div class="form">
 
        <div id="summary" class="fields">
 
            <div class="field">
 
                <div class="label-summary">
 
                  <label>${_('Clone URL')}:</label>
 
                </div>
 
                <div class="input ${summary(c.show_stats)}">
 
                  ${self.repotag(c.db_repo)}
 
                  <input style="width:80%" type="text" id="clone_url" readonly="readonly" value="${c.clone_repo_url}"/>
 
                  <input style="display:none;width:80%" type="text" id="clone_url_id" readonly="readonly" value="${c.clone_repo_url_id}"/>
 
                  <div style="display:none" id="clone_by_name" class="btn btn-small">${_('Show by Name')}</div>
 
                  <div id="clone_by_id" class="btn btn-small">${_('Show by ID')}</div>
 
                  <div style="display:none" id="clone_by_name" class="btn btn-default btn-sm">${_('Show by Name')}</div>
 
                  <div id="clone_by_id" class="btn btn-default btn-sm">${_('Show by ID')}</div>
 
                </div>
 
            </div>
 

	
 
            <div class="field">
 
              <div class="label-summary">
 
                  <label>${_('Description')}:</label>
 
              </div>
 
              <div class="input ${summary(c.show_stats)} desc">${h.urlify_text(c.db_repo.description, stylize=c.visual.stylify_metatags)}</div>
 
            </div>
 

	
 
            <div class="field">
 
              <div class="label-summary">
 
                  <label>${_('Trending files')}:</label>
 
              </div>
 
              <div class="input ${summary(c.show_stats)}">
 
                %if c.show_stats:
 
                <div id="lang_stats"></div>
 
                %else:
 
                   ${_('Statistics are disabled for this repository')}
 
                   %if h.HasPermissionAny('hg.admin')('enable stats on from summary'):
 
                        ${h.link_to(_('Enable'),h.url('edit_repo',repo_name=c.repo_name, anchor='repo_enable_statistics'),class_="btn btn-mini")}
 
                        ${h.link_to(_('Enable'),h.url('edit_repo',repo_name=c.repo_name, anchor='repo_enable_statistics'),class_="btn btn-default btn-xs")}
 
                   %endif
 
                %endif
 
              </div>
 
            </div>
 

	
 
            <div class="field">
 
              <div class="label-summary">
 
                  <label>${_('Download')}:</label>
 
              </div>
 
              <div class="input ${summary(c.show_stats)}">
 
                %if len(c.db_repo_scm_instance.revisions) == 0:
 
                  ${_('There are no downloads yet')}
 
                %elif not c.enable_downloads:
 
                  ${_('Downloads are disabled for this repository')}
 
                    %if h.HasPermissionAny('hg.admin')('enable downloads on from summary'):
 
                        ${h.link_to(_('Enable'),h.url('edit_repo',repo_name=c.repo_name, anchor='repo_enable_downloads'),class_="btn btn-mini")}
 
                        ${h.link_to(_('Enable'),h.url('edit_repo',repo_name=c.repo_name, anchor='repo_enable_downloads'),class_="btn btn-default btn-xs")}
 
                    %endif
 
                %else:
 
                    <span id="${'zip_link'}">
 
                        <a class="btn btn-small" href="${h.url('files_archive_home',repo_name=c.db_repo.repo_name,fname='tip.zip')}"><i class="icon-file-zip"></i> ${_('Download as zip')}</a>
 
                        <a class="btn btn-default btn-sm" href="${h.url('files_archive_home',repo_name=c.db_repo.repo_name,fname='tip.zip')}"><i class="icon-file-zip"></i> ${_('Download as zip')}</a>
 
                    </span>
 
                    ${h.hidden('download_options')}
 
                    <span style="vertical-align: bottom">
 
                      <input id="archive_subrepos" type="checkbox" name="subrepos" />
 
                      <label for="archive_subrepos" class="tooltip" title="${_('Check this to download archive with subrepos')}" >${_('With subrepos')}</label>
 
                    </span>
 
                %endif
 
              </div>
 
            </div>
 
        </div>
 
        <div id="summary-menu-stats">
 
          <ul>
 
@@ -295,25 +295,25 @@ $(document).ready(function(){
 
             var url = tmpl_links[k].replace('__CS__',new_cs.id);
 
             var subrepos = $('#archive_subrepos').is(':checked');
 
             url = url.replace('__SUB__',subrepos);
 
             url = url.replace('__NAME__',title_tmpl);
 

	
 
             s.html(url);
 
           }
 
       }
 
    });
 

	
 
    var tmpl_links = {};
 
    %for cnt,archive in enumerate(c.db_repo_scm_instance._get_archives()):
 
      tmpl_links["${archive['type']}"] = '${h.link_to('__NAME__', h.url('files_archive_home',repo_name=c.db_repo.repo_name, fname='__CS__'+archive['extension'],subrepos='__SUB__'),class_='btn btn-small')}';
 
      tmpl_links["${archive['type']}"] = '${h.link_to('__NAME__', h.url('files_archive_home',repo_name=c.db_repo.repo_name, fname='__CS__'+archive['extension'],subrepos='__SUB__'),class_='btn btn-default btn-sm')}';
 
    %endfor
 
});
 
</script>
 

	
 
%if c.show_stats:
 
<script type="text/javascript">
 
$(document).ready(function(){
 
    var data = ${c.trending_languages|n};
 
    var total = 0;
 
    var no_data = true;
 
    var tbl = document.createElement('table');
 
    tbl.setAttribute('class','trending_language_tbl');
kallithea/tests/functional/test_admin_gists.py
Show inline comments
 
@@ -64,25 +64,25 @@ class TestGistsController(TestController
 
    def test_create(self):
 
        self.log_user()
 
        response = self.app.post(url('gists'),
 
                                 params={'lifetime': -1,
 
                                         'content': 'gist test',
 
                                         'filename': 'foo',
 
                                         'public': 'public',
 
                                         '_authentication_token': self.authentication_token()},
 
                                 status=302)
 
        response = response.follow()
 
        response.mustcontain('added file: foo')
 
        response.mustcontain('gist test')
 
        response.mustcontain('<div class="btn btn-mini btn-success disabled">Public Gist</div>')
 
        response.mustcontain('<div class="btn btn-success btn-xs disabled">Public Gist</div>')
 

	
 
    def test_create_with_path_with_dirs(self):
 
        self.log_user()
 
        response = self.app.post(url('gists'),
 
                                 params={'lifetime': -1,
 
                                         'content': 'gist test',
 
                                         'filename': '/home/foo',
 
                                         'public': 'public',
 
                                         '_authentication_token': self.authentication_token()},
 
                                 status=200)
 
        response.mustcontain('Filename cannot be inside a directory')
 

	
 
@@ -97,41 +97,41 @@ class TestGistsController(TestController
 
    def test_create_private(self):
 
        self.log_user()
 
        response = self.app.post(url('gists'),
 
                                 params={'lifetime': -1,
 
                                         'content': 'private gist test',
 
                                         'filename': 'private-foo',
 
                                         'private': 'private',
 
                                         '_authentication_token': self.authentication_token()},
 
                                 status=302)
 
        response = response.follow()
 
        response.mustcontain('added file: private-foo<')
 
        response.mustcontain('private gist test')
 
        response.mustcontain('<div class="btn btn-mini btn-warning disabled">Private Gist</div>')
 
        response.mustcontain('<div class="btn btn-warning btn-xs disabled">Private Gist</div>')
 

	
 
    def test_create_with_description(self):
 
        self.log_user()
 
        response = self.app.post(url('gists'),
 
                                 params={'lifetime': -1,
 
                                         'content': 'gist test',
 
                                         'filename': 'foo-desc',
 
                                         'description': 'gist-desc',
 
                                         'public': 'public',
 
                                         '_authentication_token': self.authentication_token()},
 
                                 status=302)
 
        response = response.follow()
 
        response.mustcontain('added file: foo-desc')
 
        response.mustcontain('gist test')
 
        response.mustcontain('gist-desc')
 
        response.mustcontain('<div class="btn btn-mini btn-success disabled">Public Gist</div>')
 
        response.mustcontain('<div class="btn btn-success btn-xs disabled">Public Gist</div>')
 

	
 
    def test_new(self):
 
        self.log_user()
 
        response = self.app.get(url('new_gist'))
 

	
 
    def test_delete(self):
 
        self.log_user()
 
        gist = _create_gist('delete-me')
 
        response = self.app.post(url('gist_delete', gist_id=gist.gist_id),
 
            params={'_authentication_token': self.authentication_token()})
 

	
 
    def test_delete_normal_user_his_gist(self):
 
@@ -143,25 +143,25 @@ class TestGistsController(TestController
 
    def test_delete_normal_user_not_his_own_gist(self):
 
        self.log_user(TEST_USER_REGULAR_LOGIN, TEST_USER_REGULAR_PASS)
 
        gist = _create_gist('delete-me')
 
        response = self.app.post(url('gist_delete', gist_id=gist.gist_id), status=403,
 
            params={'_authentication_token': self.authentication_token()})
 

	
 
    def test_show(self):
 
        gist = _create_gist('gist-show-me')
 
        response = self.app.get(url('gist', gist_id=gist.gist_access_id))
 
        response.mustcontain('added file: gist-show-me<')
 
        response.mustcontain('%s - created' % TEST_USER_ADMIN_LOGIN)
 
        response.mustcontain('gist-desc')
 
        response.mustcontain('<div class="btn btn-mini btn-success disabled">Public Gist</div>')
 
        response.mustcontain('<div class="btn btn-success btn-xs disabled">Public Gist</div>')
 

	
 
    def test_show_as_raw(self):
 
        gist = _create_gist('gist-show-me', content='GIST CONTENT')
 
        response = self.app.get(url('formatted_gist',
 
                                    gist_id=gist.gist_access_id, format='raw'))
 
        assert response.body == 'GIST CONTENT'
 

	
 
    def test_show_as_raw_individual_file(self):
 
        gist = _create_gist('gist-show-me-raw', content='GIST BODY')
 
        response = self.app.get(url('formatted_gist_file',
 
                                    gist_id=gist.gist_access_id, format='raw',
 
                                    revision='tip', f_path='gist-show-me-raw'))
kallithea/tests/functional/test_compare.py
Show inline comments
 
@@ -64,25 +64,25 @@ class TestCompareController(TestControll
 
        response.mustcontain('%s@%s' % (repo2.repo_name, rev1))
 
        response.mustcontain("""Showing 2 commits""")
 
        response.mustcontain("""1 file changed with 2 insertions and 0 deletions""")
 

	
 
        response.mustcontain(_commit_div(cs1.raw_id, 'commit2'))
 
        response.mustcontain(_commit_div(cs2.raw_id, 'commit3'))
 

	
 
        response.mustcontain("""<a class="changeset_hash" href="/%s/changeset/%s">r1:%s</a>""" % (repo2.repo_name, cs1.raw_id, cs1.short_id))
 
        response.mustcontain("""<a class="changeset_hash" href="/%s/changeset/%s">r2:%s</a>""" % (repo2.repo_name, cs2.raw_id, cs2.short_id))
 
        ## files
 
        response.mustcontain("""<a href="#C--826e8142e6ba">file1</a>""")
 
        #swap
 
        response.mustcontain("""<a class="btn btn-small" href="/%s/compare/branch@%s...branch@%s?other_repo=%s&amp;merge=True"><i class="icon-arrows-cw"></i> Swap</a>""" % (repo2.repo_name, rev1, rev2, repo1.repo_name))
 
        response.mustcontain("""<a class="btn btn-default btn-sm" href="/%s/compare/branch@%s...branch@%s?other_repo=%s&amp;merge=True"><i class="icon-arrows-cw"></i> Swap</a>""" % (repo2.repo_name, rev1, rev2, repo1.repo_name))
 

	
 
    def test_compare_forks_on_branch_extra_commits_git(self):
 
        self.log_user()
 
        repo1 = fixture.create_repo(u'one-git', repo_type='git',
 
                                    repo_description='diff-test',
 
                                    cur_user=TEST_USER_ADMIN_LOGIN)
 
        self.r1_id = repo1.repo_id
 
        #commit something !
 
        cs0 = fixture.commit_change(repo1.repo_name, filename='file1',
 
                content='line1\n', message='commit1', vcs_type='git',
 
                parent=None, newfile=True)
 

	
 
@@ -115,25 +115,25 @@ class TestCompareController(TestControll
 
        response.mustcontain('%s@%s' % (repo2.repo_name, rev1))
 
        response.mustcontain("""Showing 2 commits""")
 
        response.mustcontain("""1 file changed with 2 insertions and 0 deletions""")
 

	
 
        response.mustcontain(_commit_div(cs1.raw_id, 'commit2'))
 
        response.mustcontain(_commit_div(cs2.raw_id, 'commit3'))
 

	
 
        response.mustcontain("""<a class="changeset_hash" href="/%s/changeset/%s">r1:%s</a>""" % (repo2.repo_name, cs1.raw_id, cs1.short_id))
 
        response.mustcontain("""<a class="changeset_hash" href="/%s/changeset/%s">r2:%s</a>""" % (repo2.repo_name, cs2.raw_id, cs2.short_id))
 
        ## files
 
        response.mustcontain("""<a href="#C--826e8142e6ba">file1</a>""")
 
        #swap
 
        response.mustcontain("""<a class="btn btn-small" href="/%s/compare/branch@%s...branch@%s?other_repo=%s&amp;merge=True"><i class="icon-arrows-cw"></i> Swap</a>""" % (repo2.repo_name, rev1, rev2, repo1.repo_name))
 
        response.mustcontain("""<a class="btn btn-default btn-sm" href="/%s/compare/branch@%s...branch@%s?other_repo=%s&amp;merge=True"><i class="icon-arrows-cw"></i> Swap</a>""" % (repo2.repo_name, rev1, rev2, repo1.repo_name))
 

	
 
    def test_compare_forks_on_branch_extra_commits_origin_has_incoming_hg(self):
 
        self.log_user()
 

	
 
        repo1 = fixture.create_repo(u'one', repo_type='hg',
 
                                    repo_description='diff-test',
 
                                    cur_user=TEST_USER_ADMIN_LOGIN)
 

	
 
        self.r1_id = repo1.repo_id
 

	
 
        #commit something !
 
        cs0 = fixture.commit_change(repo1.repo_name, filename='file1',
 
@@ -174,25 +174,25 @@ class TestCompareController(TestControll
 
        response.mustcontain('%s@%s' % (repo2.repo_name, rev1))
 
        response.mustcontain("""Showing 2 commits""")
 
        response.mustcontain("""1 file changed with 2 insertions and 0 deletions""")
 

	
 
        response.mustcontain(_commit_div(cs1.raw_id, 'commit2'))
 
        response.mustcontain(_commit_div(cs2.raw_id, 'commit3'))
 

	
 
        response.mustcontain("""<a class="changeset_hash" href="/%s/changeset/%s">r1:%s</a>""" % (repo2.repo_name, cs1.raw_id, cs1.short_id))
 
        response.mustcontain("""<a class="changeset_hash" href="/%s/changeset/%s">r2:%s</a>""" % (repo2.repo_name, cs2.raw_id, cs2.short_id))
 
        ## files
 
        response.mustcontain("""<a href="#C--826e8142e6ba">file1</a>""")
 
        #swap
 
        response.mustcontain("""<a class="btn btn-small" href="/%s/compare/branch@%s...branch@%s?other_repo=%s&amp;merge=True"><i class="icon-arrows-cw"></i> Swap</a>""" % (repo2.repo_name, rev1, rev2, repo1.repo_name))
 
        response.mustcontain("""<a class="btn btn-default btn-sm" href="/%s/compare/branch@%s...branch@%s?other_repo=%s&amp;merge=True"><i class="icon-arrows-cw"></i> Swap</a>""" % (repo2.repo_name, rev1, rev2, repo1.repo_name))
 

	
 
    def test_compare_forks_on_branch_extra_commits_origin_has_incoming_git(self):
 
        self.log_user()
 

	
 
        repo1 = fixture.create_repo(u'one-git', repo_type='git',
 
                                    repo_description='diff-test',
 
                                    cur_user=TEST_USER_ADMIN_LOGIN)
 

	
 
        self.r1_id = repo1.repo_id
 

	
 
        #commit something !
 
        cs0 = fixture.commit_change(repo1.repo_name, filename='file1',
 
@@ -233,25 +233,25 @@ class TestCompareController(TestControll
 
        response.mustcontain('%s@%s' % (repo2.repo_name, rev1))
 
        response.mustcontain("""Showing 2 commits""")
 
        response.mustcontain("""1 file changed with 2 insertions and 0 deletions""")
 

	
 
        response.mustcontain(_commit_div(cs1.raw_id, 'commit2'))
 
        response.mustcontain(_commit_div(cs2.raw_id, 'commit3'))
 

	
 
        response.mustcontain("""<a class="changeset_hash" href="/%s/changeset/%s">r1:%s</a>""" % (repo2.repo_name, cs1.raw_id, cs1.short_id))
 
        response.mustcontain("""<a class="changeset_hash" href="/%s/changeset/%s">r2:%s</a>""" % (repo2.repo_name, cs2.raw_id, cs2.short_id))
 
        ## files
 
        response.mustcontain("""<a href="#C--826e8142e6ba">file1</a>""")
 
        #swap
 
        response.mustcontain("""<a class="btn btn-small" href="/%s/compare/branch@%s...branch@%s?other_repo=%s&amp;merge=True"><i class="icon-arrows-cw"></i> Swap</a>""" % (repo2.repo_name, rev1, rev2, repo1.repo_name))
 
        response.mustcontain("""<a class="btn btn-default btn-sm" href="/%s/compare/branch@%s...branch@%s?other_repo=%s&amp;merge=True"><i class="icon-arrows-cw"></i> Swap</a>""" % (repo2.repo_name, rev1, rev2, repo1.repo_name))
 

	
 
    def test_compare_cherry_pick_changesets_from_bottom(self):
 

	
 
#        repo1:
 
#            cs0:
 
#            cs1:
 
#        repo1-fork- in which we will cherry pick bottom changesets
 
#            cs0:
 
#            cs1:
 
#            cs2: x
 
#            cs3: x
 
#            cs4: x
0 comments (0 inline, 0 general)