Merge commit 'origin/master' into mdv-gpl3
Conflicts: bin/tools/convert.py bzr revid: p_christ@hol.gr-20081025224421-g367ati5b2eeplw6 bzr revid: p_christ@hol.gr-20081104201238-oy0vgsunt2jxgu2p
This commit is contained in:
commit
8220e0ad02
|
@ -1,14 +1,14 @@
|
||||||
Metadata-Version: 1.1
|
Metadata-Version: 1.1
|
||||||
Name: OpenERP
|
Name: OpenERP
|
||||||
Version: 4.3.99
|
Version: 5.0.0-alpha
|
||||||
Author: Tiny.be
|
Author: Tiny.be
|
||||||
Author-email: fp at tiny be
|
Author-email: fp at tiny be
|
||||||
Maintainer: Tiny.be
|
Maintainer: Tiny.be
|
||||||
Maintainer-email: fp at tiny be
|
Maintainer-email: fp at tiny be
|
||||||
Home-page: http://tiny.be
|
Home-page: http://openerp.com
|
||||||
Download-url: http://openerp.com/downloads.html
|
Download-url: http://openerp.com/downloads.html
|
||||||
Summary: OpenERP is an Enterprise Resource Management written entirely in python.
|
Summary: OpenERP is an Enterprise Resource Management written entirely in python.
|
||||||
License: GPL
|
License: GPL-3
|
||||||
Description: OpenERP is a complete ERP and CRM. The main features are accounting (analytic
|
Description: OpenERP is a complete ERP and CRM. The main features are accounting (analytic
|
||||||
and financial), stock management, sales and purchases management, tasks
|
and financial), stock management, sales and purchases management, tasks
|
||||||
automation, marketing campaigns, help desk, POS, etc. Technical features include
|
automation, marketing campaigns, help desk, POS, etc. Technical features include
|
||||||
|
|
|
@ -1,33 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
|
||||||
#
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
|
|
||||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be)
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contact a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -142,6 +134,8 @@ def get_module_path(module):
|
||||||
if os.path.exists(opj(_ad, module)) or os.path.exists(opj(_ad, '%s.zip' % module)):
|
if os.path.exists(opj(_ad, module)) or os.path.exists(opj(_ad, '%s.zip' % module)):
|
||||||
return opj(_ad, module)
|
return opj(_ad, module)
|
||||||
|
|
||||||
|
logger.notifyChannel('init', netsvc.LOG_WARNING, 'addon:%s:module not found' % (module,))
|
||||||
|
return False
|
||||||
raise IOError, 'Module not found : %s' % module
|
raise IOError, 'Module not found : %s' % module
|
||||||
|
|
||||||
def get_module_resource(module, *args):
|
def get_module_resource(module, *args):
|
||||||
|
@ -152,7 +146,8 @@ def get_module_resource(module, *args):
|
||||||
|
|
||||||
@return: absolute path to the resource
|
@return: absolute path to the resource
|
||||||
"""
|
"""
|
||||||
return opj(get_module_path(module), *args)
|
a = get_module_path(module)
|
||||||
|
return a and opj(a, *args) or False
|
||||||
|
|
||||||
def get_modules():
|
def get_modules():
|
||||||
"""Returns the list of module names
|
"""Returns the list of module names
|
||||||
|
@ -175,9 +170,12 @@ def create_graph(module_list, force=None):
|
||||||
module = module[:-4]
|
module = module[:-4]
|
||||||
try:
|
try:
|
||||||
mod_path = get_module_path(module)
|
mod_path = get_module_path(module)
|
||||||
|
if not mod_path:
|
||||||
|
continue
|
||||||
except IOError:
|
except IOError:
|
||||||
continue
|
continue
|
||||||
terp_file = get_module_resource(module, '__terp__.py')
|
terp_file = get_module_resource(module, '__terp__.py')
|
||||||
|
if not terp_file: continue
|
||||||
if os.path.isfile(terp_file) or zipfile.is_zipfile(mod_path):
|
if os.path.isfile(terp_file) or zipfile.is_zipfile(mod_path):
|
||||||
try:
|
try:
|
||||||
info = eval(tools.file_open(terp_file).read())
|
info = eval(tools.file_open(terp_file).read())
|
||||||
|
@ -282,9 +280,10 @@ def load_module_graph(cr, graph, status=None, **kwargs):
|
||||||
|
|
||||||
# Update translations for all installed languages
|
# Update translations for all installed languages
|
||||||
modobj = pool.get('ir.module.module')
|
modobj = pool.get('ir.module.module')
|
||||||
modobj.update_translations(cr, 1, [mid], None)
|
if modobj:
|
||||||
|
modobj.update_translations(cr, 1, [mid], None)
|
||||||
cr.commit()
|
cr.commit()
|
||||||
|
|
||||||
statusi+=1
|
statusi+=1
|
||||||
|
|
||||||
cr.execute("""select model,name from ir_model where id not in (select model_id from ir_model_access)""")
|
cr.execute("""select model,name from ir_model where id not in (select model_id from ir_model_access)""")
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,32 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
# Copyright (c) 2008 Camptocamp SA
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
{
|
{
|
||||||
"name" : "Base",
|
"name" : "Base",
|
||||||
"version" : "1.0",
|
"version" : "1.0",
|
||||||
|
|
|
@ -78,8 +78,8 @@
|
||||||
<form string="Users">
|
<form string="Users">
|
||||||
<field name="password" password="True"/>
|
<field name="password" password="True"/>
|
||||||
<label colspan="4" string="Please note that you will have to logout and relog if you change your password."/>
|
<label colspan="4" string="Please note that you will have to logout and relog if you change your password."/>
|
||||||
<field name="context_lang"/>
|
<field name="context_lang" completion="1"/>
|
||||||
<field name="context_tz"/>
|
<field name="context_tz" completion="1"/>
|
||||||
<newline/>
|
<newline/>
|
||||||
<field colspan="4" name="signature"/>
|
<field colspan="4" name="signature"/>
|
||||||
</form>
|
</form>
|
||||||
|
@ -198,15 +198,17 @@
|
||||||
<field colspan="4" name="signature"/>
|
<field colspan="4" name="signature"/>
|
||||||
</page>
|
</page>
|
||||||
<page string="Groups">
|
<page string="Groups">
|
||||||
|
<label string="Groups are used to defined access rights on each screen and menu." align="0.0" colspan="4"/>
|
||||||
<field colspan="4" nolabel="1" name="groups_id"/>
|
<field colspan="4" nolabel="1" name="groups_id"/>
|
||||||
</page>
|
</page>
|
||||||
<page string="Roles">
|
<page string="Roles">
|
||||||
|
<label string="Roles are used to defined available actions, provided by workflows." align="0.0" colspan="4"/>
|
||||||
<field colspan="4" nolabel="1" name="roles_id"/>
|
<field colspan="4" nolabel="1" name="roles_id"/>
|
||||||
</page>
|
</page>
|
||||||
</notebook>
|
</notebook>
|
||||||
<label string="" colspan="2"/>
|
<label string="" colspan="2"/>
|
||||||
<group col="2" colspan="2">
|
<group col="2" colspan="2">
|
||||||
<button icon='gtk-cancel' special="cancel" name="action_next" type='object' string='Close'/>
|
<button icon='gtk-cancel' special="cancel" name="action_next" type='object' string='Skip'/>
|
||||||
<button name='action_new' icon='gtk-ok' type='object' string='Add User'/>
|
<button name='action_new' icon='gtk-ok' type='object' string='Add User'/>
|
||||||
</group>
|
</group>
|
||||||
</form>
|
</form>
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -281,6 +281,7 @@
|
||||||
</tree>
|
</tree>
|
||||||
</field>
|
</field>
|
||||||
<field colspan="4" name="domain"/>
|
<field colspan="4" name="domain"/>
|
||||||
|
<field colspan="4" name="context"/>
|
||||||
<field name="limit"/>
|
<field name="limit"/>
|
||||||
<field name="auto_refresh"/>
|
<field name="auto_refresh"/>
|
||||||
<newline/>
|
<newline/>
|
||||||
|
@ -648,11 +649,14 @@
|
||||||
<group colspan="2" col="2">
|
<group colspan="2" col="2">
|
||||||
<separator string="Field Type" colspan="2"/>
|
<separator string="Field Type" colspan="2"/>
|
||||||
<field name="ttype" select="2"/>
|
<field name="ttype" select="2"/>
|
||||||
<field name="relation" select="2"/>
|
<field name="relation" select="2" attrs="{'required': [('ttype','in',['many2one','one2many','many2many'])],
|
||||||
<field name="selection"/>
|
'readonly': [('ttype','not in', ['many2one','one2many','many2many'])]}"/>
|
||||||
<field name="size"/>
|
<field name="relation_field" attrs="{'required': [('ttype','=','one2many')],
|
||||||
|
'readonly': [('ttype','!=','one2many')]}"/>
|
||||||
|
<field name="selection" attrs="{'required': [('ttype','=','selection')], 'readonly': [('ttype','!=','selection')]}"/>
|
||||||
|
<field name="size" attrs="{'required': [('ttype','=','char')], 'readonly': [('ttype','!=','char')]}"/>
|
||||||
<field name="state"/>
|
<field name="state"/>
|
||||||
<field name="domain"/>
|
<field name="domain" attrs="{'readonly': [('relation','=','')]}"/>
|
||||||
</group>
|
</group>
|
||||||
|
|
||||||
<group colspan="2" col="2">
|
<group colspan="2" col="2">
|
||||||
|
@ -661,8 +665,7 @@
|
||||||
<field name="readonly" select="2"/>
|
<field name="readonly" select="2"/>
|
||||||
<field name="select_level"/>
|
<field name="select_level"/>
|
||||||
<field name="translate"/>
|
<field name="translate"/>
|
||||||
<field name="relate"/>
|
<field name="on_delete" attrs="{'readonly': [('ttype','!=','many2one')]}"/>
|
||||||
<field name="on_delete"/>
|
|
||||||
</group>
|
</group>
|
||||||
<separator string="Security on Groups" colspan="4"/>
|
<separator string="Security on Groups" colspan="4"/>
|
||||||
<field name="groups" colspan="4" nolabel="1"/>
|
<field name="groups" colspan="4" nolabel="1"/>
|
||||||
|
@ -725,11 +728,14 @@
|
||||||
<page string="Properties">
|
<page string="Properties">
|
||||||
<group colspan="2" col="2">
|
<group colspan="2" col="2">
|
||||||
<field name="ttype" select="2"/>
|
<field name="ttype" select="2"/>
|
||||||
<field name="relation" select="2"/>
|
<field name="relation" select="2" attrs="{'required': [('ttype','in', ['many2one','one2many','many2many'])],
|
||||||
<field name="selection"/>
|
'readonly': [('ttype','not in', ['many2one','one2many','many2many'])]}"/>
|
||||||
<field name="size"/>
|
<field name="relation_field" attrs="{'required': [('ttype','=','one2many')],
|
||||||
|
'readonly': [('ttype','!=','one2many')]}"/>
|
||||||
|
<field name="selection" attrs="{'required': [('ttype','=','selection')], 'readonly': [('ttype','!=','selection')]}"/>
|
||||||
|
<field name="size" attrs="{'required': [('ttype','=','char')], 'readonly': [('ttype','!=','char')]}"/>
|
||||||
<field name="state"/>
|
<field name="state"/>
|
||||||
<field name="domain"/>
|
<field name="domain" attrs="{'readonly': [('relation','=','')]}"/>
|
||||||
</group>
|
</group>
|
||||||
|
|
||||||
<group colspan="2" col="2">
|
<group colspan="2" col="2">
|
||||||
|
@ -737,8 +743,7 @@
|
||||||
<field name="readonly" select="2"/>
|
<field name="readonly" select="2"/>
|
||||||
<field name="select_level"/>
|
<field name="select_level"/>
|
||||||
<field name="translate"/>
|
<field name="translate"/>
|
||||||
<field name="relate"/>
|
<field name="on_delete" attrs="{'readonly': [('ttype','!=','many2one')]}"/>
|
||||||
<field name="on_delete"/>
|
|
||||||
</group>
|
</group>
|
||||||
</page>
|
</page>
|
||||||
<page string="Security on Groups" colspan="4">
|
<page string="Security on Groups" colspan="4">
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -185,7 +177,7 @@ class act_window(osv.osv):
|
||||||
|
|
||||||
if 'calendar' not in modes:
|
if 'calendar' not in modes:
|
||||||
mobj = self.pool.get(act.res_model)
|
mobj = self.pool.get(act.res_model)
|
||||||
if mobj._date_name in mobj._columns:
|
if hasattr(mobj, '_date_name') and mobj._date_name in mobj._columns:
|
||||||
res[act.id].append((False, 'calendar'))
|
res[act.id].append((False, 'calendar'))
|
||||||
return res
|
return res
|
||||||
|
|
||||||
|
@ -298,13 +290,12 @@ def model_get(self, cr, uid, context={}):
|
||||||
|
|
||||||
class ir_model_fields(osv.osv):
|
class ir_model_fields(osv.osv):
|
||||||
_inherit = 'ir.model.fields'
|
_inherit = 'ir.model.fields'
|
||||||
_rec_name = 'complete_name'
|
_rec_name = 'field_description'
|
||||||
_columns = {
|
_columns = {
|
||||||
'complete_name': fields.char('Complete Name', required=True, size=64, select=1),
|
'complete_name': fields.char('Complete Name', required=True, size=64, select=1),
|
||||||
}
|
}
|
||||||
|
|
||||||
def name_search(self, cr, uid, name, args=None, operator='ilike', context=None, limit=80):
|
def name_search(self, cr, uid, name, args=None, operator='ilike', context=None, limit=80):
|
||||||
|
|
||||||
def get_fields(cr, uid, field, rel):
|
def get_fields(cr, uid, field, rel):
|
||||||
result = []
|
result = []
|
||||||
mobj = self.pool.get('ir.model')
|
mobj = self.pool.get('ir.model')
|
||||||
|
@ -501,9 +492,11 @@ class actions_server(osv.osv):
|
||||||
if action.state == 'email':
|
if action.state == 'email':
|
||||||
user = config['email_from']
|
user = config['email_from']
|
||||||
subject = action.name
|
subject = action.name
|
||||||
|
address = self.get_field_value(cr, uid, action, context)
|
||||||
address = self.get_field_value(cr, uid, str(action.message), action, context)
|
if not address:
|
||||||
body = self.merge_message(cr, uid, action, context)
|
raise osv.except_osv(_('Error'), _("Please specify the Partner Email address !"))
|
||||||
|
|
||||||
|
body = self.merge_message(cr, uid, str(action.message), action, context)
|
||||||
|
|
||||||
if tools.email_send_attach(user, address, subject, body, debug=False) == True:
|
if tools.email_send_attach(user, address, subject, body, debug=False) == True:
|
||||||
logger.notifyChannel('email', netsvc.LOG_INFO, 'Email successfully send to : %s' % (address))
|
logger.notifyChannel('email', netsvc.LOG_INFO, 'Email successfully send to : %s' % (address))
|
||||||
|
@ -522,7 +515,7 @@ class actions_server(osv.osv):
|
||||||
# for the sms gateway user / password
|
# for the sms gateway user / password
|
||||||
api_id = ''
|
api_id = ''
|
||||||
text = action.sms
|
text = action.sms
|
||||||
to = self.get_field_value(cr, uid, str(action.message), action, context)
|
to = self.get_field_value(cr, uid, action, context)
|
||||||
#TODO: Apply message mearge with the field
|
#TODO: Apply message mearge with the field
|
||||||
if tools.sms_send(user, password, api_id, text, to) == True:
|
if tools.sms_send(user, password, api_id, text, to) == True:
|
||||||
logger.notifyChannel('sms', netsvc.LOG_INFO, 'SMS successfully send to : %s' % (action.address))
|
logger.notifyChannel('sms', netsvc.LOG_INFO, 'SMS successfully send to : %s' % (action.address))
|
||||||
|
@ -543,6 +536,7 @@ class actions_server(osv.osv):
|
||||||
exec code in localdict
|
exec code in localdict
|
||||||
if 'action' in localdict:
|
if 'action' in localdict:
|
||||||
return localdict['action']
|
return localdict['action']
|
||||||
|
|
||||||
if action.state == 'object_write':
|
if action.state == 'object_write':
|
||||||
res = {}
|
res = {}
|
||||||
for exp in action.fields_lines:
|
for exp in action.fields_lines:
|
||||||
|
|
|
@ -1,36 +1,101 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
from osv import fields,osv
|
from osv import fields,osv
|
||||||
|
from osv.orm import except_orm
|
||||||
|
import tools
|
||||||
|
|
||||||
class ir_attachment(osv.osv):
|
class ir_attachment(osv.osv):
|
||||||
|
|
||||||
|
def check(self, cr, uid, ids, mode):
|
||||||
|
if not ids:
|
||||||
|
return
|
||||||
|
ima = self.pool.get('ir.model.access')
|
||||||
|
if isinstance(ids, (int, long)):
|
||||||
|
ids = [ids]
|
||||||
|
objs = self.browse(cr, uid, ids) or []
|
||||||
|
for o in objs:
|
||||||
|
if o and o.res_model:
|
||||||
|
ima.check(cr, uid, o.res_model, mode)
|
||||||
|
|
||||||
|
check = tools.cache()(check)
|
||||||
|
|
||||||
|
def search(self, cr, uid, args, offset=0, limit=None, order=None,
|
||||||
|
context=None, count=False):
|
||||||
|
ids = super(ir_attachment, self).search(cr, uid, args, offset=offset,
|
||||||
|
limit=limit, order=order,
|
||||||
|
context=context, count=False)
|
||||||
|
if not ids:
|
||||||
|
if count:
|
||||||
|
return 0
|
||||||
|
return []
|
||||||
|
models = super(ir_attachment,self).read(cr, uid, ids, ['id', 'res_model'])
|
||||||
|
cache = {}
|
||||||
|
ima = self.pool.get('ir.model.access')
|
||||||
|
for m in models:
|
||||||
|
if m['res_model'] in cache:
|
||||||
|
if not cache[m['res_model']]:
|
||||||
|
ids.remove(m['id'])
|
||||||
|
continue
|
||||||
|
cache[m['res_model']] = ima.check(cr, uid, m['res_model'], 'read',
|
||||||
|
raise_exception=False)
|
||||||
|
|
||||||
|
if count:
|
||||||
|
return len(ids)
|
||||||
|
return ids
|
||||||
|
|
||||||
|
def read(self, cr, uid, ids, *args, **kwargs):
|
||||||
|
self.check(cr, uid, ids, 'read')
|
||||||
|
return super(ir_attachment, self).read(cr, uid, ids, *args, **kwargs)
|
||||||
|
|
||||||
|
def write(self, cr, uid, ids, *args, **kwargs):
|
||||||
|
self.check(cr, uid, ids, 'write')
|
||||||
|
return super(ir_attachment, self).write(cr, uid, ids, *args, **kwargs)
|
||||||
|
|
||||||
|
def copy(self, cr, uid, id, *args, **kwargs):
|
||||||
|
self.check(cr, uid, [id], 'write')
|
||||||
|
return super(ir_attachment, self).copy(cr, uid, id, *args, **kwargs)
|
||||||
|
|
||||||
|
def unlink(self, cr, uid, ids, *args, **kwargs):
|
||||||
|
self.check(cr, uid, ids, 'unlink')
|
||||||
|
return super(ir_attachment, self).unlink(cr, uid, ids, *args, **kwargs)
|
||||||
|
|
||||||
|
def create(self, cr, uid, values, *args, **kwargs):
|
||||||
|
if 'res_model' in values and values['res_model'] != '':
|
||||||
|
self.pool.get('ir.model.access').check(cr, uid, values['res_model'], 'create')
|
||||||
|
return super(ir_attachment, self).create(cr, uid, values, *args, **kwargs)
|
||||||
|
|
||||||
|
def clear_cache(self):
|
||||||
|
self.check()
|
||||||
|
|
||||||
|
def __init__(self, *args, **kwargs):
|
||||||
|
r = super(ir_attachment, self).__init__(*args, **kwargs)
|
||||||
|
self.pool.get('ir.model.access').register_cache_clearing_method(self._name, 'clear_cache')
|
||||||
|
return r
|
||||||
|
|
||||||
|
def __del__(self):
|
||||||
|
self.pool.get('ir.model.access').unregister_cache_clearing_method(self._name, 'clear_cache')
|
||||||
|
return super(ir_attachment, self).__del__()
|
||||||
|
|
||||||
_name = 'ir.attachment'
|
_name = 'ir.attachment'
|
||||||
_columns = {
|
_columns = {
|
||||||
'name': fields.char('Attachment Name',size=64, required=True),
|
'name': fields.char('Attachment Name',size=64, required=True),
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,42 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
|
||||||
# SPEC: Execute "model.function(*eval(args))" periodically
|
|
||||||
# date : date to execute the job or NULL if directly
|
|
||||||
# delete_after: delete the ir.cron entry after execution
|
|
||||||
# interval_* : period
|
|
||||||
# max_repeat : number of execution or NULL if endlessly
|
|
||||||
#
|
|
||||||
# TODO:
|
|
||||||
# Error treatment: exception, request, ... -> send request to uid
|
|
||||||
#
|
|
||||||
|
|
||||||
from mx import DateTime
|
from mx import DateTime
|
||||||
import time
|
import time
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -54,6 +46,3 @@ class ir_default(osv.osv):
|
||||||
}
|
}
|
||||||
ir_default()
|
ir_default()
|
||||||
|
|
||||||
|
|
||||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
# Copyright (c) 2008 Camptocamp SA
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -72,7 +64,7 @@ class ir_model(osv.osv):
|
||||||
def unlink(self, cr, user, ids, context=None):
|
def unlink(self, cr, user, ids, context=None):
|
||||||
for model in self.browse(cr, user, ids, context):
|
for model in self.browse(cr, user, ids, context):
|
||||||
if model.state <> 'manual':
|
if model.state <> 'manual':
|
||||||
raise except_orm(_('Error'), _("You can not remove the model '%s' !") %(field.name,))
|
raise except_orm(_('Error'), _("You can not remove the model '%s' !") %(model.name,))
|
||||||
res = super(ir_model, self).unlink(cr, user, ids, context)
|
res = super(ir_model, self).unlink(cr, user, ids, context)
|
||||||
pooler.restart_pool(cr.dbname)
|
pooler.restart_pool(cr.dbname)
|
||||||
return res
|
return res
|
||||||
|
@ -162,8 +154,8 @@ class ir_model_grid(osv.osv):
|
||||||
'model_id':model_id,
|
'model_id':model_id,
|
||||||
'group_id':group_id
|
'group_id':group_id
|
||||||
}) ]
|
}) ]
|
||||||
vals = dict(map(lambda x: ('perm_'+x, x[0] in (vals[val] or '')), perms_rel))
|
vals2 = dict(map(lambda x: ('perm_'+x, x[0] in (vals[val] or '')), perms_rel))
|
||||||
acc_obj.write(cr, uid, rules, vals, context=context)
|
acc_obj.write(cr, uid, rules, vals2, context=context)
|
||||||
return True
|
return True
|
||||||
|
|
||||||
def fields_get(self, cr, uid, fields=None, context=None, read_access=True):
|
def fields_get(self, cr, uid, fields=None, context=None, read_access=True):
|
||||||
|
@ -182,8 +174,8 @@ class ir_model_grid(osv.osv):
|
||||||
cols = ['model', 'name']
|
cols = ['model', 'name']
|
||||||
xml = '''<?xml version="1.0"?>
|
xml = '''<?xml version="1.0"?>
|
||||||
<%s editable="bottom">
|
<%s editable="bottom">
|
||||||
<field name="name" select="1" readonly="1"/>
|
<field name="name" select="1" readonly="1" required="1"/>
|
||||||
<field name="model" select="1" readonly="1"/>
|
<field name="model" select="1" readonly="1" required="1"/>
|
||||||
<field name="group_0"/>
|
<field name="group_0"/>
|
||||||
''' % (view_type,)
|
''' % (view_type,)
|
||||||
for group in groups_br:
|
for group in groups_br:
|
||||||
|
@ -201,10 +193,9 @@ class ir_model_fields(osv.osv):
|
||||||
'name': fields.char('Name', required=True, size=64, select=1),
|
'name': fields.char('Name', required=True, size=64, select=1),
|
||||||
'model': fields.char('Object Name', size=64, required=True),
|
'model': fields.char('Object Name', size=64, required=True),
|
||||||
'relation': fields.char('Object Relation', size=64),
|
'relation': fields.char('Object Relation', size=64),
|
||||||
|
'relation_field': fields.char('Relation Field', size=64),
|
||||||
'model_id': fields.many2one('ir.model', 'Object id', required=True, select=True, ondelete='cascade'),
|
'model_id': fields.many2one('ir.model', 'Object id', required=True, select=True, ondelete='cascade'),
|
||||||
'field_description': fields.char('Field Label', required=True, size=256),
|
'field_description': fields.char('Field Label', required=True, size=256),
|
||||||
'relate': fields.boolean('Click and Relate'),
|
|
||||||
|
|
||||||
'ttype': fields.selection(_get_fields_type, 'Field Type',size=64, required=True),
|
'ttype': fields.selection(_get_fields_type, 'Field Type',size=64, required=True),
|
||||||
'selection': fields.char('Field Selection',size=128),
|
'selection': fields.char('Field Selection',size=128),
|
||||||
'required': fields.boolean('Required'),
|
'required': fields.boolean('Required'),
|
||||||
|
@ -212,15 +203,14 @@ class ir_model_fields(osv.osv):
|
||||||
'select_level': fields.selection([('0','Not Searchable'),('1','Always Searchable'),('2','Advanced Search')],'Searchable', required=True),
|
'select_level': fields.selection([('0','Not Searchable'),('1','Always Searchable'),('2','Advanced Search')],'Searchable', required=True),
|
||||||
'translate': fields.boolean('Translate'),
|
'translate': fields.boolean('Translate'),
|
||||||
'size': fields.integer('Size'),
|
'size': fields.integer('Size'),
|
||||||
'state': fields.selection([('manual','Custom Field'),('base','Base Field')],'Manualy Created'),
|
'state': fields.selection([('manual','Custom Field'),('base','Base Field')],'Manualy Created', required=True, readonly=True),
|
||||||
'on_delete': fields.selection([('cascade','Cascade'),('set null','Set NULL')], 'On delete', help='On delete property for many2one fields'),
|
'on_delete': fields.selection([('cascade','Cascade'),('set null','Set NULL')], 'On delete', help='On delete property for many2one fields'),
|
||||||
'domain': fields.char('Domain', size=256),
|
'domain': fields.char('Domain', size=256),
|
||||||
|
|
||||||
'groups': fields.many2many('res.groups', 'ir_model_fields_group_rel', 'field_id', 'group_id', 'Groups'),
|
'groups': fields.many2many('res.groups', 'ir_model_fields_group_rel', 'field_id', 'group_id', 'Groups'),
|
||||||
'view_load': fields.boolean('View Auto-Load'),
|
'view_load': fields.boolean('View Auto-Load'),
|
||||||
}
|
}
|
||||||
|
_rec_name='field_description'
|
||||||
_defaults = {
|
_defaults = {
|
||||||
'relate': lambda *a: 0,
|
|
||||||
'view_load': lambda *a: 0,
|
'view_load': lambda *a: 0,
|
||||||
'selection': lambda *a: "[]",
|
'selection': lambda *a: "[]",
|
||||||
'domain': lambda *a: "[]",
|
'domain': lambda *a: "[]",
|
||||||
|
@ -278,13 +268,43 @@ class ir_model_access(osv.osv):
|
||||||
cr.execute("select 1 from res_groups_users_rel where uid=%d and gid in(select res_id from ir_model_data where module=%s and name=%s)", (uid, grouparr[0], grouparr[1],))
|
cr.execute("select 1 from res_groups_users_rel where uid=%d and gid in(select res_id from ir_model_data where module=%s and name=%s)", (uid, grouparr[0], grouparr[1],))
|
||||||
return bool(cr.fetchone())
|
return bool(cr.fetchone())
|
||||||
|
|
||||||
def check_groups_by_id(self, cr, uid, group_id):
|
def check_group(self, cr, uid, model, mode, group_ids):
|
||||||
cr.execute("select 1 from res_groups_users_rel where uid=%i and gid=%i", (uid, group_id,))
|
""" Check if a specific group has the access mode to the specified model"""
|
||||||
return bool(cr.fetchone())
|
assert mode in ['read','write','create','unlink'], 'Invalid access mode'
|
||||||
|
|
||||||
|
if isinstance(model, browse_record):
|
||||||
|
assert model._table_name == 'ir.model', 'Invalid model object'
|
||||||
|
model_name = model.name
|
||||||
|
else:
|
||||||
|
model_name = model
|
||||||
|
|
||||||
|
if isinstance(group_ids, (int, long)):
|
||||||
|
group_ids = [group_ids]
|
||||||
|
for group_id in group_ids:
|
||||||
|
cr.execute("SELECT perm_" + mode + " "
|
||||||
|
" FROM ir_model_access a "
|
||||||
|
" JOIN ir_model m ON (m.id = a.model_id) "
|
||||||
|
" WHERE m.model = %s AND a.group_id = %d", (model_name, group_id)
|
||||||
|
)
|
||||||
|
r = cr.fetchone()
|
||||||
|
if r is None:
|
||||||
|
cr.execute("SELECT perm_" + mode + " "
|
||||||
|
" FROM ir_model_access a "
|
||||||
|
" JOIN ir_model m ON (m.id = a.model_id) "
|
||||||
|
" WHERE m.model = %s AND a.group_id IS NULL", (model_name, )
|
||||||
|
)
|
||||||
|
r = cr.fetchone()
|
||||||
|
|
||||||
|
access = bool(r and r[0])
|
||||||
|
if access:
|
||||||
|
return True
|
||||||
|
# pass no groups -> no access
|
||||||
|
return False
|
||||||
|
|
||||||
def check(self, cr, uid, model, mode='read', raise_exception=True):
|
def check(self, cr, uid, model, mode='read', raise_exception=True):
|
||||||
# Users root have all access (Todo: exclude xml-rpc requests)
|
|
||||||
if uid==1:
|
if uid==1:
|
||||||
|
# User root have all accesses
|
||||||
|
# TODO: exclude xml-rpc requests
|
||||||
return True
|
return True
|
||||||
|
|
||||||
assert mode in ['read','write','create','unlink'], 'Invalid access mode'
|
assert mode in ['read','write','create','unlink'], 'Invalid access mode'
|
||||||
|
@ -329,27 +349,42 @@ class ir_model_access(osv.osv):
|
||||||
|
|
||||||
check = tools.cache()(check)
|
check = tools.cache()(check)
|
||||||
|
|
||||||
|
__cache_clearing_methods = []
|
||||||
|
|
||||||
|
def register_cache_clearing_method(self, model, method):
|
||||||
|
self.__cache_clearing_methods.append((model, method))
|
||||||
|
|
||||||
|
def unregister_cache_clearing_method(self, model, method):
|
||||||
|
try:
|
||||||
|
i = self.__cache_clearing_methods.index((model, method))
|
||||||
|
del self.__cache_clearing_methods[i]
|
||||||
|
except ValueError:
|
||||||
|
pass
|
||||||
|
|
||||||
|
def call_cache_clearing_methods(self):
|
||||||
|
for model, method in self.__cache_clearing_methods:
|
||||||
|
getattr(self.pool.get(model), method)()
|
||||||
|
|
||||||
#
|
#
|
||||||
# Check rights on actions
|
# Check rights on actions
|
||||||
#
|
#
|
||||||
def write(self, cr, uid, *args, **argv):
|
def write(self, cr, uid, *args, **argv):
|
||||||
self.pool.get('ir.ui.menu').clear_cache()
|
self.call_cache_clearing_methods()
|
||||||
res = super(ir_model_access, self).write(cr, uid, *args, **argv)
|
res = super(ir_model_access, self).write(cr, uid, *args, **argv)
|
||||||
self.check()
|
self.check() # clear the cache of check function
|
||||||
return res
|
return res
|
||||||
|
|
||||||
def create(self, cr, uid, *args, **argv):
|
def create(self, cr, uid, *args, **argv):
|
||||||
res = super(ir_model_access, self).create(cr, uid, *args, **argv)
|
res = super(ir_model_access, self).create(cr, uid, *args, **argv)
|
||||||
self.check()
|
self.check()
|
||||||
return res
|
return res
|
||||||
|
|
||||||
def unlink(self, cr, uid, *args, **argv):
|
def unlink(self, cr, uid, *args, **argv):
|
||||||
self.pool.get('ir.ui.menu').clear_cache()
|
self.call_cache_clearing_methods()
|
||||||
res = super(ir_model_access, self).unlink(cr, uid, *args, **argv)
|
res = super(ir_model_access, self).unlink(cr, uid, *args, **argv)
|
||||||
self.check()
|
self.check()
|
||||||
return res
|
return res
|
||||||
def read(self, cr, uid, *args, **argv):
|
|
||||||
res = super(ir_model_access, self).read(cr, uid, *args, **argv)
|
|
||||||
self.check()
|
|
||||||
return res
|
|
||||||
ir_model_access()
|
ir_model_access()
|
||||||
|
|
||||||
class ir_model_data(osv.osv):
|
class ir_model_data(osv.osv):
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -160,7 +152,7 @@ class ir_translation(osv.osv, Cacheable):
|
||||||
|
|
||||||
def unlink(self, cursor, user, ids, context=None):
|
def unlink(self, cursor, user, ids, context=None):
|
||||||
self.clear()
|
self.clear()
|
||||||
return super(ir_translation, self).unlink(cusor, user, ids,
|
return super(ir_translation, self).unlink(cursor, user, ids,
|
||||||
context=context)
|
context=context)
|
||||||
|
|
||||||
def create(self, cursor, user, vals, context=None):
|
def create(self, cursor, user, vals, context=None):
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -61,7 +53,13 @@ class ir_ui_menu(osv.osv):
|
||||||
|
|
||||||
def __init__(self, *args, **kwargs):
|
def __init__(self, *args, **kwargs):
|
||||||
self._cache = {}
|
self._cache = {}
|
||||||
return super(ir_ui_menu, self).__init__(*args, **kwargs)
|
r = super(ir_ui_menu, self).__init__(*args, **kwargs)
|
||||||
|
self.pool.get('ir.model.access').register_cache_clearing_method(self._name, 'clear_cache')
|
||||||
|
return r
|
||||||
|
|
||||||
|
def __del__(self):
|
||||||
|
self.pool.get('ir.model.access').unregister_cache_clearing_method(self._name, 'clear_cache')
|
||||||
|
return super(ir_ui_menu, self).__del__()
|
||||||
|
|
||||||
def clear_cache(self):
|
def clear_cache(self):
|
||||||
# radical but this doesn't frequently happen
|
# radical but this doesn't frequently happen
|
||||||
|
@ -81,7 +79,7 @@ class ir_ui_menu(osv.osv):
|
||||||
return []
|
return []
|
||||||
|
|
||||||
modelaccess = self.pool.get('ir.model.access')
|
modelaccess = self.pool.get('ir.model.access')
|
||||||
user_groups = set(self.pool.get('res.users').read(cr, 1, uid)['groups_id'])
|
user_groups = set(self.pool.get('res.users').read(cr, 1, uid, ['groups_id'])['groups_id'])
|
||||||
result = []
|
result = []
|
||||||
for menu in self.browse(cr, uid, ids):
|
for menu in self.browse(cr, uid, ids):
|
||||||
# this key works because user access rights are all based on user's groups (cfr ir_model_access.check)
|
# this key works because user access rights are all based on user's groups (cfr ir_model_access.check)
|
||||||
|
@ -97,8 +95,11 @@ class ir_ui_menu(osv.osv):
|
||||||
restrict_to_groups = [g.id for g in menu.groups_id]
|
restrict_to_groups = [g.id for g in menu.groups_id]
|
||||||
if not user_groups.intersection(restrict_to_groups):
|
if not user_groups.intersection(restrict_to_groups):
|
||||||
continue
|
continue
|
||||||
|
result.append(menu.id)
|
||||||
|
self._cache[key] = True
|
||||||
|
continue
|
||||||
|
|
||||||
if menu.action: # FIXME elif ?
|
if menu.action:
|
||||||
# we check if the user has access to the action of the menu
|
# we check if the user has access to the action of the menu
|
||||||
m, oid = menu.action.split(',', 1)
|
m, oid = menu.action.split(',', 1)
|
||||||
data = self.pool.get(m).browse(cr, 1, int(oid))
|
data = self.pool.get(m).browse(cr, 1, int(oid))
|
||||||
|
@ -121,8 +122,8 @@ class ir_ui_menu(osv.osv):
|
||||||
# not displayed if there is no children
|
# not displayed if there is no children
|
||||||
continue
|
continue
|
||||||
|
|
||||||
self._cache[key] = True
|
|
||||||
result.append(menu.id)
|
result.append(menu.id)
|
||||||
|
self._cache[key] = True
|
||||||
|
|
||||||
if count:
|
if count:
|
||||||
return len(result)
|
return len(result)
|
||||||
|
@ -228,7 +229,8 @@ class ir_ui_menu(osv.osv):
|
||||||
'child_id' : fields.one2many('ir.ui.menu', 'parent_id','Child ids'),
|
'child_id' : fields.one2many('ir.ui.menu', 'parent_id','Child ids'),
|
||||||
'parent_id': fields.many2one('ir.ui.menu', 'Parent Menu', select=True),
|
'parent_id': fields.many2one('ir.ui.menu', 'Parent Menu', select=True),
|
||||||
'groups_id': many2many_unique('res.groups', 'ir_ui_menu_group_rel',
|
'groups_id': many2many_unique('res.groups', 'ir_ui_menu_group_rel',
|
||||||
'menu_id', 'gid', 'Groups'),
|
'menu_id', 'gid', 'Groups', help="If you put groups, the visibility of this menu will be based on these groups. "\
|
||||||
|
"If this field is empty, Open ERP will compute visibility based on the related object's read access."),
|
||||||
'complete_name': fields.function(_get_full_name, method=True,
|
'complete_name': fields.function(_get_full_name, method=True,
|
||||||
string='Complete Name', type='char', size=128),
|
string='Complete Name', type='char', size=128),
|
||||||
'icon': fields.selection(tools.icons, 'Icon', size=64),
|
'icon': fields.selection(tools.icons, 'Icon', size=64),
|
||||||
|
@ -240,8 +242,8 @@ class ir_ui_menu(osv.osv):
|
||||||
('ir.actions.report.xml', 'ir.actions.report.xml'),
|
('ir.actions.report.xml', 'ir.actions.report.xml'),
|
||||||
('ir.actions.act_window', 'ir.actions.act_window'),
|
('ir.actions.act_window', 'ir.actions.act_window'),
|
||||||
('ir.actions.wizard', 'ir.actions.wizard'),
|
('ir.actions.wizard', 'ir.actions.wizard'),
|
||||||
('ir.actions.url', 'ir.actions.act_url'),
|
('ir.actions.url', 'ir.actions.url'),
|
||||||
]),
|
]),
|
||||||
}
|
}
|
||||||
_defaults = {
|
_defaults = {
|
||||||
'icon' : lambda *a: 'STOCK_OPEN',
|
'icon' : lambda *a: 'STOCK_OPEN',
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -206,12 +198,9 @@ class ir_values(osv.osv):
|
||||||
keys.append(x[1])
|
keys.append(x[1])
|
||||||
if x[3]:
|
if x[3]:
|
||||||
model,id = x[2].split(',')
|
model,id = x[2].split(',')
|
||||||
try:
|
id = int(id)
|
||||||
id = int(id)
|
datas = self.pool.get(model).read(cr, uid, id, False, context)
|
||||||
datas = self.pool.get(model).read(cr, uid, [id], False, context)
|
if not datas:
|
||||||
except:
|
|
||||||
return False
|
|
||||||
if not len(datas):
|
|
||||||
#ir_del(cr, uid, x[0])
|
#ir_del(cr, uid, x[0])
|
||||||
return False
|
return False
|
||||||
def clean(x):
|
def clean(x):
|
||||||
|
@ -221,7 +210,7 @@ class ir_values(osv.osv):
|
||||||
if key in x:
|
if key in x:
|
||||||
del x[key]
|
del x[key]
|
||||||
return x
|
return x
|
||||||
datas = clean(datas[0])
|
datas = clean(datas)
|
||||||
else:
|
else:
|
||||||
datas = pickle.loads(x[2])
|
datas = pickle.loads(x[2])
|
||||||
if meta:
|
if meta:
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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 wizard_menu
|
import wizard_menu
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -38,7 +30,7 @@ action_type = '''<?xml version="1.0"?>
|
||||||
</form>'''
|
</form>'''
|
||||||
|
|
||||||
action_type_fields = {
|
action_type_fields = {
|
||||||
'type': {'string':"Start date",'type':'selection','required':True ,'selection':[('ir.actions.report.xml','Open Report')]},
|
'type': {'string':"Select Action Type",'type':'selection','required':True ,'selection':[('ir.actions.report.xml','Open Report')]},
|
||||||
}
|
}
|
||||||
|
|
||||||
report_action = '''<?xml version="1.0"?>
|
report_action = '''<?xml version="1.0"?>
|
||||||
|
@ -60,13 +52,7 @@ class create_action(wizard.interface):
|
||||||
|
|
||||||
rpt = reports.browse(cr, uid, form['report'])
|
rpt = reports.browse(cr, uid, form['report'])
|
||||||
|
|
||||||
action = """
|
action = """action = {"type": "ir.actions.report.xml","model":"%s","report_name": "%s","ids": context["active_ids"]}""" % (rpt.model, rpt.report_name)
|
||||||
action = {
|
|
||||||
'type': 'ir.actions.report.xml',
|
|
||||||
'model':'%s',
|
|
||||||
'report_name': '%s',
|
|
||||||
'ids': context['active_ids'],
|
|
||||||
}""" % (rpt.model, rpt.report_name)
|
|
||||||
|
|
||||||
obj = pool.get('ir.actions.server')
|
obj = pool.get('ir.actions.server')
|
||||||
obj.write(cr, uid, data['ids'], {'code':action})
|
obj.write(cr, uid, data['ids'], {'code':action})
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,31 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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 workflow
|
import workflow
|
||||||
import print_instance
|
import print_instance
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -132,10 +124,10 @@ class wkf_transition(osv.osv):
|
||||||
_table = "wkf_transition"
|
_table = "wkf_transition"
|
||||||
_name = "workflow.transition"
|
_name = "workflow.transition"
|
||||||
_log_access = False
|
_log_access = False
|
||||||
_rec_name = 'signal' #TODO: pas top mais bon...
|
_rec_name = 'signal'
|
||||||
_columns = {
|
_columns = {
|
||||||
'trigger_model': fields.char('Trigger Type', size=128),
|
'trigger_model': fields.char('Trigger Object', size=128),
|
||||||
'trigger_expr_id': fields.char('Trigger Expr ID', size=128),
|
'trigger_expr_id': fields.char('Trigger Expression', size=128),
|
||||||
'signal': fields.char('Signal (button Name)', size=64),
|
'signal': fields.char('Signal (button Name)', size=64),
|
||||||
'role_id': fields.many2one('res.roles', 'Role Required'),
|
'role_id': fields.many2one('res.roles', 'Role Required'),
|
||||||
'condition': fields.char('Condition', required=True, size=128),
|
'condition': fields.char('Condition', required=True, size=128),
|
||||||
|
@ -153,7 +145,7 @@ class wkf_instance(osv.osv):
|
||||||
_rec_name = 'res_type'
|
_rec_name = 'res_type'
|
||||||
_log_access = False
|
_log_access = False
|
||||||
_columns = {
|
_columns = {
|
||||||
'wkf_id': fields.many2one('workflow', 'Workflow', ondelete='restrict', select=True),
|
'wkf_id': fields.many2one('workflow', 'Workflow', ondelete='cascade', select=True),
|
||||||
'uid': fields.integer('User ID'),
|
'uid': fields.integer('User ID'),
|
||||||
'res_id': fields.integer('Resource ID', select=True),
|
'res_id': fields.integer('Resource ID', select=True),
|
||||||
'res_type': fields.char('Resource Object', size=64, select=True),
|
'res_type': fields.char('Resource Object', size=64, select=True),
|
||||||
|
|
|
@ -43,13 +43,13 @@
|
||||||
<field name="view_id" ref="view_workflow_tree"/>
|
<field name="view_id" ref="view_workflow_tree"/>
|
||||||
</record>
|
</record>
|
||||||
<menuitem action="action_workflow_form" id="menu_workflow" parent="base.menu_workflow_root"/>
|
<menuitem action="action_workflow_form" id="menu_workflow" parent="base.menu_workflow_root"/>
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
================================
|
================================
|
||||||
Activities
|
Activities
|
||||||
================================
|
================================
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<record id="view_workflow_activity_form" model="ir.ui.view">
|
<record id="view_workflow_activity_form" model="ir.ui.view">
|
||||||
<field name="name">workflow.activity.form</field>
|
<field name="name">workflow.activity.form</field>
|
||||||
<field name="model">workflow.activity</field>
|
<field name="model">workflow.activity</field>
|
||||||
|
@ -59,9 +59,9 @@
|
||||||
<field colspan="4" name="name" select="1"/>
|
<field colspan="4" name="name" select="1"/>
|
||||||
<field name="wkf_id" select="1"/>
|
<field name="wkf_id" select="1"/>
|
||||||
<field name="kind" select="1"/>
|
<field name="kind" select="1"/>
|
||||||
<field name="action" select="1"/>
|
<field name="action_id" select="1" colspan="4"/>
|
||||||
<field name="action_id" select="1"/>
|
<field name="action" select="1" colspan="4" attrs="{'readonly':[('kind','=','dummy')]}"/>
|
||||||
<field name="subflow_id"/>
|
<field name="subflow_id" attrs="{'readonly':[('kind','<>','subflow')]}"/>
|
||||||
<field name="signal_send"/>
|
<field name="signal_send"/>
|
||||||
<newline/>
|
<newline/>
|
||||||
<field name="flow_start"/>
|
<field name="flow_start"/>
|
||||||
|
@ -77,9 +77,7 @@
|
||||||
<field name="condition"/>
|
<field name="condition"/>
|
||||||
<field name="trigger_model"/>
|
<field name="trigger_model"/>
|
||||||
<field name="trigger_expr_id"/>
|
<field name="trigger_expr_id"/>
|
||||||
|
|
||||||
</tree>
|
</tree>
|
||||||
|
|
||||||
</field>
|
</field>
|
||||||
<separator colspan="4" string="Incoming transitions"/>
|
<separator colspan="4" string="Incoming transitions"/>
|
||||||
<field colspan="4" name="in_transitions" nolabel="1">
|
<field colspan="4" name="in_transitions" nolabel="1">
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -219,6 +211,51 @@ class module(osv.osv):
|
||||||
res[m.id] = ''
|
res[m.id] = ''
|
||||||
return res
|
return res
|
||||||
|
|
||||||
|
def _get_menus(self, cr, uid, ids, field_name=None, arg=None, context={}):
|
||||||
|
res = {}
|
||||||
|
model_data_obj = self.pool.get('ir.model.data')
|
||||||
|
menu_obj = self.pool.get('ir.ui.menu')
|
||||||
|
for m in self.browse(cr, uid, ids):
|
||||||
|
if m.state == 'installed':
|
||||||
|
menu_txt = ''
|
||||||
|
menus_id = model_data_obj.search(cr,uid,[('module','=',m.name),('model','=','ir.ui.menu')])
|
||||||
|
for data_id in model_data_obj.browse(cr,uid,menus_id):
|
||||||
|
menu_txt += menu_obj.browse(cr,uid,data_id.res_id).complete_name + '\n'
|
||||||
|
res[m.id] = menu_txt
|
||||||
|
else:
|
||||||
|
res[m.id] = ''
|
||||||
|
return res
|
||||||
|
|
||||||
|
def _get_reports(self, cr, uid, ids, field_name=None, arg=None, context={}):
|
||||||
|
res = {}
|
||||||
|
model_data_obj = self.pool.get('ir.model.data')
|
||||||
|
report_obj = self.pool.get('ir.actions.report.xml')
|
||||||
|
for m in self.browse(cr, uid, ids):
|
||||||
|
if m.state == 'installed':
|
||||||
|
report_txt = ''
|
||||||
|
report_id = model_data_obj.search(cr,uid,[('module','=',m.name),('model','=','ir.actions.report.xml')])
|
||||||
|
for data_id in model_data_obj.browse(cr,uid,report_id):
|
||||||
|
report_txt += report_obj.browse(cr,uid,data_id.res_id).name + '\n'
|
||||||
|
res[m.id] = report_txt
|
||||||
|
else:
|
||||||
|
res[m.id] = ''
|
||||||
|
return res
|
||||||
|
|
||||||
|
def _get_views(self, cr, uid, ids, field_name=None, arg=None, context={}):
|
||||||
|
res = {}
|
||||||
|
model_data_obj = self.pool.get('ir.model.data')
|
||||||
|
view_obj = self.pool.get('ir.ui.view')
|
||||||
|
for m in self.browse(cr, uid, ids, context=context):
|
||||||
|
if m.state == 'installed':
|
||||||
|
view_txt = ''
|
||||||
|
view_id = model_data_obj.search(cr,uid,[('module','=',m.name),('model','=','ir.ui.view')])
|
||||||
|
for data_id in model_data_obj.browse(cr,uid,view_id):
|
||||||
|
view_txt += view_obj.browse(cr,uid,data_id.res_id).name + '\n'
|
||||||
|
res[m.id] = view_txt
|
||||||
|
else:
|
||||||
|
res[m.id] = ''
|
||||||
|
return res
|
||||||
|
|
||||||
_columns = {
|
_columns = {
|
||||||
'name': fields.char("Name", size=128, readonly=True, required=True),
|
'name': fields.char("Name", size=128, readonly=True, required=True),
|
||||||
'category_id': fields.many2one('ir.module.category', 'Category', readonly=True),
|
'category_id': fields.many2one('ir.module.category', 'Category', readonly=True),
|
||||||
|
@ -242,9 +279,16 @@ class module(osv.osv):
|
||||||
('to install','To be installed')
|
('to install','To be installed')
|
||||||
], string='State', readonly=True),
|
], string='State', readonly=True),
|
||||||
'demo': fields.boolean('Demo data'),
|
'demo': fields.boolean('Demo data'),
|
||||||
'license': fields.selection([('GPL-2', 'GPL-2'),('GPL-3', 'GPL-3'),
|
'license': fields.selection([
|
||||||
('Other proprietary', 'Other proprietary')], string='License',
|
('GPL-2', 'GPL-2'),
|
||||||
readonly=True),
|
('GPL-2 or any later version', 'GPL-2 or later version'),
|
||||||
|
('GPL-3', 'GPL-3'),
|
||||||
|
('GPL-3 or any later version', 'GPL-3 or later version'),
|
||||||
|
('Other proprietary', 'Other proprietary')
|
||||||
|
], string='License', readonly=True),
|
||||||
|
'menus_by_module': fields.function(_get_menus, method=True, string='Menus', type='text'),
|
||||||
|
'reports_by_module': fields.function(_get_reports, method=True, string='Reports', type='text'),
|
||||||
|
'views_by_module': fields.function(_get_views, method=True, string='Views', type='text'),
|
||||||
}
|
}
|
||||||
|
|
||||||
_defaults = {
|
_defaults = {
|
||||||
|
@ -310,7 +354,7 @@ class module(osv.osv):
|
||||||
m.state not in ('uninstalled','uninstallable','to remove')''', (module.name,))
|
m.state not in ('uninstalled','uninstallable','to remove')''', (module.name,))
|
||||||
res = cr.fetchall()
|
res = cr.fetchall()
|
||||||
if res:
|
if res:
|
||||||
raise orm.except_orm(_('Error'), _('The module you are trying to remove depends on installed modules :\n %s') % '\n'.join(map(lambda x: '\t%s: %s' % (x[0], x[1]), res)))
|
raise orm.except_orm(_('Error'), _('Some installed modules depends on the module you plan to desinstall :\n %s') % '\n'.join(map(lambda x: '\t%s: %s' % (x[0], x[1]), res)))
|
||||||
self.write(cr, uid, ids, {'state': 'to remove'})
|
self.write(cr, uid, ids, {'state': 'to remove'})
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
@ -380,7 +424,7 @@ class module(osv.osv):
|
||||||
continue
|
continue
|
||||||
terp_file = addons.get_module_resource(name, '__terp__.py')
|
terp_file = addons.get_module_resource(name, '__terp__.py')
|
||||||
mod_path = addons.get_module_path(name)
|
mod_path = addons.get_module_path(name)
|
||||||
if os.path.isdir(mod_path) or os.path.islink(mod_path) or zipfile.is_zipfile(mod_path):
|
if mod_path and (os.path.isdir(mod_path) or os.path.islink(mod_path) or zipfile.is_zipfile(mod_path)):
|
||||||
terp = self.get_module_info(mod_name)
|
terp = self.get_module_info(mod_name)
|
||||||
if not terp or not terp.get('installable', True):
|
if not terp or not terp.get('installable', True):
|
||||||
continue
|
continue
|
||||||
|
@ -528,10 +572,12 @@ class module(osv.osv):
|
||||||
self.write(cr, uid, [id], {'category_id': p_id})
|
self.write(cr, uid, [id], {'category_id': p_id})
|
||||||
|
|
||||||
def action_install(self,cr,uid,ids,context=None):
|
def action_install(self,cr,uid,ids,context=None):
|
||||||
self.write(cr , uid, ids ,{'state' : 'to install'})
|
for module in self.browse(cr, uid, ids, context):
|
||||||
self.download(cr, uid, ids, context=context)
|
if module.state <> 'uninstalled':
|
||||||
for id in ids:
|
continue
|
||||||
cr.execute("select m.id as id from ir_module_module_dependency d inner join ir_module_module m on (m.name=d.name) where d.module_id=%d and m.state='uninstalled'",(id,))
|
self.write(cr , uid, [module.id] ,{'state' : 'to install'})
|
||||||
|
self.download(cr, uid, [module.id], context=context)
|
||||||
|
cr.execute("select m.id as id from ir_module_module_dependency d inner join ir_module_module m on (m.name=d.name) where d.module_id=%d and m.state='uninstalled'",(module.id,))
|
||||||
dep_ids = map(lambda x:x[0],cr.fetchall())
|
dep_ids = map(lambda x:x[0],cr.fetchall())
|
||||||
if len(dep_ids):
|
if len(dep_ids):
|
||||||
self.action_install(cr,uid,dep_ids,context=context)
|
self.action_install(cr,uid,dep_ids,context=context)
|
||||||
|
@ -541,9 +587,9 @@ class module(osv.osv):
|
||||||
|
|
||||||
if not filter_lang:
|
if not filter_lang:
|
||||||
pool = pooler.get_pool(cr.dbname)
|
pool = pooler.get_pool(cr.dbname)
|
||||||
lang_obj=pool.get('res.lang')
|
lang_obj = pool.get('res.lang')
|
||||||
lang_ids=lang_obj.search(cr, uid, [('translatable', '=', True)])
|
lang_ids = lang_obj.search(cr, uid, [('translatable', '=', True)])
|
||||||
filter_lang= [lang.code for lang in lang_obj.browse(cr, uid, lang_ids)]
|
filter_lang = [lang.code for lang in lang_obj.browse(cr, uid, lang_ids)]
|
||||||
elif not isinstance(filter_lang, (list, tuple)):
|
elif not isinstance(filter_lang, (list, tuple)):
|
||||||
filter_lang = [filter_lang]
|
filter_lang = [filter_lang]
|
||||||
|
|
||||||
|
@ -554,7 +600,7 @@ class module(osv.osv):
|
||||||
for lang in filter_lang:
|
for lang in filter_lang:
|
||||||
f = os.path.join(tools.config['addons_path'], mod.name, 'i18n', lang + '.po')
|
f = os.path.join(tools.config['addons_path'], mod.name, 'i18n', lang + '.po')
|
||||||
if os.path.exists(f):
|
if os.path.exists(f):
|
||||||
logger.notifyChannel("init", netsvc.LOG_INFO, 'addons %s: loading translation file for language %s' % (mod.name, lang))
|
logger.notifyChannel("init", netsvc.LOG_INFO, 'addon %s: loading translation file for language %s' % (mod.name, lang))
|
||||||
tools.trans_load(cr.dbname, f, lang, verbose=False)
|
tools.trans_load(cr.dbname, f, lang, verbose=False)
|
||||||
|
|
||||||
module()
|
module()
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<openerp>
|
<openerp>
|
||||||
<data>
|
<data>
|
||||||
|
|
||||||
<!-- Modules Categories -->
|
<!-- Modules Categories -->
|
||||||
|
|
||||||
<record id="view_module_category_form" model="ir.ui.view">
|
<record id="view_module_category_form" model="ir.ui.view">
|
||||||
<field name="name">ir.module.category.form</field>
|
<field name="name">ir.module.category.form</field>
|
||||||
<field name="model">ir.module.category</field>
|
<field name="model">ir.module.category</field>
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
</form>
|
</form>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
<record id="view_module_category_tree" model="ir.ui.view">
|
<record id="view_module_category_tree" model="ir.ui.view">
|
||||||
<field name="name">ir.module.category.tree</field>
|
<field name="name">ir.module.category.tree</field>
|
||||||
<field name="model">ir.module.category</field>
|
<field name="model">ir.module.category</field>
|
||||||
|
@ -36,9 +36,9 @@
|
||||||
<field name="domain">[('parent_id','=',False)]</field>
|
<field name="domain">[('parent_id','=',False)]</field>
|
||||||
</record>
|
</record>
|
||||||
<menuitem action="action_module_category_tree" id="menu_action_module_category_tree" parent="base.menu_management"/>
|
<menuitem action="action_module_category_tree" id="menu_action_module_category_tree" parent="base.menu_management"/>
|
||||||
|
|
||||||
<!-- Click on a category -->
|
<!-- Click on a category -->
|
||||||
|
|
||||||
<record id="action_module_open_categ" model="ir.actions.act_window">
|
<record id="action_module_open_categ" model="ir.actions.act_window">
|
||||||
<field name="name">Modules</field>
|
<field name="name">Modules</field>
|
||||||
<field name="res_model">ir.module.module</field>
|
<field name="res_model">ir.module.module</field>
|
||||||
|
@ -53,10 +53,10 @@
|
||||||
<field eval="'ir.actions.act_window,%d'%action_module_open_categ" name="value"/>
|
<field eval="'ir.actions.act_window,%d'%action_module_open_categ" name="value"/>
|
||||||
<field eval="True" name="object"/>
|
<field eval="True" name="object"/>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
|
||||||
<!-- Modules -->
|
<!-- Modules -->
|
||||||
|
|
||||||
<record id="module_form" model="ir.ui.view">
|
<record id="module_form" model="ir.ui.view">
|
||||||
<field name="name">ir.module.module.form</field>
|
<field name="name">ir.module.module.form</field>
|
||||||
<field name="model">ir.module.module</field>
|
<field name="model">ir.module.module</field>
|
||||||
|
@ -95,6 +95,14 @@
|
||||||
</tree>
|
</tree>
|
||||||
</field>
|
</field>
|
||||||
</page>
|
</page>
|
||||||
|
<page string="Features" attrs="{'invisible':[('state','!=','installed')]}">
|
||||||
|
<separator string="Created Menus" colspan="4"/>
|
||||||
|
<field colspan="4" name="menus_by_module" nolabel="1"/>
|
||||||
|
<separator string="Created Views" colspan="2"/>
|
||||||
|
<separator string="Defined Reports" colspan="2"/>
|
||||||
|
<field colspan="2" name="views_by_module" nolabel="1"/>
|
||||||
|
<field colspan="2" name="reports_by_module" nolabel="1"/>
|
||||||
|
</page>
|
||||||
</notebook>
|
</notebook>
|
||||||
</form>
|
</form>
|
||||||
</field>
|
</field>
|
||||||
|
@ -123,7 +131,7 @@
|
||||||
<field name="domain"/>
|
<field name="domain"/>
|
||||||
</record>
|
</record>
|
||||||
<menuitem action="open_module_tree" id="menu_module_tree" parent="base.menu_management"/>
|
<menuitem action="open_module_tree" id="menu_module_tree" parent="base.menu_management"/>
|
||||||
|
|
||||||
<record id="open_module_tree_install" model="ir.actions.act_window">
|
<record id="open_module_tree_install" model="ir.actions.act_window">
|
||||||
<field name="name">Installed modules</field>
|
<field name="name">Installed modules</field>
|
||||||
<field name="res_model">ir.module.module</field>
|
<field name="res_model">ir.module.module</field>
|
||||||
|
@ -148,7 +156,7 @@
|
||||||
<field name="domain">[('state','in', ['to upgrade', 'to remove', 'to install'])]</field>
|
<field name="domain">[('state','in', ['to upgrade', 'to remove', 'to install'])]</field>
|
||||||
</record>
|
</record>
|
||||||
<menuitem action="open_module_tree_upgrade" id="menu_module_tree_upgrade" parent="base.menu_module_tree"/>
|
<menuitem action="open_module_tree_upgrade" id="menu_module_tree_upgrade" parent="base.menu_module_tree"/>
|
||||||
|
|
||||||
<record id="repository_form" model="ir.ui.view">
|
<record id="repository_form" model="ir.ui.view">
|
||||||
<field name="name">ir.module.repository.form</field>
|
<field name="name">ir.module.repository.form</field>
|
||||||
<field name="model">ir.module.repository</field>
|
<field name="model">ir.module.repository</field>
|
||||||
|
@ -183,7 +191,7 @@
|
||||||
<field name="view_mode">tree,form</field>
|
<field name="view_mode">tree,form</field>
|
||||||
<field name="context">{'active_test': False}</field>
|
<field name="context">{'active_test': False}</field>
|
||||||
</record>
|
</record>
|
||||||
<menuitem action="open_repository_tree" id="menu_module_repository_tree" parent="base.menu_management"/>
|
<menuitem action="open_repository_tree" id="menu_module_repository_tree" parent="base.menu_management"/>
|
||||||
|
|
||||||
</data>
|
</data>
|
||||||
</openerp>
|
</openerp>
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -112,7 +112,7 @@
|
||||||
<blockTable colWidths="276.0,234.0" repeatRows="1" style="Tableau2">
|
<blockTable colWidths="276.0,234.0" repeatRows="1" style="Tableau2">
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<para style="Standard">Name: [[ module.shortdesc]]</para>
|
<pre style="Standard">Name: [[ objdoc(module.shortdesc) ]]</pre>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<para style="Standard">Version: [[module.latest_version]]</para>
|
<para style="Standard">Version: [[module.latest_version]]</para>
|
||||||
|
@ -127,7 +127,7 @@
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</blockTable>
|
</blockTable>
|
||||||
<para style="P6">[[ module.description ]]</para>
|
<pre style="P6">[[ module.description ]]</pre>
|
||||||
<section>
|
<section>
|
||||||
<para style="Standard">[[ repeatIn(findobj(module.name) ,'object') ]]</para>
|
<para style="Standard">[[ repeatIn(findobj(module.name) ,'object') ]]</para>
|
||||||
<blockTable colWidths="510.0" repeatRows="1" style="Tableau3">
|
<blockTable colWidths="510.0" repeatRows="1" style="Tableau3">
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be)
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contact a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -47,7 +39,7 @@ view_form = """<?xml version="1.0"?>
|
||||||
<group colspan="2" col="4">
|
<group colspan="2" col="4">
|
||||||
<separator string="System Upgrade" colspan="4"/>
|
<separator string="System Upgrade" colspan="4"/>
|
||||||
<label align="0.0" string="Choose a language to install:" colspan="4"/>
|
<label align="0.0" string="Choose a language to install:" colspan="4"/>
|
||||||
<field name="lang" colspan="4"/>
|
<field name="lang" colspan="4" required="1"/>
|
||||||
<label align="0.0" string="Note that this operation may take a few minutes." colspan="4"/>
|
<label align="0.0" string="Note that this operation may take a few minutes." colspan="4"/>
|
||||||
</group>
|
</group>
|
||||||
</form>"""
|
</form>"""
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -87,26 +79,19 @@ class wizard_info_get(wizard.interface):
|
||||||
db, pool = pooler.get_db_and_pool(cr.dbname)
|
db, pool = pooler.get_db_and_pool(cr.dbname)
|
||||||
cr = db.cursor()
|
cr = db.cursor()
|
||||||
mod_obj = pool.get('ir.module.module')
|
mod_obj = pool.get('ir.module.module')
|
||||||
ids = mod_obj.search(cr, uid, [
|
ids = mod_obj.search(cr, uid, [('state', 'in', ['to upgrade', 'to remove', 'to install'])])
|
||||||
('state', 'in', ['to upgrade', 'to remove', 'to install'])])
|
unmet_packages = []
|
||||||
unmet_packages=[]
|
|
||||||
mod_dep_obj = pool.get('ir.module.module.dependency')
|
mod_dep_obj = pool.get('ir.module.module.dependency')
|
||||||
for mod in mod_obj.browse(cr,uid,ids):
|
for mod in mod_obj.browse(cr, uid, ids):
|
||||||
depends_mod_ids=mod_dep_obj.search(cr,uid,[('module_id','=',mod.id)])
|
depends_mod_ids = mod_dep_obj.search(cr, uid, [('module_id', '=', mod.id)])
|
||||||
for dep_mod in mod_dep_obj.browse(cr,uid,depends_mod_ids):
|
for dep_mod in mod_dep_obj.browse(cr, uid, depends_mod_ids):
|
||||||
if dep_mod.state in ('unknown','uninstalled'):
|
if dep_mod.state in ('unknown','uninstalled'):
|
||||||
unmet_packages.append(dep_mod.name)
|
unmet_packages.append(dep_mod.name)
|
||||||
if len(unmet_packages):
|
if len(unmet_packages):
|
||||||
raise wizard.except_wizard('Unmet dependency !','Following modules are uninstalled or unknown. \n\n'+'\n'.join(unmet_packages))
|
raise wizard.except_wizard('Unmet dependency !', 'Following modules are uninstalled or unknown. \n\n'+'\n'.join(unmet_packages))
|
||||||
mod_obj.download(cr, uid, ids, context=context)
|
mod_obj.download(cr, uid, ids, context=context)
|
||||||
cr.commit()
|
cr.commit()
|
||||||
db, pool = pooler.restart_pool(cr.dbname, update_module=True)
|
db, pool = pooler.restart_pool(cr.dbname, update_module=True)
|
||||||
|
|
||||||
# Update translations for all installed languages
|
|
||||||
cr = db.cursor()
|
|
||||||
modobj = pool.get('ir.module.module')
|
|
||||||
mids = modobj.search(cr, uid, [('state', '=', 'installed')])
|
|
||||||
modobj.update_translations(cr, uid, mids, None)
|
|
||||||
return {}
|
return {}
|
||||||
|
|
||||||
def _config(self, cr, uid, data, context=None):
|
def _config(self, cr, uid, data, context=None):
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,31 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 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.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# You should have received a copy of the GNU General Public License
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -55,6 +46,11 @@ class Bank(osv.osv):
|
||||||
_defaults = {
|
_defaults = {
|
||||||
'active': lambda *a: 1,
|
'active': lambda *a: 1,
|
||||||
}
|
}
|
||||||
|
def name_get(self, cr, uid, ids, context=None):
|
||||||
|
result = []
|
||||||
|
for bank in self.browse(cr, uid, ids, context):
|
||||||
|
result.append((bank.id, (bank.bic and (bank.bic + ' - ') or '') + bank.name))
|
||||||
|
return result
|
||||||
|
|
||||||
Bank()
|
Bank()
|
||||||
|
|
||||||
|
|
|
@ -1,31 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 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.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# You should have received a copy of the GNU General Public License
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -140,7 +132,6 @@ class res_partner(osv.osv):
|
||||||
'ref': fields.char('Code', size=64),
|
'ref': fields.char('Code', size=64),
|
||||||
'lang': fields.selection(_lang_get, 'Language', size=5, help="If the selected language is loaded in the system, all documents related to this partner will be printed in this language. If not, it will be english."),
|
'lang': fields.selection(_lang_get, 'Language', size=5, help="If the selected language is loaded in the system, all documents related to this partner will be printed in this language. If not, it will be english."),
|
||||||
'user_id': fields.many2one('res.users', 'Dedicated Salesman', help='The internal user that is in charge of communicating with this partner if any.'),
|
'user_id': fields.many2one('res.users', 'Dedicated Salesman', help='The internal user that is in charge of communicating with this partner if any.'),
|
||||||
'responsible': fields.many2one('res.users', 'Users'),
|
|
||||||
'vat': fields.char('VAT',size=32 ,help="Value Added Tax number"),
|
'vat': fields.char('VAT',size=32 ,help="Value Added Tax number"),
|
||||||
'bank_ids': fields.one2many('res.partner.bank', 'partner_id', 'Banks'),
|
'bank_ids': fields.one2many('res.partner.bank', 'partner_id', 'Banks'),
|
||||||
'website': fields.char('Website',size=64),
|
'website': fields.char('Website',size=64),
|
||||||
|
@ -247,18 +238,6 @@ class res_partner(osv.osv):
|
||||||
result[a] = adr.get(a, default_address)
|
result[a] = adr.get(a, default_address)
|
||||||
return result
|
return result
|
||||||
|
|
||||||
def property_get(self, cr, uid, ids,property_pref=[]):
|
|
||||||
select = ids
|
|
||||||
if isinstance(ids, (int, long)):
|
|
||||||
select = [ids]
|
|
||||||
result=self.read(cr,uid,select,property_pref)
|
|
||||||
for res in result:
|
|
||||||
for prt in property_pref:
|
|
||||||
res[prt] = res[prt] and res[prt][0] or False
|
|
||||||
if isinstance(ids, (int, long)):
|
|
||||||
return result[0]
|
|
||||||
return result
|
|
||||||
|
|
||||||
def gen_next_ref(self, cr, uid, ids):
|
def gen_next_ref(self, cr, uid, ids):
|
||||||
if len(ids) != 1:
|
if len(ids) != 1:
|
||||||
return True
|
return True
|
||||||
|
@ -290,7 +269,7 @@ class res_partner_address(osv.osv):
|
||||||
_name = 'res.partner.address'
|
_name = 'res.partner.address'
|
||||||
_order = 'id'
|
_order = 'id'
|
||||||
_columns = {
|
_columns = {
|
||||||
'partner_id': fields.many2one('res.partner', 'Partner', ondelete='cascade', select=True),
|
'partner_id': fields.many2one('res.partner', 'Partner', ondelete='cascade', select=True, help="Keep empty for a private address, not related to partner."),
|
||||||
'type': fields.selection( [ ('default','Default'),('invoice','Invoice'), ('delivery','Delivery'), ('contact','Contact'), ('other','Other') ],'Address Type', help="Used to select automatically the right address according to the context in sales and purchases documents."),
|
'type': fields.selection( [ ('default','Default'),('invoice','Invoice'), ('delivery','Delivery'), ('contact','Contact'), ('other','Other') ],'Address Type', help="Used to select automatically the right address according to the context in sales and purchases documents."),
|
||||||
'function': fields.many2one('res.partner.function', 'Function'),
|
'function': fields.many2one('res.partner.function', 'Function'),
|
||||||
'title': fields.selection(_contact_title_get, 'Title', size=32),
|
'title': fields.selection(_contact_title_get, 'Title', size=32),
|
||||||
|
|
|
@ -3,7 +3,8 @@
|
||||||
<data>
|
<data>
|
||||||
<menuitem icon="terp-partner" id="menu_base_partner" name="Partners" sequence="0"/>
|
<menuitem icon="terp-partner" id="menu_base_partner" name="Partners" sequence="0"/>
|
||||||
|
|
||||||
<menuitem id="menu_base_config" name="Configuration" parent="menu_base_partner" sequence="1"/>
|
<menuitem id="menu_base_config" name="Configuration" parent="menu_base_partner" sequence="1"
|
||||||
|
groups="group_system"/>
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
================================
|
================================
|
||||||
|
@ -208,8 +209,8 @@
|
||||||
<field name="name"/>
|
<field name="name"/>
|
||||||
<field name="title"/>
|
<field name="title"/>
|
||||||
<field name="ref"/>
|
<field name="ref"/>
|
||||||
<field name="city"/>
|
<field name="city" select="2"/>
|
||||||
<field name="country"/>
|
<field name="country" select="2"/>
|
||||||
<field name="lang"/>
|
<field name="lang"/>
|
||||||
</tree>
|
</tree>
|
||||||
</field>
|
</field>
|
||||||
|
@ -227,8 +228,6 @@
|
||||||
<field domain="[('domain', '=', 'partner')]" name="title"/>
|
<field domain="[('domain', '=', 'partner')]" name="title"/>
|
||||||
<field name="lang" select="2"/>
|
<field name="lang" select="2"/>
|
||||||
<field name="supplier" select="2"/>
|
<field name="supplier" select="2"/>
|
||||||
<field name="city" select="2" invisible="1"/>
|
|
||||||
<field name="country" select="2" invisible="1"/>
|
|
||||||
</group>
|
</group>
|
||||||
<notebook colspan="4">
|
<notebook colspan="4">
|
||||||
<page string="General">
|
<page string="General">
|
||||||
|
@ -338,7 +337,10 @@
|
||||||
<field name="view_type">form</field>
|
<field name="view_type">form</field>
|
||||||
<field name="view_mode">form,tree</field>
|
<field name="view_mode">form,tree</field>
|
||||||
</record>
|
</record>
|
||||||
<menuitem action="action_partner_customer_form_new" id="menu_partner_customer_form_new" parent="menu_partner_form"/>
|
<menuitem
|
||||||
|
action="action_partner_customer_form_new"
|
||||||
|
sequence="50"
|
||||||
|
id="menu_partner_customer_form_new" parent="menu_partner_form"/>
|
||||||
|
|
||||||
<record id="view_payterm_form" model="ir.ui.view">
|
<record id="view_payterm_form" model="ir.ui.view">
|
||||||
<field name="name">res.payterm</field>
|
<field name="name">res.payterm</field>
|
||||||
|
@ -503,7 +505,7 @@
|
||||||
<field name="view_id" ref="view_partner_category_tree"/>
|
<field name="view_id" ref="view_partner_category_tree"/>
|
||||||
<field name="domain">[('parent_id','=',False)]</field>
|
<field name="domain">[('parent_id','=',False)]</field>
|
||||||
</record>
|
</record>
|
||||||
<menuitem action="action_partner_category" id="menu_partner_category_main" parent="base.menu_base_partner" sequence="1"/>
|
<menuitem action="action_partner_category" id="menu_partner_category_main" parent="base.menu_partner_form" sequence="1"/>
|
||||||
|
|
||||||
<record id="action_partner_by_category" model="ir.actions.act_window">
|
<record id="action_partner_by_category" model="ir.actions.act_window">
|
||||||
<field name="name" eval="False"/>
|
<field name="name" eval="False"/>
|
||||||
|
@ -529,5 +531,10 @@
|
||||||
</record>
|
</record>
|
||||||
<menuitem action="action_partner_category_form" id="menu_partner_category_form" parent="base.menu_base_config"/>
|
<menuitem action="action_partner_category_form" id="menu_partner_category_form" parent="base.menu_base_config"/>
|
||||||
|
|
||||||
|
<act_window domain="[('partner_id', '=', active_id)]"
|
||||||
|
id="act_res_partner_event" name="Events"
|
||||||
|
res_model="res.partner.event"
|
||||||
|
src_model="res.partner"/>
|
||||||
|
|
||||||
</data>
|
</data>
|
||||||
</openerp>
|
</openerp>
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -58,7 +50,7 @@ def _mass_mail_send(self, cr, uid, data, context):
|
||||||
to = '%s <%s>' % (name, adr.email)
|
to = '%s <%s>' % (name, adr.email)
|
||||||
#TODO: add some tests to check for invalid email addresses
|
#TODO: add some tests to check for invalid email addresses
|
||||||
#CHECKME: maybe we should use res.partner/email_send
|
#CHECKME: maybe we should use res.partner/email_send
|
||||||
tools.email_send(data['form']['from'], [to], data['form']['subject'], data['form']['text'])
|
tools.email_send(data['form']['from'], [to], data['form']['subject'], data['form']['text'],subtype='html')
|
||||||
nbr += 1
|
nbr += 1
|
||||||
pooler.get_pool(cr.dbname).get('res.partner.event').create(cr, uid,
|
pooler.get_pool(cr.dbname).get('res.partner.event').create(cr, uid,
|
||||||
{'name': 'Email sent through mass mailing',
|
{'name': 'Email sent through mass mailing',
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -126,7 +118,7 @@ class res_company(osv.osv):
|
||||||
<setFont name="Helvetica" size="8"/>
|
<setFont name="Helvetica" size="8"/>
|
||||||
<drawRightString x="19.7cm" y="28.3cm"><pageNumber/> / </drawRightString>
|
<drawRightString x="19.7cm" y="28.3cm"><pageNumber/> / </drawRightString>
|
||||||
<drawString x="19.8cm" y="28.3cm"><pageCount/></drawString>
|
<drawString x="19.8cm" y="28.3cm"><pageCount/></drawString>
|
||||||
<stroke color="#aaaaaa"/>
|
<stroke color="#000000"/>
|
||||||
<lines>1.3cm 28.1cm 20cm 28.1cm</lines>
|
<lines>1.3cm 28.1cm 20cm 28.1cm</lines>
|
||||||
</pageGraphics>
|
</pageGraphics>
|
||||||
</pageTemplate>
|
</pageTemplate>
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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 time
|
||||||
|
@ -45,6 +37,7 @@ class res_currency(osv.osv):
|
||||||
date=context['date']
|
date=context['date']
|
||||||
else:
|
else:
|
||||||
date=time.strftime('%Y-%m-%d')
|
date=time.strftime('%Y-%m-%d')
|
||||||
|
date= date or time.strftime('%Y-%m-%d')
|
||||||
for id in ids:
|
for id in ids:
|
||||||
cr.execute("SELECT currency_id, rate FROM res_currency_rate WHERE currency_id = %d AND name <= '%s' ORDER BY name desc LIMIT 1" % (id, date))
|
cr.execute("SELECT currency_id, rate FROM res_currency_rate WHERE currency_id = %d AND name <= '%s' ORDER BY name desc LIMIT 1" % (id, date))
|
||||||
if cr.rowcount:
|
if cr.rowcount:
|
||||||
|
@ -79,7 +72,7 @@ class res_currency(osv.osv):
|
||||||
def is_zero(self, cr, uid, currency, amount):
|
def is_zero(self, cr, uid, currency, amount):
|
||||||
return abs(self.round(cr, uid, currency, amount)) < currency.rounding
|
return abs(self.round(cr, uid, currency, amount)) < currency.rounding
|
||||||
|
|
||||||
def compute(self, cr, uid, from_currency_id, to_currency_id, from_amount, round=True, context={}):
|
def compute(self, cr, uid, from_currency_id, to_currency_id, from_amount, round=True, context={}, account=None, account_invert=False):
|
||||||
if not from_currency_id:
|
if not from_currency_id:
|
||||||
from_currency_id = to_currency_id
|
from_currency_id = to_currency_id
|
||||||
xc=self.browse(cr, uid, [from_currency_id,to_currency_id], context=context)
|
xc=self.browse(cr, uid, [from_currency_id,to_currency_id], context=context)
|
||||||
|
@ -94,6 +87,16 @@ class res_currency(osv.osv):
|
||||||
raise osv.except_osv(_('Error'), _('No rate found \n' \
|
raise osv.except_osv(_('Error'), _('No rate found \n' \
|
||||||
'for the currency: %s \n' \
|
'for the currency: %s \n' \
|
||||||
'at the date: %s') % (code, date))
|
'at the date: %s') % (code, date))
|
||||||
|
rate = to_currency.rate/from_currency.rate
|
||||||
|
if account and (account.currency_mode=='average') and account.currency_id:
|
||||||
|
q = self.pool.get('account.move.line')._query_get(cr, uid, context=context)
|
||||||
|
cr.execute('select sum(debit-credit),sum(amount_currency) from account_move_line l ' \
|
||||||
|
'where l.currency_id=%d and l.account_id=%d and '+q, (account.currency_id.id,account.id,))
|
||||||
|
tot1,tot2 = cr.fetchone()
|
||||||
|
if tot2 and not account_invert:
|
||||||
|
rate = float(tot1)/float(tot2)
|
||||||
|
elif tot1 and account_invert:
|
||||||
|
rate = float(tot2)/float(tot1)
|
||||||
if to_currency_id==from_currency_id:
|
if to_currency_id==from_currency_id:
|
||||||
if round:
|
if round:
|
||||||
return self.round(cr, uid, to_currency, from_amount)
|
return self.round(cr, uid, to_currency, from_amount)
|
||||||
|
@ -101,9 +104,10 @@ class res_currency(osv.osv):
|
||||||
return from_amount
|
return from_amount
|
||||||
else:
|
else:
|
||||||
if round:
|
if round:
|
||||||
return self.round(cr, uid, to_currency, from_amount * to_currency.rate/from_currency.rate)
|
return self.round(cr, uid, to_currency, from_amount * rate)
|
||||||
else:
|
else:
|
||||||
return (from_amount * to_currency.rate/from_currency.rate)
|
return (from_amount * rate)
|
||||||
|
|
||||||
def name_search(self, cr, uid, name, args=[], operator='ilike', context={}, limit=80):
|
def name_search(self, cr, uid, name, args=[], operator='ilike', context={}, limit=80):
|
||||||
args2 = args[:]
|
args2 = args[:]
|
||||||
if name:
|
if name:
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,10 +1,18 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<openerp>
|
<openerp>
|
||||||
<data noupdate="1">
|
<data noupdate="0">
|
||||||
|
|
||||||
<record model="res.groups" id="group_partner_manager">
|
<record model="res.groups" id="group_partner_manager">
|
||||||
<field name="name">Partner Manager</field>
|
<field name="name">Partner Manager</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
<record model="ir.ui.menu" id="menu_base_config">
|
||||||
|
<field eval="[(6,0,[ref('group_system'), ref('group_partner_manager')])]" name="groups_id"/>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
<record model="ir.ui.menu" id="menu_partner_customer_form_new">
|
||||||
|
<field eval="[(6,0,[ref('group_partner_manager')])]" name="groups_id"/>
|
||||||
|
</record>
|
||||||
|
|
||||||
</data>
|
</data>
|
||||||
</openerp>
|
</openerp>
|
||||||
|
|
|
@ -1,31 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
# Copyright (c) 2008 Camptocamp SA
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -57,6 +48,7 @@ class groups(osv.osv):
|
||||||
res = super(groups, self).write(cr, uid, ids, vals, context=context)
|
res = super(groups, self).write(cr, uid, ids, vals, context=context)
|
||||||
# Restart the cache on the company_get method
|
# Restart the cache on the company_get method
|
||||||
self.pool.get('ir.rule').domain_get()
|
self.pool.get('ir.rule').domain_get()
|
||||||
|
self.pool.get('ir.model.access').check()
|
||||||
return res
|
return res
|
||||||
|
|
||||||
def create(self, cr, uid, vals, context=None):
|
def create(self, cr, uid, vals, context=None):
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
|
||||||
<!-- Set access to menu -->
|
<!-- Set accesses to menu -->
|
||||||
<record model="ir.ui.menu" id="base.menu_administration">
|
<record model="ir.ui.menu" id="base.menu_administration">
|
||||||
<field name="groups_id" eval="[(6,0, [ref('group_system'), ref('group_erp_manager')])]"/>
|
<field name="groups_id" eval="[(6,0, [ref('group_system'), ref('group_erp_manager')])]"/>
|
||||||
</record>
|
</record>
|
||||||
|
@ -51,6 +51,23 @@
|
||||||
<record id="base.menu_users" model="ir.ui.menu">
|
<record id="base.menu_users" model="ir.ui.menu">
|
||||||
<field eval="[(6,0,[ref('base.group_erp_manager')])]" name="groups_id"/>
|
<field eval="[(6,0,[ref('base.group_erp_manager')])]" name="groups_id"/>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
<record id="base.menu_action_currency_form" model="ir.ui.menu">
|
||||||
|
<field eval="[(6,0,[ref('base.group_system')])]" name="groups_id"/>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
<record id="base.menu_custom" model="ir.ui.menu">
|
||||||
|
<field eval="[(6,0,[ref('base.group_system')])]" name="groups_id"/>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
<record id="base.menu_translation" model="ir.ui.menu">
|
||||||
|
<!-- FIXME: a "Usability / Translations" group ?? -->
|
||||||
|
<field eval="[(6,0,[ref('base.group_system')])]" name="groups_id"/>
|
||||||
|
</record>
|
||||||
|
|
||||||
|
<record id="base.menu_management" model="ir.ui.menu">
|
||||||
|
<field eval="[(6,0,[ref('base.group_system')])]" name="groups_id"/>
|
||||||
|
</record>
|
||||||
|
|
||||||
</data>
|
</data>
|
||||||
</openerp>
|
</openerp>
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||||
"access_ir_attachment_group_user","ir_attachment group_system_user","model_ir_attachment","group_user",1,1,1,1
|
"access_ir_attachment_group_system","ir_attachment group_system","model_ir_attachment",,1,1,1,1
|
||||||
"access_ir_attachment_group_system","ir_attachment group_system","model_ir_attachment",,1,0,0,0
|
|
||||||
"access_ir_cron_group_cron","ir_cron group_cron","model_ir_cron","group_system",1,1,1,1
|
"access_ir_cron_group_cron","ir_cron group_cron","model_ir_cron","group_system",1,1,1,1
|
||||||
|
"access_ir_cron_user","ir_cron user","model_ir_cron","group_user",1,0,0,0
|
||||||
"access_ir_default_group_system","ir_default group_system","model_ir_default",,1,1,1,1
|
"access_ir_default_group_system","ir_default group_system","model_ir_default",,1,1,1,1
|
||||||
"access_ir_exports_group_system","ir_exports group_system","model_ir_exports",,1,1,1,1
|
"access_ir_exports_group_system","ir_exports group_system","model_ir_exports",,1,1,1,1
|
||||||
"access_ir_exports_line_group_system","ir_exports_line group_system","model_ir_exports_line",,1,1,1,1
|
"access_ir_exports_line_group_system","ir_exports_line group_system","model_ir_exports_line",,1,1,1,1
|
||||||
|
@ -32,8 +32,11 @@
|
||||||
"access_ir_sequence_type_group_user","ir_sequence_type group_user","model_ir_sequence_type",,1,0,0,0
|
"access_ir_sequence_type_group_user","ir_sequence_type group_user","model_ir_sequence_type",,1,0,0,0
|
||||||
"access_ir_translation_group_system","ir_translation group_system","model_ir_translation",,1,1,1,1
|
"access_ir_translation_group_system","ir_translation group_system","model_ir_translation",,1,1,1,1
|
||||||
"access_ir_ui_menu_group_user","ir_ui_menu group_user","model_ir_ui_menu",,1,0,0,0
|
"access_ir_ui_menu_group_user","ir_ui_menu group_user","model_ir_ui_menu",,1,0,0,0
|
||||||
|
"access_ir_ui_menu_group_system","ir_ui_menu group_system","model_ir_ui_menu","group_system",1,1,1,1
|
||||||
"access_ir_ui_view_group_user","ir_ui_view group_user","model_ir_ui_view",,1,0,0,0
|
"access_ir_ui_view_group_user","ir_ui_view group_user","model_ir_ui_view",,1,0,0,0
|
||||||
|
"access_ir_ui_view_group_system","ir_ui_view group_system","model_ir_ui_view","group_system",1,1,1,1
|
||||||
"access_ir_ui_view_custom_group_user","ir_ui_view_custom_group_user","model_ir_ui_view_custom",,1,0,0,0
|
"access_ir_ui_view_custom_group_user","ir_ui_view_custom_group_user","model_ir_ui_view_custom",,1,0,0,0
|
||||||
|
"access_ir_ui_view_custom_group_system","ir_ui_view_custom_group_system","model_ir_ui_view_custom","group_system",1,1,1,1
|
||||||
"access_ir_ui_view_sc_group_user","ir_ui_view_sc group_user","model_ir_ui_view_sc",,1,1,1,1
|
"access_ir_ui_view_sc_group_user","ir_ui_view_sc group_user","model_ir_ui_view_sc",,1,1,1,1
|
||||||
"access_ir_values_group_erp_manager","ir_values group_erp_manager","model_ir_values",,1,1,1,1
|
"access_ir_values_group_erp_manager","ir_values group_erp_manager","model_ir_values",,1,1,1,1
|
||||||
"access_wizard_ir_model_menu_create_group_system","wizard_ir_model_menu_create group_system","model_wizard_ir_model_menu_create","group_system",1,1,1,1
|
"access_wizard_ir_model_menu_create_group_system","wizard_ir_model_menu_create group_system","model_wizard_ir_model_menu_create","group_system",1,1,1,1
|
||||||
|
@ -47,59 +50,74 @@
|
||||||
"access_res_country_state_group_user","res_country_state group_user","model_res_country_state","group_partner_manager",1,1,1,1
|
"access_res_country_state_group_user","res_country_state group_user","model_res_country_state","group_partner_manager",1,1,1,1
|
||||||
"access_res_currency_group_all","res_currency group_all","model_res_currency",,1,0,0,0
|
"access_res_currency_group_all","res_currency group_all","model_res_currency",,1,0,0,0
|
||||||
"access_res_currency_rate_group_all","res_currency_rate group_all","model_res_currency_rate",,1,0,0,0
|
"access_res_currency_rate_group_all","res_currency_rate group_all","model_res_currency_rate",,1,0,0,0
|
||||||
"access_res_currency_group_user","res_currency group_user","model_res_currency","group_user",1,1,1,1
|
"access_res_currency_group_system","res_currency group_system","model_res_currency","group_system",1,1,1,1
|
||||||
"access_res_currency_rate_group_user","res_currency_rate group_user","model_res_currency_rate","group_user",1,1,1,1
|
"access_res_currency_rate_group_system","res_currency_rate group_system","model_res_currency_rate","group_system",1,1,1,1
|
||||||
"access_res_groups_group_erp_manager","res_groups group_erp_manager","model_res_groups","group_erp_manager",1,1,1,1
|
"access_res_groups_group_erp_manager","res_groups group_erp_manager","model_res_groups","group_erp_manager",1,1,1,1
|
||||||
"access_res_groups_group_user","res_groups group_user","model_res_groups",,1,0,0,0
|
"access_res_groups_group_user","res_groups group_user","model_res_groups",,1,0,0,0
|
||||||
"access_res_lang_group_all","res_lang group_all","model_res_lang",,1,0,0,0
|
"access_res_lang_group_all","res_lang group_all","model_res_lang",,1,0,0,0
|
||||||
"access_res_lang_group_user","res_lang group_user","model_res_lang","group_system",1,1,1,1
|
"access_res_lang_group_user","res_lang group_user","model_res_lang","group_system",1,1,1,1
|
||||||
"access_res_partner_group_partner_manager","res_partner group_partner_manager","model_res_partner","group_partner_manager",1,1,1,1
|
"access_res_partner_group_partner_manager","res_partner group_partner_manager","model_res_partner","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_group_user","res_partner group_user","model_res_partner",,1,0,0,0
|
"access_res_partner_group_user","res_partner group_user","model_res_partner",group_user,1,0,0,0
|
||||||
"access_res_partner_address_group_partner_manager","res_partner_address group_partner_manager","model_res_partner_address","group_partner_manager",1,1,1,1
|
"access_res_partner_address_group_partner_manager","res_partner_address group_partner_manager","model_res_partner_address","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_address_group_user","res_partner_address group_user","model_res_partner_address",,1,0,0,0
|
"access_res_partner_address_group_user","res_partner_address group_user","model_res_partner_address",group_user,1,0,0,0
|
||||||
"access_res_partner_bank_group_user","res_partner_bank group_user","model_res_partner_bank",,1,0,0,0
|
"access_res_partner_bank_group_user","res_partner_bank group_user","model_res_partner_bank",group_user,1,0,0,0
|
||||||
"access_res_partner_bank_group_partner_manager","res_partner_bank group_partner_manager","model_res_partner_bank","group_partner_manager",1,1,1,1
|
"access_res_partner_bank_group_partner_manager","res_partner_bank group_partner_manager","model_res_partner_bank","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_bank_type_group_partner_manager","res_partner_bank_type group_partner_manager","model_res_partner_bank_type","group_partner_manager",1,1,1,1
|
"access_res_partner_bank_type_group_partner_manager","res_partner_bank_type group_partner_manager","model_res_partner_bank_type","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_bank_type_group_user","res_partner_bank_type group_user","model_res_partner_bank_type",,1,0,0,0
|
"access_res_partner_bank_type_group_user","res_partner_bank_type group_user","model_res_partner_bank_type",group_user,1,0,0,0
|
||||||
"access_res_partner_bank_type_field_group_partner_manager","res_partner_bank_type_field group_partner_manager","model_res_partner_bank_type_field","group_partner_manager",1,1,1,1
|
"access_res_partner_bank_type_field_group_partner_manager","res_partner_bank_type_field group_partner_manager","model_res_partner_bank_type_field","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_bank_type_field_group_user","res_partner_bank_type_field group_user","model_res_partner_bank_type_field",,1,0,0,0
|
"access_res_partner_bank_type_field_group_user","res_partner_bank_type_field group_user","model_res_partner_bank_type_field",group_user,1,0,0,0
|
||||||
"access_res_partner_canal_group_user","res_partner_canal group_user","model_res_partner_canal",,1,0,0,0
|
"access_res_partner_canal_group_user","res_partner_canal group_user","model_res_partner_canal",group_user,1,0,0,0
|
||||||
"access_res_partner_canal_group_partner_manager","res_partner_canal group_partner_manager","model_res_partner_canal","group_partner_manager",1,1,1,1
|
"access_res_partner_canal_group_partner_manager","res_partner_canal group_partner_manager","model_res_partner_canal","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_category_group_user","res_partner_category group_user","model_res_partner_category","group_partner_manager",1,1,1,0
|
"access_res_partner_category_group_user","res_partner_category group_user","model_res_partner_category",group_user,1,0,0,0
|
||||||
"access_res_partner_category_group_partner_manager","res_partner_category group_partner_manager","model_res_partner_category",,1,0,0,1
|
"access_res_partner_category_group_partner_manager","res_partner_category group_partner_manager","model_res_partner_category","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_event_group_user","res_partner_event group_user","model_res_partner_event",,1,1,1,1
|
"access_res_partner_event_group_user","res_partner_event group_user","model_res_partner_event",group_user,1,1,1,1
|
||||||
|
"access_res_partner_event_group_partner_manager","res_partner_event group_partner_manager","model_res_partner_event","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_event_type_group_partner_manager","res_partner_event_type group_partner_manager","model_res_partner_event_type","group_partner_manager",1,1,1,1
|
"access_res_partner_event_type_group_partner_manager","res_partner_event_type group_partner_manager","model_res_partner_event_type","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_event_type_group_user","res_partner_event_type group_user","model_res_partner_event_type",,1,0,0,0
|
"access_res_partner_event_type_group_user","res_partner_event_type group_user","model_res_partner_event_type",group_user,1,0,0,0
|
||||||
"access_res_partner_function_group_user","res_partner_function group_user","model_res_partner_function","group_partner_manager",1,1,1,1
|
"access_res_partner_function_group_user","res_partner_function group_user","model_res_partner_function","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_function_group_partner_manager","res_partner_function group_partner_manager","model_res_partner_function",,1,0,0,0
|
"access_res_partner_function_group_partner_manager","res_partner_function group_partner_manager","model_res_partner_function",group_user,1,0,0,0
|
||||||
"access_res_partner_som_group_user","res_partner_som group_user","model_res_partner_som","group_partner_manager",1,1,1,1
|
"access_res_partner_som_group_user","res_partner_som group_user","model_res_partner_som","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_som_group_partner_manager","res_partner_som group_partner_manager","model_res_partner_som",,1,0,0,0
|
"access_res_partner_som_group_partner_manager","res_partner_som group_partner_manager","model_res_partner_som",group_user,1,0,0,0
|
||||||
"access_res_partner_title_group_user","res_partner_title group_user","model_res_partner_title","group_partner_manager",1,1,1,1
|
"access_res_partner_title_group_user","res_partner_title group_user","model_res_partner_title","group_partner_manager",1,1,1,1
|
||||||
"access_res_partner_title_group_partner_manager","res_partner_title group_partner_manager","model_res_partner_title",,1,0,0,0
|
"access_res_partner_title_group_partner_manager","res_partner_title group_partner_manager","model_res_partner_title",group_user,1,0,0,0
|
||||||
"access_res_request_group_user","res_request group_user","model_res_request",,1,1,1,1
|
"access_res_request_group_user","res_request group_user","model_res_request",,1,1,1,1
|
||||||
"access_res_request_history_group_user","res_request_history group_user","model_res_request_history",,1,1,1,1
|
"access_res_request_history_group_user","res_request_history group_user","model_res_request_history",,1,1,1,1
|
||||||
"access_res_request_link_group_system","res_request_link group_system","model_res_request_link","group_system",1,1,1,1
|
"access_res_request_link_group_system","res_request_link group_system","model_res_request_link","group_system",1,1,1,1
|
||||||
"access_res_request_link_group_user","res_request_link group_user","model_res_request_link",,1,0,0,0
|
"access_res_request_link_group_user","res_request_link group_user","model_res_request_link",,1,0,0,0
|
||||||
"access_res_users_group_user","res_users group_user","model_res_users",,1,0,0,0
|
"access_res_users_all","res_users all","model_res_users",,1,0,0,0
|
||||||
"access_res_users_group_erp_manager","res_users group_erp_manager","model_res_users","group_erp_manager",1,1,1,1
|
"access_res_users_group_erp_manager","res_users group_erp_manager","model_res_users","group_erp_manager",1,1,1,1
|
||||||
"access_ir_actions_all","ir_actions_all","model_ir_actions_actions",,1,0,0,0
|
"access_ir_actions_all","ir_actions_all","model_ir_actions_actions",,1,0,0,0
|
||||||
|
"access_ir_actions_group_system","ir_actions_group_system","model_ir_actions_actions","group_system",1,1,1,1
|
||||||
"access_ir_actions_act_window_all","ir_actions_act_window_all","model_ir_actions_act_window",,1,0,0,0
|
"access_ir_actions_act_window_all","ir_actions_act_window_all","model_ir_actions_act_window",,1,0,0,0
|
||||||
"access_ir_actions_act_window_close_group_all","ir_actions_act_window_close_all","model_ir_actions_act_window_close",,1,0,0,0
|
"access_ir_actions_act_window_system","ir_actions_act_window_system","model_ir_actions_act_window","group_system",1,1,1,1
|
||||||
|
"access_ir_actions_act_window_close_all","ir_actions_act_window_close_all","model_ir_actions_act_window_close",,1,0,0,0
|
||||||
|
"access_ir_actions_act_window_close_group_system","ir_actions_act_window_close_group_system","model_ir_actions_act_window_close","group_system",1,1,1,1
|
||||||
"access_ir_actions_report_xml_all","ir_actions_report_xml","model_ir_actions_report_xml",,1,0,0,0
|
"access_ir_actions_report_xml_all","ir_actions_report_xml","model_ir_actions_report_xml",,1,0,0,0
|
||||||
|
"access_ir_actions_report_xml_group_system","ir_actions_report_xml_group_system","model_ir_actions_report_xml","group_system",1,1,1,1
|
||||||
"access_ir_actions_wizard_all","ir_actions_wizard","model_ir_actions_wizard",,1,0,0,0
|
"access_ir_actions_wizard_all","ir_actions_wizard","model_ir_actions_wizard",,1,0,0,0
|
||||||
|
"access_ir_actions_wizard_group_system","ir_actions_wizard_group_system","model_ir_actions_wizard","group_system",1,1,1,1
|
||||||
"access_ir_actions_todo_group_system","ir_actions_todo group system","model_ir_actions_todo","group_system",1,1,1,1
|
"access_ir_actions_todo_group_system","ir_actions_todo group system","model_ir_actions_todo","group_system",1,1,1,1
|
||||||
"access_ir_actions_config_wiz_group_system","ir_actions_configuration_wizard group system","model_ir_actions_configuration_wizard","group_system",1,1,1,1
|
"access_ir_actions_config_wiz_group_system","ir_actions_configuration_wizard group system","model_ir_actions_configuration_wizard","group_system",1,1,1,1
|
||||||
"access_workflow_group_system","workflow_group_system","model_workflow","group_system",1,0,0,0
|
"access_workflow_all","workflow_all","model_workflow",,1,0,0,0
|
||||||
"access_workflow_activity_group_system","workflow_activity_group_system","model_workflow_activity","group_system",1,0,0,0
|
"access_workflow_group_system","workflow_group_system","model_workflow","group_system",1,1,1,1
|
||||||
"access_workflow_instance_group_system","workflow_instance_group_system","model_workflow_instance","group_system",1,0,0,0
|
"access_workflow_activity_all","workflow_activity_all","model_workflow_activity",,1,0,0,0
|
||||||
"access_workflow_transition_group_system","workflow_transition_group_system","model_workflow_transition","group_system",1,0,0,0
|
"access_workflow_activity_group_system","workflow_activity_group_system","model_workflow_activity","group_system",1,1,1,1
|
||||||
"access_workflow_triggers_group_system","workflow_triggers_group_system","model_workflow_triggers","group_system",1,0,0,0
|
"access_workflow_instance_all","workflow_instance_all","model_workflow_instance",,1,1,1,1
|
||||||
"access_workflow_workitem_group_system","workflow_workitem_group_system","model_workflow_workitem","group_system",1,0,0,0
|
"access_workflow_transition_all","workflow_transition_all","model_workflow_transition",,1,0,0,0
|
||||||
"access_actions_report_custom_group_system","ir_actions_report_custom_group_system","model_ir_actions_report_custom","group_system",1,0,0,0
|
"access_workflow_transition_group_system","workflow_transition_group_system","model_workflow_transition","group_system",1,1,1,1
|
||||||
"access_ir_actions_act_window_view_group_employee","ir_actions_act_window_view_group_employee","model_ir_actions_act_window_view","group_system",1,0,0,0
|
"access_workflow_triggers_all","workflow_triggers_all","model_workflow_triggers",,1,0,0,0
|
||||||
"access_ir_actions_url_group_user","ir_actions_url_group_user","model_ir_actions_url","group_system",1,0,0,0
|
"access_workflow_triggers_group_system","workflow_triggers_group_system","model_workflow_triggers","group_system",1,1,1,1
|
||||||
"access_ir_server_object_lines_group_user","ir_server_object_lines_group_user","model_ir_server_object_lines","group_system",1,0,0,0
|
"access_workflow_workitem_all","workflow_workitem_all","model_workflow_workitem",,1,1,1,1
|
||||||
"access_ir_actions_server_group_user","ir_actions_server_group_user","model_ir_actions_server","group_system",1,0,0,0
|
"access_actions_report_custom_all","ir_actions_report_custom_all","model_ir_actions_report_custom",,1,0,0,0
|
||||||
|
"access_actions_report_custom_group_system","ir_actions_report_custom_group_system","model_ir_actions_report_custom","group_system",1,1,1,1
|
||||||
|
"access_ir_actions_act_window_view_all","ir_actions_act_window_view_all","model_ir_actions_act_window_view",,1,0,0,0
|
||||||
|
"access_ir_actions_act_window_view_group_system","ir_actions_act_window_view_group_system","model_ir_actions_act_window_view","group_system",1,1,1,1
|
||||||
|
"access_ir_actions_url_all","ir_actions_url_all","model_ir_actions_url",,1,0,0,0
|
||||||
|
"access_ir_actions_url_group_system","ir_actions_url_group_system","model_ir_actions_url","group_system",1,1,1,1
|
||||||
|
"access_ir_server_object_lines_all","ir_server_object_lines_all","model_ir_server_object_lines",,1,0,0,0
|
||||||
|
"access_ir_server_object_lines_group_system","ir_server_object_lines_group_system","model_ir_server_object_lines","group_system",1,1,1,1
|
||||||
|
"access_ir_actions_server_all","ir_actions_server_all","model_ir_actions_server",,1,0,0,0
|
||||||
|
"access_ir_actions_server_group_system","ir_actions_server_group_system","model_ir_actions_server","group_system",1,1,1,1
|
||||||
"access_module_update_translations_group_user","wizard_update_translations_group_user","model_wizard_module_update_translations","group_system",1,1,1,1
|
"access_module_update_translations_group_user","wizard_update_translations_group_user","model_wizard_module_update_translations","group_system",1,1,1,1
|
||||||
"access_res_bank_group_system","res_bank_group_system","model_res_bank","group_system",1,1,1,1
|
"access_res_bank_group_system","res_bank_group_system","model_res_bank","group_system",1,1,1,1
|
||||||
"access_res_payterm_group_system","res_payterm_group_system","model_res_payterm","group_system",1,1,1,1
|
"access_res_payterm_group_system","res_payterm_group_system","model_res_payterm","group_system",1,1,1,1
|
||||||
|
@ -107,3 +125,5 @@
|
||||||
"access_res_config_view_group_erpmanager","res_config_view_erp_manager","model_res_config_view","group_erp_manager",1,1,1,1
|
"access_res_config_view_group_erpmanager","res_config_view_erp_manager","model_res_config_view","group_erp_manager",1,1,1,1
|
||||||
"access_res_roles_all","res_roles_all","model_res_roles",,1,0,0,0
|
"access_res_roles_all","res_roles_all","model_res_roles",,1,0,0,0
|
||||||
"access_res_config_view_all","res_config_view_all","model_res_config_view",,1,0,0,0
|
"access_res_config_view_all","res_config_view_all","model_res_config_view",,1,0,0,0
|
||||||
|
"access_res_bank_group_partner_manager","res_bank_group_partner_manager","model_res_bank","group_partner_manager",1,1,1,1
|
||||||
|
"access_res_bank_user","res_bank user","model_res_bank","group_user",1,0,0,0
|
||||||
|
|
|
|
@ -2,30 +2,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be)
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contact a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
952
bin/gpl.txt
952
bin/gpl.txt
|
@ -1,278 +1,674 @@
|
||||||
GNU GENERAL PUBLIC LICENSE
|
GNU GENERAL PUBLIC LICENSE
|
||||||
Version 2, June 1991
|
Version 3, 29 June 2007
|
||||||
|
|
||||||
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
|
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||||
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
Everyone is permitted to copy and distribute verbatim copies
|
||||||
Everyone is permitted to copy and distribute verbatim copies
|
of this license document, but changing it is not allowed.
|
||||||
of this license document, but changing it is not allowed.
|
|
||||||
|
Preamble
|
||||||
Preamble
|
|
||||||
|
The GNU General Public License is a free, copyleft license for
|
||||||
The licenses for most software are designed to take away your
|
software and other kinds of works.
|
||||||
freedom to share and change it. By contrast, the GNU General Public
|
|
||||||
License is intended to guarantee your freedom to share and change free
|
The licenses for most software and other practical works are designed
|
||||||
software--to make sure the software is free for all its users. This
|
to take away your freedom to share and change the works. By contrast,
|
||||||
General Public License applies to most of the Free Software
|
the GNU General Public License is intended to guarantee your freedom to
|
||||||
Foundation's software and to any other program whose authors commit to
|
share and change all versions of a program--to make sure it remains free
|
||||||
using it. (Some other Free Software Foundation software is covered by
|
software for all its users. We, the Free Software Foundation, use the
|
||||||
the GNU Library General Public License instead.) You can apply it to
|
GNU General Public License for most of our software; it applies also to
|
||||||
your programs, too.
|
any other work released this way by its authors. You can apply it to
|
||||||
|
your programs, too.
|
||||||
When we speak of free software, we are referring to freedom, not
|
|
||||||
price. Our General Public Licenses are designed to make sure that you
|
When we speak of free software, we are referring to freedom, not
|
||||||
have the freedom to distribute copies of free software (and charge for
|
price. Our General Public Licenses are designed to make sure that you
|
||||||
this service if you wish), that you receive source code or can get it
|
have the freedom to distribute copies of free software (and charge for
|
||||||
if you want it, that you can change the software or use pieces of it
|
them if you wish), that you receive source code or can get it if you
|
||||||
in new free programs; and that you know you can do these things.
|
want it, that you can change the software or use pieces of it in new
|
||||||
|
free programs, and that you know you can do these things.
|
||||||
To protect your rights, we need to make restrictions that forbid
|
|
||||||
anyone to deny you these rights or to ask you to surrender the rights.
|
To protect your rights, we need to prevent others from denying you
|
||||||
These restrictions translate to certain responsibilities for you if you
|
these rights or asking you to surrender the rights. Therefore, you have
|
||||||
distribute copies of the software, or if you modify it.
|
certain responsibilities if you distribute copies of the software, or if
|
||||||
|
you modify it: responsibilities to respect the freedom of others.
|
||||||
For example, if you distribute copies of such a program, whether
|
|
||||||
gratis or for a fee, you must give the recipients all the rights that
|
For example, if you distribute copies of such a program, whether
|
||||||
you have. You must make sure that they, too, receive or can get the
|
gratis or for a fee, you must pass on to the recipients the same
|
||||||
source code. And you must show them these terms so they know their
|
freedoms that you received. You must make sure that they, too, receive
|
||||||
rights.
|
or can get the source code. And you must show them these terms so they
|
||||||
|
know their rights.
|
||||||
We protect your rights with two steps: (1) copyright the software, and
|
|
||||||
(2) offer you this license which gives you legal permission to copy,
|
Developers that use the GNU GPL protect your rights with two steps:
|
||||||
distribute and/or modify the software.
|
(1) assert copyright on the software, and (2) offer you this License
|
||||||
|
giving you legal permission to copy, distribute and/or modify it.
|
||||||
Also, for each author's protection and ours, we want to make certain
|
|
||||||
that everyone understands that there is no warranty for this free
|
For the developers' and authors' protection, the GPL clearly explains
|
||||||
software. If the software is modified by someone else and passed on, we
|
that there is no warranty for this free software. For both users' and
|
||||||
want its recipients to know that what they have is not the original, so
|
authors' sake, the GPL requires that modified versions be marked as
|
||||||
that any problems introduced by others will not reflect on the original
|
changed, so that their problems will not be attributed erroneously to
|
||||||
authors' reputations.
|
authors of previous versions.
|
||||||
|
|
||||||
Finally, any free program is threatened constantly by software
|
Some devices are designed to deny users access to install or run
|
||||||
patents. We wish to avoid the danger that redistributors of a free
|
modified versions of the software inside them, although the manufacturer
|
||||||
program will individually obtain patent licenses, in effect making the
|
can do so. This is fundamentally incompatible with the aim of
|
||||||
program proprietary. To prevent this, we have made it clear that any
|
protecting users' freedom to change the software. The systematic
|
||||||
patent must be licensed for everyone's free use or not licensed at all.
|
pattern of such abuse occurs in the area of products for individuals to
|
||||||
|
use, which is precisely where it is most unacceptable. Therefore, we
|
||||||
The precise terms and conditions for copying, distribution and
|
have designed this version of the GPL to prohibit the practice for those
|
||||||
modification follow.
|
products. If such problems arise substantially in other domains, we
|
||||||
|
stand ready to extend this provision to those domains in future versions
|
||||||
GNU GENERAL PUBLIC LICENSE
|
of the GPL, as needed to protect the freedom of users.
|
||||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
|
||||||
|
Finally, every program is threatened constantly by software patents.
|
||||||
0. This License applies to any program or other work which contains
|
States should not allow patents to restrict development and use of
|
||||||
a notice placed by the copyright holder saying it may be distributed
|
software on general-purpose computers, but in those that do, we wish to
|
||||||
under the terms of this General Public License. The "Program", below,
|
avoid the special danger that patents applied to a free program could
|
||||||
refers to any such program or work, and a "work based on the Program"
|
make it effectively proprietary. To prevent this, the GPL assures that
|
||||||
means either the Program or any derivative work under copyright law:
|
patents cannot be used to render the program non-free.
|
||||||
that is to say, a work containing the Program or a portion of it,
|
|
||||||
either verbatim or with modifications and/or translated into another
|
The precise terms and conditions for copying, distribution and
|
||||||
language. (Hereinafter, translation is included without limitation in
|
modification follow.
|
||||||
the term "modification".) Each licensee is addressed as "you".
|
|
||||||
|
TERMS AND CONDITIONS
|
||||||
Activities other than copying, distribution and modification are not
|
|
||||||
covered by this License; they are outside its scope. The act of
|
0. Definitions.
|
||||||
running the Program is not restricted, and the output from the Program
|
|
||||||
is covered only if its contents constitute a work based on the
|
"This License" refers to version 3 of the GNU General Public License.
|
||||||
Program (independent of having been made by running the Program).
|
|
||||||
Whether that is true depends on what the Program does.
|
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||||
|
works, such as semiconductor masks.
|
||||||
1. You may copy and distribute verbatim copies of the Program's
|
|
||||||
source code as you receive it, in any medium, provided that you
|
"The Program" refers to any copyrightable work licensed under this
|
||||||
conspicuously and appropriately publish on each copy an appropriate
|
License. Each licensee is addressed as "you". "Licensees" and
|
||||||
copyright notice and disclaimer of warranty; keep intact all the
|
"recipients" may be individuals or organizations.
|
||||||
notices that refer to this License and to the absence of any warranty;
|
|
||||||
and give any other recipients of the Program a copy of this License
|
To "modify" a work means to copy from or adapt all or part of the work
|
||||||
along with the Program.
|
in a fashion requiring copyright permission, other than the making of an
|
||||||
|
exact copy. The resulting work is called a "modified version" of the
|
||||||
You may charge a fee for the physical act of transferring a copy, and
|
earlier work or a work "based on" the earlier work.
|
||||||
you may at your option offer warranty protection in exchange for a fee.
|
|
||||||
|
A "covered work" means either the unmodified Program or a work based
|
||||||
2. You may modify your copy or copies of the Program or any portion
|
on the Program.
|
||||||
of it, thus forming a work based on the Program, and copy and
|
|
||||||
distribute such modifications or work under the terms of Section 1
|
To "propagate" a work means to do anything with it that, without
|
||||||
above, provided that you also meet all of these conditions:
|
permission, would make you directly or secondarily liable for
|
||||||
|
infringement under applicable copyright law, except executing it on a
|
||||||
a) You must cause the modified files to carry prominent notices
|
computer or modifying a private copy. Propagation includes copying,
|
||||||
stating that you changed the files and the date of any change.
|
distribution (with or without modification), making available to the
|
||||||
|
public, and in some countries other activities as well.
|
||||||
b) You must cause any work that you distribute or publish, that in
|
|
||||||
whole or in part contains or is derived from the Program or any
|
To "convey" a work means any kind of propagation that enables other
|
||||||
part thereof, to be licensed as a whole at no charge to all third
|
parties to make or receive copies. Mere interaction with a user through
|
||||||
parties under the terms of this License.
|
a computer network, with no transfer of a copy, is not conveying.
|
||||||
|
|
||||||
c) If the modified program normally reads commands interactively
|
An interactive user interface displays "Appropriate Legal Notices"
|
||||||
when run, you must cause it, when started running for such
|
to the extent that it includes a convenient and prominently visible
|
||||||
interactive use in the most ordinary way, to print or display an
|
feature that (1) displays an appropriate copyright notice, and (2)
|
||||||
announcement including an appropriate copyright notice and a
|
tells the user that there is no warranty for the work (except to the
|
||||||
notice that there is no warranty (or else, saying that you provide
|
extent that warranties are provided), that licensees may convey the
|
||||||
a warranty) and that users may redistribute the program under
|
work under this License, and how to view a copy of this License. If
|
||||||
these conditions, and telling the user how to view a copy of this
|
the interface presents a list of user commands or options, such as a
|
||||||
License. (Exception: if the Program itself is interactive but
|
menu, a prominent item in the list meets this criterion.
|
||||||
does not normally print such an announcement, your work based on
|
|
||||||
the Program is not required to print an announcement.)
|
1. Source Code.
|
||||||
|
|
||||||
These requirements apply to the modified work as a whole. If
|
The "source code" for a work means the preferred form of the work
|
||||||
identifiable sections of that work are not derived from the Program,
|
for making modifications to it. "Object code" means any non-source
|
||||||
and can be reasonably considered independent and separate works in
|
form of a work.
|
||||||
themselves, then this License, and its terms, do not apply to those
|
|
||||||
sections when you distribute them as separate works. But when you
|
A "Standard Interface" means an interface that either is an official
|
||||||
distribute the same sections as part of a whole which is a work based
|
standard defined by a recognized standards body, or, in the case of
|
||||||
on the Program, the distribution of the whole must be on the terms of
|
interfaces specified for a particular programming language, one that
|
||||||
this License, whose permissions for other licensees extend to the
|
is widely used among developers working in that language.
|
||||||
entire whole, and thus to each and every part regardless of who wrote it.
|
|
||||||
|
The "System Libraries" of an executable work include anything, other
|
||||||
Thus, it is not the intent of this section to claim rights or contest
|
than the work as a whole, that (a) is included in the normal form of
|
||||||
your rights to work written entirely by you; rather, the intent is to
|
packaging a Major Component, but which is not part of that Major
|
||||||
exercise the right to control the distribution of derivative or
|
Component, and (b) serves only to enable use of the work with that
|
||||||
collective works based on the Program.
|
Major Component, or to implement a Standard Interface for which an
|
||||||
|
implementation is available to the public in source code form. A
|
||||||
In addition, mere aggregation of another work not based on the Program
|
"Major Component", in this context, means a major essential component
|
||||||
with the Program (or with a work based on the Program) on a volume of
|
(kernel, window system, and so on) of the specific operating system
|
||||||
a storage or distribution medium does not bring the other work under
|
(if any) on which the executable work runs, or a compiler used to
|
||||||
the scope of this License.
|
produce the work, or an object code interpreter used to run it.
|
||||||
|
|
||||||
3. You may copy and distribute the Program (or a work based on it,
|
The "Corresponding Source" for a work in object code form means all
|
||||||
under Section 2) in object code or executable form under the terms of
|
the source code needed to generate, install, and (for an executable
|
||||||
Sections 1 and 2 above provided that you also do one of the following:
|
work) run the object code and to modify the work, including scripts to
|
||||||
|
control those activities. However, it does not include the work's
|
||||||
a) Accompany it with the complete corresponding machine-readable
|
System Libraries, or general-purpose tools or generally available free
|
||||||
source code, which must be distributed under the terms of Sections
|
programs which are used unmodified in performing those activities but
|
||||||
1 and 2 above on a medium customarily used for software interchange; or,
|
which are not part of the work. For example, Corresponding Source
|
||||||
|
includes interface definition files associated with source files for
|
||||||
b) Accompany it with a written offer, valid for at least three
|
the work, and the source code for shared libraries and dynamically
|
||||||
years, to give any third party, for a charge no more than your
|
linked subprograms that the work is specifically designed to require,
|
||||||
cost of physically performing source distribution, a complete
|
such as by intimate data communication or control flow between those
|
||||||
machine-readable copy of the corresponding source code, to be
|
subprograms and other parts of the work.
|
||||||
distributed under the terms of Sections 1 and 2 above on a medium
|
|
||||||
customarily used for software interchange; or,
|
The Corresponding Source need not include anything that users
|
||||||
|
can regenerate automatically from other parts of the Corresponding
|
||||||
c) Accompany it with the information you received as to the offer
|
Source.
|
||||||
to distribute corresponding source code. (This alternative is
|
|
||||||
allowed only for noncommercial distribution and only if you
|
The Corresponding Source for a work in source code form is that
|
||||||
received the program in object code or executable form with such
|
same work.
|
||||||
an offer, in accord with Subsection b above.)
|
|
||||||
|
2. Basic Permissions.
|
||||||
The source code for a work means the preferred form of the work for
|
|
||||||
making modifications to it. For an executable work, complete source
|
All rights granted under this License are granted for the term of
|
||||||
code means all the source code for all modules it contains, plus any
|
copyright on the Program, and are irrevocable provided the stated
|
||||||
associated interface definition files, plus the scripts used to
|
conditions are met. This License explicitly affirms your unlimited
|
||||||
control compilation and installation of the executable. However, as a
|
permission to run the unmodified Program. The output from running a
|
||||||
special exception, the source code distributed need not include
|
covered work is covered by this License only if the output, given its
|
||||||
anything that is normally distributed (in either source or binary
|
content, constitutes a covered work. This License acknowledges your
|
||||||
form) with the major components (compiler, kernel, and so on) of the
|
rights of fair use or other equivalent, as provided by copyright law.
|
||||||
operating system on which the executable runs, unless that component
|
|
||||||
itself accompanies the executable.
|
You may make, run and propagate covered works that you do not
|
||||||
|
convey, without conditions so long as your license otherwise remains
|
||||||
If distribution of executable or object code is made by offering
|
in force. You may convey covered works to others for the sole purpose
|
||||||
access to copy from a designated place, then offering equivalent
|
of having them make modifications exclusively for you, or provide you
|
||||||
access to copy the source code from the same place counts as
|
with facilities for running those works, provided that you comply with
|
||||||
distribution of the source code, even though third parties are not
|
the terms of this License in conveying all material for which you do
|
||||||
compelled to copy the source along with the object code.
|
not control copyright. Those thus making or running the covered works
|
||||||
|
for you must do so exclusively on your behalf, under your direction
|
||||||
4. You may not copy, modify, sublicense, or distribute the Program
|
and control, on terms that prohibit them from making any copies of
|
||||||
except as expressly provided under this License. Any attempt
|
your copyrighted material outside their relationship with you.
|
||||||
otherwise to copy, modify, sublicense or distribute the Program is
|
|
||||||
void, and will automatically terminate your rights under this License.
|
Conveying under any other circumstances is permitted solely under
|
||||||
However, parties who have received copies, or rights, from you under
|
the conditions stated below. Sublicensing is not allowed; section 10
|
||||||
this License will not have their licenses terminated so long as such
|
makes it unnecessary.
|
||||||
parties remain in full compliance.
|
|
||||||
|
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||||
5. You are not required to accept this License, since you have not
|
|
||||||
signed it. However, nothing else grants you permission to modify or
|
No covered work shall be deemed part of an effective technological
|
||||||
distribute the Program or its derivative works. These actions are
|
measure under any applicable law fulfilling obligations under article
|
||||||
prohibited by law if you do not accept this License. Therefore, by
|
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||||
modifying or distributing the Program (or any work based on the
|
similar laws prohibiting or restricting circumvention of such
|
||||||
Program), you indicate your acceptance of this License to do so, and
|
measures.
|
||||||
all its terms and conditions for copying, distributing or modifying
|
|
||||||
the Program or works based on it.
|
When you convey a covered work, you waive any legal power to forbid
|
||||||
|
circumvention of technological measures to the extent such circumvention
|
||||||
6. Each time you redistribute the Program (or any work based on the
|
is effected by exercising rights under this License with respect to
|
||||||
Program), the recipient automatically receives a license from the
|
the covered work, and you disclaim any intention to limit operation or
|
||||||
original licensor to copy, distribute or modify the Program subject to
|
modification of the work as a means of enforcing, against the work's
|
||||||
these terms and conditions. You may not impose any further
|
users, your or third parties' legal rights to forbid circumvention of
|
||||||
restrictions on the recipients' exercise of the rights granted herein.
|
technological measures.
|
||||||
You are not responsible for enforcing compliance by third parties to
|
|
||||||
this License.
|
4. Conveying Verbatim Copies.
|
||||||
|
|
||||||
7. If, as a consequence of a court judgment or allegation of patent
|
You may convey verbatim copies of the Program's source code as you
|
||||||
infringement or for any other reason (not limited to patent issues),
|
receive it, in any medium, provided that you conspicuously and
|
||||||
conditions are imposed on you (whether by court order, agreement or
|
appropriately publish on each copy an appropriate copyright notice;
|
||||||
otherwise) that contradict the conditions of this License, they do not
|
keep intact all notices stating that this License and any
|
||||||
excuse you from the conditions of this License. If you cannot
|
non-permissive terms added in accord with section 7 apply to the code;
|
||||||
distribute so as to satisfy simultaneously your obligations under this
|
keep intact all notices of the absence of any warranty; and give all
|
||||||
License and any other pertinent obligations, then as a consequence you
|
recipients a copy of this License along with the Program.
|
||||||
may not distribute the Program at all. For example, if a patent
|
|
||||||
license would not permit royalty-free redistribution of the Program by
|
You may charge any price or no price for each copy that you convey,
|
||||||
all those who receive copies directly or indirectly through you, then
|
and you may offer support or warranty protection for a fee.
|
||||||
the only way you could satisfy both it and this License would be to
|
|
||||||
refrain entirely from distribution of the Program.
|
5. Conveying Modified Source Versions.
|
||||||
|
|
||||||
If any portion of this section is held invalid or unenforceable under
|
You may convey a work based on the Program, or the modifications to
|
||||||
any particular circumstance, the balance of the section is intended to
|
produce it from the Program, in the form of source code under the
|
||||||
apply and the section as a whole is intended to apply in other
|
terms of section 4, provided that you also meet all of these conditions:
|
||||||
circumstances.
|
|
||||||
|
a) The work must carry prominent notices stating that you modified
|
||||||
It is not the purpose of this section to induce you to infringe any
|
it, and giving a relevant date.
|
||||||
patents or other property right claims or to contest validity of any
|
|
||||||
such claims; this section has the sole purpose of protecting the
|
b) The work must carry prominent notices stating that it is
|
||||||
integrity of the free software distribution system, which is
|
released under this License and any conditions added under section
|
||||||
implemented by public license practices. Many people have made
|
7. This requirement modifies the requirement in section 4 to
|
||||||
generous contributions to the wide range of software distributed
|
"keep intact all notices".
|
||||||
through that system in reliance on consistent application of that
|
|
||||||
system; it is up to the author/donor to decide if he or she is willing
|
c) You must license the entire work, as a whole, under this
|
||||||
to distribute software through any other system and a licensee cannot
|
License to anyone who comes into possession of a copy. This
|
||||||
impose that choice.
|
License will therefore apply, along with any applicable section 7
|
||||||
|
additional terms, to the whole of the work, and all its parts,
|
||||||
This section is intended to make thoroughly clear what is believed to
|
regardless of how they are packaged. This License gives no
|
||||||
be a consequence of the rest of this License.
|
permission to license the work in any other way, but it does not
|
||||||
|
invalidate such permission if you have separately received it.
|
||||||
8. If the distribution and/or use of the Program is restricted in
|
|
||||||
certain countries either by patents or by copyrighted interfaces, the
|
d) If the work has interactive user interfaces, each must display
|
||||||
original copyright holder who places the Program under this License
|
Appropriate Legal Notices; however, if the Program has interactive
|
||||||
may add an explicit geographical distribution limitation excluding
|
interfaces that do not display Appropriate Legal Notices, your
|
||||||
those countries, so that distribution is permitted only in or among
|
work need not make them do so.
|
||||||
countries not thus excluded. In such case, this License incorporates
|
|
||||||
the limitation as if written in the body of this License.
|
A compilation of a covered work with other separate and independent
|
||||||
|
works, which are not by their nature extensions of the covered work,
|
||||||
9. The Free Software Foundation may publish revised and/or new versions
|
and which are not combined with it such as to form a larger program,
|
||||||
of the General Public License from time to time. Such new versions will
|
in or on a volume of a storage or distribution medium, is called an
|
||||||
be similar in spirit to the present version, but may differ in detail to
|
"aggregate" if the compilation and its resulting copyright are not
|
||||||
address new problems or concerns.
|
used to limit the access or legal rights of the compilation's users
|
||||||
|
beyond what the individual works permit. Inclusion of a covered work
|
||||||
Each version is given a distinguishing version number. If the Program
|
in an aggregate does not cause this License to apply to the other
|
||||||
specifies a version number of this License which applies to it and "any
|
parts of the aggregate.
|
||||||
later version", you have the option of following the terms and conditions
|
|
||||||
either of that version or of any later version published by the Free
|
6. Conveying Non-Source Forms.
|
||||||
Software Foundation. If the Program does not specify a version number of
|
|
||||||
this License, you may choose any version ever published by the Free Software
|
You may convey a covered work in object code form under the terms
|
||||||
Foundation.
|
of sections 4 and 5, provided that you also convey the
|
||||||
|
machine-readable Corresponding Source under the terms of this License,
|
||||||
10. If you wish to incorporate parts of the Program into other free
|
in one of these ways:
|
||||||
programs whose distribution conditions are different, write to the author
|
|
||||||
to ask for permission. For software which is copyrighted by the Free
|
a) Convey the object code in, or embodied in, a physical product
|
||||||
Software Foundation, write to the Free Software Foundation; we sometimes
|
(including a physical distribution medium), accompanied by the
|
||||||
make exceptions for this. Our decision will be guided by the two goals
|
Corresponding Source fixed on a durable physical medium
|
||||||
of preserving the free status of all derivatives of our free software and
|
customarily used for software interchange.
|
||||||
of promoting the sharing and reuse of software generally.
|
|
||||||
|
b) Convey the object code in, or embodied in, a physical product
|
||||||
NO WARRANTY
|
(including a physical distribution medium), accompanied by a
|
||||||
|
written offer, valid for at least three years and valid for as
|
||||||
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
|
long as you offer spare parts or customer support for that product
|
||||||
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
|
model, to give anyone who possesses the object code either (1) a
|
||||||
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
|
copy of the Corresponding Source for all the software in the
|
||||||
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
|
product that is covered by this License, on a durable physical
|
||||||
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
medium customarily used for software interchange, for a price no
|
||||||
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
|
more than your reasonable cost of physically performing this
|
||||||
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
|
conveying of source, or (2) access to copy the
|
||||||
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
|
Corresponding Source from a network server at no charge.
|
||||||
REPAIR OR CORRECTION.
|
|
||||||
|
c) Convey individual copies of the object code with a copy of the
|
||||||
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
written offer to provide the Corresponding Source. This
|
||||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
|
alternative is allowed only occasionally and noncommercially, and
|
||||||
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
|
only if you received the object code with such an offer, in accord
|
||||||
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
|
with subsection 6b.
|
||||||
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
|
|
||||||
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
|
d) Convey the object code by offering access from a designated
|
||||||
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
|
place (gratis or for a charge), and offer equivalent access to the
|
||||||
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
|
Corresponding Source in the same way through the same place at no
|
||||||
POSSIBILITY OF SUCH DAMAGES.
|
further charge. You need not require recipients to copy the
|
||||||
|
Corresponding Source along with the object code. If the place to
|
||||||
|
copy the object code is a network server, the Corresponding Source
|
||||||
|
may be on a different server (operated by you or a third party)
|
||||||
|
that supports equivalent copying facilities, provided you maintain
|
||||||
|
clear directions next to the object code saying where to find the
|
||||||
|
Corresponding Source. Regardless of what server hosts the
|
||||||
|
Corresponding Source, you remain obligated to ensure that it is
|
||||||
|
available for as long as needed to satisfy these requirements.
|
||||||
|
|
||||||
|
e) Convey the object code using peer-to-peer transmission, provided
|
||||||
|
you inform other peers where the object code and Corresponding
|
||||||
|
Source of the work are being offered to the general public at no
|
||||||
|
charge under subsection 6d.
|
||||||
|
|
||||||
|
A separable portion of the object code, whose source code is excluded
|
||||||
|
from the Corresponding Source as a System Library, need not be
|
||||||
|
included in conveying the object code work.
|
||||||
|
|
||||||
|
A "User Product" is either (1) a "consumer product", which means any
|
||||||
|
tangible personal property which is normally used for personal, family,
|
||||||
|
or household purposes, or (2) anything designed or sold for incorporation
|
||||||
|
into a dwelling. In determining whether a product is a consumer product,
|
||||||
|
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||||
|
product received by a particular user, "normally used" refers to a
|
||||||
|
typical or common use of that class of product, regardless of the status
|
||||||
|
of the particular user or of the way in which the particular user
|
||||||
|
actually uses, or expects or is expected to use, the product. A product
|
||||||
|
is a consumer product regardless of whether the product has substantial
|
||||||
|
commercial, industrial or non-consumer uses, unless such uses represent
|
||||||
|
the only significant mode of use of the product.
|
||||||
|
|
||||||
|
"Installation Information" for a User Product means any methods,
|
||||||
|
procedures, authorization keys, or other information required to install
|
||||||
|
and execute modified versions of a covered work in that User Product from
|
||||||
|
a modified version of its Corresponding Source. The information must
|
||||||
|
suffice to ensure that the continued functioning of the modified object
|
||||||
|
code is in no case prevented or interfered with solely because
|
||||||
|
modification has been made.
|
||||||
|
|
||||||
|
If you convey an object code work under this section in, or with, or
|
||||||
|
specifically for use in, a User Product, and the conveying occurs as
|
||||||
|
part of a transaction in which the right of possession and use of the
|
||||||
|
User Product is transferred to the recipient in perpetuity or for a
|
||||||
|
fixed term (regardless of how the transaction is characterized), the
|
||||||
|
Corresponding Source conveyed under this section must be accompanied
|
||||||
|
by the Installation Information. But this requirement does not apply
|
||||||
|
if neither you nor any third party retains the ability to install
|
||||||
|
modified object code on the User Product (for example, the work has
|
||||||
|
been installed in ROM).
|
||||||
|
|
||||||
|
The requirement to provide Installation Information does not include a
|
||||||
|
requirement to continue to provide support service, warranty, or updates
|
||||||
|
for a work that has been modified or installed by the recipient, or for
|
||||||
|
the User Product in which it has been modified or installed. Access to a
|
||||||
|
network may be denied when the modification itself materially and
|
||||||
|
adversely affects the operation of the network or violates the rules and
|
||||||
|
protocols for communication across the network.
|
||||||
|
|
||||||
|
Corresponding Source conveyed, and Installation Information provided,
|
||||||
|
in accord with this section must be in a format that is publicly
|
||||||
|
documented (and with an implementation available to the public in
|
||||||
|
source code form), and must require no special password or key for
|
||||||
|
unpacking, reading or copying.
|
||||||
|
|
||||||
|
7. Additional Terms.
|
||||||
|
|
||||||
|
"Additional permissions" are terms that supplement the terms of this
|
||||||
|
License by making exceptions from one or more of its conditions.
|
||||||
|
Additional permissions that are applicable to the entire Program shall
|
||||||
|
be treated as though they were included in this License, to the extent
|
||||||
|
that they are valid under applicable law. If additional permissions
|
||||||
|
apply only to part of the Program, that part may be used separately
|
||||||
|
under those permissions, but the entire Program remains governed by
|
||||||
|
this License without regard to the additional permissions.
|
||||||
|
|
||||||
|
When you convey a copy of a covered work, you may at your option
|
||||||
|
remove any additional permissions from that copy, or from any part of
|
||||||
|
it. (Additional permissions may be written to require their own
|
||||||
|
removal in certain cases when you modify the work.) You may place
|
||||||
|
additional permissions on material, added by you to a covered work,
|
||||||
|
for which you have or can give appropriate copyright permission.
|
||||||
|
|
||||||
|
Notwithstanding any other provision of this License, for material you
|
||||||
|
add to a covered work, you may (if authorized by the copyright holders of
|
||||||
|
that material) supplement the terms of this License with terms:
|
||||||
|
|
||||||
|
a) Disclaiming warranty or limiting liability differently from the
|
||||||
|
terms of sections 15 and 16 of this License; or
|
||||||
|
|
||||||
|
b) Requiring preservation of specified reasonable legal notices or
|
||||||
|
author attributions in that material or in the Appropriate Legal
|
||||||
|
Notices displayed by works containing it; or
|
||||||
|
|
||||||
|
c) Prohibiting misrepresentation of the origin of that material, or
|
||||||
|
requiring that modified versions of such material be marked in
|
||||||
|
reasonable ways as different from the original version; or
|
||||||
|
|
||||||
|
d) Limiting the use for publicity purposes of names of licensors or
|
||||||
|
authors of the material; or
|
||||||
|
|
||||||
|
e) Declining to grant rights under trademark law for use of some
|
||||||
|
trade names, trademarks, or service marks; or
|
||||||
|
|
||||||
|
f) Requiring indemnification of licensors and authors of that
|
||||||
|
material by anyone who conveys the material (or modified versions of
|
||||||
|
it) with contractual assumptions of liability to the recipient, for
|
||||||
|
any liability that these contractual assumptions directly impose on
|
||||||
|
those licensors and authors.
|
||||||
|
|
||||||
|
All other non-permissive additional terms are considered "further
|
||||||
|
restrictions" within the meaning of section 10. If the Program as you
|
||||||
|
received it, or any part of it, contains a notice stating that it is
|
||||||
|
governed by this License along with a term that is a further
|
||||||
|
restriction, you may remove that term. If a license document contains
|
||||||
|
a further restriction but permits relicensing or conveying under this
|
||||||
|
License, you may add to a covered work material governed by the terms
|
||||||
|
of that license document, provided that the further restriction does
|
||||||
|
not survive such relicensing or conveying.
|
||||||
|
|
||||||
|
If you add terms to a covered work in accord with this section, you
|
||||||
|
must place, in the relevant source files, a statement of the
|
||||||
|
additional terms that apply to those files, or a notice indicating
|
||||||
|
where to find the applicable terms.
|
||||||
|
|
||||||
|
Additional terms, permissive or non-permissive, may be stated in the
|
||||||
|
form of a separately written license, or stated as exceptions;
|
||||||
|
the above requirements apply either way.
|
||||||
|
|
||||||
|
8. Termination.
|
||||||
|
|
||||||
|
You may not propagate or modify a covered work except as expressly
|
||||||
|
provided under this License. Any attempt otherwise to propagate or
|
||||||
|
modify it is void, and will automatically terminate your rights under
|
||||||
|
this License (including any patent licenses granted under the third
|
||||||
|
paragraph of section 11).
|
||||||
|
|
||||||
|
However, if you cease all violation of this License, then your
|
||||||
|
license from a particular copyright holder is reinstated (a)
|
||||||
|
provisionally, unless and until the copyright holder explicitly and
|
||||||
|
finally terminates your license, and (b) permanently, if the copyright
|
||||||
|
holder fails to notify you of the violation by some reasonable means
|
||||||
|
prior to 60 days after the cessation.
|
||||||
|
|
||||||
|
Moreover, your license from a particular copyright holder is
|
||||||
|
reinstated permanently if the copyright holder notifies you of the
|
||||||
|
violation by some reasonable means, this is the first time you have
|
||||||
|
received notice of violation of this License (for any work) from that
|
||||||
|
copyright holder, and you cure the violation prior to 30 days after
|
||||||
|
your receipt of the notice.
|
||||||
|
|
||||||
|
Termination of your rights under this section does not terminate the
|
||||||
|
licenses of parties who have received copies or rights from you under
|
||||||
|
this License. If your rights have been terminated and not permanently
|
||||||
|
reinstated, you do not qualify to receive new licenses for the same
|
||||||
|
material under section 10.
|
||||||
|
|
||||||
|
9. Acceptance Not Required for Having Copies.
|
||||||
|
|
||||||
|
You are not required to accept this License in order to receive or
|
||||||
|
run a copy of the Program. Ancillary propagation of a covered work
|
||||||
|
occurring solely as a consequence of using peer-to-peer transmission
|
||||||
|
to receive a copy likewise does not require acceptance. However,
|
||||||
|
nothing other than this License grants you permission to propagate or
|
||||||
|
modify any covered work. These actions infringe copyright if you do
|
||||||
|
not accept this License. Therefore, by modifying or propagating a
|
||||||
|
covered work, you indicate your acceptance of this License to do so.
|
||||||
|
|
||||||
|
10. Automatic Licensing of Downstream Recipients.
|
||||||
|
|
||||||
|
Each time you convey a covered work, the recipient automatically
|
||||||
|
receives a license from the original licensors, to run, modify and
|
||||||
|
propagate that work, subject to this License. You are not responsible
|
||||||
|
for enforcing compliance by third parties with this License.
|
||||||
|
|
||||||
|
An "entity transaction" is a transaction transferring control of an
|
||||||
|
organization, or substantially all assets of one, or subdividing an
|
||||||
|
organization, or merging organizations. If propagation of a covered
|
||||||
|
work results from an entity transaction, each party to that
|
||||||
|
transaction who receives a copy of the work also receives whatever
|
||||||
|
licenses to the work the party's predecessor in interest had or could
|
||||||
|
give under the previous paragraph, plus a right to possession of the
|
||||||
|
Corresponding Source of the work from the predecessor in interest, if
|
||||||
|
the predecessor has it or can get it with reasonable efforts.
|
||||||
|
|
||||||
|
You may not impose any further restrictions on the exercise of the
|
||||||
|
rights granted or affirmed under this License. For example, you may
|
||||||
|
not impose a license fee, royalty, or other charge for exercise of
|
||||||
|
rights granted under this License, and you may not initiate litigation
|
||||||
|
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||||
|
any patent claim is infringed by making, using, selling, offering for
|
||||||
|
sale, or importing the Program or any portion of it.
|
||||||
|
|
||||||
|
11. Patents.
|
||||||
|
|
||||||
|
A "contributor" is a copyright holder who authorizes use under this
|
||||||
|
License of the Program or a work on which the Program is based. The
|
||||||
|
work thus licensed is called the contributor's "contributor version".
|
||||||
|
|
||||||
|
A contributor's "essential patent claims" are all patent claims
|
||||||
|
owned or controlled by the contributor, whether already acquired or
|
||||||
|
hereafter acquired, that would be infringed by some manner, permitted
|
||||||
|
by this License, of making, using, or selling its contributor version,
|
||||||
|
but do not include claims that would be infringed only as a
|
||||||
|
consequence of further modification of the contributor version. For
|
||||||
|
purposes of this definition, "control" includes the right to grant
|
||||||
|
patent sublicenses in a manner consistent with the requirements of
|
||||||
|
this License.
|
||||||
|
|
||||||
|
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||||
|
patent license under the contributor's essential patent claims, to
|
||||||
|
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||||
|
propagate the contents of its contributor version.
|
||||||
|
|
||||||
|
In the following three paragraphs, a "patent license" is any express
|
||||||
|
agreement or commitment, however denominated, not to enforce a patent
|
||||||
|
(such as an express permission to practice a patent or covenant not to
|
||||||
|
sue for patent infringement). To "grant" such a patent license to a
|
||||||
|
party means to make such an agreement or commitment not to enforce a
|
||||||
|
patent against the party.
|
||||||
|
|
||||||
|
If you convey a covered work, knowingly relying on a patent license,
|
||||||
|
and the Corresponding Source of the work is not available for anyone
|
||||||
|
to copy, free of charge and under the terms of this License, through a
|
||||||
|
publicly available network server or other readily accessible means,
|
||||||
|
then you must either (1) cause the Corresponding Source to be so
|
||||||
|
available, or (2) arrange to deprive yourself of the benefit of the
|
||||||
|
patent license for this particular work, or (3) arrange, in a manner
|
||||||
|
consistent with the requirements of this License, to extend the patent
|
||||||
|
license to downstream recipients. "Knowingly relying" means you have
|
||||||
|
actual knowledge that, but for the patent license, your conveying the
|
||||||
|
covered work in a country, or your recipient's use of the covered work
|
||||||
|
in a country, would infringe one or more identifiable patents in that
|
||||||
|
country that you have reason to believe are valid.
|
||||||
|
|
||||||
|
If, pursuant to or in connection with a single transaction or
|
||||||
|
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||||
|
covered work, and grant a patent license to some of the parties
|
||||||
|
receiving the covered work authorizing them to use, propagate, modify
|
||||||
|
or convey a specific copy of the covered work, then the patent license
|
||||||
|
you grant is automatically extended to all recipients of the covered
|
||||||
|
work and works based on it.
|
||||||
|
|
||||||
|
A patent license is "discriminatory" if it does not include within
|
||||||
|
the scope of its coverage, prohibits the exercise of, or is
|
||||||
|
conditioned on the non-exercise of one or more of the rights that are
|
||||||
|
specifically granted under this License. You may not convey a covered
|
||||||
|
work if you are a party to an arrangement with a third party that is
|
||||||
|
in the business of distributing software, under which you make payment
|
||||||
|
to the third party based on the extent of your activity of conveying
|
||||||
|
the work, and under which the third party grants, to any of the
|
||||||
|
parties who would receive the covered work from you, a discriminatory
|
||||||
|
patent license (a) in connection with copies of the covered work
|
||||||
|
conveyed by you (or copies made from those copies), or (b) primarily
|
||||||
|
for and in connection with specific products or compilations that
|
||||||
|
contain the covered work, unless you entered into that arrangement,
|
||||||
|
or that patent license was granted, prior to 28 March 2007.
|
||||||
|
|
||||||
|
Nothing in this License shall be construed as excluding or limiting
|
||||||
|
any implied license or other defenses to infringement that may
|
||||||
|
otherwise be available to you under applicable patent law.
|
||||||
|
|
||||||
|
12. No Surrender of Others' Freedom.
|
||||||
|
|
||||||
|
If conditions are imposed on you (whether by court order, agreement or
|
||||||
|
otherwise) that contradict the conditions of this License, they do not
|
||||||
|
excuse you from the conditions of this License. If you cannot convey a
|
||||||
|
covered work so as to satisfy simultaneously your obligations under this
|
||||||
|
License and any other pertinent obligations, then as a consequence you may
|
||||||
|
not convey it at all. For example, if you agree to terms that obligate you
|
||||||
|
to collect a royalty for further conveying from those to whom you convey
|
||||||
|
the Program, the only way you could satisfy both those terms and this
|
||||||
|
License would be to refrain entirely from conveying the Program.
|
||||||
|
|
||||||
|
13. Use with the GNU Affero General Public License.
|
||||||
|
|
||||||
|
Notwithstanding any other provision of this License, you have
|
||||||
|
permission to link or combine any covered work with a work licensed
|
||||||
|
under version 3 of the GNU Affero General Public License into a single
|
||||||
|
combined work, and to convey the resulting work. The terms of this
|
||||||
|
License will continue to apply to the part which is the covered work,
|
||||||
|
but the special requirements of the GNU Affero General Public License,
|
||||||
|
section 13, concerning interaction through a network will apply to the
|
||||||
|
combination as such.
|
||||||
|
|
||||||
|
14. Revised Versions of this License.
|
||||||
|
|
||||||
|
The Free Software Foundation may publish revised and/or new versions of
|
||||||
|
the GNU General Public License from time to time. Such new versions will
|
||||||
|
be similar in spirit to the present version, but may differ in detail to
|
||||||
|
address new problems or concerns.
|
||||||
|
|
||||||
|
Each version is given a distinguishing version number. If the
|
||||||
|
Program specifies that a certain numbered version of the GNU General
|
||||||
|
Public License "or any later version" applies to it, you have the
|
||||||
|
option of following the terms and conditions either of that numbered
|
||||||
|
version or of any later version published by the Free Software
|
||||||
|
Foundation. If the Program does not specify a version number of the
|
||||||
|
GNU General Public License, you may choose any version ever published
|
||||||
|
by the Free Software Foundation.
|
||||||
|
|
||||||
|
If the Program specifies that a proxy can decide which future
|
||||||
|
versions of the GNU General Public License can be used, that proxy's
|
||||||
|
public statement of acceptance of a version permanently authorizes you
|
||||||
|
to choose that version for the Program.
|
||||||
|
|
||||||
|
Later license versions may give you additional or different
|
||||||
|
permissions. However, no additional obligations are imposed on any
|
||||||
|
author or copyright holder as a result of your choosing to follow a
|
||||||
|
later version.
|
||||||
|
|
||||||
|
15. Disclaimer of Warranty.
|
||||||
|
|
||||||
|
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||||
|
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||||
|
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||||
|
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||||
|
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||||
|
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||||
|
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||||
|
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||||
|
|
||||||
|
16. Limitation of Liability.
|
||||||
|
|
||||||
|
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||||
|
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||||
|
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||||
|
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||||
|
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||||
|
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||||
|
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||||
|
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||||
|
SUCH DAMAGES.
|
||||||
|
|
||||||
|
17. Interpretation of Sections 15 and 16.
|
||||||
|
|
||||||
|
If the disclaimer of warranty and limitation of liability provided
|
||||||
|
above cannot be given local legal effect according to their terms,
|
||||||
|
reviewing courts shall apply local law that most closely approximates
|
||||||
|
an absolute waiver of all civil liability in connection with the
|
||||||
|
Program, unless a warranty or assumption of liability accompanies a
|
||||||
|
copy of the Program in return for a fee.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
How to Apply These Terms to Your New Programs
|
||||||
|
|
||||||
|
If you develop a new program, and you want it to be of the greatest
|
||||||
|
possible use to the public, the best way to achieve this is to make it
|
||||||
|
free software which everyone can redistribute and change under these terms.
|
||||||
|
|
||||||
|
To do so, attach the following notices to the program. It is safest
|
||||||
|
to attach them to the start of each source file to most effectively
|
||||||
|
state the exclusion of warranty; and each file should have at least
|
||||||
|
the "copyright" line and a pointer to where the full notice is found.
|
||||||
|
|
||||||
|
<one line to give the program's name and a brief idea of what it does.>
|
||||||
|
Copyright (C) <year> <name of author>
|
||||||
|
|
||||||
|
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 3 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, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
Also add information on how to contact you by electronic and paper mail.
|
||||||
|
|
||||||
|
If the program does terminal interaction, make it output a short
|
||||||
|
notice like this when it starts in an interactive mode:
|
||||||
|
|
||||||
|
<program> Copyright (C) <year> <name of author>
|
||||||
|
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||||
|
This is free software, and you are welcome to redistribute it
|
||||||
|
under certain conditions; type `show c' for details.
|
||||||
|
|
||||||
|
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||||
|
parts of the General Public License. Of course, your program's commands
|
||||||
|
might be different; for a GUI interface, you would use an "about box".
|
||||||
|
|
||||||
|
You should also get your employer (if you work as a programmer) or school,
|
||||||
|
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||||
|
For more information on this, and how to apply and follow the GNU GPL, see
|
||||||
|
<http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
The GNU General Public License does not permit incorporating your program
|
||||||
|
into proprietary programs. If your program is a subroutine library, you
|
||||||
|
may consider it more useful to permit linking proprietary applications with
|
||||||
|
the library. If this is what you want to do, use the GNU Lesser General
|
||||||
|
Public License instead of this License. But first, please read
|
||||||
|
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
||||||
|
|
|
@ -1,31 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
|
|
||||||
from ir import *
|
from ir import *
|
||||||
|
|
35
bin/ir/ir.py
35
bin/ir/ir.py
|
@ -1,31 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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 pickle
|
import pickle
|
||||||
import osv
|
import osv
|
||||||
|
|
|
@ -2,31 +2,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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 time
|
||||||
import threading
|
import threading
|
||||||
|
@ -288,9 +281,13 @@ class SimpleThreadedXMLRPCServer(SocketServer.ThreadingMixIn,
|
||||||
SimpleXMLRPCServer.SimpleXMLRPCServer):
|
SimpleXMLRPCServer.SimpleXMLRPCServer):
|
||||||
|
|
||||||
def server_bind(self):
|
def server_bind(self):
|
||||||
self.socket.setsockopt(socket.SOL_SOCKET,
|
try:
|
||||||
socket.SO_REUSEADDR, 1)
|
self.socket.setsockopt(socket.SOL_SOCKET,
|
||||||
SimpleXMLRPCServer.SimpleXMLRPCServer.server_bind(self)
|
socket.SO_REUSEADDR, 1)
|
||||||
|
SimpleXMLRPCServer.SimpleXMLRPCServer.server_bind(self)
|
||||||
|
except:
|
||||||
|
sys.stderr.write("ERROR: address already in use\n")
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
|
|
||||||
class HttpDaemon(threading.Thread):
|
class HttpDaemon(threading.Thread):
|
||||||
|
@ -309,9 +306,14 @@ class HttpDaemon(threading.Thread):
|
||||||
SecureXMLRPCServer.SecureXMLRPCServer):
|
SecureXMLRPCServer.SecureXMLRPCServer):
|
||||||
|
|
||||||
def server_bind(self):
|
def server_bind(self):
|
||||||
self.socket.setsockopt(socket.SOL_SOCKET,
|
try:
|
||||||
socket.SO_REUSEADDR, 1)
|
self.socket.setsockopt(socket.SOL_SOCKET,
|
||||||
SecureXMLRPCServer.SecureXMLRPCServer.server_bind(self)
|
socket.SO_REUSEADDR, 1)
|
||||||
|
SecureXMLRPCServer.SecureXMLRPCServer.server_bind(self)
|
||||||
|
except:
|
||||||
|
sys.stderr.write("ERROR: address already in use\n")
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
|
|
||||||
self.server = SecureThreadedXMLRPCServer((interface, port),
|
self.server = SecureThreadedXMLRPCServer((interface, port),
|
||||||
SecureXMLRPCRequestHandler, 0)
|
SecureXMLRPCRequestHandler, 0)
|
||||||
|
|
|
@ -2,31 +2,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
"""
|
"""
|
||||||
OpenERP - Server
|
OpenERP - Server
|
||||||
|
|
|
@ -1,31 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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 osv
|
import osv
|
||||||
import fields
|
import fields
|
||||||
|
|
|
@ -1,5 +1,25 @@
|
||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
|
##############################################################################
|
||||||
|
#
|
||||||
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
|
#
|
||||||
|
# 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||||
|
#
|
||||||
|
##############################################################################
|
||||||
|
|
||||||
from tools import flatten, reverse_enumerate
|
from tools import flatten, reverse_enumerate
|
||||||
|
|
||||||
|
@ -232,9 +252,9 @@ class expression(object):
|
||||||
query = '(%s OR %s IS NULL)' % (query, left)
|
query = '(%s OR %s IS NULL)' % (query, left)
|
||||||
else:
|
else:
|
||||||
params = []
|
params = []
|
||||||
if (right == False or right is None) and operator == '=':
|
if (((right == False) and (type(right)==bool)) or (right is None)) and (operator == '='):
|
||||||
query = '%s IS NULL' % left
|
query = '%s IS NULL' % left
|
||||||
elif (right == False or right is None) and operator in ['<>', '!=']:
|
elif (((right == False) and (type(right)==bool)) or right is None) and (operator in ['<>', '!=']):
|
||||||
query = '%s IS NOT NULL' % left
|
query = '%s IS NOT NULL' % left
|
||||||
else:
|
else:
|
||||||
if left == 'id':
|
if left == 'id':
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -81,7 +73,6 @@ class _column(object):
|
||||||
self.ondelete = ondelete
|
self.ondelete = ondelete
|
||||||
self.translate = translate
|
self.translate = translate
|
||||||
self._domain = domain or []
|
self._domain = domain or []
|
||||||
self.relate = False
|
|
||||||
self._context = context
|
self._context = context
|
||||||
self.write = False
|
self.write = False
|
||||||
self.read = False
|
self.read = False
|
||||||
|
@ -90,8 +81,6 @@ class _column(object):
|
||||||
for a in args:
|
for a in args:
|
||||||
if args[a]:
|
if args[a]:
|
||||||
setattr(self, a, args[a])
|
setattr(self, a, args[a])
|
||||||
if self.relate:
|
|
||||||
warnings.warn("The relate attribute doesn't work anymore, use act_window tag instead", DeprecationWarning)
|
|
||||||
|
|
||||||
def restart(self):
|
def restart(self):
|
||||||
pass
|
pass
|
||||||
|
@ -127,6 +116,12 @@ class boolean(_column):
|
||||||
_symbol_set = (_symbol_c, _symbol_f)
|
_symbol_set = (_symbol_c, _symbol_f)
|
||||||
|
|
||||||
|
|
||||||
|
class integer_big(_column):
|
||||||
|
_type = 'integer_big'
|
||||||
|
_symbol_c = '%d'
|
||||||
|
_symbol_f = lambda x: int(x or 0)
|
||||||
|
_symbol_set = (_symbol_c, _symbol_f)
|
||||||
|
|
||||||
class integer(_column):
|
class integer(_column):
|
||||||
_type = 'integer'
|
_type = 'integer'
|
||||||
_symbol_c = '%d'
|
_symbol_c = '%d'
|
||||||
|
@ -475,6 +470,9 @@ class many2many(_column):
|
||||||
def __init__(self, obj, rel, id1, id2, string='unknown', limit=None, **args):
|
def __init__(self, obj, rel, id1, id2, string='unknown', limit=None, **args):
|
||||||
_column.__init__(self, string=string, **args)
|
_column.__init__(self, string=string, **args)
|
||||||
self._obj = obj
|
self._obj = obj
|
||||||
|
if '.' in rel:
|
||||||
|
raise Exception(_('The second argument of the many2many field %s must be a SQL table !'\
|
||||||
|
'You used %s, which is not a valid SQL table name.')% (string,rel))
|
||||||
self._rel = rel
|
self._rel = rel
|
||||||
self._id1 = id1
|
self._id1 = id1
|
||||||
self._id2 = id2
|
self._id2 = id2
|
||||||
|
@ -678,7 +676,7 @@ class related(function):
|
||||||
where += " %s.%s %s '%%%s%%' and" % (obj_child._table, self._arg[i], context[0][1], context[0][2])
|
where += " %s.%s %s '%%%s%%' and" % (obj_child._table, self._arg[i], context[0][1], context[0][2])
|
||||||
if field_detail[1] in ('date'):
|
if field_detail[1] in ('date'):
|
||||||
where += " %s.%s %s '%s' and" % (obj_child._table, self._arg[i], context[0][1], context[0][2])
|
where += " %s.%s %s '%s' and" % (obj_child._table, self._arg[i], context[0][1], context[0][2])
|
||||||
if field_detail[1] in ['integer', 'long', 'float']:
|
if field_detail[1] in ['integer', 'long', 'float','integer_big']:
|
||||||
where += " %s.%s %s '%d' and" % (obj_child._table, self._arg[i], context[0][1], context[0][2])
|
where += " %s.%s %s '%d' and" % (obj_child._table, self._arg[i], context[0][1], context[0][2])
|
||||||
query += where.rstrip('and')
|
query += where.rstrip('and')
|
||||||
cr.execute(query)
|
cr.execute(query)
|
||||||
|
|
164
bin/osv/orm.py
164
bin/osv/orm.py
|
@ -1,31 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Object relationnal mapping to postgresql module
|
# Object relationnal mapping to postgresql module
|
||||||
|
@ -48,7 +41,6 @@
|
||||||
|
|
||||||
import time
|
import time
|
||||||
import types
|
import types
|
||||||
from xml import dom, xpath
|
|
||||||
import string
|
import string
|
||||||
import netsvc
|
import netsvc
|
||||||
import re
|
import re
|
||||||
|
@ -58,6 +50,14 @@ import pickle
|
||||||
import fields
|
import fields
|
||||||
import tools
|
import tools
|
||||||
|
|
||||||
|
import sys
|
||||||
|
try:
|
||||||
|
from xml import dom, xpath
|
||||||
|
except ImportError:
|
||||||
|
sys.stderr.write("ERROR: Import xpath module\n")
|
||||||
|
sys.stderr.write("ERROR: Try to install the old python-xml package\n")
|
||||||
|
sys.exit(2)
|
||||||
|
|
||||||
from tools.config import config
|
from tools.config import config
|
||||||
|
|
||||||
regex_order = re.compile('^([a-zA-Z0-9_]+( desc)?( asc)?,?)+$', re.I)
|
regex_order = re.compile('^([a-zA-Z0-9_]+( desc)?( asc)?,?)+$', re.I)
|
||||||
|
@ -83,6 +83,9 @@ class browse_null(object):
|
||||||
def __getitem__(self, name):
|
def __getitem__(self, name):
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
def __getattr__(self, name):
|
||||||
|
return False # XXX: return self ?
|
||||||
|
|
||||||
def __int__(self):
|
def __int__(self):
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
@ -237,6 +240,7 @@ def get_pg_type(f):
|
||||||
type_dict = {
|
type_dict = {
|
||||||
fields.boolean: 'bool',
|
fields.boolean: 'bool',
|
||||||
fields.integer: 'int4',
|
fields.integer: 'int4',
|
||||||
|
fields.integer_big: 'int8',
|
||||||
fields.text: 'text',
|
fields.text: 'text',
|
||||||
fields.date: 'date',
|
fields.date: 'date',
|
||||||
fields.time: 'time',
|
fields.time: 'time',
|
||||||
|
@ -321,7 +325,6 @@ class orm_template(object):
|
||||||
'name': k,
|
'name': k,
|
||||||
'field_description': f.string.replace("'", " "),
|
'field_description': f.string.replace("'", " "),
|
||||||
'ttype': f._type,
|
'ttype': f._type,
|
||||||
'relate': (f.relate and 1) or 0,
|
|
||||||
'relation': f._obj or 'NULL',
|
'relation': f._obj or 'NULL',
|
||||||
'view_load': (f.view_load and 1) or 0,
|
'view_load': (f.view_load and 1) or 0,
|
||||||
'select_level': str(f.select or 0),
|
'select_level': str(f.select or 0),
|
||||||
|
@ -334,12 +337,12 @@ class orm_template(object):
|
||||||
vals['id'] = id
|
vals['id'] = id
|
||||||
cr.execute("""INSERT INTO ir_model_fields (
|
cr.execute("""INSERT INTO ir_model_fields (
|
||||||
id, model_id, model, name, field_description, ttype,
|
id, model_id, model, name, field_description, ttype,
|
||||||
relate,relation,view_load,state,select_level
|
relation,view_load,state,select_level
|
||||||
) VALUES (
|
) VALUES (
|
||||||
%d,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s
|
%d,%s,%s,%s,%s,%s,%s,%s,%s,%s
|
||||||
)""", (
|
)""", (
|
||||||
id, vals['model_id'], vals['model'], vals['name'], vals['field_description'], vals['ttype'],
|
id, vals['model_id'], vals['model'], vals['name'], vals['field_description'], vals['ttype'],
|
||||||
bool(vals['relate']), vals['relation'], bool(vals['view_load']), 'base',
|
vals['relation'], bool(vals['view_load']), 'base',
|
||||||
vals['select_level']
|
vals['select_level']
|
||||||
))
|
))
|
||||||
if 'module' in context:
|
if 'module' in context:
|
||||||
|
@ -352,11 +355,11 @@ class orm_template(object):
|
||||||
cr.execute('update ir_model_fields set field_description=%s where model=%s and name=%s', (vals['field_description'], vals['model'], vals['name']))
|
cr.execute('update ir_model_fields set field_description=%s where model=%s and name=%s', (vals['field_description'], vals['model'], vals['name']))
|
||||||
cr.commit()
|
cr.commit()
|
||||||
cr.execute("""UPDATE ir_model_fields SET
|
cr.execute("""UPDATE ir_model_fields SET
|
||||||
model_id=%s, field_description=%s, ttype=%s, relate=%s, relation=%s,
|
model_id=%s, field_description=%s, ttype=%s, relation=%s,
|
||||||
view_load=%s, select_level=%s, readonly=%s ,required=%s
|
view_load=%s, select_level=%s, readonly=%s ,required=%s
|
||||||
WHERE
|
WHERE
|
||||||
model=%s AND name=%s""", (
|
model=%s AND name=%s""", (
|
||||||
vals['model_id'], vals['field_description'], vals['ttype'], bool(vals['relate']),
|
vals['model_id'], vals['field_description'], vals['ttype'],
|
||||||
vals['relation'], bool(vals['view_load']),
|
vals['relation'], bool(vals['view_load']),
|
||||||
vals['select_level'], bool(vals['readonly']),bool(vals['required']), vals['model'], vals['name']
|
vals['select_level'], bool(vals['readonly']),bool(vals['required']), vals['model'], vals['name']
|
||||||
))
|
))
|
||||||
|
@ -367,6 +370,14 @@ class orm_template(object):
|
||||||
self._field_create(cr, context)
|
self._field_create(cr, context)
|
||||||
|
|
||||||
def __init__(self, cr):
|
def __init__(self, cr):
|
||||||
|
if not self._name and not hasattr(self, '_inherit'):
|
||||||
|
name = type(self).__name__.split('.')[0]
|
||||||
|
msg = "The class %s has to have a _name attribute" % name
|
||||||
|
|
||||||
|
logger = netsvc.Logger()
|
||||||
|
logger.notifyChannel('orm', netsvc.LOG_ERROR, msg )
|
||||||
|
raise except_orm('ValueError', msg )
|
||||||
|
|
||||||
if not self._description:
|
if not self._description:
|
||||||
self._description = self._name
|
self._description = self._name
|
||||||
if not self._table:
|
if not self._table:
|
||||||
|
@ -709,9 +720,11 @@ class orm_template(object):
|
||||||
# translate each selection option
|
# translate each selection option
|
||||||
sel2 = []
|
sel2 = []
|
||||||
for (key, val) in sel:
|
for (key, val) in sel:
|
||||||
val2 = translation_obj._get_source(cr, user,
|
val2 = None
|
||||||
|
if val:
|
||||||
|
val2 = translation_obj._get_source(cr, user,
|
||||||
self._name + ',' + f, 'selection',
|
self._name + ',' + f, 'selection',
|
||||||
context.get('lang', False) or 'en_US', val)
|
context.get('lang', False) or 'en_US', val)
|
||||||
sel2.append((key, val2 or val))
|
sel2.append((key, val2 or val))
|
||||||
sel = sel2
|
sel = sel2
|
||||||
res[f]['selection'] = sel
|
res[f]['selection'] = sel
|
||||||
|
@ -768,6 +781,11 @@ class orm_template(object):
|
||||||
'fields': xfields
|
'fields': xfields
|
||||||
}
|
}
|
||||||
attrs = {'views': views}
|
attrs = {'views': views}
|
||||||
|
if node.hasAttribute('widget') and node.getAttribute('widget')=='selection':
|
||||||
|
# We can not use the domain has it is defined according to the record !
|
||||||
|
attrs['selection'] = self.pool.get(relation).name_search(cr, user, '', context=context)
|
||||||
|
if not attrs.get('required',False):
|
||||||
|
attrs['selection'].append((False,''))
|
||||||
fields[node.getAttribute('name')] = attrs
|
fields[node.getAttribute('name')] = attrs
|
||||||
|
|
||||||
elif node.nodeType==node.ELEMENT_NODE and node.localName in ('form', 'tree'):
|
elif node.nodeType==node.ELEMENT_NODE and node.localName in ('form', 'tree'):
|
||||||
|
@ -814,14 +832,15 @@ class orm_template(object):
|
||||||
continue
|
continue
|
||||||
|
|
||||||
ok = True
|
ok = True
|
||||||
|
|
||||||
serv = netsvc.LocalService('object_proxy')
|
if user != 1: # admin user has all roles
|
||||||
user_roles = serv.execute_cr(cr, user, 'res.users', 'read', [user], ['roles_id'])[0]['roles_id']
|
serv = netsvc.LocalService('object_proxy')
|
||||||
cr.execute("select role_id from wkf_transition where signal='%s'" % button.getAttribute('name'))
|
user_roles = serv.execute_cr(cr, user, 'res.users', 'read', [user], ['roles_id'])[0]['roles_id']
|
||||||
roles = cr.fetchall()
|
cr.execute("select role_id from wkf_transition where signal='%s'" % button.getAttribute('name'))
|
||||||
for role in roles:
|
roles = cr.fetchall()
|
||||||
if role[0]:
|
for role in roles:
|
||||||
ok = ok and serv.execute_cr(cr, user, 'res.roles', 'check', user_roles, role[0])
|
if role[0]:
|
||||||
|
ok = ok and serv.execute_cr(cr, user, 'res.roles', 'check', user_roles, role[0])
|
||||||
|
|
||||||
if not ok:
|
if not ok:
|
||||||
button.setAttribute('readonly', '1')
|
button.setAttribute('readonly', '1')
|
||||||
|
@ -873,7 +892,6 @@ class orm_template(object):
|
||||||
context = {}
|
context = {}
|
||||||
def _inherit_apply(src, inherit):
|
def _inherit_apply(src, inherit):
|
||||||
def _find(node, node2):
|
def _find(node, node2):
|
||||||
# Check if xpath query or normal inherit (with field matching)
|
|
||||||
if node2.nodeType == node2.ELEMENT_NODE and node2.localName == 'xpath':
|
if node2.nodeType == node2.ELEMENT_NODE and node2.localName == 'xpath':
|
||||||
res = xpath.Evaluate(node2.getAttribute('expr'), node)
|
res = xpath.Evaluate(node2.getAttribute('expr'), node)
|
||||||
return res and res[0]
|
return res and res[0]
|
||||||
|
@ -917,16 +935,13 @@ class orm_template(object):
|
||||||
parent.insertBefore(child, node)
|
parent.insertBefore(child, node)
|
||||||
parent.removeChild(node)
|
parent.removeChild(node)
|
||||||
else:
|
else:
|
||||||
|
sib = node.nextSibling
|
||||||
for child in node2.childNodes:
|
for child in node2.childNodes:
|
||||||
if child.nodeType == child.ELEMENT_NODE:
|
if child.nodeType == child.ELEMENT_NODE:
|
||||||
if pos == 'inside':
|
if pos == 'inside':
|
||||||
node.appendChild(child)
|
node.appendChild(child)
|
||||||
elif pos == 'after':
|
elif pos == 'after':
|
||||||
sib = node.nextSibling
|
node.parentNode.insertBefore(child, sib)
|
||||||
if sib:
|
|
||||||
node.parentNode.insertBefore(child, sib)
|
|
||||||
else:
|
|
||||||
node.parentNode.appendChild(child)
|
|
||||||
elif pos=='before':
|
elif pos=='before':
|
||||||
node.parentNode.insertBefore(child, node)
|
node.parentNode.insertBefore(child, node)
|
||||||
else:
|
else:
|
||||||
|
@ -1227,6 +1242,11 @@ class orm_memory(orm_template):
|
||||||
field_value2[i][field2] = field_value[i][field2]
|
field_value2[i][field2] = field_value[i][field2]
|
||||||
field_value = field_value2
|
field_value = field_value2
|
||||||
value[field] = field_value
|
value[field] = field_value
|
||||||
|
|
||||||
|
# get the default values from the context
|
||||||
|
for key in context or {}:
|
||||||
|
if key.startswith('default_'):
|
||||||
|
value[key[8:]] = context[key]
|
||||||
return value
|
return value
|
||||||
|
|
||||||
def search(self, cr, user, args, offset=0, limit=None, order=None,
|
def search(self, cr, user, args, offset=0, limit=None, order=None,
|
||||||
|
@ -1389,7 +1409,10 @@ class orm(orm_template):
|
||||||
for key,val in res.items():
|
for key,val in res.items():
|
||||||
if f._multi:
|
if f._multi:
|
||||||
val = val[k]
|
val = val[k]
|
||||||
cr.execute("UPDATE \"%s\" SET \"%s\"='%s' where id=%d"% (self._table, k, val, key))
|
if (val<>False) or (type(val)<>bool):
|
||||||
|
cr.execute("UPDATE \"%s\" SET \"%s\"='%s' where id=%d"% (self._table, k, val, key))
|
||||||
|
#else:
|
||||||
|
# cr.execute("UPDATE \"%s\" SET \"%s\"=NULL where id=%d"% (self._table, k, key))
|
||||||
|
|
||||||
# and add constraints if needed
|
# and add constraints if needed
|
||||||
if isinstance(f, fields.many2one):
|
if isinstance(f, fields.many2one):
|
||||||
|
@ -1528,6 +1551,7 @@ class orm(orm_template):
|
||||||
|
|
||||||
def __init__(self, cr):
|
def __init__(self, cr):
|
||||||
super(orm, self).__init__(cr)
|
super(orm, self).__init__(cr)
|
||||||
|
self._columns = self._columns.copy()
|
||||||
f = filter(lambda a: isinstance(self._columns[a], fields.function) and self._columns[a].store, self._columns)
|
f = filter(lambda a: isinstance(self._columns[a], fields.function) and self._columns[a].store, self._columns)
|
||||||
if f:
|
if f:
|
||||||
list_store = []
|
list_store = []
|
||||||
|
@ -1573,12 +1597,18 @@ class orm(orm_template):
|
||||||
'translate': (field['translate']),
|
'translate': (field['translate']),
|
||||||
#'select': int(field['select_level'])
|
#'select': int(field['select_level'])
|
||||||
}
|
}
|
||||||
#if field['relation']:
|
|
||||||
# attrs['relation'] = field['relation']
|
|
||||||
if field['ttype'] == 'selection':
|
if field['ttype'] == 'selection':
|
||||||
self._columns[field['name']] = getattr(fields, field['ttype'])(eval(field['selection']), **attrs)
|
self._columns[field['name']] = getattr(fields, field['ttype'])(eval(field['selection']), **attrs)
|
||||||
elif field['ttype'] == 'many2one':
|
elif field['ttype'] == 'many2one':
|
||||||
self._columns[field['name']] = getattr(fields, field['ttype'])(field['relation'], **attrs)
|
self._columns[field['name']] = getattr(fields, field['ttype'])(field['relation'], **attrs)
|
||||||
|
elif field['ttype'] == 'one2many':
|
||||||
|
self._columns[field['name']] = getattr(fields, field['ttype'])(field['relation'], field['relation_field'], **attrs)
|
||||||
|
elif field['ttype'] == 'many2many':
|
||||||
|
import random
|
||||||
|
_rel1 = field['relation'].replace('.', '_')
|
||||||
|
_rel2 = field['model'].replace('.', '_')
|
||||||
|
_rel_name = 'x_%s_%s_%s_rel' %(_rel1, _rel2, random.randint(0, 10000))
|
||||||
|
self._columns[field['name']] = getattr(fields, field['ttype'])(field['relation'], _rel_name, 'id1', 'id2', **attrs)
|
||||||
else:
|
else:
|
||||||
self._columns[field['name']] = getattr(fields, field['ttype'])(**attrs)
|
self._columns[field['name']] = getattr(fields, field['ttype'])(**attrs)
|
||||||
|
|
||||||
|
@ -1652,6 +1682,9 @@ class orm(orm_template):
|
||||||
field_value2[i][field2] = field_value[i][field2]
|
field_value2[i][field2] = field_value[i][field2]
|
||||||
field_value = field_value2
|
field_value = field_value2
|
||||||
value[field] = field_value
|
value[field] = field_value
|
||||||
|
for key in context or {}:
|
||||||
|
if key.startswith('default_'):
|
||||||
|
value[key[8:]] = context[key]
|
||||||
return value
|
return value
|
||||||
|
|
||||||
|
|
||||||
|
@ -2300,7 +2333,10 @@ class orm(orm_template):
|
||||||
continue
|
continue
|
||||||
value = res[field]
|
value = res[field]
|
||||||
if self._columns[field]._type in ('many2one', 'one2one'):
|
if self._columns[field]._type in ('many2one', 'one2one'):
|
||||||
value = res[field][0]
|
try:
|
||||||
|
value = res[field][0]
|
||||||
|
except:
|
||||||
|
value = res[field]
|
||||||
upd0.append('"'+field+'"='+self._columns[field]._symbol_set[0])
|
upd0.append('"'+field+'"='+self._columns[field]._symbol_set[0])
|
||||||
upd1.append(self._columns[field]._symbol_set[1](value))
|
upd1.append(self._columns[field]._symbol_set[1](value))
|
||||||
upd1.append(res['id'])
|
upd1.append(res['id'])
|
||||||
|
@ -2449,10 +2485,40 @@ class orm(orm_template):
|
||||||
data[f] = res
|
data[f] = res
|
||||||
elif ftype == 'many2many':
|
elif ftype == 'many2many':
|
||||||
data[f] = [(6, 0, data[f])]
|
data[f] = [(6, 0, data[f])]
|
||||||
|
|
||||||
|
trans_obj = self.pool.get('ir.translation')
|
||||||
|
trans_name=''
|
||||||
|
trans_data=[]
|
||||||
|
for f in fields:
|
||||||
|
trans_flag=True
|
||||||
|
if f in self._columns and self._columns[f].translate:
|
||||||
|
trans_name=self._name+","+f
|
||||||
|
elif f in self._inherit_fields and self._inherit_fields[f][2].translate:
|
||||||
|
trans_name=self._inherit_fields[f][0]+","+f
|
||||||
|
else:
|
||||||
|
trans_flag=False
|
||||||
|
|
||||||
|
if trans_flag:
|
||||||
|
trans_ids = trans_obj.search(cr, uid, [
|
||||||
|
('name', '=', trans_name),
|
||||||
|
('res_id','=',data['id'])
|
||||||
|
])
|
||||||
|
|
||||||
|
trans_data.extend(trans_obj.read(cr,uid,trans_ids,context=context))
|
||||||
|
|
||||||
del data['id']
|
del data['id']
|
||||||
|
|
||||||
for v in self._inherits:
|
for v in self._inherits:
|
||||||
del data[self._inherits[v]]
|
del data[self._inherits[v]]
|
||||||
return self.create(cr, uid, data)
|
|
||||||
|
new_id=self.create(cr, uid, data)
|
||||||
|
|
||||||
|
for record in trans_data:
|
||||||
|
del record['id']
|
||||||
|
record['res_id']=new_id
|
||||||
|
trans_obj.create(cr,uid,record)
|
||||||
|
|
||||||
|
return new_id
|
||||||
|
|
||||||
def read_string(self, cr, uid, id, langs, fields=None, context=None):
|
def read_string(self, cr, uid, id, langs, fields=None, context=None):
|
||||||
if not context:
|
if not context:
|
||||||
|
|
|
@ -1,31 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# OSV: Objects Services
|
# OSV: Objects Services
|
||||||
|
@ -158,11 +151,9 @@ class osv_pool(netsvc.Service):
|
||||||
module = module.split('.')[0][2:]
|
module = module.split('.')[0][2:]
|
||||||
self.module_object_list.setdefault(module, []).append(obj_inst)
|
self.module_object_list.setdefault(module, []).append(obj_inst)
|
||||||
|
|
||||||
|
# Return False if object does not exist
|
||||||
def get(self, name):
|
def get(self, name):
|
||||||
obj = self.obj_pool.get(name, None)
|
obj = self.obj_pool.get(name, None)
|
||||||
# We cannot uncomment this line because it breaks initialisation since objects do not initialize
|
|
||||||
# in the correct order and the ORM doesnt support correctly when some objets do not exist yet
|
|
||||||
# assert obj, "object %s does not exist !" % name
|
|
||||||
return obj
|
return obj
|
||||||
|
|
||||||
#TODO: pass a list of modules to load
|
#TODO: pass a list of modules to load
|
||||||
|
|
|
@ -1,31 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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 sql_db
|
import sql_db
|
||||||
import osv.osv
|
import osv.osv
|
||||||
|
|
|
@ -2,34 +2,27 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
name = 'openerp-server'
|
name = 'openerp-server'
|
||||||
version = '4.3.99'
|
version = '5.0.0-alpha'
|
||||||
description = 'OpenERP Server'
|
description = 'OpenERP Server'
|
||||||
long_desc = '''\
|
long_desc = '''\
|
||||||
OpenERP is a complete ERP and CRM. The main features are accounting (analytic
|
OpenERP is a complete ERP and CRM. The main features are accounting (analytic
|
||||||
|
@ -47,7 +40,7 @@ url = 'http://www.openerp.com'
|
||||||
author = 'Tiny.be'
|
author = 'Tiny.be'
|
||||||
author_email = 'info@tiny.be'
|
author_email = 'info@tiny.be'
|
||||||
support_email = 'support@openerp.com'
|
support_email = 'support@openerp.com'
|
||||||
license = 'GPL-2'
|
license = 'GPL-3'
|
||||||
|
|
||||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
@ -34,6 +26,7 @@ import print_fnc
|
||||||
import custom
|
import custom
|
||||||
import render
|
import render
|
||||||
import pychart
|
import pychart
|
||||||
|
import int_to_text
|
||||||
|
|
||||||
import report_sxw
|
import report_sxw
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,31 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
from pychart import *
|
from pychart import *
|
||||||
|
|
||||||
colorline = [color.T(r=((r+3) % 11)/10.0,
|
colorline = [color.T(r=((r+3) % 11)/10.0,
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,47 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
# trml2pdf - An RML to PDF converter
|
|
||||||
# Copyright (C) 2003, Fabien Pinckaers, UCL, FSA
|
|
||||||
#
|
|
||||||
# This library is free software; you can redistribute it and/or
|
|
||||||
# modify it under the terms of the GNU Lesser General Public
|
|
||||||
# License as published by the Free Software Foundation; either
|
|
||||||
# version 2.1 of the License, or (at your option) any later version.
|
|
||||||
#
|
|
||||||
# This library 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
|
|
||||||
# Lesser General Public License for more details.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU Lesser General Public
|
|
||||||
# License along with this library; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
|
|
||||||
from rml2html import parseString
|
from rml2html import parseString
|
||||||
|
|
||||||
|
|
|
@ -1,32 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
#!/usr/bin/python
|
|
||||||
|
|
||||||
# Copyright (C) 2005, Fabien Pinckaers, UCL, FSA
|
# Copyright (C) 2005, Fabien Pinckaers, UCL, FSA
|
||||||
#
|
#
|
||||||
|
|
|
@ -1,47 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
# trml2pdf - An RML to PDF converter
|
|
||||||
# Copyright (C) 2003, Fabien Pinckaers, UCL, FSA
|
|
||||||
#
|
|
||||||
# This library is free software; you can redistribute it and/or
|
|
||||||
# modify it under the terms of the GNU Lesser General Public
|
|
||||||
# License as published by the Free Software Foundation; either
|
|
||||||
# version 2.1 of the License, or (at your option) any later version.
|
|
||||||
#
|
|
||||||
# This library 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
|
|
||||||
# Lesser General Public License for more details.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU Lesser General Public
|
|
||||||
# License along with this library; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
|
|
||||||
import re
|
import re
|
||||||
import reportlab
|
import reportlab
|
||||||
|
|
|
@ -1,30 +1,22 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 TINY SPRL. (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
#
|
#
|
||||||
##############################################################################
|
##############################################################################
|
||||||
|
|
||||||
|
|
|
@ -1,47 +1,24 @@
|
||||||
# -*- encoding: utf-8 -*-
|
# -*- encoding: utf-8 -*-
|
||||||
##############################################################################
|
##############################################################################
|
||||||
#
|
#
|
||||||
# Copyright (c) 2004-2008 Tiny SPRL (http://tiny.be) All Rights Reserved.
|
# OpenERP, Open Source Management Solution
|
||||||
|
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
|
||||||
|
# $Id$
|
||||||
#
|
#
|
||||||
# $Id$
|
# 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 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
#
|
#
|
||||||
# WARNING: This program as such is intended to be used by professional
|
# This program is distributed in the hope that it will be useful,
|
||||||
# programmers who take the whole responsability of assessing all potential
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# consequences resulting from its eventual inadequacies and bugs
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# End users who are looking for a ready-to-use solution with commercial
|
# GNU General Public License for more details.
|
||||||
# garantees and support are strongly adviced to contract a Free Software
|
|
||||||
# Service Company
|
|
||||||
#
|
#
|
||||||
# This program is Free Software; you can redistribute it and/or
|
# You should have received a copy of the GNU General Public License
|
||||||
# modify it under the terms of the GNU General Public License
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# 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.
|
|
||||||
###############################################################################
|
|
||||||
# trml2pdf - An RML to PDF converter
|
|
||||||
# Copyright (C) 2003, Fabien Pinckaers, UCL, FSA
|
|
||||||
#
|
|
||||||
# This library is free software; you can redistribute it and/or
|
|
||||||
# modify it under the terms of the GNU Lesser General Public
|
|
||||||
# License as published by the Free Software Foundation; either
|
|
||||||
# version 2.1 of the License, or (at your option) any later version.
|
|
||||||
#
|
|
||||||
# This library 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
|
|
||||||
# Lesser General Public License for more details.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU Lesser General Public
|
|
||||||
# License along with this library; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
|
|
||||||
from reportlab.lib import colors
|
from reportlab.lib import colors
|
||||||
import re
|
import re
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue