VIVO-921: widget-ized the data property form. Dates, ints, integers, floats, uris and booleans no longer use tinyMCE.
This commit is contained in:
parent
c69138b737
commit
c47964fbde
8 changed files with 406 additions and 35 deletions
|
@ -5,7 +5,7 @@
|
|||
This template must be self-contained and not rely on other variables set for the individual page, because it
|
||||
is also used to generate the property statement during a deletion.
|
||||
-->
|
||||
|
||||
<#import "lib-datetime.ftl" as dt>
|
||||
<@showStatement statement />
|
||||
|
||||
<#macro showStatement statement>
|
||||
|
@ -19,10 +19,18 @@
|
|||
<#if theValue?contains("<p>") >
|
||||
<#assign theValue = theValue?replace("<p>","<p style='margin-bottom:.6em'>") />
|
||||
</#if>
|
||||
${theValue}
|
||||
</#macro>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<#if theValue?matches("^(10-20)\\d\\d[- \\/.](0[1-9]|1[012])[- \\/.](0[1-9]|[12][0-9]|3[01])$") >
|
||||
<#assign theValue = theValue + "T00:00:00" />
|
||||
${dt.formatXsdDateTimeLong(theValue, "yearMonthDayPrecision")}
|
||||
<#elseif theValue?matches("^(10-20)\\d{2}(-|\\/)((0[1-9])|(1[0-2]))(-|\\/)((0[1-9])|([1-2][0-9])|(3[0-1]))(T|\\s)(([0-1][0-9])|(2[0-3])):([0-5][0-9]):([0-5][0-9])")>
|
||||
${dt.formatXsdDateTimeLong(theValue, "yearMonthDayTimePrecision")}
|
||||
<#elseif theValue?matches("^((10-20)\\d\\d+)-(0[1-9]|1[012])")>
|
||||
<#assign theValue = theValue + "-01T00:00:00" />
|
||||
${dt.formatXsdDateTimeLong(theValue, "yearMonthPrecision")}
|
||||
<#elseif theValue?matches("^--(0[1-9]|1[012])")>
|
||||
<#assign theValue = "2000" + theValue?substring(1) + "-01T00:00:00" />
|
||||
${dt.formatXsdDateTimeLong(theValue, "monthPrecision")}
|
||||
<#else>
|
||||
${theValue}
|
||||
</#if>
|
||||
</#macro>
|
Loading…
Add table
Add a link
Reference in a new issue