Skip to Content
Odoo Menú
  • Registra entrada
  • Prova-ho gratis
  • Aplicacions
    Finances
    • Comptabilitat
    • Facturació
    • Despeses
    • Full de càlcul (IA)
    • Documents
    • Signatura
    Vendes
    • CRM
    • Vendes
    • Punt de venda per a botigues
    • Punt de venda per a restaurants
    • Subscripcions
    • Lloguer
    Imatges de llocs web
    • Creació de llocs web
    • Comerç electrònic
    • Blog
    • Fòrum
    • Xat en directe
    • Aprenentatge en línia
    Cadena de subministrament
    • Inventari
    • Fabricació
    • PLM
    • Compres
    • Manteniment
    • Qualitat
    Recursos humans
    • Empleats
    • Reclutament
    • Absències
    • Avaluacions
    • Recomanacions
    • Flota
    Màrqueting
    • Màrqueting Social
    • Màrqueting per correu electrònic
    • Màrqueting per SMS
    • Esdeveniments
    • Automatització del màrqueting
    • Enquestes
    Serveis
    • Projectes
    • Fulls d'hores
    • Servei de camp
    • Suport
    • Planificació
    • Cites
    Productivitat
    • Converses
    • Validacions
    • IoT
    • VoIP
    • Coneixements
    • WhatsApp
    Aplicacions de tercers Odoo Studio Plataforma d'Odoo al núvol
  • Sectors
    Comerç al detall
    • Llibreria
    • Botiga de roba
    • Botiga de mobles
    • Botiga d'ultramarins
    • Ferreteria
    • Botiga de joguines
    Food & Hospitality
    • Bar i pub
    • Restaurant
    • Menjar ràpid
    • Guest House
    • Distribuïdor de begudes
    • Hotel
    Immobiliari
    • Agència immobiliària
    • Estudi d'arquitectura
    • Construcció
    • Gestió immobiliària
    • Jardineria
    • Associació de propietaris de béns immobles
    Consultoria
    • Empresa comptable
    • Partner d'Odoo
    • Agència de màrqueting
    • Bufet d'advocats
    • Captació de talent
    • Auditoria i certificació
    Fabricació
    • Textile
    • Metal
    • Mobles
    • Menjar
    • Brewery
    • Regals corporatius
    Salut i fitness
    • Club d'esport
    • Òptica
    • Centre de fitness
    • Especialistes en benestar
    • Farmàcia
    • Perruqueria
    Trades
    • Servei de manteniment
    • Hardware i suport informàtic
    • Sistemes d'energia solar
    • Shoe Maker
    • Serveis de neteja
    • Instal·lacions HVAC
    Altres
    • Nonprofit Organization
    • Agència del medi ambient
    • Lloguer de panells publicitaris
    • Fotografia
    • Lloguer de bicicletes
    • Distribuïdors de programari
    Browse all Industries
  • Comunitat
    Aprèn
    • Tutorials
    • Documentació
    • Certificacions
    • Formació
    • Blog
    • Pòdcast
    Potenciar l'educació
    • Programa educatiu
    • Scale-Up! El joc empresarial
    • Visita Odoo
    Obtindre el programari
    • Descarregar
    • Comparar edicions
    • Novetats de les versions
    Col·laborar
    • GitHub
    • Fòrum
    • Esdeveniments
    • Traduccions
    • Converteix-te en partner
    • Services for Partners
    • Registra la teva empresa comptable
    Obtindre els serveis
    • Troba un partner
    • Troba un comptable
    • Contacta amb un expert
    • Serveis d'implementació
    • Referències del client
    • Suport
    • Actualitzacions
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Programar una demo
  • Preus
  • Ajuda

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Comptabilitat
  • Inventari
  • PoS
  • Projectes
  • MRP
All apps
You need to be registered to interact with the community.
All Posts People Badges
Etiquetes (View all)
odoo accounting v14 pos v15
About this forum
You need to be registered to interact with the community.
All Posts People Badges
Etiquetes (View all)
odoo accounting v14 pos v15
About this forum
Ajuda

How to change the default email template when sending by email a quotation, sales order, invoice ...

Subscriure's

Get notified when there's activity on this post

This question has been flagged
quickstartemail_templateEmailv14
6 Respostes
46345 Vistes
Avatar
Laure Meessen (lme)

