@@ -1271,6 +1271,20 @@
|
||||
<field name="currency_id" ref="INR"/>
|
||||
<field eval="time.strftime('%Y-01-01')" name="name"/>
|
||||
</record>
|
||||
|
||||
<record id="AUD" model="res.currency">
|
||||
<field name="name">AUD</field>
|
||||
<field name="code">AUD</field>
|
||||
<field name="rounding">0.01</field>
|
||||
<field name="accuracy">4</field>
|
||||
<field name="company_id" ref="main_company"/>
|
||||
</record>
|
||||
<record id="rateAUD" model="res.currency.rate">
|
||||
<field name="rate">1.5266</field>
|
||||
<field name="currency_id" ref="AUD"/>
|
||||
<field eval="time.strftime('%Y-01-01')" name="name"/>
|
||||
</record>
|
||||
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -7,13 +7,13 @@ msgstr ""
|
||||
"Project-Id-Version: OpenERP Server 5.0.4\n"
|
||||
"Report-Msgid-Bugs-To: support@openerp.com\n"
|
||||
"POT-Creation-Date: 2009-12-18 08:39+0000\n"
|
||||
"PO-Revision-Date: 2010-02-22 05:40+0000\n"
|
||||
"PO-Revision-Date: 2010-02-25 06:18+0000\n"
|
||||
"Last-Translator: goranc <goranc@gmail.com>\n"
|
||||
"Language-Team: openerp-translators\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-02-23 05:05+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-02-26 04:49+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
"Language: hr\n"
|
||||
|
||||
@@ -1458,7 +1458,7 @@ msgstr "Madagaskar"
|
||||
msgid ""
|
||||
"The Object name must start with x_ and not contain any special character !"
|
||||
msgstr ""
|
||||
"aziv objekta mora početi s x_ i ne smije sadržavati posebne znakove !"
|
||||
"Naziv objekta mora početi s x_ i ne smije sadržavati posebne znakove !"
|
||||
|
||||
#. module: base
|
||||
#: help:ir.rule.group,global:0
|
||||
|
||||
@@ -8,13 +8,13 @@ msgstr ""
|
||||
"Project-Id-Version: openobject-server\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"POT-Creation-Date: 2009-12-18 08:39+0000\n"
|
||||
"PO-Revision-Date: 2010-02-22 05:38+0000\n"
|
||||
"Last-Translator: Fabien (Open ERP) <fp@tinyerp.com>\n"
|
||||
"PO-Revision-Date: 2010-02-25 06:23+0000\n"
|
||||
"Last-Translator: OpenERP Administrators <Unknown>\n"
|
||||
"Language-Team: Japanese <ja@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-02-23 05:04+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-02-26 04:49+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: base
|
||||
@@ -25,7 +25,7 @@ msgstr "セント・ヘレナ"
|
||||
#. module: base
|
||||
#: wizard_view:res.partner.sms_send,init:0
|
||||
msgid "SMS - Gateway: clickatell"
|
||||
msgstr ""
|
||||
msgstr "SMS - ゲートウェイ:clickatell"
|
||||
|
||||
#. module: base
|
||||
#: view:res.lang:0
|
||||
|
||||
@@ -7,13 +7,13 @@ msgstr ""
|
||||
"Project-Id-Version: OpenERP Server 5.0.0\n"
|
||||
"Report-Msgid-Bugs-To: support@openerp.com\n"
|
||||
"POT-Creation-Date: 2009-12-18 08:39+0000\n"
|
||||
"PO-Revision-Date: 2010-02-15 05:47+0000\n"
|
||||
"Last-Translator: Walter Cheuk <wwycheuk@gmail.com>\n"
|
||||
"PO-Revision-Date: 2010-02-24 06:09+0000\n"
|
||||
"Last-Translator: OpenERP Administrators <Unknown>\n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-02-17 04:54+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-02-25 04:50+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: base
|
||||
@@ -40,7 +40,7 @@ msgstr ""
|
||||
#: field:ir.ui.view,arch:0
|
||||
#: field:ir.ui.view.custom,arch:0
|
||||
msgid "View Architecture"
|
||||
msgstr "视图结构"
|
||||
msgstr "視圖結構"
|
||||
|
||||
#. module: base
|
||||
#: code:addons/base/ir/ir_model.py:0
|
||||
@@ -58,7 +58,7 @@ msgstr ""
|
||||
#: field:workflow.activity,wkf_id:0
|
||||
#: field:workflow.instance,wkf_id:0
|
||||
msgid "Workflow"
|
||||
msgstr "工作流"
|
||||
msgstr "工作流程"
|
||||
|
||||
#. module: base
|
||||
#: view:wizard.module.lang.export:0
|
||||
@@ -7784,7 +7784,7 @@ msgstr ""
|
||||
#. module: base
|
||||
#: field:ir.actions.server,mobile:0
|
||||
msgid "Mobile No"
|
||||
msgstr ""
|
||||
msgstr "手機號碼"
|
||||
|
||||
#. module: base
|
||||
#: model:ir.actions.act_window,name:base.action_partner_by_category
|
||||
@@ -7886,12 +7886,12 @@ msgstr ""
|
||||
#: code:addons/base/res/partner/partner.py:0
|
||||
#, python-format
|
||||
msgid "Partners: "
|
||||
msgstr ""
|
||||
msgstr "合作伙伴 "
|
||||
|
||||
#. module: base
|
||||
#: model:res.country,name:base.kp
|
||||
msgid "North Korea"
|
||||
msgstr ""
|
||||
msgstr "北韓(North Korea)"
|
||||
|
||||
#. module: base
|
||||
#: view:ir.report.custom:0
|
||||
@@ -7921,7 +7921,7 @@ msgstr ""
|
||||
#. module: base
|
||||
#: field:ir.exports,name:0
|
||||
msgid "Export Name"
|
||||
msgstr ""
|
||||
msgstr "匯出名稱"
|
||||
|
||||
#. module: base
|
||||
#: help:res.partner.address,type:0
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
</record>
|
||||
|
||||
<record model="res.groups" id="group_multi_company">
|
||||
<field name="name">Useability / Multi Company</field>
|
||||
<field name="name">Multi Companies</field>
|
||||
</record>
|
||||
|
||||
<record model="res.groups" context="{'noadmin':True}" id="group_extended">
|
||||
@@ -29,10 +29,6 @@
|
||||
<field name="name">Useability / No One</field>
|
||||
</record>
|
||||
|
||||
<record model="res.groups" id="group_multi_company">
|
||||
<field name="name">Multi Companies</field>
|
||||
</record>
|
||||
|
||||
<!--
|
||||
Users
|
||||
-->
|
||||
|
||||
+29
-8
@@ -1849,18 +1849,22 @@ class orm(orm_template):
|
||||
self.pool.get('ir.model.access').check(cr, uid, self._name, 'read', context=context)
|
||||
if not fields:
|
||||
fields = self._columns.keys()
|
||||
|
||||
(qu1, qu2, tables) = self._where_calc(cr, uid, domain, context=context)
|
||||
|
||||
(where_clause, where_params, tables) = self._where_calc(cr, uid, domain, context=context)
|
||||
dom = self.pool.get('ir.rule').domain_get(cr, uid, self._name, context=context)
|
||||
qu1 = qu1 + dom[0]
|
||||
qu2 = qu2 + dom[1]
|
||||
where_clause = where_clause + dom[0]
|
||||
where_params = where_params + dom[1]
|
||||
for t in dom[2]:
|
||||
if t not in tables:
|
||||
tables.append(t)
|
||||
if len(qu1):
|
||||
qu1 = ' where '+string.join(qu1, ' and ')
|
||||
|
||||
# Take care of adding join(s) if groupby is an '_inherits'ed field
|
||||
tables, where_clause = self._inherits_join_calc(groupby,tables,where_clause)
|
||||
|
||||
if len(where_clause):
|
||||
where_clause = ' where '+string.join(where_clause, ' and ')
|
||||
else:
|
||||
qu1 = ''
|
||||
where_clause = ''
|
||||
limit_str = limit and ' limit %d' % limit or ''
|
||||
offset_str = offset and ' offset %d' % offset or ''
|
||||
|
||||
@@ -1885,7 +1889,8 @@ class orm(orm_template):
|
||||
flist += ',avg('+f+') as '+f
|
||||
else:
|
||||
flist += ',sum('+f+') as '+f
|
||||
cr.execute('select min(id) as id,'+flist+' from ' + self._table +qu1+' group by '+ groupby + limit_str + offset_str,qu2)
|
||||
|
||||
cr.execute('select min(%s.id) as id,' % self._table + flist + ' from ' + ','.join(tables) + where_clause + ' group by '+ groupby + limit_str + offset_str, where_params)
|
||||
alldata = {}
|
||||
groupby = group_by
|
||||
for r in cr.dictfetchall():
|
||||
@@ -1916,6 +1921,22 @@ class orm(orm_template):
|
||||
del d['id']
|
||||
return data
|
||||
|
||||
def _inherits_join_calc(self, field, tables, where_clause):
|
||||
""" Adds missing table select and join clause(s) for reaching
|
||||
the field coming from an '_inherits' parent table.
|
||||
@param tables: list of table._table names enclosed in double quotes as returned
|
||||
by _where_calc()
|
||||
"""
|
||||
current_table = self
|
||||
while field in current_table._inherit_fields and not field in current_table._columns:
|
||||
parent_table = self.pool.get(current_table._inherit_fields[field][0])
|
||||
parent_table_name = parent_table._table
|
||||
if '"%s"'%parent_table_name not in tables:
|
||||
tables.append('"%s"'%parent_table_name)
|
||||
where_clause.append('(%s.%s = %s.id)' % (current_table._table, current_table._inherits[parent_table._name], parent_table_name))
|
||||
current_table = parent_table
|
||||
return (tables, where_clause)
|
||||
|
||||
def _parent_store_compute(self, cr):
|
||||
logger = netsvc.Logger()
|
||||
logger.notifyChannel('orm', netsvc.LOG_INFO, 'Computing parent left and right for table %s...' % (self._table, ))
|
||||
|
||||
+38
-18
@@ -327,23 +327,23 @@ def html2plaintext(html, body_id=None, encoding='utf-8'):
|
||||
## (c) Fry-IT, www.fry-it.com, 2007
|
||||
## <peter@fry-it.com>
|
||||
## download here: http://www.peterbe.com/plog/html2plaintext
|
||||
|
||||
|
||||
|
||||
|
||||
""" from an HTML text, convert the HTML to plain text.
|
||||
If @body_id is provided then this is the tag where the
|
||||
If @body_id is provided then this is the tag where the
|
||||
body (not necessarily <body>) starts.
|
||||
"""
|
||||
try:
|
||||
from BeautifulSoup import BeautifulSoup, SoupStrainer, Comment
|
||||
except:
|
||||
return html
|
||||
|
||||
|
||||
urls = []
|
||||
if body_id is not None:
|
||||
strainer = SoupStrainer(id=body_id)
|
||||
else:
|
||||
strainer = SoupStrainer('body')
|
||||
|
||||
|
||||
soup = BeautifulSoup(html, parseOnlyThese=strainer, fromEncoding=encoding)
|
||||
for link in soup.findAll('a'):
|
||||
title = link.renderContents()
|
||||
@@ -351,7 +351,7 @@ def html2plaintext(html, body_id=None, encoding='utf-8'):
|
||||
urls.append(dict(url=url, tag=str(link), title=title))
|
||||
|
||||
html = soup.__str__()
|
||||
|
||||
|
||||
url_index = []
|
||||
i = 0
|
||||
for d in urls:
|
||||
@@ -368,11 +368,11 @@ def html2plaintext(html, body_id=None, encoding='utf-8'):
|
||||
html = html.replace('<h2>','**').replace('</h2>','**')
|
||||
html = html.replace('<h1>','**').replace('</h1>','**')
|
||||
html = html.replace('<em>','/').replace('</em>','/')
|
||||
|
||||
|
||||
# the only line breaks we respect is those of ending tags and
|
||||
|
||||
# the only line breaks we respect is those of ending tags and
|
||||
# breaks
|
||||
|
||||
|
||||
html = html.replace('\n',' ')
|
||||
html = html.replace('<br>', '\n')
|
||||
html = html.replace('<tr>', '\n')
|
||||
@@ -381,7 +381,7 @@ def html2plaintext(html, body_id=None, encoding='utf-8'):
|
||||
html = html.replace(' ' * 2, ' ')
|
||||
|
||||
|
||||
# for all other tags we failed to clean up, just remove then and
|
||||
# for all other tags we failed to clean up, just remove then and
|
||||
# complain about them on the stderr
|
||||
def desperate_fixer(g):
|
||||
#print >>sys.stderr, "failed to clean up %s" % str(g.group())
|
||||
@@ -501,8 +501,8 @@ def email_send(email_from, email_to, subject, body, email_cc=None, email_bcc=Non
|
||||
return True
|
||||
except Exception,e:
|
||||
netsvc.Logger().notifyChannel('email_send (maildir)', netsvc.LOG_ERROR, e)
|
||||
return False
|
||||
|
||||
return False
|
||||
|
||||
try:
|
||||
oldstderr = smtplib.stderr
|
||||
s = smtplib.SMTP()
|
||||
@@ -511,7 +511,7 @@ def email_send(email_from, email_to, subject, body, email_cc=None, email_bcc=Non
|
||||
if debug:
|
||||
smtplib.stderr = WriteToLogger()
|
||||
|
||||
s.set_debuglevel(int(bool(debug))) # 0 or 1
|
||||
s.set_debuglevel(int(bool(debug))) # 0 or 1
|
||||
s.connect(smtp_server, config['smtp_port'])
|
||||
if ssl:
|
||||
s.ehlo()
|
||||
@@ -519,7 +519,7 @@ def email_send(email_from, email_to, subject, body, email_cc=None, email_bcc=Non
|
||||
s.ehlo()
|
||||
|
||||
if config['smtp_user'] or config['smtp_password']:
|
||||
s.login(config['smtp_user'], config['smtp_password'])
|
||||
s.login(config['smtp_user'], config['smtp_password'])
|
||||
s.sendmail(email_from,
|
||||
flatten([email_to, email_cc, email_bcc]),
|
||||
msg.as_string()
|
||||
@@ -754,10 +754,10 @@ class cache(object):
|
||||
else:
|
||||
kwargs2 = self._unify_args(*args, **kwargs)
|
||||
keys_to_del = [key for key, _ in self._generate_keys(dbname, kwargs2) if key in self.cache.keys()]
|
||||
|
||||
|
||||
for key in keys_to_del:
|
||||
self.cache.pop(key)
|
||||
|
||||
|
||||
@classmethod
|
||||
def clean_caches_for_db(cls, dbname):
|
||||
for c in cls.__caches:
|
||||
@@ -906,6 +906,7 @@ def get_iso_codes(lang):
|
||||
|
||||
def get_languages():
|
||||
languages={
|
||||
'ab_RU': u'Abkhazian (RU)',
|
||||
'ar_AR': u'Arabic / الْعَرَبيّة',
|
||||
'bg_BG': u'Bulgarian / български',
|
||||
'bs_BS': u'Bosnian / bosanski jezik',
|
||||
@@ -920,29 +921,48 @@ def get_languages():
|
||||
'es_AR': u'Spanish (AR) / Español (AR)',
|
||||
'es_ES': u'Spanish / Español',
|
||||
'et_EE': u'Estonian / Eesti keel',
|
||||
'fa_IR': u'Persian / Iran, Islamic Republic of',
|
||||
'fi_FI': u'Finland / Suomi',
|
||||
'fr_BE': u'French (BE) / Français (BE)',
|
||||
'fr_CH': u'French (CH) / Français (CH)',
|
||||
'fr_FR': u'French / Français',
|
||||
'gl_ES': u'Galician / Spain',
|
||||
'gu_IN': u'Gujarati / India',
|
||||
'hi_IN': u'Hindi / India',
|
||||
'hr_HR': u'Croatian / hrvatski jezik',
|
||||
'hu_HU': u'Hungarian / Magyar',
|
||||
'id_ID': u'Indonesian / Bahasa Indonesia',
|
||||
'it_IT': u'Italian / Italiano',
|
||||
'iu_CA': u'Inuktitut / Canada',
|
||||
'ja_JP': u'Japanese / Japan',
|
||||
'ko_KP': u'Korean / Korea, Democratic Peoples Republic of',
|
||||
'ko_KR': u'Korean / Korea, Republic of',
|
||||
'lt_LT': u'Lithuanian / Lietuvių kalba',
|
||||
'lv_LV': u'Latvian / Latvia',
|
||||
'ml_IN': u'Malayalam / India',
|
||||
'mn_MN': u'Mongolian / Mongolia',
|
||||
'nb_NO': u'Norwegian Bokmål / Norway',
|
||||
'nl_NL': u'Dutch / Nederlands',
|
||||
'nl_BE': u'Dutch (Belgium) / Nederlands (Belgïe)',
|
||||
'oc_FR': u'Occitan (post 1500) / France',
|
||||
'pl_PL': u'Polish / Język polski',
|
||||
'pt_BR': u'Portugese (BR) / português (BR)',
|
||||
'pt_PT': u'Portugese / português',
|
||||
'ro_RO': u'Romanian / limba română',
|
||||
'ru_RU': u'Russian / русский язык',
|
||||
'si_LK': u'Sinhalese / Sri Lanka',
|
||||
'sk_SK': u'Slovak / Slovakia',
|
||||
'sl_SL': u'Slovenian / slovenščina',
|
||||
'sq_AL': u'Albanian / Shqipëri',
|
||||
'sr_RS': u'Serbian / Serbia',
|
||||
'sv_SE': u'Swedish / svenska',
|
||||
'te_IN': u'Telugu / India',
|
||||
'tr_TR': u'Turkish / Türkçe',
|
||||
'vi_VN': u'Vietnam / Cộng hòa xã hội chủ nghĩa Việt Nam',
|
||||
'uk_UA': u'Ukrainian / украї́нська мо́ва',
|
||||
'ur_PK': u'Urdu / Pakistan',
|
||||
'zh_CN': u'Chinese (CN) / 简体中文',
|
||||
'zh_HK': u'Chinese (HK)',
|
||||
'zh_TW': u'Chinese (TW) / 正體字',
|
||||
'th_TH': u'Thai / ภาษาไทย',
|
||||
'tlh_TLH': u'Klingon',
|
||||
@@ -1181,9 +1201,9 @@ def detect_ip_addr():
|
||||
# RATIONALE BEHIND TIMESTAMP CALCULATIONS AND TIMEZONE MANAGEMENT:
|
||||
# The server side never does any timestamp calculation, always
|
||||
# sends them in a naive (timezone agnostic) format supposed to be
|
||||
# expressed within the server timezone, and expects the clients to
|
||||
# expressed within the server timezone, and expects the clients to
|
||||
# provide timestamps in the server timezone as well.
|
||||
# It stores all timestamps in the database in naive format as well,
|
||||
# It stores all timestamps in the database in naive format as well,
|
||||
# which also expresses the time in the server timezone.
|
||||
# For this reason the server makes its timezone name available via the
|
||||
# common/timezone_get() rpc method, which clients need to read
|
||||
|
||||
Reference in New Issue
Block a user