Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
5 Antwoorden
13227 Weergaven

So you go to a customer/supplier, in "More", you can select "Portal Access Management" and invite people to use the portal, once you've done that an email is sent using an email template and the title of this email is "Your OpenERP Account at Your company". (sorry my karma is not sufficient to attach printscreen :()

I want to be able to modify this template but i can't find it.

Can somebody tell me where is this template (i know where to find the other template but this one doesn't appear there).

Thank You!

 

Avatar
Annuleer
Beste antwoord

Hello,

The text is programmed in addons/portal/wizard/portal_wizard.py

Avatar
Annuleer
Beste antwoord

For odoo 10, you can open " addons/portal/wizard/portal_wizard.py" as Els wrote.

In that file, you will find:

@api.multi

    def _send_email(self):

        """ send notification email to a new portal user """

        if not self.env.user.email:

            raise UserError(_('You must have an email address in your User Preferences to send emails.'))


        # determine subject and body in the portal user's language

        template = self.env.ref('portal.mail_template_data_portal_welcome')

        for wizard_line in self:...

The template "portal.mail_template_data_portal_welcome" is named "Portal: new user" in the admin setting of the email in developper mode.


You will have to look at the user freindly emails, it seems that the name of the sender is the current user in the system. So you might have to modify the pyhon code in the file...:

def extract_email(email):

    """ extract the email address from a user-friendly email address """


We just implemented thit here and hope this is the right way to do it.

Ths is a old post, but it is the first one that come on google, so maybe this will save some one else some time.

Avatar
Annuleer
Beste antwoord

The way to edit it is to change the translation from *Settings > Translations > Application Terms > Translated Terms*. Search the translated field as "addons/portal/wizard/portal_wizard.py". You will find the email template in the list. Simply enter a translation for your language (even if you use English).


Dear %(name)s,

You have been given access to %(company)s's %(portal)s.

Your login account data is:

Username: %(login)s

Portal: %(portal_url)s

Database: %(db)s

You can set or change your password via the following url:

%(signup_url)s

%(welcome_message)s

--

Odoo - Open Source Business Applications

http://www.openerp.com

Avatar
Annuleer
Auteur Beste antwoord

Ok thank you.

If someone is interested, indeed, the text is in the code mentionned by Els. So it can't be handled from the interface like some other email template (like payment reminder mails and so on...)

Avatar
Annuleer
Beste antwoord

Edit the following template:

 

https://www.dropbox.com/s/4z215wsbz94pv38/Portal-Email-Template.png

 

Avatar
Annuleer
Gerelateerde posts Antwoorden Weergaven Activiteit
1
feb. 24
2550
0
okt. 23
992
1
jul. 23
3449
3
dec. 23
19162
1
feb. 22
6193