Files @ 31f510a88584
Branch filter:

Location: kallithea/rhodecode/templates/admin/admin_log.html

Bradley M. Kuhn
Update minified YUI to version 2.9 built from Source.

yui.2.9.js used to be a minified version of YUI 2.9 until 5143b8df576c updated
it to something else and applied more aggresive minification. We stick to a
clean but minified version 2.9.

The license of YUI is BSD 3-clause, as described on
http://yuilibrary.com/license/ .

Since the minified version combines with GPLv3'd Javascript, it is only GPLv3'd
compliant to distribute this Object Code version with the Corresponding Source
(or offer therefor).

This yui.2.9.js is built from Source this way:
git clone https://github.com/yui/builder
git clone https://github.com/yui/yui2
cd yui2/
git checkout hudson-yui2-2800
ln -sf JumpToPageDropDown.js src/paginator/js/JumpToPageDropdown.js # work around inconsistent casing
rm -f tmp.js
for m in yahoo event dom connection animation dragdrop element datasource autocomplete container event-delegate json datatable paginator; do
rm -f build/$m/$m.js; ( cd src/$m && ant build deploybuild ) && sed -e 's,@VERSION@,2.9.0,g' -e 's,@BUILD@,2800,g' build/$m/$m.js >> tmp.js
done
java -jar ../builder/componentbuild/lib/yuicompressor/yuicompressor-2.4.4.jar tmp.js -o yui.2.9.js

The source is mirrored and available on https://kallithea-scm.org/repos/mirror .
## -*- coding: utf-8 -*-
%if c.users_log:
<table>
    <tr>
        <th class="left">${_('Username')}</th>
        <th class="left">${_('Action')}</th>
        <th class="left">${_('Repository')}</th>
        <th class="left">${_('Date')}</th>
        <th class="left">${_('From IP')}</th>
    </tr>

    %for cnt,l in enumerate(c.users_log):
    <tr class="parity${cnt%2}">
        <td>
        %if l.user is not None:
          ${h.link_to(l.user.username,h.url('edit_user', id=l.user.user_id))}
        %else:
          ${l.username}
        %endif
        </td>
        <td>${h.action_parser(l)[0]()}
            <div class="journal_action_params">
                ${h.literal(h.action_parser(l)[1]())}
            </div>
        </td>
        <td>
            %if l.repository is not None:
              ${h.link_to(l.repository.repo_name,h.url('summary_home',repo_name=l.repository.repo_name))}
            %else:
              ${l.repository_name}
            %endif
        </td>

        <td>${h.fmt_date(l.action_date)}</td>
        <td>${l.user_ip}</td>
    </tr>
    %endfor
</table>

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

    YUE.delegate("user_log","click",function(e,matchedEl,container){
          var el = e.target;
          YUD.setStyle(YUD.get(el.id.substring(1)),'display','');
          YUD.setStyle(el.parentNode,'display','none');
      },'.show_more');
  });
</script>

<div class="pagination-wh pagination-left">
${c.users_log.pager('$link_previous ~2~ $link_next')}
</div>
%else:
    ${_('No actions yet')}
%endif