diff --git a/addons/account/account_report.xml b/addons/account/account_report.xml index 6a230a56a68..1e1e6fc8916 100644 --- a/addons/account/account_report.xml +++ b/addons/account/account_report.xml @@ -59,12 +59,14 @@ model="res.partner" name="account.rappel" rml="account/report/rappel.rml" + sxw="account/report/rappel.sxw" auto="False" /> +# +# WARNING: This program as such is intended to be used by professional +# programmers who take the whole responsability of assessing all potential +# consequences resulting from its eventual inadequacies and bugs +# End users who are looking for a ready-to-use solution with commercial +# garantees and support are strongly adviced to contract a Free Software +# Service Company +# +# This program is Free Software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +# +############################################################################## + +import account_simulation +import wizard diff --git a/addons/base_report_designer/__terp__.py b/addons/base_report_designer/__terp__.py new file mode 100644 index 00000000000..5b5a58aa5db --- /dev/null +++ b/addons/base_report_designer/__terp__.py @@ -0,0 +1,20 @@ +{ + "name" : "Report designer interface module", + "description" : """ +This module adds wizards to import/export documents to be edited in +OpenOffice. +""", + "version" : "1.0", + "depends" : ["account"], + "author" : "Tiny", + "website" : "http://tinyerp.com", + "category" : "Generic Modules/Base", + "init_xml" : [ ], + "demo_xml" : [ ], + "update_xml" : [ "base_report_designer_wizard.xml" ], +# "translations" : { +# "fr": "i18n/french_fr.csv" +# }, + "active": False, + "installable": True +} diff --git a/addons/base_report_designer/base_report_designer_wizard.xml b/addons/base_report_designer/base_report_designer_wizard.xml new file mode 100644 index 00000000000..ee2ede762cb --- /dev/null +++ b/addons/base_report_designer/base_report_designer_wizard.xml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + diff --git a/addons/base_report_designer/wizard/__init__.py b/addons/base_report_designer/wizard/__init__.py new file mode 100644 index 00000000000..b3bb16434f6 --- /dev/null +++ b/addons/base_report_designer/wizard/__init__.py @@ -0,0 +1,29 @@ +############################################################################## +# +# Copyright (c) 2004 TINY SPRL. (http://tiny.be) All Rights Reserved. +# Fabien Pinckaers +# +# WARNING: This program as such is intended to be used by professional +# programmers who take the whole responsability of assessing all potential +# consequences resulting from its eventual inadequacies and bugs +# End users who are looking for a ready-to-use solution with commercial +# garantees and support are strongly adviced to contract a Free Software +# Service Company +# +# This program is Free Software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +# +############################################################################## + +import base_report_designer_modify diff --git a/addons/base_report_designer/wizard/base_report_designer_modify.py b/addons/base_report_designer/wizard/base_report_designer_modify.py new file mode 100644 index 00000000000..3bb949c1d06 --- /dev/null +++ b/addons/base_report_designer/wizard/base_report_designer_modify.py @@ -0,0 +1,221 @@ +############################################################################## +# +# Copyright (c) 2005-2006 TINY SPRL. (http://tiny.be) All Rights Reserved. +# +# WARNING: This program as such is intended to be used by professional +# programmers who take the whole responsability of assessing all potential +# consequences resulting from its eventual inadequacies and bugs +# End users who are looking for a ready-to-use solution with commercial +# garantees and support are strongly adviced to contract a Free Software +# Service Company +# +# This program is Free Software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +# +############################################################################## + +import time +import wizard +import osv +import pooler +import urllib +import base64 +import tools + +intro_form = ''' +
+ + +''' + +intro_fields = { + 'text': { + 'string':'Introduction', + 'type':'text', + 'readonly':True, + 'default': lambda *args: """ +This system must be used with the Tiny OpenOffice plugin. If you +did not installed yet, you can find this package on: + http://tinyerp.com + +This wizard will provide you the .SXW report that you can modify +in OpenOffice. After having modified it, you will be able to reupload +it to the Tiny ERP server. +"""}, + 'operation': { + 'string':'Operation', + 'type':'selection', + 'selection':[('create','Create a new report'),('modify','Modify an existing report')], + 'size':32, + 'required':True, + 'default':lambda *args: 'create' + }, +} + +get_form = ''' +
+ + +''' + +get_fields = { + 'report_id': { + 'string':'Report', + 'type':'many2one', + 'relation':'ir.actions.report.xml', + 'required':True, + 'domain': [('report_sxw_content','<>',False)] + }, +} + +get_form_result = ''' +
+ + + + + +