Add a message template

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
Il y a 13 ans
Since you cannot add a new message template via the administration area (there is no 'new' button).
Do you need to add a new template into the Database itself or is there another way to add a new message template?

Did somebody already done this. If so, can you give some information what steps you have taken.
Il y a 13 ans
We're using the following SQL script to add new message templates:
IF NOT EXISTS (
    SELECT 1
    FROM [dbo].[Nop_MessageTemplate]
    WHERE [Name] = N'YourTemplateName')
BEGIN
  INSERT [dbo].[Nop_MessageTemplate] ([Name])
  VALUES (N'YourTemplateName')

  DECLARE @MessageTemplateID INT
  SELECT @MessageTemplateID =  mt.MessageTemplateID FROM Nop_MessageTemplate mt
              WHERE mt.Name = N'YourTemplateName'

  IF (@MessageTemplateID > 0)
  BEGIN
    INSERT [dbo].[Nop_MessageTemplateLocalized] ([MessageTemplateID], [LanguageID], [BCCEmailAddresses], [Subject], [Body])
    VALUES (@MessageTemplateID, 7, N'', N'your email title',  N'your email body')
  END
END
GO

P.S. Replace 7 with your language identifier
Il y a 13 ans
Thank you Andrei :)
Il y a 12 ans
where do i add this?

After the customer email to us, I want to set up:

- an automated confirmation to the customer’s email should read as follows  
Dear Valued Customer,

Thank you for your inquiry.  At Yourstore.com, we strive to provide you with the best customer service by assisting each individual in great detail.  As such, please note that we will respond to your inquiry between 24-48 hours.  
Best regards,

The Yourstore.com Team

Add a “SHOP NOW”  box and link it to our site


do you think would that be helpful? sorry, i'm new to here. looking forward for a positive response.
Il y a 12 ans
Hi,

Setup an auto responder on your mail server if you host your own site, server etc or use third party auto responder software to the email address's you want.

If you use outlook: http://www.outlookbackup.com/tips/outlook-autoresponder.html

or

http://email-responder.net/
Il y a 12 ans
okay thanks. :)
Il y a 11 ans
I would also like to add custom templates to our installation of nop, but the database has changed since the above solution was provided. Could you all show us how this is done in more current revisions?
Il y a 7 ans
Hello:  

This post is very old and that's why I am using it anyway as the topic is the same. But not sure if in new versions of Nop we're able to add new message templates.  I had a look at the system templates but the Message templates is not there. Am using Nop 3.70 and am hoping to avoid having to resolve this in coding. I see no "Add" button in the admin area, which could be very useful.

From the existing templates list, some are missing that might be critical to store owners, at least they are to me and I would like to know how to resolve this:

- Refunded order: a message template for Vendor notification
- Order cancellation: Vendor notification message template (that's critical to ensure that the vendor knows the order did not go through, and for accounting purposes)
- Vendor account: Vendor notification to confirm activation of account

Thanks!
Il y a 7 ans
As in 3.80 Version , There two options:

1. Click edit on any existing message template click copy template then edit the template as you need


2. Run SQL Script to create new message template



IF NOT EXISTS (
   SELECT 1
   FROM [dbo].[MessageTemplate]
   WHERE [Name]=N'Nop.Plugin.MyPlugin.OrderPlaced.CustomerNotification')
BEGIN
INSERT [dbo].[MessageTemplate] ([Name], [BccEmailAddresses], [Subject], [Body], [IsActive], [DelayBeforeSend], [DelayPeriodId], [AttachedDownloadId], [EmailAccountId],[LimitedToStores])
VALUES (N'Nop.Plugin.MyPlugin.OrderPlaced.CustomerNotification', NULL, N'Order receipt from %Store.Name%.', N'<p> Hi! This message from% Store.Name% </ p> ', 'true', null,0, 0,1,0)
END
GO


Note: Nop.Plugin.MyPlugin.OrderPlaced.CustomerNotification is just message template name you can add any name you like

References:

1. https://www.nopcommerce.com/boards/t/41842/create-new-message-template.aspx

2. https://www.nopcommerce.com/boards/t/22627/how-to-add-a-new-message-template.aspx
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.