Zum Inhalt springen
Odoo Menü
  • Anmelden
  • Jetzt gratis testen
  • Apps
    Finanzen
    • Buchhaltung
    • Rechnungsstellung
    • Spesenabrechnung
    • Tabellenkalkulation (BI)
    • Dokumente
    • E-Signatur
    Vertrieb
    • CRM
    • Vertrieb
    • Kassensystem – Shop
    • Kassensystem – Restaurant
    • Abonnements
    • Vermietung
    Websites
    • Website-Builder
    • E-Commerce
    • Blog
    • Forum
    • Livechat
    • E-Learning
    Lieferkette
    • Lager
    • Fertigung
    • PLM
    • Einkauf
    • Wartung
    • Qualität
    Personalwesen
    • Mitarbeiter
    • Personalbeschaffung
    • Abwesenheiten
    • Mitarbeiterbeurteilung
    • Personalempfehlungen
    • Fuhrpark
    Marketing-
    • Social Marketing
    • E-Mail-Marketing
    • SMS-Marketing
    • Veranstaltungen
    • Marketing-Automatisierung
    • Umfragen
    Dienstleistungen
    • Projekte
    • Zeiterfassung
    • Außendienst
    • Kundendienst
    • Planung
    • Termine
    Produktivität
    • Dialog
    • Genehmigungen
    • IoT
    • VoIP
    • Wissensdatenbank
    • WhatsApp
    Apps von Drittanbietern Odoo Studio Odoo Cloud-Plattform
  • Branchen
    Einzelhandel
    • Buchladen
    • Kleidergeschäft
    • Möbelhaus
    • Lebensmittelgeschäft
    • Baumarkt
    • Spielwarengeschäft
    Essen & Gastgewerbe
    • Bar und Kneipe
    • Restaurant
    • Fast Food
    • Gästehaus
    • Getränkehändler
    • Hotel
    Immobilien
    • Immobilienagentur
    • Architekturbüro
    • Baugewerbe
    • Immobilienverwaltung
    • Gartenarbeit
    • Eigentümervereinigung
    Beratung
    • Buchhaltungsfirma
    • Odoo-Partner
    • Marketingagentur
    • Anwaltskanzlei
    • Talentakquise
    • Prüfung & Zertifizierung
    Fertigung
    • Textil
    • Metall
    • Möbel
    • Speisen
    • Brauerei
    • Firmengeschenke
    Gesundheit & Fitness
    • Sportklub
    • Brillengeschäft
    • Fitnessstudio
    • Therapeut
    • Apotheke
    • Friseursalon
    Handel
    • Handyman
    • IT-Hardware & -Support
    • Solarenergiesysteme
    • Schuster
    • Reinigungsdienstleistungen
    • HLK-Dienstleistungen
    Sonstiges
    • Gemeinnützige Organisation
    • Umweltschutzagentur
    • Plakatwandvermietung
    • Fotostudio
    • Fahrrad-Leasing
    • Software-Händler
    Alle Branchen ansehen
  • Community
    Lernen
    • Tutorials
    • Dokumentation
    • Zertifizierungen
    • Schulung
    • Blog
    • Podcast
    Bildung fördern
    • Bildungsprogramm
    • Scale-Up! Planspiel
    • Odoo besuchen
    Software anfragen
    • Herunterladen
    • Editionen vergleichen
    • Releases
    Zusammenarbeiten
    • Github
    • Forum
    • Veranstaltungen
    • Übersetzungen
    • Partner werden
    • Dienstleistungen für Partner
    • Buchhaltungsfirma registrieren
    Services anfragen
    • Partner finden
    • Buchhalter finden
    • Einen Experten treffen
    • Implementierungsservices
    • Kundenreferenzen
    • Support
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Eine Demo erhalten
  • Preiskalkulation
  • Hilfe

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

  • CRM
  • e-Commerce
  • Buchhaltung
  • Lager
  • PoS
  • Projekte
  • MRP
All apps
Sie müssen registriert sein, um mit der Community zu interagieren.
Alle Beiträge Personen Abzeichen
Stichwörter (Alle anzeigen)
odoo accounting v14 pos v15
Über dieses Forum
Sie müssen registriert sein, um mit der Community zu interagieren.
Alle Beiträge Personen Abzeichen
Stichwörter (Alle anzeigen)
odoo accounting v14 pos v15
Über dieses Forum
Hilfe

Automated Action Not Triggering When Quotation Is Sent (state = “sent”) — CRM Stage Not Updating (Odoo 19)

Abonnieren

Erhalten Sie eine Benachrichtigung, wenn es eine Aktivität zu diesem Beitrag gibt

Diese Frage wurde gekennzeichnet
actionconfigurationworkflow
2 Antworten
313 Ansichten
Avatar
Yani Aimene
Hello everyone,

I'm trying to create a simple automated action in Odoo 19 to update the CRM stage of an opportunity when its related Sales Order (quotation) is sent by email.

Expected behavior:

