Commit graph

125 commits

Author SHA1 Message Date
Gaetan Delannay 9b9853e570 [pod,px] Better error reporting. [gen] Calendar field: allow to validate events from a timeline. 2015-03-05 10:42:08 +01:00
Gaetan Delannay 6e03682b99 [pod,px] Bugifx:complete tracebacks when errors within Python expressions. 2015-02-26 09:53:53 +01:00
Gaetan Delannay f047242d81 [gen] String field: bugfix when ajax-editing an empty multilingual field. 2015-01-30 12:02:39 +01:00
Gaetan Delannay a905aaa139 [shared] Added utils::flipDict allowing to flip keys<->values of a dict. [gen] file.py: added missing i18n labels. [gen] Added css style for rendering nice tables within the message popup. 2015-01-16 20:22:29 +01:00
Gaetan Delannay ffb8bed189 [pod] If you define a variable named 'tableName' inside a table, it will be used to name the table. For information, with Calc, every spreadsheet is represented as a table; the table name is the name that appears in the corresponding tab, in the bottom of the screen. 2015-01-14 11:46:25 +01:00
Gaetan Delannay 1730ce3c19 [pod] In an ods template, you can now define a variable 'columnsRepeated' that specifies, for every column of the table representing a spreadsheet, how much times it will be repeated bysubsequent 'for... cell' statements. For example, if you have a spreadsheet with 2 columns, and you will need to repeat the second one 100 times, define a statement 'do table with columnsRepeated=(1,100)'. If you don't do that, pod will be unable to guess what column must be repeated and how, will consider your table has having 2 columns and will produce a resulting table spreading the cells within a 2-columns wide table. 2015-01-13 17:02:59 +01:00
Gaetan Delannay 1ed4f0bf23 [pod] Bugfix: repeated error in a for loop (https://bugs.launchpad.net/appy/+bug/394267). [gen] pod field: get the value of appy cookie 'showSubTitle' in any pod template. 2014-10-16 17:35:35 +02:00
Gaetan Delannay 25f0e8184e [pod] When inserting an image via statement do... from document(...), parameter 'sizeUnit' can now be 'pc' (percentage): in this case, percentages are expressed as a tuple (widthPercentage, heightPercentage) in parameter 'size' and must be integers from 1 to 100. [bin] backup.py: better error handling when contacting SMTP server. [gen] Calendar widget for Date fields: bugfix (when the date range is in reverse chronological order). [gen] Ref field: added hook 'afterLink' allowing to execute a method just after an object has been linked. [gen] Ref field: added attribute 'unlinkElement' allowing to define a specific condition for unlinking a given object (before, it was only possible to define, in attribute 'unlink', a global condition allowing to unlink any object from the Ref. [gen] Bugfix: the link to the home page, when clicking on the logo, is fixed. 2014-07-10 09:46:39 +02:00
Gaetan Delannay 477db8a21c [pod] Bugfix for https://bugs.launchpad.net/appy/+bug/1244738. 2014-06-24 08:31:39 +02:00
Gaetan Delannay f2571d2671 [pod] Force raiseOnError=True when working from an ODS template (solves bug https://bugs.launchpad.net/appy/+bug/1173295). 2014-06-23 21:02:15 +02:00
Gaetan Delannay c676d0b29c [pod] Bugfix for https://bugs.launchpad.net/appy/+bug/1333352. 2014-06-23 19:18:05 +02:00
Gaetan Delannay f7eaed817e [pod] Bugfix for https://bugs.launchpad.net/appy/+bug/1328139. 2014-06-23 16:48:32 +02:00
Gaetan Delannay f8f3c0e865 [pod] Added param Renderer.raiseOnError (False by default), that, if True, will force the Renderer to raise an error instead of dumping it into a note in the pod result. 2014-06-23 12:54:32 +02:00
Gaetan Delannay 114223a114 [pod] converter.py now works from Python2.4 to Python3. Thanks to Lennart Regebro who wrote the 'e=sys.exc_info()[1]' trick for catching exceptions in both Python2.4 and Python3 and Luc Saffre for discovering it. 2014-06-18 11:46:43 +02:00
Gaetan Delannay 1d0ee7a614 [gen] Bugfix in the Ref field; added method workflow.Transition.getBack that finds the 'back' transition of a given transition. 2014-05-02 12:35:09 +02:00
Gaetan Delannay ff102fbbe8 [pod] Take into account tabs. 'do ... from text' is now obsolete: pod expression now handle correctly tabs and carriage returns. 2014-03-06 11:33:47 +01:00
Gaetan Delannay e1d0597694 [gen] list field now takes into account 'show' attribute of sub-fields. 2014-01-14 09:07:42 +01:00
Gaetan Delannay 180b3473e8 [pod,px] Allow to reference an already defined variable instead of defining one in a var statement, via the '@' prefix. For example, in PX: var='@i = i + 1'. [pod] Repaired broken tests [gen] Bugfixes. 2013-09-23 22:36:09 +02:00
Gaetan Delannay 1be7d9f0ab [bin] backup.py: remove Data.fs.old before packing the ZODB to avoid disk space problems; [checkldap] added a param to define the scope of the LDAP query (base, onelevel or subtree); [shared] xml_parser: convert nbsp entity to the equivalent utf-8 char. 2013-09-05 10:42:19 +02:00
Gaetan Delannay 34e3a3083e [gen] More work ZPT->PX. 2013-08-21 12:35:30 +02:00
Gaetan Delannay 1810373304 [gen] Optimized PXs. [px] added tag 'var2', similar to 'var', but that is executed after tags 'for' and 'if'. 2013-07-15 11:23:29 +02:00
Gaetan Delannay 25b4edfc1d [gen] Moved Appy fields into appy/fields together with their PX. 2013-07-08 23:39:16 +02:00
Gaetan Delannay 7fcd2f44d3 [gen] More ZPT->PX work. 2013-06-27 17:40:01 +02:00
Gaetan Delannay cb6fea7631 [pod,px] 'loop' variable allows to know if we are managing an even or odd elem via loop.<elem>.odd and loop.<elem>.even. [gen] In the process of migrating from ZPT (Zope Page Templates) to appy.px (Python Xml). 2013-06-27 11:57:39 +02:00
Gaetan Delannay e4b84be05e [px] Managed special HTML attributes like 'checked' and 'selected'. 2013-06-26 13:44:31 +02:00
Gaetan Delannay 5ece5c9831 [px] Added the possibility to have several PX actions in the same XHTML tag. If several PX action are defined, they are evaluated in this order: var, for, if. 2013-06-25 23:22:33 +02:00
Gaetan Delannay 1d931cfb96 [px] Made PX thread-safe. 2013-06-25 12:04:23 +02:00
Gaetan Delannay 086f93e845 [gen] Added the posssibility to create a custom widget that displays an icon for generating a doc from a pod field, but with an additional param allowing to customize the pod context. 2013-06-20 17:35:52 +02:00
Gaetan Delannay 06039b300c [pod] Line breaks which are found within pod expression results are converted to odf line-breaks into the pod result. 2013-06-12 10:30:20 +02:00
Gaetan Delannay 1b3af98305 [pod] Bugfix in function 'pod'; added new method 'pageBreak' allowing to insert a page break via a note 'do xxx from pageBreak()' 2013-05-31 15:23:28 +02:00
Gaetan Delannay 0c50fe188a Updated 'print' statements throughout Appy code, in order to be Python3x as well as Python2x-compliant. 2013-05-30 00:46:11 +02:00
Gaetan Delannay e8c63f225f [pod] Within the context of a 'for' statement, loop objects now have additional boolean attributes named 'first' and 'last' that allow to know if the currently walked element is, respectively, the first of the last element of the whole list. Added params 'pageBreakBefore' and 'pageBreakAfter' to OdtImporter and PodImporter. 2013-05-27 22:32:18 +02:00
Gaetan Delannay 540a9947d8 [pod,px] An expression that begins with char ':' is considered XML code that will come into the result unescaped. 2013-05-24 10:16:16 +02:00
Gaetan Delannay b996de09c6 [gen] Bugfixes. 2013-05-16 09:53:27 +02:00
Gaetan Delannay a94d400d03 [pod] Bugfix: error when a pod template does not have a 'mimetype' file inside (https://bugs.launchpad.net/bugs/1173009); bugfix: error when parsing some ods pod templates: some cells do not have attribute 'office:value-type' (see bug https://bugs.launchpad.net/bugs/1173301). [gen] Added a basic integration of gen applications with Google Analytics. 2013-04-29 21:32:05 +02:00
Gaetan Delannay 4e5e5143cb [pod] Allowed to call a pod template within another pod template via new POD function 'pod'. 2013-04-22 10:57:51 +02:00
Gaetan Delannay eaf7156b47 [pod] Added the possibility, for function 'document', to import, into an ODT result, external documents of various formats: doc, xls, ppt, etc. This new 'ConvertImporter' uses LibreOffice to first convert the doc into PDF, and then uses the PdfImporter to split the PDF into images (one image per page) and include in in the pod result. 2013-04-19 15:30:18 +02:00
Gaetan Delannay 2a145ac890 [px] PXs can be called by other PXs. 2013-03-22 12:52:24 +01:00
Gaetan Delannay bfbf9bea82 [pod] Improved error handling. [px] More work on PX. 2013-03-19 22:06:47 +01:00
Gaetan Delannay d5296ba321 [pod] Added the possibility to define several variables, in 'with' statements, separated by ';'. 2013-03-19 17:07:11 +01:00
Gaetan Delannay bf98b2cdf2 [px] Implemented attribute values containing Python expressions, and errors management. 2013-03-16 00:02:16 +01:00
Gaetan Delannay be3cc6ae59 [px] First draft for a new template engine Python-XML, sharing the pod roots. 2013-03-15 16:50:28 +01:00
Gaetan Delannay 24089ef674 [gen] Improved search abilities. [pod] Bugfix: import several times an image from the same URL. 2013-02-18 15:03:26 +01:00
Gaetan Delannay 2307a284cc [gen] Wrapper.reindex: allow to specify attribute 'fields' containing the list of fields that must be reindexed. If not given, all object fields are reindexed. [pod] POD ODS templates: into POD results from ODS templates, Python expressions that produce ints, floats or dates (Zope DateTime only for the moment) produce cells with typed values. 2013-02-06 17:15:01 +01:00
Gaetan Delannay 43261fde60 [pod+gen] Added POD rendering based on ODS templates. Integrated with gen. 2013-02-05 08:51:25 +01:00
Gaetan Delannay d5d99b67eb [pod] Performance improvement: stop computing tag names, create a dict of precomputed tags before starting parsing. 2013-01-31 12:50:25 +01:00
Gaetan Delannay ad94fee755 [gen] First draft of using POD ODS (Calc) templates. 2013-01-31 00:11:24 +01:00
Gaetan Delannay 47bcf87a5c [pod] Use, when available, Python's uuid module to generate images and file names to be included in pod results. 2013-01-23 11:47:50 +01:00
Gaetan Delannay 5d31bc10db [pod] Changed the way pod results are re-zipped, in order to be compliant with section 17.4 of the OpenDocument format specification (bug https://bugs.launchpad.net/appy/+bug/1101237). 2013-01-22 16:34:29 +01:00
Gaetan Delannay 240ce59519 [gen] Allow to display, in history, differences between successive versions of XHTML fields via appy.shared.diff.HtmlDiff (which was not integrated to appy.gen until now). Improved rendering of XHTML fields. [pod] bugfix while generating filenames for files included into pod results. 2013-01-07 15:30:13 +01:00