最近の検索
最近の検索はありません
Trigger - Count Attachments
回答済み
投稿日時:2021年7月30日
Hello, I'm using the following code in a trigger.
{% for comment in ticket.comments limit:1 offset:0 %}
{{comment.value_rich}}
{% for attachment in comment.attachments %}
{{attachment.filename}} - {{attachment.url}}
{% endfor %}
{% endfor %}
Can I check in the loop whether the comment has an attachment in order to show additional text? Something like that
{% for comment in ticket.comments limit:1 offset:0 %}
{{comment.value_rich}}
{% IF COMMENT HAS ATTACHMENTS %}
Notice: You have to log in to be able to download the attachment. If you don't have an account yet, click Send Password.
{% for attachment in comment.attachments %}
{{attachment.filename}} - {{attachment.url}}
{% endfor %}
{% ENDIF %}
{% endfor %}
What would be the right condition?
0
2
2件のコメント
ZZ Graeme Carmichael
Linus
Try this:
2
Linus
Hi Graeme, that is the solution. Great!
0