Join front-end
This commit is contained in:
parent
366ac8768b
commit
8281609df0
@ -54,14 +54,12 @@ public class TbMsgToEmailNode implements TbNode {
|
|||||||
private static final String IMAGES = "images";
|
private static final String IMAGES = "images";
|
||||||
|
|
||||||
private TbMsgToEmailNodeConfiguration config;
|
private TbMsgToEmailNodeConfiguration config;
|
||||||
private boolean isDynamicHtmlTemplate = false;
|
private boolean isDynamicHtmlTemplate;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void init(TbContext ctx, TbNodeConfiguration configuration) throws TbNodeException {
|
public void init(TbContext ctx, TbNodeConfiguration configuration) throws TbNodeException {
|
||||||
this.config = TbNodeUtils.convert(configuration, TbMsgToEmailNodeConfiguration.class);
|
this.config = TbNodeUtils.convert(configuration, TbMsgToEmailNodeConfiguration.class);
|
||||||
if(this.config.getMailBodyType().equals("dynamic")) {
|
this.isDynamicHtmlTemplate = this.config.getMailBodyType().equals("dynamic");
|
||||||
this.isDynamicHtmlTemplate = true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@ -37,8 +37,7 @@ public class TbMsgToEmailNodeConfiguration implements NodeConfiguration {
|
|||||||
configuration.toTemplate = "${userEmail}";
|
configuration.toTemplate = "${userEmail}";
|
||||||
configuration.subjectTemplate = "Device ${deviceType} temperature high";
|
configuration.subjectTemplate = "Device ${deviceType} temperature high";
|
||||||
configuration.bodyTemplate = "Device ${deviceName} has high temperature ${temp}";
|
configuration.bodyTemplate = "Device ${deviceName} has high temperature ${temp}";
|
||||||
configuration.isHtmlTemplate = "${isHtml}";
|
configuration.mailBodyType = "false";
|
||||||
configuration.mailBodyType = "dynamic";
|
|
||||||
return configuration;
|
return configuration;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user