How to change the default email template when using "Send by email" on a quotation, sales order, purchase, invoice or other business documents?

For example;

  • you accidentally deleted the original built-in quotation email template.
    Now, when you hit "Send by email" you have to select the new email template by hand each time because the default is empty and you need to reset the default. 

  • your customer has its own custom email templates and he wants to set it as the default when hitting "Send by email"  instead of manually selecting it each time. 


8
Avatar
Descartar
Accounting - Luxe Taste & Style Publishing sarl

that is a very clear explanation.
I wonder why, for a simple action like changing a default template, still in ODOO V15, the user shall go thru such nightmare...

Ray Carnes (ray)

Another approach is (1) Copy the default template. (2) Rename the original so you know it is custom, and make any edits you like. This will be the template that is the default, since it is really still the original, just with changes. (3) Rename the copy with (original) at the end, so you have it in case the one you modify is not suitable for all Use Cases. We recommend taking a copy just so you will always have a working template, but this isn't even necessary for everyone - the default template is a default, and any edits you make will persist during upgrades.

Avatar
Laure Meessen (lme)
Autor Best Answer

Let's consider the case in which we want to change the default email template Sales order: Confirmation Email on a sales order (screenshot below).


Here are the steps to follow;

1. Activate debug mode

2. Go in Settings -> Technical -> Emails -> Templates

Open the new email template that you wish to set as default. 
In its URL (check that you are on debug mode) find the id number of the email template


In this example the id of your email template is 78.

Repeat this and also get the id of the original email template (here let’s say its 54)


3. Then go back in Settings -> Technical -> Sequence & Identifiers -> External Identifiers
Search on the 1) record id of the original default email template that you want to replace (ex 54 here)
+ add a filter on 2) external identifiers with the value "template" 

Open the right record according to what you want to change.


Indicate the new id = 78 (for this example) and save.
Note that the Record (name of the email template) updated into the new default email template that you chose.



4. Make first a copy the original default email template, then delete the original.

Without this step, the default won't change properly. You still want to keep the original on hand just in case you need it later.

5. Check out that it worked 



The default is set as your new report (here Sales Order: Confirmation email (custom copy))


NB: If you have mistakenly deleted the original built-in default email template BEFORE changing its id record in the external identifier into the new email template id,

then the external identifier will be deleted as well.

No panic, you can just recreate the external identifier. For that use a test database, locate the external id linked to the original report and reproduce the external ID in your db + link it with the right record id.

19
Avatar
Descartar
Julian Sautter (jus)

Very useful and well explained! Thank you Laure!

Marco Vogels

Hi Laure. Perfect explanation! However, one question, when I change my 'default' template let's call it, this changes for all companies within my multi-company set-up. Is there a way to do this per company?

Ray Carnes (ray)

Be sure to check the External ID of the template that appears in USE TEMPLATE is actually "sale.mail_template_sale_confirmation" (template named "Sales Order: Confirmation Email") because in some configurations it may be "sale.email_template_edi_sale" instead (template named "Sales Order: Send by email") so THAT is the one you want to change with the ID of the one you made.

Michael Toumbas

Dear Laure! Thank you for the very clear explanation! Is it possible to do this and have default email templates on a per company level on v16?

Avatar
Mickael Lehoux
Best Answer

thank you very useful.
it works on odoo v17

1
Avatar
Descartar
Avatar
Martin Todorov
Best Answer

Hey guys i am on version 18 and i did everything you told me. But when i try to validate my OUT document i receive. This is after i deleted the default template for Email delivery confirmation
RPC_ERROR


Odoo Server Error


Occured on buldent-testing-20328414.dev.odoo.com on model stock.picking and id 16 on 2025-05-21 13:21:46 GMT


