Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
I
Internship-uksw-2019 api-document-management
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Internship UKSW 2019
Internship-uksw-2019 api-document-management
Commits
14593fd1
Commit
14593fd1
authored
Apr 06, 2020
by
Internship UKSW 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Initial commit
parent
c0a77d08
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
11 deletions
+10
-11
API.js
routes/API.js
+10
-11
No files found.
routes/API.js
View file @
14593fd1
...
@@ -14,24 +14,23 @@ const sendEmail = (request, response) => {
...
@@ -14,24 +14,23 @@ const sendEmail = (request, response) => {
<p>
${
message
}
</p>
<p>
${
message
}
</p>
`
`
let
transporter
=
nodemailer
.
createTransport
({
let
transporter
=
nodemailer
.
createTransport
({
host
:
'smtp.gmail.com'
,
//
host: 'smtp.gmail.com',
// service: 'Gmail',
// service: 'Gmail',
//
host: 'mta.visionet.co.id',
host
:
'mta.visionet.co.id'
,
port
:
587
,
port
:
587
,
secure
:
false
,
secure
:
false
,
auth
:
{
auth
:
{
user
:
'
vdocmanagement@gmail.com
'
,
user
:
'
prastowo.nugroho.int@visionet.co.id
'
,
pass
:
'
docmgmt123
'
pass
:
'
02Maret2020
'
},
},
// auth: {
// user: 'prastowo.nugroho.int@visionet.co.id',
// pass: '02Maret2020'
// },
tls
:
{
tls
:
{
rejectUnauthorized
:
false
rejectUnauthorized
:
false
},
},
// debug: true
// debug: true
// auth: {
// user: 'vdocmanagement@gmail.com',
// pass: 'docmgmt123'
// },
})
})
let
maillist
=
[
let
maillist
=
[
...
@@ -40,10 +39,10 @@ const sendEmail = (request, response) => {
...
@@ -40,10 +39,10 @@ const sendEmail = (request, response) => {
maillist
.
forEach
(
function
(
to
,
i
,
array
)
{
maillist
.
forEach
(
function
(
to
,
i
,
array
)
{
let
mailOptions
=
{
let
mailOptions
=
{
from
:
'
vdocmanagement@gmail.com'
,
//'prastowo.nugroho.int@visionet.co.id
'
from
:
'
prastowo.nugroho.int@visionet.co.id'
,
//'vdocmanagement@gmail.com
'
cc
:
emailcc
,
cc
:
emailcc
,
subject
:
subject
,
subject
:
subject
,
text
:
message
,
text
:
"Hello World"
,
html
:
htmlEmail
html
:
htmlEmail
}
}
mailOptions
.
to
=
to
;
mailOptions
.
to
=
to
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment