Automatic dates (client side) » History » Version 1
Version 1/8
-
Next ยป -
Current version
Pablo Alingery, 21/03/2012 19:30
Automatic dates (client side)¶
Ajout dans le fichier /client-public/js/components/commons/forms/components/singleSelection/DateBeetween.js ligne 37
var date1 = new Date(); var numberOfDaysToRemove= 8; date1.setDate(date1.getDate()-numberOfDaysToRemove); date1.setHours(0, 0, 0, 0) this.fieldFrom = new Ext.form.DateField({ allowBlank : true, format : dateFormat, flex : 1, //height : this.height, //value : new Date(this.defaultValues[0]).format(dateFormat), //value : new Date("2010/09/02 23:00:00").format(dateFormat), value : date1.format(dateFormat), showTime : this.showTime }); var date2 = new Date(); date2.setHours(0, 0, 0, 0); this.fieldTo = new Ext.form.DateField({ allowBlank : true, format : dateFormat, flex : 1, //height : this.height, //value : new Date(this.defaultValues[1]).format(dateFormat), value : date2.format(dateFormat), showTime : this.showTime });