[CMF-checkins] CVS: Products/CMFTopic/skins/zpt_topic - friendlydatec_edit.pt:1.1 friendlydatec_editform.pt:1.1 listc_edit.pt:1.1 sic_edit.pt:1.1 ssc_edit.pt:1.1 topic_criteria_form.pt:1.1 topic_edit_form.pt:1.1 topic_subtopics_form.pt:1.1 topic_view.pt:1.1

Andrew Sawyers andrew@digicool.com
Wed, 29 Aug 2001 10:20:49 -0400


Update of /cvs-repository/Products/CMFTopic/skins/zpt_topic
In directory cvs.zope.org:/tmp/cvs-serv10647/zpt_topic

Added Files:
	friendlydatec_edit.pt friendlydatec_editform.pt listc_edit.pt 
	sic_edit.pt ssc_edit.pt topic_criteria_form.pt 
	topic_edit_form.pt topic_subtopics_form.pt topic_view.pt 
Log Message:

*Topic zpt skins....first pass.


=== Added File Products/CMFTopic/skins/zpt_topic/friendlydatec_edit.pt ===
<table border="0" cellpadding="0" cellspacing="2" class="FormLayout">
 <tr>
  <td width="20">
   <input type="checkbox" value="" name="criterion_ids:list" id=""
        tal:attributes="value here/getId; id string:cb_${here/getId}">
  </td>
  <td align="left">
   <label for="" tal:attributes="for string:cb_${here/getId}">
    <strong title="" tal:attributes="title here/Description>"Friendly" Date:</strong>
    <tt tal:content="here/Field">Field</tt>
   </label>
   <input type="hidden" name="criteria.id:records" value="" tal:attributes="value here/getId">
  </td>
 </tr>
 <tr valign="top">
  <td width="20">&nbsp;</td>
  <td>
    <select name="criteria.operation:records">
     <option value="min" tal:attributes="python:here.operation=='min'">At the least:</option>
     <option value="max" tal:attributes="python:here.operation=='max'">At the most:</option>
    </select>

   <select name="criteria.value:records" tal:define="dateoptions here/defaultDateOptions">
     <option value=""
        tal:repeat="doption dateoptions"
        tal:attributes="value doption; selected python:here.value == doption"
        tal:content="doption"
     >Date Option</option>
   </select>

    <select name="criteria.daterange:records">
     <option value="old" tal:attributes="selected python:here.daterange() == 'old'">old</option>
     <option value="ahead" tal:attributes="selected python:here.daterange() == 'ahead'">ahead</option>
    </select>
  </td>
 </tr>
</table>



=== Added File Products/CMFTopic/skins/zpt_topic/friendlydatec_editform.pt ===
<table border="0" cellpadding="0" cellspacing="2" class="FormLayout">
 <tr>
  <td width="20">
   <input type="checkbox" value="" name="criterion_ids:list" id=""
        tal:attributes="value here/getId; id string:cb_${here/getId}">
  </td>
  <td align="left">
   <label for="" tal:attributes="for string:cb_${here/getId}">
    <strong title="" tal:attributes="title here/Description">"Friendly" Date:</strong>
    <tt tal:content="here/Field">Field</tt>
   </label>
   <input type="hidden" name="criteria.id:records" value="" tal:attributes="value here/getId">
  </td>
 </tr>
 <tr valign="top">
  <td width="20">&nbsp;</td>
  <td>
    <select name="criteria.operation:records">
     <option value="min" tal:attributes="selected python:here.operation=='min'">At the least:</option>
     <option value="max" tal:attributes="selected python:here.operation=='max'">At the most:</option>
    </select>

   <select name="criteria.value:records" tal:define="dateoptions here/defaultDateOptions">
     <option value=""
        tal:repeat="doption dateoptions"
        tal:attributes="value python:doption[0]; selected python:here.value == doption"
        tal:content="python:doption[1]"
     >Date Option</option>
   </select>

    <select name="criteria.daterange:records">
     <option value="old" tal:attributes="selected python:here.daterange == 'old'">old</option>
     <option value="ahead" tal:attributes="selected python:here.daterange == 'ahead'">ahead</option>
    </select>
  </td>
 </tr>
