<#if field.control.params.submitTime?? && field.control.params.submitTime == "false"><#assign submitTime=false><#else><#assign submitTime=true></#if>
<#if field.control.params.showTime?? && field.control.params.showTime == "true"><#assign showTime=true><#else><#assign showTime=false></#if>
<#if showTime><#assign viewFormat>${msg("form.control.date-picker.view.time.format.year")}</#assign><#else><#assign viewFormat>${msg("form.control.date-picker.view.date.format.year")}</#assign></#if>
<#assign disabled=field.disabled>
<#if field.control.params.forceEditable?? && field.control.params.forceEditable == "true">
<#assign disabled=false>
</#if>
<#assign multiValued=false>
<#if field.value != "" && field.value?index_of(",") != -1>
<#assign multiValued=true>
</#if>
<#if form.capabilities?? && form.capabilities.javascript?? && form.capabilities.javascript == false><#assign jsDisabled=true><#else><#assign jsDisabled=false></#if>
<div class="form-field">
<#if form.mode == "view">
<div class="viewmode-field">
<#if field.mandatory && field.value == "">
<span class="incomplete-warning"><img src="${url.context}/res/components/form/images/warning-16.png" title="${msg("form.field.incomplete")}" /><span>
</#if>
<span class="viewmode-label">${field.label?html}:</span>
<#if field.value == "">
<span class="viewmode-value">
${msg("form.control.novalue")}
<#elseif !multiValued>
<span class="viewmode-value viewmode-value-date" data-date-iso8601="${field.value}" data-show-time="${showTime?string}">
${xmldate(field.value)?string(viewFormat)}
<#else>
<span class="viewmode-value">
<#list field.value?split(",") as dateEl>
${xmldate(dateEl)?string(viewFormat)}<#if dateEl_has_next>,</#if>
</#list>
</#if>
</span>
</div>
<#elseif !multiValued>
<#if jsDisabled>
<label for="${fieldHtmlId}">${field.label?html}:<#if field.mandatory><span class="mandatory-indicator">${msg("form.required.fields.marker")}</span></#if></label>
<input id="${fieldHtmlId}" name="${field.name?html}" type="text" class="date-entry" value="${field.value?html}" <#if field.description??>title="${field.description}"</#if> <#if disabled>disabled="true"<#else>tabindex="0"</#if> />
<div class="format-info">
<span class="date-format">${msg("form.control.date-picker.entry.datetime.format.year.nojs")}</span>
</div>
<#else>
<#assign controlId = fieldHtmlId + "-cntrl">
<script type="text/javascript">//<![CDATA[
(function()
{
new Alfresco.DatePicker("${controlId}", "${fieldHtmlId}").setOptions(
{
<#if form.mode == "view" || disabled>disabled: true,</#if>
currentValue: "${field.value?js_string}",
showTime: ${showTime?string},
submitTime: ${submitTime?string},
mandatory: ${field.mandatory?string}
}).setMessages(
${messages}
);
})();
//]]></script>
<input id="${fieldHtmlId}" type="hidden" name="${field.name?html}" value="${field.value?html}" />
<label for="${controlId}-date">${field.label?html}:<#if field.mandatory><span class="mandatory-indicator">${msg("form.required.fields.marker")}</span></#if></label>
<input id="${controlId}-date" name="-" type="text" class="date-entry" <#if field.description??>title="${field.description}"</#if> <#if disabled>disabled="true"<#else>tabindex="0"</#if> />
<#if disabled == false>
<a id="${controlId}-icon"><img src="${url.context}/res/components/form/images/calendar.png" class="datepicker-icon" tabindex="0"/></a>
</#if>
<div id="${controlId}" class="datepicker"></div>
<#if showTime>
<input id="${controlId}-time" name="-" type="text" class="time-entry" <#if field.description??>title="${field.description}"</#if> <#if disabled>disabled="true"<#else>tabindex="0"</#if> />
</#if>
<@formLib.renderFieldHelp field=field />
<div class="format-info">
<span class="date-format">${msg("form.control.date-picker.display.date.format.year")}</span>
<#if showTime><span class="time-format<#if disabled>-disabled</#if>">${msg("form.control.date-picker.display.time.format.year")}</span></#if>
</div>
</#if>
</#if>
</div>
## Format used for date entry in date picker, 'entry' format is used by date parsing code,
## 'display' format is shown to the user under date entry field
form.control.date-picker.entry.date.format=d/M/yyyy
form.control.date-picker.display.date.format=DD/MM/AAAA
form.control.date-picker.entry.date.format.year=yyyy
form.control.date-picker.display.date.format.year=AAAA
## Format used for time entry in datetime picker, 'entry' format is used by date parsing code,
## 'display' format is shown to the user under time entry field
form.control.date-picker.entry.time.format=HH:mm
form.control.date-picker.display.time.format=HH:MM (24 Horas)
## Format used for date and time when form is in 'view' mode
form.control.date-picker.view.date.format=EEE dd MMM yyyy
form.control.date-picker.view.time.format=EEE dd MMM yyyy HH:mm:ss z
form.control.date-picker.view.date.format.year=yyyy
form.control.date-picker.view.time.format.year=yyyy
## Format used for date and time input field when JavaScript is disabled
form.control.date-picker.entry.datetime.format.nojs=YYYY-MM-DDThh:mm:ss.sTZD
form.control.date-picker.entry.datetime.format.year.nojs=YYYY
Alfresco.DatePicker
de JavaScript. Lo tienes definido en share/components/form/date-picker.js
. Una vez que lo hayas rebautizado (p. e. Alfresco.YearPicker
) cambia también la referencia en tu FTL de control.
Content from pre 2016 and from language groups that have been closed.
Content is read-only.
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.