Overview
Comment:Fix datepicker when switching to December from January, fix [9f765f4ab37f5631da5b31ecb8ce7b77da311e61]
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk | stable
Files: files | file ages | folders
SHA3-256: c4f649c73746c72c67daa8fcad4d67f3d64c812b1034bd7522027078bcdaf286
User & Date: bohwaz on 2022-01-20 17:32:40
Other Links: manifest | tags
References
2022-01-20
17:33 Fixed ticket [9f765f4ab3]: Pb lors de changement date 2022 vers 2021 plus 5 other changes artifact: 7bb83811ce user: bohwaz
Context
2022-01-21
01:49
Fix copy service check-in: ab0846d770 user: bohwaz tags: trunk, stable
2022-01-20
17:32
Fix datepicker when switching to December from January, fix [9f765f4ab37f5631da5b31ecb8ce7b77da311e61] check-in: c4f649c737 user: bohwaz tags: trunk, stable
2022-01-19
01:09
This is more reliable and takes less CPU check-in: 152ab929f9 user: bohwaz tags: trunk, stable
Changes

Modified src/www/admin/static/scripts/datepicker2.js from [03f694848a] to [9b5b078a36].

221
222
223
224
225
226
227

228
229
230
231
232
233
234
235
236
237
238
239
240
241
242

			this.date.setYear(y);
			this.refresh();
		}

		month(change, relative)
		{

			let m = relative ? this.date.getMonth() + change : change;
			this.date.setMonth(m);

			// When the date of the day is > number of days in month, it switches to following month
			// so we change the current date as well
			if (this.date.getMonth() != m) {
				this.date.setDate(0);
				this.date.setMonth(m);
			}

			this.refresh();
			this.focus(false);
		}

		day(change)







>





|

<







221
222
223
224
225
226
227
228
229
230
231
232
233
234
235

236
237
238
239
240
241
242

			this.date.setYear(y);
			this.refresh();
		}

		month(change, relative)
		{
			let d = this.date.getDate();
			let m = relative ? this.date.getMonth() + change : change;
			this.date.setMonth(m);

			// When the date of the day is > number of days in month, it switches to following month
			// so we change the current date as well
			if (this.date.getDate() != d) {
				this.date.setDate(0);

			}

			this.refresh();
			this.focus(false);
		}

		day(change)