diff --git a/addons/hr_holidays/wizard/hr_holidays_summary_department.py b/addons/hr_holidays/wizard/hr_holidays_summary_department.py index 3688e1ad..0ac88110 100644 --- a/addons/hr_holidays/wizard/hr_holidays_summary_department.py +++ b/addons/hr_holidays/wizard/hr_holidays_summary_department.py @@ -31,4 +31,4 @@ class HolidaysSummaryDept(models.TransientModel): 'model': 'hr.department', 'form': data } - return self.env.ref('hr_holidays.action_report_holidayssummary').report_action(departments, data=datas) + return self.env.ref('hr_holidays.action_report_holidayssummary').with_context(from_transient_model=True).report_action(departments, data=datas) diff --git a/addons/l10n_ch/i18n/de.po b/addons/l10n_ch/i18n/de.po index 23db145e..381fac22 100644 --- a/addons/l10n_ch/i18n/de.po +++ b/addons/l10n_ch/i18n/de.po @@ -1,31 +1,266 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: -# * l10n_ch +# * l10n_ch # -# Translators: -# BT_astauder , 2015 -# Ermin Trevisan , 2015 -# Wolfgang Taferner, 2016 msgid "" msgstr "" -"Project-Id-Version: Odoo 9.0\n" +"Project-Id-Version: Odoo Server 11.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-09-18 15:42+0000\n" -"PO-Revision-Date: 2016-01-15 03:53+0000\n" -"Last-Translator: Wolfgang Taferner\n" -"Language-Team: German (http://www.transifex.com/odoo/odoo-9/language/de/)\n" -"Language: de\n" +"POT-Creation-Date: 2018-01-16 15:58+0000\n" +"PO-Revision-Date: 2018-01-16 15:58+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" +"Plural-Forms: \n" #. module: l10n_ch -#: model:ir.actions.client,name:l10n_ch.action_client_l10n_ch_menu -msgid "Open Account Dashboard Menu" -msgstr " Buchführungsübersicht öffnen" +#: model:ir.model,name:l10n_ch.model_res_bank +msgid "Bank" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_partner_bank +msgid "Bank Accounts" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_company_l10n_ch_isr_print_bank_location +#: model:ir.model.fields,help:l10n_ch.field_res_config_settings_l10n_ch_isr_print_bank_location +msgid "Boolean option field indicating whether or not the alternate layout (the one printing bank name and address) must be used when generating an ISR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_sent +msgid "Boolean value telling whether or not the ISR corresponding to this invoice has already been printed or sent by mail." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_valid +msgid "Boolean value. True iff all the data required to generate the ISR are present" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_bank_l10n_ch_postal_chf +msgid "CHF ISR reference" +msgstr "" + +#. module: l10n_ch +#: model:account.cash.rounding,name:l10n_ch.cash_rounding_5_centime +msgid "Coinage 0.05" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_company +msgid "Companies" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_currency_name +msgid "Currency" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_bank_l10n_ch_postal_eur +msgid "EUR ISR reference" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_mail_template +msgid "Email Templates" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_mail_compose_message +msgid "Email composition wizard" +msgstr "" + +#. module: l10n_ch +#: model:ir.actions.report,name:l10n_ch.l10n_ch_isr_report +msgid "ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.l10n_ch_isr_report_template +msgid "ISR for invoice" +msgstr "ESR bezüglich der Rechnung" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_number_spaced +msgid "ISR number split in blocks of 5 characters (right-justified), to generate ISR report." +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.isr_invoice_search_view +msgid "ISR reference number" +msgstr "" + +#. module: l10n_ch +#: code:addons/l10n_ch/models/mail_compose_message.py:23 +#, python-format +msgid "ISR sent" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_account_invoice +msgid "Invoice" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_number +msgid "L10N Ch Isr Number" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_number_spaced +msgid "L10N Ch Isr Number Spaced" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_optical_line +msgid "L10N Ch Isr Optical Line" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_postal +msgid "L10N Ch Isr Postal" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_postal_formatted +msgid "L10N Ch Isr Postal Formatted" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_sent +msgid "L10N Ch Isr Sent" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_valid +msgid "L10N Ch Isr Valid" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_partner_bank_l10n_ch_postal +msgid "L10N Ch Postal" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_optical_line +msgid "Optical reading line, as it will be printed on ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_postal_formatted +msgid "Postal reference of the bank, formated with '-' and without the padding zeros, to generate ISR report." +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.isr_invoice_form +msgid "Print ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_company_l10n_ch_isr_print_bank_location +msgid "Print bank location" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_config_settings_l10n_ch_isr_print_bank_location +msgid "Print bank on ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.res_config_settings_view_form +msgid "Print the coordinates of your bank under the 'Payment for' title of the ISR.\n" +" Your address will be moved to the 'in favour of' section." +msgstr "" #. module: l10n_ch #: model:ir.ui.menu,name:l10n_ch.account_reports_ch_statements_menu -msgid "Swiss Statements" -msgstr "CH Bilanz- und Erfolgsrechnungen" +msgid "Switzerland" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_0 +msgid "TVA 0%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_25 +msgid "TVA 2.5%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_37 +msgid "TVA 3.7%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_38 +msgid "TVA 3.8%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_77 +msgid "TVA 7.7%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_8 +msgid "TVA 8%" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_partner_bank_l10n_ch_postal +msgid "The ISR number of the company within the bank" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_currency_name +msgid "The name of this invoice's currency" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_postal +msgid "The postal reference identifying the bank managing this ISR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_bank_l10n_ch_postal_chf +msgid "The postal reference of the bank, used to generate ISR payment slips in CHF." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_bank_l10n_ch_postal_eur +msgid "The postal reference of the bank, used to generate ISR payment slips in EUR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_number +msgid "The reference number associated with this invoice" +msgstr "" + +#. module: l10n_ch +#: code:addons/l10n_ch/models/account_invoice.py:154 +#, python-format +msgid "You cannot generate an ISR yet.\n" +"\n" +" For this, you need to :\n" +"\n" +" - set a valid postal account number (or an IBAN referencing one) for your company\n" +"\n" +" - define its bank\n" +"\n" +" - associate this bank with a postal reference for the currency used in this invoice\n" +"\n" +" - fill the 'bank account' field of the invoice with the postal to be used to receive the related payment. A default account will be automatically set for all invoices created after you defined a postal account for your company." +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_config_settings +msgid "res.config.settings" +msgstr "" + diff --git a/addons/l10n_ch/i18n/fr.po b/addons/l10n_ch/i18n/fr.po index fce536ed..9a0899c5 100644 --- a/addons/l10n_ch/i18n/fr.po +++ b/addons/l10n_ch/i18n/fr.po @@ -1,30 +1,266 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: -# * l10n_ch +# * l10n_ch # -# Translators: -# Maxime Chambreuil , 2015 -# Miguel Vidali , 2015 msgid "" msgstr "" -"Project-Id-Version: Odoo 9.0\n" +"Project-Id-Version: Odoo Server 11.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-09-18 15:42+0000\n" -"PO-Revision-Date: 2015-11-11 21:04+0000\n" -"Last-Translator: Maxime Chambreuil \n" -"Language-Team: French (http://www.transifex.com/odoo/odoo-9/language/fr/)\n" -"Language: fr\n" +"POT-Creation-Date: 2018-01-16 15:58+0000\n" +"PO-Revision-Date: 2018-01-16 15:58+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Plural-Forms: nplurals=2; plural=(n > 1);\n" +"Plural-Forms: \n" #. module: l10n_ch -#: model:ir.actions.client,name:l10n_ch.action_client_l10n_ch_menu -msgid "Open Account Dashboard Menu" -msgstr "Ouvrez le menu Comptabilité" +#: model:ir.model,name:l10n_ch.model_res_bank +msgid "Bank" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_partner_bank +msgid "Bank Accounts" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_company_l10n_ch_isr_print_bank_location +#: model:ir.model.fields,help:l10n_ch.field_res_config_settings_l10n_ch_isr_print_bank_location +msgid "Boolean option field indicating whether or not the alternate layout (the one printing bank name and address) must be used when generating an ISR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_sent +msgid "Boolean value telling whether or not the ISR corresponding to this invoice has already been printed or sent by mail." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_valid +msgid "Boolean value. True iff all the data required to generate the ISR are present" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_bank_l10n_ch_postal_chf +msgid "CHF ISR reference" +msgstr "" + +#. module: l10n_ch +#: model:account.cash.rounding,name:l10n_ch.cash_rounding_5_centime +msgid "Coinage 0.05" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_company +msgid "Companies" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_currency_name +msgid "Currency" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_bank_l10n_ch_postal_eur +msgid "EUR ISR reference" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_mail_template +msgid "Email Templates" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_mail_compose_message +msgid "Email composition wizard" +msgstr "" + +#. module: l10n_ch +#: model:ir.actions.report,name:l10n_ch.l10n_ch_isr_report +msgid "ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.l10n_ch_isr_report_template +msgid "ISR for invoice" +msgstr "BVR relatif à la facture" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_number_spaced +msgid "ISR number split in blocks of 5 characters (right-justified), to generate ISR report." +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.isr_invoice_search_view +msgid "ISR reference number" +msgstr "" + +#. module: l10n_ch +#: code:addons/l10n_ch/models/mail_compose_message.py:23 +#, python-format +msgid "ISR sent" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_account_invoice +msgid "Invoice" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_number +msgid "L10N Ch Isr Number" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_number_spaced +msgid "L10N Ch Isr Number Spaced" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_optical_line +msgid "L10N Ch Isr Optical Line" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_postal +msgid "L10N Ch Isr Postal" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_postal_formatted +msgid "L10N Ch Isr Postal Formatted" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_sent +msgid "L10N Ch Isr Sent" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_valid +msgid "L10N Ch Isr Valid" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_partner_bank_l10n_ch_postal +msgid "L10N Ch Postal" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_optical_line +msgid "Optical reading line, as it will be printed on ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_postal_formatted +msgid "Postal reference of the bank, formated with '-' and without the padding zeros, to generate ISR report." +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.isr_invoice_form +msgid "Print ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_company_l10n_ch_isr_print_bank_location +msgid "Print bank location" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_config_settings_l10n_ch_isr_print_bank_location +msgid "Print bank on ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.res_config_settings_view_form +msgid "Print the coordinates of your bank under the 'Payment for' title of the ISR.\n" +" Your address will be moved to the 'in favour of' section." +msgstr "" #. module: l10n_ch #: model:ir.ui.menu,name:l10n_ch.account_reports_ch_statements_menu -msgid "Swiss Statements" -msgstr "Déclarations suisses" +msgid "Switzerland" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_0 +msgid "TVA 0%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_25 +msgid "TVA 2.5%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_37 +msgid "TVA 3.7%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_38 +msgid "TVA 3.8%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_77 +msgid "TVA 7.7%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_8 +msgid "TVA 8%" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_partner_bank_l10n_ch_postal +msgid "The ISR number of the company within the bank" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_currency_name +msgid "The name of this invoice's currency" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_postal +msgid "The postal reference identifying the bank managing this ISR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_bank_l10n_ch_postal_chf +msgid "The postal reference of the bank, used to generate ISR payment slips in CHF." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_bank_l10n_ch_postal_eur +msgid "The postal reference of the bank, used to generate ISR payment slips in EUR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_number +msgid "The reference number associated with this invoice" +msgstr "" + +#. module: l10n_ch +#: code:addons/l10n_ch/models/account_invoice.py:154 +#, python-format +msgid "You cannot generate an ISR yet.\n" +"\n" +" For this, you need to :\n" +"\n" +" - set a valid postal account number (or an IBAN referencing one) for your company\n" +"\n" +" - define its bank\n" +"\n" +" - associate this bank with a postal reference for the currency used in this invoice\n" +"\n" +" - fill the 'bank account' field of the invoice with the postal to be used to receive the related payment. A default account will be automatically set for all invoices created after you defined a postal account for your company." +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_config_settings +msgid "res.config.settings" +msgstr "" + diff --git a/addons/l10n_ch/i18n/it.po b/addons/l10n_ch/i18n/it.po index 2480ce80..f6349399 100644 --- a/addons/l10n_ch/i18n/it.po +++ b/addons/l10n_ch/i18n/it.po @@ -1,28 +1,266 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: -# * l10n_ch +# * l10n_ch # -# Translators: msgid "" msgstr "" -"Project-Id-Version: Odoo 9.0\n" +"Project-Id-Version: Odoo Server 11.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-09-18 15:42+0000\n" -"PO-Revision-Date: 2016-02-24 22:58+0000\n" -"Last-Translator: Martin Trigaux\n" -"Language-Team: Italian (http://www.transifex.com/odoo/odoo-9/language/it/)\n" -"Language: it\n" +"POT-Creation-Date: 2018-01-16 15:58+0000\n" +"PO-Revision-Date: 2018-01-16 15:58+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" +"Plural-Forms: \n" #. module: l10n_ch -#: model:ir.actions.client,name:l10n_ch.action_client_l10n_ch_menu -msgid "Open Account Dashboard Menu" -msgstr "Apri menu dashboard dell'account" +#: model:ir.model,name:l10n_ch.model_res_bank +msgid "Bank" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_partner_bank +msgid "Bank Accounts" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_company_l10n_ch_isr_print_bank_location +#: model:ir.model.fields,help:l10n_ch.field_res_config_settings_l10n_ch_isr_print_bank_location +msgid "Boolean option field indicating whether or not the alternate layout (the one printing bank name and address) must be used when generating an ISR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_sent +msgid "Boolean value telling whether or not the ISR corresponding to this invoice has already been printed or sent by mail." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_valid +msgid "Boolean value. True iff all the data required to generate the ISR are present" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_bank_l10n_ch_postal_chf +msgid "CHF ISR reference" +msgstr "" + +#. module: l10n_ch +#: model:account.cash.rounding,name:l10n_ch.cash_rounding_5_centime +msgid "Coinage 0.05" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_company +msgid "Companies" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_currency_name +msgid "Currency" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_bank_l10n_ch_postal_eur +msgid "EUR ISR reference" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_mail_template +msgid "Email Templates" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_mail_compose_message +msgid "Email composition wizard" +msgstr "" + +#. module: l10n_ch +#: model:ir.actions.report,name:l10n_ch.l10n_ch_isr_report +msgid "ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.l10n_ch_isr_report_template +msgid "ISR for invoice" +msgstr "SR relativo alla fattura" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_number_spaced +msgid "ISR number split in blocks of 5 characters (right-justified), to generate ISR report." +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.isr_invoice_search_view +msgid "ISR reference number" +msgstr "" + +#. module: l10n_ch +#: code:addons/l10n_ch/models/mail_compose_message.py:23 +#, python-format +msgid "ISR sent" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_account_invoice +msgid "Invoice" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_number +msgid "L10N Ch Isr Number" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_number_spaced +msgid "L10N Ch Isr Number Spaced" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_optical_line +msgid "L10N Ch Isr Optical Line" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_postal +msgid "L10N Ch Isr Postal" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_postal_formatted +msgid "L10N Ch Isr Postal Formatted" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_sent +msgid "L10N Ch Isr Sent" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_valid +msgid "L10N Ch Isr Valid" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_partner_bank_l10n_ch_postal +msgid "L10N Ch Postal" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_optical_line +msgid "Optical reading line, as it will be printed on ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_postal_formatted +msgid "Postal reference of the bank, formated with '-' and without the padding zeros, to generate ISR report." +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.isr_invoice_form +msgid "Print ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_company_l10n_ch_isr_print_bank_location +msgid "Print bank location" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_config_settings_l10n_ch_isr_print_bank_location +msgid "Print bank on ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.res_config_settings_view_form +msgid "Print the coordinates of your bank under the 'Payment for' title of the ISR.\n" +" Your address will be moved to the 'in favour of' section." +msgstr "" #. module: l10n_ch #: model:ir.ui.menu,name:l10n_ch.account_reports_ch_statements_menu -msgid "Swiss Statements" +msgid "Switzerland" msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_0 +msgid "TVA 0%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_25 +msgid "TVA 2.5%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_37 +msgid "TVA 3.7%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_38 +msgid "TVA 3.8%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_77 +msgid "TVA 7.7%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_8 +msgid "TVA 8%" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_partner_bank_l10n_ch_postal +msgid "The ISR number of the company within the bank" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_currency_name +msgid "The name of this invoice's currency" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_postal +msgid "The postal reference identifying the bank managing this ISR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_bank_l10n_ch_postal_chf +msgid "The postal reference of the bank, used to generate ISR payment slips in CHF." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_bank_l10n_ch_postal_eur +msgid "The postal reference of the bank, used to generate ISR payment slips in EUR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_number +msgid "The reference number associated with this invoice" +msgstr "" + +#. module: l10n_ch +#: code:addons/l10n_ch/models/account_invoice.py:154 +#, python-format +msgid "You cannot generate an ISR yet.\n" +"\n" +" For this, you need to :\n" +"\n" +" - set a valid postal account number (or an IBAN referencing one) for your company\n" +"\n" +" - define its bank\n" +"\n" +" - associate this bank with a postal reference for the currency used in this invoice\n" +"\n" +" - fill the 'bank account' field of the invoice with the postal to be used to receive the related payment. A default account will be automatically set for all invoices created after you defined a postal account for your company." +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_config_settings +msgid "res.config.settings" +msgstr "" + diff --git a/addons/l10n_ch/i18n/l10n_ch.pot b/addons/l10n_ch/i18n/l10n_ch.pot index 0c549cf2..a0cb2ff5 100644 --- a/addons/l10n_ch/i18n/l10n_ch.pot +++ b/addons/l10n_ch/i18n/l10n_ch.pot @@ -4,10 +4,10 @@ # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 9.0\n" +"Project-Id-Version: Odoo Server 11.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2015-09-18 15:42+0000\n" -"PO-Revision-Date: 2015-09-18 15:42+0000\n" +"POT-Creation-Date: 2018-01-16 15:58+0000\n" +"PO-Revision-Date: 2018-01-16 15:58+0000\n" "Last-Translator: <>\n" "Language-Team: \n" "MIME-Version: 1.0\n" @@ -16,12 +16,251 @@ msgstr "" "Plural-Forms: \n" #. module: l10n_ch -#: model:ir.actions.client,name:l10n_ch.action_client_l10n_ch_menu -msgid "Open Account Dashboard Menu" +#: model:ir.model,name:l10n_ch.model_res_bank +msgid "Bank" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_partner_bank +msgid "Bank Accounts" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_company_l10n_ch_isr_print_bank_location +#: model:ir.model.fields,help:l10n_ch.field_res_config_settings_l10n_ch_isr_print_bank_location +msgid "Boolean option field indicating whether or not the alternate layout (the one printing bank name and address) must be used when generating an ISR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_sent +msgid "Boolean value telling whether or not the ISR corresponding to this invoice has already been printed or sent by mail." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_valid +msgid "Boolean value. True iff all the data required to generate the ISR are present" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_bank_l10n_ch_postal_chf +msgid "CHF ISR reference" +msgstr "" + +#. module: l10n_ch +#: model:account.cash.rounding,name:l10n_ch.cash_rounding_5_centime +msgid "Coinage 0.05" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_company +msgid "Companies" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_currency_name +msgid "Currency" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_bank_l10n_ch_postal_eur +msgid "EUR ISR reference" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_mail_template +msgid "Email Templates" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_mail_compose_message +msgid "Email composition wizard" +msgstr "" + +#. module: l10n_ch +#: model:ir.actions.report,name:l10n_ch.l10n_ch_isr_report +msgid "ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.l10n_ch_isr_report_template +msgid "ISR for invoice" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_number_spaced +msgid "ISR number split in blocks of 5 characters (right-justified), to generate ISR report." +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.isr_invoice_search_view +msgid "ISR reference number" +msgstr "" + +#. module: l10n_ch +#: code:addons/l10n_ch/models/mail_compose_message.py:23 +#, python-format +msgid "ISR sent" +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_account_invoice +msgid "Invoice" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_number +msgid "L10N Ch Isr Number" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_number_spaced +msgid "L10N Ch Isr Number Spaced" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_optical_line +msgid "L10N Ch Isr Optical Line" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_postal +msgid "L10N Ch Isr Postal" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_postal_formatted +msgid "L10N Ch Isr Postal Formatted" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_sent +msgid "L10N Ch Isr Sent" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_account_invoice_l10n_ch_isr_valid +msgid "L10N Ch Isr Valid" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_partner_bank_l10n_ch_postal +msgid "L10N Ch Postal" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_optical_line +msgid "Optical reading line, as it will be printed on ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_postal_formatted +msgid "Postal reference of the bank, formated with '-' and without the padding zeros, to generate ISR report." +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.isr_invoice_form +msgid "Print ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_company_l10n_ch_isr_print_bank_location +msgid "Print bank location" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,field_description:l10n_ch.field_res_config_settings_l10n_ch_isr_print_bank_location +msgid "Print bank on ISR" +msgstr "" + +#. module: l10n_ch +#: model:ir.ui.view,arch_db:l10n_ch.res_config_settings_view_form +msgid "Print the coordinates of your bank under the 'Payment for' title of the ISR.\n" +" Your address will be moved to the 'in favour of' section." msgstr "" #. module: l10n_ch #: model:ir.ui.menu,name:l10n_ch.account_reports_ch_statements_menu -msgid "Swiss Statements" +msgid "Switzerland" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_0 +msgid "TVA 0%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_25 +msgid "TVA 2.5%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_37 +msgid "TVA 3.7%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_38 +msgid "TVA 3.8%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_77 +msgid "TVA 7.7%" +msgstr "" + +#. module: l10n_ch +#: model:account.tax.group,name:l10n_ch.tax_group_tva_8 +msgid "TVA 8%" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_partner_bank_l10n_ch_postal +msgid "The ISR number of the company within the bank" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_currency_name +msgid "The name of this invoice's currency" +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_postal +msgid "The postal reference identifying the bank managing this ISR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_bank_l10n_ch_postal_chf +msgid "The postal reference of the bank, used to generate ISR payment slips in CHF." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_res_bank_l10n_ch_postal_eur +msgid "The postal reference of the bank, used to generate ISR payment slips in EUR." +msgstr "" + +#. module: l10n_ch +#: model:ir.model.fields,help:l10n_ch.field_account_invoice_l10n_ch_isr_number +msgid "The reference number associated with this invoice" +msgstr "" + +#. module: l10n_ch +#: code:addons/l10n_ch/models/account_invoice.py:154 +#, python-format +msgid "You cannot generate an ISR yet.\n" +"\n" +" For this, you need to :\n" +"\n" +" - set a valid postal account number (or an IBAN referencing one) for your company\n" +"\n" +" - define its bank\n" +"\n" +" - associate this bank with a postal reference for the currency used in this invoice\n" +"\n" +" - fill the 'bank account' field of the invoice with the postal to be used to receive the related payment. A default account will be automatically set for all invoices created after you defined a postal account for your company." +msgstr "" + +#. module: l10n_ch +#: model:ir.model,name:l10n_ch.model_res_config_settings +msgid "res.config.settings" msgstr "" diff --git a/addons/l10n_fr_certification/models/account.py b/addons/l10n_fr_certification/models/account.py index 2198c6ab..cfadd41f 100644 --- a/addons/l10n_fr_certification/models/account.py +++ b/addons/l10n_fr_certification/models/account.py @@ -36,13 +36,13 @@ class AccountMove(models.Model): _('An error occured when computing the inalterability. Impossible to get the unique previous posted journal entry.')) #build and return the hash - return self._compute_hash(prev_move.l10n_fr_hash if prev_move else '') + return self._compute_hash(prev_move.l10n_fr_hash if prev_move else u'') def _compute_hash(self, previous_hash): """ Computes the hash of the browse_record given as self, based on the hash of the previous record in the company's securisation sequence given as parameter""" self.ensure_one() - hash_string = sha256(previous_hash + self.l10n_fr_string_to_hash) + hash_string = sha256((previous_hash + self.l10n_fr_string_to_hash).encode('utf-8')) return hash_string.hexdigest() def _compute_string_to_hash(self): @@ -63,7 +63,7 @@ class AccountMove(models.Model): values[k] = _getattrstring(line, field) #make the json serialization canonical # (https://tools.ietf.org/html/draft-staykov-hu-json-canonical-form-00) - move.l10n_fr_string_to_hash = dumps(values, sort_keys=True, encoding="utf-8", + move.l10n_fr_string_to_hash = dumps(values, sort_keys=True, ensure_ascii=True, indent=None, separators=(',',':')) @@ -118,7 +118,7 @@ class AccountMove(models.Model): if not moves: raise UserError(_('There isn\'t any journal entry flagged for data inalterability yet for the company %s. This mechanism only runs for journal entries generated after the installation of the module France - Certification CGI 286 I-3 bis.') % self.env.user.company_id.name) - previous_hash = '' + previous_hash = u'' start_move_info = [] for move in moves: if move.l10n_fr_hash != move._compute_hash(previous_hash=previous_hash): diff --git a/addons/mail/static/src/js/systray.js b/addons/mail/static/src/js/systray.js index 2a786fd7..4ccd4b69 100644 --- a/addons/mail/static/src/js/systray.js +++ b/addons/mail/static/src/js/systray.js @@ -3,7 +3,6 @@ flectra.define('mail.systray', function (require) { var config = require('web.config'); var core = require('web.core'); -var framework = require('web.framework'); var session = require('web.session'); var SystrayMenu = require('web.SystrayMenu'); var Widget = require('web.Widget'); @@ -175,6 +174,9 @@ var ActivityMenu = Widget.extend({ return self._rpc({ model: 'res.users', method: 'activity_user_count', + kwargs: { + context: session.user_context, + }, }).then(function (data) { self.activities = data; self.activityCounter = _.reduce(data, function(total_count, p_data){ return total_count + p_data.total_count; }, 0); diff --git a/addons/mail/static/tests/client_action_mobile_tests.js b/addons/mail/static/tests/client_action_mobile_tests.js new file mode 100644 index 00000000..e781ae34 --- /dev/null +++ b/addons/mail/static/tests/client_action_mobile_tests.js @@ -0,0 +1,105 @@ +odoo.define('mail.client_action_mobile_tests', function (require) { +"use strict"; + +var session = require('web.session'); +var testUtils = require('web.test_utils'); +var Widget = require('web.Widget'); + +var ChatAction = require('mail.chat_client_action'); +var chat_manager = require('mail.chat_manager'); + +QUnit.module('mail', {}, function () { + +QUnit.module('Discuss client action in mobile', { + beforeEach: function () { + this.data = { + 'mail.message': { + fields: {}, + }, + }; + this.createChatAction = function (params) { + var Parent = Widget.extend({ + do_push_state: function () {}, + }); + var parent = new Parent(); + testUtils.addMockEnvironment(parent, { + data: this.data, + archs: { + 'mail.message,false,search': '', + }, + session: params.session || {}, + intercepts: params.intercepts || {}, + }); + var chatAction = new ChatAction(parent, params); + chatAction.set_cp_bus(new Widget()); + chatAction.appendTo($('#qunit-fixture')); + + return chatAction; + }; + + }, +}); + +QUnit.test('mobile basic rendering', function (assert) { + // This is a very basic first test for the client action. However, with + // the chat_manager, it is hard to override RPCs (for instance, the + // /mail/client_action route is always called when the test suite is + // launched), and we must wait for this RPC to be done before starting to + // test the interface. This should be refactored to facilitate the testing. + assert.expect(9); + var done = assert.async(); + + var rpc = session.rpc; + + var chatAction = this.createChatAction({ + id: 1, + context: {}, + params: {}, + intercepts: { + get_session: function (ev) { + ev.data.callback({}); + }, + }, + session: { + rpc: function (route, args) { + if (args.method === 'message_fetch') { + return $.when([]); + } + return rpc.apply(this, arguments); + }, + }, + }); + + chat_manager.is_ready.then(function () { + // test basic rendering in mobile + assert.strictEqual(chatAction.$('.o_mail_chat_mobile_control_panel').length, 1, + "should have rendered a control panel"); + assert.strictEqual(chatAction.$('.o_mail_chat_content .o_mail_no_content').length, 1, + "should display the no content message"); + assert.strictEqual(chatAction.$('.o_mail_mobile_tabs').length, 1, + "should have rendered the tabs"); + assert.ok(chatAction.$('.o_mail_mobile_tab[data-type=channel_inbox]').hasClass('active'), + "should be in inbox tab"); + assert.strictEqual(chatAction.$('.o_mail_chat_mobile_inbox_buttons:visible').length, 1, + "inbox/starred buttons should be visible"); + assert.ok(chatAction.$('.o_mail_chat_mobile_inbox_buttons .o_channel_inbox_item[data-type=channel_inbox]').hasClass('btn-primary'), + "should be in inbox"); + + // move to DMs tab + chatAction.$('.o_mail_mobile_tab[data-type=dm]').click(); + assert.ok(chatAction.$('.o_mail_mobile_tab[data-type=dm]').hasClass('active'), + "should be in DMs tab"); + assert.strictEqual(chatAction.$('.o_mail_chat_content .o_mail_no_content').length, 0, + "should display the no content message"); + chatAction.$('.o_mail_chat_button_dm').click(); // click to add a channel + assert.strictEqual(chatAction.$('.o_mail_add_channel input:visible').length, 1, + "should display the input to add a channel"); + + chatAction.destroy(); + done(); + }); +}); + +}); + +}); diff --git a/addons/mail/static/tests/client_action_tests.js b/addons/mail/static/tests/client_action_tests.js deleted file mode 100644 index 00c0f2d5..00000000 --- a/addons/mail/static/tests/client_action_tests.js +++ /dev/null @@ -1,88 +0,0 @@ -flectra.define('mail.client_action_test', function (require) { -"use strict"; - -var testUtils = require('web.test_utils'); -var Widget = require('web.Widget'); - -var ChatAction = require("mail.chat_client_action"); - -QUnit.module('mail', {}, function () { - -QUnit.module('Discuss client action', { - beforeEach: function () { - this.data = { - 'mail.message': { - fields: {}, - }, - }; - this.createChatAction = function (params) { - var parent = new Widget(); - testUtils.addMockEnvironment(parent, { - data: this.data, - archs: { - 'mail.message,false,search': '', - }, - config: {device: {isMobile: true}}, - }); - var chatAction = new ChatAction(parent, params); - chatAction.set_cp_bus(new Widget()); - chatAction.appendTo($('#qunit-fixture')); - - return chatAction; - }; - - }, -}); - -QUnit.skip('mobile basic rendering', function (assert) { - // Unfortunately, this test is skipped for now because there is no way to - // execute the whole test suite in mobile (it only works test by test), so - // as the client action include for mobile is rejected when we are not in - // mobile, it isn't possible to test it - // Moreover, RPCs done by the chat_manager (e.g. message_fetch) should be - // properly mocked. - assert.expect(11); - - var parent = new Widget(); - testUtils.addMockEnvironment(parent, { - data: this.data, - archs: { - 'mail.message,false,search': '', - }, - config: {device: {isMobile: true}}, - }); - - var params = { - id: 1, - context: {}, - params: {}, - }; - var chatAction = this.createChatAction(params); - - // test basic rendering in mobile - assert.equal(chatAction.$(".o_mail_chat_mobile_control_panel").length, 1, "Mobile control panel created"); - assert.equal(chatAction.$(".o_mail_mobile_tab").length, 4, "Four mobile tabs created"); - assert.equal(chatAction.$('.o_mail_chat_content').length, 1, "One default chat content pane created"); - assert.equal(chatAction.$(".o_mail_chat_tab_pane").length, 3, "Three mobile tab panes created"); - - // Inbox - assert.equal(chatAction.activeMobileTab, "channel_inbox", "'channel_inbox' is default active tab"); - assert.ok(chatAction.$(".o_channel_inbox_item:nth(0)").hasClass("btn-primary"), "Showing 'Inbox'"); - - // Starred - chatAction.$(".o_channel_inbox_item[data-type='channel_starred']").click(); - assert.ok(chatAction.$(".o_channel_inbox_item:nth(1)").hasClass("btn-primary"), "Clicked on 'Starred'"); - - assert.ok(chatAction.$(".o_mail_chat_content").is(":visible"), "Default main content pane visible"); - - chatAction.$(".o_mail_mobile_tab[data-type='dm']").click(); - assert.equal(chatAction.activeMobileTab, "dm", "After click on 'Conversation', is now active tab"); - - assert.ok(!chatAction.$(".o_mail_chat_content").is(":visible"), "none", "'Main' content pane is invisible"); - assert.ok(chatAction.$(".o_mail_chat_tab_pane:nth(0)").is(":visible"), "'Conversation' pane is visible"); - - chatAction.destroy(); -}); - -}); -}); diff --git a/addons/mail/views/mail_templates.xml b/addons/mail/views/mail_templates.xml index 241beaeb..646b9011 100644 --- a/addons/mail/views/mail_templates.xml +++ b/addons/mail/views/mail_templates.xml @@ -41,13 +41,18 @@ + +