🐛 fix template id type #405

This commit is contained in:
ricardo 2020-03-25 14:52:12 -04:00
parent 6785b1ed46
commit 87eda6619f
2 changed files with 2 additions and 2 deletions

View file

@ -299,7 +299,7 @@ export const emailFields = [
},
},
{
displayName: 'Template',
displayName: 'Template ID',
name: 'templateId',
type: 'string',
required: true,

View file

@ -185,7 +185,7 @@ export class Mailjet implements INodeType {
//https://dev.mailjet.com/email/guides/send-api-v31/#use-a-template
if (operation === 'sendTemplate') {
const fromEmail = this.getNodeParameter('fromEmail', i) as string;
const templateId = this.getNodeParameter('templateId', i) as string;
const templateId = parseInt(this.getNodeParameter('templateId', i) as string, 10);
const subject = this.getNodeParameter('subject', i) as string;
const variables = (this.getNodeParameter('variablesUi', i) as IDataObject).variablesValues as IDataObject[];
const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject;