Skip to Content
Odoo Menu
  • Zaloguj się
  • Wypróbuj za darmo
  • Aplikacje
    Finanse
    • Księgowość
    • Fakturowanie
    • Wydatki
    • Arkusz kalkulacyjny (BI)
    • Dokumenty
    • Podpisy
    Sprzedaż
    • CRM
    • Sprzedaż
    • PoS Sklep
    • PoS Restauracja
    • Subskrypcje
    • Wypożyczalnia
    Strony Internetowe
    • Kreator Stron Internetowych
    • eCommerce
    • Blog
    • Forum
    • Czat na Żywo
    • eLearning
    Łańcuch dostaw
    • Magazyn
    • Produkcja
    • PLM
    • Zakupy
    • Konserwacja
    • Jakość
    Zasoby Ludzkie
    • Pracownicy
    • Rekrutacja
    • Urlopy
    • Ocena pracy
    • Polecenia Pracownicze
    • Flota
    Marketing
    • Marketing Społecznościowy
    • E-mail Marketing
    • SMS Marketing
    • Wydarzenia
    • Automatyzacja Marketingu
    • Ankiety
    Usługi
    • Projekt
    • Ewidencja czasu pracy
    • Usługi Terenowe
    • Helpdesk
    • Planowanie
    • Spotkania
    Produktywność
    • Dyskusje
    • Zatwierdzenia
    • IoT
    • VoIP
    • Baza wiedzy
    • WhatsApp
    Aplikacje trzecich stron Studio Odoo Odoo Cloud Platform
  • Branże
    Sprzedaż detaliczna
    • Księgarnia
    • Sklep odzieżowy
    • Sklep meblowy
    • Sklep spożywczy
    • Sklep z narzędziami
    • Sklep z zabawkami
    Żywienie i hotelarstwo
    • Bar i Pub
    • Restauracja
    • Fast Food
    • Pensjonat
    • Dystrybutor napojów
    • Hotel
    Agencja nieruchomości
    • Agencja nieruchomości
    • Biuro architektoniczne
    • Budowa
    • Zarządzanie nieruchomościami
    • Ogrodnictwo
    • Stowarzyszenie właścicieli nieruchomości
    Doradztwo
    • Biuro księgowe
    • Partner Odoo
    • Agencja marketingowa
    • Kancelaria prawna
    • Agencja rekrutacyjna
    • Audyt i certyfikacja
    Produkcja
    • Tekstylia
    • Metal
    • Meble
    • Jedzenie
    • Browar
    • Prezenty firmowe
    Zdrowie & Fitness
    • Klub sportowy
    • Salon optyczny
    • Centrum fitness
    • Praktycy Wellness
    • Apteka
    • Salon fryzjerski
    Transakcje
    • Złota rączka
    • Wsparcie Sprzętu IT
    • Systemy energii słonecznej
    • Szewc
    • Firma sprzątająca
    • Usługi HVAC
    Inne
    • Organizacja non-profit
    • Agencja Środowiskowa
    • Wynajem billboardów
    • Fotografia
    • Leasing rowerów
    • Sprzedawca oprogramowania
    Przeglądaj wszystkie branże
  • Community
    Ucz się
    • Samouczki
    • Dokumentacja
    • Certyfikacje
    • Szkolenie
    • Blog
    • Podcast
    Pomóż w nauce innym
    • Program Edukacyjny
    • Scale Up! Gra biznesowa
    • Odwiedź Odoo
    Skorzystaj z oprogramowania
    • Pobierz
    • Porównaj edycje
    • Wydania
    Współpracuj
    • Github
    • Forum
    • Wydarzenia
    • Tłumaczenia
    • Zostań partnerem
    • Usługi dla partnerów
    • Zarejestruj swoją firmę rachunkową
    Skorzystaj z usług
    • Znajdź partnera
    • Znajdź księgowego
    • Spotkaj się z doradcą
    • Usługi wdrożenia
    • Opinie klientów
    • Wsparcie
    • Aktualizacje
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Zaplanuj demo
  • Cennik
  • Pomoc

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

  • CRM
  • e-Commerce
  • Księgowość
  • Zapasy
  • PoS
  • Projekt
  • MRP
