[Zope-CVS] CVS: Products/QueueCatalog/www - edit.zpt:1.1

Shane Hathaway shane@cvs.zope.org
Thu, 5 Sep 2002 17:21:05 -0400


Update of /cvs-repository/Products/QueueCatalog/www
In directory cvs.zope.org:/tmp/cvs-serv5774/www

Added Files:
	edit.zpt 
Log Message:
- Allowed the user to configure the list of indexes to defer.  By
deferring only text indexes, we can get most of the advantages of
the catalog queue without having to make applications aware of the
catalog queue.

- Carefully avoided using old acquisition wrappers when retrieving the
ZCatalog from the cache, and renamed the cache variable to
_v_catalog_cache.

- Avoided calling __init__ more than once, which is bad style.

- Defined an exception class so we don't mask TypeErrors.

- The catalog location should not be confined to superValues();
removed this assumption.  The catalog can be at an arbitrary path.

- _update(): Allowed uids to be relative physical paths.  ZCatalog
works fine with relative paths and we very much need relative paths.

- Renamed _zcatalog_method to _is_zcatalog_method for clarity.

- getZCatalog(): fixed improper reuse of the variable "ZC".

- Used a real security declaration as opposed to
__allow_access_to_unprotected_subobjects__.


=== Added File Products/QueueCatalog/www/edit.zpt ===
<h1 tal:replace="structure here/manage_page_header">Header</h1>
<h1 tal:replace="structure here/manage_tabs">Tabs</h1>

<p class="form-help">
  Edit the properties of this ZCatalog Queue on this form
</p>

<form action="manage_edit">

  <table cellspacing="0" cellpadding="3">

    <tr>
      <td align="left" valign="top"><div class="form-optional">
        Title
      </div></td>
      <td align="left" valign="top" colspan="3">
        <input type="text" name="title" size="40"
               tal:attributes="value here/getTitle" />
      </td>
    </tr>

    <tr>
      <td align="left" valign="top" class="form-label">
        Catalog location
      </td>
      <td align="left" valign="top" colspan="3">
        <input name="location"
               tal:attributes="value here/manage_getLocation" />
      </td>
    </tr>

    <tr tal:define="indexes here/getIndexInfo" tal:condition="indexes">
      <td align="left" valign="top"><div class="form-optional">
         Indexes to defer
      </td>
      <td align="left" valign="top" colspan="3">

<select name="deferred_indexes:list" multiple="multiple"
  tal:define="deferred_indexes here/getDeferredIndexes">
<option tal:repeat="index_info indexes"
  tal:attributes="value index_info/id; selected python:
  index_info['id'] in deferred_indexes"
  tal:content="string: ${index_info/id} (${index_info/meta_type})"></option>
</select>

      </td>
    </tr>

    <tr>
      <td>&nbsp;</td>
      <td colspan="3">
        <br>
        <input type="submit" name="submit" value="Save Changes">
      </td>
    </tr>

  </table>

</form>

<h1 tal:replace="structure here/manage_page_footer">Footer</h1>