Modify or Disable HTML for "Sales Order - Send by Email" template - odoo

How to change Sales Order - Send by Email template, not the text but style of the sent mail.
For example, change header/footer color or if possible completely disable HTML and send all e-mail messages as plain text.

Looks like this is pulling from the Sale Order Notification Email. I went into Settings > Technical > Email > Templates, searched for that Notification Email template and replaced the Content with the following:
${object.body | safe}

This is defined in the paynow and other Views that apply to the mail model.
Look in table mail.message and see which layout it's using.

Related

How to Personalize window behavior in odoo 8 livechat

How to Personalize window behavior in Odoo 8
Goals for now are:
add fields asking visitors Name, Email and Concern, As you can see at first image "A" the customer name is "Visitor"
change visitors name base on his/her Name input
change the design (background color, font, etc)
I already search on odoo documentation but no tutorials for Live Chat customization.
TIA
The appearance and the behaviour of the live_chat window is defined in the files addons/im_chat/static/src/js/im_chat.js, addons/im_chat/static/src/xml/im_chat.xml and addons/im_livechat/static/src/js/im_livechat.js
Depending on your needs your will have to modify these files. For the needs you have outlined in your question you have to:
1) add fields asking visitors Name, Email and Concern, As you can see
at first image "A" the customer name is "Visitor"
You have to modify the send_welcome_message function on the im_livechat.js in order for you to send a custom initial message and you have to change the im_chat.Conversation_message_bubble template in order to give each "text bubble" a different look (for example to insert a textbox asking for user's info)
2) change visitors name base on his/her Name input
When you collect your data, the user's name is saved in the variable defaultUsername in im_livechat.js, you will have to set it there
3) change the design (background color, font, etc)
All of this can happen from changing the template with the name = im_chat.Conversation_message_bubble from the im_chat.xml file accordingly.

How to remove inbound attachments from message property?

I m using a html form which allows user to enter the details and choose a file to be sent as an attachment with an email via smtp connector in mule. I m using encoding type as- enctype="multipart/form-data" in my html form with method as "post". So all my html fields are coming as inbound attachments and they are being sent as separate 8 attachments in the mail.
Out of the 8 inbound attachments i want to drop 7 attachments and send only one attachment that is the file (highlighted with green) via email. How can i achieve this? Which transformer i should use?
[mule message structure image][1]
![1]: http://i.stack.imgur.com/F9fYu.png
I had similar problem and I found solution. First, you need to copy interesting attachment from inbound to outbound (use copy-attachment tag) and after that you should use transformer email:object-to-mime-transformer with attribute useInboundAttachments set to false. Works for me.
According to me you can drag and drop Attachment transformer after you receive all the attachments and then select Copy Attachment and give value as #[message.inboundAttachments.'file'].
Same to remove you can drag and drop Attachment Transformer and then select RemoveAttchment and then using MEL give attachment name.
#[message.inboundAttachments.'subject']
Hope this helps you !

How to change content of order confirmation email template in prestashop?

I want to change the content of order confirmation email template, only if a particular product has ordered. Is there any solution?
You can find the general template of email order confirmation in mails/language/order_conf.(html/txt).
The product list template in mails/languages/order_conf_product_list.(tpl/txt)
Called in classes/PaymentModule.php, validateOrder() function if you want to add variables.

Apex - passing a variable from one page to another

I have a form on one page which prompts a user to enter their email address. When they click "next" I want Apex to redirect the user to a different page which shows them a report which selects the records from the users table where the email address matches the one that they entered.
E.g.
SELECT *
FROM USERS
WHERE EMAIL_ADDRESS = (the email address that they entered on the previous page);
Can someone please explain the easiest way to do this?
I have only in the last 5 seconds heard about 'Apex' Lol ... But I think I found what you need to do.
You need to define a 'Branch' which will allow you to POST to whichever page you need to.
Here's some documentation on 'Branches': http://docs.oracle.com/cd/B32472_01/doc/appdev.300/b32469/pdf_report.htm#BABICIJG
Also this snipet may help:
It's [The 'branch'] in the middle (page processing section) of the
development page at the bottom. The branch will be executed whenever a
post submission occurs but you can put conditions on the branch.
Which I found at: http://dbaforums.org/oracle/index.php?showtopic=8139
The "Next" button should not redirect but should submit. The value of the page item has to be pushed to the session state for it to be available in the (apex) session. On submit you can then define a branch which will take you to the page with your report. Your report can then reference the page item by using bind variable notation in the region source:
SELECT * FROM USERS WHERE EMAIL_ADDRESS = :Px_EMAIL_ADDRESS

How to implement contacts/email address picker like in Apple's mail application?

when sending a mail on the iPhone/iPad you start typing the name of the recipient and list of proposals shows up. Either pick one from those, or continue typing an email address. Adding a new address turns the first one entered into a blue button like thing.
I would like to use this to allow users to select a couple of email addresses. Does anybody know if it is a standard component?
René
I dont really know if it is a standar UI control but i guess you could figure out something with the help of this video, this one uses the UI Person picker to display the persons name
http://www.alexyork.net/blog/post/Selecting-a-contact-from-the-Address-Book-with-MonoTouch.aspx
and with some modifications you could search on contact list and display a modal view with suggestions of the emails in the list
with this example you can get all the emails in the contact list
ABAddressBook ab = new ABAddressBook();
ABMutableMultiValue<string> emails = new ABMutableStringMultiValue();
foreach (ABPerson person in ab) {
ABMultiValue<string> personemails = person.GetEmails();
foreach (ABMultiValueEntry<string> item in personemails) {
emails.Add(item.Value, item.Label);
}
}
With this code you will get all the emails on the contact list in the variable "emails" now you just need to access the "emails" variable and look for the email the user is typing.
Hope this helps.
Alex