File:  [Repository] / ECHO_content / zpt / ECHO_linkCreator_main.zpt
Revision 1.5: download - view: text, annotated - select for diffs - revision graph
Tue Jan 9 17:01:01 2007 UTC (17 years, 6 months ago) by dwinter
Branches: MAIN
CVS tags: cleanup, Root_cleanup, HEAD
bug fixed in echo_xslt

    1: <html>
    2: <head>
    3: <SCRIPT LANGUAGE="JavaScript"><!--
    4: function openChild(file,window,button) {
    5:     childWindow=open(file,window);
    6:     if (childWindow.opener == null) childWindow.opener = self;
    7:     };
    8: //--></SCRIPT>
    9: </head>
   10: <body tal:define="col options/collection;global nr python:-1; masterUrl options/masterUrl; slaveUrl options/slaveUrl; entries python:here.getCollectionEntries(col)">
   11: <h2>Collection: <span tal:replace="col"/></h2>
   12: <form id="urls" tal:attributes="action python:here.absolute_url()+'/setUrls'">
   13: <input type="hidden" name="collection" 
   14: tal:attributes="value col">
   15: <table>
   16: <tr>
   17: <td>
   18: Masterurl
   19: </td>
   20: <td><input type="text" size="100" id="masterUrl" name="masterUrl" tal:attributes="value masterUrl">
   21: </td>
   22: </tr>
   23: <tr>
   24: <td>
   25: Slaveurl
   26: </td>
   27: <td><input type="text" size="100" id="slaveUrl" name="slaveUrl" tal:attributes="value slaveUrl">
   28: </td>
   29: </tr>
   30: </table>
   31: <input type="submit" value="submit">
   32: </form>
   33: <form id="docs">
   34: <table>
   35: <tr>
   36: <td>Master document</td>
   37: <td><input size="50" id="master"></td>
   38: </tr>
   39: <tr>
   40: <td>Slave document</td>
   41: <td><input size="50" id="slave"></td>
   42: </tr>
   43: </table>
   44: </form>
   45: <button tal:attributes="onclick python:'openChild(document.getElementById(\'urls\').masterUrl.value+\'collection=%s&type=master&_pn=1&fn=\'+document.getElementById(\'docs\').master.value,\'masterWindow\',\'master\')'%col">show master</button>
   46: <button tal:attributes="onclick python:'openChild(document.getElementById(\'urls\').slaveUrl.value+\'collection=%s&type=slave&_pn=1&fn=\'+document.getElementById(\'docs\').slave.value,\'slaveWindow\',\'slave\')'%col">show slave</button>
   47: 
   48: 
   49: <tal:x tal:repeat="entry entries">
   50: <form  tal:attributes="action python:here.absolute_url()+'/changeEntry'" tal:define="global nr python:nr+1">
   51: <input type="hidden" name="nr:int" tal:attributes="value nr">
   52: <input type="hidden" name="collection" 
   53: tal:attributes="value col">
   54: <table>
   55: <tr tal:condition="python:entry.has_key('master')">
   56: <td >Master:</td> 
   57: <td tal:content="python:entry['master'][0]"/>
   58: <td tal:content="python:entry['master'][1]"/>
   59: <td><input site="20" name="masterID" tal:attributes="value python:entry['master'][2]"/></td>
   60: <td><a target="master" tal:attributes="href python:masterUrl+'fn='+entry['master'][0]+'&_id='+entry['master'][1].split('(')[0]+'&_pagelink='+entry['master'][2]+'/'+str(entries.index(entry))+'/source&_links='+here.absolute_url()+'/'+col+'/getCollectionXML'">show
   61: </a>
   62: <a target="master" tal:attributes="href python:masterUrl+'_showall=yes&fn='+entry['master'][0]+'&_id='+entry['master'][1].split('(')[0]+'&_pagelink='+entry['master'][2]+'/'+str(entries.index(entry))+'/source&_links='+here.absolute_url()+'/'+col+'/getCollectionXML'">all on this page
   63: </a>
   64: </tr>
   65: <tr tal:condition="python:entry.has_key('slave')">
   66: <td>Slave:</td> 
   67: <td><input type="text" size="90"  name="slaveUrl" tal:attributes="value python:entry['slave'][0]"/>
   68: <td tal:content="python:entry['slave'][1]"/>
   69: <td tal:content="python:entry['slave'][2]"/>
   70: <td><a target="slave" tal:attributes="href python:slaveUrl+'fn='+entry['slave'][0]+'&_id='+entry['slave'][1].split('(')[0]+'&_pagelink='+entry['slave'][2]+'/'+str(entries.index(entry))+'/target&_links='+here.absolute_url()+'/'+col+'/getCollectionXML'">show
   71: </a>
   72: <input type="submit" value="change">
   73: </tr>
   74: </table>
   75: </form>
   76: <form  tal:attributes="action python:here.absolute_url()+'/removeEntry'">
   77: <input type="hidden" name="nr:int" 
   78: tal:attributes="value nr">
   79: <input type="hidden" name="collection" 
   80: tal:attributes="value col">
   81: <input type="submit" value="delete">
   82: </form>
   83: <hr>
   84: </tal:x>
   85: 
   86: </body>
   87: </html>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>