view MoinMoin/templates/mychanges.html @ 2772:239e3b34c6b4

fix parentid adding to metadata, use it for +mychanges, display it on +meta
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Tue, 02 Sep 2014 20:32:52 +0200
parents 5762664a2887
children 05b4f45a4872
line wrap: on
line source
{% extends theme("layout.html") %}
{% import "utils.html" as utils %}

{% block content %}
    {% set (history, next_offset, previous_offset) = my_changes_page %}
    {% if my_changes %}
        <div class='moin-offset-links'>
            {% if previous_offset >= 0 %}
                <a href="{{ url_for('frontend.mychanges', offset=previous_offset) }}" title="{{ _("Previous") }}">&laquo;</a>
            {% endif %}
            {% if next_offset %}
                <a href="{{ url_for('frontend.mychanges', offset=next_offset) }}" title="{{ _("Next") }}">&raquo;</a>
            {% endif %}
        </div>
        <h1>{{ _('My Changes') }}</h1>
        <div class="moin-clr"></div>
        <div id="moin-page-history">
            <table class="zebra">
                <thead>
                    <tr>
                        <th>{{ _("Item") }}</th>
                        <th>{{ _("Rev.") }}</th>
                        <th>{{ _("Timestamp") }}</th>
                        <th class="moin-integer">{{ _("Size") }}</th>
                        <th>{{ _("Diff") }}</th>
                        <th>{{ _("Content-Type") }}</th>
                        <th>{{ _("Comment") }}</th>
                    </tr>
                </thead>
                <tbody>
                    {% for doc in my_changes %}
                        <tr>
                            <td class="moin-wordbreak">
                                {% for name in doc.name %}
                                    {% if not loop.first %}|{% endif %}
                                    <a href="{{ url_for_item(name, namespace=doc.fqname.namespace, endpoint='frontend.show_item') }}">{{ name }}</a>
                                {% endfor %}
                            </td>
                            <td>{{ doc.revid|shorten_id }}</td>
                            <td>{{ doc.mtime|datetimeformat }}</td>
                            <td class="moin-integer">{{ doc.size }}</td>
                            <td>
                                <div class="moin-hist-rev">
                                    <form action="{{ url_for('frontend.diff', item_name=doc.fqname) }}" method="GET">
                                        <input type="hidden" name="rev1" value="{{ doc.parentid }}" />
                                        <input type="hidden" name="rev2" value="{{ doc.revid }}" />
                                        <input type="submit" class="btn btn-sm btn-primary" value="Diff" />
                                    </form>
                                </div>
                            </td>
                            <td class="moin-wordbreak">{{ doc.contenttype }}</td>
                            <td class="moin-wordbreak">{{ doc.comment }}</td>
                        </tr>
                    {% endfor %}
                </tbody>
            </table>
        </div>
    {% endif %}
{% endblock %}