js/WebDatePicker.js

(开头部分) 9KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

///////////////////////////////////////////////////
//WebDatePicker.js
//PowerAsp.NET Controls
//////////////////////////////////////////////////
var currentOpenCalender;
var currentIsOpen = 0;

function HideCalender()
{
   if(currentIsOpen == 1)
   {
      currentOpenCalender.style.display = "none";
      currentOpenCalender = null;
      document.onclick=null;
      defaultCoordinate.Remove();
   }
   currentIsOpen++;
   return true;
 }

function CalenderObject(ctrl,edit,initDate)
{
 this.currentDate = initDate;
 this.owner = ctrl;
 this.editCtrl = edit;
 //mapping control from DOM to variable.
 this.yearCtrl = ctrl.children[0].children[0].children[0].children[0].children[0].children[0].children[2];
 this.monthCtrl = ctrl.children[0].children[0].children[0].children[0].children[0].children[0].children[5];
 this.headerFirst = ctrl.children[0].children[0].children[0].children[0].children[0].children[1];
 this.date_row1 = ctrl.children[0].children[0].children[0].children[0].children[0].children[2];
 this.date_row2 = ctrl.children[0].children[0].children[0].children[0].children[0].children[3];
 this.date_row3 = ctrl.children[0].children[0].children[0].children[0].children[0].children[4];
 this.date_row4 = ctrl.children[0].children[0].children[0].children[0].children[0].children[5];
 this.date_row5 = ctrl.children[0].children[0].children[0].children[0].children[0].children[6]; 
 this.date_row6 = ctrl.children[0].children[0].children[0].children[0].children[0].children[7]; 
 this.dateCtrls = new Array(32);
 this.currentDay;


 this.CoordinateNow = function()
 {
      currentIsOpen = 1;	
      HideCalender();	
 }
 
 this.UpdateData = function()
 {
   var baseDate = new Date(this.currentDate.getYear(),this.currentDate.getMonth(),this.currentDate.getDate());
   
   var year = (this.currentDate.getYear()<1900?(1900+this.currentDate.getYear()):this.currentDate.getYear());
   
   var ysel = year;
   var msel = baseDate.getMonth()+1;
   var dsel = baseDate.getDate();
   if(msel<10)msel='0'+msel
   if(dsel<10)dsel='0'+dsel
   this.editCtrl.value = ysel+'-'+msel+'-'+dsel; 
 }
 
 this.getDayCount = function()
后面还有 279 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明

AI 解读

登录后可用,每次 10 积分,解读结果公开显示在下面。

还没有人解读过这个文件。