[PythonReports-checkins] PythonReports/PythonReports template.py, 1.7, 1.8
Brought to you by:
a1s
From: alexander s. <a1...@us...> - 2006-12-19 13:32:30
|
Update of /cvsroot/pythonreports/PythonReports/PythonReports In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv9039 Modified Files: template.py Log Message: added Arg and Subreport Index: template.py =================================================================== RCS file: /cvsroot/pythonreports/PythonReports/PythonReports/template.py,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** template.py 15 Dec 2006 13:24:48 -0000 1.7 --- template.py 19 Dec 2006 13:32:29 -0000 1.8 *************** *** 1,4 **** --- 1,5 ---- """PythonReports Template (PRT) structures""" """History (most recent first): + 15-dec-2006 [als] added Arg and Subreport 15-dec-2006 [als] Eject type defaults to "page" 15-dec-2006 [als] allow empty detail section; *************** *** 122,125 **** --- 123,150 ---- ) + Arg = Validator(tag="arg", + attributes={ + "name": (String, REQUIRED), + "value": (String, REQUIRED), + }, + doc="Actual argument value passed to subreport to fill a parameter slot" + ) + + # TODO subreport validation: + # - cannot be placed in a column + # - if inline is True, ownpageno must be False. + Subreport = Validator(tag="subreport", + attributes={ + "template": (String, REQUIRED), + "seq": (Integer, REQUIRED), + "data": (Expression, REQUIRED), + "when": (Expression, None), + "inline": (Boolean, False), + "ownpageno": (Boolean, False), + }, children=( + (Arg, Validator.UNRESTRICTED), + ), doc="Sets an embedded report to run on an inner data sequence" + ) + Field = Validator(tag="field", attributes={ *************** *** 217,220 **** --- 242,246 ---- # common set of child validators for all section elements _section_children = ( + (Subreport, Validator.UNRESTRICTED), (Box, Validator.ZERO_OR_ONE), (Style, Validator.UNRESTRICTED), *************** *** 307,311 **** Page size may be specified either with the "pagesize" attribute ! of with a pair of "width" and "height". If neither is set, it's an error. """ --- 333,337 ---- Page size may be specified either with the "pagesize" attribute ! or with a pair of "width" and "height". If neither is set, it's an error. """ |