Originally posted by Unknown
Use the lava below to only show attributes in the workflow form that have values.
*Be sure to update the form Id in the lava so that it pulls the correct form attributes.
<html>
<head>
<style>
html {
}
body {
margin: 24 125px;
font-family: Arial, 'OpenSans';
color: #000;
}
</style>
</head>
<body>
<br/>
<h1>{{ Workflow.Name }}</h1>
{% workflowactionform where:'Id == 107' %}
{% for form in workflowactionformItems %}
{{form.Header}}
<br/>
<br/>
<table>
<tr>
<td>
<strong>Date</strong>
</td>
</tr>
<tr>
<td>
{{ 'Now' | Date:'MMMM d, yyyy' }}
<br/><br/>
</td>
</tr>
{% for attribute in form.FormAttributes %}
{% assign attributeValue = Workflow | Attribute:attribute.Attribute.Key %}
{% assign string = attributeValue | Size %}
{% if attribute.IsVisible == true %}
{% if string > 0 %}
<tr>
<td>
{% assign preHtml = attribute.PreHtml | StripNewlines | StripHtml | Replace:' ', '' %}
{% if attribute.HideLabel == true and preHtml != empty %}
<strong>{{attribute.PreHtml | StripNewlines | StripHtml }}</strong>
{% else %}
<strong>{{ attribute.Attribute.Name }}</strong>
{% endif %}
</td>
</tr>
<tr>
<td>
{{ Workflow | Attribute:attribute.Attribute.Key }}
<br/><br/>
</td>
</tr>
{% endif %}
{% endif %}
{% endfor %}
{{form.Footer}}
{% endfor %}
{% endworkflowactionform %}
</table>
</body>
</html>