</table>



=== Added File Products/CMFTopic/skins/zpt_topic/listc_edit.pt ===
<table border="0" cellpadding="0" cellspacing="2" class="FormLayout">
<tr>
    <td width="20">
        <input type="checkbox" value="" name="criterion_ids:list" id=""
            tal:attributes="value here/getId; id string:cb_${here/getId}">
    </td>
    <td align="left">
        <label for="" tal:attributes="for string:cb_${here/getId}">
            <strong title="" tal:attributes="title here/Description">List:</strong>
            <tt tal:content="here/Field">Field</tt>
        </label>
        <input type="hidden" name="criteria.id:records" value="" tal:attributes="value here/getId">
    </td>
</tr>
<tr valign="top">
    <td width="20">&nbsp;</td>
    <td valign="top"><br>
        <strong>Value:</strong>
        <textarea name="criteria.value:lines:records" rows="5" cols="40"
            tal:content="python:modules['string'].join(here.value, '\n')"
        ></textarea>
    </td>
</tr>
</table>



=== Added File Products/CMFTopic/skins/zpt_topic/sic_edit.pt ===
<table border="0" cellpadding="0" cellspacing="2" class="FormLayout">
<tr>
    <td width="20">
        <input type="checkbox" value="" name="criterion_ids:list" id=""
            tal:attributes="value here/getId; id string:cb_${here/getId}">
    </td>
    <td align="left">
        <label for=""
            tal:attributes="for string:cb_${here/getId}">
            <strong title="" tal:attributes="title here/Description">Integer:</strong>
            <tt tal:content="here/Field">Field</tt>
        </label>
        <input type="hidden" name="criteria.id:records" value=""
            tal:attributes="value here/getId">
    </td>
</tr>
<tr>
    <td width="20">&nbsp;</td>
    <td>
        <strong>Value:</strong>
        <input type="text" name="criteria.value:records" value="" size="40"
            tal:attributes="value here/value">
    </td>
</tr>
<tr>
    <td width="20">&nbsp;</td>
    <td>
    <strong>Direction:</strong>
    <input type="radio" name="" value="min" id=""
            tal:attributes="checked python:here.direction=='min'; id string:${here/getId}_min; name string:criteria.direction__${here/getId}:records"/>
        <label for="" tal:attributes="for string:${here/getId}_min">Minimum</label>

    <input type="radio" name="" value="max" id=""
            tal:attributes="checked python:here.direction=='max'; id string:${here/getId}_max; name string:criteria.direction__${here/getId}:records" />
        <label for="" tal:attributes="for string:${here/getId}_max">Maximum</label>

    <input type="radio" name="" value="min:max" id=""
            tal:attributes="checked python:here.direction=='min:max'; id string:${here/getId}_minmax; name string:criteria.direction__${here/getId}:records"/>
        <label for="&dtml-getId;_minmax">Min/Max</label>
    </td>
</table>



=== Added File Products/CMFTopic/skins/zpt_topic/ssc_edit.pt ===
<table border="0" cellpadding="0" cellspacing="2" class="FormLayout">
<tr>
    <td width="20">
        <input type="checkbox" value="" name="criterion_ids:list" id=""
            tal:attributes="value here/getId; id string:cb_${here/getId}"/>
    </td>
    <td align="left">
    <label for=""
        tal:attributes="for string:cb_${here/getId}">
        <strong title=""
            tal:attributes="title here/Description">
                String:
        </strong>
        <tt
            tal:content="here/Field">
                Field
        </tt>
    </label>
    <input type="hidden" name="criteria.id:records" value=""
        tal:attributes="value here/getId"/>
    </td>
