From 0fee09f987d9b7a446c083a5eab040e242850390 Mon Sep 17 00:00:00 2001 From: leon Date: Thu, 10 Aug 2023 16:50:27 +0800 Subject: [PATCH] sync --- roojs-bootstrap-debug.js | 2 +- roojs-bootstrap.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/roojs-bootstrap-debug.js b/roojs-bootstrap-debug.js index 61f231c22a..2032bddf97 100644 --- a/roojs-bootstrap-debug.js +++ b/roojs-bootstrap-debug.js @@ -23032,7 +23032,7 @@ Roo.extend(Roo.bootstrap.form.DateField, Roo.bootstrap.form.Input, { } translation.months.push(month); - translation/monthsShort.push(monthShort); + translation.monthsShort.push(monthShort); } }, diff --git a/roojs-bootstrap.js b/roojs-bootstrap.js index 740336698e..9633e33824 100644 --- a/roojs-bootstrap.js +++ b/roojs-bootstrap.js @@ -968,7 +968,7 @@ Roo.bootstrap.form.DateField=function(A){Roo.bootstrap.form.DateField.superclass },setDate:function(d){this.setUTCDate(new Date(d.getTime()-(d.getTimezoneOffset()*60000)));},setUTCDate:function(d){this.date=d;this.setValue(this.date);},translateDates:function(A){var B=Roo.bootstrap.form.DateField.dates[A]={days:[],daysShort:[],daysMin:[],months:[],monthsShort:[]} ;var C=A.replace('_','-');var D=['zh-hk','zh-cn','jp','ko'].indexOf(C.toLowerCase())<0;for(var i=0;i<7;i++){var E=new Date(2020,0,5+i);var F=new Intl.DateTimeFormat(C,{weekday:'long'}).format(E);var G=new Intl.DateTimeFormat(C,{weekday:'short'}).format(E); var H=new Intl.DateTimeFormat(C,{weekday:'narrow'}).format(E);if(D){G=F.substring(0,3);H=F.substring(0,2);}B.days.push(F);B.daysShort.push(G);B.daysMin.push(H);}for(var i=0;i<12;i++){var E=new Date(2020,i);var I=new Intl.DateTimeFormat(C,{month:'long'}).format(E); -var J=new Intl.DateTimeFormat(C,{month:'short'}).format(E);if(D){J=I.substring(0,3);}B.months.push(I);B/monthsShort.push(J);}},onRender:function(ct,A){Roo.bootstrap.form.DateField.superclass.onRender.call(this,ct,A);this.translateDates(this.language);this.isRTL=Roo.bootstrap.form.DateField.dates[this.language].rtl||false; +var J=new Intl.DateTimeFormat(C,{month:'short'}).format(E);if(D){J=I.substring(0,3);}B.months.push(I);B.monthsShort.push(J);}},onRender:function(ct,A){Roo.bootstrap.form.DateField.superclass.onRender.call(this,ct,A);this.translateDates(this.language);this.isRTL=Roo.bootstrap.form.DateField.dates[this.language].rtl||false; this.format=this.format||'m/d/y';this.isInline=false;this.isInput=true;this.component=this.el.select('.add-on',true).first()||false;this.component=(this.component&&this.component.length===0)?false:this.component;this.hasInput=this.component&&this.inputEl().length; if(typeof(this.minViewMode==='string')){switch(this.minViewMode){case 'months':this.minViewMode=1;break;case 'years':this.minViewMode=2;break;default:this.minViewMode=0;break;}}if(typeof(this.viewMode==='string')){switch(this.viewMode){case 'months':this.viewMode=1; break;case 'years':this.viewMode=2;break;default:this.viewMode=0;break;}}this.pickerEl=Roo.get(document.body).createChild(Roo.bootstrap.form.DateField.template);this.picker().setVisibilityMode(Roo.Element.DISPLAY).originalDisplay='block';this.picker().on('mousedown',this.onMousedown,this); -- 2.39.2