All apps
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
Wszystkie posty Osoby Odznaki
Tagi (Zobacz wszystko)
odoo accounting v14 pos v15
O tym forum
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
Wszystkie posty Osoby Odznaki
Tagi (Zobacz wszystko)
odoo accounting v14 pos v15
O tym forum
Pomoc

how to send automatic mail when project created ?

Zaprenumeruj

Otrzymaj powiadomienie o aktywności w tym poście

To pytanie dostało ostrzeżenie
projectmailmodulesmoduleautomatic_email
22 Odpowiedzi
15174 Widoki
Awatar
Ahmed elbarbary

hi ,

i have a module to send automatic mail when customer has been created what about if i need to send mail when project created, what i should change in these files ?

__init__.py

import res_partner

------------------------------------------------------------------------------------------------------------------------------------------------------------

__openerp__.py

# -*- coding: utf-8 -*-
{
    "name" : "Automatical email to customer",
    "version" : "1.0",
    "author" : "Author name",
    "description": """
        Sends automatic when customer created
    """,
    "website" : "Author website name",
    "category" : "",
    'depends': ['base'],
    "data" : ['email_template_customer_auto.xml',],
    'js': [], 
    'css': [

    ],
    'qweb': [
    ],
    "active": False,
    "installable": True,

}

------------------------------------------------------------------------------------------------------------------------------------------------------------

res_partner.py

from osv import osv, fields

class res_partner(osv.osv):
    _inherit = 'res.partner'
    _columns = {}

    def create(self, cr, uid, vals, context=None):
        res = super(res_partner, self).create(cr, uid, vals, context=context)
        if vals:
            template = self.pool.get('ir.model.data').get_object(cr, uid, 'customer_auto_email', 'email_template_customer_auto')
            mail_id = self.pool.get('email.template').send_mail(cr, uid, template.id, res , force_send=True)

        return res

res_partner()

--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

 

email_template_customer_auto.xml

<?xml version="1.0" encoding="utf-8"?>
<openerp>
  <data noupdate="1">

        <!--Email template-->
        <record id="email_template_customer_auto" model="email.template">
            <field name="name">Send auto email</field>
            <field name="email_from">${object.company_id and object.company_id.email or ''}</field>
            <field name="subject">New Customer created ${object.name}</field>
            <field name="email_to">${object.company_id and object.company_id.email or ''}</field>
            <field name="model_id" ref="base.model_res_partner"/>
            <field name="auto_delete" eval="True"/>
            <field name="lang">${object.lang}</field>
            <field name="body_html"><![CDATA[
             
          the email content

Thank you!           
            ]]></field>
        </record>
  
  </data>
</openerp>

0
Awatar
Odrzuć
ABU K

Whent I try to install your code It raise an error ----AssertionError: The model email.template does not exist !

Ahmed elbarbary
Autor

so install module "Email template " and try again

ABU K

When I create a customer and save ,then I got this error######### ValueError: No such external ID currently defined in the system: customer_auto_email.email_template_customer_auto

OdooBot
is it a pop up message or it is  taceback ?


On 18 September 2014 09:15, Libu Koshy <libukoshym@mail.odoo.com> wrote:

When I create a customer and save ,then I got this error######### ValueError: No such external ID currently defined in the system: customer_auto_email.email_template_customer_auto

--
Libu Koshy
Sent by Odoo Inc. using Odoo about Forum Post how to send automatic mail when project created ?

Ahmed elbarbary
Autor

uninstall this module and delete it from your modules and i will send u the complete module to your email now

OdooBot
this is send auto email when customer be created 