Traceback (most recent call last):

  File "/home/odoo/src/odoo/odoo/http.py", line 1976, in _transactioning

    return service_model.retrying(func, env=self.env)

           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/service/model.py", line 156, in retrying

    result = func()

             ^^^^^^

  File "/home/odoo/src/odoo/odoo/http.py", line 1943, in _serve_ir_http

    response = self.dispatcher.dispatch(rule.endpoint, args)

               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/http.py", line 2191, in dispatch

    result = self.request.registry['ir.http']._dispatch(endpoint)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/addons/base/models/ir_http.py", line 333, in _dispatch

    result = endpoint(**request.params)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/http.py", line 740, in route_wrapper

    result = endpoint(self, *args, **params_ok)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/web/controllers/dataset.py", line 42, in call_button

    action = call_kw(request.env[model], method, args, kwargs)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/api.py", line 533, in call_kw

    result = getattr(recs, name)(*args, **kwargs)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/sale_project_stock/models/stock_picking.py", line 11, in button_validate

    res = super().button_validate()

          ^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/stock/models/stock_picking.py", line 1428, in button_validate

    pickings_to_backorder.with_context(cancel_backorder=False)._action_done()

  File "/home/odoo/src/user/shipping_backbone_ns/models/stock_picking.py", line 19, in _action_done

    action_done = super(StockPicking, self)._action_done()

                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/sale_stock/models/stock.py", line 120, in _action_done

    res = super()._action_done()

          ^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/enterprise/quality_control/models/stock_picking.py", line 86, in _action_done

    return super(StockPicking, self)._action_done()

           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/mrp_subcontracting/models/stock_picking.py", line 54, in _action_done

    res = super(StockPicking, self)._action_done()

          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/stock/models/stock_picking.py", line 1263, in _action_done

    self._send_confirmation_email()

  File "/home/odoo/src/odoo/addons/stock_delivery/models/stock_picking.py", line 100, in _send_confirmation_email

    return super(StockPicking, self)._send_confirmation_email()

           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/stock_sms/models/stock_picking.py", line 49, in _send_confirmation_email

    super(Picking, self)._send_confirmation_email()

  File "/home/odoo/src/odoo/addons/stock/models/stock_picking.py", line 1270, in _send_confirmation_email

    stock_pick.with_context(force_send=True).message_post_with_source(

  File "/home/odoo/src/odoo/addons/mass_mailing/models/mail_thread.py", line 42, in message_post_with_source

    return super(MailThread, self.with_context(

           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/mail/models/mail_thread.py", line 2562, in message_post_with_source

    template, view = self._get_source_from_ref(source_ref)

                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/mail/models/mail_thread.py", line 3009, in _get_source_from_ref

    raise ValueError(

ValueError: Mailing or posting with a source should not be called with an empty template


The above server error caused the following client error:

RPC_ERROR: Odoo Server Error

    RPC_ERROR

        at makeErrorFromResponse (https://buldent-testing-20328414.dev.odoo.com/web/assets/380de69/web.assets_web.min.js:3143:163)

        at XMLHttpRequest.<anonymous> (https://buldent-testing-20328414.dev.odoo.com/web/assets/380de69/web.assets_web.min.js:3148:13)

0
Avatar
Descartar
Avatar
Martin Todorov
Best Answer

Hey guys i am on version 18 and i did everything you told me. But when i try to validate my OUT document i receive. This is after i deleted the default template for Email delivery confirmation
RPC_ERROR


Odoo Server Error


Occured on buldent-testing-20328414.dev.odoo.com on model stock.picking and id 16 on 2025-05-21 13:21:46 GMT


Traceback (most recent call last):

  File "/home/odoo/src/odoo/odoo/http.py", line 1976, in _transactioning

    return service_model.retrying(func, env=self.env)

           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/service/model.py", line 156, in retrying

    result = func()

             ^^^^^^

  File "/home/odoo/src/odoo/odoo/http.py", line 1943, in _serve_ir_http

    response = self.dispatcher.dispatch(rule.endpoint, args)

               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/http.py", line 2191, in dispatch

    result = self.request.registry['ir.http']._dispatch(endpoint)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/addons/base/models/ir_http.py", line 333, in _dispatch

    result = endpoint(**request.params)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/http.py", line 740, in route_wrapper

    result = endpoint(self, *args, **params_ok)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/web/controllers/dataset.py", line 42, in call_button

    action = call_kw(request.env[model], method, args, kwargs)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/odoo/api.py", line 533, in call_kw

    result = getattr(recs, name)(*args, **kwargs)

             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/sale_project_stock/models/stock_picking.py", line 11, in button_validate

    res = super().button_validate()

          ^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/stock/models/stock_picking.py", line 1428, in button_validate

    pickings_to_backorder.with_context(cancel_backorder=False)._action_done()

  File "/home/odoo/src/user/shipping_backbone_ns/models/stock_picking.py", line 19, in _action_done

    action_done = super(StockPicking, self)._action_done()

                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/sale_stock/models/stock.py", line 120, in _action_done

    res = super()._action_done()

          ^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/enterprise/quality_control/models/stock_picking.py", line 86, in _action_done

    return super(StockPicking, self)._action_done()

           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/mrp_subcontracting/models/stock_picking.py", line 54, in _action_done

    res = super(StockPicking, self)._action_done()

          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/stock/models/stock_picking.py", line 1263, in _action_done

    self._send_confirmation_email()

  File "/home/odoo/src/odoo/addons/stock_delivery/models/stock_picking.py", line 100, in _send_confirmation_email

    return super(StockPicking, self)._send_confirmation_email()

           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/stock_sms/models/stock_picking.py", line 49, in _send_confirmation_email

    super(Picking, self)._send_confirmation_email()

  File "/home/odoo/src/odoo/addons/stock/models/stock_picking.py", line 1270, in _send_confirmation_email

    stock_pick.with_context(force_send=True).message_post_with_source(

  File "/home/odoo/src/odoo/addons/mass_mailing/models/mail_thread.py", line 42, in message_post_with_source

    return super(MailThread, self.with_context(

           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/mail/models/mail_thread.py", line 2562, in message_post_with_source

    template, view = self._get_source_from_ref(source_ref)

                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "/home/odoo/src/odoo/addons/mail/models/mail_thread.py", line 3009, in _get_source_from_ref

    raise ValueError(

ValueError: Mailing or posting with a source should not be called with an empty template


The above server error caused the following client error:

RPC_ERROR: Odoo Server Error

    RPC_ERROR

        at makeErrorFromResponse (https://buldent-testing-20328414.dev.odoo.com/web/assets/380de69/web.assets_web.min.js:3143:163)

        at XMLHttpRequest.<anonymous> (https://buldent-testing-20328414.dev.odoo.com/web/assets/380de69/web.assets_web.min.js:3148:13)

0
Avatar
Descartar
Avatar
Sunyah Faisal
Best Answer

Since you are using the sales module, check out the module "Club SO lines" by intelliversal integrated solutions. This module groups the products written under a section with marked checkbox and shows them as a single product to the customer in their invoice.

0
Avatar
Descartar
Avatar
Nazeer
Best Answer

Hi guys is there any way to set customer specific email templates in invoice while sending?

Odoo 15

thanks in advance


0
Avatar
Descartar
Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Registrar-se
Related Posts Respostes Vistes Activitat
How to deal with outgoing email servers authentication error message? Solved
quickstart Email v14
Avatar
1
de maig 21
3654
Dynamic Links in Email Marketing Campaign
link email_template v14
Avatar
Avatar
2
de set. 24
4171
How to indicate the email "to" is my custom model field?
email email_template Email
Avatar
0
de jul. 24
1946
How to Change Button Text on Email Templates Solved
emailtemplate email_template v14
Avatar
Avatar
Avatar
Avatar
Avatar
4
d’oct. 22
6459
How to solve the badRequest error when trying to submit Youtube videos to the elearning application ? Solved
quickstart elearning v14
Avatar
Avatar
2
de març 22
4986
Community
  • Tutorials
  • Documentació
  • Fòrum
Codi obert
  • Descarregar
  • GitHub
  • Runbot
  • Traduccions
Serveis
  • Allotjament a Odoo.sh
  • Suport
  • Actualització
  • Desenvolupaments personalitzats
  • Educació
  • Troba un comptable
  • Troba un partner
  • Converteix-te en partner
Sobre nosaltres
  • La nostra empresa
  • Actius de marca
  • Contacta amb nosaltres
  • Llocs de treball
  • Esdeveniments
  • Pòdcast
  • Blog
  • Clients
  • Informació legal • Privacitat
  • Seguretat
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo és un conjunt d'aplicacions empresarials de codi obert que cobreix totes les necessitats de la teva empresa: CRM, comerç electrònic, comptabilitat, inventari, punt de venda, gestió de projectes, etc.

La proposta única de valor d'Odoo és ser molt fàcil d'utilitzar i estar totalment integrat, ambdues alhora.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now