diff --git a/price_update_notifications/data/email_templates.xml b/price_update_notifications/data/email_templates.xml
index d9cc0b6..dc8bf8b 100644
--- a/price_update_notifications/data/email_templates.xml
+++ b/price_update_notifications/data/email_templates.xml
@@ -9,9 +9,7 @@
Notification -
Effective {{ object.effective_date.strftime("%Y-%m-%d") }}
-
Dear ,
\n" +"We have recently updated the pricing for the following\n" +" products you have purchased or requested pricing for in the past\n" +" year. Please take note that these prices will be effective as of\n" +" .\n" +"
\n" +"| Product | \n" +"Unit | \n" +"Unit Price | \n" +"Currency | \n" +"
|---|---|---|---|
| \n" +" \n" +" | \n" +"\n" +" \n" +" | \n" +"\n" +" \n" +" | \n" +"\n" +" \n" +" | \n" +"
Best regards,
\n" +"The team.
\n" +"Bonjour ,
\n" +"Nous avons récemment mis à jour les prix pour les produits " +" suivants, que vous avez demandé en soumission ou" +" commandés dans la dernière année. Veuillez noter " +" que ces prix entreront en vigueur le " +" " +"
\n" +"| Produit | \n" +"Unité de mesure | \n" +"Prix unitaire | \n" +"Devise | \n" +"
|---|---|---|---|
| \n" +" \n" +" | \n" +"\n" +" \n" +" | \n" +"\n" +" \n" +" | \n" +"\n" +" \n" +" | \n" +"
Cordialement,
\n" +"L'équipe
\n" +"The following partners do not have emails configured:
" +msgstr "Les partenaires suivants n'ont pas d'adresse courriel définie.
" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_needaction +msgid "Action Needed" +msgstr "Action requise" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__active +msgid "Active" +msgstr "Actif" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__product_template_ids +#: model_terms:ir.ui.view,arch_db:price_update_notifications.price_notice_mailing_view_form +#: model_terms:ir.ui.view,arch_db:price_update_notifications.send_price_update_notice_view_form +msgid "Applicable Products" +msgstr "Produits applicables" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_attachment_count +msgid "Attachment Count" +msgstr "Nombre de pièces jointes" + +#. module: price_update_notifications +#: model_terms:ir.ui.view,arch_db:price_update_notifications.send_price_update_notice_view_form +msgid "Cancel" +msgstr "Annuler" + +#. module: price_update_notifications +#: model_terms:ir.ui.view,arch_db:price_update_notifications.send_price_update_notice_view_form +msgid "Create Notifications" +msgstr "Créer les envois" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__create_uid +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__create_uid +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__create_uid +msgid "Created by" +msgstr "Créé par" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__create_date +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__create_date +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__create_date +msgid "Created on" +msgstr "Créé le" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__currency_id +msgid "Currency" +msgstr "Devise" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__effective_date +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__pricing_date +msgid "Effective Pricing Date" +msgstr "Date d'entrée en vigueur des prix" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__email +msgid "Email" +msgstr "Courriel" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__line_ids +msgid "Line" +msgstr "Ligne" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__mailing_id +msgid "Mailing" +msgstr "Envoi" + +#. module: price_update_notifications +#: model_terms:ir.actions.act_window,help:price_update_notifications.action_view_price_notice_mailings +msgid "No mailings yet. Create one!" +msgstr "Il n'existe aucun envoi. Créez-en un!" + +#. module: price_update_notifications +#. odoo-python +#: code:addons/price_update_notifications/wizard/send_price_update_notice.py:0 +#, python-format +msgid "" +"No valid partners were selected. Partners must have an email address set." +msgstr "" +"Aucun partenaire valide n'a été sélectionné. Les partenaires doivent avoir un courriel défini." + +#. module: price_update_notifications +#: model_terms:ir.ui.view,arch_db:price_update_notifications.price_notice_mailing_view_form +msgid "Notification Lines" +msgstr "Lignes de notification" + + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__partner_id +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__partner_ids +msgid "Partner" +msgstr "Partenaire" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__price +msgid "Price" +msgstr "Prix" + +#. module: price_update_notifications +#: model:ir.model,name:price_update_notifications.model_price_notice_mailing +msgid "Price Notice Mailing" +msgstr "Mise à jour des prix" + +#. module: price_update_notifications +#: model:ir.model,name:price_update_notifications.model_price_notice_mailing_line +msgid "Price Notice Mailing Line" +msgstr "Ligne de mise à jour des prix" + +#. module: price_update_notifications +#: model:ir.actions.act_window,name:price_update_notifications.action_view_price_notice_mailings +msgid "Price Notice Mailings" +msgstr "Mise à jour des prix" + +#. module: price_update_notifications +#: model:ir.model,name:price_update_notifications.model_wizard_price_update_notice +msgid "Price Update Notice Wizard" +msgstr "" + +#. module: price_update_notifications +#: model:ir.ui.menu,name:price_update_notifications.sale_menu_price_notice_mailing +msgid "Price Update Notices" +msgstr "Mises à jour des prix" + +#. module: price_update_notifications +#: model:ir.actions.server,name:price_update_notifications.send_pricing_update_mails_ir_actions_server +msgid "" +"Price Update Notifications: Send\n" +" Notifications" +msgstr "" +"Mise à jour des prix: envoyer\n" +" notifications" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__product_id +msgid "Product" +msgstr "Produit" + +#. module: price_update_notifications +#: model:mail.template,name:price_update_notifications.mail_template_price_update +msgid "Product Price Update" +msgstr "Mise à jour du prix des produits" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__product_template_ids +msgid "Product Template" +msgstr "Gabarit de produit" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__send_date +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__send_date +msgid "Send Date" +msgstr "Date d'envoi" + +#. module: price_update_notifications +#: model:ir.actions.act_window,name:price_update_notifications.action_send_price_update_notice_wizard +msgid "Send Price Update Notice" +msgstr "Envoyer mises à jour des prix" + +#. module: price_update_notifications +#: model:ir.actions.server,name:price_update_notifications.partner_action_send_price_update_notice +msgid "Send Price Update Notice(s)" +msgstr "Envoyer mise(s) à jour des prix" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__sent +msgid "Sent" +msgstr "Envoyé" + +#. module: price_update_notifications +#: model:mail.template,description:price_update_notifications.mail_template_price_update +msgid "" +"Sent using the send price update letter action on partners." +" " +msgstr "" +"Envoyé en utilisant l'action d'envoi des mises à jour des prix sur les partenaires." + +#. module: price_update_notifications +#: model:ir.model.fields,help:price_update_notifications.field_wizard_price_update_notice__pricing_date +msgid "The date at which the prices are valid." +msgstr "La date à laquelle les prix sont valides." + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__warning_msg +msgid "Warning Msg" +msgstr "Avertissement" \ No newline at end of file diff --git a/price_update_notifications/i18n/price_update_notifications.pot b/price_update_notifications/i18n/price_update_notifications.pot new file mode 100644 index 0000000..e4496ad --- /dev/null +++ b/price_update_notifications/i18n/price_update_notifications.pot @@ -0,0 +1,374 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * price_update_notifications +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 17.0+e\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2024-12-05 18:30+0000\n" +"PO-Revision-Date: 2024-12-05 18:30+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: \n" + +#. module: price_update_notifications +#: model:mail.template,subject:price_update_notifications.mail_template_price_update +msgid "" +"\n" +" {{ object.partner_id.company_id.name }} Price Update\n" +" Notification -\n" +" Effective {{ object.effective_date.strftime(\"%Y-%m-%d\") }}\n" +" " +msgstr "" + +#. module: price_update_notifications +#: model:mail.template,body_html:price_update_notifications.mail_template_price_update +msgid "" +"Dear ,
\n" +"We have recently updated the pricing for the following\n" +" products you have purchased or requested pricing for in the past\n" +" year. Please take note that these prices will be effective as of\n" +" .\n" +"
\n" +"| Product | \n" +"Unit | \n" +"Unit Price | \n" +"Currency | \n" +"
|---|---|---|---|
| \n" +" \n" +" | \n" +"\n" +" \n" +" | \n" +"\n" +" \n" +" | \n" +"\n" +" \n" +" | \n" +"
Best regards,
\n" +"The team.
\n" +"The following partners do not have emails configured:
" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_needaction +msgid "Action Needed" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__active +msgid "Active" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__product_template_ids +#: model_terms:ir.ui.view,arch_db:price_update_notifications.price_notice_mailing_view_form +#: model_terms:ir.ui.view,arch_db:price_update_notifications.send_price_update_notice_view_form +msgid "Applicable Products" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_attachment_count +msgid "Attachment Count" +msgstr "" + +#. module: price_update_notifications +#: model_terms:ir.ui.view,arch_db:price_update_notifications.send_price_update_notice_view_form +msgid "Cancel" +msgstr "" + +#. module: price_update_notifications +#: model_terms:ir.ui.view,arch_db:price_update_notifications.send_price_update_notice_view_form +msgid "Create Notifications" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__create_uid +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__create_uid +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__create_uid +msgid "Created by" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__create_date +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__create_date +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__create_date +msgid "Created on" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__currency_id +msgid "Currency" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__display_name +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__display_name +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__display_name +msgid "Display Name" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__effective_date +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__pricing_date +msgid "Effective Pricing Date" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__email +msgid "Email" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_follower_ids +msgid "Followers" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_partner_ids +msgid "Followers (Partners)" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__has_message +msgid "Has Message" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__id +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__id +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__id +msgid "ID" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,help:price_update_notifications.field_price_notice_mailing__message_needaction +msgid "If checked, new messages require your attention." +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,help:price_update_notifications.field_price_notice_mailing__message_has_error +#: model:ir.model.fields,help:price_update_notifications.field_price_notice_mailing__message_has_sms_error +msgid "If checked, some messages have a delivery error." +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_is_follower +msgid "Is Follower" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__write_uid +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__write_uid +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__write_date +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__write_date +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__write_date +msgid "Last Updated on" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__line_ids +msgid "Line" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__mailing_id +msgid "Mailing" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_has_error +msgid "Message Delivery error" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_ids +msgid "Messages" +msgstr "" + +#. module: price_update_notifications +#: model_terms:ir.actions.act_window,help:price_update_notifications.action_view_price_notice_mailings +msgid "No mailings yet. Create one!" +msgstr "" + +#. module: price_update_notifications +#. odoo-python +#: code:addons/price_update_notifications/wizard/send_price_update_notice.py:0 +#, python-format +msgid "" +"No valid partners were selected. Partners must have an email address set." +msgstr "" + +#. module: price_update_notifications +#: model_terms:ir.ui.view,arch_db:price_update_notifications.price_notice_mailing_view_form +msgid "Notification Lines" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_needaction_counter +msgid "Number of Actions" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_has_error_counter +msgid "Number of errors" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,help:price_update_notifications.field_price_notice_mailing__message_needaction_counter +msgid "Number of messages requiring action" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,help:price_update_notifications.field_price_notice_mailing__message_has_error_counter +msgid "Number of messages with delivery error" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__partner_id +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__partner_ids +msgid "Partner" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__price +msgid "Price" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model,name:price_update_notifications.model_price_notice_mailing +msgid "Price Notice Mailing" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model,name:price_update_notifications.model_price_notice_mailing_line +msgid "Price Notice Mailing Line" +msgstr "" + +#. module: price_update_notifications +#: model:ir.actions.act_window,name:price_update_notifications.action_view_price_notice_mailings +msgid "Price Notice Mailings" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model,name:price_update_notifications.model_wizard_price_update_notice +msgid "Price Update Notice Wizard" +msgstr "" + +#. module: price_update_notifications +#: model:ir.ui.menu,name:price_update_notifications.sale_menu_price_notice_mailing +msgid "Price Update Notices" +msgstr "" + +#. module: price_update_notifications +#: model:ir.actions.server,name:price_update_notifications.send_pricing_update_mails_ir_actions_server +msgid "" +"Price Update Notifications: Send\n" +" Notifications" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing_line__product_id +msgid "Product" +msgstr "" + +#. module: price_update_notifications +#: model:mail.template,name:price_update_notifications.mail_template_price_update +msgid "Product Price Update" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__product_template_ids +msgid "Product Template" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__rating_ids +msgid "Ratings" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__message_has_sms_error +msgid "SMS Delivery error" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__send_date +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__send_date +msgid "Send Date" +msgstr "" + +#. module: price_update_notifications +#: model:ir.actions.act_window,name:price_update_notifications.action_send_price_update_notice_wizard +msgid "Send Price Update Notice" +msgstr "" + +#. module: price_update_notifications +#: model:ir.actions.server,name:price_update_notifications.partner_action_send_price_update_notice +msgid "Send Price Update Notice(s)" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__sent +msgid "Sent" +msgstr "" + +#. module: price_update_notifications +#: model:mail.template,description:price_update_notifications.mail_template_price_update +msgid "" +"Sent using the send price update\n" +" letter action on partners.\n" +" " +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,help:price_update_notifications.field_wizard_price_update_notice__pricing_date +msgid "The date at which the prices are valid." +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_wizard_price_update_notice__warning_msg +msgid "Warning Msg" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,field_description:price_update_notifications.field_price_notice_mailing__website_message_ids +msgid "Website Messages" +msgstr "" + +#. module: price_update_notifications +#: model:ir.model.fields,help:price_update_notifications.field_price_notice_mailing__website_message_ids +msgid "Website communication history" +msgstr "" diff --git a/price_update_notifications/wizard/send_price_update_notice.py b/price_update_notifications/wizard/send_price_update_notice.py index 4d2f110..df6a1cf 100644 --- a/price_update_notifications/wizard/send_price_update_notice.py +++ b/price_update_notifications/wizard/send_price_update_notice.py @@ -37,7 +37,11 @@ class SendPriceUpdateNotice(models.TransientModel): warning_msg = None valid_partners = partners.filtered("email") if not valid_partners: - raise UserError(_("No valid partners were selected. Partners must have an email address set.")) + raise UserError( + _( + "No valid partners were selected. Partners must have an email address set." + ) + ) vals.update( partner_ids=partners.filtered("email").ids, warning_msg=warning_msg,