On 18 September 2014 11:22, Libu Koshy <libukoshym@mail.odoo.com> wrote:

Server Traceback (most recent call last) with a pop up wizard

--
Libu Koshy
Sent by Odoo Inc. using Odoo about Forum Post how to send automatic mail when project created ?

OdooBot
this is send auto email when project be created 

On 18 September 2014 11:40, AHMED ELBARBARY <aelbarbary152@gmail.com> wrote:
this is send auto email when customer be created 

On 18 September 2014 11:22, Libu Koshy <libukoshym@mail.odoo.com> wrote:

Server Traceback (most recent call last) with a pop up wizard

--
Libu Koshy
Sent by Odoo Inc. using Odoo about Forum Post how to send automatic mail when project created ?


OdooBot
this is send auto email when invoice be created 

On 18 September 2014 11:41, AHMED ELBARBARY <aelbarbary152@gmail.com> wrote:
this is send auto email when project be created 

On 18 September 2014 11:40, AHMED ELBARBARY <aelbarbary152@gmail.com> wrote:
this is send auto email when customer be created 

On 18 September 2014 11:22, Libu Koshy <libukoshym@mail.odoo.com> wrote:

Server Traceback (most recent call last) with a pop up wizard

--
Libu Koshy
Sent by Odoo Inc. using Odoo about Forum Post how to send automatic mail when project created ?



OdooBot
only invoice module or all modules 

OdooBot
really i am sorry i cannot help u i didn't know what is this error, it works fine at my system without any adding configuration just paste the module folders to addons then update module list and install those modules and every thing going well , u can check your outgoing mail server if u have the same problem u can do automated action and email templates from openerp wizard setting  instead of those modules


On 18 September 2014 12:51, Libu Koshy <libukoshym@mail.odoo.com> wrote:

Now I tried only this module(invoice module) ,and when I create a invoice then error occurs

--
Libu Koshy
Sent by Odoo Inc. using Odoo about Forum Post how to send automatic mail when project created ?

Awatar
Janeesh
Najlepsza odpowiedź

Hi,

Try this code.

module name : project_auto_email

__init__.py

import project

------------------------------------------------------------------------------------------------------------------------------------------------------------

__openerp.py

# -*- coding: utf-8 -*-
{
    "name" : "Automatical email on Project Creation",
    "version" : "1.0",
    "author" : "Author name",
    "description": """
        Sends automatic when projects created
    """,
    "website" : "Author website name",
    "category" : "",
    'depends': ['base' ,'project'],
    "data" : ['email_template_project_auto.xml',],
    'js': [], 
    'css': [

    ],
    'qweb': [
    ],
    "active": False,
    "installable": True,

}

------------------------------------------------------------------------------------------------------------------------------------------------------------

project.py

from osv import osv, fields

class project_project(osv.osv):
    _inherit = 'project.project'
    _columns = {}

    def create(self, cr, uid, vals, context=None):
        res = super(project_project, self).create(cr, uid, vals, context=context)
        if vals:
            template = self.pool.get('ir.model.data').get_object(cr, uid, 'project_auto_email', 'email_template_project_auto')
            mail_id = self.pool.get('email.template').send_mail(cr, uid, template.id, res , force_send=True)

        return res

project_project()

--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

 

email_template_project_auto.xml

<?xml version="1.0" encoding="utf-8"?>
<openerp>
  <data noupdate="1">

        <!--Email template-->
        <record id="email_template_project_auto" model="email.template">
            <field name="name">Send auto email</field>
            <field name="email_from">${object.company_id and object.company_id.email or ''}</field>
            <field name="subject">New Customer created ${object.name}</field>
            <field name="email_to">${object.company_id and object.company_id.email or ''}</field>
            <field name="model_id" ref="project.model_project_project"/>
            <field name="auto_delete" eval="True"/>
            <field name="lang">${object.lang}</field>
            <field name="body_html"><![CDATA[
             
          the email content

Thank you!           
            ]]></field>
        </record>
  
  </data>
