[ADD] Inherit copy to add (copy) in the name field
[IMP] Update template and french translation bzr revid: christophe.chauvet@syleam.fr-20091208101725-dp7al0teb8eq2zj2
This commit is contained in:
parent
a4cfc08caf
commit
d75a0e5133
|
@ -5,8 +5,8 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: support@openerp.com\n"
|
||||
"POT-Creation-Date: 2009-12-08 09:51:18+0000\n"
|
||||
"PO-Revision-Date: 2009-12-08 10:52+0100\n"
|
||||
"POT-Creation-Date: 2009-12-08 10:15:44+0000\n"
|
||||
"PO-Revision-Date: 2009-12-08 11:16+0100\n"
|
||||
"Last-Translator: Christophe Chauvet <christophe.chauvet@syleam.fr>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
|
@ -162,6 +162,12 @@ msgstr "Erreur: code EAN invalide"
|
|||
msgid "Expression, must be True to match"
|
||||
msgstr "L'expression doit être à True pour correspondre"
|
||||
|
||||
#. module: multi_company
|
||||
#: code:addons/multi_company/multi_company.py:0
|
||||
#, python-format
|
||||
msgid " (copy)"
|
||||
msgstr " (copie)"
|
||||
|
||||
#. module: multi_company
|
||||
#: view:multi_company.default:0
|
||||
msgid "Matching"
|
||||
|
|
|
@ -6,8 +6,8 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: OpenERP Server 5.0.6\n"
|
||||
"Report-Msgid-Bugs-To: support@openerp.com\n"
|
||||
"POT-Creation-Date: 2009-12-08 09:51:18+0000\n"
|
||||
"PO-Revision-Date: 2009-12-08 09:51:18+0000\n"
|
||||
"POT-Creation-Date: 2009-12-08 10:15:44+0000\n"
|
||||
"PO-Revision-Date: 2009-12-08 10:15:44+0000\n"
|
||||
"Last-Translator: <>\n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
|
@ -159,6 +159,12 @@ msgstr ""
|
|||
msgid "Expression, must be True to match"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: code:addons/multi_company/multi_company.py:0
|
||||
#, python-format
|
||||
msgid " (copy)"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: view:multi_company.default:0
|
||||
msgid "Matching"
|
||||
|
|
|
@ -26,6 +26,7 @@ for each company
|
|||
|
||||
from osv import osv
|
||||
from osv import fields
|
||||
from tools.translate import _
|
||||
|
||||
class multi_company_default(osv.osv):
|
||||
"""
|
||||
|
@ -53,6 +54,19 @@ class multi_company_default(osv.osv):
|
|||
'sequence': lambda *a: 100,
|
||||
}
|
||||
|
||||
def copy(self, cr, uid, id, default=None, context=None):
|
||||
"""
|
||||
Add (copy) in the name when duplicate record
|
||||
"""
|
||||
if not context:
|
||||
context = {}
|
||||
if not default:
|
||||
default = {}
|
||||
company = self.browse(cr, uid, id, context=context)
|
||||
default = default.copy()
|
||||
default['name'] = company.name + _(' (copy)')
|
||||
return super(multi_company_default, self).copy(cr, uid, id, default, context=context)
|
||||
|
||||
multi_company_default()
|
||||
|
||||
class res_company(osv.osv):
|
||||
|
|
Loading…
Reference in New Issue