</tr>
<tr>
    <td width="20">&nbsp;</td>
    <td>
        <strong>Value:</strong>
        <input type="text" name="criteria.value:records"
            value="" size="40"
            tal:attributes="value here/value | nothing" />
    </td>
</tr>
</table>



=== Added File Products/CMFTopic/skins/zpt_topic/topic_criteria_form.pt ===
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
            "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns:tal="http://xml.zope.org/namespaces/tal"
    xmlns:metal="http://xml.zope.org/namespaces/metal"
    metal:use-macro="container/main_template/macros/master">
<body>
<div metal:fill-slot="main">

<div class="Desktop">

<div class="Topic">

<h2> Topic Criteria: <span tal:replace="here/getId" /> </h2>

<form action="" method="post" tal:attributes="action here/absolute_url">
<span tal:define="criteria here/listCriteria">
    <span tal:repeat="criterion criteria">
        <span tal:define="editform string:criterion/${criterion/getEditForm}"
            tal:replace="structure python:path(editform)" />
    </span>
</span>
<input type="submit" name="topic_deleteCriteria:action" value=" Delete selected ">
&nbsp;&nbsp;
<input type="submit" name="topic_editCriteria:action" value=" Save changes ">
<input type="hidden" name=":default_action" value="editCriteria">
</form>


<form action="" method="post" tal:attributes="action string:${here/absolute_url}/topic_addCriterion">
<h2> Add New Topic Criteria: </h2>
<table class="FormLayout">
<tr valign="top">
    <th align="right"> Field id: </th>
    <td>
        <select name="field" tal:define="fields here/listAvailableFields">
            <option value="" tal:repeat="field fields" tal:attributes="value field" tal:content="field">Field</option>
        </select>
    </td>
</tr>
<tr valign="top">
    <th align="left"> Criteria type: </th>
    <td>
        <select name="criteria_type" tal:define="types here/listCriteriaTypes">
            <option value="" tal:repeat="type types" tal:attributes="value type/name" tal:content="type/name">Type</option>
        </select>
    </td>
</tr>
<tr>
    <td>&nbsp;</td>
    <td><input type="submit" value=" Add "></td>
</tr>
</table>
</form>

</div>

</div>

</div>
</body>
</html>


=== Added File Products/CMFTopic/skins/zpt_topic/topic_edit_form.pt ===
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
            "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns:tal="http://xml.zope.org/namespaces/tal"
    xmlns:metal="http://xml.zope.org/namespaces/metal"
    metal:use-macro="container/main_template/macros/master">
<body>
<div metal:fill-slot="main">

<div class="Desktop">

<div class="Topic">

<h2> Edit Topic: <span tal:replace="here/id" /> </h2>

<form action="" method="post" tal:attributes="action here/absolute_url">
<table class="FormLayout">

 <tr valign="top">
  <th align="right"> Title: </th>
  <td><input type="text" name="title" value="Title" size="30" tal:attributes="value here/title" /></td>
 </tr>
 <tr valign="top">
  <th align="right"> Description: </th>
  <td><textarea name="description:test" rows="5" cols="65"
        tal:content="here/description"
       >Description</textarea></td>
 </tr>
 <tr valign="top">
  <th align="right"> Acquire Criteria<br>from Parent: </th>
  <td>
   <input type="checkbox"
          name="acquireCriteria"
          value="1" tal:attributes="checked python:here.acquireCriteria and 'checked' or ''">
   <input type="hidden"
          name="acquireCriteria:default"
          value="">
  </td>
 </tr>

 <tr valign="top">
  <td> <br> </td>
  <td>
   <input type="submit" name="topic_editTopic:action" value="Change">
  </td>
 </tr>

</table>
</form>

</div>

</div>
</div>
</body>
</html>


=== Added File Products/CMFTopic/skins/zpt_topic/topic_subtopics_form.pt ===
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
            "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns:tal="http://xml.zope.org/namespaces/tal"
    xmlns:metal="http://xml.zope.org/namespaces/metal"
    metal:use-macro="container/main_template/macros/master">