</openerp>

7
Awatar
Odrzuć
Awatar
Roy Mathew
Najlepsza odpowiedź

Change the following line into xml file

Your line is : <field name="model_id" ref="base.model_project_project"/>

Change it by : <field name="model_id" ref="project.model_project_project"/>

2
Awatar
Odrzuć
Awatar
Med Said BARA
Najlepsza odpowiedź

Why not using OpenChatter ?  By subscribing as many followers as you want.

https://www.dropbox.com/s/urgc666clpnn4jt/OpenChatter Project.png

 

 

If you want to do that by coding, hereafter a good  and simple example on how to send an automatic mail when a Task is created.

https://www.odoo.com/apps/7.0/send_mail_task/

You can try to adapt this example to your need (e.g send mail when Project is created or when a Customer is created)

Some helpful links:

https://doc.odoo.com/trunk/mail/mail_openchatter_howto/

https://github.com/vnc-biz/openerp-addons-bundle/blob/master-7.0/mail/doc/mail_openchatter_howto.rst

https://anybox.fr/blog/openerp-disable-autofollow-in-openchatter

https://doc.odoo.com/trunk/mail/mail_thread/

https://www.odoo.com/forum/help-1/question/what-is-the-track-proprerty-of-mail-thread-model-used-for-1704

1
Awatar
Odrzuć
Awatar
Emipro Technologies Pvt. Ltd.
Najlepsza odpowiedź

Hi Ahmed,

Just change the following line into xml file with my line.

Your line is : <field name="model_id" ref="base.model_project_project"/>

Change it by : <field name="model_id" ref="project.model_project_project"/>

1
Awatar
Odrzuć
Awatar
Ahmed elbarbary
Autor Najlepsza odpowiedź
0
Awatar
Odrzuć
Podoba Ci się ta dyskusja? Dołącz do niej!

Stwórz konto dzisiaj, aby cieszyć się ekskluzywnymi funkcjami i wchodzić w interakcje z naszą wspaniałą społecznością!

Zarejestruj się
Powiązane posty Odpowiedzi Widoki Czynność
CHANGE THE STAGE
project modules
Awatar
0
sie 24
3260
help with the module all-in-one whatsapp integration-sale purchase account and crm odoo 10
modules module
Awatar
0
maj 20
3670
How to define the thousands separator BY CUSTOM MODULE? Rozwiązane
modules module
Awatar
Awatar
Awatar
3
gru 19
6236
OpenERP 7.0 will not update modules list? Rozwiązane
modules module
Awatar
Awatar
Awatar
Awatar
Awatar
6
gru 23
20887
How to import a field from an module to other?
modules module
Awatar
Awatar
1
mar 15
5165
Społeczność
  • Samouczki
  • Dokumentacja
  • Forum
Open Source
  • Pobierz
  • Github
  • Runbot
  • Tłumaczenia
Usługi
  • Hosting Odoo.sh
  • Wsparcie
  • Aktualizacja
  • Indywidualne rozwiązania
  • Edukacja
  • Znajdź księgowego
  • Znajdź partnera
  • Zostań partnerem
O nas
  • Nasza firma
  • Zasoby marki
  • Skontaktuj się z nami
  • Oferty pracy
  • Wydarzenia
  • Podcast
  • Blog
  • Klienci
  • Informacje prawne • Prywatność
  • Bezpieczeństwo Odoo
الْعَرَبيّة 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 to pakiet aplikacji biznesowych typu open source, które zaspokoją wszystkie potrzeby Twojej firmy: CRM, eCommerce, księgowość, inwentaryzacja, punkt sprzedaży, zarządzanie projektami itp.

Unikalną wartością Odoo jest to, że jest jednocześnie bardzo łatwe w użyciu i w pełni zintegrowane.

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