Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: 邮件通知模板能否在客户端配置 || [Feature]: Can the email notification template be configured on the client? #2452

Closed
kok777 opened this issue Apr 23, 2024 · 1 comment
Labels
discussion Question or dicussion enhancement New feature or request

Comments

@kok777
Copy link

kok777 commented Apr 23, 2024

功能概述 | Describe the feature

能否在客户端里配置邮件通知模板
因为我一个服务端同时 供中文页面和英文页面使用。我可以在客户端来设置使用不同的邮件模板吗?
或者服务端里的配置有这个功能吗?

var walineConfig = {
     "mailSubject": "Your comment on Blog received a reply",
     "mailTemplate": `<div style="width: 550px;height: auto;border-radius: 5px;margin:0 auto;box-shadow: 0px 0px 20px #888888;position: relative;padding-bottom: 5px;">
 <div style="background-image: url(https://www.haomwei.com/images/banner.jpg);width:550px;height: 250px;background-size: cover;background-repeat: no-repeat;border-radius: 5px 5px 0px 0px;"></div>
 <div style="width: 200px;height: 40px;background-color: #91a5a5;margin-top: -20px;margin-left: 20px;box-shadow: 3px 3px 3px rgba(0, 0, 0, 0.3);color: rgb(255, 255, 255);text-align: center;line-height: 40px;">Hi {{parent.nick}},</div>
 <div style="background-color:white;line-height:180%;padding:0 15px 12px;width:520px;margin:30px auto;color:#555555;font-family:'Century Gothic','Trebuchet MS','Hiragino Sans GB','Microsoft Yahei',Tahoma,Helvetica,Arial,'SimSun',sans-serif;font-size:12px;margin-bottom: 0px;">  
     <h2 style="border-bottom:1px solid #DDD;font-size:14px;font-weight:normal;padding:13px 0 10px 8px;"><span style="color: #12ADDB;font-weight: bold;">&gt; </span>
       Your comment on <a style="text-decoration:none;color: #12ADDB;" href="" target="_blank"></a>"Blog"</a> received a reply</h2>  
     <div style="padding:0 12px 0 12px;margin-top:18px">         
         <p>{{parent.nick}}, you wrote:</p>  
         <p style="background-color: #f5f5f5;border: 0px solid #DDD;padding: 10px 15px;margin:18px 0">{{parent.comment}}</p>  
         <p><strong>{{self.nick}}</strong>&nbsp;replied:</p>  
         <p style="background-color: #f5f5f5;border: 0px solid #DDD;padding: 10px 15px;margin:18px 0">{{self.comment|safe}}</p>  
     </div>  
 </div>
 <a style="text-decoration:none; color:#FFF;width: 25%;text-align: center;background-color:#91a5a5;height: 40px;line-height: 35px;box-shadow: 3px 3px 3px rgba(0, 0, 0, 0.30);margin: -10px auto;display: block;" href="{{site.postUrl}}" target="_blank">View full reply or visit Blog.</a>
 <div style="color:#8c8c8c;;font-family: 'Century Gothic','Trebuchet MS','Hiragino Sans GB','Microsoft Yahei',Tahoma,Helvetica,Arial,'SimSun',sans-serif;font-size: 10px;width: 100%;text-align: center;margin-top: 30px;">
     <p>This email was sent automatically by the system. Please do not reply directly.</p>
 </div>
 <div style="color:#8c8c8c;;font-family: 'Century Gothic','Trebuchet MS','Hiragino Sans GB','Microsoft Yahei',Tahoma,Helvetica,Arial,'SimSun',sans-serif;font-size: 10px;width: 100%;text-align: center;">
     <p>©2022 Copyright Blog {{-self.commentLink}}</p>
 </div>
</div>`,
     "locale": {
       "placeholder": "Comment with Email address will get notification when replied"
     }
   };

Feature Overview | Describe the feature

Can I configure email notification templates in the client?
Because my server is used for both Chinese pages and English pages. Can I set up a different email template on the client?
Or does the configuration in the server have this function?

