[MERGE] mail: from chm

bzr revid: fva@openerp.com-20121022132802-u02hg6ps4dvc4auu
This commit is contained in:
Frédéric van der Essen
2012-10-22 15:28:02 +02:00
29 changed files with 1414 additions and 457 deletions
+1 -1
View File
@@ -160,7 +160,7 @@
<field name="name">account.analytic.line.tree</field>
<field name="model">account.analytic.line</field>
<field name="arch" type="xml">
<tree editable="top" string="Analytic Entries">
<tree string="Analytic Entries">
<field name="date"/>
<field name="ref" invisible="context.get('to_invoice', False)"/>
<field name="name"/>
+213
View File
@@ -0,0 +1,213 @@
# Mongolian translation for openobject-addons
# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2012.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2012-02-08 00:35+0000\n"
"PO-Revision-Date: 2012-10-22 02:35+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: Mongolian <mn@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: 2012-10-22 04:40+0000\n"
"X-Generator: Launchpad (build 16165)\n"
#. module: anonymization
#: model:ir.model,name:anonymization.model_ir_model_fields_anonymize_wizard
msgid "ir.model.fields.anonymize.wizard"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymization,field_name:0
msgid "Field Name"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymization,field_id:0
msgid "Field"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymization.history,state:0
#: field:ir.model.fields.anonymize.wizard,state:0
msgid "State"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymize.wizard,file_import:0
msgid "Import"
msgstr ""
#. module: anonymization
#: model:ir.model,name:anonymization.model_ir_model_fields_anonymization
msgid "ir.model.fields.anonymization"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymization.history,direction:0
msgid "Direction"
msgstr ""
#. module: anonymization
#: model:ir.actions.act_window,name:anonymization.action_ir_model_fields_anonymization_tree
#: view:ir.model.fields.anonymization:0
#: model:ir.ui.menu,name:anonymization.menu_administration_anonymization_fields
msgid "Anonymized Fields"
msgstr ""
#. module: anonymization
#: model:ir.ui.menu,name:anonymization.menu_administration_anonymization
msgid "Database anonymization"
msgstr ""
#. module: anonymization
#: selection:ir.model.fields.anonymization.history,direction:0
msgid "clear -> anonymized"
msgstr ""
#. module: anonymization
#: selection:ir.model.fields.anonymization,state:0
#: selection:ir.model.fields.anonymize.wizard,state:0
msgid "Anonymized"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymization,state:0
msgid "unknown"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymization,model_id:0
msgid "Object"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymization.history,filepath:0
msgid "File path"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymization.history,date:0
msgid "Date"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymize.wizard,file_export:0
msgid "Export"
msgstr ""
#. module: anonymization
#: view:ir.model.fields.anonymize.wizard:0
msgid "Reverse the Database Anonymization"
msgstr ""
#. module: anonymization
#: view:ir.model.fields.anonymize.wizard:0
msgid "Database Anonymization"
msgstr ""
#. module: anonymization
#: model:ir.ui.menu,name:anonymization.menu_administration_anonymization_wizard
msgid "Anonymize database"
msgstr ""
#. module: anonymization
#: view:ir.model.fields.anonymization.history:0
#: field:ir.model.fields.anonymization.history,field_ids:0
msgid "Fields"
msgstr ""
#. module: anonymization
#: selection:ir.model.fields.anonymization,state:0
#: selection:ir.model.fields.anonymize.wizard,state:0
msgid "Clear"
msgstr ""
#. module: anonymization
#: view:ir.model.fields.anonymize.wizard:0
#: field:ir.model.fields.anonymize.wizard,summary:0
msgid "Summary"
msgstr ""
#. module: anonymization
#: view:ir.model.fields.anonymization:0
msgid "Anonymized Field"
msgstr ""
#. module: anonymization
#: selection:ir.model.fields.anonymize.wizard,state:0
msgid "Unstable"
msgstr "Тогтмол биш"
#. module: anonymization
#: selection:ir.model.fields.anonymization.history,state:0
msgid "Exception occured"
msgstr ""
#. module: anonymization
#: selection:ir.model.fields.anonymization,state:0
#: selection:ir.model.fields.anonymize.wizard,state:0
msgid "Not Existing"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymization,model_name:0
msgid "Object Name"
msgstr ""
#. module: anonymization
#: model:ir.actions.act_window,name:anonymization.action_ir_model_fields_anonymization_history_tree
#: view:ir.model.fields.anonymization.history:0
#: model:ir.ui.menu,name:anonymization.menu_administration_anonymization_history
msgid "Anonymization History"
msgstr ""
#. module: anonymization
#: model:ir.model,name:anonymization.model_ir_model_fields_anonymization_history
msgid "ir.model.fields.anonymization.history"
msgstr ""
#. module: anonymization
#: model:ir.actions.act_window,name:anonymization.action_ir_model_fields_anonymize_wizard
#: view:ir.model.fields.anonymize.wizard:0
msgid "Anonymize Database"
msgstr ""
#. module: anonymization
#: field:ir.model.fields.anonymize.wizard,name:0
msgid "File Name"
msgstr ""
#. module: anonymization
#: selection:ir.model.fields.anonymization.history,direction:0
msgid "anonymized -> clear"
msgstr ""
#. module: anonymization
#: selection:ir.model.fields.anonymization.history,state:0
msgid "Started"
msgstr ""
#. module: anonymization
#: selection:ir.model.fields.anonymization.history,state:0
msgid "Done"
msgstr ""
#. module: anonymization
#: view:ir.model.fields.anonymization.history:0
#: field:ir.model.fields.anonymization.history,msg:0
#: field:ir.model.fields.anonymize.wizard,msg:0
msgid "Message"
msgstr ""
#. module: anonymization
#: code:addons/anonymization/anonymization.py:55
#: sql_constraint:ir.model.fields.anonymization:0
#, python-format
msgid "You cannot have two fields with the same name on the same object!"
msgstr ""
+8 -8
View File
@@ -7,13 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 6.0dev\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2012-02-08 01:37+0100\n"
"PO-Revision-Date: 2012-05-10 18:17+0000\n"
"Last-Translator: Fabien (Open ERP) <fp@tinyerp.com>\n"
"PO-Revision-Date: 2012-10-21 21:20+0000\n"
"Last-Translator: mchip <mifchip@gmail.com>\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: 2012-10-19 05:20+0000\n"
"X-Launchpad-Export-Date: 2012-10-22 04:40+0000\n"
"X-Generator: Launchpad (build 16165)\n"
#. module: hr
@@ -103,7 +103,7 @@ msgstr ""
#. module: hr
#: model:ir.actions.todo.category,name:hr.category_hr_management_config
msgid "HR Management"
msgstr ""
msgstr "Žmogiškųjų išteklių valdymas"
#. module: hr
#: help:hr.employee,partner_id:0
@@ -130,7 +130,7 @@ msgstr "Pastabos"
#. module: hr
#: selection:hr.employee,marital:0
msgid "Married"
msgstr ""
msgstr "Vedęs"
#. module: hr
#: model:ir.actions.act_window,help:hr.action_create_hr_employee_installer
@@ -152,7 +152,7 @@ msgstr ""
#. module: hr
#: field:hr.employee,color:0
msgid "Color Index"
msgstr ""
msgstr "Spalvos indeksas"
#. module: hr
#: model:process.transition,note:hr.process_transition_employeeuser0
@@ -169,7 +169,7 @@ msgstr ""
#. module: hr
#: field:hr.employee,identification_id:0
msgid "Identification No"
msgstr ""
msgstr "Asmens kodas"
#. module: hr
#: selection:hr.employee,gender:0
@@ -206,7 +206,7 @@ msgstr "Žemesniosios kategorijos"
#: view:hr.job:0 field:hr.job,description:0
#: model:ir.model,name:hr.model_hr_job
msgid "Job Description"
msgstr ""
msgstr "Darbo aprašymas"
#. module: hr
#: field:hr.employee,work_location:0
@@ -86,6 +86,8 @@ class report_custom(report_rml):
for att in attendences:
dt = datetime.strptime(att['name'], '%Y-%m-%d %H:%M:%S')
if ldt and att['action'] == 'sign_out':
if dt.date() > ldt.date():
dt = ldt
wh += (float((dt - ldt).seconds)/60/60)
else:
ldt = dt
+1 -1
View File
@@ -38,7 +38,7 @@ class report_custom(report_rml):
def create_xml(self, cr, uid, ids, datas, context=None):
obj_emp = pooler.get_pool(cr.dbname).get('hr.employee')
ids = datas['active_ids']
start_date = datetime.strptime(datas['form']['init_date'], '%Y-%m-%d')
end_date = datetime.strptime(datas['form']['end_date'], '%Y-%m-%d')
first_monday = start_date - relativedelta(days=start_date.date().weekday())
@@ -37,6 +37,7 @@ class hr_attendance_byweek(osv.osv_memory):
def print_report(self, cr, uid, ids, context=None):
datas = {
'ids': [],
'active_ids': context['active_ids'],
'model': 'hr.employee',
'form': self.read(cr, uid, ids)[0]
}
@@ -313,7 +313,7 @@ You can automatically receive job application though an email gateway, see the H
<field eval="0" name="rating_allow_one_column_require"/>
<field name="req_error_msg">This question requires an answer.</field>
<field eval="3" name="sequence"/>
<field name="question">Exprience</field>
<field name="question">Experience</field>
<field eval="0" name="is_require_answer"/>
<field name="type">comment</field>
<field name="comment_valid_err_msg">The comment you entered is in an invalid format.</field>
+642
View File
@@ -0,0 +1,642 @@
# Macedonian translation for openobject-addons
# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2012.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2012-02-08 00:36+0000\n"
"PO-Revision-Date: 2012-10-20 13:07+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: Macedonian <mk@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: 2012-10-21 04:41+0000\n"
"X-Generator: Launchpad (build 16165)\n"
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:43
#: code:addons/hr_timesheet/report/users_timesheet.py:77
#, python-format
msgid "Wed"
msgstr "Сре"
#. module: hr_timesheet
#: view:hr.sign.out.project:0
msgid "(Keep empty for current_time)"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/wizard/hr_timesheet_sign_in_out.py:132
#, python-format
msgid "No employee defined for your user !"
msgstr ""
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
msgid "Group By..."
msgstr "Групирај По..."
#. module: hr_timesheet
#: model:ir.actions.act_window,help:hr_timesheet.action_hr_timesheet_sign_in
msgid ""
"Employees can encode their time spent on the different projects. A project "
"is an analytic account and the time spent on a project generate costs on the "
"analytic account. This feature allows to record at the same time the "
"attendance and the timesheet."
msgstr ""
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
msgid "Today"
msgstr "Денес"
#. module: hr_timesheet
#: field:hr.employee,journal_id:0
msgid "Analytic Journal"
msgstr "Аналитичка картица"
#. module: hr_timesheet
#: view:hr.sign.out.project:0
msgid "Stop Working"
msgstr ""
#. module: hr_timesheet
#: model:ir.actions.act_window,name:hr_timesheet.action_hr_timesheet_employee
#: model:ir.ui.menu,name:hr_timesheet.menu_hr_timesheet_employee
msgid "Employee Timesheet"
msgstr ""
#. module: hr_timesheet
#: view:account.analytic.account:0
msgid "Work done stats"
msgstr ""
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
#: model:ir.ui.menu,name:hr_timesheet.menu_hr_reporting_timesheet
msgid "Timesheet"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:43
#: code:addons/hr_timesheet/report/users_timesheet.py:77
#, python-format
msgid "Mon"
msgstr "Пон"
#. module: hr_timesheet
#: view:hr.sign.in.project:0
msgid "Sign in"
msgstr "Најава"
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:43
#: code:addons/hr_timesheet/report/users_timesheet.py:77
#, python-format
msgid "Fri"
msgstr "Пет"
#. module: hr_timesheet
#: field:hr.employee,uom_id:0
msgid "UoM"
msgstr ""
#. module: hr_timesheet
#: view:hr.sign.in.project:0
msgid ""
"Employees can encode their time spent on the different projects they are "
"assigned on. A project is an analytic account and the time spent on a "
"project generates costs on the analytic account. This feature allows to "
"record at the same time the attendance and the timesheet."
msgstr ""
#. module: hr_timesheet
#: field:hr.sign.out.project,analytic_amount:0
msgid "Minimum Analytic Amount"
msgstr ""
#. module: hr_timesheet
#: view:hr.analytical.timesheet.employee:0
msgid "Monthly Employee Timesheet"
msgstr ""
#. module: hr_timesheet
#: view:hr.sign.out.project:0
msgid "Work done in the last period"
msgstr ""
#. module: hr_timesheet
#: field:hr.sign.in.project,state:0
#: field:hr.sign.out.project,state:0
msgid "Current state"
msgstr "Тековен статус"
#. module: hr_timesheet
#: field:hr.sign.in.project,name:0
#: field:hr.sign.out.project,name:0
msgid "Employees name"
msgstr "Име на Вработениот"
#. module: hr_timesheet
#: field:hr.sign.out.project,account_id:0
msgid "Project / Analytic Account"
msgstr ""
#. module: hr_timesheet
#: model:ir.model,name:hr_timesheet.model_hr_analytical_timesheet_users
msgid "Print Employees Timesheet"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/hr_timesheet.py:175
#: code:addons/hr_timesheet/hr_timesheet.py:177
#, python-format
msgid "Warning !"
msgstr "Внимание !"
#. module: hr_timesheet
#: code:addons/hr_timesheet/wizard/hr_timesheet_sign_in_out.py:77
#: code:addons/hr_timesheet/wizard/hr_timesheet_sign_in_out.py:132
#, python-format
msgid "UserError"
msgstr "Корисничка Грешка"
#. module: hr_timesheet
#: code:addons/hr_timesheet/wizard/hr_timesheet_sign_in_out.py:77
#, python-format
msgid "No cost unit defined for this employee !"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:43
#: code:addons/hr_timesheet/report/users_timesheet.py:77
#, python-format
msgid "Tue"
msgstr "Вто"
#. module: hr_timesheet
#: code:addons/hr_timesheet/wizard/hr_timesheet_print_employee.py:42
#, python-format
msgid "Warning"
msgstr "Предупредување"
#. module: hr_timesheet
#: field:hr.analytic.timesheet,partner_id:0
msgid "Partner"
msgstr "Партнер"
#. module: hr_timesheet
#: view:hr.sign.in.project:0
#: view:hr.sign.out.project:0
msgid "Sign In/Out by Project"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:43
#: code:addons/hr_timesheet/report/users_timesheet.py:77
#, python-format
msgid "Sat"
msgstr "Саб"
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:43
#: code:addons/hr_timesheet/report/users_timesheet.py:77
#, python-format
msgid "Sun"
msgstr "Нед"
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
msgid "Analytic account"
msgstr "Аналитичко конто"
#. module: hr_timesheet
#: view:hr.analytical.timesheet.employee:0
#: view:hr.analytical.timesheet.users:0
msgid "Print"
msgstr "Печати"
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
#: model:ir.actions.act_window,name:hr_timesheet.act_hr_timesheet_line_evry1_all_form
#: model:ir.ui.menu,name:hr_timesheet.menu_hr_working_hours
msgid "Timesheet Lines"
msgstr ""
#. module: hr_timesheet
#: view:hr.analytical.timesheet.users:0
msgid "Monthly Employees Timesheet"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "July"
msgstr "Јули"
#. module: hr_timesheet
#: field:hr.sign.in.project,date:0
#: field:hr.sign.out.project,date_start:0
msgid "Starting Date"
msgstr "Почетен датум"
#. module: hr_timesheet
#: view:hr.employee:0
msgid "Categories"
msgstr "Категории"
#. module: hr_timesheet
#: constraint:hr.analytic.timesheet:0
msgid "You cannot modify an entry in a Confirmed/Done timesheet !."
msgstr ""
#. module: hr_timesheet
#: help:hr.employee,product_id:0
msgid "Specifies employee's designation as a product with type 'service'."
msgstr ""
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
msgid "Total cost"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "September"
msgstr "Септември"
#. module: hr_timesheet
#: model:ir.model,name:hr_timesheet.model_hr_analytic_timesheet
msgid "Timesheet Line"
msgstr ""
#. module: hr_timesheet
#: field:hr.analytical.timesheet.users,employee_ids:0
msgid "employees"
msgstr ""
#. module: hr_timesheet
#: view:account.analytic.account:0
msgid "Stats by month"
msgstr ""
#. module: hr_timesheet
#: view:account.analytic.account:0
#: field:hr.analytical.timesheet.employee,month:0
#: field:hr.analytical.timesheet.users,month:0
msgid "Month"
msgstr "Месец"
#. module: hr_timesheet
#: field:hr.sign.out.project,info:0
msgid "Work Description"
msgstr ""
#. module: hr_timesheet
#: view:account.analytic.account:0
msgid "Invoice Analysis"
msgstr ""
#. module: hr_timesheet
#: model:ir.actions.report.xml,name:hr_timesheet.report_user_timesheet
msgid "Employee timesheet"
msgstr ""
#. module: hr_timesheet
#: model:ir.actions.act_window,name:hr_timesheet.action_hr_timesheet_sign_in
#: model:ir.actions.act_window,name:hr_timesheet.action_hr_timesheet_sign_out
msgid "Sign in / Sign out by project"
msgstr ""
#. module: hr_timesheet
#: model:ir.actions.act_window,name:hr_timesheet.action_define_analytic_structure
msgid "Define your Analytic Structure"
msgstr ""
#. module: hr_timesheet
#: view:hr.sign.in.project:0
msgid "Sign in / Sign out"
msgstr "Најава / Одјава"
#. module: hr_timesheet
#: code:addons/hr_timesheet/hr_timesheet.py:175
#, python-format
msgid ""
"Analytic journal is not defined for employee %s \n"
"Define an employee for the selected user and assign an analytic journal!"
msgstr ""
#. module: hr_timesheet
#: view:hr.sign.in.project:0
msgid "(Keep empty for current time)"
msgstr ""
#. module: hr_timesheet
#: view:hr.employee:0
msgid "Timesheets"
msgstr ""
#. module: hr_timesheet
#: model:ir.actions.act_window,help:hr_timesheet.action_define_analytic_structure
msgid ""
"You should create an analytic account structure depending on your needs to "
"analyse costs and revenues. In OpenERP, analytic accounts are also used to "
"track customer contracts."
msgstr ""
#. module: hr_timesheet
#: field:hr.analytic.timesheet,line_id:0
msgid "Analytic Line"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "August"
msgstr "Август"
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "June"
msgstr "Јуни"
#. module: hr_timesheet
#: view:hr.analytical.timesheet.employee:0
msgid "Print My Timesheet"
msgstr ""
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
msgid "Date"
msgstr "Датум"
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "November"
msgstr "Ноември"
#. module: hr_timesheet
#: constraint:hr.employee:0
msgid "Error ! You cannot create recursive Hierarchy of Employees."
msgstr "Грешка! Не можете да креирате рекурзивна хиерархија на вработените."
#. module: hr_timesheet
#: field:hr.sign.out.project,date:0
msgid "Closing Date"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "October"
msgstr "Октомври"
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "January"
msgstr "Јануари"
#. module: hr_timesheet
#: view:account.analytic.account:0
msgid "Key dates"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:43
#: code:addons/hr_timesheet/report/users_timesheet.py:77
#, python-format
msgid "Thu"
msgstr "Чет"
#. module: hr_timesheet
#: view:account.analytic.account:0
msgid "Analysis stats"
msgstr ""
#. module: hr_timesheet
#: model:ir.model,name:hr_timesheet.model_hr_analytical_timesheet_employee
msgid "Print Employee Timesheet & Print My Timesheet"
msgstr ""
#. module: hr_timesheet
#: field:hr.sign.in.project,emp_id:0
#: field:hr.sign.out.project,emp_id:0
msgid "Employee ID"
msgstr "Идентификационен Број на Вработениот"
#. module: hr_timesheet
#: view:hr.sign.out.project:0
msgid "General Information"
msgstr "Општи информации"
#. module: hr_timesheet
#: model:ir.actions.act_window,name:hr_timesheet.action_hr_timesheet_my
msgid "My Current Timesheet"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "December"
msgstr "Декември"
#. module: hr_timesheet
#: view:hr.analytical.timesheet.employee:0
#: view:hr.analytical.timesheet.users:0
#: view:hr.sign.in.project:0
#: view:hr.sign.out.project:0
msgid "Cancel"
msgstr "Откажи"
#. module: hr_timesheet
#: model:ir.actions.act_window,name:hr_timesheet.action_hr_timesheet_users
#: model:ir.actions.report.xml,name:hr_timesheet.report_users_timesheet
#: model:ir.actions.wizard,name:hr_timesheet.wizard_hr_timesheet_users
#: model:ir.ui.menu,name:hr_timesheet.menu_hr_timesheet_users
msgid "Employees Timesheet"
msgstr ""
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
msgid "Information"
msgstr "Информации"
#. module: hr_timesheet
#: field:hr.analytical.timesheet.employee,employee_id:0
#: model:ir.model,name:hr_timesheet.model_hr_employee
msgid "Employee"
msgstr "Вработен"
#. module: hr_timesheet
#: model:ir.actions.act_window,help:hr_timesheet.act_hr_timesheet_line_evry1_all_form
msgid ""
"Through this menu you can register and follow your workings hours by project "
"every day."
msgstr ""
#. module: hr_timesheet
#: field:hr.sign.in.project,server_date:0
#: field:hr.sign.out.project,server_date:0
msgid "Current Date"
msgstr "Тековен датум"
#. module: hr_timesheet
#: view:hr.analytical.timesheet.employee:0
msgid "This wizard will print monthly timesheet"
msgstr ""
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
#: field:hr.employee,product_id:0
msgid "Product"
msgstr "Продукт"
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
msgid "Invoicing"
msgstr "Фактурирање"
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "May"
msgstr "Мај"
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
msgid "Total time"
msgstr "Вкупно време"
#. module: hr_timesheet
#: view:hr.sign.in.project:0
msgid "(local time on the server side)"
msgstr ""
#. module: hr_timesheet
#: model:ir.model,name:hr_timesheet.model_hr_sign_in_project
msgid "Sign In By Project"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "February"
msgstr "Февруари"
#. module: hr_timesheet
#: model:ir.model,name:hr_timesheet.model_hr_sign_out_project
msgid "Sign Out By Project"
msgstr ""
#. module: hr_timesheet
#: view:hr.analytical.timesheet.users:0
msgid "Employees"
msgstr "Вработени"
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "March"
msgstr "Март"
#. module: hr_timesheet
#: code:addons/hr_timesheet/report/user_timesheet.py:40
#: code:addons/hr_timesheet/report/users_timesheet.py:73
#: selection:hr.analytical.timesheet.employee,month:0
#: selection:hr.analytical.timesheet.users,month:0
#, python-format
msgid "April"
msgstr "Април"
#. module: hr_timesheet
#: code:addons/hr_timesheet/hr_timesheet.py:177
#, python-format
msgid ""
"No analytic account defined on the project.\n"
"Please set one or we can not automatically fill the timesheet."
msgstr ""
#. module: hr_timesheet
#: view:account.analytic.account:0
#: view:hr.analytic.timesheet:0
msgid "Users"
msgstr "Корисници"
#. module: hr_timesheet
#: view:hr.sign.in.project:0
msgid "Start Working"
msgstr ""
#. module: hr_timesheet
#: view:account.analytic.account:0
msgid "Stats by user"
msgstr ""
#. module: hr_timesheet
#: code:addons/hr_timesheet/wizard/hr_timesheet_print_employee.py:42
#, python-format
msgid "No employee defined for this user"
msgstr ""
#. module: hr_timesheet
#: field:hr.analytical.timesheet.employee,year:0
#: field:hr.analytical.timesheet.users,year:0
msgid "Year"
msgstr "Година"
#. module: hr_timesheet
#: view:hr.analytic.timesheet:0
msgid "Accounting"
msgstr "Сметководство"
#. module: hr_timesheet
#: view:hr.sign.out.project:0
msgid "Change Work"
msgstr ""
#~ msgid "Sum"
#~ msgstr "Вкупно"
#~ msgid "Total"
#~ msgstr "Вкупно"
@@ -147,7 +147,7 @@ class hr_si_project(osv.osv_memory):
'view_type': 'form',
'view_mode': 'tree,form',
'res_model': 'hr.sign.%s.project' % in_out,
'views': [(False,'tree'), (resource_id,'form')],
'views': [(resource_id,'form')],
'type': 'ir.actions.act_window',
'target': 'new'
}
@@ -176,7 +176,7 @@ account_analytic_line()
class hr_analytic_timesheet(osv.osv):
_inherit = "hr.analytic.timesheet"
def on_change_account_id(self, cr, uid, ids, account_id):
def on_change_account_id(self, cr, uid, ids, account_id, user_id=False):
res = {}
if not account_id:
return res
@@ -50,7 +50,7 @@
<field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_form"/>
<field name="arch" type="xml">
<field name="account_id" position="replace">
<field domain="[('type','in',['normal','contract']),('state', '&lt;&gt;', 'close'),('use_timesheets','=',1)]" name="account_id" on_change="on_change_account_id(account_id)" context="{'default_use_timesheets': 1}"/>
<field domain="[('type','in',['normal','contract']),('state', '&lt;&gt;', 'close'),('use_timesheets','=',1)]" name="account_id" on_change="on_change_account_id(account_id, user_id)" context="{'default_use_timesheets': 1}"/>
</field>
</field>
</record>
@@ -72,7 +72,7 @@
<field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_tree"/>
<field name="arch" type="xml">
<field name="account_id" position="replace">
<field domain="[('type','in',['normal','contract']),('state', '&lt;&gt;', 'close'),('use_timesheets','=',1)]" name="account_id" on_change="on_change_account_id(account_id)" context="{'default_use_timesheets': 1}"/>
<field domain="[('type','in',['normal','contract']),('state', '&lt;&gt;', 'close'),('use_timesheets','=',1)]" name="account_id" on_change="on_change_account_id(account_id, user_id)" context="{'default_use_timesheets': 1}"/>
</field>
</field>
</record>
@@ -388,7 +388,7 @@ class hr_timesheet_line(osv.osv):
return True
def multi_on_change_account_id(self, cr, uid, ids, account_ids, context=None):
return dict([(el, self.on_change_account_id(cr, uid, ids, el)) for el in account_ids])
return dict([(el, self.on_change_account_id(cr, uid, ids, el, context.get('user_id', uid))) for el in account_ids])
hr_timesheet_line()
@@ -97,7 +97,7 @@
<field colspan="4" context="{'user_id':user_id}" name="timesheet_ids" nolabel="1">
<tree editable="top" string="Timesheet Lines">
<field name="date"/>
<field domain="[('type','in',['normal', 'contract']), ('state', '&lt;&gt;', 'close'),('use_timesheets','=',1)]" name="account_id" on_change="on_change_account_id(account_id)" context="{'default_use_timesheets': 1}"/>
<field domain="[('type','in',['normal', 'contract']), ('state', '&lt;&gt;', 'close'),('use_timesheets','=',1)]" name="account_id" on_change="on_change_account_id(account_id, user_id)" context="{'default_use_timesheets': 1}"/>
<field name="name"/>
<field name="unit_amount" on_change="on_change_unit_amount(product_id, unit_amount, False, product_uom_id,journal_id)" widget="float_time"/>
<field name="to_invoice" widget="selection"/>
@@ -110,7 +110,7 @@
</tree>
<form string="Timesheet Lines" version="7.0">
<field name="date"/>
<field domain="[('type','=','normal'), ('state', '&lt;&gt;', 'close')]" name="account_id" on_change="on_change_account_id(account_id)"/>
<field domain="[('type','=','normal'), ('state', '&lt;&gt;', 'close')]" name="account_id" on_change="on_change_account_id(account_id, user_id)"/>
<field name="name"/>
<field name="unit_amount" on_change="on_change_unit_amount(product_id, unit_amount, False, product_uom_id,journal_id)" widget="float_time"/>
<field name="to_invoice"/>
@@ -46,6 +46,7 @@ class timesheet_report(osv.osv):
'department_id':fields.many2one('hr.department','Department',readonly=True),
'date_from': fields.date('Date from',readonly=True,),
'date_to': fields.date('Date to',readonly=True),
'date_current': fields.date('Current date', required=True),
'state' : fields.selection([
('new', 'New'),
('draft','Draft'),
@@ -64,6 +65,9 @@ class timesheet_report(osv.osv):
htss.name,
htss.date_from,
htss.date_to,
to_char(htss.date_from, 'YYYY-MM-DD') as day,
to_char(htss.date_from, 'YYYY') as year,
to_char(htss.date_from, 'MM') as month,
count(*) as nbr,
aal.unit_amount as quantity,
aal.amount as cost,
+46 -48
View File
@@ -45,7 +45,7 @@ class mail_message(osv.Model):
_inherit = ['ir.needaction_mixin']
_order = 'id desc'
_message_read_limit = 10
_message_read_limit = 15
_message_read_fields = ['id', 'parent_id', 'model', 'res_id', 'body', 'subject', 'date', 'to_read',
'type', 'vote_user_ids', 'attachment_ids', 'author_id', 'partner_ids', 'record_name', 'favorite_user_ids']
_message_record_name_length = 18
@@ -77,8 +77,7 @@ class mail_message(osv.Model):
notif_obj = self.pool.get('mail.notification')
notif_ids = notif_obj.search(cr, uid, [
('partner_id', 'in', [partner_id]),
('message_id', 'in', ids),
('read', '=', True)
('message_id', 'in', ids)
], context=context)
for notif in notif_obj.browse(cr, uid, notif_ids, context=context):
res[notif.message_id.id] = not notif.read
@@ -163,13 +162,14 @@ class mail_message(osv.Model):
#------------------------------------------------------
def vote_toggle(self, cr, uid, ids, context=None):
''' Toggles vote. Performed using read to avoid access rights issues. '''
''' Toggles vote. Performed using read to avoid access rights issues.
Done as SUPERUSER_ID because uid may vote for a message he cannot modify. '''
for message in self.read(cr, uid, ids, ['vote_user_ids'], context=context):
new_has_voted = not (uid in message.get('vote_user_ids'))
if new_has_voted:
self.write(cr, uid, message.get('id'), {'vote_user_ids': [(4, uid)]}, context=context)
self.write(cr, SUPERUSER_ID, message.get('id'), {'vote_user_ids': [(4, uid)]}, context=context)
else:
self.write(cr, uid, message.get('id'), {'vote_user_ids': [(3, uid)]}, context=context)
self.write(cr, SUPERUSER_ID, message.get('id'), {'vote_user_ids': [(3, uid)]}, context=context)
return new_has_voted or False
#------------------------------------------------------
@@ -177,13 +177,14 @@ class mail_message(osv.Model):
#------------------------------------------------------
def favorite_toggle(self, cr, uid, ids, context=None):
''' Toggles favorite. Performed using read to avoid access rights issues. '''
''' Toggles favorite. Performed using read to avoid access rights issues.
Done as SUPERUSER_ID because uid may star a message he cannot modify. '''
for message in self.read(cr, uid, ids, ['favorite_user_ids'], context=context):
new_is_favorite = not (uid in message.get('favorite_user_ids'))
if new_is_favorite:
self.write(cr, uid, message.get('id'), {'favorite_user_ids': [(4, uid)]}, context=context)
self.write(cr, SUPERUSER_ID, message.get('id'), {'favorite_user_ids': [(4, uid)]}, context=context)
else:
self.write(cr, uid, message.get('id'), {'favorite_user_ids': [(3, uid)]}, context=context)
self.write(cr, SUPERUSER_ID, message.get('id'), {'favorite_user_ids': [(3, uid)]}, context=context)
return new_is_favorite or False
#------------------------------------------------------
@@ -252,9 +253,11 @@ class mail_message(osv.Model):
# result = sorted(result, key=lambda k: k['id'])
tree_not = []
# expandable for not show message
for message_id, message in read_messages.iteritems():
# get all childs
# SHOULD NOT BE SUPERUSED_ID -> check search is correctly implemented in mail.message
id_list = sorted(read_messages.keys())
for message_id in id_list:
message = read_messages[message_id]
# TDE note: check search is correctly implemented in mail.message
not_loaded_ids = self.search(cr, uid, [
('parent_id', '=', message['id']),
('id', 'not in', message_loaded_ids),
@@ -307,7 +310,7 @@ class mail_message(osv.Model):
'type': 'expandable',
'parent_id': parent_id,
'id': -1,
'max_limit': True
'max_limit': True,
})
return message_list
@@ -342,11 +345,9 @@ class mail_message(osv.Model):
further parents
:return list: list of trees of messages
"""
print '>>> executing message_read'
if message_loaded_ids:
domain += [('id', 'not in', message_loaded_ids)]
limit = limit or self._message_read_limit
limit = 200
read_messages = {}
message_list = []
@@ -359,37 +360,36 @@ class mail_message(osv.Model):
# TDE FIXME: check access rights on search are implemented for mail.message
# fetch messages according to the domain, add their parents if uid has access to
if not ids:
ids = self.search(cr, uid, domain, context=context, limit=limit)
for message in self.read(cr, uid, ids, self._message_read_fields, context=context):
# if not in tree and not in message_loded list
if not read_messages.get(message.get('id')) and message.get('id') not in message_loaded_ids:
read_messages[message.get('id')] = message
message_list.append(self._message_get_dict(cr, uid, message, context=context))
ids = self.search(cr, uid, domain, context=context, limit=limit)
for message in self.read(cr, uid, ids, self._message_read_fields, context=context):
# if not in tree and not in message_loded list
if not read_messages.get(message.get('id')) and message.get('id') not in message_loaded_ids:
read_messages[message.get('id')] = message
message_list.append(self._message_get_dict(cr, uid, message, context=context))
# get all parented message if the user have the access
parent = self._get_parent(cr, uid, message, context=context)
while parent and parent.get('id') != parent_id:
if not read_messages.get(parent.get('id')) and parent.get('id') not in message_loaded_ids:
read_messages[parent.get('id')] = parent
message_list.append(self._message_get_dict(cr, uid, parent, context=context))
parent = self._get_parent(cr, uid, parent, context=context)
# get all parented message if the user have the access
parent = self._get_parent(cr, uid, message, context=context)
while parent and parent.get('id') != parent_id:
if not read_messages.get(parent.get('id')) and parent.get('id') not in message_loaded_ids:
read_messages[parent.get('id')] = parent
message_list.append(self._message_get_dict(cr, uid, parent, context=context))
parent = self._get_parent(cr, uid, parent, context=context)
# get the child expandable messages for the tree
message_list = sorted(message_list, key=lambda k: k['id'])
message_list = self._message_read_expandable(cr, uid, message_list, read_messages,
message_loaded_ids=message_loaded_ids, domain=domain, context=context, parent_id=parent_id, limit=limit)
# get the child expandable messages for the tree
message_list = sorted(message_list, key=lambda k: k['id'])
message_list = self._message_read_expandable(cr, uid, message_list, read_messages,
message_loaded_ids=message_loaded_ids, domain=domain, context=context, parent_id=parent_id, limit=limit)
return message_list
# TDE Note: do we need this ?
def user_free_attachment(self, cr, uid, context=None):
attachment = self.pool.get('ir.attachment')
attachment_list = []
attachment_ids = attachment.search(cr, uid, [('res_model', '=', 'mail.message'), ('create_uid', '=', uid)])
if len(attachment_ids):
attachment_list = [{'id': attach.id, 'name': attach.name, 'date': attach.create_date} for attach in attachment.browse(cr, uid, attachment_ids, context=context)]
return attachment_list
# def user_free_attachment(self, cr, uid, context=None):
# attachment = self.pool.get('ir.attachment')
# attachment_list = []
# attachment_ids = attachment.search(cr, uid, [('res_model', '=', 'mail.message'), ('create_uid', '=', uid)])
# if len(attachment_ids):
# attachment_list = [{'id': attach.id, 'name': attach.name, 'date': attach.create_date} for attach in attachment.browse(cr, uid, attachment_ids, context=context)]
# return attachment_list
#------------------------------------------------------
# Email api
@@ -410,7 +410,7 @@ class mail_message(osv.Model):
- create: if
- I am in the document message_follower_ids OR
- I can write on the related document if res_model, res_id OR
- I write a mail to another user (no res_model)
- I create a private message (no model, no res_id)
- Otherwise: raise
- write: if
- I can write on the related document if res_model, res_id
@@ -448,10 +448,14 @@ class mail_message(osv.Model):
if operation == 'read':
author_ids = [mid for mid, message in message_values.iteritems()
if message.get('author_id') and message.get('author_id') == partner_id]
# Create: Check messages you create that are private messages -> ir.rule ?
elif operation == 'create':
author_ids = [mid for mid, message in message_values.iteritems()
if not message.get('model') and not message.get('res_id')]
else:
author_ids = []
# Create: Check message_follower_ids and author_ids
# Create: Check message_follower_ids
if operation == 'create':
doc_follower_ids = []
for model, mids in model_record_ids.items():
@@ -467,12 +471,6 @@ class mail_message(osv.Model):
else:
doc_follower_ids = []
# Create/write: Check author_ids
if operation == 'create' or operation == 'write':
author_ids = author_ids+[mid for mid, message in message_values.iteritems()
if message.get('author_id') and message.get('author_id') == partner_id and not message.get('res_model')]
# Calculate remaining ids, and related model/res_ids
model_record_ids = {}
other_ids = set(ids).difference(set(notified_ids), set(author_ids), set(doc_follower_ids))
+1 -1
View File
@@ -58,7 +58,7 @@
<field name="author_id"/>
<field name="partner_ids"/>
<filter string="Unread"
name="messages_unread" help="Show messages to read"
name="message_unread" help="Show messages to read"
domain="[('to_read', '=', True)]"/>
<filter string="Comments"
name="comments" help="Comments"
+8 -8
View File
@@ -108,12 +108,12 @@ class mail_thread(osv.AbstractModel):
# find the document followers, update the data
fol_obj = self.pool.get('mail.followers')
fol_ids = fol_obj.search(cr, SUPERUSER_ID, [
fol_ids = fol_obj.search(cr, uid, [
('partner_id', '=', user_pid),
('res_id', 'in', ids),
('res_model', '=', self._name),
], context=context)
for fol in fol_obj.browse(cr, SUPERUSER_ID, fol_ids, context=context):
for fol in fol_obj.browse(cr, uid, fol_ids, context=context):
thread_subtype_dict = res[fol.res_id]['message_subtype_data']
for subtype in fol.subtype_ids:
thread_subtype_dict[subtype.name]['followed'] = True
@@ -225,8 +225,8 @@ class mail_thread(osv.AbstractModel):
def create(self, cr, uid, vals, context=None):
""" Override to subscribe the current user. """
thread_id = super(mail_thread, self).create(cr, SUPERUSER_ID, vals, context=context)
self.message_subscribe_users(cr, SUPERUSER_ID, [thread_id], [uid], context=context)
thread_id = super(mail_thread, self).create(cr, uid, vals, context=context)
self.message_subscribe_users(cr, uid, [thread_id], [uid], context=context)
return thread_id
def unlink(self, cr, uid, ids, context=None):
@@ -705,10 +705,10 @@ class mail_thread(osv.AbstractModel):
mail_message = self.pool.get('mail.message')
attachment_ids = ir_attachment.search(cr, SUPERUSER_ID, [('res_model', '=', 'mail.message'), ('res_id', '=', 0), ('create_uid', '=', uid), ('id', 'in', attachments)], context=context)
if attachment_ids:
ir_attachment.write(cr, SUPERUSER_ID, attachment_ids, { 'res_model': self._name, 'res_id': thread_id }, context=context)
mail_message.write(cr, SUPERUSER_ID, [new_message_id], {'attachment_ids': [(6, 0, [pid for pid in attachment_ids])]} )
new_message = self.pool.get('mail.message').message_read(cr, uid, [new_message_id])
ir_attachment.write(cr, SUPERUSER_ID, attachment_ids, {'res_model': self._name, 'res_id': thread_id}, context=context)
mail_message.write(cr, SUPERUSER_ID, [new_message_id], {'attachment_ids': [(6, 0, [pid for pid in attachment_ids])]}, context=context)
new_message = self.pool.get('mail.message').message_read(cr, uid, [new_message_id], context=context)
return new_message
#------------------------------------------------------
+13
View File
@@ -126,6 +126,19 @@ class res_users(osv.Model):
return self.pool.get('res.partner').message_post_api(cr, uid, partner_id, body=body, subject=subject,
type=type, subtype=subtype, parent_id=parent_id, attachments=attachments, context=context, **kwargs)
def message_post(self, cr, uid, thread_id, context=None, **kwargs):
""" Redirect the posting of message on res.users to the related partner.
This is done because when giving the context of Chatter on the
various mailboxes, we do not have access to the current partner_id.
We therefore post on the user and redirect on its partner. """
assert thread_id, "res.users does not support posting global messages"
if context and 'thread_model' in context:
context['thread_model'] = 'res.partner'
if isinstance(thread_id, (list, tuple)):
thread_id = thread_id[0]
partner_id = self.pool.get('res.users').read(cr, uid, thread_id, ['partner_id'], context=context)['partner_id'][0]
return self.pool.get('res.partner').message_post(cr, uid, partner_id, context=context, **kwargs)
def message_update(self, cr, uid, ids, msg_dict, update_vals=None, context=None):
partner_id = self.pool.get('res.users').browse(cr, uid, ids)[0].partner_id.id
return self.pool.get('res.partner').message_update(cr, uid, [partner_id], msg_dict,
+1 -1
View File
@@ -11,7 +11,7 @@
</record>
<record id="mail_followers_read_own" model="ir.rule">
<field name="name">mail.followers: read its own entries</field>
<field name="name">mail.followers: read and write its own entries</field>
<field name="model_id" ref="model_mail_followers"/>
<field name="domain_force">[('partner_id', '=', user.partner_id.id)]</field>
<field name="perm_create" eval="False"/>
+3
View File
@@ -63,6 +63,9 @@
opacity: 0.8;
-webkit-transition: opacity 0.2s linear;
}
.openerp .oe_mail .oe_msg.oe_msg_composer .oe_msg_footer{
height: auto;
}
.openerp .oe_mail .oe_msg .oe_msg_content{
display: block;
overflow: hidden;
File diff suppressed because it is too large Load Diff
+5 -12
View File
@@ -39,6 +39,7 @@ openerp_mail_followers = function(session, mail) {
this._check_visibility();
this.reinit();
this.bind_events();
this._super();
},
_check_visibility: function() {
@@ -72,7 +73,7 @@ openerp_mail_followers = function(session, mail) {
target: 'new',
context: {
'default_res_model': self.view.dataset.model,
'default_res_id': self.view.dataset.ids[0]
'default_res_id': self.view.datarecord.id,
},
}
self.do_action(action, {
@@ -85,18 +86,11 @@ openerp_mail_followers = function(session, mail) {
read_value: function () {
var self = this;
return this.ds_model.read_ids([this.view.dataset.ids[0]], ['message_follower_ids']).pipe(function (results) {
return this.ds_model.read_ids([this.view.datarecord.id], ['message_follower_ids']).pipe(function (results) {
self.set_value(results[0].message_follower_ids);
});
},
set_value: function (value_) {
this._super(value_);
// TDE FIXME: render_value is never called... ask to niv
// TDE TODO: in start, call this._super(), should resolve this issue
this.render_value();
},
render_value: function () {
this.reinit();
return this.fetch_followers(this.get("value"));
@@ -188,8 +182,7 @@ openerp_mail_followers = function(session, mail) {
display_subtypes:function (data) {
var self = this;
var subtype_list_ul = this.$('.oe_subtypes');
var records = data[this.view.dataset.ids[0]].message_subtype_data;
var records = data[this.view.datarecord.id || this.view.dataset.ids[0]].message_subtype_data;
_(records).each(function (record, record_name) {
record.name = record_name;
record.followed = record.followed || undefined;
@@ -209,7 +202,7 @@ openerp_mail_followers = function(session, mail) {
$(record).attr('checked',false);
});
var context = new session.web.CompoundContext(this.build_context(), {});
return this.ds_model.call('message_unsubscribe_users', [[this.view.dataset.ids[0]], [this.session.uid], context]).pipe(this.proxy('read_value'));
return this.ds_model.call('message_unsubscribe_users', [[this.view.datarecord.id], [this.session.uid], context]).pipe(this.proxy('read_value'));
},
do_update_subscription: function (event) {
+39 -40
View File
@@ -17,7 +17,7 @@
<t t-name="mail.compose_message">
<div class="oe_msg oe_msg_composer">
<div class="oe_msg_left">
<img class="oe_msg_icon" alt="User img" t-attf-src="#{widget.datasets.avatar}"/>
<img class="oe_msg_icon" alt="User img" t-attf-src="#{widget.avatar}"/>
</div>
<div class="oe_msg_center">
<div class="oe_msg_content">
@@ -70,8 +70,8 @@
Template used to display attachments in a mail.message
-->
<t t-name="mail.thread.message.attachments">
<ul t-attf-class="oe_msg_attachments #{widget.datasets.attachment_ids[0]?'':'oe_hidden'}">
<t t-foreach="widget.datasets.attachment_ids" t-as="attachment">
<ul t-attf-class="oe_msg_attachments #{widget.attachment_ids[0]?'':'oe_hidden'}">
<t t-foreach="widget.attachment_ids" t-as="attachment">
<li>
<span t-if="(attachment.upload or attachment.percent_loaded&lt;100)" t-attf-title="{(attachment.name || attachment.filename) + (attachment.date?' \n('+attachment.date+')':'' )}" t-attf-name="{attachment.name || attachment.filename}">
<div class="oe_upload_in_process">
@@ -82,7 +82,7 @@
<a t-if="(!attachment.upload or attachment.percent_loaded&gt;=100)" t-att-href="attachment.url" t-attf-title="{(attachment.name || attachment.filename) + (attachment.date?' \n('+attachment.date+')':'' )}">
<t t-raw="attachment.name || attachment.filename"/>
</a>
<t t-if="widget.options.show_attachment_delete and (!attachment.upload or attachment.percent_loaded&gt;=100)">
<t t-if="(!attachment.upload or attachment.percent_loaded&gt;=100)">
<a class="oe_right oe_mail_attachment_delete" title="Delete this attachment" t-attf-data-id="{attachment.id}">x</a>
</t>
@@ -105,13 +105,13 @@
<t t-name="mail.thread.list_recipients">
<div class="oe_mail_list_recipients">
Post to:
<span t-if="!widget.datasets.is_private" class="oe_all_follower">All Followers</span>
<t t-if="!widget.datasets.is_private and widget.datasets.partner_ids.length"> and </t>
<span t-if="!widget.is_private" class="oe_all_follower">All Followers</span>
<t t-if="!widget.is_private and widget.partner_ids.length"> and </t>
<t t-set="inc" t-value="0"/>
<t t-if="widget.datasets.partner_ids.length" t-foreach="widget.datasets.partner_ids" t-as="partner"><span t-attf-class="oe_partner_follower #{inc>=3?'oe_hidden':''}"><t t-if="inc" t-raw="', '"/><a t-attf-href="#model=res.partner&amp;id=#{partner[0]}"><t t-raw="partner[1]"/></a></span><t t-set="inc" t-value="inc+1"/>
<t t-if="widget.partner_ids.length" t-foreach="widget.partner_ids" t-as="partner"><span t-attf-class="oe_partner_follower #{inc>=3?'oe_hidden':''}"><t t-if="inc" t-raw="', '"/><a t-attf-href="#model=res.partner&amp;id=#{partner[0]}"><t t-raw="partner[1]"/></a></span><t t-set="inc" t-value="inc+1"/>
</t>
<t t-if="widget.datasets.partner_ids.length>=3">
<span class="oe_more">, <a><t t-raw="widget.datasets.partner_ids.length-3"/> others...</a></span>
<t t-if="widget.partner_ids.length>=3">
<span class="oe_more">, <a><t t-raw="widget.partner_ids.length-3"/> others...</a></span>
<a class="oe_more_hidden">&lt;&lt;&lt;</a>
</t>
</div>
@@ -174,9 +174,9 @@
-->
<div t-name="mail.record_thread" class="oe_mail_record_wall">
<!-- <h4>History and Comments</h4> -->
<ul class="oe_mail_wall_threads">
<div class="oe_mail_wall_threads">
<!-- contains the document thread -->
</ul>
</div>
</div>
<t t-name="mail.thread">
@@ -185,43 +185,42 @@
<!-- default layout -->
<t t-name="mail.thread.message">
<div t-attf-class="oe_msg oe_lvl_#{widget.datasets.thread_level} oe_msg_#{widget.datasets.type} oe_msg_#{widget.datasets.to_read?'unread':'read'}">
<!-- message actions (read/unread, reply, delete...) -->
<div t-attf-class="oe_msg oe_lvl_#{widget.thread_level} oe_msg_#{widget.type} oe_msg_#{widget.to_read?'unread':'read'}">
<div class='oe_msg_left'>
<a t-attf-href="#model=res.partner&amp;id=#{widget.datasets.author_id[0]}" t-att-title="widget.datasets.author_id[1]">
<img class="oe_msg_icon" t-att-src="widget.datasets.avatar"/>
<a t-attf-href="#model=res.partner&amp;id=#{widget.author_id[0]}" t-att-title="widget.author_id[1]">
<img class="oe_msg_icon" t-att-src="widget.avatar"/>
</a>
</div>
<div class="oe_msg_center">
<div class='oe_msg_icons'>
<span class='oe_read' t-if="widget.datasets.show_read_unread_button"><a title="Read" class="oe_e">W</a></span>
<span class='oe_unread' t-if="widget.datasets.show_read_unread_button"><a title="Set back to unread" class="oe_e">W</a></span>
<span class='oe_reply' t-if="widget.datasets.show_reply_button"><a title="Reply" class="oe_e">(</a></span>
<span class='oe_star'><a t-attf-class="oe_e oe_mail_starbox #{widget.datasets.has_stared?'oe_stared':''}">7</a></span>
<span class='oe_read' t-if="widget.show_read_unread_button"><a title="Read" class="oe_e">W</a></span>
<span class='oe_unread' t-if="widget.show_read_unread_button"><a title="Set back to unread" class="oe_e">W</a></span>
<span class='oe_reply' t-if="widget.show_reply_button"><a title="Reply" class="oe_e">(</a></span>
<span class='oe_star'><a t-attf-class="oe_e oe_mail_starbox #{widget.has_stared?'oe_stared':''}">7</a></span>
</div>
<!-- message itself -->
<div class="oe_msg_content">
<h1 t-if="widget.datasets.subject" class="oe_msg_title">
<t t-raw="widget.datasets.subject"/>
<h1 t-if="widget.subject" class="oe_msg_title">
<t t-raw="widget.subject"/>
</h1>
<div class="oe_msg_body">
<t t-if="widget.options.show_record_name and widget.datasets.record_name and (!widget.datasets.subject) and !widget.options.thread_level and !widget.options.display_on_thread[0] and widget.datasets.model!='res.partner'">
<a class="oe_mail_action_model" t-attf-href="#model=#{widget.datasets.model}&amp;id=#{widget.datasets.res_id}"><t t-raw="widget.datasets.record_name"/></a>
<t t-if="widget.options.show_record_name and widget.record_name and (!widget.subject) and !widget.options.thread_level and !widget.options.display_on_thread[0] and widget.model!='res.partner'">
<a class="oe_mail_action_model" t-attf-href="#model=#{widget.model}&amp;id=#{widget.res_id}"><t t-raw="widget.record_name"/></a>
</t>
<t t-raw="widget.datasets.body"/>
<t t-raw="widget.body"/>
</div>
<t t-if="widget.datasets.attachment_ids.length > 0">
<t t-if="widget.attachment_ids.length > 0">
<t t-call="mail.thread.message.attachments"/>
</t>
</div>
<div class="oe_msg_footer">
from <a t-if="widget.datasets.author_id" t-attf-href="#model=res.partner&amp;id=#{widget.datasets.author_id[0]}"><t t-raw="widget.datasets.author_id[1]"/></a>
<span t-att-title="widget.datasets.date"><t t-raw="widget.datasets.timerelative"/></span>
<a t-if="widget.datasets.attachment_ids.length > 0" class="oe_mail_msg_view_attachments">
<t t-if="widget.datasets.attachment_ids.length == 1">1 Attachment</t>
<t t-if="widget.datasets.attachment_ids.length > 1"><t t-raw="widget.datasets.attachment_ids.length"/> Attachments</t>
from <a t-if="widget.author_id" t-attf-href="#model=res.partner&amp;id=#{widget.author_id[0]}"><t t-raw="widget.author_id[1]"/></a>
<span t-att-title="widget.date"><t t-raw="widget.timerelative"/></span>
<a t-if="widget.attachment_ids.length > 0" class="oe_mail_msg_view_attachments">
<t t-if="widget.attachment_ids.length == 1">1 Attachment</t>
<t t-if="widget.attachment_ids.length > 1"><t t-raw="widget.attachment_ids.length"/> Attachments</t>
</a>
<t t-call="mail.thread.message.vote"/>
</div>
@@ -231,9 +230,9 @@
<!-- expandable message layout -->
<t t-name="mail.thread.expandable">
<div t-attf-class="oe_msg oe_msg_#{widget.datasets.type} oe_msg_unread">
<div t-attf-class="oe_msg oe_msg_#{widget.type} oe_msg_unread">
<div class="oe_msg_content oe_msg_more_message">
<a class="oe_msg_fetch_more">Load more messages <span t-if="widget.datasets.nb_messages>0">(<t t-raw="widget.datasets.nb_messages"/> messages not display)</span>...</a>
<a class="oe_msg_fetch_more">Load more messages <span t-if="widget.nb_messages>0">(<t t-raw="widget.nb_messages"/> messages not display)</span>...</a>
</div>
</div>
</t>
@@ -254,22 +253,22 @@
<span t-name="mail.thread.message.vote">
<!--
<span class="oe_left oe_mail_vote_count">
<t t-if='widget.datasets.has_voted'>
<t t-if='widget.has_voted'>
You
</t>
<t t-if='(widget.datasets.vote_nb - (widget.datasets.has_voted ? 1 : 0)) > 0'>
<t t-if='widget.datasets.has_voted'> and </t>
<t t-esc="widget.datasets.vote_nb"/> people
<t t-if='(widget.vote_nb - (widget.has_voted ? 1 : 0)) > 0'>
<t t-if='widget.has_voted'> and </t>
<t t-esc="widget.vote_nb"/> people
</t>
<t t-if='(widget.datasets.vote_nb - (widget.datasets.has_voted ? 1 : 0)) > 0'>
<t t-raw="(widget.datasets.vote_nb - (widget.datasets.has_voted ? 1 : 0))"/>
<t t-if='(widget.vote_nb - (widget.has_voted ? 1 : 0)) > 0'>
<t t-raw="(widget.vote_nb - (widget.has_voted ? 1 : 0))"/>
concur
</t>
</span>
<button t-attf-class="oe_msg_vote oe_tag">
<span>
<t t-if="!widget.datasets.has_voted">Concur</t>
<t t-if="widget.datasets.has_voted">Respectfully disagree</t>
<t t-if="!widget.has_voted">Concur</t>
<t t-if="widget.has_voted">Respectfully disagree</t>
</span>
</button>
-->
+14
View File
@@ -581,11 +581,19 @@ class test_mail(TestMailMockups):
reply_msg = MAIL_TEMPLATE.format(to='Pretty Pigs <group+pigs@example.com>, other@gmail.com', subject='Re: 1',
extra='In-Reply-To: %s' % msg1.message_id)
self.mail_group.message_process(cr, uid, None, reply_msg)
# TDE note: temp various asserts because of the random bug about msg1.child_ids
msg_ids = self.mail_message.search(cr, uid, [('model', '=', 'mail.group'), ('res_id', '=', self.group_pigs_id)], limit=1)
new_msg = self.mail_message.browse(cr, uid, msg_ids[0])
self.assertEqual(new_msg.parent_id, msg1, 'Newly processed mail_message (%d) should have msg1 as parent' % (new_msg.id))
# 2. References header
reply_msg2 = MAIL_TEMPLATE.format(to='Pretty Pigs <group+pigs@example.com>, other@gmail.com', subject='Re: Re: 1',
extra='References: <2233@a.com>\r\n\t<3edss_dsa@b.com> %s' % msg1.message_id)
self.mail_group.message_process(cr, uid, None, reply_msg2)
# TDE note: temp various asserts because of the random bug about msg1.child_ids
msg_ids = self.mail_message.search(cr, uid, [('model', '=', 'mail.group'), ('res_id', '=', self.group_pigs_id)], limit=1)
new_msg = self.mail_message.browse(cr, uid, msg_ids[0])
self.assertEqual(new_msg.parent_id, msg1, 'Newly processed mail_message should have msg1 as parent')
# 3. Subject contains [<ID>] + model passed to message+process -> only attached to group, not to mail
reply_msg3 = MAIL_TEMPLATE.format(to='Pretty Pigs <group+pigs@example.com>, other@gmail.com',
@@ -595,6 +603,12 @@ class test_mail(TestMailMockups):
group_pigs.refresh()
msg1.refresh()
self.assertEqual(5, len(group_pigs.message_ids), 'group should contain 5 messages')
# TDE note: python test + debug because of the random error we see with the next assert
if len(msg1.child_ids) != 2:
msg_ids = self.mail_message.search(cr, uid, [('model', '=', 'mail.group'), ('res_id', '=', self.group_pigs_id)], limit=10)
for new_msg in self.mail_message.browse(cr, uid, msg_ids):
print new_msg.subject, '(id', new_msg.id, ')', 'parent_id:', new_msg.parent_id
print '\tchild_ids', [child.id for child in new_msg.child_ids]
self.assertEqual(2, len(msg1.child_ids), 'msg1 should have 2 children now')
def test_60_message_vote(self):
@@ -6,14 +6,14 @@
<field name="model">mail.compose.message</field>
<field name="arch" type="xml">
<form string="Compose Email" version="7.0">
<!-- truly invisible fields for control and options -->
<field name="composition_mode" nolabel="1" invisible="0"/>
<field name="model" nolabel="1" invisible="0"/>
<field name="res_id" nolabel="1" invisible="0"/>
<field name="parent_id" nolabel="1" invisible="0"/>
<field name="content_subtype" nolabel="1" invisible="0"/>
<!-- visible wizard -->
<group>
<!-- truly invisible fields for control and options -->
<field name="composition_mode" invisible="1"/>
<field name="model" invisible="1"/>
<field name="res_id" invisible="1"/>
<field name="parent_id" invisible="1"/>
<field name="content_subtype" invisible="1"/>
<!-- visible wizard -->
<field name="subject" placeholder="Subject..."
attrs="{'invisible':[('content_subtype', '=', 'plain')]}"/>/>
<field name="partner_ids" widget="many2many_tags" placeholder="Add contacts to notify..."
-1
View File
@@ -24,7 +24,6 @@ access_account_account,account.account mrp_worker,account.model_account_account,
access_purchase_order_mrp_worker,purchase.order mrp_worker,purchase.model_purchase_order,mrp.group_mrp_user,1,0,0,0
access_purchase_order_line_mrp_worker,purchase.order.line mrp_worker,purchase.model_purchase_order_line,mrp.group_mrp_user,1,0,0,0
access_hr_timesheet_group_mrp_worker,resource.calendar mrp_manager,resource.model_resource_calendar,mrp.group_mrp_manager,1,1,1,1
access_procurement_stock_worker,procurement.order stock_worker,model_procurement_order,stock.group_stock_user,1,1,1,1
access_procurement_user,procurement.order.user,model_procurement_order,base.group_user,1,1,1,1
access_mrp_production_stock_worker,mrp.production stock_worker,model_mrp_production,stock.group_stock_user,1,0,0,0
access_report_workcenter_load,report.workcenter.load,model_report_workcenter_load,mrp.group_mrp_manager,1,1,1,1
1 id name model_id:id group_id:id perm_read perm_write perm_create perm_unlink
24 access_purchase_order_mrp_worker purchase.order mrp_worker purchase.model_purchase_order mrp.group_mrp_user 1 0 0 0
25 access_purchase_order_line_mrp_worker purchase.order.line mrp_worker purchase.model_purchase_order_line mrp.group_mrp_user 1 0 0 0
26 access_hr_timesheet_group_mrp_worker resource.calendar mrp_manager resource.model_resource_calendar mrp.group_mrp_manager 1 1 1 1
access_procurement_stock_worker procurement.order stock_worker model_procurement_order stock.group_stock_user 1 1 1 1
27 access_procurement_user procurement.order.user model_procurement_order base.group_user 1 1 1 1
28 access_mrp_production_stock_worker mrp.production stock_worker model_mrp_production stock.group_stock_user 1 0 0 0
29 access_report_workcenter_load report.workcenter.load model_report_workcenter_load mrp.group_mrp_manager 1 1 1 1
+1 -1
View File
@@ -13,7 +13,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2012-10-19 05:14+0000\n"
"X-Launchpad-Export-Date: 2012-10-20 05:07+0000\n"
"X-Generator: Launchpad (build 16165)\n"
#. module: product
+10 -11
View File
@@ -7,14 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 6.0dev\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2012-09-20 07:29+0000\n"
"PO-Revision-Date: 2012-05-10 17:41+0000\n"
"Last-Translator: NOVOTRADE RENDSZERHÁZ ( novotrade.hu ) "
"<openerp@novotrade.hu>\n"
"PO-Revision-Date: 2012-10-19 17:22+0000\n"
"Last-Translator: Herczeg Péter <herczegp@gmail.com>\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: 2012-10-19 05:11+0000\n"
"X-Launchpad-Export-Date: 2012-10-20 05:07+0000\n"
"X-Generator: Launchpad (build 16165)\n"
#. module: sale
@@ -400,7 +399,7 @@ msgstr "Rendelés"
#. module: sale
#: field:sale.order,message_ids:0
msgid "Messages"
msgstr ""
msgstr "Üzenetek"
#. module: sale
#: selection:sale.report,month:0
@@ -634,7 +633,7 @@ msgstr "Megerősítés"
#. module: sale
#: view:sale.order:0
msgid "Unread messages"
msgstr ""
msgstr "Olvasatlan üzenetek"
#. module: sale
#: field:sale.order,partner_shipping_id:0
@@ -672,7 +671,7 @@ msgstr ""
#. module: sale
#: field:sale.order,message_unread:0
msgid "Unread Messages"
msgstr ""
msgstr "Olvasatlan üzenetek"
#. module: sale
#: view:sale.order:0
@@ -1105,7 +1104,7 @@ msgstr ""
#. module: sale
#: model:ir.model,name:sale.model_mail_message
msgid "Message"
msgstr ""
msgstr "Üzenet"
#. module: sale
#: field:sale.config.settings,module_warning:0
@@ -1323,7 +1322,7 @@ msgstr ""
#. module: sale
#: field:sale.order,message_is_follower:0
msgid "Is a Follower"
msgstr ""
msgstr "követő"
#. module: sale
#: code:addons/sale/sale.py:261
@@ -1638,7 +1637,7 @@ msgstr "Mégsem"
#. module: sale
#: field:sale.order,message_follower_ids:0
msgid "Followers"
msgstr ""
msgstr "Követők"
#. module: sale
#: code:addons/sale/sale.py:947
@@ -2012,7 +2011,7 @@ msgstr ""
#. module: sale
#: help:sale.order,message_ids:0
msgid "Messages and communication history"
msgstr ""
msgstr "Üzenetek és kommunikáció történet"
#. module: sale
#: view:sale.order:0
+1
View File
@@ -5,6 +5,7 @@
<record id="group_stock_user" model="res.groups">
<field name="name">User</field>
<field name="category_id" ref="base.module_category_warehouse_management"/>
<field name="implied_ids" eval="[(4, ref('base.group_user'))]"/>
</record>
<record id="group_stock_manager" model="res.groups">
<field name="name">Manager</field>