Email sending tool (#3837)

### What problem does this PR solve?

_Briefly describe what this PR aims to solve. Include background context
that will help reviewers understand the purpose of the PR._
Added the function of sending emails through SMTP
Instructions for use-
Corresponding parameters need to be configured
Need to output upstream in a fixed format

![image](https://github.com/user-attachments/assets/93bc1af7-6d4f-4406-bd1d-bc042535dd82)


### Type of change


- [√] New Feature (non-breaking change which adds functionality)

---------

Co-authored-by: Kevin Hu <kevinhu.sh@gmail.com>
This commit is contained in:
小黑马
2024-12-04 11:21:17 +08:00
committed by GitHub
parent 285bc58364
commit efae7afd62
12 changed files with 426 additions and 0 deletions

View File

@ -1050,6 +1050,31 @@ When you want to search the given knowledge base at first place, set a higher pa
template: 'Template',
templateDescription:
'This component is used for typesetting the outputs of various components.',
emailComponent: 'Email',
emailDescription: 'Send email to specified address',
smtpServer: 'SMTP Server',
smtpPort: 'SMTP Port',
senderEmail: 'Sender Email',
authCode: 'Authorization Code',
senderName: 'Sender Name',
toEmail: 'Recipient Email',
ccEmail: 'CC Email',
emailSubject: 'Subject',
emailContent: 'Content',
smtpServerRequired: 'Please input SMTP server address',
senderEmailRequired: 'Please input sender email',
authCodeRequired: 'Please input authorization code',
toEmailRequired: 'Please input recipient email',
emailContentRequired: 'Please input email content',
emailSentSuccess: 'Email sent successfully',
emailSentFailed: 'Failed to send email',
dynamicParameters: 'Dynamic Parameters',
jsonFormatTip:
'Upstream component should provide JSON string in following format:',
toEmailTip: 'to_email: Recipient email (Required)',
ccEmailTip: 'cc_email: CC email (Optional)',
subjectTip: 'subject: Email subject (Optional)',
contentTip: 'content: Email content (Optional)',
},
footer: {
profile: 'All rights reserved @ React',

View File

@ -1029,6 +1029,30 @@ export default {
testRun: '试运行',
template: '模板转换',
templateDescription: '该组件用于排版各种组件的输出。',
emailComponent: '邮件',
emailDescription: '发送邮件到指定邮箱',
smtpServer: 'SMTP服务器',
smtpPort: 'SMTP端口',
senderEmail: '发件人邮箱',
authCode: '授权码',
senderName: '发件人名称',
toEmail: '收件人邮箱',
ccEmail: '抄送邮箱',
emailSubject: '邮件主题',
emailContent: '邮件内容',
smtpServerRequired: '请输入SMTP服务器地址',
senderEmailRequired: '请输入发件人邮箱',
authCodeRequired: '请输入授权码',
toEmailRequired: '请输入收件人邮箱',
emailContentRequired: '请输入邮件内容',
emailSentSuccess: '邮件发送成功',
emailSentFailed: '邮件发送失败',
dynamicParameters: '动态参数说明',
jsonFormatTip: '上游组件需要传入以下格式的JSON字符串:',
toEmailTip: 'to_email: 收件人邮箱(必填)',
ccEmailTip: 'cc_email: 抄送邮箱(可选)',
subjectTip: 'subject: 邮件主题(可选)',
contentTip: 'content: 邮件内容(可选)',
},
footer: {
profile: 'All rights reserved @ React',