Evgeny Shvarov · Apr 5, 2016

How to avoid writing duplicate code in dtl InterSystems Ensemble


There is a question for Ensemble on Stackoverflow:

I have the below dtl. In the foreach loop, I am just copying the same code in another part under anif condition. How can I avoid this redundancy? Can I reuse using sub transformation?

Here is the dtl class file :

Original question.

0 477
Discussion (2)0
Log in or sign up to continue

Maybe I'm missing something, but it seems like you could have an OR condition to eliminate the code duplication 

if condition='ExcludeInactiveAllergiesAlerts="No" OR flag'="No"