When I click “Send by Email” on a quotation, the Sales Order state becomes “sent”, and the linked opportunity should automatically move to the stage “Devis envoyé” (Quotation Sent).
But the automated action never triggers, and the CRM stage never updates.

What I have done

Automated Action settings

Model: Sales Order (sale.order)

Trigger: On creation & update

Before update domain: All records

Apply on: state = sent (in the UI = “Soumission envoyée”)

On Update Fields: tried with and without selecting state

Action: Execute Python Code

Action is active

Python code used (no errors):

stage = env['crm.stage'].search([('name', '=', 'Devis envoyé')], limit=1)
for order in records:
    if not order.opportunity_id:
        continue
    if order.state == 'sent' and stage:
        order.opportunity_id.write({'stage_id': stage.id})

What is happening

Sending the quotation DOES change the Sales Order state to “sent”, confirmed in the UI.

The quotation IS linked to an opportunity (opportunity_id is not empty).

The automated action never triggers.

No error appears in the logs or UI.

Even a debug automated action that only does: order.message_post(body="DEBUG")
…does not post anything in the chatter.

This tells me the automated action is simply not running at all, even with no domains or filters.

What I have confirmed

Action is active.

Model is correct (sale.order).

The “sent” state corresponds to the value "Soumission envoyée” in the UI.

I tried versions with and without domains.

I tried “On update”, “On creation & update”, and “On update of field: state”.
Nothing triggers the action.

My questions

Is there a known issue in Odoo 19 where automated actions do NOT trigger on Sales Orders when the state changes from draft to sent?

Should "Send by Email" trigger an automated action on Sales Orders?

Does the email wizard update the record in a way that bypasses automated actions?

Is there another method recommended to react to the quotation being sent?

Is there a limitation in Odoo 19 Online / Enterprise that prevents some automated actions from executing?

Any help would be greatly appreciated


I’m simply trying to update the CRM stage when a quotation is sent — something that several Odoo forum posts suggest should work — but the automated action never fires, even with zero domain filters and a basic message_post() debug.

0
Avatar
Verwerfen
Avatar
Ray Carnes (ray)
Beste Antwort

I just tested this and it worked:

stage = env['crm.stage'].search([('name', '=', 'Proposition')], limit=1)
for order in records:
if not order.opportunity_id:
continue
if order.state == 'sent' and stage:
order.opportunity_id.write({'stage_id': stage.id})
0
Avatar
Verwerfen
Avatar
Kunjan Patel
Beste Antwort
Hello Yani Aimene,
I hope you are doing well

Why it doesn't work:
The "Send by Email" button changes state inside message_post() with tracking_disable=True, which bypasses automated actions.

Solution:
Create a custom module and override message_post:
from odoo import models
  class SaleOrder(models.Model):
      _inherit = 'sale.order'

      def message_post(self, **kwargs):
          result = super().message_post(**kwargs)
          if self.env.context.get('mark_so_as_sent'):
              stage = self.env['crm.stage'].search([('name', '=', 'Devis envoyé')], limit=1)
              if stage:
                  for order in self.filtered(lambda o: o.state == 'sent' and o.opportunity_id):
                      order.opportunity_id.stage_id = stage
          return result

I hope this information helps you

Thanks & Regards,
Kunjan Patel
0
Avatar
Verwerfen
Diskutieren Sie gerne? Treten Sie bei, statt nur zu lesen!

Erstellen Sie heute ein Konto, um exklusive Funktionen zu nutzen und mit unserer tollen Community zu interagieren!

Registrieren
Verknüpfte Beiträge Antworten Ansichten Aktivität
Issue with Callback Not Updating Properly When Order is Open in Odoo 17
action configuration workflow
Avatar
0
Nov. 24
1680
How can I edit the Website?
action configuration
Avatar
Avatar
Avatar
2
Okt. 25
820
Marketing Automation- campaign running but not emails sent.
configuration workflow
Avatar
Avatar
1
Okt. 25
700
Link quotation emails to the original customer email thread
action workflow
Avatar
0
Aug. 25
944
suppression site web
action configuration
Avatar
Avatar
2
Juli 25
1563
Community
  • Tutorials
  • Dokumentation
  • Forum
Open Source
  • Herunterladen
  • Github
  • Runbot
  • Übersetzungen
Dienstleistungen
  • Odoo.sh-Hosting
  • Support
  • Upgrade
  • Individuelle Entwicklungen
  • Bildung
  • Buchhalter finden
  • Partner finden
  • Partner werden
Über uns
  • Unsere Firma
  • Markenwerte
  • Kontakt
  • Karriere
  • Veranstaltungen
  • Podcast
  • Blog
  • Kunden
  • Rechtliches • Datenschutz
  • Sicherheit
الْعَرَبيّة 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 ist eine Suite von Open-Source-Betriebsanwendungen, die alle Bedürfnisse Ihres Unternehmens abdecken: CRM, E-Commerce, Buchhaltung, Lager, Kassensystem, Projektmanagement etc.

Das einzigartige Wertversprechen von Odoo ist, dass es gleichzeitig sehr einfach zu bedienen und voll integriert ist.

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