Some fixes.
This commit is contained in:
parent
41cd01c2b9
commit
d54f941caa
5 changed files with 25 additions and 7 deletions
|
@ -410,6 +410,7 @@ export default class CUD extends Component {
|
||||||
const response = await axios.post(getUrl('rest/forms-preview'), data);
|
const response = await axios.post(getUrl('rest/forms-preview'), data);
|
||||||
|
|
||||||
this.setState({
|
this.setState({
|
||||||
|
previewKey: formKey,
|
||||||
previewContents: response.data.content,
|
previewContents: response.data.content,
|
||||||
previewLabel: this.templateSettings[formKey].label
|
previewLabel: this.templateSettings[formKey].label
|
||||||
});
|
});
|
||||||
|
@ -504,10 +505,15 @@ export default class CUD extends Component {
|
||||||
{this.state.previewContents &&
|
{this.state.previewContents &&
|
||||||
<div className={this.state.previewFullscreen ? formsStyles.editorFullscreen : formsStyles.editor}>
|
<div className={this.state.previewFullscreen ? formsStyles.editorFullscreen : formsStyles.editor}>
|
||||||
<div className={formsStyles.navbar}>
|
<div className={formsStyles.navbar}>
|
||||||
|
<div className={formsStyles.navbarLeft}>
|
||||||
{this.state.fullscreen && <img className={formsStyles.logo} src={getTrustedUrl('static/mailtrain-notext.png')}/>}
|
{this.state.fullscreen && <img className={formsStyles.logo} src={getTrustedUrl('static/mailtrain-notext.png')}/>}
|
||||||
<div className={formsStyles.title}>{t('formPreview') + ' ' + this.state.previewLabel}</div>
|
<div className={formsStyles.title}>{t('formPreview') + ' ' + this.state.previewLabel}</div>
|
||||||
<a className={formsStyles.btn} onClick={() => this.setState({previewContents: null, previewFullscreen: false})}><Icon icon="window-close"/></a>
|
</div>
|
||||||
<a className={formsStyles.btn} onClick={() => this.setState({previewFullscreen: !this.state.previewFullscreen})}><Icon icon="window-maximize"/></a>
|
<div className={formsStyles.navbarRight}>
|
||||||
|
<a className={formsStyles.btn} onClick={() => this.preview(this.state.previewKey)} title={t('Refresh')}><Icon icon="sync-alt"/></a>
|
||||||
|
<a className={formsStyles.btn} onClick={() => this.setState({previewFullscreen: !this.state.previewFullscreen})} title={t('Maximize editor')}><Icon icon="window-maximize"/></a>
|
||||||
|
<a className={formsStyles.btn} onClick={() => this.setState({previewContents: null, previewFullscreen: false})} title={t('Close preview')}><Icon icon="window-close"/></a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<iframe className={formsStyles.host} src={"data:text/html;charset=utf-8," + encodeURIComponent(this.state.previewContents)}></iframe>
|
<iframe className={formsStyles.host} src={"data:text/html;charset=utf-8," + encodeURIComponent(this.state.previewContents)}></iframe>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -92,7 +92,7 @@ export default class Status extends Component {
|
||||||
const columns = [
|
const columns = [
|
||||||
{ data: 1, title: t('row') },
|
{ data: 1, title: t('row') },
|
||||||
{ data: 2, title: t('email') },
|
{ data: 2, title: t('email') },
|
||||||
{ data: 3, title: t('reason') }
|
{ data: 3, title: t('reason'), render: data => t(...JSON.parse(data)) }
|
||||||
];
|
];
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
|
@ -150,7 +150,7 @@ export default class Status extends Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
actions.push({
|
actions.push({
|
||||||
label: <Icon icon="eye-open" title={t('runStatus')}/>,
|
label: <Icon icon="eye" title={t('runStatus')}/>,
|
||||||
link: `/lists/${this.props.list.id}/imports/${this.props.entity.id}/status/${data[0]}`
|
link: `/lists/${this.props.list.id}/imports/${this.props.entity.id}/status/${data[0]}`
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -929,7 +929,7 @@
|
||||||
"invalidEmailAddressEmailMxRecordNotFound": "Invalid email address \"{{email}}\": MX record not found for domain",
|
"invalidEmailAddressEmailMxRecordNotFound": "Invalid email address \"{{email}}\": MX record not found for domain",
|
||||||
"invalidEmailAddressEmailAddressDomainNot": "Invalid email address \"{{email}}\": Address domain not found",
|
"invalidEmailAddressEmailAddressDomainNot": "Invalid email address \"{{email}}\": Address domain not found",
|
||||||
"invalidEmailAddressEmailAddressDomain": "Invalid email address \"{{email}}\": Address domain name is required",
|
"invalidEmailAddressEmailAddressDomain": "Invalid email address \"{{email}}\": Address domain name is required",
|
||||||
"invalidEmailGeneric": "invalidEmailGeneric",
|
"invalidEmailGeneric": "Invalid email address \"{{email}}\"",
|
||||||
"mailerPasswordChangeRequest": "Mailer password change request",
|
"mailerPasswordChangeRequest": "Mailer password change request",
|
||||||
"mailtrain": "Mailtrain",
|
"mailtrain": "Mailtrain",
|
||||||
"emailAddressChanged": "Email address changed",
|
"emailAddressChanged": "Email address changed",
|
||||||
|
|
|
@ -394,6 +394,18 @@ class CampaignSender {
|
||||||
try {
|
try {
|
||||||
const info = await mailer.sendMassMail(mail);
|
const info = await mailer.sendMassMail(mail);
|
||||||
status = SubscriptionStatus.SUBSCRIBED;
|
status = SubscriptionStatus.SUBSCRIBED;
|
||||||
|
|
||||||
|
/*
|
||||||
|
ZoneMTA
|
||||||
|
info.response: 250 Message queued as 1691ad7f7ae00080fd
|
||||||
|
info.messageId: <e65c9386-e899-7d01-b21e-ec03c3a9d9b4@sathyasai.org>
|
||||||
|
|
||||||
|
Postal Mail Server
|
||||||
|
info.response: 250 OK
|
||||||
|
info.messageId: <xxxxxxxxx@xxx.xx> (postal messageId)
|
||||||
|
*/
|
||||||
|
|
||||||
|
console.log(`response: ${info.response} messageId: ${info.messageId}`);
|
||||||
response = info.response || info.messageId;
|
response = info.response || info.messageId;
|
||||||
|
|
||||||
await knex('campaigns').where('id', campaign.id).increment('delivered');
|
await knex('campaigns').where('id', campaign.id).increment('delivered');
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue