NIHVIVO-304 TestWidget demonstrates the use of different markup macros based on Java logic.

This commit is contained in:
rjy7 2010-11-15 02:22:37 +00:00
parent 37d95fe5fc
commit d53a900e11
2 changed files with 16 additions and 9 deletions

View file

@ -8,17 +8,16 @@
${headScripts.add("/js/testheadscript.js")}
</#macro>
<#macro markup>
<#import "lib-list.ftl" as l>
<#macro loggedIn>
<div class="testWidget">
<h4>This is the test widget using macros.</h4>
<p>I like ${fruit}.</p>
<h4>This is the test widget for logged-in users.</h4>
<p>Login status: ${status}.</p>
</div>
</#macro>
<#macro altMarkup>
<#macro notLoggedIn>
<div class="testWidget">
<h4>This is the alternate version of the test widget.</h4>
<p>I hate ${fruit}.</p>
<h4>This is the test widget for non-logged-in users.</h4>
<p>Login status: ${status}.</p>
</div>
</#macro>