<body>
<div metal:fill-slot="main">

<div class="Desktop">

<div class="Topic">

<h2> Topic Subtopics: <span tal:replace="here/getId">Id</span> </h2>

<form action="" method="post" tal:attributes="action here/absolute_url">
<table class="FormLayout" tal:define="subtopics here/listSubtopics">

<tr valign="top" tal:repeat="topic subtopics">
    <td>
        <input type="checkbox" name="ids:list" value="" tal:attributes="value topic/getId">
    </td>
    <td tal:define="queries topic/buildQuery; items python:queries.items()">
        <a href="" tal:attributes="href topic/getId" tal:content="topic/getId">Id</a>
        (<span tal:repeat="item items" tal:condition="items">
            <span tal:define="n repeat/item/number; key python:item[0]; value python:item[1]">
            <span tal:replace="string:${key} : ${value}"/>
            <span tal:replace="string:," tal:condition="python:n < len(items)" />
            </span>
        </span>)
    </td>
</tr>

<tr valign="top">
    <td> <br> </td>
    <td>
        <input type="submit" name="folder_rename_form:action" value="Rename">
        <input type="submit" name="folder_cut:action" value="Cut">
        <input type="submit" name="folder_copy:action" value="Copy">
        <input type="submit" name="folder_paste:action" value="Paste">
        <input type="submit" name="folder_delete:action" value="Delete">
    </td>
</tr>

</table>
</form>

<form action="topic_addSubtopic" method="get">
<h2> Add subtopic: </h2>
<p><strong>Id: </strong>
<input type="text" name="new_id" size="30" /><br />
<input type="submit" value=" Add " /></p>
</form>

</div>

</div>
</div>
</body>
</html>


=== Added File Products/CMFTopic/skins/zpt_topic/topic_view.pt ===
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
            "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns:tal="http://xml.zope.org/namespaces/tal"
    xmlns:metal="http://xml.zope.org/namespaces/metal"
    metal:use-macro="container/main_template/macros/master">
<body>
<div metal:fill-slot="main">

<div class="Desktop">

<div class="Topic">

<h2><span tal:replace="here/title">title</span> </h2>

<span tal:define="topics python:here.objectValues( [ 'Portal Topic' ] )" tal:condition="topics">
    <h4>Subtopics: </h4>
    <div tal:repeat="topic topics">
        <a href=""
            tal:define="topictitle python:topic.Title() or topic.getId()"
            tal:attributes="href topic/absolute_url"
            tal:content="topictitle">
                Topic Title
            </a>
    </div>
</span>

<span tal:define="
            b_start string:0;b_start request/b_start | b_start;
            results here/queryCatalog;
            Batch python:modules['ZTUtils'].Batch;
            global batch python:Batch(results, 5, int(b_start), orphan=1)">
    <h4>Topic Matches: </h4>
    <div tal:repeat="match batch" tal:condition="batch">
        <a href=""
            tal:attributes="href python:here.portal_catalog.getpath(match.data_record_id_)"
            tal:content="match/Title">
                Match Title
            </a>
    </div>


    <span tal:define="p batch/previous" tal:condition="p">
    <a href=""
        tal:attributes="href string:?b_start=${p/first}">Previous <span
        tal:replace="p/length">n</span> items</a>
    </span>&nbsp;&nbsp;
    <span tal:define="n batch/next" tal:condition="n">
    <a href=""
        tal:attributes="href string:?b_start=${batch/end}">Next <span
        tal:replace="n/length">n</span> items</a>
    </span>

    <h3> Query Parameters </h3>

    <ul tal:define="queries here/buildQuery; items python:queries.items()"
        tal:condition="queries">
    <span tal:repeat="item items">
    <li tal:define="key python:item[0]; value python:item[1]" tal:content="string:${key} : ${value}">item</li>
    </span>
    </ul>
</span>

</div>

</div>
</div>
</body>
</html>