📄 a573a488.js
字号:
function ComponentArt_MultiPage(id){this.ClientControlId=this.Id=id;this.qqQz=id+'_table';this.DomElement=document.getElementById(this.qqQz);this.Pages=new Array();this.StateField=document.getElementById(id+'_SelectedIndex');this.SelectedPage=null;};ComponentArt_MultiPage.prototype.GetProperty=function(propName){return this[propName];};ComponentArt_MultiPage.prototype.SetProperty=function(propName,propValue){this[propName]=propValue;};ComponentArt_MultiPage.prototype.AddPage=function(page){page.ParentMultiPage=this;this.Pages[this.Pages.length]=page;};ComponentArt_MultiPage.prototype.ConvertPageToIndex=function(page){for(var index=0;index<this.Pages.length;index++){if(this.Pages[index]==page){return index;};};return-1;};ComponentArt_MultiPage.prototype.Disable=function(){this.DomElement.disabled=true;for(var index=0;index<this.Pages.length;index++){this.Pages[index].Disable();};};ComponentArt_MultiPage.prototype.DisablePage=function(id){var page=this.FindPageById(id);page.Disable();};ComponentArt_MultiPage.prototype.Enable=function(){this.DomElement.disabled=false;for(var index=0;index<this.Pages.length;index++){this.Pages[index].Enable();};};ComponentArt_MultiPage.prototype.GetPage=function(index){if(index>=0&&index<this.Pages.length)return this.Pages[index];else return null;};ComponentArt_MultiPage.prototype.GetPageIndex=function(){if(this.SelectedPage)return this.ConvertPageToIndex(this.SelectedPage);else return-1;};ComponentArt_MultiPage.prototype.GoFirst=function(){this.SetPageIndex(0);};ComponentArt_MultiPage.prototype.GoLast=function(){this.SetPageIndex(this.NumPages()-1);};ComponentArt_MultiPage.prototype.GoNext=function(bWrap){var currentIndex=this.GetPageIndex();if(currentIndex>=this.NumPages()-1){if(bWrap){this.GoFirst();};}else{this.SetPageIndex(currentIndex+1);};};ComponentArt_MultiPage.prototype.GoPrevious=function(bWrap){var currentIndex=this.GetPageIndex();if(currentIndex<=0){if(bWrap){this.GoLast();};}else{this.SetPageIndex(currentIndex-1);};};ComponentArt_MultiPage.prototype.NumPages=function(){return this.Pages.length;};ComponentArt_MultiPage.prototype.SetPageIndex=function(index,qzma){if(index>=0&&index<this.Pages.length){this.Pages[index].Show(qzma);};};ComponentArt_MultiPage.prototype.SetPageId=function(id){var oPage=this.FindPageById(id);if(oPage){oPage.Show();};};ComponentArt_MultiPage.prototype.FindPageById=function(id){for(var qzba=0;qzba<this.Pages.length;qzba++){if(this.Pages[qzba].Id==id||this.Pages[qzba].qqQz==id){return this.Pages[qzba];};};return null;};function ComponentArt_PageView(qqQz,id){this.ParentMultiPage=null;this.Id=id;this.DomElement=document.getElementById(qqQz);this.qqQz=qqQz;};ComponentArt_PageView.prototype.GetProperty=function(propName){return this[propName];};ComponentArt_PageView.prototype.SetProperty=function(propName,propValue){this[propName]=propValue;};ComponentArt_PageView.prototype.DisableRecurse=function(arDomElements){for(var qzba=0;qzba<arDomElements.length;qzba++){if(arDomElements[qzba].nodeName=='SELECT'||arDomElements[qzba].nodeName=='INPUT'||arDomElements[qzba].nodeName=='TEXTBOX'){arDomElements[qzba].disabled=true;}else if(arDomElements[qzba].childNodes.length>0){this.DisableRecurse(arDomElements[qzba].childNodes);};};};ComponentArt_PageView.prototype.Disable=function(){this.DomElement.disabled=true;this.DisableRecurse(this.DomElement.childNodes);};ComponentArt_PageView.prototype.EnableRecurse=function(arDomElements){for(var qzba=0;qzba<arDomElements.length;qzba++){if(arDomElements[qzba].nodeName=='SELECT'||arDomElements[qzba].nodeName=='INPUT'||arDomElements[qzba].nodeName=='TEXTBOX'){arDomElements[qzba].disabled=false;}else if(arDomElements[qzba].childNodes.length>0){this.EnableRecurse(arDomElements[qzba].childNodes);};};};ComponentArt_PageView.prototype.Enable=function(){this.DomElement.disabled=false;this.EnableRecurse(this.DomElement.childNodes);};ComponentArt_PageView.prototype.Show=function(qzma){if(!qzma&&this.ParentMultiPage&&this.ParentMultiPage.AutoPostBack){__doPostBack(this.ParentMultiPage.ControlId,this.ParentMultiPage.ConvertPageToIndex(this));return;};if(this.ParentMultiPage){if(this.ParentMultiPage.SelectedPage){this.ParentMultiPage.SelectedPage.DomElement.style.display='none';};this.ParentMultiPage.SelectedPage=this;this.DomElement.style.display='';};if(this.ParentMultiPage.StateField){this.ParentMultiPage.StateField.value=this.ParentMultiPage.ConvertPageToIndex(this);};};var ComponentArt_MultiPage_Kernel_Loaded=true;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -