Merge branch 'maint-rel-1.6' into develop

This commit is contained in:
tworrall 2013-12-09 16:18:42 -05:00
commit 0c9ad8bd08
4 changed files with 12 additions and 6 deletions

View file

@ -862,3 +862,5 @@ view_labels_capitalized = Ver etiquetas
view_labels_for = Ver Etiquetas de view_labels_for = Ver Etiquetas de
select_an_existing_document = Seleccione un documento existente select_an_existing_document = Seleccione un documento existente
datetime_year_required = Intervalos de fecha / hora deben empezar por un año. Ingrese una Fecha de inicio, un fin de año o los dos.

View file

@ -63,8 +63,11 @@ public class DateTimeIntervalValidationVTwo implements N3ValidatorVTwo {
// errors.put(startFieldName, "If there is an end date, there should be a start date"); // errors.put(startFieldName, "If there is an end date, there should be a start date");
// return errors; // return errors;
// } // }
// We need to ensure that the user has entered a start year or end year -- tlw72
if ( literalListIsNull(formStartYear) && literalListIsNull(formStartYear) ) {
errors.put(startFieldName, "Date/time intervals must begin with a year. Please enter a start year or an end year.");
return errors;
}
//Assuming form start year and form end year are working in conjunction with multiple values //Assuming form start year and form end year are working in conjunction with multiple values
int index; int index;
if (!literalListIsNull(formStartYear) && !literalListIsNull(formEndYear)) { if (!literalListIsNull(formStartYear) && !literalListIsNull(formEndYear)) {

View file

@ -876,3 +876,5 @@ view_labels_capitalized = View Labels
view_labels_for = View Labels for view_labels_for = View Labels for
select_an_existing_document = Select an existing document select_an_existing_document = Select an existing document
datetime_year_required = Date/time intervals must begin with a year. Enter either a Start Year, an End Year or both.

View file

@ -58,7 +58,7 @@
<#if htmlForElements?keys?seq_contains("endField")> <#if htmlForElements?keys?seq_contains("endField")>
${i18n().end_capitalized}&nbsp; ${htmlForElements["endField"]} ${i18n().end_capitalized}&nbsp; ${htmlForElements["endField"]}
</#if> </#if>
<span class="requiredHint"> *${i18n().datetime_year_required}</span>
<p class="submit"> <p class="submit">
<input type="hidden" name="editKey" value="${editKey}" /> <input type="hidden" name="editKey" value="${editKey}" />
<input type="submit" id="submit" value="${submitButtonText}" role="button" /> <input type="submit" id="submit" value="${submitButtonText}" role="button" />
@ -69,8 +69,7 @@
</p> </p>
</form> </form>
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/edit/forms/css/customForm.css" />', ${stylesheets.add('<link rel="stylesheet" href="${urls.base}/templates/freemarker/edit/forms/css/customForm.css" />')}
'<link rel="stylesheet" href="${urls.base}/edit/forms/css/personHasEducationalTraining.css" />')}
${scripts.add('<script type="text/javascript" src="${urls.base}/js/utils.js"></script>', ${scripts.add('<script type="text/javascript" src="${urls.base}/js/utils.js"></script>',
'<script type="text/javascript" src="${urls.base}/js/customFormUtils.js"></script>')} '<script type="text/javascript" src="${urls.base}/js/customFormUtils.js"></script>')}