Files @ 137ea21dfc10
Branch filter:

Location: kallithea/kallithea/templates/journal/journal.html

domruf
auth: when a auth plugin can't be imported try the next one instead of breaking completly

Some authentication modules depend on external services. This may cause the import
to fail.
Or another scenario is that a (third party) authentication module has been removed
and can't be imported anymore.
## -*- coding: utf-8 -*-
<%inherit file="/base/base.html"/>
<%block name="title">
    ${_('Journal')}
</%block>
<%def name="breadcrumbs_links()">
    <form id="filter_form" class="pull-left form-inline">
      <input class="form-control 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 data-toggle="tooltip" title="${h.journal_filter_help()}">?</span>
      <input type='submit' value="${_('Filter')}" class="btn btn-default btn-xs"/>
      ${_('Journal')} - ${ungettext('%s Entry', '%s Entries', c.journal_pager.item_count) % (c.journal_pager.item_count)}
    </form>
</%def>
<%block name="header_menu">
    ${self.menu('journal')}
</%block>
<%block name="head_extra">
  <link href="${h.url('journal_atom', api_key=request.authuser.api_key)}" rel="alternate" title="${_('ATOM journal feed')}" type="application/atom+xml" />
  <link href="${h.url('journal_rss', api_key=request.authuser.api_key)}" rel="alternate" title="${_('RSS journal feed')}" type="application/rss+xml" />
</%block>

<%def name="main()">
    <div class="panel panel-primary">
        <div class="panel-heading clearfix">
            <div class="pull-left">
                ${self.breadcrumbs()}
            </div>
            <div class="pull-right panel-title">
                <a href="${h.url('my_account_watched')}"><i class="icon-eye"></i> ${_('Watched Repositories')}</a>
                <a href="${h.url('my_account_repos')}"><i class="icon-database"></i> ${_('My Repositories')}</a>
                <a id="refresh" href="${h.url('journal')}"><i class="icon-arrows-cw"></i></a>
                <a href="${h.url('journal_atom', api_key=request.authuser.api_key)}"><i class="icon-rss-squared"></i></a>
            </div>
        </div>
        <div id="journal" class="panel-body">
            <%include file='journal_data.html'/>
        </div>
    </div>

<script type="text/javascript">

    $('#j_filter').click(function(){
        var $jfilter = $('#j_filter');
        if($jfilter.hasClass('initial')){
            $jfilter.val('');
        }
    });
    var fix_j_filter_width = function(len){
        $('#j_filter').css('width', Math.max(80, len*6.50)+'px');
    };
    $('#j_filter').keyup(function(){
        fix_j_filter_width($('#j_filter').val().length);
    });
    $('#filter_form').submit(function(e){
        e.preventDefault();
        var val = $('#j_filter').val();
        window.location = "${url.current(filter='__FILTER__')}".replace('__FILTER__',val);
    });
    fix_j_filter_width($('#j_filter').val().length);

    $('#refresh').click(function(e){
        asynchtml("${h.url.current(filter=c.search_term)}", $("#journal"), function(){
            show_more_event();
            tooltip_activate();
            });
        e.preventDefault();
    });

</script>

<script type="text/javascript">
    $(document).ready(function(){
        var $journal = $('#journal');
        $journal.on('click','.pager_link',function(e){
            asynchtml(e.target.href, $journal, function(){
                show_more_event();
                tooltip_activate();
            });
            e.preventDefault();
        });
        $('#journal').on('click','.show_more',function(e){
            var el = e.target;
            $('#'+el.id.substring(1)).show();
            $(el.parentNode).hide();
        });
    });
</script>
</%def>