varwalineConfig = {
     "mailSubject": "Your comment on Blog received a reply",
     "mailTemplate": `<div style="width: 550px;height: auto;border-radius: 5px;margin:0 auto;box-shadow: 0px 0px 20px #888888;position: relative;padding-bottom: 5px;" >
 <div style="background-image: url(https://www.haomwei.com/images/banner.jpg);width:550px;height: 250px;background-size: cover;background-repeat: no-repeat; border-radius: 5px 5px 0px 0px;"></div>
 <div style="width: 200px;height: 40px;background-color: #91a5a5;margin-top: -20px;margin-left: 20px;box-shadow: 3px 3px 3px rgba(0, 0, 0, 0.3) ;color: rgb(255, 255, 255);text-align: center;line-height: 40px;">Hi {{parent.nick}},</div>
 <div style="background-color:white;line-height:180%;padding:0 15px 12px;width:520px;margin:30px auto;color:#555555;font-family:'Century Gothic','Trebuchet MS ','Hiragino Sans GB','Microsoft Yahei',Tahoma,Helvetica,Arial,'SimSun',sans-serif;font-size:12px;margin-bottom: 0px;">
     <h2 style="border-bottom:1px solid #DDD;font-size:14px;font-weight:normal;padding:13px 0 10px 8px;"><span style="color: #12ADDB;font-weight: bold ;">> </span>
       Your comment on <a style="text-decoration:none;color: #12ADDB;" href="" target="_blank"></a>"Blog"</a> received a reply</h2>
     <div style="padding:0 12px 0 12px;margin-top:18px">
         <p>{{parent.nick}}, you wrote:</p>
         <p style="background-color: #f5f5f5;border: 0px solid #DDD;padding: 10px 15px;margin:18px 0">{{parent.comment}}</p>
         <p><strong>{{self.nick}}</strong> replied:</p>
         <p style="background-color: #f5f5f5;border: 0px solid #DDD;padding: 10px 15px;margin:18px 0">{{self.comment|safe}}</p>
     </div>
 </div>
 <a style="text-decoration:none; color:#FFF;width: 25%;text-align: center;background-color:#91a5a5;height: 40px;line-height: 35px;box-shadow: 3px 3px 3px rgba(0, 0, 0, 0.30);margin: -10px auto;display: block;" href="{{site.postUrl}}" target="_blank">View full reply or visit Blog.</a >
 <div style="color:#8c8c8c;;font-family: 'Century Gothic','Trebuchet MS','Hiragino Sans GB','Microsoft Yahei',Tahoma,Helvetica,Arial,'SimSun',sans-serif; font-size: 10px;width: 100%;text-align: center;margin-top: 30px;">
     <p>This email was sent automatically by the system. Please do not reply directly.</p>
 </div>
 <div style="color:#8c8c8c;;font-family: 'Century Gothic','Trebuchet MS','Hiragino Sans GB','Microsoft Yahei',Tahoma,Helvetica,Arial,'SimSun',sans-serif; font-size: 10px;width: 100%;text-align: center;">
     <p>©2022 Copyright Blog {{-self.commentLink}}</p>
 </div>
</div>`,
     "locale": {
       "placeholder": "Comment with Email address will get notification when replied"
     }
   };
@kok777 kok777 added discussion Question or dicussion enhancement New feature or request labels Apr 23, 2024
@kok777 kok777 changed the title [Feature]: 邮件通知模板能否再客户端配置 [Feature]: 邮件通知模板能否在客户端配置 Apr 23, 2024
@github-actions github-actions bot changed the title [Feature]: 邮件通知模板能否在客户端配置 [Feature]: 邮件通知模板能否在客户端配置 || [Feature]: Can the email notification template be configured on the client? Apr 23, 2024
@github-actions github-actions bot changed the title [Feature]: 邮件通知模板能否在客户端配置 || [Feature]: Can the email notification template be configured on the client? [Feature]: 邮件通知模板能否再客户端配置 || [Feature]: Can the email notification template be configured on the client? Apr 23, 2024
@kok777 kok777 changed the title [Feature]: 邮件通知模板能否再客户端配置 || [Feature]: Can the email notification template be configured on the client? [Feature]: 邮件通知模板能否在客户端配置 || [Feature]: Can the email notification template be configured on the client? Apr 23, 2024
@RylanBot
Copy link

RylanBot commented Jul 8, 2024

请问这个配置成功了吗?最新版本似乎一直失败。


Is this configuration successful? The latest version seems to keep failing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion Question or dicussion enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants