Merge pull request #7 from patrickmcelwee/fix_date_precision_display

Allow getFormat function to accept qualified date precisions
This commit is contained in:
Jim Blake 2014-12-30 17:04:01 -05:00
commit ac37a7f8e9

View file

@ -159,15 +159,15 @@
and the format type to determine how to display it. --> and the format type to determine how to display it. -->
<#local format> <#local format>
<#if formatType == "long"> <#if formatType == "long">
<#if precision == "yearPrecision">yyyy <#if precision?ends_with("yearPrecision")>yyyy
<#elseif precision == "yearMonthPrecision">MMMM yyyy <#elseif precision?ends_with("yearMonthPrecision")>MMMM yyyy
<#elseif precision == "yearMonthDayPrecision">MMMM d, yyyy <#elseif precision?ends_with("yearMonthDayPrecision")>MMMM d, yyyy
<#else>MMMM d, yyyy h:mm a <#else>MMMM d, yyyy h:mm a
</#if> </#if>
<#else> <#-- formatType == "short" --> <#else> <#-- formatType == "short" -->
<#if precision == "yearPrecision">yyyy <#if precision?ends_with("yearPrecision")>yyyy
<#elseif precision == "yearMonthPrecision">M/yyyy <#elseif precision?ends_with("yearMonthPrecision")>M/yyyy
<#elseif precision == "yearMonthDayPrecision">M/d/yyyy <#elseif precision?ends_with("yearMonthDayPrecision")>M/d/yyyy
<#else>M/d/yyyy h:mm a <#else>M/d/yyyy h:mm a
</#if> </#if>
</#if> </#if>