File tree 3 files changed +10
-2
lines changed
src/main/groovy/au/org/ala/ecodata/forms
3 files changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -300,6 +300,14 @@ function orEmptyArray(v) {
300
300
return _ . isEqual ( value1 , value2 ) ;
301
301
} ;
302
302
303
+ parser . functions . formatDateForValidation = function ( value ) {
304
+ if ( ! value ) {
305
+ return '' ;
306
+ }
307
+
308
+ return moment ( value ) . format ( 'DD-MM-YYYY' ) ;
309
+ }
310
+
303
311
var specialBindings = function ( ) {
304
312
305
313
return {
Original file line number Diff line number Diff line change 1
1
<div id =" ${ context. source } Date" class =" input-group" >
2
- <input class =" form-control form-control-sm inputDatePicker" ${context.attributes} data-bind =" ${ context. databindAttrs } " type =" text" size =" 12" ${context.validationAttr} />
2
+ <input class =" form-control form-control-sm inputDatePicker" ${context.attributes} data-bind =" ${ context. databindAttrs } " type =" text" size =" 12" autocomplete = " off " ${context.validationAttr} />
3
3
<div class =" input-group-append" >
4
4
<span class =" add-on input-group-text open-datepicker" ><i class =" fa fa-th" ></i ></span >
5
5
</div >
Original file line number Diff line number Diff line change @@ -86,7 +86,7 @@ public class EditModelWidgetRenderer implements ModelWidgetRenderer {
86
86
@Override
87
87
void renderSimpleDate (WidgetRenderContext context ) {
88
88
context. databindAttrs. add ' datepicker' , context. source + ' .date'
89
- context. writer << " <input${ context.attributes.toString()} data-bind='${ context.databindAttrs.toString()} '${ context.validationAttr} type='text' class='form-control form-control-sm input-small'/>"
89
+ context. writer << " <input${ context.attributes.toString()} data-bind='${ context.databindAttrs.toString()} '${ context.validationAttr} type='text' autocomplete='off' class='form-control form-control-sm input-small'/>"
90
90
}
91
91
92
92
@Override
You can’t perform that action at this time.
0 commit comments