0.1.4 • Published 4 years ago
ngx-maillerby-az v0.1.4
NgxMaillerbyAz Ninh 7214997
This library was generated with Angular CLI version 7.2.0.
Requirement
import NgxMaillerbyAz
to your component. You can copy import { NgxMaillerbyAzService } from 'ngx-maillerby-az';
.
import { NgxMaillerbyAzService } from 'ngx-maillerby-az';...
constructor( public maillerService: NgxMaillerbyAzService )
Send - Default Mail ( với mail được setup trên service )
const params = { name: '', // Tên người nhận mail
user: '', // Để trống nếu gửi bằng tài khoản setup trên service
password: '', // Để trống nếu gửi bằng tài khoản setup trên service
email: '', // mail nhận, nếu list mail nhận : vd: 'bar@example.com, baz@example.com, ...'
cc: '', // mail cc, nếu list mail cc : vd: 'bar@example.com, baz@example.com, ...'
bcc: '', // mail bcc, nếu list mail bcc : vd: 'bar@example.com, baz@example.com, ...'
email_from: '', // Tên mail gửi
subject: '', // Tiêu đề mail
text: '', // Text mail
template: '', // Template mail
};
this.maillerService.sendMail(params).subscribe( response => {
console.log('Sendmail ok', response);
});
Send - Dynamic Mail ( với mail được setup trên service )
const params = { name: '', // Tên người nhận mail
user: '', // Nếu để trống sẽ tự động chuyển về Send - Default Mail
password: '', // Nếu để trống sẽ tự động chuyển về Send - Default Mail
email: '', // mail nhận, nếu list mail nhận : vd: 'bar@example.com, baz@example.com, ...'
cc: '', // mail cc, nếu list mail cc : vd: 'bar@example.com, baz@example.com, ...'
bcc: '', // mail bcc, nếu list mail bcc : vd: 'bar@example.com, baz@example.com, ...'
email_from: '', // Tên mail gửi
subject: '', // Tiêu đề mail
text: '', // Text mail
template: '', // Template mail
};
this.maillerService.sendMailDynamic(params).subscribe( response => {
console.log('Sendmail ok', response);
});