<dtml-var standard_html_header>

<div class="Desktop">

<h1> Undo Transactions </h1>

<dtml-let transactions="portal_undo.listUndoableTransactionsFor(this())">

<dtml-if transactions>

  <form action="undo" method="POST">
  <p>This application's transactional feature allows you to easily undo changes
  made to the application's settings or data. You can revert the application
  to a &quot;snapshot&quot; of it's state at a previous point in time. </p>
  <p>
  Select one or more transactions below and then click on the &quot;Undo&quot;
  button to undo the transactions.  Note that even though a transaction
  is shown below, you will not be able to undo it if later transactions
  modified objects that were modified by the transaction. </p>

  <table class="FormLayout">
    <tr><td colspan="2" align="center"><input type="SUBMIT" value=" Undo " />
        </td></tr>
    <tr><td></td></tr>
    <dtml-if first_transaction>
       <tr><td colspan="2" align="center">
       <a href="undo_form?first_transaction:int=<dtml-var
	 expr="first_transaction*2-last_transaction"
	 >&last_transaction:int=<dtml-var first_transaction
         >&PrincipiaUndoBatchSize:int=<dtml-var PrincipiaUndoBatchSize
         >">
       Later Transactions</h>
       </td></tr>
    </dtml-if>
    <dtml-in transactions mapping>
      <tr>
      <td valign="top"><input type="checkbox" name="transaction_info:list"
	  value="<dtml-var id html_quote>" /></td>
      <td valign="top">
	  <strong><dtml-var description html_quote></strong> by <strong>
          <dtml-if user_name>
	    <dtml-var user_name html_quote>
          <dtml-else>
            <em>Zope</em>
          </dtml-if>
	  </strong> on <dtml-var time fmt=Mon> <dtml-var time fmt=day> at
	  <dtml-var time fmt=Time>
      </td>
    </tr>
    </dtml-in>
    <tr><td colspan="2" align="center">
    <dtml-if expr="_.len(transactions) == PrincipiaUndoBatchSize">
       <a href="undo_form?first_transaction:int=<dtml-var
	 last_transaction>&last_transaction:int=<dtml-var
	 expr="last_transaction+PrincipiaUndoBatchSize"
         >&PrincipiaUndoBatchSize:int=<dtml-var PrincipiaUndoBatchSize
         >">
       Earlier Transactions</a>
    </dtml-if>
    </td></tr>
    <tr><td></td></tr>
    <tr><td colspan="2" align="center"><input type="SUBMIT" value=" Undo " />
    </td></tr>
  </table>
  </form>

<dtml-else>

  There are no transactions that can be undone.

</dtml-if>

</dtml-let>

</div>

<dtml-var standard_html_footer>
