/*
 * Isomorphic SmartClient
 * Version v11.1p_2017-06-29 (2017-06-29)
 * Copyright(c) 1998 and beyond Isomorphic Software, Inc. All rights reserved.
 * "SmartClient" is a trademark of Isomorphic Software, Inc.
 *
 * licensing@smartclient.com
 *
 * http://smartclient.com/license
 */

if(window.isc&&window.isc.module_Core&&!window.isc.module_Forms){isc.module_Forms=1;isc._moduleStart=isc._Forms_start=(isc.timestamp?isc.timestamp():new Date().getTime());if(isc._moduleEnd&&(!isc.Log||(isc.Log&&isc.Log.logIsDebugEnabled('loadTime')))){isc._pTM={message:'Forms load/parse time: '+(isc._moduleStart-isc._moduleEnd)+'ms',category:'loadTime'};if(isc.Log&&isc.Log.logDebug)isc.Log.logDebug(isc._pTM.message,'loadTime');else if(isc._preLog)isc._preLog[isc._preLog.length]=isc._pTM;else isc._preLog=[isc._pTM]}isc.definingFramework=true;if(window.isc&&isc.version!="v11.1p_2017-06-29/LGPL Deployment"&&!isc.DevUtil){isc.logWarn("SmartClient module version mismatch detected: This application is loading the core module from SmartClient version '"+isc.version+"' and additional modules from 'v11.1p_2017-06-29/LGPL Deployment'. Mixing resources from different SmartClient packages is not supported and may lead to unpredictable behavior. If you are deploying resources from a single package you may need to clear your browser cache, or restart your browser."+(isc.Browser.isSGWT?" SmartGWT developers may also need to clear the gwt-unitCache and run a GWT Compile.":""))}
isc.A=isc.Canvas;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.applyTableResizePolicy=function isc_c_Canvas_applyTableResizePolicy(_1,_2,_3,_4,_5,_6,_7){var _8=this.logIsDebugEnabled("tablePolicy"),_9=this.logIsInfoEnabled("tablePolicy"),_10=this.logIsDebugEnabled("tablePlacement");var _11=_1.$8j;if(!this.$8k(_1)){_11=_1.$8j=[];var _12=0,_13=0;for(var _14=0;_14<_1.length;_14++){var _15=_1[_14];if(!_15.alwaysTakeSpace&&!_15.visible)continue;var _16=_15.getColSpan(),_17=_15.getRowSpan();if(_17==0||_16==0)continue;if(_16==null)_16=1;if(_17==null)_17=1;var _18=_16;if(_16=="*")_18=1;var _19=_15.getTitleOrientation();if(_15.showTitle&&(_19==isc.Canvas.LEFT||_19==isc.Canvas.RIGHT))
{_18+=(_15.getTitleColSpan()||1);if(_16!="*")_16+=(_15.getTitleColSpan()||1)}
var _20=(_15.isStartRow?_15.isStartRow():_15.startRow),_21=(_15.isEndRow?_15.isEndRow():_15.endRow);if(_10){this.logDebug("at: "+["row"+_12,"col"+_13]+", item: "+(_15.name||_15.Class)+(_16=="*"?", colSpan:'*'":"")+", required cols:"+_18+(_17>1?", rowSpan:"+_17:"")+(_20?", startRow:true":"")+(_21?", endRow:true":""),"tablePlacement")}
var _22=null,_23=null;if(_13>=_4||(_20&&_13!=0)){_12++;_13=0;_15.$8l=true}else{_15.$8l=false}
if(_12<_11.length){for(;_12<_11.length;_12++){var _24=_11[_12];if(_24==null)break;for(;_13<_4;_13++){if(_24[_13]!=null)continue;for(var j=_13;j<_4;j++){if(_24[j]!=null)break;if((j-_13)+1>=_18){_22=_12;_23=_13;break}}
if(_23!=null)break}
if(_23!=null)break;_13=0;_15.$8l=true}}
if(_23==null){_22=_12;_23=0;_15.$8l=true}
_13=_23;if(_16=="*")_16=_4-_13;if(!isc.isA.Number(_17))_17=1;for(var r=_12;r<_12+_17;r++){if(!_11[r])_11[r]=[];for(var c=_13;c<_13+_16;c++){_11[r][c]=_14}}
_15.$8m=[_23,_22,_23+_16,_22+_17];_13+=_16;if(_21)_13=_4;if(_10){this.logDebug("item: "+(_15.name||_15.Class)+" placed at: "+["row"+_22,"col"+_23]+(_15.$8l?", marked startRow ":"")+", rowTable: "+this.echoAll(_11),"tablePlacement")}}
var _28=[];for(var r=0;r<_11.length;r++){var _29=_11[r];if(_29==null)break;var _30=0,_31=null;for(var c=0;c<_29.length;c++){if(_29[c]==null){_30++;continue}
if(r>0&&_11[r-1]!=null&&_29[c]==_11[r-1][c])continue;var _14=_29[c],_15=_1[_14];if(_15==_31||_15==null)continue;_15.$8n=_28;_15.$8o=_30;if(_10&&(_30>0||_28.length>0)){this.logDebug("itemNum:"+_14+" ("+(_15.name||_15.Class)+") at: "+["row"+_22,"col"+_23]+" preceded by "+(_30>0?_30+" empty cells":"")+(_28.length>0?" "+_28.length+" empty rows":""),"tablePlacement")}
_30=0;_28=[];_31=_15}
if(_31==null){_28.add(_30+(_4-_29.length));_30=0}}
if(_28!=null&&_11.length>0){var _32=_28.length;var _29=_11[_11.length-1];for(var c=0;c<_29.length;c++){var _14=_29[c];_15=_1[_14];if(_15==null)continue;var _33=_15.$8m[3]-_15.$8m[1];_33-=_32;_15.$135a=_33}}}
if(!_5||!isc.isAn.Array(_5)){if(!isc.isAn.Array(_5)){this.logWarn(" 'colWidths' not an array - Ignoring.","tableResizePolicy")}
_5=[]}
_5=_5.duplicate();for(var c=0;c<_5.length;c++){var _34=_5[c];if(isc.isA.String(_34)){if(_34=="*")_5[c]=[0,10000,0,1];else if(_34.contains("*"))_5[c]=[0,10000,0,parseInt(_34)];else if(_34.contains("%"))_5[c]=[0,10000,parseInt(_34),0];else{var _35=parseInt(_34);if(_35==_34){_5[c]=_35}else{this.logWarn("Failed to understand specified colWidth:"+_34);_5[c]=[0,10000,0,1]}}}}
_1.colWidths=_5;var _36;if(!_6){_6=[];for(var r=0;r<_11.length;r++){var _29=_11[r],_37=null,_38=100000,_39=0,_40=0;if(!_29)continue;for(var c=0;c<_29.length;c++){var _15=_1[_29[c]];if(!_15)continue;var _41=_15.getCellHeight(_7);var _17=(_15.$8m[3]-_15.$8m[1]);if(_8)this.logWarn("item at: "+[r,c]+" has height: "+_41+", item is: "+_15);_15.$8p=false;if(isc.isA.Number(_41)){_41=Math.floor(_41/_17);if(_8)this.logWarn("item: "+_15+" has pixel size: "+_41);if(_37==null||_41>_37){_37=_41}
if(_41>_38)_38=_41}else if(isc.isA.String(_41)){if(_41.contains("*")){_15.$8p=true;var _42=(_41=="*"?1:parseFloat(_41))/_17;if(_8)this.logWarn("item: "+_15+" has star size: "+_42);_40=Math.max(_40,_42)}else{_15.$8p=true;var _43=parseFloat(_41)/_17;if(_8)this.logWarn("item: "+_15+" has percent size: "+_43);if(_43>_39)_39=_43}
if(_36==null)_36=2*_15.form.cellPadding;var _44=_15.getMinHeight();if(_44!=null){_44+=_36;if(_44>_37){_37=_44}
if(_44>_38){_38=_44}}
var _45=_15.getMaxHeight();if(_45!=null){_45+=_36;if(_45<_38&&_37<_45)
{_38=_45}}}
if(_39>0||_40>0){if(_37==null)_37=0;_6[r]=[_37,_38,_39,_40]}else{if(_37==null){_37=_1.$8q||22}
_6[r]=_37}}}}
_1.rowHeights=_6;if(_9)this.logInfo("\ntotalWidth: "+_2+", totalHeight: "+_3+"\nspecified sizes:\ncols:"+this.echoAll(_1.colWidths)+", rows: "+this.echoAll(_1.rowHeights),"tablePolicy");_1.$8r=_5=isc.Canvas.stretchResizeList(_1.colWidths,_2);_1.$8s=_6=isc.Canvas.stretchResizeList(_1.rowHeights,_3);if(_9)this.logInfo("\nderived sizes:\ncols:"+this.echoAll(_1.$8r)+", rows: "+this.echoAll(_1.$8s),"tablePolicy");for(_14=0;_14<_1.length;_14++){_15=_1[_14];if(!_15.visible)continue;var _46=isc.isA.Canvas(_15),_47=!_46&&isc.isA.CanvasItem(_15),_34=_47?(_15.canvas&&_15.canvas.$pn)||_15.width:_15.getWidth(),_48=_46?_15.getHeight():_15.getCellHeight(_7),_19=_15.getTitleOrientation(),_49=_15.$8m,_50=0;if(_49==null)continue;if(_15.showTitle){if(_19==isc.Canvas.LEFT){_50=_5[_49[0]]}else{_50=_5[_49[2]]}}
if(_34=="*"||_34=="100%"){_34=0;var _51=_15.getTitleColSpan()||1,_52=(_15.showTitle&&_19==isc.Canvas.LEFT)?_51:0,_53=(_15.showTitle&&_19==isc.Canvas.RIGHT)?_51:0,_54=_49[0]+_52,_55=Math.min(_5.length,_49[2]-_53);for(var c=_54;c<_55;c++){_34+=_5[c]}}
if(_15.$8p){_48=0;var _20=_49[1],_21=_49[3];for(var c=_20;c<_21;c++){_48+=_6[c]}}
_15.$8t=[_34,_48];_15.$8u=_50}},isc.A.$8k=function isc_c_Canvas__tableResizePolicyIsValid(_1){if(!_1.$8j)return false;return true},isc.A.invalidateTableResizePolicy=function isc_c_Canvas_invalidateTableResizePolicy(_1){delete _1.$8j;delete _1.$8s;delete _1.$8r},isc.A.stretchResizeList=function isc_c_Canvas_stretchResizeList(_1,_2){var _3=0,_4=0,_5=0,_6=_1.duplicate();for(var i=0;i<_1.length;i++){var _8=_6[i];if(isc.isA.Number(_8)){_8=Math.max(_8,1);_5+=_8;_6[i]=_8}else{var _9=_8[2],_10=_8[3];if(_10==0){_3+=_9}
_4+=_10}}
if(_4){var _11=0;if(_3<100){_11=(100-_3)/_4}
for(var r=0;r<_1.length;r++){var _8=_6[r];if(isc.isA.Number(_8))continue;var _9=_8[2],_10=_8[3],_13=_10*_11;if(_9<_13){_8[2]=_13}
if(_10>0)_3+=_8[2]}}
if(_3<=0)return _6;var _14=Math.max(0,_2-_5);for(var r=0;r<_1.length;r++){var _15=Math.max(0,_14/_3),_8=_6[r];if(isc.isA.Number(_8))continue;var _16=_8[0];if(_16==0)continue;var _17=_8[2],_18=_15*_17;if(_18<_16){_6[r]=_16;_14-=_16;_3-=_17;r=0}}
for(var r=0;r<_1.length;r++){var _15=Math.max(0,_14/_3),_8=_6[r];if(isc.isA.Number(_8))continue;var _19=_8[1],_17=_8[2],_18=_15*_17;if(_18>_19){_6[r]=_19;_14-=_19;_3-=_17;r=0}}
_15=Math.max(0,_14/_3);for(var r=0;r<_1.length;r++){_8=_6[r];if(isc.isA.Number(_8))continue;var _17=_8[2];_6[r]=Math.floor(_17*_15);_14-=_6[r]}
if(_14>0){for(var r=_1.length-1;r>=0;r--){_8=_1[r];if(isc.isA.Number(_8))continue;var _19=_8[1];if(_6[r]+_14<=_19){_6[r]+=_14;break}}
if(r<0&&this.logIsInfoEnabled("tablePolicy")){this.logInfo("stretchResizeList(): unable to assign "+_14+"px of remaining space to a variable-sized item due to due to specified maximums","tablePolicy")}}
return _6});isc.B._maxIndex=isc.C+4;isc.ClassFactory.defineClass("ButtonTable",isc.Canvas);isc.A=isc.ButtonTable.getPrototype();isc.A.cellSpacing=0;isc.A.cellPadding=2;isc.A.cellBorder=0;isc.A.tableStyle="menuTable";isc.A.baseButtonStyle="button";isc.A.backgroundColor="CCCCCC";isc.A.useEventParts=true;isc.A=isc.ButtonTable.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.buttonTableClickMaskDefaults={_constructor:"Canvas",width:"100%",height:"100%",overflow:"hidden",click:function(){this.creator.hide()}};isc.B.push(isc.A.setItems=function isc_ButtonTable_setItems(_1){this.items=isc.shallowClone(_1);this.redraw()},isc.A.getInnerHTML=function isc_ButtonTable_getInnerHTML(){var _1=isc.SB.create();_1.append("<TABLE"," CLASS=",this.tableStyle," WIDTH=",this.getWidth()-(this.overflow==isc.Canvas.SCROLL||this.overflow==isc.Canvas.AUTO?this.getScrollbarSize():0)," HEIGHT=",this.getHeight()," CELLSPACING=",this.cellSpacing," CELLPADDING=",this.cellPadding," BORDER=",this.cellBorder,"><TR>");for(var r=0;r<this.items.length;r++){var _3=this.items[r];_1.append("<TR>");if(!isc.isAn.Array(_3))_3=[_3];for(var i=0;i<_3.length;i++){var _5=_3[i];if(_5.eventPart){_1.append(this.getCellButtonHTML(_5.contents,_5.style,_5.disabled,_5.selected,_5.align,_5.extraTagStuff,_5.eventPart,_5.eventId))}else{_1.append(this.getCellHTML(_5.contents,_5.style,_5.align,_5.extraTagStuff))}}
_1.append("</TR>")}
_1.append("</TABLE>");return _1.release(false)},isc.A.showModal=function isc_ButtonTable_showModal(){if(!this.buttonTableClickMask){this.buttonTableClickMask=this.createAutoChild("buttonTableClickMask")}
this.buttonTableClickMask.show();this.buttonTableClickMask.bringToFront();this.show();this.unmask();this.moveAbove(this.buttonTableClickMask)},isc.A.hide=function isc_ButtonTable_hide(){this.Super("hide",arguments);if(this.buttonTableClickMask)this.buttonTableClickMask.hide()},isc.A.destroy=function isc_ButtonTable_destroy(){if(this.buttonTableClickMask){this.buttonTableClickMask.destroy();this.buttonTableClickMask=null}
this.Super("destroy",arguments)},isc.A.getButtonBaseStyle=function isc_ButtonTable_getButtonBaseStyle(_1){var _2;if(_1)_2=_1.getAttribute("basestyle");if(!_2)_2=this.baseButtonStyle;return _2},isc.A.getMouseOutStyle=function isc_ButtonTable_getMouseOutStyle(_1){var _2=this.getButtonBaseStyle(_1);if(this.buttonIsSelected(_1)){_2+="Selected"}
if(this.buttonIsDisabled(_1)){_2+="Disabled"}
return _2},isc.A.buttonIsSelected=function isc_ButtonTable_buttonIsSelected(_1){return _1&&_1.getAttribute("buttonselected")},isc.A.buttonIsDisabled=function isc_ButtonTable_buttonIsDisabled(_1){return _1&&_1.getAttribute("buttondisabled")},isc.A.cellButtonOver=function isc_ButtonTable_cellButtonOver(_1){var _2=this.getButtonBaseStyle(_1);if(this.buttonIsSelected(_1))_2+="Selected";if(_1)_1.className=_2+"Over"},isc.A.cellButtonOut=function isc_ButtonTable_cellButtonOut(_1){if(!_1)return;_1.className=this.getMouseOutStyle(_1)},isc.A.cellButtonDown=function isc_ButtonTable_cellButtonDown(_1){if(_1){var _2=this.getButtonBaseStyle(_1);if(this.buttonIsSelected(_1))_2+="Selected";_2+="Down"
_1.className=_2}},isc.A.getCellHTML=function isc_ButtonTable_getCellHTML(_1,_2,_3,_4){return isc.StringBuffer.concat("<TD ALIGN=",(_3||isc.Canvas.CENTER)," CLASS=",(_2||this.baseButtonStyle+"Disabled"),(_4||_4),">",_1,"</TD>")},isc.A.handleMouseDown=function isc_ButtonTable_handleMouseDown(_1){_1.touchStartReturnValue=false;var _2=_1.nativeTarget;if(_2.tagName!="TD")_2=_2.parentNode;if(!_2.getAttribute||!_2.getAttribute(this.$pk))return;this.cellButtonDown(_2);this.Super("handleMouseDown",arguments)},isc.A.handleMouseUp=function isc_ButtonTable_handleMouseUp(_1){var _2=_1.nativeTarget;if(_2.tagName!="TD")_2=_2.parentNode;if(!_2.getAttribute||!_2.getAttribute(this.$pk))return;this.cellButtonOut(_2);this.Super("handleMouseUp",arguments)},isc.A.getCellButtonHTML=function isc_ButtonTable_getCellButtonHTML(_1,_2,_3,_4,_5,_6,_7,_8){if(_2==null)_2=this.baseButtonStyle;var _9=_2;if(_3)_9+="Selected";if(_4)_9+="Disabled";var _10=" "+this.$pk+"="+(_7?_7:"$95w");if(_8!=null)_10+=" id="+this.getID()+"_"+_7+"_"+_8;return isc.StringBuffer.concat("<TD ALIGN=",(_5||isc.Canvas.CENTER)," CLASS=",_9," ONMOUSEOVER='",this.getID(),".cellButtonOver(this);return false;' "," ONMOUSEOUT='",this.getID(),".cellButtonOut(this);return true;'"," basestyle='",_2,"'",(_3?" buttonselected='true'":null),(_4?" buttondisabled='true'":null),(_6?" "+_6:null),_10+">",_1,"</TD>")});isc.B._maxIndex=isc.C+16;if(isc.ListGrid==null){isc.Log.logInfo("Source for DateGrid included in this module, but required superclass (ListGrid) is not loaded. This can occur if the Forms module is loaded without the Grids module. DateGrid class will not be defined within this page.","moduleDependencies")}else{isc.ClassFactory.defineClass("DateGrid","ListGrid");isc.A=isc.DateGrid.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.width=10;isc.A.height=10;isc.A.cellHeight=20;isc.A.autoFitData="vertical";isc.A.minFieldWidth=20;isc.A.autoFitMaxRows=5;isc.A.useCellRollOvers=true;isc.A.canSelectCells=true;isc.A.leaveScrollbarGap=false;isc.A.canResizeFields=false;isc.A.headerButtonProperties={padding:0};isc.A.headerHeight=20;isc.A.canSort=false;isc.A.canEdit=false;isc.A.showSortArrow=isc.ListGrid.NONE;isc.A.showFiscalYear=false;isc.A.showFiscalWeek=false;isc.A.showCalendarWeek=false;isc.A.loadingDataMessage="";isc.A.alternateRecordStyles=false;isc.A.showHeaderMenuButton=false;isc.A.showHeaderContextMenu=false;isc.A.cellPadding=0;isc.A.wrapCells=false;isc.A.locateRowsBy="targetCellValue";isc.A.fiscalYearFieldTitle="Year";isc.A.weekFieldTitle="Wk";isc.A.canReorderFields=false;isc.A.bodyProperties={canSelectOnRightMouse:false,height:1,overflow:"visible"};isc.A.headerProperties={overflow:"visible"};isc.A.alwaysShowFirstFiscalWeek=true;isc.B.push(isc.A.initWidget=function isc_DateGrid_initWidget(){this.shortDayNames=isc.DateUtil.getShortDayNames(3);this.shortDayTitles=isc.DateUtil.getShortDayNames(this.dayNameLength);this.shortMonthNames=isc.DateUtil.getShortMonthNames();this.Super("initWidget",arguments);this.refreshUI(this.startDate||new Date())},isc.A.getTitleField=function isc_DateGrid_getTitleField(){return null},isc.A.getCellAlign=function isc_DateGrid_getCellAlign(_1,_2,_3){return"center"},isc.A.formatCellValue=function isc_DateGrid_formatCellValue(_1,_2,_3,_4){if(_1&&_1.getDate)return _1.getDate();return""+_1},isc.A.getCellStyle=function isc_DateGrid_getCellStyle(_1,_2,_3){var _4=this.getField(_3),_5=this.getRecordWeekNumber(_1),_6=_5==this.selectedWeek;if(_4.name=="fiscalYear"){return!_6?this.baseFiscalYearStyle:this.selectedWeekStyle}else if(_4.name=="fiscalWeek"||_4.name=="calendarWeek"){return!_6?this.baseWeekStyle:this.selectedWeekStyle}
var _7=this.getCellDate(_1,_2,_3),_8=this.dateIsDisabled(_7),_9=_7.getMonth()!=this.workingMonth,_10=this.Super("getCellStyle",arguments);;if(_4.isDateField){if((_8||_9)){_10=_4.isWeekend?this.disabledWeekendStyle:this.disabledWeekdayStyle;var _11=this.body.getEventRow(),_12=this.body.getEventColumn(),_13=(_11==_2&&_12==_3),_14=this.selection&&this.selection.lastSelectedCell,_15=_14?_14[0]==_2&&_14[1]==_3:this.cellSelection?this.cellSelection.isSelected(_2,_3):false,_16=_10.indexOf("Over"),_17=_10.indexOf("Selected");if(_16>=0)_10=_10.substring(0,_16);if(_17>=0)_10=_10.substring(0,_17);if(_15)_10+="Selected";if(_13)_10+="Over"}}
return _10},isc.A.cellMouseDown=function isc_DateGrid_cellMouseDown(_1,_2,_3){var _4=this.getCellDate(_1,_2,_3);if(!_4)return true;if(this.dateIsDisabled(_4))return false;return true},isc.A.cellClick=function isc_DateGrid_cellClick(_1,_2,_3){var _4=this.getCellDate(_1,_2,_3);if(!_4)return true;if(this.dateIsDisabled(_4)){return true}
this.dateClick(_4.getFullYear(),_4.getMonth(),_4.getDate())},isc.A.dateClick=function isc_DateGrid_dateClick(_1,_2,_3){},isc.A.getRecordWeekNumber=function isc_DateGrid_getRecordWeekNumber(_1){if(!_1)return-1;return this.showFiscalWeek?_1.fiscalWeek:_1.calendarWeek},isc.A.isSelectedWeek=function isc_DateGrid_isSelectedWeek(_1){return this.getRecordWeekNumber(_1)==this.selectedWeek},isc.A.cellSelectionChanged=function isc_DateGrid_cellSelectionChanged(_1){var _2=this.getCellSelection();for(var i=0;i<_1.length;i++){var _4=_1[i];if(_2.cellIsSelected(_4[0],_4[1])){var _5=this.getRecordWeekNumber(this.getRecord(_4[0]));if(this.selectedWeek!=_5){this.setSelectedWeek(_5)}
return}}
return},isc.A.setSelectedWeek=function isc_DateGrid_setSelectedWeek(_1){this.selectedWeek=_1;this.markForRedraw();this.selectedWeekChanged(this.selectedWeek)},isc.A.selectedWeekChanged=function isc_DateGrid_selectedWeekChanged(_1){},isc.A.getWorkingMonth=function isc_DateGrid_getWorkingMonth(){return this.workingMonth},isc.A.getSelectedDate=function isc_DateGrid_getSelectedDate(){return null},isc.A.disableMarkedDates=function isc_DateGrid_disableMarkedDates(){this.disabledDateStrings=[];if(this.disabledDates&&this.disabledDates.length>0){for(var i=0;i<this.disabledDates.length;i++){this.disabledDateStrings[i]=this.disabledDates[i].toShortDate()}}},isc.A.dateIsDisabled=function isc_DateGrid_dateIsDisabled(_1){if(!_1)return;if(this.disableWeekends&&this.dateIsWeekend(_1))return true;var _2=this.disabledDateStrings.contains(_1.toShortDate());return _2},isc.A.getCellDate=function isc_DateGrid_getCellDate(_1,_2,_3){if(_3<this.dateColumnOffset||!this.getField(_3))return;var _4=_1.rowStartDate,_5=isc.DateUtil.createLogicalDate(_4.getFullYear(),_4.getMonth(),_4.getDate()+(_3-this.dateColumnOffset));return _5},isc.A.selectDateCell=function isc_DateGrid_selectDateCell(_1){var _2=this.getCellSelection(),_3=this.getDateCell(_1);if(!_3)return;if(_3.colNum!=null)_2.selectSingleCell(_3.rowNum,_3.colNum);this.setSelectedWeek(this.getRecordWeekNumber(_3.record))},isc.A.getDateCell=function isc_DateGrid_getDateCell(_1){var _2=this.getCellSelection(),_3=this.data;if(_1&&_3&&_3.length>0){var _4=this.showWeekends==false?5:7;for(var i=0;i<_3.length;i++){var _6=_3[i];if(_6){for(var j=0;j<_4;j++){var _8=_1.getDay();if(isc.DateUtil.compareLogicalDates(_6[this.shortDayNames[_1.getDay()]],_1)==0)
{var _9=this.shortDayNames[_1.getDay()],_10=this.getField(_9),_11=_10?this.getFieldNum(_10.name):null;if(_10){return{rowNum:i,colNum:_11,record:_6}}
break}}}}}},isc.A.shouldDisableDate=function isc_DateGrid_shouldDisableDate(_1){var _2=this.dateIsDisabled(_1);return _2},isc.A.setStartDate=function isc_DateGrid_setStartDate(_1){var _2=_1.getFullYear(),_3=_1.getMonth(),_4=_1.getDate(),_5=isc.DateUtil.createLogicalDate(_2,_3,1),_6=_5.getDay();var _7=_5.duplicate();var _8=0;if(_6>this.firstDayOfWeek){_8=(_6-this.firstDayOfWeek)*-1}else if(_6<this.firstDayOfWeek){_8=(this.firstDayOfWeek-_6)-7}
var _9=isc.DateUtil.createLogicalDate(_2,_3,1+_8,0);this.workingMonth=_1.getMonth();this.startDate=_9;this.buildCalendarData();var _10=this.$148m-this.headerHeight;var _11=Math.max(this.cellHeight,Math.floor(_10/5));this.setCellHeight(_11);this.markForRedraw()},isc.A.refreshUI=function isc_DateGrid_refreshUI(_1){_1=_1||this.startDate;if(_1)this.setStartDate(_1)},isc.A.getFieldList=function isc_DateGrid_getFieldList(){var _1=[];this.dateColumnOffset=0;if(this.showFiscalYear){_1.add({name:"fiscalYear",type:"number",title:this.fiscalYearFieldTitle,width:30,overflow:"visible",align:"center",cellAlign:"center",showRollOver:false,showDown:false,baseStyle:this.baseFiscalYearStyle,headerBaseStyle:this.fiscalYearHeaderStyle||this.baseFiscalYearStyle});this.dateColumnOffset++}
if(this.showFiscalWeek){_1.add({name:"fiscalWeek",type:"number",title:this.weekFieldTitle,width:25,overflow:"visible",align:"center",showRollOver:false,showDown:false,baseStyle:this.baseWeekStyle,headerBaseStyle:this.weekHeaderStyle||this.baseWeekStyle});this.dateColumnOffset++}
if(this.showCalendarWeek){_1.add({name:"calendarWeek",type:"number",title:this.weekFieldTitle,width:25,overflow:"visible",align:"center",showRollOver:false,showDown:false,baseStyle:this.baseWeekStyle,headerBaseStyle:this.weekHeaderStyle||this.baseWeekStyle});this.dateColumnOffset++}
var _2=this.getWeekendDays(),_3=isc.Canvas.measureContent;var _4=_3(this.shortDayTitles.join("<br>"),this.headerBaseStyle),_5=Math.max(_3("00",this.baseWeekDayStyle),_3("33",this.baseWeekDayStyle));var _6=Math.max(Math.max(_4,_5),this.minFieldWidth);for(var i=0;i<this.shortDayNames.length;i++){var _8=i+this.firstDayOfWeek;if(_8>6)_8-=7;if(!this.showWeekends&&_2.contains(_8))continue;var _9={name:this.shortDayNames[_8],title:this.shortDayTitles[_8],type:"text",align:"center",width:this.dateFieldWidth||_6,overflow:"visible",padding:0,isDateField:true,dateOffset:i,showRollOver:false,showDown:false};if(_2.contains(_8)){_9.isWeekend=true;_9.baseStyle=this.baseWeekendStyle;_9.headerBaseStyle=this.weekendHeaderStyle}else{_9.isWeekend=false;_9.baseStyle=this.baseWeekdayStyle;_9.headerBaseStyle=this.headerBaseStyle}
_1.add(_9)}
this.disableMarkedDates();return _1},isc.A.getWeekendDays=function isc_DateGrid_getWeekendDays(){return this.weekendDays||isc.DateUtil.getWeekendDays()},isc.A.dateIsWeekend=function isc_DateGrid_dateIsWeekend(_1){if(!_1)return false;return this.getWeekendDays().contains(_1.getDay())},isc.A.buildCalendarData=function isc_DateGrid_buildCalendarData(_1){if(_1)this.startDate=_1;_1=this.startDate;var _2=[],_3=_1,_4=this.startDate.getMonth(),_5=(_4==11||this.workingMonth==11),_6=isc.DateUtil.createLogicalDate(_1.getFullYear()+(_5?1:0),(this.workingMonth==11?0:this.workingMonth+1),1);var _7=(_6.getTime()-_3.getTime())/1000/60/60/24,_8=_7/7;var _9=Math.floor(_8)+(_7%7>0?1:0);for(var i=0;i<=_9;i++){var _11=isc.DateUtil.createLogicalDate(_3.getFullYear(),_3.getMonth(),_3.getDate()+(i*7));if(i==_9&&_11.getMonth()!=this.workingMonth){break}
_2.add(this.getWeekRecord(_11))}
if(!this.isDrawn()&&(this.creator&&this.creator.isDrawn()))this.draw();this.setData(_2);this.setFields(this.getFieldList());this.selectDateCell(this.getSelectedDate())},isc.A.getFiscalCalendar=function isc_DateGrid_getFiscalCalendar(){return this.fiscalCalendar||isc.DateUtil.getFiscalCalendar()},isc.A.getWeekRecord=function isc_DateGrid_getWeekRecord(_1){var _2=this.getFiscalCalendar(),_3=_1.getFiscalYear(_2),_4=isc.DateUtil.dateAdd(_1.duplicate(),"d",6);if(_1.logicalDate)_4.logicalDate=true;var _5=isc.DateUtil.dateAdd(_1.duplicate(),"d",4);var _6={rowStartDate:_1,rowEndDate:_4.duplicate(),fiscalYear:_3.fiscalYear,fiscalYearEnd:_4.getFiscalYear(_2).fiscalYear,fiscalWeek:_1.getFiscalWeek(_2,this.firstDayOfWeek),fiscalWeekEnd:_4.getFiscalWeek(_2,this.firstDayOfWeek),calendarWeek:_5.getWeek(this.firstDayOfWeek),weekDate:_5};if(_6.fiscalWeek!=_6.fiscalWeekEnd){var _7=false,_8=false;if(_6.fiscalYear!=_6.fiscalYearEnd){if(!this.alwaysShowFirstFiscalWeek){var _9=Date.getFiscalStartDate(_4,_2).getDay(),_10=_9-this.firstDayOfWeek;if(_10<0)_10+=6;if(_10<3)_7=true}else _7=true}
if(!_7){var _11=Date.getFiscalStartDate(_1,_2).getDay(),_10=_11-this.firstDayOfWeek;if(_10<0)_10+=6;if(_10>0&&_10<3)_8=true}
if(_7){_6.fiscalYear=_6.fiscalYearEnd;_6.fiscalWeek=1}else if(_8){_6.fiscalWeek+=1}}
var _12=_1.getFullYear(),_13=_1.getMonth(),_14=this.getWeekendDays();for(var i=0;i<7;i++){var _16=isc.DateUtil.createLogicalDate(_12,_13,_1.getDate()+i,0);var _17=this.shortDayNames[_16.getDay()];_6[_17]=_16}
return _6});isc.B._maxIndex=isc.C+29}
isc.ClassFactory.defineClass("DateChooser","VLayout");isc.A=isc.DateChooser.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.height=1;isc.A.overflow="visible";isc.A.showNavigationLayout=true;isc.A.navigationLayoutConstructor="HLayout";isc.A.navigationLayoutDefaults={width:1,height:1,layoutAlign:"center",align:"center"};isc.A.showFiscalYearChooser=false;isc.A.fiscalYearChooserButtonDefaults={minWidth:30,autoFit:true,click:function(){this.creator.showFiscalYearMenu()},autoParent:"navigationLayout",align:"center"};isc.A.showWeekChooser=false;isc.A.weekChooserButtonDefaults={minWidth:25,autoFit:true,click:function(){this.creator.showWeekMenu()},autoParent:"navigationLayout",align:"center"};isc.A.previousYearButtonDefaults={width:20,click:function(){this.creator.showPrevYear()},autoParent:"navigationLayout",align:"center",noDoubleClicks:true};isc.A.previousMonthButtonDefaults={width:20,click:function(){this.creator.showPrevMonth()},autoParent:"navigationLayout",align:"center",noDoubleClicks:true};isc.A.monthChooserButtonDefaults={click:function(){this.creator.showMonthMenu()},autoParent:"navigationLayout",align:"center"};isc.A.yearChooserButtonDefaults={click:function(){this.creator.showYearMenu()},autoParent:"navigationLayout",align:"center"};isc.A.nextMonthButtonDefaults={width:20,click:function(){this.creator.showNextMonth()},autoParent:"navigationLayout",align:"center",noDoubleClicks:true};isc.A.nextYearButtonDefaults={width:20,click:function(){this.creator.showNextYear()},autoParent:"navigationLayout",align:"center",noDoubleClicks:true};isc.A.buttonLayoutConstructor="HLayout";isc.A.buttonLayoutDefaults={width:1,height:1,overflow:"visible",layoutAlign:"center",extraSpace:2};isc.A.dateGridDefaults={_constructor:"DateGrid",autoDraw:false,layoutAlign:"center",dateClick:function(_1,_2,_3){this.creator.dateClick(_1,_2,_3)},getSelectedDate:function(){return this.creator.chosenDate},selectedWeekChanged:function(_1){this.creator.updateWeekChooser(_1,true)}};isc.A.bottomButtonConstructor="IButton";isc.A.todayButtonDefaults={padding:2,autoFit:true,autoParent:"buttonLayout",click:function(){this.creator.todayClick()}};isc.A.cancelButtonDefaults={padding:2,autoFit:true,autoParent:"buttonLayout",click:function(){this.creator.cancelClick()}};isc.A.applyButtonDefaults={padding:2,autoFit:true,autoParent:"buttonLayout",click:function(){this.creator.applyClick()}};isc.A.navigationLayoutHeight=20;isc.A.showYearButtons=true;isc.A.showYearChooser=true;isc.A.showMonthButtons=true;isc.A.showMonthChooser=true;isc.A.skinImgDir="images/common/";isc.A.prevYearIcon="[SKIN]doubleArrow_left.gif";isc.A.prevYearIconWidth=14;isc.A.prevYearIconHeight=7;isc.A.prevMonthIcon="[SKIN]arrow_left.gif";isc.A.prevMonthIconWidth=7;isc.A.prevMonthIconHeight=7;isc.A.nextYearIcon="[SKIN]doubleArrow_right.gif";isc.A.nextYearIconWidth=14;isc.A.nextYearIconHeight=7;isc.A.nextMonthIcon="[SKIN]arrow_right.gif";isc.A.nextMonthIconWidth=7;isc.A.nextMonthIconHeight=7;isc.A.showDoubleYearIcon=true;isc.A.yearMenuStyle="dateChooserYearMenu";isc.A.startYear=1995;isc.A.endYear=2020;isc.A.monthMenuStyle="dateChooserMonthMenu";isc.A.weekMenuStyle="dateChooserWeekMenu";isc.A.buttonLayoutControls=["todayButton","cancelButton","applyButton"];isc.A.showTodayButton=true;isc.A.showCancelButton=false;isc.A.todayButtonTitle="Today";isc.A.cancelButtonTitle="Cancel";isc.A.applyButtonTitle="Apply";isc.A.disableWeekends=false;isc.A.showWeekends=true;isc.A.firstDayOfWeek=0;isc.A.year=new Date().getFullYear();isc.A.month=new Date().getMonth();isc.A.chosenDate=new Date();isc.A.baseButtonStyle="dateChooserButton";isc.A.baseWeekdayStyle="dateChooserWeekday";isc.A.baseWeekendStyle="dateChooserWeekend";isc.A.baseFiscalYearStyle="dateChooserFiscalYearCell";isc.A.baseWeekStyle="dateChooserWeekCell";isc.A.disabledWeekdayStyle="dateChooserDisabledWeekday";isc.A.disabledWeekendStyle="dateChooserDisabledWeekend";isc.A.selectedWeekStyle="dateChooserSelectedWeek";isc.A.alternateStyleSuffix="Dark";isc.A.headerStyle="dateChooserButtonDisabled";isc.A.navButtonConstructor="IButton";isc.A.useBackMask=true;isc.A.canFocus=true;isc.A.useFirstDayOfFiscalWeek=true;isc.A.timeLayoutConstructor="HLayout";isc.A.timeLayoutDefaults={width:1,height:1,overflow:"visible",layoutAlign:"center",extraSpace:1};isc.A.timeFormDefaults={_constructor:"DynamicForm",width:1,overflow:"visible",layoutAlign:"center"};isc.A.closeOnEscapeKeypress=false;isc.A.timeItemDefaults={name:"time",editorType:"TimeItem",useTextField:false,showTitle:false};isc.A.timeItemTitle="Time";isc.A.use24HourTime=true;isc.A.fiscalYearFieldTitle="Year";isc.A.weekFieldTitle="Wk";isc.B.push(isc.A.getWeekendDays=function isc_DateChooser_getWeekendDays(){return this.weekendDays||isc.DateUtil.getWeekendDays()});isc.B._maxIndex=isc.C+1;isc.A=isc.DateChooser.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.showControlPropertyMap={todayButton:"showTodaybutton",cancelButton:"showCancelButton",applyButton:"showApplyButton"};isc.A.$880="body";isc.A.$881="header";isc.A.dayNameLength=2;isc.A.monthMenuFormat="MMM";isc.B.push(isc.A.initWidget=function isc_DateChooser_initWidget(){if(this.showFiscalYearChooser&&this.useFirstDayOfFiscalWeek){var _1=Date.getFiscalStartDate(new Date(),this.getFiscalCalendar());this.firstDayOfWeek=_1.getDay()}
if(this.headerHeight!=null)this.navigationLayoutHeight=this.headerHeight;if(this.showNavigationLayout!=false){this.addAutoChild("navigationLayout",{},this.navigationLayoutConstructor);this.addMember(this.navigationLayout);this.addAutoChild("fiscalYearChooserButton",{baseStyle:(this.baseNavButtonStyle||this.baseButtonStyle),title:this.chosenDate.getFiscalYear(this.getFiscalCalendar()).fiscalYear,autoDraw:false},this.navButtonConstructor);this.addAutoChild("weekChooserButton",{baseStyle:(this.baseNavButtonStyle||this.baseButtonStyle),title:this.showFiscalYearChooser?this.chosenDate.getFiscalWeek(this.getFiscalCalendar()):this.chosenDate.getWeek(this.firstDayOfWeek),autoDraw:false},this.navButtonConstructor);if(this.showYearButtons){this.addAutoChild("previousYearButton",{baseStyle:(this.baseNavButtonStyle||this.baseButtonStyle),title:this.getPreviousYearIconHTML()},this.navButtonConstructor)}
if(this.showMonthButtons){this.addAutoChild("previousMonthButton",{baseStyle:(this.baseNavButtonStyle||this.baseButtonStyle),title:this.getPreviousMonthIconHTML()},this.navButtonConstructor)}
if(this.showMonthChooser!=false){var _2=this.monthChooserButtonDefaults.width,_3=this.monthChooserButtonDefaults.minWidth,_4=this.$180r();this.addAutoChild("monthChooserButton",isc.addProperties({},this.monthChooserButtonDefaults,{baseStyle:(this.baseNavButtonStyle||this.baseButtonStyle),title:this.chosenDate.getShortMonthName(),width:_2||_4,minWidth:_3||_2||_4},this.monthChooserButtonProperties),this.navButtonConstructor)}
if(this.showYearChooser!=false){var _2=this.yearChooserButtonDefaults.width,_3=this.yearChooserButtonDefaults.minWidth,_4=this.$180s();this.addAutoChild("yearChooserButton",isc.addProperties({},this.yearChooserButtonDefaults,{baseStyle:(this.baseNavButtonStyle||this.baseButtonStyle),title:this.chosenDate.getFullYear(),width:_2||_4,minWidth:_3||_2||_4},this.yearChooserButtonProperties),this.navButtonConstructor)}
if(this.showMonthButtons){this.addAutoChild("nextMonthButton",{baseStyle:(this.baseNavButtonStyle||this.baseButtonStyle),title:this.getNextMonthIconHTML()},this.navButtonConstructor)}
if(this.showYearButtons){this.addAutoChild("nextYearButton",{baseStyle:(this.baseNavButtonStyle||this.baseButtonStyle),title:this.getNextYearIconHTML()},this.navButtonConstructor)}}
var _5=isc.addProperties({},{title:this.timeItemTitle,use24HourTime:this.use24HourTime,showSecondItem:!!this.showSecondItem},this.timeItemDefaults,this.timeItemProperties,{name:"time"});this.addAutoChild("timeLayout");this.addAutoChild("timeForm",{items:[_5]});this.timeLayout.addMember(this.timeForm);this.addMember(this.timeLayout);this.timeLayout.hide();if(this.showTodayButton||this.showCancelButton){var _6={baseStyle:this.baseBottomButtonStyle||this.baseButtonStyle};if(this.todayButtonHeight!=null)_6.height=this.todayButtonHeight;this.todayButtonDefaults.title=this.todayButtonTitle;if(_6.height)this.todayButtonDefaults.height=_6.height;this.cancelButtonDefaults.title=this.cancelButtonTitle;if(_6.height)this.cancelButtonDefaults.height=_6.height;this.applyButtonDefaults.title=this.applyButtonTitle;if(_6.height)this.applyButtonDefaults.height=_6.height;this.makeButtonLayout(_6)}
if(this.chosenDate){if(this.showTimeItem){this.chosenTime=isc.DateUtil.getLogicalTimeOnly(this.chosenDate)}
this.chosenDate=isc.DateUtil.getLogicalDateOnly(this.chosenDate);this.year=this.chosenDate.getFullYear();this.month=this.chosenDate.getMonth();this.day=this.chosenDate.getDate()}
this.Super("initWidget",arguments);this.updateUI()},isc.A.shouldShowButtonLayoutControl=function isc_DateChooser_shouldShowButtonLayoutControl(_1){var _2=this.showControlPropertyMap[_1];if(_2==null){this.showControlPropertyMap[_1]=_2="show"+_1.substring(0,1).toUpperCase+_1.substring(1)}
return this[_2]!=false},isc.A.makeButtonLayout=function isc_DateChooser_makeButtonLayout(_1){this.addAutoChild("buttonLayout",null,this.buttonLayoutConstructor);for(var i=0;i<this.buttonLayoutControls.length;i++){var _3=this.buttonLayoutControls[i],_4=null;if(isc.isA.Canvas(_3)){_4=_3}else if(isc.isA.String(_3)){if(!this.shouldShowButtonLayoutControl(_3))continue;_4=this.addAutoChild(_3,_1,this.bottomButtonConstructor)}
if(_3!=null&&_4==null){_4=this.createCanvas(_3)}
this.buttonLayout.addMember(_4)}},isc.A.draw=function isc_DateChooser_draw(){this.Super("draw",arguments);if(!this.dateGrid){var _1=0;if(this.navigationLayout&&this.navigationLayout.isVisible()){_1+=this.navigationLayout.getVisibleHeight()}
if(this.timeLayout&&this.timeLayout.isVisible()){_1+=this.timeLayout.getVisibleHeight();_1+=this.timeLayout.extraSpace||0}
if(this.buttonLayout&&this.buttonLayout.isVisible()){_1+=this.buttonLayout.getVisibleHeight();_1+=this.buttonLayout.extraSpace||0}
var _2=(this.border||"").indexOf("px");if(_2>=0){var _3=parseInt(this.border.substring(0,_2+1));_1+=(_3*2)}
var _4={startDate:this.chosenDate,dayNameLength:this.dayNameLength,showFiscalYear:this.showFiscalYearChooser,fiscalYearFieldTitle:this.fiscalYearFieldTitle,showFiscalWeek:this.showFiscalYearChooser&&this.showWeekChooser,showCalendarWeek:!this.showFiscalYearChooser&&this.showWeekChooser,weekFieldTitle:this.weekFieldTitle,disabledDates:this.disabledDates,firstDayOfWeek:this.firstDayOfWeek,headerBaseStyle:this.headerStyle,weekendHeaderStyle:this.weekendHeaderStyle||this.headerStyle,baseFiscalYearStyle:this.baseFiscalYearStyle,fiscalYearHeaderStyle:this.fiscalYearHeaderStyle||this.baseFiscalYearStyle,baseWeekStyle:this.baseWeekStyle,weekHeaderStyle:this.weekHeaderStyle||this.baseWeekStyle,baseWeekdayStyle:this.baseWeekdayStyle||this.baseButtonStyle,baseWeekendStyle:this.baseWeekendStyle||this.baseWeekdayStyle||this.baseButtonStyle,alternateRecordStyles:this.alternateWeekStyles,disabledWeekdayStyle:this.disabledWeekdayStyle,disabledWeekendStyle:this.disabledWeekendStyle,selectedWeekStyle:this.selectedWeekStyle,fiscalCalendar:this.getFiscalCalendar(),showWeekends:this.showWeekends,disableWeekends:this.disableWeekends,weekendDays:this.getWeekendDays(),locatorParent:this,height:"*",$148m:this.getVisibleHeight()-_1,startDate:this.getData()};if(this.borderCalendar!=null){_4.border=0;_4.showHeaderShadow=false;_4.layoutTopMargin=5;_4.height=191}
this.addAutoChild("dateGrid",_4);this.addMember(this.dateGrid,this.navigationLayout?1:0)}},isc.A.getTimeItem=function isc_DateChooser_getTimeItem(){if(this.timeForm)return this.timeForm.getItem("time")},isc.A.recreateTimeItem=function isc_DateChooser_recreateTimeItem(_1){var _2=isc.addProperties({},{title:this.timeItemTitle,use24HourTime:this.use24HourTime,showSecondItem:!!this.showSecondItem},this.timeItemDefaults,this.timeItemProperties,{name:"time",value:_1});this.timeForm.setItems([_2])},isc.A.resized=function isc_DateChooser_resized(){this.placeNear(this.getLeft(),this.getTop())},isc.A.handleKeyPress=function isc_DateChooser_handleKeyPress(){var _1=this.Super("handleKeyPress",arguments);if(_1!=false){if((this.closeOnEscapeKeypress)&&("Escape"==isc.EH.getKey())){this.cancelClick()}}},isc.A.getPreviousYearIconHTML=function isc_DateChooser_getPreviousYearIconHTML(){var _1,_2=new Date(this.year,this.month,1),_3=_2.getFullYear()==9999;if(this.showDoubleYearIcon){var _4=this.getPreviousMonthIconHTML();_1=_3?"&nbsp;":"<NOBR>"+_4+_4+"<\/NOBR>"}else{var _5=this.isRTL()?this.prevYearIconRTL||this.nextYearIcon:this.prevYearIcon;_1=_3?"&nbsp;":this.imgHTML(_5,this.prevYearIconWidth,this.prevYearIconHeight)}
return _1},isc.A.getPreviousMonthIconHTML=function isc_DateChooser_getPreviousMonthIconHTML(){var _1=this.isRTL()?this.prevMonthIconRTL||this.nextMonthIcon:this.prevMonthIcon,_2=this.imgHTML(_1,this.prevMonthIconWidth,this.prevMonthIconHeight);return _2},isc.A.getNextMonthIconHTML=function isc_DateChooser_getNextMonthIconHTML(){var _1=this.isRTL()?this.nextMonthIconRTL||this.prevMonthIcon:this.nextMonthIcon,_2=this.imgHTML(_1,this.nextMonthIconWidth,this.nextMonthIconHeight);return _2},isc.A.getNextYearIconHTML=function isc_DateChooser_getNextYearIconHTML(){var _1,_2=new Date(this.year,this.month,1),_3=_2.getFullYear()==9999;if(this.showDoubleYearIcon){var _4=this.getNextMonthIconHTML();_1=_3?"&nbsp;":"<NOBR>"+_4+_4+"<\/NOBR>"}else{var _5=this.isRTL()?this.nextYearIconRTL||this.prevYearIcon:this.nextYearIcon;_1=_3?"&nbsp;":this.imgHTML(_5,this.nextYearIconWidth,this.nextYearIconHeight)}
return _1},isc.A.show=function isc_DateChooser_show(){var _1=this.Super("show",arguments);if(this.autoClose){this.showClickMask(this.getID()+".close();",true,this);this.bringToFront()}},isc.A.setData=function isc_DateChooser_setData(_1){if(!isc.isA.Date(_1))_1=new Date();var _2="datetime";if(this.callingFormItem){_2=this.callingFormItem.type}
var _3=isc.DateUtil.getLogicalDateOnly(_1),_4=isc.DateUtil.getLogicalTimeOnly(_1);this.year=_3.getFullYear();this.month=_3.getMonth();this.day=_3.getDate();this.chosenDate=_3;this.chosenTime=_4;var _5=this.getTimeItem();if(_5)_5.setValue(this.chosenTime);this.updateUI();if(this.dateGrid)this.dateGrid.setStartDate(this.chosenDate)},isc.A.updateGridData=function isc_DateChooser_updateGridData(_1){if(!this.dateGrid)return;_1.setDate(1);var _2=isc.DateUtil.$100e(_1),_3=_2.startDate;this.dateGrid.showWeekends=this.showWeekends;this.dateGrid.showFiscalYear=this.showFiscalYearChooser;this.dateGrid.showFiscalWeek=this.showFiscalYearChooser&&this.showWeekChooser;this.dateGrid.showCalendarWeek=!this.showFiscalYearChooser&&this.showWeekChooser;if(this.showFiscalYearChooser){if(this.useFirstDayOfFiscalWeek){var _4=isc.DateUtil.getFiscalYear(_2.fiscalYear+1);if(_4.year<_2.fiscalYear){_4=isc.DateUtil.getFiscalYear(_4.fiscalYear+1)}
this.dateGrid.firstDayOfWeek=this.firstDayOfWeek=_4.startDate.getDay()}}
this.dateGrid.refreshUI(_1)},isc.A.getData=function isc_DateChooser_getData(){var _1=this.chosenDate.duplicate();if(this.showTimeItem){_1=isc.DateUtil.combineLogicalDateAndTime(_1,this.chosenTime)}
return _1},isc.A.redraw=function isc_DateChooser_redraw(){this.Super("redraw",arguments);this.updateUI()},isc.A.getDayNames=function isc_DateChooser_getDayNames(){if(isc.DateChooser.$8w==null){isc.DateChooser.$8w=[isc.DateUtil.getShortDayNames(1),isc.DateUtil.getShortDayNames(2),isc.DateUtil.getShortDayNames(3)]}
return isc.DateChooser.$8w[this.dayNameLength-1]},isc.A.getDayCellButtonHTML=function isc_DateChooser_getDayCellButtonHTML(_1,_2,_3){if(_1==null)
return this.getCellButtonHTML("&nbsp;",null,_2,false,false,isc.Canvas.CENTER);var _4=this.chosenDate&&(isc.DateUtil.compareLogicalDates(_1,this.chosenDate)==0),_5=(_1.getMonth()!=this.month);var _6="dateFromId",_7=_1.getFullYear()+"_"+_1.getMonth()+"_"+_1.getDate();if(this.disableWeekends&&this.getWeekendDays().contains(_1.getDay())){_5=true;_6=null}
return this.getCellButtonHTML(_1.getDate(),_2,_4,_5,isc.Canvas.CENTER,null,_6,_7)},isc.A.dateIsSelected=function isc_DateChooser_dateIsSelected(_1){return null},isc.A.showPrevMonth=function isc_DateChooser_showPrevMonth(){if(--this.month==-1){this.month=11;this.year--}
this.updateUI()},isc.A.showNextMonth=function isc_DateChooser_showNextMonth(){if(++this.month==12){this.month=0;this.year++}
this.updateUI()},isc.A.updateHeader=function isc_DateChooser_updateHeader(_1,_2){if(!this.showNavigationLayout&&this.navigationLayout){this.navigationLayout.hide()}else if(this.showNavigationLayout){this.navigationLayout.show();var _3=this.navigationLayout.members;if(this.weekChooserButton){if(this.showWeekChooser&&!_3.contains(this.weekChooserButton)){this.navigationLayout.addMember(this.weekChooserButton,0);this.weekChooserButton.show()}else if(!this.showWeekChooser&&_3.contains(this.weekChooserButton)){this.navigationLayout.removeMember(this.weekChooserButton);this.weekChooserButton.hide()}
this.updateWeekChooser(_1!=null?_1:(this.fiscalYearChooserButton?_2.getFiscalWeek(this.getFiscalCalendar()):new Date(_2.getTime()+(4*86400000)).getWeek(this.firstDayOfWeek)))}
if(this.fiscalYearChooserButton){if(this.showFiscalYearChooser&&!_3.contains(this.fiscalYearChooserButton)){this.navigationLayout.addMember(this.fiscalYearChooserButton,0);this.fiscalYearChooserButton.show()}else if(!this.showFiscalYearChooser&&_3.contains(this.fiscalYearChooserButton)){this.navigationLayout.removeMember(this.fiscalYearChooserButton);this.fiscalYearChooserButton.hide()}
this.fiscalYearChooserButton.setTitle(""+_2.getFiscalYear(this.getFiscalCalendar()).fiscalYear)}
if(this.borderCalendar!=null)this.monthChooserButton.setTitle(_2.getMonthName());else this.monthChooserButton.setTitle(_2.getShortMonthName());this.yearChooserButton.setTitle(""+this.getHeaderYearTitle(this.year));var _4=this.startYear&&this.startYear==_2.getFullYear(),_5=this.endYear&&this.endYear==_2.getFullYear();this.previousYearButton.setDisabled(_4);this.previousMonthButton.setDisabled(_4&&_2.getMonth()==0);this.nextMonthButton.setDisabled(_5&&_2.getMonth()==11);this.nextYearButton.setDisabled(_5)}},isc.A.updateUI=function isc_DateChooser_updateUI(_1){var _2=new Date(this.year,this.month,this.day);if(_2.getMonth()>this.month)_2=isc.DateUtil.getEndOf(new Date(this.year,this.month,1),"M",true);this.updateHeader(_1,_2);if(!this.showTimeItem&&this.timeForm){this.timeLayout.hide();if(this.applyButton)this.applyButton.hide()}else if(this.showTimeItem){this.recreateTimeItem(this.chosenTime);this.timeLayout.show();if(this.applyButton){this.applyButton.show();if(this.timeLayoutIsVisibleWidth){this.setWidth(this.timeLayoutIsVisibleWidth);this.buttonLayout.setBorder(0);if(this.dateGrid)this.dateGrid.setMinFieldWidth(this.timeLayoutIsVisibleMinFieldWidth)}}}
this.updateGridData(_2)},isc.A.updateWeekChooser=function isc_DateChooser_updateWeekChooser(_1,_2){if(this.weekChooserButton){this.weekChooserButton.setTitle(""+_1);if(!_2&&this.dateGrid)this.dateGrid.setSelectedWeek(_1)}},isc.A.showMonth=function isc_DateChooser_showMonth(_1){this.month=_1;if(this.monthMenu)this.monthMenu.hide();this.bringToFront();this.updateUI()},isc.A.getFiscalCalendar=function isc_DateChooser_getFiscalCalendar(){return this.fiscalCalendar||isc.DateUtil.getFiscalCalendar()},isc.A.setFiscalCalendar=function isc_DateChooser_setFiscalCalendar(_1){this.fiscalCalendar=_1},isc.A.showWeek=function isc_DateChooser_showWeek(_1){if(this.fiscalYearChooserButton){var _2=isc.DateUtil.createLogicalDate(this.year,this.month,this.chosenDate.getDate());var _3=this.getFiscalCalendar(),_4=Date.getFiscalStartDate(_2),_5=new Date(_4.getFullYear(),_3.defaultMonth,_3.defaultDate+(7*_1))}else{_5=new Date(this.year,0,1+(7*_1))}
this.year=_5.getFullYear();this.month=_5.getMonth();if(this.weekMenu)this.weekMenu.hide();this.bringToFront();this.updateUI(_1)},isc.A.getMonthText=function isc_DateChooser_getMonthText(_1){var _2=isc.DateUtil.format(_1,this.monthMenuFormat);return _2},isc.A.$180t=function isc_DateChooser__getMonthChooserTitles(){var _1=isc.Date.createLogicalDate(2001,0,1);var _2=[];for(var i=0;i<12;i++){_1.setMonth(i);_2.add(this.getMonthText(_1))}
return _2},isc.A.$180r=function isc_DateChooser__getMonthChooserButtonWidth(){var _1=this.$180t(),_2=(this.baseNavButtonStyle||this.baseButtonStyle)+"Over",_3=isc.Element.$yp(_2)*2,_4=isc.Canvas.measureContent(_1.join("<br>"),_2)+_3;this.$180u=_4;return this.$180u},isc.A.$180s=function isc_DateChooser__getYearChooserButtonWidth(){var _1=[];for(var i=this.startYear;i<=this.endYear;i++){_1.add(""+this.getYearTitle(i))}
var _3=(this.baseNavButtonStyle||this.baseButtonStyle)+"Over",_4=isc.Element.$yp(_3)*2,_5=isc.Canvas.measureContent(_1.join("<br>"),_3)+_4;this.$180v=_5;return this.$180v},isc.A.showMonthMenu=function isc_DateChooser_showMonthMenu(){if(!this.monthMenu){var _1=[[]],_2=isc.DateUtil.createLogicalDate(2001,0,1);for(var i=0;i<12;i++){_2.setMonth(i);_1[_1.length-1].add({contents:this.getMonthText(_2),eventPart:"showMonth",eventId:i});if((i+1)%3==0)_1.add([])}
this.monthMenu=isc.MonthChooser.newInstance({styleName:this.monthMenuStyle,left:this.monthChooserButton.getPageLeft()+5,top:this.getPageTop()+this.navigationLayoutHeight,width:Math.min(this.getVisibleWidth(),120),height:Math.min(this.getVisibleHeight()-this.navigationLayoutHeight,80),items:_1,visibility:isc.Canvas.HIDDEN,baseButtonStyle:this.baseButtonStyle,dateChooser:this});var _4=this.monthChooserButton.getPageLeft()-
((this.monthMenu.getWidth()-this.monthChooserButton.getWidth())/2);this.monthMenu.placeNear(Math.max(_4,0))}else{var _5=this.getPageTop()+this.navigationLayoutHeight,_6=Math.min(this.getVisibleWidth(),120),_7=Math.min(this.getVisibleHeight()-this.navigationLayoutHeight,80),_8=this.monthChooserButton.getWidth(),_4=this.monthChooserButton.getPageLeft()-((_6-_8)/2);this.monthMenu.resizeTo(_6,_7);this.monthMenu.placeNear(Math.max(_4,0),_5)}
this.monthMenu.showModal()},isc.A.showWeekMenu=function isc_DateChooser_showWeekMenu(){if(!this.weekMenu){var _1=[[]],_2=isc.DateUtil.createLogicalDate(2001,0,1);for(var i=1;i<53;i++){_1[_1.length-1].add({contents:""+i,eventPart:"showWeek",eventId:i});if((i)%7==0)_1.add([])}
this.weekMenu=isc.WeekChooser.newInstance({styleName:this.weekMenuStyle,left:this.weekChooserButton.getPageLeft()+5,top:this.getPageTop()+this.navigationLayoutHeight,width:Math.min(this.getVisibleWidth(),120),height:Math.min(this.getVisibleHeight()-this.navigationLayoutHeight,80),items:_1,visibility:isc.Canvas.HIDDEN,baseButtonStyle:this.baseButtonStyle,dateChooser:this});var _4=this.weekChooserButton.getPageLeft()-
((this.weekMenu.getWidth()-this.weekChooserButton.getWidth())/2);this.weekMenu.setPageLeft(Math.max(_4,0))}else{var _5=this.getPageTop()+this.navigationLayoutHeight,_6=Math.min(this.getVisibleWidth(),120),_7=Math.min(this.getVisibleHeight()-this.navigationLayoutHeight,80),_8=this.weekChooserButton.getWidth(),_4=this.weekChooserButton.getPageLeft()-((_6-_8)/2);this.weekMenu.setPageRect(Math.max(_4,0),_5,_6,_7)}
this.weekMenu.showModal()},isc.A.showPrevYear=function isc_DateChooser_showPrevYear(){this.year--;this.updateUI()},isc.A.showNextYear=function isc_DateChooser_showNextYear(){if(this.year<this.endYear){this.year++;this.updateUI()}},isc.A.showYear=function isc_DateChooser_showYear(_1){if(_1<this.startYear||_1>this.endYear)return;this.year=_1;if(this.yearMenu)this.yearMenu.hide();this.updateUI()},isc.A.showFiscalYear=function isc_DateChooser_showFiscalYear(_1){var f=isc.DateUtil.getFiscalYear(_1,this.getFiscalCalendar());this.year=f.year;this.month=f.month;if(this.yearMenu)this.yearMenu.hide();this.updateUI()},isc.A.showFiscalYearMenu=function isc_DateChooser_showFiscalYearMenu(){this.showYearMenu(true)},isc.A.showYearMenu=function isc_DateChooser_showYearMenu(_1){var _2=!_1?this.yearChooserButton:this.fiscalYearChooserButton;var _3=(this.endYear-this.startYear),_4=Math.round(_3/10)>3?Math.round(_3/10):3;var _5=[[]];for(var i=0;i<=(this.endYear-this.startYear);i++){var _7=i+this.startYear;_5[_5.length-1].add({contents:this.getYearTitle(_7),eventPart:"showYear",eventId:_7});if((i+1)%_4==0)_5.add([])}
if(!this.yearMenu){this.yearMenu=isc.YearChooser.newInstance({styleName:this.yearMenuStyle,top:this.getPageTop()+this.navigationLayoutHeight,width:Math.min(this.getVisibleWidth(),(40*_4)),height:Math.min(this.getVisibleHeight()-this.navigationLayoutHeight,80),items:_5,visibility:isc.Canvas.HIDDEN,baseButtonStyle:this.baseButtonStyle,dateChooser:this});var _8=_2.getPageLeft()-((this.yearMenu.getWidth()-_2.getWidth())/2);this.yearMenu.placeNear(Math.max(_8,0))}else{var _9=this.getPageTop()+this.navigationLayoutHeight,_10=Math.min(this.getVisibleWidth(),(40*_4)),_11=Math.min(this.getVisibleHeight()-this.navigationLayoutHeight,80),_12=_2.getWidth(),_8=_2.getPageLeft()-((_10-_12)/2);this.yearMenu.items=_5;this.yearMenu.resizeTo(_10,_11);this.yearMenu.placeNear(Math.max(_8,0),_9)}
var _13=_1;this.yearMenu.showYearClick=function(_14,_15){if(_13)this.dateChooser.showFiscalYear(parseInt(_15));else this.dateChooser.showYear(parseInt(_15))}
this.yearMenu.markForRedraw("Redraw to pick up any changes in yearItems");this.yearMenu.showModal()},isc.A.getYearTitle=function isc_DateChooser_getYearTitle(_1){return""+_1},isc.A.getHeaderYearTitle=function isc_DateChooser_getHeaderYearTitle(_1){return""+_1},isc.A.dateClick=function isc_DateChooser_dateClick(_1,_2,_3,_4,_5){var _6=this.chosenDate=isc.DateUtil.createLogicalDate(_1,_2,_3);var _7=this.year!=_1;if(_7)this.year=_1;if(_7||this.month!=_2)this.showMonth(_2);this.month=_2;this.year=_1;this.day=_3;if(_4)this.dateGrid.selectDateCell(_6);if(this.showTimeItem){this.chosenTime=this.getTimeItem().getValue();if(this.closeOnDateClick!=true&&_5!=true)return}
if(_5==false)return;this.dataChanged();if(window.dateClickCallback){if(isc.isA.String(window.dateClickCallback)){window.dateClickCallback=isc.$aq("date",window.dateClickCallback)}
window.dateClickCallback(_6)}
if(this.autoHide)this.hide();if(this.autoClose)this.close();return _6},isc.A.dataChanged=function isc_DateChooser_dataChanged(){},isc.A.cancelClick=function isc_DateChooser_cancelClick(){this.close()},isc.A.todayClick=function isc_DateChooser_todayClick(){var _1=new Date();this.dateClick(_1.getFullYear(),_1.getMonth(),_1.getDate(),true)},isc.A.applyClick=function isc_DateChooser_applyClick(){var _1=this.chosenDate.duplicate();this.dateClick(_1.getFullYear(),_1.getMonth(),_1.getDate(),true,true)},isc.A.close=function isc_DateChooser_close(){this.hideClickMask();if(this.yearMenu&&this.yearMenu.isVisible())this.yearMenu.hide();if(this.monthMenu&&this.monthMenu.isVisible())this.monthMenu.hide();if(this.isDrawn())this.clear()},isc.A.dateFromIdClick=function isc_DateChooser_dateFromIdClick(_1,_2){var _3=_2.split("_");if(_3.length!=3)return null;var _4=parseInt(_3[0]),_5=parseInt(_3[1]),_6=parseInt(_3[2]);return this.dateClick(_4,_5,_6)});isc.B._maxIndex=isc.C+50;isc.A=isc.DateChooser;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.getSharedDateChooser=function isc_c_DateChooser_getSharedDateChooser(_1){if(!this.$8x){this.$8x=this.create(_1,{_generated:true,autoHide:true,showCancelButton:true,closeOnEscapeKeypress:true});return this.$8x}
isc.addProperties(this.$8x,_1);return this.$8x});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("WeekChooser","ButtonTable");isc.A=isc.WeekChooser.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.showWeekClick=function isc_WeekChooser_showWeekClick(_1,_2){this.dateChooser.showWeek(parseInt(_2))});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("MonthChooser","ButtonTable");isc.A=isc.MonthChooser.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.showMonthClick=function isc_MonthChooser_showMonthClick(_1,_2){this.dateChooser.showMonth(parseInt(_2))});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("YearChooser","ButtonTable");isc.A=isc.YearChooser.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.showYearClick=function isc_YearChooser_showYearClick(_1,_2){this.dateChooser.showYear(parseInt(_2))});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("Slider",isc.Canvas);isc.A=isc.Slider;isc.A.DOWN="down";isc.A.UP="";isc.A.EVENTNAME="sliderMove";isc.A=isc.Slider.getPrototype();isc.A.title="Set Value";isc.A.length=200;isc.A.vertical=true;isc.A.thumbThickWidth=23;isc.A.thumbThinWidth=17;isc.A.trackWidth=7;isc.A.skinImgDir="images/Slider/";isc.A.thumbSrc="thumb.gif";isc.A.trackSrc="track.gif";isc.A.trackCapSize=6;isc.A.trackImageType=isc.Img.STRETCH;isc.A.showTitle=true;isc.A.showRange=true;isc.A.showValue=true;isc.A.labelWidth=50;isc.A.labelHeight=20;isc.A.labelSpacing=5;isc.A.titleSpacing=5;isc.A.titleStyle="sliderTitle";isc.A.rangeStyle="sliderRange";isc.A.valueStyle="sliderValue";isc.A.value=1;isc.A.minValue=1;isc.A.maxValue=100;isc.A.roundValues=true;isc.A.roundPrecision=1;isc.A.flipValues=false;isc.A.canFocus=true;isc.A.stepPercent=5;isc.A.animateThumbTime=250;isc.A.animateThumbAcceleration="slowStartandEnd";isc.A.valueChangedOnDrag=true;isc.A.valueChangedOnRelease=true;isc.A.valueChangedOnClick=true;isc.A=isc.Slider.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.rangeLabelDefaults={_constructor:"Label",wrap:false};isc.A.hValueLabelWidth=5;isc.A.valueLabelDefaults={_constructor:"Label",moveWithMaster:false,wrap:false,mouseUp:function(){return false}};isc.A.trackConstructor="StretchImg";isc.A.trackDefaults={showDisabled:true};isc.A.showActiveTrack=false;isc.A.activeTrackStyle='sliderTrackActive';isc.A.activeTrackDefaults={_constructor:'StatefulCanvas',contents:''};isc.A.extraThumbSpace=2;isc.A.touchExtraThumbSpace=8;isc.A.thumbDefaults={_constructor:"Img",overflow:"hidden",showDisabled:true,cursor:isc.Canvas.HAND,$jo:false,handleMouseDown:function(){this.setState(isc.Slider.DOWN)},handleMouseUp:function(){this.setState(isc.Slider.UP)},handleMouseOut:function(){var _1=this.ns.EH;if(!_1.dragging||this!==_1.dragTarget){this.setState(isc.Slider.UP)}},canDrag:true,dragAppearance:isc.EventHandler.NONE,dragStartDistance:0,handleDragStart:function(){var _1=this.ns.EH;_1.dragOffsetX=-1*(this.getPageLeft()-_1.mouseDownEvent.x);_1.dragOffsetY=-1*(this.getPageTop()-_1.mouseDownEvent.y);this.setState(isc.Slider.DOWN)},handleDragMove:function(){this.creator.$85()},handleDragStop:function(){this.setState(isc.Slider.UP);if(this.creator.valueChangedOnRelease){this.creator.handleValueChanged(this.creator.value)}},canFocus:true,tabIndex:-1,showTriggerArea:true};isc.B.push(isc.A.initWidget=function isc_Slider_initWidget(){this.Super("initWidget",arguments);if(!(this.minValue<=this.maxValue)){this.logWarn("Slider specified with minValue:"+this.minValue+", greater than maxValue:"+this.maxValue+" - reversing max and min value.");var _1=this.minValue;this.minValue=this.maxValue;this.maxValue=_1}
if(this.minValue!=null)this.minValue=this.$85d(this.minValue);if(this.maxValue!=null)this.maxValue=this.$85d(this.maxValue);this.setUpSize();this.$80();if(this.showTitle)this._titleLabel=this.addChild(this.$54());if(this.showRange){this.$50=this.addChild(this.$51("min"));this.$52=this.addChild(this.$51("max"))}
if(this.showValue){this._thumb.addPeer(this.$53());this._valueLabel.sendToBack();this.$81()}
this.setValue(this.value,!(this.animateThumbInit==true))},isc.A.setUpSize=function isc_Slider_setUpSize(){var _1=this.$pn,_2=this.$po,_3=this.$1494(),_4=this.$1495();if(this.vertical){if(_1==null){var _5=Math.max(_3,this.trackWidth);if(this.showValue)_5+=this.labelWidth+this.labelSpacing;if(this.showRange)_5+=this.labelWidth+this.labelSpacing;_5+=this.getHPadding();this.logInfo("defaulting width to "+_5+"px");this.setWidth(_5)}
if(_2==null){var _6=this.length;if(this.showTitle)_6+=this.labelHeight+this.labelSpacing;if(this.showValue&&(this.labelHeight>_4)){_6+=(this.labelHeight-_4)}
_6+=this.getVPadding();this.logInfo("no specified height on vertical Slider - defaulting to:"+_6+" based on slider.length of "+this.length);this.setHeight(_6)}else{this.length=this.getInnerContentHeight(false);if(this.showTitle)this.length-=(this.labelHeight+this.labelSpacing);if(this.showValue&&(this.labelHeight>_4)){this.length-=(this.labelHeight-_4)}
this.logInfo("setting slider track length to:"+this.length+", based on specified height")}}else{if(_2==null){var _6=Math.max(_3,this.trackWidth);if(this.showValue)_6+=this.labelHeight+this.labelSpacing;if(this.showRange)_6+=this.labelHeight+this.labelSpacing;_6+=this.getVPadding();this.logInfo("defaulting height to "+_6+"px");this.setHeight(_6)}
if(_1==null){var _5=(this.length+(this.showTitle?this.labelWidth+this.labelSpacing:0));if(this.showValue&&(this.labelWidth>_4)){_5+=(this.labelWidth-_4)}
_5+=this.getHPadding();this.logInfo("no specified width on horizontal Slider - defaulting to:"+_5+" based on slider.length of "+this.length);this.setWidth(_5)}else{this.length=this.getInnerContentWidth(false);if(this.showTitle)this.length-=(this.labelWidth+this.labelSpacing);if(this.showValue&&(this.hValueLabelWidth>_4)){this.length-=(this.hValueLabelWidth-_4)}
this.logInfo("setting slider track length to:"+this.length+", based on specified width")}}
this.$8y=this.length-_4;if(this.numValues&&this.numValues>1){this.$8z=this.$8y/(this.numValues-1)}},isc.A.resizeBy=function isc_Slider_resizeBy(_1,_2){this.Super("resizeBy",arguments);if(!this._track)return;var _3=this.vertical;if((_3&&_2!=0)||(!_3&&_1!=0)){this.length+=_3?_2:_1;this.$8y=this.length-this.$1495();if(_3)this._track.resizeBy(0,_2);else this._track.resizeBy(_1,0);if(this.numValues&&this.numValues>1){this.$8z=this.$8y/(this.numValues-1)}
this.setValue(this.value,true,true);if(this.showRange){if(this.vertical){var _4=this.flipValues?this.$52:this.$50;_4.moveBy(0,_2)}else{var _4=this.flipValues?this.$50:this.$52;_4.moveBy(_1,0)}}}},isc.A.$51=function isc_Slider__createRangeLabel(_1){var _2,_3,_4,_5,_6=(this.vertical?_1=="max":_1=="min");if(this.flipValues)_6=!_6;if(this.vertical){_2=Math.max(this.$1494(),this.trackWidth)+this.labelSpacing+(this.showValue?this.labelWidth+this.labelSpacing:0)+this.getLeftPadding();_4=isc.Canvas.LEFT;if(_6){_3=this._track.getTop();_5=isc.Canvas.TOP}else{var _7=this._track.getTop()+this._track.getHeight();_3=_7-this.labelHeight;_5=isc.Canvas.BOTTOM}}else{_3=Math.max(this.$1494(),this.trackWidth)+this.labelSpacing+(this.showValue?this.labelHeight+this.labelSpacing:0)+this.getTopPadding();_5=isc.Canvas.TOP;if(_6){_2=this._track.getLeft();_4=isc.Canvas.LEFT}else{var _8=this._track.getLeft()+this._track.getWidth();_2=_8-this.labelWidth;_4=isc.Canvas.RIGHT}}
return this.createAutoChild("rangeLabel",{ID:this.getID()+"_"+_1+"Label",left:_2,top:_3,width:this.labelWidth,height:this.labelHeight,align:_4,valign:_5,className:this.rangeStyle,contents:(_1=="min"?(this.minValueLabel?this.minValueLabel:this.minValue):(this.maxValueLabel?this.maxValueLabel:this.maxValue))})},isc.A.$54=function isc_Slider__createTitleLabel(){var _1=(this.vertical?isc.Canvas.CENTER:isc.Canvas.RIGHT);return isc.Label.create({ID:this.getID()+"_titleLabel",autoDraw:false,left:this.getLeftPadding(),top:this.getTopPadding(),width:(this.vertical?this.getInnerContentWidth(false):this.labelWidth),height:(this.vertical?this.labelHeight:this.getInnerContentHeight(false)),align:_1,className:this.titleStyle,contents:this.title})},isc.A.$53=function isc_Slider__createValueLabel(){var _1,_2,_3,_4,_5;var _6=this.hLabelSpacing==null?this.labelSpacing:this.hLabelSpacing;var _7=this.vLabelSpacing==null?this.labelSpacing:this.vLabelSpacing;if(this.vertical){_1=this._thumb.getLeft()-this.labelWidth-_6;_2=this._thumb.getTop()+parseInt(this._thumb.getHeight()/2-this.labelHeight/2);_4=isc.Canvas.RIGHT;_5=isc.Canvas.CENTER;_3=this.labelWidth}else{_1=this._thumb.getLeft()+parseInt(this._thumb.getWidth()/2-this.labelWidth/2);_2=this._thumb.getTop()-this.labelHeight-_7;_4=isc.Canvas.CENTER;_5=isc.Canvas.BOTTOM;_3=this.labelWidth}
var _8=(this.vertical?this.vValueStyle:this.hValueStyle)||this.valueStyle;var _9=this.$185r=this.createAutoChild("valueLabelLayout",{_constructor:this.vertical?"HLayout":"VLayout",left:_1,top:_2,width:this.vertical?_3:1,height:this.labelHeight,align:_4,defaultLayoutAlign:"center",observes:[{source:this,message:"handleValueChanged",action:"this.$81();"}]});var _10=this.createAutoChild("valueLabel",{width:1,height:1,overflow:'visible',baseStyle:_8,contents:this.value});this._valueLabel=_10;this.$185r.addMember(_10);if(!this.vertical){isc.addMethods(_9,{draw:function(){var _11=this.visibility;this.hide();this.Super("draw",arguments);this.parentElement.$81();this.setVisibility(this.prevVis)}})};return this.$185r},isc.A.draw=function isc_Slider_draw(){this.Super("draw",arguments);if(this.showActiveTrack)this.updateActiveTrack()},isc.A.setValueStyle=function isc_Slider_setValueStyle(_1){this.valueStyle=_1;if(this._valueLabel!=null)this._valueLabel.setBaseStyle(_1)},isc.A.$80=function isc_Slider__createTrackLayout(){var _1=this.$82(),_2,_3,_4=(this.vertical?this.trackWidth:this.length),_5=(this.vertical?this.length:this.trackWidth),_6,_7,_8=this.$1494(),_9=this.$1495(),_10=(this.vertical?_8:_9),_11=(this.vertical?_9:_8);var _12=_8>this.trackWidth;if(_12){if(this.vertical){_6=_1[0];_2=_6+parseInt(_8/2-this.trackWidth/2);_3=_1[1];_7=_1[1]}else{_7=_1[1];_3=_7+parseInt(_8/2-this.trackWidth/2);_2=_1[0];_6=_1[0]}}else{if(this.vertical){_2=_1[0];_6=_2+parseInt(this.trackWidth/2-_9/2);_3=_1[1];_7=_1[1]}else{_3=_1[1];_7=_3+parseInt(this.trackWidth/2-_9/2);_2=_1[0];_6=_1[0]}}
this.logDebug("calculated coords for track:"+[_2,_3,_4,_5]);this.logDebug("calculated coords for thumb:"+[_6,_7,_10,_11]);this._track=this.addChild(this.$83(_3,_2,_4,_5));this._thumb=this._track.addPeer(this.$84(_7,_6,_10,_11))},isc.A.$82=function isc_Slider__getTrackLayoutPos(){var _1=(this.vertical?this.vTitleSpacing:this.hTitleSpacing)||this.titleSpacing;var _2=this.vertical?(this.showValue?this.labelWidth+this.labelSpacing:0):(this.showTitle?this.labelWidth+_1:0),_3=this.vertical?(this.showTitle?this.labelHeight+_1:0):(this.showValue?this.labelHeight+this.labelSpacing:0);_2+=this.getLeftPadding();_3+=this.getTopPadding();if(this.showValue){var _4=this.$1495()
if(this.vertical&&(this.labelHeight>_4)){_3+=Math.round((this.labelHeight-_4)/2)}
if(this.horizontal&&(this.labelWidth>_4)){_2+=Math.round((this.labelWidth-_4)/2)}}
return[_2,_3]},isc.A.$185t=function isc_Slider__createActiveTrack(){this.$185u=this.createAutoChild('activeTrack',{styleName:this.activeTrackStyle});this.addChild(this.$185u)},isc.A.updateActiveTrack=function isc_Slider_updateActiveTrack(){if(!this.showActiveTrack||!this.isDrawn())return;if(!this.$185u)this.$185t();var _1=this._track,_2=this.$185u,_3=this._thumb;_2.moveTo(_1.getLeft(),_1.getTop());_2.resizeTo(_1.getWidth(),_1.getHeight());if(this.vertical){var _4=_3.getTop()+(_3.getHeight()/2);var _5=Math.max(0,_1.getTop()+_1.getHeight()-_4);_2.setTop(_4);_2.setHeight(_5)}else{_2.setWidth((_3.getLeft()+(_3.getWidth()/2))-_2.getLeft())}
if(!_2.isDrawn())_2.draw();else _2.redraw();_2.moveAbove(_1)},isc.A.$83=function isc_Slider__createTrack(_1,_2,_3,_4){return this.createAutoChild("track",{left:_2,top:_1,width:_3,height:_4,vertical:this.vertical,capSize:this.trackCapSize,src:"[SKIN]"+(this.vertical?"v":"h")+this.trackSrc,skinImgDir:this.skinImgDir,imageType:this.trackImageType,styleName:this[(this.vertical?"v":"h")+"TrackStyle"],overflow:"hidden",canFocus:true,tabIndex:-1,cacheImageSizes:false})},isc.A.$84=function isc_Slider__createThumb(_1,_2,_3,_4){var _5=(isc.Browser.isTouch?this.touchExtraThumbSpace:this.extraThumbSpace);var _6=this.createAutoChild("thumb",{left:_2,top:_1,width:_3,height:_4,src:"[SKIN]"+(this.vertical?"v":"h")+this.thumbSrc,skinImgDir:this.skinImgDir,styleName:this[(this.vertical?"v":"h")+"ThumbStyle"],triggerAreaTop:_5,triggerAreaRight:_5,triggerAreaBottom:_5,triggerAreaLeft:_5});return _6},isc.A.$1260=function isc_Slider__getValueFromCoords(_1,_2,_3){var _4,_5,_6=isc.EventHandler;if(this.vertical){var _7=this._track.getTop(),_8=this.$8y+_7;_4=_2[1]-_6.dragOffsetY-this.getPageTop();_4=Math.max(_7,Math.min(_8,_4));var _9=_4-_7;if(this.numValues){_9=Math.round(_9/this.$8z)*this.$8z;_4=Math.round(_9)+_7}
if(_4==this._thumb.getTop())return;this.logDebug("drag-moving thumb to:"+_4)
if(_1&&this.animateThumb){this.$87=this._thumb.animateMove(this._thumb.getLeft(),_4,null,this.animateThumbTime,this.animateThumbAcceleration)}else if(_3){this._thumb.setTop(_4)}
_5=(this.flipValues?_9/this.$8y:1-_9/this.$8y)}else{var _10=this._track.getLeft(),_8=this.$8y+_10;_4=_2[0]-_6.dragOffsetX-this.getPageLeft();_4=Math.max(_10,Math.min(_8,_4));var _9=_4-_10;if(this.numValues){_9=Math.round(_9/this.$8z)*this.$8z;_4=Math.round(_9)+_10}
if(_4==this._thumb.getLeft())return;this.logDebug("drag-moving thumb to:"+_4)
if(_1&&this.animateThumb){this.$87=this._thumb.animateMove(_4,this._thumb.getTop(),null,this.animateThumbTime,this.animateThumbAcceleration)}else if(_3){this._thumb.setLeft(_4)}
_5=(this.flipValues?1-_9/this.$8y:_9/this.$8y)}
if(this.maxValue==this.minValue)return this.minValue;var _11=_5*(this.maxValue-this.minValue)+this.minValue
return this.$85d(_11)},isc.A.$85=function isc_Slider__thumbMove(_1){var _2=this.ns.EH;var _3=this.$1260(_1,[_2.getX(),_2.getY()],true);if(_3!=null)this.value=_3;this.logDebug("slider value from drag-move:"+this.value);if(this.valueChangedOnDrag||!this.valueIsChanging()){this.handleValueChanged(this.value)}
if(this.sliderTarget)isc.EventHandler.handleEvent(this.sliderTarget,isc.Slider.EVENTNAME,this)},isc.A.$85d=function isc_Slider__getRoundedValue(_1){if(this.roundValues)_1=Math.round(_1);else if(this.roundPrecision!=null){var _2=Math.pow(10,this.roundPrecision);_1=(Math.round(_1*_2))/_2}
return _1},isc.A.$81=function isc_Slider__updateValueLabel(){if(this.showActiveTrack)this.updateActiveTrack();var _1=this._valueLabel;if(_1==null)return;var _2=this.getValue();_1.setContents(_2);var _3=this._thumb,_4=this.$185r;if(_4.isDrawn()){if(_1.isDrawn())_1.redraw("sizing layout");else _1.draw()}else return;_1.adjustForContent();_4.reflowNow();if(this.vertical){_4.setTop(parseInt((_3.getTop()+_3.getHeight()/2)-_4.getHeight()/2))}else{var _5=_1.getVisibleWidth(),_6=this.$1261(_2),_7=_3.getWidth(),_8=Math.floor((_6+(_7/2))-(_5/2)),_9=_6+_7;if(_8+_5>=_9){_8=_9-_5}
_4.setLeft(_8)}},isc.A.handleMouseUp=function isc_Slider_handleMouseUp(){if(this.valueChangedOnClick)this.$85(true)},isc.A.$1261=function isc_Slider__getThumbPositionFromValue(_1,_2){var _3,_4;if(!isc.isA.Number(_1))return;_1=Math.max(this.minValue,(Math.min(_1,this.maxValue)));_1=this.$85d(_1);if(_2)this.value=_1;if(this.minValue==this.maxValue)_3=1;else _3=(_1-this.minValue)/(this.maxValue-this.minValue);_4=_3*this.$8y;if(this.vertical){return this._track.getTop()+parseInt(this.flipValues?_4:this.$8y-_4)}else{return this._track.getLeft()+parseInt(this.flipValues?this.$8y-_4:_4)}},isc.A.setValue=function isc_Slider_setValue(_1,_2,_3){var _4=this.$1261(_1,true);if(_4==null)return;if(this.vertical){if(this.animateThumb&&!_2){this.$87=this._thumb.animateMove(this._thumb.getLeft(),_4,null,this.animateThumbTime,this.animateThumbAcceleration)}else{this._thumb.setTop(_4)}}else{if(this.animateThumb&&!_2){this.$87=this._thumb.animateMove(_4,this._thumb.getTop(),null,this.animateThumbTime,this.animateThumbAcceleration)}else{this._thumb.setLeft(_4)}}
if(!_3){this.handleValueChanged(this.value)}
if(this.sliderTarget)isc.EventHandler.handleEvent(this.sliderTarget,isc.Slider.EVENTNAME,this)},isc.A.getValue=function isc_Slider_getValue(){return this.value},isc.A.valueChanged=function isc_Slider_valueChanged(_1){},isc.A.handleValueChanged=function isc_Slider_handleValueChanged(_1){this.valueChanged(_1);this.updateActiveTrack()},isc.A.valueIsChanging=function isc_Slider_valueIsChanging(){var _1=this.ns.EH;return(_1.dragging&&this._thumb===_1.dragTarget)},isc.A.handleKeyPress=function isc_Slider_handleKeyPress(_1,_2){var _3=_1.keyName;if(_3=="Home"){this.setValue(this.minValue,true);return false}
if(_3=="End"){this.setValue(this.maxValue,true);return false}
var _4=(this.maxValue-this.minValue)*this.stepPercent/100;if(this.roundValues&&_4<1)_4=1;if(this.vertical){if((this.flipValues&&_3=="Arrow_Up")||(!this.flipValues&&_3=="Arrow_Down"))
{this.setValue(this.getValue()-_4,true);return false}else if((this.flipValues&&_3=="Arrow_Down")||(!this.flipValues&&_3=="Arrow_Up"))
{this.setValue(this.getValue()+_4,true);return false}}else{if((this.flipValues&&_3=="Arrow_Left")||(!this.flipValues&&_3=="Arrow_Right"))
{this.setValue(this.getValue()+_4,true)
return false}else if((this.flipValues&&_3=="Arrow_Right")||(!this.flipValues&&_3=="Arrow_Left"))
{this.setValue(this.getValue()-_4,true)
return false}}
if(this.keyPress){this.convertToMethod("keyPress");return this.keyPress(_1,_2)}},isc.A.setCanFocus=function isc_Slider_setCanFocus(_1){this.Super("canFocus",arguments);if(this._thumb!=null)this._thumb.setCanFocus(_1);if(this._track!=null)this._track.setCanFocus(_1)},isc.A.setMinValue=function isc_Slider_setMinValue(_1){_1=this.$85d(_1);this.minValue=_1;if(this.$50)this.$50.setContents(_1);if(this.getValue()<this.minValue)this.setValue(this.minValue)},isc.A.setMaxValue=function isc_Slider_setMaxValue(_1){_1=this.$85d(_1);this.maxValue=_1;if(this.$52)this.$52.setContents(_1);if(this.getValue()>this.maxValue)this.setValue(this.maxValue)},isc.A.setNumValues=function isc_Slider_setNumValues(_1){this.numValues=_1;this.$8z=this.$8y/(this.numValues-1);this.setValue(this.minValue)},isc.A.setTitle=function isc_Slider_setTitle(_1){this._titleLabel.setContents(_1)},isc.A.setLength=function isc_Slider_setLength(_1){this.length=_1;this.setUpSize()},isc.A.$74i=function isc_Slider__refreshChildren(){this._titleLabel.destroy();this._track.destroy();this._thumb.destroy();this._valueLabel.destroy();this.$50.destroy();this.$52.destroy();this.initWidget()},isc.A.setVertical=function isc_Slider_setVertical(_1){this.vertical=_1;this.$74i()},isc.A.$1494=function isc_Slider__getThumbThickWidth(){return(isc.Browser.isTouch&&this.touchThumbThickWidth!=null?this.touchThumbThickWidth:this.thumbThickWidth)},isc.A.setThumbThickWidth=function isc_Slider_setThumbThickWidth(_1){this.thumbThickWidth=_1;this.$74i()},isc.A.$1495=function isc_Slider__getThumbThinWidth(){return(isc.Browser.isTouch&&this.touchThumbThinWidth!=null?this.touchThumbThinWidth:this.thumbThinWidth)},isc.A.setThumbThinWidth=function isc_Slider_setThumbThinWidth(_1){this.thumbThinWidth=_1;this.$74i()},isc.A.setTrackWidth=function isc_Slider_setTrackWidth(_1){this.trackWidth=_1;this.$74i()},isc.A.setThumbSrc=function isc_Slider_setThumbSrc(_1){this.thumbSrc=_1;this.$74i()},isc.A.setTrackSrc=function isc_Slider_setTrackSrc(_1){this.trackSrc=_1;this.$74i()},isc.A.setTrackCapSize=function isc_Slider_setTrackCapSize(_1){this.trackCapSize=_1;this.$74i()},isc.A.setTrackImageType=function isc_Slider_setTrackImageType(_1){this.trackImageType=_1;this.$74i()},isc.A.setShowTitle=function isc_Slider_setShowTitle(_1){this.showTitle=_1;this.$74i()},isc.A.setShowRange=function isc_Slider_setShowRange(_1){this.showRange=_1;this.$74i()},isc.A.setShowValue=function isc_Slider_setShowValue(_1){this.showValue=_1;this.$74i()},isc.A.setLabelWidth=function isc_Slider_setLabelWidth(_1){this.labelWidth=_1;this.$74i()},isc.A.setLabelHeight=function isc_Slider_setLabelHeight(_1){this.labelHeight=_1;this.$74i()},isc.A.setLabelSpacing=function isc_Slider_setLabelSpacing(_1){this.labelSpacing=_1;this.$74i()},isc.A.setMaxValueLabel=function isc_Slider_setMaxValueLabel(_1){this.$52.setContents(_1)},isc.A.setRoundValues=function isc_Slider_setRoundValues(_1){this.roundValues=_1;this.$74i()},isc.A.setRoundPrecision=function isc_Slider_setRoundPrecision(_1){this.roundPrecision=_1;this.$74i()},isc.A.setFlipValues=function isc_Slider_setFlipValues(_1){this.flipValues=_1;this.$74i()},isc.A.setStepPercent=function isc_Slider_setStepPercent(_1){this.stepPercent=_1;this.$74i()});isc.B._maxIndex=isc.C+54;isc.Slider.registerStringMethods({valueChanged:"value"})
isc.defineClass("RangeSlider",isc.Canvas);isc.A=isc.RangeSlider;isc.A.$119c=1e-6;isc.A=isc.RangeSlider.getPrototype();isc.A.vertical=false;isc.A.minValue=0;isc.A.maxValue=0;isc.A.startValue=0;isc.A.endValue=0;isc.A.baseStyle="rangeSlider";isc.A.overflow="hidden";isc.A.thumbSize="7px";isc.A.labelStartDefaults={_constructor:isc.Label,wrap:false,overflow:"hidden"};isc.A.startThumbDefaults={_constructor:isc.Snapbar,wrap:false,overflow:"hidden",canDrag:true,keepInParentRect:true,canCollapse:false,showGrip:true,showClosedGrip:false,$1056:true,dragStart:function(){this.creator.oldStartValue=this.creator.startValue;this.creator.dragpoint=this.creator.vertical?isc.Event.mouseDownEvent.y:isc.Event.mouseDownEvent.x;this.creator.isDragging=true;this.creator.fireChangedEvent()},dragMove:function(){var _1=this.creator.vertical?this.creator.getValuesForPixels(isc.Event.lastEvent.y-this.creator.dragpoint):this.creator.getValuesForPixels(isc.Event.lastEvent.x-this.creator.dragpoint);this.creator.setStartValue(this.creator.oldStartValue+_1);this.creator.fireChangedEvent();return true},dragStop:function(){this.creator.isDragging=false;this.creator.fireChangedEvent()}};isc.A.labelDragDefaults={_constructor:isc.Label,overflow:"hidden",canDrag:true,keepInParentRect:true,dragAppearance:"none",dragMove:function(){var _1=this.creator.vertical?this.creator.getValuesForPixels(isc.Event.lastEvent.y-this.creator.dragpoint):this.creator.getValuesForPixels(isc.Event.lastEvent.x-this.creator.dragpoint);this.creator.setValues(this.creator.oldStartValue+_1,this.creator.oldEndValue+_1);this.creator.fireChangedEvent();return true},dragStart:function(){this.creator.oldStartValue=this.creator.startValue;this.creator.oldEndValue=this.creator.endValue;this.creator.dragpoint=this.creator.vertical?isc.Event.mouseDownEvent.y:isc.Event.mouseDownEvent.x;this.creator.isDragging=true;this.creator.fireChangedEvent()},dragStop:function(){this.creator.isDragging=false;this.creator.fireChangedEvent()}};isc.A.labelEndDefaults={_constructor:isc.Label,overflow:"hidden"};isc.A.endThumbDefaults={_constructor:isc.Snapbar,canDrag:true,overflow:"hidden",keepInParentRect:true,canCollapse:false,showGrip:true,$1056:true,dragStart:function(){this.creator.oldEndValue=this.creator.endValue;this.creator.dragpoint=this.creator.vertical?isc.Event.mouseDownEvent.y:isc.Event.mouseDownEvent.x;this.creator.isDragging=true;this.creator.fireChangedEvent()},dragMove:function(){var _1=this.creator.vertical?this.creator.getValuesForPixels(isc.Event.lastEvent.y-this.creator.dragpoint):this.creator.getValuesForPixels(isc.Event.lastEvent.x-this.creator.dragpoint);this.creator.setEndValue(this.creator.oldEndValue+_1);if(this.creator.scrollbar){this.creator.scrollbar.moveThumb()}
this.creator.fireChangedEvent();return true},dragStop:function(){this.creator.isDragging=false;this.creator.fireChangedEvent()}};isc.A.scrollbarDefaults={thumbDragStop:function(){this.Super("thumbDragStop",arguments);this.creator.thumbdragging=false;this.creator.isDragging=false;this.creator.updatePositions();this.creator.fireChangedEvent()},thumbDragStart:function(){this.Super("thumbDragStart",arguments);this.creator.thumbdragging=true;this.creator.isDragging=true;this.creator.oldStartValue=this.creator.startValue;this.creator.oldEndValue=this.creator.endValue;this.creator.dragpoint=this.getEventCoord();this.creator.fireChangedEvent()}};isc.A=isc.RangeSlider.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.initWidget=function isc_RangeSlider_initWidget(){this.Super("initWidget",arguments);if(this.maxValue<this.minValue){var x=this.minValue;this.minValue=this.maxValue;this.maxValue=x}
if(this.startValue<this.minValue){this.startValue=this.minValue}
if(this.endValue>this.maxValue){this.endValue=this.endValue}
if(!this.trackDefaults){isc.RangeSlider.setInstanceProperty("trackDefaults",this.getTrackDefaults())}
if(this.vertical){this.createControls(true)}
else{this.createControls()}},isc.A.getTrackDefaults=function isc_RangeSlider_getTrackDefaults(){return{overflow:"hidden",showDisabled:true,cacheImageSizes:false,_constructor:isc.Slider.getInstanceProperty("trackConstructor"),capSize:isc.Slider.getInstanceProperty("trackCapSize"),skinImgDir:isc.Slider.getInstanceProperty("skinImgDir"),imageType:isc.Slider.getInstanceProperty("trackImageType"),trackSrc:isc.Slider.getInstanceProperty("trackSrc")}},isc.A.resized=function isc_RangeSlider_resized(){this.Super("resized",arguments);if(this.showTrack){if(this.vertical){this.track.setWidth(isc.Slider.getInstanceProperty("trackWidth"));this.track.setHeight(this.height)}else{this.track.setHeight(isc.Slider.getInstanceProperty("trackWidth"));this.track.setWidth(this.width)}}
this.updatePositions()},isc.A.createControls=function isc_RangeSlider_createControls(_1){var _2=this;var _3;var _4=isc.Slider.getInstanceProperty("trackWidth");if(_1){this.scrollbar=this.addAutoChild("scrollbar",{_constructor:this.scrollbarConstructor,vertical:true,height:"100%"});if(this.scrollbar){_3=this.getWidth()-this.scrollbar.getWidth();this.scrollbar.setLeft(_3);this.scrollbar.setTop(0)}else{_3=this.getWidth()}
this.labelStart=this.addAutoChild("labelStart",{width:_3,baseStyle:this.baseStyle+"Start"});this.labelDrag=this.addAutoChild("labelDrag",{width:_3,baseStyle:this.baseStyle+"Selected"});this.labelEnd=this.addAutoChild("labelEnd",{width:_3,baseStyle:_2.baseStyle+"End"});this.startThumb=this.addAutoChild("startThumb",{height:this.thumbSize,width:_3,target:this.labelStart,vertical:false});this.endThumb=this.addAutoChild("endThumb",{height:this.thumbSize,width:_3,target:this.labelEnd,vertical:false,makeLabel:function(){this.Super("makeLabel",arguments);this.label.addMethods({getCustomState:function(){if(isc.Snapbar.getInstanceProperty("showClosedGrip")){return"closed"}}})}});this.track=this.addAutoChild("track",{left:Math.round(_3/2-_4/2),width:_4,height:this.height,vertical:this.vertical,src:"[SKIN]"+(this.vertical?"v":"h")+isc.Slider.getInstanceProperty("trackSrc"),styleName:isc.Slider.getInstanceProperty((this.vertical?"v":"h")+"TrackStyle")})}else{this.scrollbar=this.addAutoChild("scrollbar",{_constructor:isc.Scrollbar,vertical:false,width:"100%"});if(this.scrollbar){_3=this.getHeight()-this.scrollbar.getHeight();this.scrollbar.setLeft(0);this.scrollbar.setTop(_3)}else{_3=this.getHeight()}
this.labelStart=this.addAutoChild("labelStart",{height:_3,baseStyle:this.baseStyle+"Start"});this.labelDrag=this.addAutoChild("labelDrag",{height:_3,baseStyle:this.baseStyle+"Selected"});this.labelEnd=this.addAutoChild("labelEnd",{height:_3,baseStyle:this.baseStyle+"End"});this.startThumb=this.addAutoChild("startThumb",{width:this.thumbSize,height:_3,target:this.labelStart});this.endThumb=this.addAutoChild("endThumb",{width:this.thumbSize,height:_3,target:this.labelEnd,makeLabel:function(){this.Super("makeLabel",arguments);this.label.addMethods({getCustomState:function(){if(isc.Snapbar.getInstanceProperty("showClosedGrip")){return"closed"}}})}});this.track=this.addAutoChild("track",{top:Math.round(_3/2-_4/2),height:_4,width:this.width,vertical:this.vertical,src:"[SKIN]"+(this.vertical?"v":"h")+isc.Slider.getInstanceProperty("trackSrc"),styleName:isc.Slider.getInstanceProperty((this.vertical?"v":"h")+"TrackStyle")})};if(this.track){this.track.sendToBack()}
if(this.scrollbar){this.scrollbar.setScrollTarget(this)}
this.updatePositions()},isc.A.mouseUp=function isc_RangeSlider_mouseUp(){if(this.vertical){var _1=this.getOffsetY()-this.startThumb.getHeight()}else{var _1=this.getOffsetX()-this.startThumb.getWidth()}
this.slideSelectedRangeByPoints(_1);this.fireChangedEvent()},isc.A.slideSelectedRangeByPoints=function isc_RangeSlider_slideSelectedRangeByPoints(_1){var _2=this.getValuesForPixels(_1);var _3=(this.endValue-this.startValue)/2;this.isDragging=true;this.setValues(_2-_3+this.minValue,_2+_3+this.minValue);this.isDragging=false},isc.A.scrollToRatio=function isc_RangeSlider_scrollToRatio(_1,_2,_3){var _4=(this.scrollbar.getEventCoord()-this.dragpoint)/(this.scrollbar.trackSize());var _5=this.getValueForScrollRatio(_4);this.setValues(this.oldStartValue+_5,this.oldEndValue+_5);this.fireChangedEvent()},isc.A.scrollByDelta=function isc_RangeSlider_scrollByDelta(_1,_2,_3){var _4=this.endValue-this.startValue;if(this.vertical){var w=this.getHeight()-this.startThumb.getHeight()-this.endThumb.getHeight()}else{var w=this.getWidth()-this.startThumb.getWidth()-this.endThumb.getWidth()}
var _6=(this.maxValue-this.minValue)/w;var _7=20*_6*_2;var _8=this.startValue+_7;var _9=this.endValue+_7;if(_8<this.minValue){_8=this.minValue;_9=this.minValue+_4}
if(_9>this.maxValue){_9=this.maxValue;_8=this.maxValue-_4}
this.isDragging=true;this.setValues(_8,_9);this.isDragging=false;this.fireChangedEvent()},isc.A.scrollByPage=function isc_RangeSlider_scrollByPage(_1,_2,_3){var _4=Math.max((this.endValue-this.startValue),0)*_2;var _5=this.startValue+_4;var _6=this.endValue+_4;if(_5<this.minValue){_5=this.minValue;_6=this.minValue+Math.abs(_4)}
if(_6>this.maxValue){_6=this.maxValue;_5=this.maxValue-Math.abs(_4)}
this.isDragging=true;this.setValues(_5,_6);this.isDragging=false;this.fireChangedEvent()},isc.A.getViewportRatio=function isc_RangeSlider_getViewportRatio(_1){var _2=this.maxValue-this.minValue,_3=0;if(this.thumbdragging){_3=this.oldEndValue-this.oldStartValue}else{_3=this.endValue-this.startValue}
return(Math.abs(_2)<isc.RangeSlider.$119c?0:_3/_2)},isc.A.getScrollRatio=function isc_RangeSlider_getScrollRatio(_1){var _2=this.maxValue-this.minValue,_3=this.endValue-this.startValue;return(Math.abs(_2-_3)<isc.RangeSlider.$119c?0:(this.startValue-this.minValue)/(_2-_3))},isc.A.getValueForScrollRatio=function isc_RangeSlider_getValueForScrollRatio(_1){return _1*(this.maxValue-this.minValue)},isc.A.getValuesForPixels=function isc_RangeSlider_getValuesForPixels(_1){if(this.vertical){return _1*(this.maxValue-this.minValue)/(this.getHeight())}
else{return _1*(this.maxValue-this.minValue)/(this.getWidth())}},isc.A.updatePositions=function isc_RangeSlider_updatePositions(){if(this.vertical){var w=this.getHeight()-this.startThumb.getHeight()-this.endThumb.getHeight()}else{var w=this.getWidth()-this.startThumb.getWidth()-this.endThumb.getWidth()}
var _2=0;if(this.maxValue-this.minValue>0){_2=w/(this.maxValue-this.minValue)}
var _3=Math.round((this.startValue-this.minValue)*_2);var _4=Math.round((this.endValue-this.startValue)*_2);var _5=Math.round((this.maxValue-this.endValue)*_2);var _6=Math.round((this.startValue-this.minValue+this.endValue-this.startValue)*_2);if(this.vertical){if(_3==0){this.startThumb.target=this.labelDrag}else{this.labelStart.show();this.labelStart.setTop(0);this.labelStart.setHeight(_3)}
if(_4==0){this.labelDrag.hide()}else{this.labelDrag.show();this.labelDrag.setHeight(_4);this.labelDrag.setTop(_3+this.startThumb.getHeight())}
if(_5==0){this.labelEnd.hide()}else{this.labelEnd.show();this.labelEnd.setTop(_6+this.startThumb.getHeight()+this.endThumb.getHeight());this.labelEnd.setHeight(_5)}
this.startThumb.setTop(_3);this.endThumb.setTop(_6+this.startThumb.getHeight())}
else{if(_3==0){this.labelStart.hide()}
else{this.labelStart.show();this.labelStart.setLeft(0);this.labelStart.setWidth(_3)}
if(_4==0){this.labelDrag.hide()}
else{this.labelDrag.show();this.labelDrag.setWidth(_4);this.labelDrag.setLeft(_3+this.startThumb.getWidth())}
if(_5==0){this.labelEnd.hide()}else{this.labelEnd.show();this.labelEnd.setLeft(_6+this.startThumb.getWidth()+this.endThumb.getWidth());this.labelEnd.setWidth(_5)}
this.startThumb.setLeft(_3);this.endThumb.setLeft(_6+this.startThumb.getWidth())}
if(this.scrollbar){this.scrollbar.setThumb()}},isc.A.clampToMinMax=function isc_RangeSlider_clampToMinMax(_1){if(_1<=this.minValue){_1=this.minValue}
if(_1>=this.maxValue){_1=this.maxValue}
return _1},isc.A.isInMinMaxRange=function isc_RangeSlider_isInMinMaxRange(_1){if(_1<this.minValue){return false}
if(_1>this.maxValue){return false}
return true},isc.A.setValues=function isc_RangeSlider_setValues(_1,_2){if(this.isDragging){_1=this.clampToMinMax(_1);_2=this.clampToMinMax(_2);this.startValue=_1;this.endValue=_2;this.updatePositions()}else{if(this.isInMinMaxRange(_1)&&this.isInMinMaxRange(_2)&&_1<=_2){this.startValue=_1;this.endValue=_2;this.updatePositions()}}},isc.A.setStartValue=function isc_RangeSlider_setStartValue(_1){if(this.isDragging){_1=this.clampToMinMax(_1);if(_1>=this.endValue){_1=this.endValue}
this.startValue=_1;this.updatePositions()}else{if(this.isInMinMaxRange(_1)&&_1<=this.endValue){this.startValue=_1;this.updatePositions()}else{isc.logWarn("Ignoring setStartValue to "+_1+" (out of range).")}}},isc.A.setEndValue=function isc_RangeSlider_setEndValue(_1){if(this.isDragging){_1=this.clampToMinMax(_1);if(_1<=this.startValue){_1=this.startValue}
this.endValue=_1;this.updatePositions()}else{if(this.isInMinMaxRange(_1)&&_1>=this.startValue){this.endValue=_1;this.updatePositions()}else{isc.logWarn("Ignoring setEndValue to "+_1+" (out of range).")}}},isc.A.getStartValue=function isc_RangeSlider_getStartValue(){return this.startValue},isc.A.getEndValue=function isc_RangeSlider_getEndValue(){return this.endValue},isc.A.setMinValue=function isc_RangeSlider_setMinValue(_1){this.minValue=_1;this.updatePositions()},isc.A.setMaxValue=function isc_RangeSlider_setMaxValue(_1){this.maxValue=_1;this.updatePositions()},isc.A.getMinValue=function isc_RangeSlider_getMinValue(){return this.minValue},isc.A.getMaxValue=function isc_RangeSlider_getMaxValue(){return this.maxValue},isc.A.fireChangedEvent=function isc_RangeSlider_fireChangedEvent(){this.changed(this.startValue,this.endValue,this.isDragging)},isc.A.changed=function isc_RangeSlider_changed(_1,_2,_3){});isc.B._maxIndex=isc.C+27;if(isc.ListGrid){isc.ClassFactory.defineClass("ScrollingMenu","ListGrid");isc.defer("isc.ScrollingMenu.addProperties({ enableSelectOnRowOver: !isc.Browser.isTouch });");isc.A=isc.ScrollingMenu.getPrototype();isc.A.minHeight=null;isc.A.useBackMask=true;isc.A.canFocus=true;isc.A.showHeader=false;isc.A.showEdges=false;isc.A.autoDraw=false;isc.A.className="scrollingMenu";isc.A.bodyStyleName="scrollingMenuBody";isc.A.selectionType="single";isc.A.leaveScrollbarGap=false;isc.A.generateClickOnSpace=false;isc.A.generateDoubleClickOnEnter=false;isc.A.generateClickOnEnter=true;isc.A.showModal=true;isc.A.arrowKeyAction="select";isc.A.filterOnKeypress=true;isc.ScrollingMenu.changeDefaults("filterEditorDefaults",{backgroundColor:"white",editorKeyPress:function(_1,_2,_3){if(_2=="Arrow_Down"){this.sourceWidget.$318(1);return false}
if(_2=="Arrow_Up"){this.sourceWidget.$318(-1);return false}
if(_2=="Enter"){this.sourceWidget.$240();return}
return this.Super("editorKeyPress",arguments)}});isc.ScrollingMenu.changeDefaults("bodyDefaults",{$vl:function(){return this.creator.$vl.apply(this.creator,arguments)}});isc.A=isc.ScrollingMenu.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$859=true;isc.B.push(isc.A.show=function isc_ScrollingMenu_show(){if(this.showModal)this.showClickMask({target:this,methodName:"cancel"},false,[this]);this.Super("show",arguments);if(this.showModal)this.body.focus()},isc.A.recordClick=function isc_ScrollingMenu_recordClick(_1,_2,_3,_4,_5,_6,_7){this.hide();if(_2!=null)this.itemClick(_2)},isc.A.itemClick=function isc_ScrollingMenu_itemClick(_1){},isc.A.rowOver=function isc_ScrollingMenu_rowOver(_1,_2,_3){if(this.enableSelectOnRowOver){this.selection.selectSingle(_1);this.fireSelectionUpdated()}},isc.A.createSelectionModel=function isc_ScrollingMenu_createSelectionModel(_1,_2,_3,_4,_5){var _6=this.invokeSuper("ScrollingMenu","createSelectionModel",_1,_2,_3,_4,_5);this.selection.addProperties({selectOnRowOver:function(_7){this.selectSingle(_7);this.selectionFromMouse=true},setSelected:function(_7,_8){this.selectionFromMouse=false;return this.Super("setSelected",arguments)}});return _6},isc.A.bodyKeyPress=function isc_ScrollingMenu_bodyKeyPress(_1,_2){var _3=_1.keyName;if(_3==this.$10j){var _4=this.selection;if(_4&&_4.selectionFromMouse){this.cancel();return false}}
if(_3=="Escape"){this.cancel();return false}
return this.Super("bodyKeyPress",arguments)},isc.A.cancel=function isc_ScrollingMenu_cancel(){this.hide()},isc.A.hide=function isc_ScrollingMenu_hide(){this.hideClickMask();return this.Super("hide",arguments)},isc.A.dataChanged=function isc_ScrollingMenu_dataChanged(){var _1=this.Super("dataChanged",arguments);if(!this.$859)return;if(this.data&&this.data.getLength()>0&&this.selection&&!this.selection.anySelected()&&(isc.isA.ResultSet==null||!isc.isA.ResultSet(this.data)||this.data.rowIsLoaded(0)))
{this.selection.selectItem(0);this.fireSelectionUpdated()}
return _1});isc.B._maxIndex=isc.C+9}
isc.ClassFactory.defineClass("DynamicForm","Canvas","DataBoundComponent");isc.addGlobal("FormLayout",isc.DynamicForm);isc.A=isc.DynamicForm;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.GET="GET";isc.A.POST="POST";isc.A.NORMAL="normal";isc.A.MULTIPART="multipart";isc.A.NORMAL_ENCODING="application/x-www-form-urlencoded";isc.A.MULTIPART_ENCODING="multipart/form-data";isc.A.$89="$89";isc.A.$9a="$9a";isc.A.$9b="$9b";isc.A.$9c="$9d";isc.A.$9e="$9f";isc.A.$99r="inlineErrorHandle";isc.A.$9g="$9g";isc.B.push(isc.A.buildOperatorIndex=function isc_c_DynamicForm_buildOperatorIndex(){if(isc.DataSource==null)return;var _1=isc.getValues(isc.DataSource.getSearchOperators());_1=_1.sortByProperties(["symbol"],[false],[function(_4,_5,_6){var _2=_4[_5],_3=isc.isA.String(_2)?_2.length:0;return _3}]);this.$85l=_1.makeIndex("symbol",true)},isc.A.getOperatorIndex=function isc_c_DynamicForm_getOperatorIndex(){return this.$85l},isc.A.$1145=function isc_c_DynamicForm__defaultItemHoverHTMLImpl(_1){if(_1.implementsPromptNatively)return null;var _2=(_1.isReadOnly()?_1.readOnlyHover:null)||_1.prompt;if(!_2&&_1.parentItem)_2=isc.DynamicForm.$1145(_1.parentItem);return _2},isc.A.$1146=function isc_c_DynamicForm__defaultValueHoverHTMLImpl(_1){var _2=_1.getDisplayValue();if(_1!=null&&_1.multiple&&_1.multipleValueSeparator)_2=_2.join(_1.multipleValueSeparator);if(_2!=null){_2=""+_2;var _3;if(_2==_1.$54t&&((_3=_1.getValue())==null||_3==isc.emptyString))
{_2=""}else if(!_1.canEscapeHTML){_2=_2.asHTML()}}
return _2},isc.A.getDefaultOperatorForType=function isc_c_DynamicForm_getDefaultOperatorForType(_1,_2,_3,_4){var _5=_2&&_2.form,_6=_1==null?"text":isc.isA.String(_1)?_1:_1.name,_7;if((_2&&(_2.valueMap||_2.optionDataSource))||isc.SimpleType.inheritsFrom(_6,"enum")||isc.SimpleType.inheritsFrom(_6,"boolean")||isc.SimpleType.inheritsFrom(_6,"float")||isc.SimpleType.inheritsFrom(_6,"integer")||isc.SimpleType.inheritsFrom(_6,"date")||isc.SimpleType.inheritsFrom(_6,"time"))
{_7="equals"}else{var _8="iContains";if(_5){_8=_5.defaultSearchOperator||(_5.allowExpressions?"iContainsPattern":"iContains");var _9=_5.getDataSource(),_10=_4&&isc.isA.String(_4)?_9&&_9.getField(_4):_4,_11=_9&&_9.getFieldOperators(_10),_12=_11&&_11.contains(_8);if(!_12&&_11)_8=_11[0]}
_7=isc.DataSource.getCriteriaOperator(null,_3,_8)}
return _7});isc.B._maxIndex=isc.C+5;isc.A=isc.DynamicForm.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.flattenItems=false;isc.A.numCols=2;isc.A.fixedColWidths=false;isc.A.fixedRowHeights=false;isc.A.colWidths=null;isc.A.minColWidth=20;isc.A.cellSpacing=0;isc.A.cellPadding=2;isc.A.cellBorder=0;isc.A.defaultRowHeight=22;isc.A.sectionVisibilityMode="multiple";isc.A.allowContentAndChildren=true;isc.A.separateContentInsertion=true;isc.A.$r9=true;isc.A.fieldIdProperty="name";isc.A.titleField="title";isc.A.showDetailFields=true;isc.A.longTextEditorThreshold=255;isc.A.longTextEditorType="textArea";isc.A.titlePrefix="";isc.A.rightTitlePrefix=":&nbsp;";isc.A.titleSuffix="&nbsp;:";isc.A.rightTitleSuffix="";isc.A.exclusiveTitlePrefix="";isc.A.exclusiveRightTitlePrefix="";isc.A.exclusiveTitleSuffix="";isc.A.exclusiveRightTitleSuffix="";isc.A.titleWidth=100;isc.A.clipItemTitles=false;isc.A.showInlineErrors=true;isc.A.showErrorIcons=true;isc.A.showErrorText=false;isc.A.showErrorStyle=true;isc.A.errorOrientation="left";isc.A.errorItemDefaults={type:"blurb",wrap:true,showIf:function(){return!this.form.showInlineErrors&&this.form.hasErrors()},defaultDynamicValue:function(_1,_2,_3){return _2.getErrorsHTML(_2.getErrors())}};isc.A.errorItemCellStyle="formCellError";isc.A.errorsPreamble="The following errors were found:";isc.A.hiliteRequiredFields=true;isc.A.requiredTitlePrefix="<b>";isc.A.requiredRightTitlePrefix="<b>:&nbsp;";isc.A.requiredTitleSuffix="&nbsp;:</b>";isc.A.requiredRightTitleSuffix="</b>";isc.A.exclusiveRequiredTitlePrefix=null;isc.A.exclusiveRequiredRightTitlePrefix=null;isc.A.exclusiveRequiredTitleSuffix=null;isc.A.exclusiveRequiredRightTitleSuffix=null;isc.A.readOnlyDisplay="readOnly";isc.A.readOnlyTextBoxStyle="staticTextItem";isc.A.wrapHintText=true;isc.A.minHintWidth=80;isc.A.canHover=false;isc.A.itemHoverDelay=500;isc.A.itemHoverStyle="formHover";isc.A.originalValueMessage="Original value: $value";isc.A.overflow=isc.Canvas.VISIBLE;isc.A.defaultHeight=20;isc.A.validateOnChange=false;isc.A.implicitSaveDelay=2000;isc.A.synchronousValidation=false;isc.A.autoFocus=false;isc.A.autoFocusOnError=true;isc.A.selectOnFocus=false;isc.A.selectOnClick=false;isc.A.canFocus=true;isc.A._useNativeTabIndex=false;isc.A._useFocusProxy=false;isc.A.autoComplete="none";isc.A.uniqueMatch=true;isc.A.browserSpellCheck=true;isc.A.cancelParamName="org.apache.struts.taglib.html.CANCEL";isc.A.cancelParamValue="cancel";isc.A.action="#";isc.A.method=isc.DynamicForm.POST;isc.A.encoding=isc.DynamicForm.NORMAL_ENCODING;isc.A.writeFormTag=true;isc.A.autoSendTargetFieldName="__target__";isc.A.useNativeSelectItems=false;isc.A.operator="and";isc.A.nestedEditorType="NestedEditorItem";isc.A.nestedListEditorType="NestedListEditorItem";isc.A.canDropItems=false;isc.A.canAddColumns=true;isc.A.showPending=null;isc.B.push(isc.A.hasInherentHeight=function isc_DynamicForm_hasInherentHeight(){if(this.inherentHeight!=null)return this.inherentHeight;return(this.overflow==isc.Canvas.VISIBLE||this.overflow==isc.Canvas.CLIP_H)},isc.A.setValuesManager=function isc_DynamicForm_setValuesManager(_1){if(isc.isA.String(_1))_1=window[_1];if(isc.isA.ValuesManager(_1))_1.addMember(this);else this.valuesManager=_1});isc.B._maxIndex=isc.C+2;isc.A=isc.DynamicForm.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.isEditComponent=true;isc.A.$9i="upload";isc.A.$94c="UploadItem";isc.A.$94d="TUploadItem";isc.A.$9j="mutex";isc.A.$9k=["name","editorType","readOnlyEditorType","type","valueMap","defaultValue","showTitle","left","top","width","height"];isc.A.canTabToIcons=true;isc.A.dataArity="single";isc.A.storeAtomicValues=false;isc.A.storeDisplayValues=true;isc.A.$70l="/";isc.A.$9l="form";isc.A.$9m="$9n";isc.A.$9o="$9p";isc.A.$172o={visibleWhen:{attribute:"visibility",exclusiveProperty:"showIf"},requiredWhen:{attribute:"setRequired",exclusiveProperty:"requiredId"},readOnlyWhen:{attribute:"readOnly",additionalProperties:{"fieldAppearance":"readOnlyDisplay"}},formula:{attribute:"formula"},textFormula:{attribute:"textFormula"}};isc.A.$9q="absolute";isc.A.$9r="showIf";isc.A.$9s="item,value,form,values";isc.A.$9t="</FORM>";isc.A.$9u="tablePolicy";isc.A.$9v="<COL WIDTH=";isc.A.$9w=((isc.Browser.isIE&&!isc.Browser.isIE9)?"<TR STYLE='position:absolute'>":"<TR>");isc.A.$9y=(isc.Browser.isSafari||isc.Browser.isMoz?"</div></TD>":"</TD>");isc.A.$5u="<TD>";isc.A.$5v="</TD>";isc.A.$5s="<TR>";isc.A.$5t="</TR>";isc.A.$9z="<br>";isc.A.$90="</TABLE></FORM>";isc.A.$127r="</TABLE>";isc.A.$91=["<INPUT TYPE=HIDDEN NAME='",,"' VALUE='",,"'>"];isc.A.titleHeight=15;isc.A.$92="height:";isc.A.$93="width:";isc.A.$11j="max-width:";isc.A.$94="max-height:";isc.A.$92="height:";isc.A.$95="<NOBR>";isc.A.$96="</td></tr></TABLE>";isc.A.$97="</DIV>";isc.A.$98="</TD>";isc.A.$99=["<TD ",," CLASS='",,"' ALIGN='",,"' VALIGN='",,"'",,,">"];isc.A.emitOuterTextOverflow=false;isc.A.$o0="top";isc.A.$63z="$428";isc.A.$114x="$114y";isc.A.$114z=[,"<div style='float:right'>",,"</div><div id='",,"' style='overflow:hidden;",isc.Browser.$114w,":ellipsis",(isc.Browser.isIE&&!isc.Browser.isStrict?";width:100%":""),"'>",,,"</div>",null];isc.A.$10c=["<FORM ","ID","=",,," METHOD=",," ACTION='",,"' ENCTYPE=",,,,," ONSUBMIT='return ",,".$10d()' ONRESET='",,".resetValues(); return false;'"," STYLE='margin-bottom:0px'"," ACCEPT-CHARSET='UTF-8'",">"];isc.A.$10e=" STYLE='position:absolute;left:0px;top:0px;'";isc.A.$10f=" TARGET='";isc.A.writeWidthAttribute=false;isc.A.$10g=["<TABLE role='presentation' ID='",,"' WIDTH='",,"' CELLSPACING='",,"' CELLPADDING='",,"' BORDER='",,(isc.Browser.isMoz?"'><TBODY>":"'>")];isc.A.$119i="' WIDTH='";isc.A.$10h="table";isc.A.formSubmitFailedWarning="Form was unable to be submitted. The most likely cause for this is an invalid value in an upload field.";isc.A.$10i="requiredIf";isc.A.$842="required";isc.A.$10j="Enter";isc.A.$51h="Backspace";isc.A.itemHoverHTML=isc.DynamicForm.$1145;isc.A.valueHoverHTML=isc.DynamicForm.$1146;isc.B.push(isc.A.initWidget=function isc_DynamicForm_initWidget(){if(isc.$cv)arguments.$cw=this;if(!isc.DynamicForm.$85l)isc.DynamicForm.buildOperatorIndex();this.setColWidths(this.colWidths);this.Super("initWidget",arguments);if(this.showComplexFieldsRecursively)this.showComplexFields=true;if(this.fields&&this.items==null)this.items=this.fields;if(this.defaultItems!=null&&this.items==null){this.items=[];for(var i=0;i<this.defaultItems.length;i++){this.items[i]=isc.addProperties({},this.defaultItems[i])}}
if(this.values==null)this.values={};if(this.action!=isc.DynamicForm.getPrototype().action&&this.action!=null&&!isc.isA.emptyString(this.action))
{this.setAction(this.action)}
if(this.valuesManager!=null){if(isc.isA.String(this.valuesManager)){if(window[this.valuesManager])this.valuesManager=window[this.valuesManager]}
if(isc.isA.ValuesManager(this.valuesManager)){if(this.dataSource==null&&this.valuesManager.dataSource!=null){this.dataSource=this.valuesManager.dataSource}}}
if(!this.dataSource){var _2=this.items||[];for(var i=0;i<_2.length;i++){if(_2[i]==null)continue;if(this.dataPath||_2[i].dataPath){this.$834=isc.shallowClone(_2);break}}}
if(this.dataSource)this.dataSource=this.getDataSource();this.$143m(this.items?this.items:[],true);if(this.isDisabled()){this.setDisabled(true)}
this.setErrors(this.errors?this.errors:{});this.setValues(this.values,true);if(this.selectionComponent!=null)this.setSelectionComponent(this.selectionComponent,true)},isc.A.$10k=function isc_DynamicForm__destroyItems(_1){if(!_1)return;if(!isc.isA.FormItem(_1[0]))return;_1.callMethod("destroy");this.destroyOrphanedItems("containing form destroyed")},isc.A.destroy=function isc_DynamicForm_destroy(){this.$1639();if(this.valuesManager&&this.valuesManager.removeMember){this.valuesManager.removeMember(this)}
this.$10k(this.items);this.Super("destroy",arguments)},isc.A.setHandleDisabled=function isc_DynamicForm_setHandleDisabled(_1){if(this.isDrawn()){if(this.redrawOnDisable)this.markForRedraw("setDisabled");this.$1703=true;this.disableKeyboardEvents(_1);delete this.$1703}
var _2=this.getItems();for(var i=0;i<_2.length;i++){_2[i].updateDisabled(true)}},isc.A.disableKeyboardEvents=function isc_DynamicForm_disableKeyboardEvents(_1,_2,_3){var _3=this.$1703;var _4=this.$167w;this.Super("disableKeyboardEvents",arguments);if(!_3&&(_4!=_1)){this.$167w=_1;this.markForRedraw("Disable Keyboard events on items")}},isc.A.applyFieldDefaults=function isc_DynamicForm_applyFieldDefaults(_1){if(_1==null)return;for(var i=0;i<_1.length;i++){var _3=_1[i];if(_3==null)return}},isc.A.getEditorType=function isc_DynamicForm_getEditorType(_1,_2){return this.getClass().getEditorType(_1,this,_2)},isc.A.getFieldType=function isc_DynamicForm_getFieldType(_1,_2){if(_1.type!=null&&(_1.type!="any"||_1.fieldTypeProperty==null))
{return _1.type}
if(_1.criteriaField&&this.dataSource){var _3=isc.DataSource.get(this.dataSource);var _4=_3?_3.getField(_1.criteriaField):null;if(_4)return _4.type}
if(_1.optionDataSource&&_1.getValueFieldName){var _3=isc.DataSource.get(_1.optionDataSource);var _5=_3?_3.getField(_1.getValueFieldName()):null;if(_5)return _5.type}
if(_1.fieldTypeProperty!=null){if(_2==null)_2=this.values;if(_2&&_2[_1.fieldTypeProperty]!=null){return _2[_1.fieldTypeProperty]}}
return null},isc.A.$167p=function isc_DynamicForm__itemChanged(_1,_2){if(!_1.suppressItemChanged){if(this.itemChanged!=null){this.itemChanged(_1,_2)}
if(this.valuesManager&&this.valuesManager.itemChanged){this.valuesManager.itemChanged(_1,_2)}}
if(this.$179d){this.fireRuleContextChanged(this)}},isc.A.setItems=function isc_DynamicForm_setItems(_1){this.$143m(_1)},isc.A.$143m=function isc_DynamicForm__setItems(_1,_2){this.$1639();if(_1!=null){for(var i=0;i<_1.length;i++){var _4=false;if(_1[i]==null){this.logWarn("Encountered empty entry in items array - removing this entry.")
_4=true}
if(isc.isA.Canvas(_1[i])){this.logWarn("Encountered a Canvas instance:"+_1[i]+" in the items array - the DynamicForm items array should contain only FormItem definitions. Removing this entry.");_4=true}
if(_4){_1.removeAt(i);i-=1}}}
_1=this.bindToDataSource(_1);if(!_1)_1=[];else if(_1==this.items)_1=_1.duplicate();if(this.items!=null&&this.items.length>0&&!_2){this.removeItems(this.items)}
this.$10l(_1,null,true,_2);if(this.ruleScope||this.isRuleScope)this.$164b(this.getItems());if(!_2&&this.rulesEngine){this.rulesEngine.processContextChanged()}},isc.A.setFields=function isc_DynamicForm_setFields(_1){this.setItems(_1)},isc.A.getFields=function isc_DynamicForm_getFields(){return this.items},isc.A.getAllFields=function isc_DynamicForm_getAllFields(){return this.items},isc.A.getItems=function isc_DynamicForm_getItems(){return this.items},isc.A.visibleAtPoint=function isc_DynamicForm_visibleAtPoint(_1,_2,_3,_4){if(this.invokeSuper(isc.DynamicForm,"visibleAtPoint",_1,_2,_3,_4))
return true;var _5=this.items||[],_6={},_7=_5.indexOf(this.getFocusSubItem());for(var i=-1;i<_5.length;i++){var _9=i;if(i==-1){_9=_7}else if(_9==_7)continue;if(_9==-1)continue;var _10=_5[_9],_11=_10.containerWidget;if(_11==this||!_10.isDrawn()||!_10.isVisible())continue;var _12=_11.getID();if(_6[_12]==null){_6[_12]=_11.visibleAtPoint(_1,_2,_3,_4)}
if(!_6[_12])continue;var _13=_10.getPageLeft(),_14=_10.getPageTop();if(_13<=_1&&(_13+_10.getVisibleWidth())>=_1&&_14<=_2&&(_14+_10.getVisibleHeight())>=_2){return true}}
return false},isc.A.addItems=function isc_DynamicForm_addItems(_1,_2){if(!isc.isAn.Array(_1))_1=[_1];if(this.dataSource){var _3=isc.DS.get(this.dataSource);for(var i=0;i<_1.length;i++){_1[i]=this.combineFieldData(_1[i]);var _5=_1[i].name;if(_5&&this.getItem(_5)){this.removeItem(_5)}}}
this.addFieldValidators(_1);if(_2==null||_2>this.items.length)_2=this.items.length;this.$10l(_1,_2);this.$164b(_1)},isc.A.$10l=function isc_DynamicForm__addItems(_1,_2,_3,_4){this.addingItems=true;var _5=this.isDrawn();this.applyFieldDefaults(_1);var _6=[];var _7=false,_8=false,_9=(this.sectionVisibilityMode==this.$9j);for(var _10=0;_10<_1.length;_10++){var _11=_1[_10];if(!_11){_1.removeItem(_10);_10--;continue}
var _12=this.getEditorType(_11,this.values);_11.$167r=_12;_1[_10]=_11=this.createItem(_11,_12);if(_12==this.$9i||_12==this.$94c||_12==this.$94d)
{_7=true}
if(isc.FileItem&&isc.isA.FileItem(_11)&&_8){this.logWarn("Attempting to creating a form with multiple FileItems. This is not currently supported - only the first file type field value will be committed on submission of this form.")}
if(isc.isA.SectionItem(_11)){_6.add(_11);if(_11.sectionExpanded&&_9)
this.$6l=_11}}
if(_3)this.items=_1
else this.items.addListAt(_1,_2);if(!_4){this.setItemValues(this.getValues(),false,true,_1)}
if(_7)this.encoding=isc.DynamicForm.MULTIPART_ENCODING;for(var i=0;i<_6.length;i++){var _14=_6[i],_15=_14.sectionExpanded;if(_15&&(!_9||(this.$6l==_14))){_14.expandSection()}else{_14.collapseSection()}}
this.$10m=true;this.assignItemsTabPosition();this.markForRedraw("Form items added");delete this.addingItems},isc.A.copyKnownProperties=function isc_DynamicForm_copyKnownProperties(_1,_2,_3){var _4;for(var i=0;i<_3.length;i++){var _6=_3[i],_7=_2[_6];if(_7!==_4){_1[_6]=_7;delete _2[_6]}}},isc.A.createItem=function isc_DynamicForm_createItem(_1,_2){if(_1.form!=null&&!(_1.form==this.getID()||_1.form!=this)){this.logWarn("Unsupported 'form' property ["+_1.form+"] set on item:"+_1+".  Ignoring.")}
if(_1.destroyed&&isc.isA.FormItem(_1)){this.logWarn("destroyed FormItem passed to setItems()/addItem(): FormItems cannot be re-used with different DynamicForms")}
if(_1.showIf==null&&_1.hidden){_1.showIf="return false"}
var _3=isc.FormItemFactory.getItemClassName(_1,_2,this),_4=isc.FormItemFactory.getItemClass(_3);var _5=!_4;if(_5){this.logWarn("Problem initializing item: "+isc.Log.echo(_1)+" - derived FormItem class is: "+_3+".  If this is  not a typo, please make sure the relevant module is loaded.  A SpacerItem will be created for this FormItem.");_4=isc.ClassFactory.getClass("SpacerItem",true);if(_1.showTitle==false)_5=false}
if(isc.SGWTFactory&&isc.isA.SGWTFactoryObject(_4)){var _6=_1;if(_6.editorType||_6[isc.gwtRef]){_6=isc.addProperties({},_1);delete _6.editorType;delete _6[isc.gwtRef];delete _6[isc.gwtModule]}
var _7=_4.create(_6);var _8=this.createItem(_7,_7.editorType);_4.setJsObj(_8[isc.gwtRef],_8);return _8}
var _9=_1;_1=_4.createRaw();_1.form=_1.containerWidget=_1.eventParent=this;var _10=null;if(_1["validators"]!=null&&_9["validators"]!=null){_10=_1.validators}
if(isc.Browser.isIE&&this.canAlterItems){this.copyKnownProperties(_1,_9,this.$9k)}
if(this.autoChildItems){if(_1.ID==null)_1.ID=null;this.$d3(_4.Class,_1,_9)}else{_1.completeCreation(_9);if(_10!=null){if(!_1.validators){_1.validators=_10}else{if(!isc.isAn.Array(_1.validators)){_1.validators=[_1.validators]}
if(_1.validators.$69){_1.validators=_1.validators.duplicate()}
_1.validators.addList(_10)}}}
_1.form=this;if(_1.destroyed)_1.destroyed=false;if(_1.shouldSaveValue&&(_1[this.fieldIdProperty]==null||isc.isAn.emptyString(_1[this.fieldIdProperty]))&&(_1.dataPath==null||isc.isAn.emptyString(_1.dataPath)))
{this.logWarn(_1.getClass()+" form item defined with no '"+this.fieldIdProperty+"' property - Value cannot be validated and will not be saved. To explicitly exclude a form item from the set of values to be saved, set 'shouldSaveValue' to false for this item.")
_1.shouldSaveValue=false}
_1.updateCanEdit();_1.updateReadOnlyDisplay();if(_5&&_1.titleOrientation!="top")_1.colSpan+=_1.titleColSpan;return _1},isc.A.removeItems=function isc_DynamicForm_removeItems(_1){if(_1==null)return;if(!isc.isAn.Array(_1))_1=[_1];if(_1==this.items)_1=this.items.duplicate();_1=this.map("getItem",_1);var _2=this.$163o();for(var i=0;i<_1.length;i++){var _4=_1[i];if(_4==null)continue;if(_2){var _5=_1[i].getCriterion();if(_5!=null){if(this.$76u==null){this.$76u={_constructor:"AdvancedCriteria",operator:"and",criteria:[]}}
this.$76u.criteria.add(_5);delete this.values[_1[i].name]}}}
this.items.removeList(_1);if(this.$89t==null){this.$89t=[]}
var _6=this.getRuleScopeComponent();for(var i=0;i<_1.length;i++){var _4=_1[i];if(_4==null)continue;if(_6&&_6.rulesEngine&&isc.isA.FormItem(_4)){var _7=this.$177w(_4);if(_4.requiredWhen)this.$1637(_7,"setRequired",_4.name);if(_4.visibleWhen)this.$1637(_7,"visibility",_4.name);if(_4.readOnlyWhen)this.$1637(_7,"readOnly",_4.name);if(_4.formula)this.$1637(_7,"formula",_4.name);if(_4.textFormula)this.$1637(_7,"textFormula",_4.name)}
if(_4.items!=null){_1.addList(_4.items,i+1)}
if(this.$10n==_4){delete this.$10n;delete this.$189e;if(this.hasStableLocalID())this.provideRuleContext(this.getLocalId()+".focusField",null,this)}
if(!this.items.contains(_4)&&isc.isA.FormItem(_4)){if(this.isDrawn()){if(_4.$112n)_4.$112n();this.$89t.add(_4)}else{_4.destroy()}}}
this.$10m=true;this.markForRedraw("Form items removed")},isc.A.addField=function isc_DynamicForm_addField(_1,_2){this.addItems(_1,_2)},isc.A.removeField=function isc_DynamicForm_removeField(_1){this.removeItems(_1)},isc.A.addItem=function isc_DynamicForm_addItem(_1,_2){this.addItems(_1,_2)},isc.A.removeItem=function isc_DynamicForm_removeItem(_1){this.removeItems(_1)},isc.A.addFields=function isc_DynamicForm_addFields(_1,_2){return this.addItems(_1,_2)},isc.A.removeFields=function isc_DynamicForm_removeFields(_1){return this.removeItems(_1)},isc.A.itemAutoTabIndexUpdated=function isc_DynamicForm_itemAutoTabIndexUpdated(_1){if(!this.isDrawn())return;var _2=window[_1];if(this.logIsDebugEnabled("TabIndexManager")){this.logDebug("tab index update notification for item:"+_2,"TabIndexManager")}
if(_2==null||_2.destroyed||_2.form!=this){this.logWarn("auto tab index update notification for item with ID "+_1+", this may be a stale entry as we do not have an item with this ID.");return}
if(_2.$kk()&&_2.isDrawn()){_2.$173(_2.getGlobalTabIndex(),true)}
this.itemTabIndexUpdated(_2)},isc.A.itemTabIndexUpdated=function isc_DynamicForm_itemTabIndexUpdated(_1){},isc.A.$180m=function isc_DynamicForm__removeItemFromTabIndexManager(_1){isc.TabIndexManager.removeTarget(_1.ID)},isc.A.assignItemsTabPosition=function isc_DynamicForm_assignItemsTabPosition(){var _1=this.items;if(!_1||_1.length==0)return;var _2=this.sortItemsIntoTabOrder();for(var i=0,_4=0;i<_2.length;i++){var _5=_2[i];if(_5==null)continue;isc.TabIndexManager.moveTarget(_5.ID,this.ID,_4);_4++;if(_5.$kk()&&_5.globalTabIndex==null&&_5.tabIndex!=-1){_5.$173(_5.getGlobalTabIndex())}}},isc.A.sortItemsIntoTabOrder=function isc_DynamicForm_sortItemsIntoTabOrder(){return isc.DynamicForm.sortItemsIntoTabOrder(this.items,this)},isc.A.getChildTabPosition=function isc_DynamicForm_getChildTabPosition(_1){if(_1.canvasItem!=null){this.logWarn("Unexpected call to 'getChildTabPosition' for a CanvasItem canvas")}
var _2=this.items?this.items.length:0;var _3=this.children,_4=0;for(var i=0;i<this.children.length;i++){if(!_3[i].updateTabPositionOnReparent)continue;if(_3[i]==_1)break;_4++}
return _2+_4},isc.A.$kk=function isc_DynamicForm__canFocus(_1,_2,_3,_4){if(this.canFocus==true)return true;var _5=this.getItems()||[];for(var i=0;i<_5.length;i++){if(!isc.isA.FormItem(_5[i]))continue;if(_5[i].$kk())return true}
return this.invokeSuper(isc.DynamicForm,"$kk",_1,_2,_3,_4)},isc.A.handleMoved=function isc_DynamicForm_handleMoved(_1,_2,_3,_4){this.invokeSuper(isc.DynamicForm,"handleMoved",_1,_2,_3,_4);this.itemsMoved()},isc.A.handleParentMoved=function isc_DynamicForm_handleParentMoved(_1,_2,_3,_4){this.invokeSuper(isc.DynamicForm,"handleParentMoved",_1,_2,_3,_4);this.itemsMoved()},isc.A.zIndexChanged=function isc_DynamicForm_zIndexChanged(_1,_2,_3,_4){this.invokeSuper(isc.DynamicForm,"zIndexChanged",_1,_2,_3,_4);this.itemsZIndexChanged()},isc.A.parentZIndexChanged=function isc_DynamicForm_parentZIndexChanged(_1,_2,_3,_4){this.invokeSuper(isc.DynamicForm,"parentZIndexChanged",_1,_2,_3,_4);this.itemsZIndexChanged()},isc.A.itemsMoved=function isc_DynamicForm_itemsMoved(_1){if(_1==null)_1=this.getItems();if(!_1)return;for(var i=0;i<_1.length;i++){if(_1[i].isVisible)_1[i].moved()}},isc.A.itemsVisibilityChanged=function isc_DynamicForm_itemsVisibilityChanged(){var _1=this.getItems();if(!_1)return;for(var i=0;i<_1.length;i++){if(_1[i].visibilityChanged)_1[i].visibilityChanged()}},isc.A.itemsZIndexChanged=function isc_DynamicForm_itemsZIndexChanged(){var _1=this.getItems();if(!_1)return;for(var i=0;i<_1.length;i++){_1[i].zIndexChanged()}},isc.A.scrollTo=function isc_DynamicForm_scrollTo(_1,_2,_3){var _4=this.getScrollLeft(),_5=this.getScrollTop();this.Super("scrollTo",arguments);if(_4!=this.getScrollLeft()||_5!=this.getScrollTop())this.itemsMoved()},isc.A.$1f=function isc_DynamicForm__canAnimateClip(){if(this.canAnimateClip!=null)return this.canAnimateClip;return true},isc.A.setTitleOrientation=function isc_DynamicForm_setTitleOrientation(_1){this.titleOrientation=_1;this.$10m=true;this.markForRedraw()},isc.A.setNumCols=function isc_DynamicForm_setNumCols(_1){this.numCols=_1;this.$10m=true;this.markForRedraw()},isc.A.setAutoComplete=function isc_DynamicForm_setAutoComplete(_1){this.autoComplete=_1;for(var i=0;i<this.items.length;i++){this.items[i].$10q()}},isc.A.setValues=function isc_DynamicForm_setValues(_1,_2,_3,_4){delete this.$76u;if(isc.isAn.Array(_1)){var _5=isc.isA.Object(_1[0]);this.logWarn("values specified as an array."+(_5?" Treating the first item in the array as intended values.":" Ignoring specified values (resetting to defaults)."));if(_5)_1=_1[0];else _1=null}
if(_1==null){_1={}}else{var _6={};isc.DynamicForm.$91f(this,_1,_6);_1=_6}
this.$10r(_1);var _7=this.items;for(var i=0;i<_7.length;i++){if(_7[i].shouldSaveValue&&this.$425(_7[i])){_7[i].$426()}}
this.$164c=true;this.setItemValues(_1,null,_2);if(!_2)delete this.$164c;if(this.ruleScope||this.isRuleScope){var _9=this.getDataSource(),_10=this.hasStableLocalID()||(this.editNode!=null),_11=this.getValues();if(_11!=null)_11=isc.shallowClone(_11);if(_9&&isc.isA.DataSource(_9)&&this.$176k!=false){this.provideRuleContext(_9.getID(),_11,this,!(!_10&&_3)||_4)}
if(_10){this.provideRuleContext(this.getLocalId()+".values",_11,this,!_3||_4)}}
if(!_3){this.rememberValues()}else{if(this.rulesEngine!=null){this.rulesEngine.processEditStart(this)}}
if(_2)delete this.$164c;if(isc.isA.Function(this.valuesChanged))this.valuesChanged();this.markForRedraw("setValues")},isc.A.$425=function isc_DynamicForm__useDisplayFieldValue(_1){if(!_1||!_1.displayField)return false;if(_1.useLocalDisplayFieldValue!=null)return _1.useLocalDisplayFieldValue;if(_1.optionDataSource!=null)return false;if(_1.getValueFieldName()!=_1.getFieldName())return false;return true},isc.A.getDefaultOptionDataSource=function isc_DynamicForm_getDefaultOptionDataSource(_1){return this.dataSource},isc.A.setData=function isc_DynamicForm_setData(_1){this.setValues(_1)},isc.A.setDataSource=function isc_DynamicForm_setDataSource(_1,_2){this.Super("setDataSource",arguments);this.clearErrors()},isc.A.rememberValues=function isc_DynamicForm_rememberValues(){var _1=this.getValues();var _2={},_3=[];isc.DynamicForm.$91f(this,_1,_2,_3);this.$10s=_2;this.$10t=_3;this.updatePendingStyles();if(this.ruleScope||this.isRuleScope){var _4=this.getDataSource(),_5=this.hasStableLocalID()||(this.editNode!=null);if(_5){this.provideRuleContext(this.getLocalId()+".hasChanges",false,this,this.$164c)}}
return this.$10s},isc.A.updatePendingStyles=function isc_DynamicForm_updatePendingStyles(){var _1=this.items;for(var i=0,_3=(_1==null?0:_1.length);i<_3;++i){var _4=_1[i];if(!isc.isA.FormItem(_4))continue;_4.updatePendingStatus(_4._value)}},isc.A.resetValues=function isc_DynamicForm_resetValues(){this.clearErrors();var _1={};isc.DynamicForm.$91f(this,this.$10s,_1);if(this.$91h!=null){for(var i=0;i<this.$91h.length;i++){isc.DynamicForm.$70m(this.$91h[i],_1,this)}}
this.setValues(_1)},isc.A.clearValues=function isc_DynamicForm_clearValues(){var _1=false;if(this.ruleScope||this.isRuleScope){var _2=this.getDataSource(),_3=this.hasStableID()||(this.editNode!=null);_1=_3}
this.setValues(null,null,true,_1);var _4=this.getItems();for(var i=0;i<_4.length;i++){if(_4[i].shouldSaveValue==false)_4[i].setValue(null)}
this.clearErrors();this.rememberValues();this.markForRedraw("clearValues")},isc.A.valuesHaveChanged=function isc_DynamicForm_valuesHaveChanged(_1,_2,_3){if(_2==null)_2=this.getValues();if(_3==null)_3=this.$10s||{};return isc.DynamicForm.valuesHaveChanged(this,_1,_2,_3)},isc.A.valueHasChanged=function isc_DynamicForm_valueHasChanged(_1){var _2={fieldName:this.getValue(_1)},_3,_4={fieldName:this.$10s?this.$10s[_1]:_3};return this.valuesHaveChanged(false,_2,_4)},isc.A.getOldValues=function isc_DynamicForm_getOldValues(){var _1={};isc.addProperties(_1,this.$10s);return _1},isc.A.getOldValue=function isc_DynamicForm_getOldValue(_1){return this.getOldValues()[_1]},isc.A.getChangedValues=function isc_DynamicForm_getChangedValues(){return this.valuesHaveChanged(true)},isc.A.getValues=function isc_DynamicForm_getValues(){this.updateFocusItemValue();return this.values},isc.A.updateFocusItemValue=function isc_DynamicForm_updateFocusItemValue(){if(!this.isDrawn()||this.$146y)return;var _1=this.getFocusSubItem();if(!this.$10u){var _2=false;var _3=this.getItems(),_4=[];for(var i=0;i<_3.length;i++){if(isc.isA.PasswordItem(_3[i])){_2=true;break}else{if(_3[i]==_1&&_1.$10v()&&!_3[i].changeOnKeypress){_4[_4.length]=_3[i]}else if(_3[i].$17h()=="native"){_4[_4.length]=_3[i]}}}
if(_2)_4=_3;for(var i=0;i<_4.length;i++){var _6=_4[i];_6.updateValue()}}},isc.A.getData=function isc_DynamicForm_getData(){return this.getValues()},isc.A.$163o=function isc_DynamicForm__hasAdvancedCriteria(_1){if(this.operator!="and"||this.allowExpressions)return true;if(!_1&&this.$76u!=null)return true;return this.getItems().callMethod("hasAdvancedCriteria").contains(true)},isc.A.getExtraAdvancedCriteria=function isc_DynamicForm_getExtraAdvancedCriteria(){return this.$76u?isc.clone(this.$76u):null},isc.A.getItemValuesAsCriteria=function isc_DynamicForm_getItemValuesAsCriteria(_1,_2,_3){if(_1==null){_1=this.$163o(true)}
var _4=this.$76v(_1,_2);if(_1){_4.removeEmpty()}else{if(_3)return _4;_4=isc.DataSource.filterCriteriaForFormValues(_4)}
return _4},isc.A.getValuesAsCriteria=function isc_DynamicForm_getValuesAsCriteria(_1,_2,_3){if(_1==null){_1=this.$163o()}
var _4=this.getItemValuesAsCriteria(_1,_2,_3)
if(!_1){return _4}
var _5={operator:this.operator,_constructor:"AdvancedCriteria",criteria:[]};var _6=this.getExtraAdvancedCriteria();if(_6&&_6.criteria){if(_6.operator==this.operator)_5=_6;else _5.criteria.add(_6)}
if(_4&&_4.length>0){_5.criteria.addList(_4)}
var _7=isc.DS.checkEmptyCriteria(_5);return _7},isc.A.$76v=function isc_DynamicForm__getMappedCriteriaValues(_1,_2){var _3=isc.addProperties({},this.getValues()),_4={},_5=[];var _6=this.getFields();for(var i=0;i<_6.length;i++){if(!_6[i].shouldSaveValue)continue;var _8=_6[i],_9=_6[i].getTrimmedDataPath()||_6[i].getFieldName(),_10=_6[i].getCriteriaFieldName();isc.Canvas.$70m(_9,_3);if(!_1){if(_10!=null){if(_3[_6[i].name])delete _3[_6[i].name];if(_6[i].displayField&&_6[i]._value==null&&_3[_6[i].displayField]==_6[i].emptyDisplayValue)
{delete _3[_6[i].displayField]}
var _11=_2==null||_2=="exact"||_2=="equals";_4[_10]=_6[i].getCriteriaValue(!_11)}}else{var _12=_8.getCriterion(_2);if(_12!=null)_5.add(_12)}}
if(!_1){return isc.addProperties(_3,_4)}else{for(var _13 in _3){if(_5.find("fieldName",_13))continue;if(_3[_13]==null)continue;_5.add({operator:isc.DataSource.getCriteriaOperator(_3[_13],_2),fieldName:_13,value:_3[_13]})}
return _5}},isc.A.removeFieldCriteria=function isc_DynamicForm_removeFieldCriteria(_1,_2,_3,_4){if(!_4||!_4.criteria)return false;var _5=_4.criteria;for(var i=_5.length-1;i>=0;i--){var _7=_5[i];if(_7.criteria){this.removeFieldCriteria(_1,_2,_3,_7);if(_7.criteria.length==0)_5.removeAt(i)}else{if(_7.fieldName==_1){if(_7.operator!=_2||_7.value!=_3){_5.removeAt(i)}}}}},isc.A.removeExtraAdvancedCriteria=function isc_DynamicForm_removeExtraAdvancedCriteria(_1){var _2=isc.getKeys(_1),_3=this.items;for(var i=0;i<_2.length;i++){var _5=_2[i],_6=_1[_5],_7=null,_8=null;_3.map(function(_9){if(_5==_9.getCriteriaFieldName())_8=_9});if(_8){_7=_8.getOperator();this.removeFieldCriteria(_5,_7,_6,this.$76u)}}},isc.A.removeExtraAdvancedCriteriaFields=function isc_DynamicForm_removeExtraAdvancedCriteriaFields(_1){for(var i=0;i<_1.length;i++){this.removeFieldCriteria(_1[i],null,null,this.$76u)}},isc.A.setValuesAsCriteria=function isc_DynamicForm_setValuesAsCriteria(_1,_2,_3,_4){if(!_2&&!isc.DataSource.isAdvancedCriteria(_1,this.dataSource)){this.$144w(_1,_3,_4);var _5=this.items||[];var _6=[];if(_3&&(!_4||_4.length==0)){delete this.$76u}else if(this.$76u){if(this.$125e){this.removeExtraAdvancedCriteria(_1);var _7=this.$76u;if(_3&&_4){this.removeExtraAdvancedCriteriaFields(_4)}
if(!_7||!_7.criteria||_7.criteria.length==0)_7=null}else{delete this.$76u}}
for(var i=0;i<_5.length;i++){var _9=_5[i],_10=_9.getFieldName(),_11=false;if(isc.propertyDefined(_1,_10)&&_9.canEditSimpleCriterion(_10)){_9.setSimpleCriterion(_1[_10],_10);_11=true}else{for(var _12 in _1){if(_12!=_10&&_9.canEditSimpleCriterion(_12)){_9.setSimpleCriterion(_1[_12],_12);_11=true;break}}}
if(!_11){_6.add(_9)}}
for(var i=0;i<_6.length;i++){if(!_6[i].shouldSaveValue)continue;_6[i].clearValue()}
this.rememberValues()}else{var _13=this.values;this.$10r({});_1=isc.clone(_1);var _14=_1.operator;if(_14!=this.operator){this.logInfo("Dynamic Form editing advanced criteria object:"+isc.Comm.serialize(_1)+". Form level operator specified as '"+this.operator+"' - Criteria returned from this form will be nested in an outer "+this.operator+" clause.","AdvancedCriteria");delete _1._constructor;_1={_constructor:"AdvancedCriteria",operator:this.operator,criteria:[_1]}}
var _5=this.getItems(),_15=_1.criteria||[],_16={},_6={};for(var i=0;i<_5.length;i++){_6[_5[i].getID()]=true}
for(var i=0;i<_15.length;i++){for(var _17=0;_17<_5.length;_17++){if(!_5[_17].shouldSaveValue){_6[_5[_17].getID()]=false;continue}
var _9=_5[_17];if(this.shouldApplyCriterionToItem(_5[_17],_15[i])){var _18=_5[_17].getID();if(_16[_18]==null){_16[_18]=_15[i];_6[_18]=false}else{if(!_5[_17].canEditOpaqueValues){var _19=_16[_18];var _20=isc.DataSource.combineCriteria(_19,_15[i],this.operator,null,true);if(!_9.canEditCriterion(_20)){this.logInfo("setValuesAsCriteria(): criteria include:"+this.echoFull(_19)+" and "+this.echoFull(_15[i])+". Both of these could be applied to item:"+_9+". However, the item is unable to edit a composite criterion resulting from combining these criteria. Therefore "+this.echoFull(_15[i])+" will not be applied to this item","AdvancedCriteria");continue}else{this.logDebug("setValuesAsCriteria(): Combined multiple criteria into composite criterion:"+this.echoFull(_20)+" and assigned to item:"+_9,"AdvancedCriteria");_16[_18]=_20;_6[_18]=false}}else{continue}}
_15[i]=null;break}}}
_15.removeEmpty();for(var _18 in _16){var _9=window[_18];var _21=_16[_18];if(_9.canEditOpaqueValues&&_21){isc.Canvas.$70n(null,_9,_21.value,_13,this,true,"criteria");_21.value=isc.Canvas.$70o(null,_9,_13,this,true,"edit")}
_9.setCriterion(_21)}
for(var _18 in _6){if(!_6[_18])continue;var _9=window[_18];if(_9)_9.clearValue()}
this.$76u=_1}},isc.A.$144w=function isc_DynamicForm__saveValuesAsCriteria(_1,_2,_3){if(_2){var _4;for(var _5 in this.values){if(_3&&!_3.contains(_5))continue;if(_1[this.values[_5]]==_4){this.clearValue(_5)}}}
for(var _5 in _1){var _6=this.getItem(_5);if(_6!=null){isc.Canvas.$70n(_5,_6,_1[_5],this.values,this,true,"criteria")}else{this.setValue(_5,_1[_5])}}
this.$10r(this.values)});isc.evalBoundary;isc.B.push(isc.A.shouldApplyCriterionToItem=function isc_DynamicForm_shouldApplyCriterionToItem(_1,_2){if(_1.canEditCriterion(_2))return true;if(_2.fieldName!=null&&_2.fieldName==_1.getCriteriaFieldName()){this.logInfo("Editing AdvancedCriteria in a dynamicForm. Criteria includes a value for field:"+_2.fieldName+". This form includes an item "+_1+" with the same fieldName but the specified operator '"+_2.operator+"' does not match the operator for this form item:"+_1.getOperator()+". Original criterion will be retained and combined with any criterion returned from this item.","AdvancedCriteria")}
return false},isc.A.getValuesAsAdvancedCriteria=function isc_DynamicForm_getValuesAsAdvancedCriteria(_1,_2){return this.getValuesAsCriteria(true,_1,_2)},isc.A.getItem=function isc_DynamicForm_getItem(_1,_2){if(_1==null)return null;if(isc.isA.FormItem(_1))return _1;var _3=isc.Class.getArrayItem(_1,this.items,this.fieldIdProperty);if(_3!=null)return _3;if(isc.isA.String(_1)){var _4=isc.DynamicForm.$840(_1,this);for(var i=0;i<this.items.length;i++){var _6=this.items[i].dataPath;_6=isc.DynamicForm.$840(_6,this);if(_6==_4)return this.items[i]}}
if(!_2&&isc.isA.Number(_1-1)){return this.items[parseInt(_1)]}
return null},isc.A.getField=function isc_DynamicForm_getField(_1){return this.getItem(_1)},isc.A.getSubItem=function isc_DynamicForm_getSubItem(_1){return this.getItem(_1)},isc.A.getItemById=function isc_DynamicForm_getItemById(_1){var _2;if(isc.isA.String(_1)){_2=window[_1]}else _2=_1;if(isc.isA.FormItem(_2))return _2;return null},isc.A.getValue=function isc_DynamicForm_getValue(_1,_2){var _3=this.getItem(_1);if(_3){var _1=_3.getTrimmedDataPath()||_3.name}
return this.$70p(_1,_2)},isc.A.$70p=function isc_DynamicForm__getValue(_1,_2){return isc.DynamicForm.$70o(_1,null,this.values,this,true,_2)},isc.A.setValue=function isc_DynamicForm_setValue(_1,_2,_3){var _4=this.getItem(_1,_3);if(_4!=null){if(!this.storeAtomicValues&&!_4.canEditOpaqueValues){var _5=_4.type?isc.SimpleType.getType(_4.type):null;if(_5&&_5.getAtomicValue&&_5.updateAtomicValue){_1=_4.getTrimmedDataPath()||_4.name;this.$10w(_1,_2);_2=_5.getAtomicValue(_2)}}
return _4.setValue(_2)}else if(this.values!=null){this.$10w(_1,_2);return _2}},isc.A.clearValue=function isc_DynamicForm_clearValue(_1){var _2=this.getItem(_1);if(_2!=null)_2.clearValue();else if(this.values)isc.DynamicForm.$70m(_1,this.values)},isc.A.showItem=function isc_DynamicForm_showItem(_1){var _2=this.getItem(_1);if(_2!=null)return _2.show()},isc.A.hideItem=function isc_DynamicForm_hideItem(_1){var _2=this.getItem(_1);if(_2!=null)return _2.hide()},isc.A.saveItemValue=function isc_DynamicForm_saveItemValue(_1,_2){if(_1.shouldSaveValue==false)return;var _3=_1.getDataPath()||_1.getFieldName();if(_3==null)return;this.$924(_1,_2);this.itemDisplayValueModified(_1,_2);_1.$10x()},isc.A.itemDisplayValueModified=function isc_DynamicForm_itemDisplayValueModified(_1,_2){var _3=_1.getDataPath()||_1.getFieldName();if(!this.$425(_1)||(_1.displayField==_3))return;if(this.storeDisplayValues==false||_1.storeDisplayValues==false)return;var _4=_1.mapValueToDisplay(_2);if(_4==_1.emptyDisplayValue)_4=null;this.setValue(_1.displayField,_4,true)},isc.A.$924=function isc_DynamicForm__saveAtomicValue(_1,_2){this.$10w(_1,_2,true)},isc.A.$10w=function isc_DynamicForm__saveValue(_1,_2,_3){var _4,_5;_5=_4=_1;_1=this.getField(_4);var _6=_1;if(this.storeAtomicValues&&(!_1||!_1.canEditOpaqueValues)){if(isc.isAn.Object(_4)){_4=_1.getTrimmedDataPath()||_1[this.fieldIdProperty];_1=null}}else{if(!isc.isA.String(_4)){_4=null}else{if(_3){_1=this.getField(_4);if(_1==null){var _7=this.getDataSource();if(_7)_1=_7.getField(_4)||_7.getFieldForDataPath(_4)}}else{_1=null}}}
isc.DynamicForm.$70n(_4,_1,_2,this.values,this,true,"updateValue");_1=_6;if((this.grid==null||!this.$164c)&&(this.ruleScope||this.isRuleScope)&&(_4||(_1&&_1.name))){_4=_4||_1.name;var _7=this.getDataSource(),_8=this.hasStableLocalID()||this.grid||(this.editNode!=null);if(_7&&isc.isA.DataSource(_7)&&this.$176k!=false){this.provideRuleContext(_7.getID()+"."+_4,_2,this,_8||this.$10u)}
if(_8){var _9=_1&&_1.$176l,_10=this.$172s||this.$164c||this.$10u||_9;this.provideRuleContext(this.getLocalId()+".values."+_4,_2,this,true);if(!this.$164c){var _11=this.getLocalId()+".hasChanges";var _12=this.valuesHaveChanged(false,this.values);this.provideRuleContext(_11,_12,this,_10)}}}
var _13=this.selectionComponent;if(!_13&&this.valuesManager!=null){if(isc.isA.ValuesManager(this.valuesManager)&&this.valuesManager.members&&this.valuesManager.members.contains(this))
{if(!isc.isA.String(_5)){_5=_5.dataPath||_5.name}
this.valuesManager.$10y(_5,_2,this)}}},isc.A.clearItemValue=function isc_DynamicForm_clearItemValue(_1){var _2=isc.DynamicForm.$702(this.dataPath,_1.getDataPath()||_1.getFieldName());isc.DynamicForm.$70m(_2,this.values);if(!this.selectionComponent&&isc.isA.ValuesManager(this.valuesManager)&&this.valuesManager.members&&this.valuesManager.members.contains(this))
{this.valuesManager.$10z(_2,this)}},isc.A.$10r=function isc_DynamicForm__saveValues(_1){this.values=_1;if(!this.selectionComponent&&isc.isA.ValuesManager(this.valuesManager)&&this.valuesManager.members&&this.valuesManager.members.contains(this))
{var _2=isc.getKeys(this.values);for(var i in _1){this.valuesManager.$10y(i,_1[i],this);_2.remove(i)}
for(var i=0;i<_2.length;i++){this.valuesManager.$10z(_2[i],this)}}},isc.A.getSavedItemValue=function isc_DynamicForm_getSavedItemValue(_1){if(_1.shouldSaveValue==false)return null;var _2=isc.DynamicForm.$702(this.dataPath,_1.getDataPath()||_1.getFieldName());return this.$70p(_2)},isc.A.resetValue=function isc_DynamicForm_resetValue(_1){var _2=this.getItem(_1);return(_2?_2.resetValue():null)},isc.A.getValueMap=function isc_DynamicForm_getValueMap(_1){var _2=this.getItem(_1);return(_2?_2.getValueMap():null)},isc.A.setValueMap=function isc_DynamicForm_setValueMap(_1,_2){var _3=this.getItem(_1);return(_3?_3.setValueMap(_2):null)},isc.A.getOptions=function isc_DynamicForm_getOptions(_1){return this.getValueMap(_1)},isc.A.setOptions=function isc_DynamicForm_setOptions(_1,_2){return this.setValueMap(_1,_2)},isc.A.getForm=function isc_DynamicForm_getForm(_1){var _2=(_1==null?[this.getFormID()]:arguments);return this.Super("getForm",_2)},isc.A.getFormID=function isc_DynamicForm_getFormID(){return this.$qs(this.$9l)},isc.A.getSerializeableFields=function isc_DynamicForm_getSerializeableFields(_1,_2){_1=_1||[];_1.addList(["items"]);return this.Super("getSerializeableFields",[_1,_2],arguments)},isc.A.expandSection=function isc_DynamicForm_expandSection(_1){var _2=this.getItem(_1);if(isc.isA.SectionItem(_2))_2.expandSection()},isc.A.collapseSection=function isc_DynamicForm_collapseSection(_1){var _2=this.getItem(_1);if(isc.isA.SectionItem(_2))_2.collapseSection()},isc.A.$100=function isc_DynamicForm__sectionExpanding(_1){if(this.isDrawn()){this.$86o=this.notifyAncestorsOnReflow;this.notifyAncestorsOnReflow=true}
if(this.sectionVisibilityMode=="mutex"&&this.$6l&&this.$6l!=_1)
{this.$6l.collapseSection()}
this.$6l=_1},isc.A.$101=function isc_DynamicForm__sectionCollapsing(_1){if(this.isDrawn()){this.$86o=this.notifyAncestorsOnReflow;this.notifyAncestorsOnReflow=true}},isc.A.getErrors=function isc_DynamicForm_getErrors(){return this.errors},isc.A.getFieldErrors=function isc_DynamicForm_getFieldErrors(_1){if(!this.errors)return null;var _2;if(isc.isA.FormItem(_1)){var _3=_1;_1=_3.getFieldName();_2=this.buildFieldDataPath(this.getFullDataPath(),_3)}
var _4=this.errors[_1];if(isc.isA.String(_4)||isc.isAn.Array(_4)){return _4}
if(_2!=null){if(isc.isA.String(_4)||isc.isAn.Array(_4))return _4}
return null},isc.A.getDataPathErrors=function isc_DynamicForm_getDataPathErrors(_1){var _2=_1.split("/");var _3=this.errors;for(var i=0;i<_2.length;i++){_3=_3[_2[i]];if(!_3)return null}
return _3},isc.A.setErrors=function isc_DynamicForm_setErrors(_1,_2){this.errors=isc.DynamicForm.formatValidationErrors(_1);var _3=false,_4={};for(var _5 in this.errors){var _6=this.getItem(_5);if(!_6||!_6.visible){_4[_5]=this.errors[_5];_3=true}}
if(_2)this.showErrors(this.errors,_4)},isc.A.setError=function isc_DynamicForm_setError(_1,_2){var _3=this.errors[_1];if(!_3)this.errors[_1]=_2;else{if(isc.isA.String(_3))this.errors[_1]=[_3,_2];else this.errors[_1].add(_2)}},isc.A.addFieldErrors=function isc_DynamicForm_addFieldErrors(_1,_2,_3){if(!this.errors)this.errors={};this.addValidationError(this.errors,_1,_2);if(_3)this.showFieldErrors(_1)},isc.A.setFieldErrors=function isc_DynamicForm_setFieldErrors(_1,_2,_3){if(this.errors==null)this.errors={};this.errors[_1]=_2;if(_3)this.showFieldErrors(_1)},isc.A.clearFieldErrors=function isc_DynamicForm_clearFieldErrors(_1,_2,_3){if(this.errors==null)return;if(!this.errors[_1])return;delete this.errors[_1];if(_2){this.showFieldErrors(_1,_3)}},isc.A.clearFieldError=function isc_DynamicForm_clearFieldError(_1,_2,_3){if(this.errors==null||!this.errors[_1])return;var _4=this.errors[_1];if(!isc.isAn.Array(_4)){if(_4==_2){delete this.errors[_1]}}else{if(_4.contains(_2)){_4.remove(_2)}
if(_4.length==0)delete this.errors[_1]}
if(_3)this.showFieldErrors(_1)},isc.A.clearErrors=function isc_DynamicForm_clearErrors(_1){this.setErrors({},_1)},isc.A.hasErrors=function isc_DynamicForm_hasErrors(){var _1=this.errors;if(!_1)return false;for(var _2 in _1){if(_1[_2]!=null)return true}
return false},isc.A.hasFieldErrors=function isc_DynamicForm_hasFieldErrors(_1){var _2=this.errors;return(_2&&_2[_1]!=null)},isc.A.draw=function isc_DynamicForm_draw(_1,_2,_3,_4){if(isc.$cv)arguments.$cw=this;if(!this.readyToDraw())return this;this.$174s();this.invokeSuper(isc.DynamicForm,this.$ny,_1,_2,_3,_4);this.$102();var _5=this.autoFocus,_6=(!_5?this.$9m:this.$9o);this.$10u=true;isc.Page.setEvent(isc.EH.IDLE,this,isc.Page.FIRE_ONCE,_6);if(this.position==isc.Canvas.RELATIVE){isc.Page.setEvent(isc.EH.LOAD,this,isc.Page.FIRE_ONCE,"$103")}
if(!this.$10u){if(this.ruleScope||this.isRuleScope){this.$164b(this.getItems());var _7=this.getRuleScopeComponent(),_8=this.getValues(),_9=this.getDataSource(),_10=this.hasStableLocalID();if(_10&&this.editNode&&this.editNode.defaults&&this.editNode.defaults.hasStableID){_10=this.editNode.defaults.hasStableID()}
if(_9&&this.$176k!=false)_7.provideRuleContext(_9.getID(),_8,this,_10);if(_10){_7.provideRuleContext(this.getLocalId()+".values",_8,this,true);if(!this.$164c){_7.provideRuleContext(this.getLocalId()+".hasChanges",_8,this,this.valuesHaveChanged())}}}
if(this.rulesEngine!=null)this.rulesEngine.processEditStart(this)}
return this},isc.A.$177x=function isc_DynamicForm__getFormItemIconLocatorForWhenRules(_1,_2){var _3=isc.AutoTest.testRoot;isc.AutoTest.testRoot=null;var _4=isc.AutoTest.getFormItemIconLocator(_1,_2);isc.AutoTest.testRoot=_3;return _4},isc.A.$164b=function isc_DynamicForm__createItemWhenRules(_1){var _2=this.getRuleScopeComponent(),_3=[],_4=[];for(var i=0;i<_1.length;i++){if(_1[i].$164a){continue}
var _6=_1[i],_7=_3.length;if((!_6.showIf&&_6.visibleWhen)||(!_6.requiredIf&&_6.requiredWhen)||_6.readOnlyWhen||(_6.formula&&!isc.isA.emptyObject(_6.formula))||(_6.textFormula&&!isc.isA.emptyObject(_6.textFormula)))
{var _8=this.$177w(_6),_9=(_6.name==null?[]:null);if(!_6.showIf&&_6.visibleWhen){if(_9){_9.add("visibleWhen")}else{_3.add(this.$1636(_8,"visibility",_6.visibleWhen,_6.name))}}
if(!_6.requiredIf&&_6.requiredWhen){if(_9){_9.add("requiredWhen")}else{_3.add(this.$1636(_8,"setRequired",_6.requiredWhen,_6.name))}}
if(_6.readOnlyWhen){if(_9){_9.add("readOnlyWhen")}else{var _10=this.$1636(_8,"readOnly",_6.readOnlyWhen,_6.name);_10.fieldAppearance=this.readOnlyDisplay;_3.add(_10)}}
if(_6.formula||_6.textFormula){if(_9){_9.add(_6.formula?"formula":"textFormula")}else{var _10=this.$176m(_8,_6);_3.add(_10)}}
if(_9){for(var j=0;j<_9.length;j++){this.logWarn("Form item with no name defined - '"+_9[j]+"' is ignored: "+this.echo(_6))}}}
if(_6.icons){var _12=_6.icons;for(var j=0;j<_12.length;j++){var _13=_12[j];if((!_13.showIf&&_13.visibleWhen)||_13.enableWhen){var _8=this.$177x(_6,_13);if(!_13.showIf&&_13.visibleWhen){if(_6.name==null){this.logWarn("Form item icon with no formItem.name defined - 'visibleWhen' is ignored: "+this.echo(_13))}else{_3.add(this.$1636(_8,"visibility",_13.visibleWhen,(_6.name||_6.ID)+"$4u"+j))}}
if(_13.enableWhen){if(_6.name==null){this.logWarn("Form item icon with no formItem.name defined - 'enableWhen' is ignored: "+this.echo(_13))}else{var _14={_constructor:"AdvancedCriteria",operator:"not",criteria:_13.enableWhen};_3.add(this.$1636(_8,"enable",_14,(_6.name||_6.ID)+"$4u"+j))}}}}}
if(_3.length!=_7){_4.add(_6)}}
if(_3.length>0){var _15=this.getRulesEngine();if(!_15){return}
_15.addMember(this);for(var i=0;i<_3.length;i++){_15.addRule(_3[i])}
for(var i=0;i<_4.length;i++){_4[i].$164a=true}
if(!this.hasStableLocalID()&&this.editNode==null){this.$179d=true}}},isc.A.$1639=function isc_DynamicForm__removeItemWhenRules(){var _1=this.getRuleScopeComponent();if(_1&&this.items&&this.rulesEngine){var _2=this.items;for(var i=0;i<_2.length;i++){var _4=_2[i],_5=_2[i].getTrimmedDataPath()||_2[i].getFieldName(),_6=this.$177w(_4);if(_4.requiredWhen)this.$1637(_6,"setRequired",_5);if(_4.visibleWhen)this.$1637(_6,"visibility",_5);if(_4.readOnlyWhen)this.$1637(_6,"readOnly",_5);if(_4.formula)this.$1637(_6,"formula",_5);if(_4.textFormula)this.$1637(_6,"textFormula",_5);if(_4.icons){var _7=_4.icons;for(var j=0;j<_7.length;j++){var _9=_7[j],_6=isc.AutoTest.getFormItemIconLocator(_4,_9);if(_9.visibleWhen)this.$1637(_6,"visibility",_5+"$4u"+j);if(_9.enableWhen)this.$1637(_6,"enable",_5+"$4u"+j)}}
delete _4.$164a}
delete this.$179d}},isc.A.$176m=function isc_DynamicForm__createFormulaRule(_1,_2){var _3=_2.name,_4=(_2.formula?"formula":"textFormula"),_5=this.$1638(_1,_4,_3),_6=(_1!=null?{locator:_1}:{fieldName:this.dataSource+"."+_3}),_7=_2.type||_2.defaultType,_8=(_4=="formula"?(_7=='date'||_7=='time'?"populateExpression":"populate"):"populateText"),_9=_2.formula||_2.textFormula;return isc.addProperties({name:_5,triggerEvent:"contextChanged",type:_8,overwriteInvalidValue:true,autoPopulateClearedFlag:this.autoPopulateClearedFlag,formula:_9.text,targetRuleScope:this.getRuleScope(),allowEscapedKeys:true},_6)},isc.A.$172p=function isc_DynamicForm__updateItemWhenRule(_1,_2){var _3=this.$172o[_2];if(!_3)return;var _4=this.getRulesEngine();if(!_4)return;var _5=_3.attribute,_6=this.$177w(_1);this.$1637(_6,_5,_1.name);if(_1[_2]&&(!_3.exclusiveProperty||!_1[_3.exclusiveProperty])){if(_2=="formula"||_2=="textFormula"){var _7=this.$176m(_6,_1)}else{var _7=this.$1636(_6,_5,_1[_2],_1.name)}
if(_3.additionalProperties){for(var _8 in _3.additionalProperties){_7[_8]=_1[_3.additionalProperties[_8]]}}
_4.addRule(_7)}
_4.processContextChanged()},isc.A.$1633=function isc_DynamicForm__removeFromRuleScope(){if(this.ruleScope){var _1=this.getDataSource(),_2=this.hasStableLocalID()||this.grid||(this.editNode!=null);if(_1&&isc.isA.DataSource(_1)&&this.$176k!=false){this.provideRuleContext(_1.getID(),null,this,_2)}
if(_2)this.provideRuleContext(this.getLocalId(),null,this)}
this.Super("$1633",arguments)},isc.A.$us=function isc_DynamicForm__adjustOverflowForPageLoad(){if(isc.Browser.isSafari){var _1=this.getItems();if(this.isDrawn()&&_1){for(var i=0;i<_1.length;i++){_1[i].$104();if(this.isDirty())break}}}
return this.Super("$us",arguments)},isc.A.$9n=function isc_DynamicForm__delayedSetValues(){this.$164b(this.getItems());this.setItemValues(null,true);this.rememberValues();delete this.$10u;if(this.rulesEngine!=null)this.rulesEngine.processEditStart(this)},isc.A.$9p=function isc_DynamicForm__delayedSetValuesFocus(){this.$9n();this.delayCall("focus")},isc.A.redraw=function isc_DynamicForm_redraw(){this.$107();this.$146y=true;this.$106();if(this.$11v!=null)delete this.$11v;this.Super("redraw",arguments);this.$108();this.$146y=false;var _1,_2,_3;if(isc.Browser.isMoz){_3=this.getClipHandle();if(_3){_1=_3.scrollLeft;_2=_3.scrollTop}}
if(isc.Browser.isMoz){if(_1!=null&&_3.scrollLeft!=_1)
_3.scrollLeft=_1;if(_2!=null&&_3.scrollTop!=_2)
_3.scrollTop=_2}
this.itemsMoved();if(this.$86o!=null){this.notifyAncestorsOnReflow=this.$86o;this.$86o=null}},isc.A.$174s=function isc_DynamicForm__itemsDrawing(){var _1=this.items;for(var i=0;i<_1.length;i++){if(_1[i]){this.updateItemVisible(_1[i]);if(_1[i].visible)_1[i].drawing()}}},isc.A.updateItemVisible=function isc_DynamicForm_updateItemVisible(_1){var _2=_1.visible;var _3=this.values;if(_1.showIf){isc.Func.replaceWithMethod(_1,this.$9r,this.$9s);var _4=_1.getValue();_2=(_1.showIf(_1,_4,this,_3)==true)}
if(_2&&this.isPrinting){if(_1.shouldPrint!=null){_2=_1.shouldPrint}else if(_2&&this.currentPrintProperties.omitControls){var _5=this.currentPrintProperties.omitControls;for(var i=0;i<_5.length;i++){var _7=_5[i];if(isc.isA[_7]&&isc.isA[_7](_1)){_2=false}}}}
var _8=(_1.visible!=_2);if(_8){_1.visible=_2;_1.itemVisibilityChanged(_2)}},isc.A.$102=function isc_DynamicForm__itemsDrawn(){var _1=isc.RPCManager&&!isc.RPCManager.startQueue();this.$172s=true;var _2=this.items;for(var i=0;i<_2.length;i++){if(_2[i]){if(_2[i].visible)_2[i].drawn()}}
delete this.$172s;if(_1)isc.RPCManager.sendQueue()},isc.A.$108=function isc_DynamicForm__itemsRedrawn(){var _1=this.items;for(var i=0;i<_1.length;i++){var _3=_1[i];if(!_3)continue;if(_3.visible){_3.isDrawn()?_3.redrawn():_3.drawn(true)}else if(_3.isDrawn()){_3.cleared(true)}}
this.destroyOrphanedItems("Delayed destroy of removed items on form redraw")},isc.A.$11a=function isc_DynamicForm__itemsCleared(){var _1=this.items;if(_1){for(var i=0;i<_1.length;i++){if(_1[i].isDrawn&&_1[i].isDrawn())_1[i].cleared()}}
this.destroyOrphanedItems("Delayed destroy of removed items on clear")},isc.A.destroyOrphanedItems=function isc_DynamicForm_destroyOrphanedItems(_1){if(this.$89t!=null){this.$89t.callMethod("destroy",[_1]);delete this.$89t}},isc.A.$107=function isc_DynamicForm__itemsRedrawing(){var _1=this.items;for(var i=0;i<_1.length;i++){var _3=_1[i];if(!_3)continue;var _4=_1[i].isDrawn();this.updateItemVisible(_1[i]);var _5=_3.visible;if(_5&&_4)_3.redrawing();else if(_5&&!_4)_3.drawing(true);else if(!_5&&_4)_3.clearing(true)}},isc.A.modifyContent=function isc_DynamicForm_modifyContent(){this.$103()},isc.A.$103=function isc_DynamicForm__placeCanvasItems(){return this.$11c("placeCanvas",true)},isc.A.$11c=function isc_DynamicForm__notifyCanvasItems(_1,_2){if(!isc.CanvasItem)return;for(var i=0;i<this.items.length;i++){var _4=this.items[i];if(_4&&isc.isA.CanvasItem(_4)&&(!_2||_4.isVisible(true))){_4[_1]()}}},isc.A.redrawFormItem=function isc_DynamicForm_redrawFormItem(_1,_2){var _3=this.getItems();if(!_1)return;while(_1.parentItem)_1=_1.parentItem;if(!_3.contains(_1))return;this.$10m=true;this.markForRedraw(_1.ID+": "+(_2?_2:"redrawFormItem"))},isc.A.getElementValues=function isc_DynamicForm_getElementValues(){var _1={};for(var i=0;i<this.items.length;i++){var _3=this.items[i],_4=_3.getDataElement()?_3.getDataElement().value:"[no element]";_1[_3[this.fieldIdProperty]]=_4}
return _1},isc.A.setItemValues=function isc_DynamicForm_setItemValues(_1,_2,_3,_4,_5){var _6=isc.RPCManager?!isc.RPCManager.startQueue():false;var _7=(_1==null);if(_7)_1=this.getValues();if(_1==null)_1={};var _8;if(_3){_8=this.$76u?this.$76u.criteria:null}
_4=_4||this.items;var _9,_10=_1!=null&&!isc.isAn.emptyObject(_1);for(var _11=0;_11<_4.length;_11++){var _12=_4[_11],_13=_12.getFieldName(),_14=_12.getTrimmedDataPath(),_15=_12.isSetToDefaultValue(),_16=_9;if(_10){if(_14){_16=isc.DynamicForm.$70o(_14,(this.storeAtomicValues&&!_12.canEditOpaqueValues?null:_12),_1,this,true,"edit")}else if(_13){_16=isc.DynamicForm.$70o(_13,(this.storeAtomicValues&&!_12.canEditOpaqueValues?null:_12),_1,this,true,"edit")}}
if(_2&&isc.CanvasItem&&isc.isA.CanvasItem(_12)&&!_12.$11d())
{continue}
var _9,_17=((!_13&&!_14)||_16===_9);var _18=null;if(_3&&_17&&_12.value!=null){_18=_12.value;if(_18!=_12._value)_15=false}
var _19=null;if(_17&&_8!=null){for(var i=0;i<_8.length;i++){if(_12.canEditCriterion(_8[i])){_17=false;if(_19==null){_19=_8[i]}else{var _21=isc.DataSource.combineCriteria(_19,_8[i],this.operator,null,true);if(!_12.canEditCriterion(_21)){this.logInfo("setItemValues(): current values include multiple extra criteria that could be applied to form item:"+_12+". Criteria include:"+this.echoFull(_19)+" and "+this.echoFull(_8[i])+". However, the item is unable to edit a composite criterion resulting from combining these criteria. Therefore "+this.echoFull(_8[i])+" will not be applied to this item","AdvancedCriteria");continue}else{this.logInfo("setItemValues(): Combined multiple 'extra' criteria into composite criterion:"+this.echoFull(_21)+" and assigned to item:"+_12,"AdvancedCriteria");_19=_21}}
_8.removeAt(i);if(_8.length==0){delete this.$76u}else{i--}}}}
if(_12.shouldSaveValue==false){if(!_17){this.logInfo("DynamicForm.setValues() passed a value for '"+_12[this.fieldIdProperty]+"'. The corresponding form item was declared with 'shouldSaveValue' set to  false to exclude its value from the form's values object. Setting 'shouldSaveValue' to true for this item.\n[To avoid seeing this message in the future, set 'shouldSaveValue' to true for any form items whose values are to be managed via  form.setValues() / form.getValues().]")
_12.shouldSaveValue=true}else{var _22=(_15?null:_12._value);if(_18!=null)_22=_18;_12.setValue(_22,(_15?false:_2));continue}}
if(_18!=null){_17=false;_16=_18}
if((_17||(_19==null&&_7&&_15))&&!_5)
{var _9;if(!_3)_12.clearValue();else if(_3&&_15&&_12._value!==_9){_12.saveValue(_12._value,true)}}else{if(_19!=null){_12.setCriterion(_19)}else if(!_5||!_17){_12.setValue(_16,true)}}}
if(_6)isc.RPCManager.sendQueue()},isc.A.$11e=function isc_DynamicForm__absPos(){return this.itemLayout==this.$9q},isc.A.setColWidths=function isc_DynamicForm_setColWidths(_1){if(_1==null)return;if(isc.isA.String(_1)){var _2=_1.split(/[, ]+/);if(_2==null||_2.length==0){this.logWarn("ignoring invalid colWidths string: "+_1);if(_1==this.colWidths)this.colWidths=null;return}
_1=_2}else if(isc.isAn.Array(_1)&&_1.length==1&&isc.isA.String(_1[0]))
{var _2=_1[0].split(/[, ]+/);if(_2!=null||_2.length>1){_1=_2}}
this.colWidths=_1;if(this.isDrawn())this.markForRedraw()},isc.A.getInnerHTML=function isc_DynamicForm_getInnerHTML(_1){if(this.autoDupMethods)this.duplicateMethod("getInnerHTML");var _2=this.values,_3=this.items;var _4=false;for(var _5=0;_5<_3.length;_5++){var _6=_3[_5],_7=_6.isDrawn(),_8=_6.visible;if(_8!=_7){if(!_6.alwaysTakeSpace)_4=true}}
if(_4||this.$10m)isc.Canvas.invalidateTableResizePolicy(_3);this.$10m=false;this.setRequiredIf();if(this.flattenItems){var _9=null;for(var _5=0;_5<_3.length;_5++){var _6=_3[_5];if(_6.visible||_6.alwaysTakeSpace)_9++;if(_6.showTitle&&_6.titleOrientation!="top")
_9++;_6.$58l=_6.colSpan||null;_6.colSpan=null}
if(_9){this.numCols=_9;this.$10m=true;this.markForRedraw()}}
var _10=isc.StringBuffer.create();if(this.writeFormTag&&!this.isPrinting)_10.append(this.getFormTagStartHTML());if(this.$11e()){_10.append(this.getAbsPosHTML());_10.append(this.$9t);return _10.release(false)}
_10.append(this.getTableStartHTML());if(this.titleWidth==this.$pa&&!this.colWidths){this.colWidths=[];for(var i=0;i<this.numCols;i++)this.colWidths[i]=this.$pa}
var _12;if(this.colWidths){_12=this.colWidths;if(_12.length>this.numCols){if(!this.$76z){this.logWarn("colWidths Array longer than numCols, using only first "+this.numCols+" column widths")}
_12=_12.slice(0,this.numCols)}else if(_12.length<this.numCols){if(!this.$76z){this.logWarn("colWidths Array shorter than numCols, remaining columns get '*' size")}
_12=_12.duplicate();for(var i=_12.length;i<this.numCols;i++)_12[i]=isc.star}}else{_12=[];var _13=this.getInnerContentWidth();_13-=(this.cellBorder!=null?this.cellBorder:0);var _14=Math.floor(this.numCols/2),_15=_13-(_14*this.titleWidth),_16;if(this.isPrinting){_16="*"}else{_16=Math.floor(_15/(this.numCols-_14));_16=Math.max(this.minColWidth,_16)}
for(var i=0;i<_14;i++){_12.add(this.titleWidth);_12.add(_16)}
if((this.numCols%2)!=0)_12.add(_16);if(this.logIsInfoEnabled(this.$9u)){this.logInfo("totalWidth: "+_13+", generated colWidths: "+_12,this.$9u)}}
var _17=this.getInnerContentWidth(),_18=this.getInnerContentHeight();if(this.cellSpacing!=0){if(isc.Browser.isMoz)_18-=2*this.cellSpacing;else if(isc.Browser.isSafari)_18-=this.cellSpacing}
_3.$8q=this.defaultRowHeight;isc.Canvas.applyTableResizePolicy(_3,_17,_18,this.numCols,_12);var _19=false;if(isc.CanvasItem){for(var i=0;i<_3.length;i++){var _6=_3[i];if(_6.visible&&isc.isA.CanvasItem(_6)&&_6.checkCanvasOverflow()){if(!_19&&this.logIsInfoEnabled(this.$9u)){this.logInfo("CanvasItem: "+_6+" overflowed, rerunning policy",this.$9u)}
_19=true}}}
if(_19){isc.Canvas.applyTableResizePolicy(_3,_17,_18,this.numCols,_12,null,true)}
if(!this.isPrinting){_12=_3.$8r}
for(var _20=0;_20<_12.length;_20++){var _21=_12[_20];if(_21=="*"){_10.append("<COL>")}else{_10.append(this.$9v,_21,this.$oa)}}
if(this.isPrinting){_10.append("<tr>")}else{_10.append(this.$9w)}
var _22=isc.DynamicForm.$817();for(var _20=0;_20<_12.length;_20++){if(!isc.isA.Number(_12[_20])){_10.append(_22.join(isc.emptyString),this.$9y)}else{var _17=_12[_20];_17-=(this.cellSpacing!=null?(2*this.cellSpacing):0);if(isc.Browser.isIE8Strict){_17-=this.cellPadding!=null?(2*this.cellPadding):0}
_22[3]=(isc.FormItem?isc.FormItem.getPrototype().baseStyle:null);var _23=isc.Browser.isIE?1:0,_24=_22.join(isc.emptyString);_10.append(_24,this.fixedColWidths?isc.Canvas.spacerHTML(_17,_23):null,this.$9y)}}
_10.append(this.$5t);if(this.autoSendTarget&&this.target)_10.append(this.$11f());var _25=_3.length,_26=false;var _27=this;var _28=function completeInnerHTMLFun(_32){if(_32!=null){var _29=_10.getArray();_29.push.apply(_29,_32)}
if(_25>0)_10.append(_27.$5t);if(_27.writeFormTag&&!_27.isPrinting)_10.append(_27.$90);else _10.append(_27.$127r);var _30=_10.release(false);if(_26){_27.fireCallback(_1,"HTML",[_30]);return false}else{return _30}};if(_25>0){var _31=[],_32=new Array(_25),_33=0;var _34=function itemCompletedFun(){if(++_33==_25){return _28(_32)}};var _35;for(var _5=0;_5<_25;++_5){var _6=_3[_5],_36=isc.SB.create(),_8,_37,_38,_39,_40,_41;if(!_6){_35=_34();continue}
_8=_6.visible;_6.$10x();if(this.logIsDebugEnabled())this.logDebug("Drawing FormItem: "+_6);if(!_6.alwaysTakeSpace&&!_8){_35=_34();continue}
if((_6.rowSpan==0||_6.colSpan==0)&&_5<_25-1){_31.add(_6);_35=_34();continue}
_37=_6.getFieldName();_38=_6.getErrors();_39=_6.getValue();_40=this.getTitleOrientation(_6);if(isc.is.emptyString(_38))_38=null;if(_6.$8l||_5==0){if(_5!=0){_36.append(this.$5t)}
if(_6.$8n&&_6.$8n.length>0){for(var i=0;i<_6.$8n.length;i++){_36.append(this.$5s);var _42=this.numCols;for(var _43=0;_43<_6.$8n[i];_43++){_36.append(this.$5u,"&nbsp;",this.$5v)}
_36.append(this.$5t)}}
_36.append(this.$5s);if(_6.$8o>0){for(var i=0;i<_6.$8o;i++)_36.append(this.$5u,this.$5v)}}
if(_40==isc.Canvas.LEFT){_36.append(this.getTitleCellHTML(_6,_38))}
_36.append(this.getCellStartHTML(_6,_38));if(_8&&_40==isc.Canvas.TOP){if(this.shouldClipTitle(_6)){_36.append(this.getTitleCellInnerHTML(_6,_38))}else{_36.append(this.getTitleSpanHTML(_6,_38),this.$9z)}}
_41=(_8&&_38&&this.showInlineErrors);if(_41&&_6.getErrorOrientation()==isc.Canvas.TOP){_36.append(this.getItemErrorHTML(_6,_38))}
var _44=(function(_5,_6,_36,_8,_37,_38,_39,_40,_41){var _45=function func(_30){_36.append(_30);if(_41&&_6.getErrorOrientation()==isc.Canvas.BOTTOM){_36.append(_27.getItemErrorHTML(_6,_38))}
_36.append(_27.getCellEndHTML(_6,_38));if(_40==isc.Canvas.RIGHT){_36.append(_27.getTitleCellHTML(_6,_38))}
_32[_5]=_36.release(false);return _34()};return function(_49){if(_49!=null){var _46=_36.getArray();_46.push.apply(_46,_49)}
if(_8){if(_27.isPrinting){var _47=_6.getPrintHTML(_27.currentPrintProperties,_45);if(_47==null){return false}else{return _45(_47)}}else{return _45(_6.getInnerHTML(_39,true,_27.showInlineErrors))}}else return _45(isc.Canvas.spacerHTML(_6.width,_6.height))}})(_5,_6,_36,_8,_37,_38,_39,_40,_41);var _48=_31.length;if(_48>0){var _49=new Array(_48);var _50=(function(_44,_48,_49){var _51=0;return function(){if(++_51==_48){return _44(_49)}}})(_44,_48,_49);for(var m=0;m<_48;++m){var _53=_31[m];if(!_53.visible){_50();continue}
var _54=(function(_49,_50,m){return function(_30){_49[m]=_30;return _50()}})(_49,_50,m);if(this.isPrinting){var _47=_53.getPrintHTML(_27.currentPrintProperties,_54);if(_47==null){_26=true}else{_35=_54(_47)}}else{_35=_54(_53.getInnerHTML(_53.getValue()))}}
_31.length=0}else{_35=_44()}
if(_35===false)_26=true}
if(_26){return false}else{return _35}}else{return _28()}});isc.evalBoundary;isc.B.push(isc.A.getPrintChildren=function isc_DynamicForm_getPrintChildren(){return null},isc.A.getCanvasItemCanvii=function isc_DynamicForm_getCanvasItemCanvii(){var _1=this.items||[],_2=[];for(var i=0;i<_1.length;i++){if(_1[i].isA("CanvasItem")&&isc.isA.Canvas(_1[i].canvas)){_2.add(_1[i].canvas)}}
return _2},isc.A.createErrorItem=function isc_DynamicForm_createErrorItem(){var _1=isc.addProperties({cellStyle:this.errorItemCellStyle},this.errorItemDefaults,this.errorItemProperties);if(isc.screenReader)_1.canFocus=true;this.addItems([_1],0);this.$52o=this.getItem(0)},isc.A.getErrorsHTML=function isc_DynamicForm_getErrorsHTML(_1){if(!_1||isc.isAn.emptyObject(_1))return isc.emptyString;var _2=isc.SB.create(),_3=" : ";_2.append(this.errorsPreamble,"<ul>");for(var _4 in _1){var _5=this.getItem(_4),_6;if(_5!=null){_6=_5.getErrorMessage(_1[_4]);_2.append("<li>",_5.getTitle(),_3,_6,"</li>")}else{_6=_1[_4];if(isc.isAn.Array(_6)){_6="<ul><li>"+_6.join("</li><li>")+"</li></ul>"}
_2.append("<li>",_4,_3,_6,"</li>")}}
_2.append("</ul>");return _2.release()},isc.A.getItemErrorHTML=function isc_DynamicForm_getItemErrorHTML(_1,_2){return _1.getErrorHTML(_2)},isc.A.$11f=function isc_DynamicForm__getAutoSendTargetHTML(){this.$91[1]=this.autoSendTargetFieldName;this.$91[3]=this.target;return this.$91.join(isc.emptyString)},isc.A.getCellStartHTML=function isc_DynamicForm_getCellStartHTML(_1,_2){var _3=_1.getColSpan(),_4=_1.$135a!=null?_1.$135a:_1.getRowSpan();if(_3==0)_3=1;if(_4==0)_4=1;if(_3=="*"){var _5=(_1.$8m?_1.$8m[0]:0);_3=(this.numCols-_5)}
var _6=_1.getCellStyle();var _7=this.fixedRowHeights||_1.shouldFixRowHeight();var _8=_1.$8t?_1.$8t[1]:null;if(isc.isA.Number(_8)&&this.cellSpacing!=0)_8-=2*this.cellSpacing;if(isc.Browser.isStrict&&isc.isA.Number(_8)&&this.cellPadding!=0){_8-=2*this.cellPadding}
return this.$11g((_1.align?_1.align:((this.form?this.form.isRTL():this.isRTL())?isc.Canvas.RIGHT:isc.Canvas.LEFT)),_1.vAlign,_6,_4,_3,null,(_7?_8:null),null,_1.cssText,(this.form?this.form.getID():this.getID()),_1.getItemID(),_1.getFormCellID(),_1.$187i())},isc.A.$11g=function isc_DynamicForm__getCellStartHTML(_1,_2,_3,_4,_5,_6,_7,_8,_9,_10,_11,_12,_13){var _14=isc.StringBuffer.create(),_15=isc.$ad;_14.append("<TD ALIGN=",_1,(_2==null?_15:" VALIGN="+_2),(_3!=null?" CLASS='"+_3+"'":_15)," STYLE='",(_9!=null?_9:_15),"'",(_4>1?" ROWSPAN="+_4:_15),(_5>1?" COLSPAN="+_5:_15),(_6!=null?" WIDTH="+_6:_15),(_7!=null?" HEIGHT="+_7:_15),(_8!=null?_8:_15));if(_12){_14.append(" ID=",_12," ")}
if(_11&&_10){_14.append(isc.DynamicForm.$89,"='",_11,"'")}
_14.append(_13?"><NOBR>":">");return _14.release(false)},isc.A.getCellEndHTML=function isc_DynamicForm_getCellEndHTML(_1,_2){return this.$11h()},isc.A.$11h=function isc_DynamicForm__getCellEndHTML(_1){return _1?"</NOBR></TD>":"</TD>"},isc.A.getTitleOrientation=function isc_DynamicForm_getTitleOrientation(_1){if(_1&&!_1.shouldShowTitle())return null;return(_1?_1.titleOrientation:null)||this.titleOrientation||isc.Canvas.LEFT},isc.A.getTitleAlign=function isc_DynamicForm_getTitleAlign(_1){var _2=this.form||this;return(_1.titleAlign?_1.titleAlign:this.titleAlign?this.titleAlign:this.isRTL()?isc.Canvas.LEFT:isc.Canvas.RIGHT)},isc.A.getTitleVAlign=function isc_DynamicForm_getTitleVAlign(_1){var _2=(_1.titleVAlign?_1.titleVAlign:this.titleVAlign?this.titleVAlign:isc.Canvas.CENTER);return(_2==isc.Canvas.CENTER?isc.Canvas.MIDDLE:_2)},isc.A.getTitleHeight=function isc_DynamicForm_getTitleHeight(_1){var _2=this.form||this;return(_1.titleHeight!=null?_1.titleHeight:this.titleHeight)},isc.A.getTitleSpanHTML=function isc_DynamicForm_getTitleSpanHTML(_1,_2){var _3=isc.StringBuffer.create();_3.append("<SPAN ",this.$11i(_1)," CLASS='",_1.getTitleStyle(),"' ALIGN=",this.getTitleAlign(_1),">");_3.append(this.getTitleHTML(_1,_2));_3.append("</SPAN>");return _3.release(false)},isc.A.shouldClipTitle=function isc_DynamicForm_shouldClipTitle(_1){if(!_1||!_1.form==this)return false;return(_1.clipTitle!=null?_1.clipTitle:!!this.clipItemTitles)},isc.A.getTitleCellHTML=function isc_DynamicForm_getTitleCellHTML(_1,_2){var _3=isc.StringBuffer.create(),_4=_1.getTitleStyle(),_5=this.getTitleAlign(_1),_6=this.getTitleVAlign(_1);var _7=this.$99;_7[1]=this.$11i(_1);_7[3]=_4;_7[5]=_5;_7[7]=_6;var _8=_1.$135a;if(_8==null)_8=_1.getRowSpan();if(_8>1)_7[9]=" ROWSPAN="+_8;else _7[9]=null;if(_1.getTitleColSpan()>1)_7[10]=" COLSPAN="+_1.getTitleColSpan();else _7[10]=null;_3.append(_7.join(isc.emptyString));_3.append(this.getTitleCellInnerHTML(_1,_2));_3.append(this.$98);return _3.release(false)},isc.A.getTitleCellInnerHTML=function isc_DynamicForm_getTitleCellInnerHTML(_1,_2){var _3=isc.StringBuffer.create(),_4=_1.getTitleStyle(),_5=this.getTitleAlign(_1),_6=this.getTitleOrientation(_1),_7=_1.$8u||null,_8=_1.$8t?_1.$8t[1]:null,_9=this.shouldClipTitle(_1),_10=(_1.wrapTitle!=null?_1.wrapTitle:(this.wrapItemTitles!=null?this.wrapItemTitles:!_9));if(_6==this.$o0&&_1.$8t){_7=Math.max(_1.$8t[0],_7==null?0:_7)}
if(_8){if(this.cellSpacing)_8-=2*this.cellSpacing;var _11,_12;if(_4){_11=isc.Element.$tt(_4,true);_12=isc.Element.$tu(_4,true)}
if(_11==null)_11=this.cellPadding||0;if(_12==null)_12=this.cellPadding||0;_8-=(_11+_12)
if(_4)_8-=isc.Element.$ym(_4)}
if(_7){if(this.cellSpacing)_7-=2*this.cellSpacing;var _13,_14;if(_4){_13=isc.Element.$tr(_4,true);_14=isc.Element.$ts(_4,true)}
if(_13==null)_13=this.cellPadding||0;if(_14==null)_14=this.cellPadding||0;_7-=(_13+_14)
_7-=isc.Element.$yn(_4)}
var _15=isc.Browser.isMoz?this.$94:this.$92,_16=isc.Browser.isMoz?this.$11j:this.$93;if(_9){if(this.$10a==null){this.$10a=["<DIV style='overflow:hidden;","white-space:nowrap;",,"' ",isc.DynamicForm.$9a,"='",isc.DynamicForm.$9g,"' ",isc.DynamicForm.$89,"='",,"'>"];if(this.emitOuterTextOverflow){this.$10a[0]+=isc.Browser.$114w+":ellipsis;"}}
var _17=this.$10a;if(_7!=null)_17[2]=_16+_7+"px;";else _17[2]=null;_17[10]=_1.getID();_3.append(_17.join(isc.emptyString))}else if(!_10){_3.append(this.$95)}
_3.append(this.getTitleHTML(_1,_2,_9));if(_9){_3.append(this.$97)}
return _3.release(false)},isc.A.$11i=function isc_DynamicForm__containsItemTitleAttrHTML(_1){if(!isc.DynamicForm.$11k){isc.DynamicForm.$11l=[" ",isc.DynamicForm.$89,"='",null,"' ",isc.DynamicForm.$9a,"='",isc.DynamicForm.$9g,"' ","ID="]}
isc.DynamicForm.$11l[3]=_1.getItemID();isc.DynamicForm.$11l[10]=this.$427(_1);return isc.DynamicForm.$11l.join(isc.emptyString)},isc.A.$427=function isc_DynamicForm__getTitleCellID(_1){return this.$qs(_1.getID()+this.$63z)},isc.A.getTitleCell=function isc_DynamicForm_getTitleCell(_1){if(!this.isDrawn())return null;_1=this.getItem(_1);if(!_1)return null;return isc.Element.get(this.$427(_1))},isc.A.updateTitleCellState=function isc_DynamicForm_updateTitleCellState(_1){var _2=this.getTitleCell(_1);if(_2==null)return;_1=this.getItem(_1);_2.className=_1.getTitleStyle();_2.innerHTML=this.getTitleCellInnerHTML(_1,_1.getErrors())},isc.A.$1140=function isc_DynamicForm__getTitleClipperID(_1){return this.$qs(_1.getID()+this.$114x)},isc.A.$1141=function isc_DynamicForm__getTitleClipper(_1){if(!this.isDrawn())return null;_1=this.getItem(_1);if(!_1)return null;return isc.Element.get(this.$1140(_1))},isc.A.titleClipped=function isc_DynamicForm_titleClipped(_1){var _2=this.$1141(_1);return(_2!=null&&isc.Element.getClientWidth(_2)<_2.scrollWidth)},isc.A.getTitleHTML=function isc_DynamicForm_getTitleHTML(_1,_2,_3){var _4=isc.StringBuffer.create();var _5=_1.visible?_1.getTitleHTML():null;if(_5){var _6=this.isRequired(_1,true),_7=this.getTitleOrientation(_1),_8=(_7==isc.Canvas.LEFT||_7==isc.Canvas.TOP);if(_3){var _9=this.$114z;if(_6&&this.hiliteRequiredFields){if(_8){var _10=this.exclusiveRequiredTitlePrefix,_11=this.exclusiveRequiredTitleSuffix;if(_10==null){if(this.requiredTitlePrefix.endsWith(this.titlePrefix)){_10=this.requiredTitlePrefix.substring(0,this.requiredTitlePrefix.length-this.titlePrefix.length)}else{_10=this.requiredTitlePrefix}}
if(_11==null){if(this.requiredTitleSuffix.startsWith(this.titleSuffix)){_11=this.requiredTitleSuffix.substring(this.titleSuffix.length)}else{_11=this.requiredTitleSuffix}}
_9[0]=_10;_9[2]=this.requiredTitleSuffix.substring(0,this.requiredTitleSuffix.length-_11.length);_9[4]=this.$1140(_1);_9[10]=this.requiredTitlePrefix.substring(_10.length);_9[11]=_5;_9[13]=_11}else{var _12=this.exclusiveRequiredRightTitlePrefix,_13=this.exclusiveRequiredRightTitleSuffix;if(_12==null){if(this.requiredRightTitlePrefix.endsWith(this.rightTitlePrefix)){_12=this.requiredRightTitlePrefix.substring(0,this.requiredRightTitlePrefix.length-this.rightTitlePrefix.length)}else{_12=this.requiredRightTitlePrefix}}
if(_13==null){if(this.requiredRightTitleSuffix.startsWith(this.rightTitleSuffix)){_13=this.requiredRightTitleSuffix.substring(this.rightTitleSuffix.length)}else{_13=this.requiredRightTitleSuffix}}
_9[0]=_12;_9[2]=this.requiredRightTitleSuffix.substring(0,this.requiredRightTitleSuffix.length-_13.length);_9[4]=this.$1140(_1);_9[10]=this.requiredRightTitlePrefix.substring(_12.length);_9[11]=_5;_9[13]=_13}}else{if(_8){_9[0]=this.exclusiveTitlePrefix;_9[2]=this.titleSuffix.substring(0,this.titleSuffix.length-this.exclusiveTitleSuffix.length);_9[4]=this.$1140(_1);_9[10]=this.titlePrefix.substring(this.exclusiveTitlePrefix.length);_9[11]=_5;_9[13]=this.exclusiveTitleSuffix}else{_9[0]=this.exclusiveRightTitlePrefix;_9[2]=this.rightTitleSuffix.substring(0,this.rightTitleSuffix.length-this.exclusiveRightTitleSuffix.length);_9[4]=this.$1140(_1);_9[10]=this.rightTitlePrefix.substring(this.exclusiveRightTitlePrefix.length);_9[11]=_5;_9[13]=this.exclusiveRightTitleSuffix}}
_4.append.apply(_4,_9)}else{_4.append((_6&&this.hiliteRequiredFields?(_8?this.requiredTitlePrefix:this.requiredRightTitlePrefix):(_8?this.titlePrefix:this.rightTitlePrefix)),_5,(_6&&this.hiliteRequiredFields?(_8?this.requiredTitleSuffix:this.requiredRightTitleSuffix):(_8?this.titleSuffix:this.rightTitleSuffix)))}}else{_4.append("&nbsp;")}
return _4.release(false)},isc.A.getFormTagStartHTML=function isc_DynamicForm_getFormTagStartHTML(){var _1=this.$10c,_2=this.getFormID(),_3=this.getID();_1[3]=_2;if(this.$11e())_1[4]=this.$10e;else _1[4]=null;_1[6]=this.method;_1[8]=this.action;if(this.isMultipart())_1[10]=isc.DynamicForm.MULTIPART_ENCODING;else _1[10]=isc.DynamicForm.NORMAL_ENCODING;if(this.target!=null){_1[11]=this.$10f;_1[12]=this.target;_1[13]=this.$ob}else{_1[11]=null;_1[12]=null;_1[13]=null}
_1[15]=_3;_1[17]=_3;return _1.join(isc.emptyString)},isc.A.$174w=function isc_DynamicForm__writeWidthAttribute(){return this.writeWidthAttribute},isc.A.getTableStartHTML=function isc_DynamicForm_getTableStartHTML(){var _1=isc.isA.DynamicForm(this),_2=_1?this.$10g:isc.DynamicForm.getPrototype().$10g;_2[1]=this.$11n();if(this.isPrinting){_2[2]=_1?this.$119i:isc.DynamicForm.getPrototype().$119i;_2[3]="100%"}else if(!!this.$174w()){_2[2]=_1?this.$119i:isc.DynamicForm.getPrototype().$119i;_2[3]=(this.getInnerContentWidth!=null?this.getInnerContentWidth():this.getInnerWidth())}else{_2[3]=_2[2]=null}
_2[5]=this.cellSpacing;_2[7]=this.cellPadding;_2[9]=this.cellBorder;return _2.join(isc.emptyString)},isc.A.$11n=function isc_DynamicForm__getTableElementID(){return this.$qs(this.$10h)},isc.A.$11o=function isc_DynamicForm__getTableElement(){return isc.Element.get(this.$11n())},isc.A.layoutChildren=function isc_DynamicForm_layoutChildren(_1,_2,_3,_4){this.invokeSuper(isc.DynamicForm,"layoutChildren",_1,_2,_3,_4);var _5=this.getItems();if(!_5)return;for(var i=0;i<_5.length;i++){var _7=_5[i].width,_8=_5[i].height;if((isc.isA.String(_7)&&(_7.contains("%")||_7.contains("*")))||(isc.isA.String(_8)&&(_8.contains("%")||_8.contains("*"))))
{this.markForRedraw("size change with dynamic size children");break}}},isc.A.getAbsPosHTML=function isc_DynamicForm_getAbsPosHTML(){var _1=isc.SB.create();for(var _2=0,_3=this.items.length;_2<_3;_2++){var _4=this.items[_2];if(!_4)continue;_4.$10x();if(!_4.visible)continue;var _5=!_4.$712(),_6=this.showInlineErrors;_1.append(_4.getStandaloneItemHTML(_4.getValue(),_5,_6))}
return _1.release(false)},isc.A.getScrollWidth=function isc_DynamicForm_getScrollWidth(_1){if(this.$qz){this.$qz=null;this.adjustOverflow("widthCheckWhileDeferred")}
if(!_1&&this.$su!=null)return this.$su;var _2;if(!isc.Browser.isIE||!this.$11e()||!(this.isDrawn()||this.handleDrawn())||this.items==null)
{_2=isc.Canvas.$b4.getScrollWidth.call(this,_1)}else{_2=0;for(var i=0;i<this.items.length;i++){var _4=this.items[i];if(_4.visible==false||!_4.isDrawn())continue;var _5=_4.getAbsDiv();if(_5){var _6=_5.scrollWidth+_4.$11p(_4.left);if(_6>_2)_2=_6}}}
this.$su=_2;return _2},isc.A.getScrollHeight=function isc_DynamicForm_getScrollHeight(_1){if(this.$qz){this.$qz=null;this.adjustOverflow("heightCheckWhileDeferred")}
if(!_1&&this.$sz!=null)return this.$sz;var _2;if(!isc.Browser.isIE||!this.$11e()||!(this.isDrawn()||this.handleDrawn())||this.items==null)
{_2=isc.Canvas.$b4.getScrollHeight.call(this,_1)}else{_2=0;for(var i=0;i<this.items.length;i++){var _4=this.items[i];if(_4.visible==false||!_4.isDrawn())continue;var _5=_4.getAbsDiv();if(_5){var _6=_5.scrollHeight+_4.$11p(_4.top,true);if(_6>_2)_2=_6}}}
this.$sz=_2;return _2},isc.A.$11q=function isc_DynamicForm__formWillSubmit(){return this.canSubmit||this.isMultipart()||(this.action!=isc.DynamicForm.getPrototype().action)},isc.A.submitForm=function isc_DynamicForm_submitForm(){if(!this.$11q()){this.logWarn("Attempt to perform direct submission on DynamicForm where this.canSubmit is false. Please set this property to true, or use the standard databinding interfaces to send data to the server.")}
if(this.getFileItemForm()!=null){this.logWarn("Performing a direct submission on a DynamicForm containing a FileItem. Note: This item's value will not be submitted to the server.  FileItems are intended for use with databound forms backed by the SmartClient server only.  If you are not using the SmartClient Databinding subsystem, use an UploadItem rather than a FileItem to submit a file as part of a raw HTTP request. Otherwise use saveData() rather than a direct call to submitForm() to save the full set of values for the form.")}
var _1=this.getForm();if(!_1)return;if(_1.action!=this.action)_1.action=this.action;try{return _1.submit()}catch(e){this.logWarn("Form submission was unsuccessful. In some browsers this can occur when an upload item is present and has an invalid value.\n"+e.message);this.formSubmitFailed()}},isc.A.performImplicitSave=function isc_DynamicForm_performImplicitSave(_1,_2){this.implicitSaveInProgress=true;if(_1){if(_1.$887){_1.parentItem.updateValue()}
if(_1.$da!=null)isc.Timer.clear(_1.$da)}
if(this.awaitingImplicitSave)delete this.awaitingImplicitSave;this.logInfo("performImplicitSave called "+(!_2?"by editorExit()":"after implicitSaveDelay ("+this.implicitSaveDelay+"ms)")+" for item "+_1.name+".");if(this.valuesManager){this.valuesManager.saveData(this.getID()+".$888(data)",{showPrompt:false})}else{this.saveData(this.getID()+".$888(data)",{showPrompt:false})}},isc.A.$95x=function isc_DynamicForm__addItemToImplicitSaveUpdateArray(_1){var _2=this.valuesManager?this.valuesManager:this;if(!_2.itemsToUpdateState)_2.itemsToUpdateState=[];_1.awaitingImplicitSave=true;_2.itemsToUpdateState.add(_1);_1.updateState()},isc.A.$888=function isc_DynamicForm__implicitSaveCallback(_1){delete this.implicitSaveInProgress;var _2=this.valuesManager?this.valuesManager:this;if(_2.itemsToUpdateState){for(var i=0;i<_2.itemsToUpdateState.length;i++){var _4=_2.itemsToUpdateState[i];delete _4.awaitingImplicitSave;_4.wasAwaitingImplicitSave=true;_4.updateState()}
delete _2.itemsToUpdateState}
this.implicitSaveCallback(_1)},isc.A.implicitSaveCallback=function isc_DynamicForm_implicitSaveCallback(_1){},isc.A.formSubmitFailed=function isc_DynamicForm_formSubmitFailed(){isc.warn(this.formSubmitFailedWarning);var _1=this.getValues()._transaction;if(_1!=null&&isc.RPCManager&&isc.XMLTools){var _2=isc.XMLTools.parseXML(this.getValues()._transaction),_3;if(_2)_3=isc.XMLTools.selectNumber(_2,"//transactionNum");if(_3!=null){isc.RPCManager.doClearPrompt(_3);isc.RPCManager.clearTransaction(_3)}
var _4=this.getItem("_transaction");if(_4&&isc.isA.HiddenItem(_4)){this.clearValue("_transaction")}}},isc.A.setAction=function isc_DynamicForm_setAction(_1,_2){this.action=_1;var _3=this.getForm();if(_3)_3.action=_1;this.$66g=!_2},isc.A.setTarget=function isc_DynamicForm_setTarget(_1){this.target=_1;var _2=this.getForm();if(_2)_2.target=_1},isc.A.setMethod=function isc_DynamicForm_setMethod(_1){this.method=_1;var _2=this.getForm();if(_2)_2.method=_1},isc.A.getFileItemForm=function isc_DynamicForm_getFileItemForm(){if(!isc.FileItem)return null;var _1=this.getItems()||[];var _2=false,_3=null;for(var i=0;i<_1.length;i++){if(isc.isA.FileItem(_1[i])){if(_2){this.$1839=true;this.logWarn("This DynamicForm contains more than one item of type FileItem. This is not supported - a DynamicForm can only support a single FileItem.");continue}
var _5=_1[i].canvas;if(isc.isA.DynamicForm(_5)){_2=true;_3=_5;if(this.$1839)break}}}
return _3},isc.A.$114v=function isc_DynamicForm__propagateOperationsToFileItem(){var _1=this.getFileItemForm();if(_1!=null){_1.fetchOperation=this.fetchOperation;_1.updateOperation=this.updateOperation;_1.addOperation=this.addOperation;_1.removeOperation=this.removeOperation}},isc.A.$10d=function isc_DynamicForm__handleNativeSubmit(){return false},isc.A.validate=function isc_DynamicForm_validate(_1,_2,_3,_4,_5,_6,_7){if(this.disableValidation)return true;if(this.dataSource&&this.dataSource.useLocalValidators!=null&&this.useLocalValidators==false)return true;var _8=this.hasErrors(),_9=false,_10=this.getForm(),_11=false;var _12={},_13={},_14=this.getValues(),_15=this.$181h(true,_14),_16=(_1&&!_2&&this.dataSource)?isc.addProperties({},this.getDataSource().getFields()):null;var _17={unknownErrorMessage:this.unknownErrorMessage,serverValidationMode:"full"};if(_3)
_17.typeValidationsOnly=_3;if(_5)
_17.skipServerValidation=_5;else
_17.deferServerValidation=true;var _18=isc.rpc?isc.rpc.startQueue():false;var _19=[];for(var _20=0;_20<this.items.length;_20++){var _21=false,_22=this.items[_20],_23=_22.getFieldName(),_24=_22.getTrimmedDataPath()||_22.getFieldName(),_25=_22.getValue(),_26=!_22.visible||isc.isA.HiddenItem(_22);if(_26&&!_1)continue;if(!_23&&!_24){if(_22.validators!=null){this.logWarn("Item with index "+_20+" has no name or dataPath - can't validate.");continue}}
if(_22.validators!=null){if(!isc.isAn.Array(_22.validators)){_22.validators=[_22.validators]}
var _27=this.validateField(_22,_22.validators,_25,_15,_17);if(_27!=null){if(_27.needsServerValidation){_19.add(_22)}
if(_27.errors!=null){_21=this.addValidationError(_12,_23||_24,_27.errors);if(_21)_9=true}
if(_27.resultingValue!=null&&this.compareValues(_25,_27.resultingValue,_22))
{_25=_27.resultingValue;if(_24){isc.DynamicForm.$70n(_24,_22,_25,_14,this,true,"validate")}else if(_23){_14[_23]=_25}
_11=true}}}
if(_26&&_21)_13[_23||_24]=_12[_23||_24];if(_16)delete _16[_23]}
if(this.rulesEngine!=null){var _28=this.rulesEngine.applyFieldValidators(_12,this);if(_28)_9=true}
if(_16){_17.dontValidateNullValue=true;delete _17.typeValidationsOnly;_17.validatingDsFields=true;for(var i in _16){var _30=_16[i],_31=i,_32=_30.validators;if(_32!=null){var _25=_14[_31];var _27=this.validateField(_30,_32,_25,_14,_17);if(_27!=null&&_27.errors!=null){this.addValidationError(_12,_31,_27.errors)}}
if(_12[_31]!=null)_13[_31]=_12[_31]}}
if(_19.length>0){this.validateFieldsOnServer(_19,_15,_17,_7)}
if(!_18&&isc.rpc)isc.rpc.sendQueue();if(_9)this.logInfo("Validation errors: "+isc.Log.echoAll(_12));if(_4)return(_9?_12:true);this.setErrors(_12);if(_11){this.setItemValues(_14,null,null,null,true);for(var _33 in _14){if(this.getItem(_33)==null)this.$10w(_33,_14[_33])}}
if(!_6&&(_9||_8)){this.showErrors(_12,_13)}
return!_9},isc.A.$181h=function isc_DynamicForm__getRecordForValidation(_1,_2){var _3=this.valuesManager;if(_3!=null){var _4=_1?_3.getValues():isc.addProperties({},_3.values);if(this.dataPath!=null){_4=isc.DynamicForm.$70o(this.dataPath,null,_4,this,true)}
return _4}
var _5;if(_2!==_5)return _2;return isc.addProperties({},_1?this.getValues():this.values)},isc.A.valuesAreValid=function isc_DynamicForm_valuesAreValid(_1,_2){var _3=this.validate(_1,null,null,true,true);if(_3===true){return(_2?null:true)}else{return(_2?_3:false)}},isc.A.checkForValidationErrors=function isc_DynamicForm_checkForValidationErrors(_1,_2,_3){var _4=this.validate(_2,null,null,true,true);if(_4===true)_4=null;if(_4||_3){if(_1!=null)this.fireCallback(_1,"errorMap",[_4]);return _4}
if(!_1){this.logWarn("checkForValidationErrors(): no callback has been provided, but not skipping server-side validation - this is invalid usage");return}
var _5=this.getValues(),_6=this.buildRequest(null,"validate");_6.editor=this;var _7=this.getDataSource();_7.validateData(_5,function(_8,_9){var _4=_8.status==isc.RPCResponse.STATUS_VALIDATION_ERROR&&_8.errors?_8.errors:null;this.fireCallback(_1,"errorMap",[_4])},_6)},isc.A.getValidatedValues=function isc_DynamicForm_getValidatedValues(){if(!this.validate())return null;return this.getValues()},isc.A.showErrors=function isc_DynamicForm_showErrors(_1,_2){var _3=!this.autoFocusOnError||this.$116a;if(this.$116a)delete this.$116a;var _4;if(_2===_4)_2=this.getHiddenErrors();if(_1===_4)_1=this.getErrors();if(_1&&!this.showInlineErrors&&(!this.$52o||this.$52o.destroyed||!this.items.contains(this.$52o)))
{this.createErrorItem()}
this.markForRedraw("Validation Errors Changed");if(_1&&!isc.isAn.emptyObject(_1)&&!_3){for(var _5 in _1){var _6=this.getItem(_5);if(_6&&_6.isVisible()&&_6.isDrawn()){this.$11b(_6);break}}}
if(!this.showInlineErrors){this.delayCall("scrollIntoView",[0,0],100)}
if(_2){this.$21z(_2)}},isc.A.getHiddenErrors=function isc_DynamicForm_getHiddenErrors(){if(!this.errors)return null;var _1=false,_2={};for(var _3 in this.errors){var _4=this.getItem(_3);if(!_4||!_4.visible){_1=true;_2[_3]=this.errors[_3]}}
return(_1?_2:null)},isc.A.showFieldErrors=function isc_DynamicForm_showFieldErrors(_1,_2){var _3;if(_2)this.$116a=true;return this.showErrors()},isc.A.$21z=function isc_DynamicForm__handleHiddenValidationErrors(_1){if(_1==null||isc.isAn.emptyObject(_1))return;var _2;if(this.handleHiddenValidationErrors){_2=this.handleHiddenValidationErrors(_1)}
if(_2==false)return;var _3="Validation errors occurred for the following fields with no visible form items:";for(var _4 in _1){var _5=_1[_4];if(!isc.isAn.Array(_5))_5=[_5];if(_5.length==0)continue;_3+="\n"+_4+":";for(var i=0;i<_5.length;i++){_3+=(i==0?"- ":"\n - ")+_5[i]}}
this.logWarn(_3,"validation")},isc.A.isRequired=function isc_DynamicForm_isRequired(_1,_2){return((_2?true:isc.DynamicForm.canEditField(_1,this))&&(_1.required||_1.$11m||this.isXMLRequired(_1)))},isc.A.setRequiredIf=function isc_DynamicForm_setRequiredIf(){var _1=this.getValues();for(var _2=0;_2<this.items.length;_2++){var _3=this.items[_2],_4=_3.validators;delete _3.$11m;if(!_3.visible||!_4||_4.length==0)continue;for(var v=0;v<_4.length;v++){var _6=_4[v];if(!_6)continue;var _7=isc.Validator.getValidatorType(_6);if(_7==this.$10i){var _8=_3.getValue();if(_6.expression!=null&&!isc.isA.Function(_6.expression)){isc.Func.replaceWithMethod(_6,"expression","item,validator,value,record")}
_3.$11m=_6.expression.apply(this,[_3,_6,_8,_1])}else if(_7==this.$842){_3.$11m=true}}}},isc.A.$170m=function isc_DynamicForm__restoreFocusForClickMaskHide(){this.setFocus(true,true)},isc.A.setFocusItem=function isc_DynamicForm_setFocusItem(_1,_2){_1=this.getItem(_1);this.$10n=_1;this.$189e=_2;if(this.hasStableLocalID()){var _3=this.getLocalId()+".focusField",_4=_1&&this.isFocused()?_1.name:null,_5=this.$1671(_3);if(_4!=_5)this.provideRuleContext(_3,_4,this)}},isc.A.isFocused=function isc_DynamicForm_isFocused(){if(this.Super("isFocused",arguments)==true)return true;var _1=this.getFocusItem();if(_1&&isc.isA.CanvasItem(_1)&&_1.isFocused()){return true}
return false});isc.evalBoundary;isc.B.push(isc.A.getFocusItem=function isc_DynamicForm_getFocusItem(){var _1=this.getFocusSubItem();if(_1!=null){while(_1.parentItem!=null){_1=_1.parentItem}}
return _1},isc.A.getFocusSubItem=function isc_DynamicForm_getFocusSubItem(){return this.$10n},isc.A.getFocusItemIcon=function isc_DynamicForm_getFocusItemIcon(){return this.$189e},isc.A.$vl=function isc_DynamicForm__readyToSetFocus(){return!this.isDisabled()},isc.A.setFocus=function isc_DynamicForm_setFocus(_1,_2){if(!this.$vl())return;var _3=this.isVisible();if(_1){var _4=this.getFocusSubItem();if(_4==null){var _5=this.getItems();if(_5!=null){for(var i=0;i<_5.length;i++){var _7=_5[i];if(_7.$kk()&&_7.isDrawn()&&_7.isVisible()&&!_7.isDisabled())
{_4=_7;break}}}}
var _8=(_2&&_4?this.getFocusItemIcon():null);var _9=isc.EH.lastEvent;if(_4!=null&&!(_9.target==this&&_9.eventType==isc.EH.MOUSE_DOWN)){return this.focusInItem(_4,_8)}}
this.Super("setFocus",arguments);if(!_1){this.$11r(this.getFocusSubItem())}},isc.A.$kf=function isc_DynamicForm__focusInNextTabElement(_1){var _2=this.getFocusSubItem();if(_2==null){this.Super("$kf",arguments)}else{if(this.logIsDebugEnabled("syntheticTabIndex")){this.logDebug("Telling focus item:"+_2+" to shift focus")}
_2.$kf(_1)}},isc.A.syntheticShiftFocus=function isc_DynamicForm_syntheticShiftFocus(_1){return false},isc.A.useExplicitFocusNavigationForCanvasItem=function isc_DynamicForm_useExplicitFocusNavigationForCanvasItem(_1){if(this.alwaysManageFocusNavigation)return true;var _2=_1.containerWidget;if(_2!=this){return _2.useExplicitFocusNavigation()}
if(!this.parentElement)return false;return this.parentElement.useExplicitFocusNavigation()},isc.A.$11u=function isc_DynamicForm__canFocusInItem(_1,_2){if(isc.isA.String(_1))_1=this.getItem(_1);return _1&&_1.$kk()&&_1.isDrawn()&&_1.isVisible()&&!_1.isDisabled()&&(!_2||_1.tabIndex!=-1)},isc.A.focusInItem=function isc_DynamicForm_focusInItem(_1,_2){if(_1!=null){var _3=this.getItem(_1)}else{var _3=this.getFocusSubItem()}
if(!_3){if(_1!=null)this.logWarn("couldn't find focus item: "+_1);return}
if(_3.$kk()){if(!_2)_3.focusInItem();if(_2&&_3.focusInIcon)_3.focusInIcon(_2);this.setFocusItem(_3,_2);if(this.$10u){var _4=this;isc.Page.setEvent("idle",function(){if(!_4.destroyed)_4.focusInItem()},isc.Page.FIRE_ONCE)}}else{this.logWarn("focusInItem: item cannot accept focus: "+_3)}},isc.A.clearFocusItem=function isc_DynamicForm_clearFocusItem(){delete this.$10n;delete this.$189e;if(this.hasStableLocalID())this.provideRuleContext(this.getLocalId()+".focusField",null,this)},isc.A.blurFocusItem=function isc_DynamicForm_blurFocusItem(){var _1=this.getFocusSubItem();if(_1!=null){this.$11r(_1);this.clearFocusItem()}},isc.A.$11r=function isc_DynamicForm__blurItem(_1){if(_1!=null&&_1.hasFocus)_1.blurItem()},isc.A.$106=function isc_DynamicForm__blurFocusItemWithoutHandler(){var _1=this.getFocusSubItem();if(_1!=null&&_1.hasFocus){if(this.$11v==null)this.$11v=0;else this.$11v+=1;this.$11r(_1)}else{this.logDebug("blur w/o handler: no item to blur")}},isc.A.$11b=function isc_DynamicForm__focusInItemWithoutHandler(_1){if(!_1||!this.$11u(_1)){var _2;if(_1&&_1.parentItem){this.$11b(_1.parentItem);_2=true}
this.logInfo("$11b("+_1+"): not calling focus as item not focusable or item already has focus"+(_2?". Putting focus into containerItem instead.":""),"nativeFocus")
return}
var _3=_1.hasFocus;if(isc.Browser.isIE&&!isc.EH.synchronousFocusNotifications){var _4=isc.DynamicForm._getItemInfoFromElement(document.activeElement);_3=(_4&&_4.item==_1)}
if(_3)return;this.$65n(_1);this.focusInItem(_1)},isc.A.$65n=function isc_DynamicForm__suppressFocusHandlerForItem(_1){if(this.$11w==null)this.$11w=0;else this.$11w+=1;this.$11x=_1},isc.A.setOpacity=function isc_DynamicForm_setOpacity(_1,_2,_3,_4,_5,_6){var _7=this.opacity;this.invokeSuper(isc.DynamicForm,"setOpacity",_1,_2,_3,_4,_5,_6);_1=this.opacity;if(isc.Browser.isMoz&&this.hasFocus&&(_1!=_7)&&(_1==null||_1==100||_7==null||_7==100))
{var _8=this.getFocusSubItem();if(_8&&_8.$429()){this.$106();this.$11b(_8)}}},isc.A.clearingElement=function isc_DynamicForm_clearingElement(_1){if(this.$11w!=null&&this.$11x==_1){delete this.$11w;delete this.$11x}
if(this.$11v!=null&&(this.getFocusSubItem()==_1)){delete this.$11v}},isc.A.hide=function isc_DynamicForm_hide(){if(isc.Browser.isMoz)this.$11r(this.getFocusSubItem());this.Super("hide",arguments)},isc.A.setVisibility=function isc_DynamicForm_setVisibility(_1,_2,_3,_4){this.invokeSuper(isc.DynamicForm,"setVisibility",_1,_2,_3,_4);this.itemsVisibilityChanged();if(this.isVisible()&&this.isDrawn()&&this.autoFocus)this.focus()},isc.A.clear=function isc_DynamicForm_clear(){this.Super("clear",arguments);this.itemsVisibilityChanged()
this.$11a()},isc.A.$lf=function isc_DynamicForm__focusChanged(_1){this.Super("$lf",arguments);if(!this.hasFocus)this.$11r(this.getFocusSubItem());if(this.hasStableLocalID()&&!_1)this.provideRuleContext(this.getLocalId()+".focusField",null,this)},isc.A.parentVisibilityChanged=function isc_DynamicForm_parentVisibilityChanged(_1){if(!this.isVisible()&&isc.Browser.isMoz)this.$11r(this.getFocusSubItem());this.Super("parentVisibilityChanged",arguments);this.itemsVisibilityChanged();if(this.isVisible()&&this.autoFocus)this.focus()},isc.A.$kr=function isc_DynamicForm__allowNativeTextSelection(_1){if(_1==null)_1=isc.EH.lastEvent;var _2=this.$ne(_1);if(_2.item){var _3=_2.item.$kr(_1,_2);if(_3!=null)return _3}
return this.Super("$kr",arguments)},isc.A.$188y=function isc_DynamicForm__allowNativeDrag(_1){if(_1==null)_1=isc.EH.lastEvent;var _2=this.$ne(_1);if(_2.item){var _3=_2.item.$188y(_1,_2);if(_3!=null)return _3}
return this.Super("$188y",arguments)},isc.A.prepareForDragging=function isc_DynamicForm_prepareForDragging(_1,_2,_3,_4){var _5=this.ns.EH;if(_5.dragTarget)return;var _6=_5.lastEvent,_7=this.$ne(_6);if(_7.item&&(_7.overElement||_7.overTextBox||_7.overControlTable))return false;return this.invokeSuper(isc.DynamicForm,"prepareForDragging",_1,_2,_3,_4)},isc.A.$ne=function isc_DynamicForm__getEventTargetItemInfo(_1){if(!_1)_1=isc.EH.lastEvent;var _2=isc.EH.isMouseEvent(_1.eventType)?_1.nativeTarget:_1.nativeKeyTarget;var _3=isc.DynamicForm._getItemInfoFromElement(_2,this);_1.itemInfo=_3;_1.$172d=_1.DOMevent;return _3},isc.A.getEventItem=function isc_DynamicForm_getEventItem(){var _1=isc.EH.lastEvent.itemInfo;if(_1!=null&&!_1.inactiveContext&&!_1.overTitle)return _1.item;return null},isc.A.getEventItemInfo=function isc_DynamicForm_getEventItemInfo(){var _1=this.$ne();if(_1==null||_1.inactiveContext)return null;return{item:_1.item,overElement:_1.overElement,overtextBox:_1.overTextBox,overItem:(_1.overElement||_1.overTextBox||_1.overControlTable),overTitle:_1.overTitle,overInlineError:_1.overInlineError,icon:_1.overIcon}},isc.A.handleMouseStillDown=function isc_DynamicForm_handleMouseStillDown(_1,_2){if(isc.$cv)arguments.$cw=this;var _3=this.$ne(_1),_4=((_3.overTitle||_3.inactiveContext)?null:_3.item);if(_4!=null){if(_4.form!=this)return;if(_4.mouseStillDown){if(_4.handleMouseStillDown(_1)==false)return false}}},isc.A.handleMouseDown=function isc_DynamicForm_handleMouseDown(_1,_2){var _3=this.$ne(_1),_4=(_3.overTitle?null:_3.item);this.$921=_3;if(_4!=null){if(_4.form!=this)return;_4.handleMouseDown(_1);if(isc.Browser.isSafari&&!_3.inactiveContext&&_3.overElement&&isc.isA.CheckboxItem(_4))
{_4.focusInItem()}}},isc.A.$11y=function isc_DynamicForm__itemMouseEvent(_1,_2){var _3=this.$11z,_4=this.$110,_5=this.$1147,_6=this.$111,_7=_1.item,_8=_1.overTitle,_9=_1.overTextBox,_10=_1.overIcon;if(!_9&&_7&&_7.hasDataElement()&&_7.$15i){_9=_1.overElement}
if(_1.inactiveContext!=null){_7=null;_8=null;_10=null}
if(_3&&_3.destroyed){_3=null;this.$11z=null;this.$111=null;this.$110=null;this.$1147=null}
if(_7&&_7.destroyed){_7=null;_8=null;_9=null;_10=null}
this.$11z=_7;this.$110=_8;this.$1147=_9;this.$111=_10;if(_2==isc.EH.MOUSE_OVER){if(_7){if(_8)_7.handleTitleOver();else{if(_10)this.$111=null;_7.handleMouseOver()}}}else if(_2==isc.EH.MOUSE_OUT){if(_3){if(_4)_3.handleTitleOut();else{if(_6)_3.$114(_6);_3.handleMouseOut()}}}else{var _11=(_3!=_7||_4!=_8||_5!=_9);if(_11){if(_3){if(_4)_3.handleTitleOut();else{if(_6)_3.$114(_6);_3.handleMouseOut()}}
if(_7){if(_8)_7.handleTitleOver();else{if(_10)_7.$113(_10);if(!_10||(_7.$17z==null&&_10!=_7.errorIconName)){_7.handleMouseOver()}}}}else if(_7){if(_8)_7.handleTitleMove();else{if(_6!=_10){if(_6)_7.$114(_6);if(_10)_7.$113(_10)}else if(_7){if(_10)_7.$115(_10);_7.handleMouseMove()}}}}},isc.A.handleMouseOver=function isc_DynamicForm_handleMouseOver(_1,_2){if(this.mouseOver&&this.mouseOver(_1,_2)==false)return false;this.$11y(this.$ne(_1),isc.EH.MOUSE_OVER)},isc.A.handleMouseMove=function isc_DynamicForm_handleMouseMove(_1,_2){if(this.mouseMove&&this.mouseMove(_1,_2)==false)return false;this.$11y(this.$ne(_1),isc.EH.MOUSE_MOVE)},isc.A.handleMouseOut=function isc_DynamicForm_handleMouseOut(_1,_2){this.$11y({},isc.EH.MOUSE_OUT);if(this.mouseOut&&this.mouseOut(_1,_2)==false)return false},isc.A.handleMouseWheel=function isc_DynamicForm_handleMouseWheel(_1,_2){var _3=this.$ne(_1),_4=_3.item;if(_4&&_4.$178s(_1,_2))return isc.EH.STOP_BUBBLING;return this.Super("handleMouseWheel",arguments)},isc.A.bubbleItemHandler=function isc_DynamicForm_bubbleItemHandler(_1,_2,_3,_4,_5,_6){var _7=this.getItemById(_1),_8=null;for(;_7!=null;_7=_7.parentItem){if(_7.form!=this)continue;if(_7[_2]!=null&&!isc.isA.Function(_7[_2])){isc.Func.replaceWithMethod(_7,_2,"arg1,arg2,arg3,arg4")}
if(_7[_2]==null){this.logWarn("handler:"+_2+" is not present on itemID "+_1);return false}
_8=_7[_2](_3,_4,_5,_6);if(_8==false)return _8}
return _8},isc.A.bubbleInactiveEditorEvent=function isc_DynamicForm_bubbleInactiveEditorEvent(_1,_2,_3){return this.bubbleItemHandler(_1,"$680",_2,_3.inactiveContext,_3)},isc.A.elementChanged=function isc_DynamicForm_elementChanged(_1){var _2=this.bubbleItemHandler(_1,"elementChanged",_1);return(_2!=false)},isc.A.handleClick=function isc_DynamicForm_handleClick(_1,_2){var _3=this.$ne(_1);var _4;if(_3&&_3.item){var _5=_3.item;var _6=this.$921||{},_7=this.$921?this.$921.item:null;if(_7==_3.item){_4=this.handleItemClick(_3,_6);this.$1590=this.$921}}
delete this.$921;if(_4==false||_4==isc.EH.STOP_BUBBLING)return _4;return this.Super("handleClick",arguments)},isc.A.handleItemClick=function isc_DynamicForm_handleItemClick(_1,_2){var _3;var _4=_1.item;if(_1.inactiveContext){this.logInfo("Bubbling inactive editor event for "+_4.ID,"EventHandler");_3=this.bubbleInactiveEditorEvent("click",_4,_1)}else{if(this.$921.overTitle&&_1.overTitle){this.logInfo("Bubbling handleTitleClick event for "+_4.ID,"EventHandler");_3=this.bubbleItemHandler(_4,"handleTitleClick",_4)}else{var _5=_4.isA("SpacerItem"),_6=_5||(_1.overElement||_1.overTextBox||_1.overControlTable),_7=_5||(_2.overElement||_2.overTextBox||_2.overControlTable)
if(_2.overIcon&&_1.overIcon&&(_4.form==this)){if(_4.$116(_1.overIcon)==false)
return false;var _8=_4.getIcon(_1.overIcon);if(_8&&_8.writeIntoItem){_6=true;_7=true}}
if(_2.overValueIcon&&_1.overValueIcon&&(_4.form==this)){if(_4.valueIconClick!=null){if(_4.valueIconClick(this,_4,_4.getValue())===false){return false}}}
if(_6&&_7){this.logInfo("Bubbling handleClick event for "+_4.ID,"EventHandler");if(this.bubbleItemHandler(_4,"handleClick",_4)==false){_3=false}}
if(_3!=false){this.logInfo("Bubbling handleCellClick event for "+_4.ID,"EventHandler");_3=this.bubbleItemHandler(_4,"handleCellClick",_4)}}}
return _3},isc.A.handleDoubleClick=function isc_DynamicForm_handleDoubleClick(_1,_2){var _3=this.$ne(_1),_4=this.$921,_5=this.$1590;var _6;if(_3&&_3.item&&_4&&(_4.item==_3.item))
{if(_5&&(_5.item==_3.item)){var _7=_3.item;if(_3.inactiveContext){_6=this.bubbleInactiveEditorEvent(_7,"doubleClick",_3)}else if(_3.overTitle&&_4.overTitle){_6=this.bubbleItemHandler(_7,"handleTitleDoubleClick",_7)}else{var _8=(_3.overElement||_3.overTextBox||_3.overControlTable),_9=(_4.overElement||_4.overTextBox||_4.overControlTable)
if(_3.overIcon&&_4.overIcon){if(_7.$116(_3.overIcon)==false)return false;var _10=_7.getIcon(_3.overIcon);if(_10&&_10.writeIntoItem){_8=true;_9=true}}
if(_8&&_9){if(this.bubbleItemHandler(_7,"handleDoubleClick",_7)==false){_6=false}}
if(_6!=false){_6=this.bubbleItemHandler(_7,"handleCellDoubleClick",_7)}}}else{_6=this.handleItemClick(_3,_4||{})}}
delete this.$921;delete this.$1590;if(_6==false||_6==isc.EH.STOP_BUBBLING)return _6;return this.Super("handleDoubleClick",arguments)},isc.A.handleShowContextMenu=function isc_DynamicForm_handleShowContextMenu(_1,_2){var _3=this.$ne(_1);var _4;if(_3!=null&&_3.item!=null){if(_3.overIcon&&isc.Browser.isTouch)_4=false;else{var _5=_3.item;if(_5){if(_5.handleShowContextMenu){_4=_5.handleShowContextMenu()}
if(_4!=false&&this.showItemContextMenu){_4=this.showItemContextMenu(_5)}}}}
if(_4==false||_4==isc.EH.STOP_BUBBLING)return _4;return this.Super("handleShowContextMenu",arguments)},isc.A.handleFocusIn=function isc_DynamicForm_handleFocusIn(_1,_2){var _3=false;if(isc.EH.synchronousFocusNotifications&&_1!=null){var _4=isc.DynamicForm._getItemInfoFromElement(_1,this);var _5=_4?_4.item:null;if(_5){if(_1==_5.getFocusElement()){isc.FormItem.$763(_1);_3=true}else if(_4.overIcon!=null){_5.$121(_4.overIcon,_1)
_3=true}}}
if(!_3){this.logDebug("DynamicForm.handleFocusIn(): Received focusin notification for element:"+_1+". This doesn't appear to be a focus target for an item, so simply recording the event as a widget-level focus on the form itself.","nativeFocusIn");return this.Super("handleFocusIn",arguments)}},isc.A.handleFocusOut=function isc_DynamicForm_handleFocusOut(_1,_2){var _3=false;if(isc.EH.synchronousFocusNotifications&&_1!=null){var _4=isc.DynamicForm._getItemInfoFromElement(_1,this),_5=_4?_4.item:null;if(_5){if(_1==_5.getFocusElement()){isc.FormItem.$764(_1);_3=true}else if(_4.overIcon!=null){_5.$123(_4.overIcon,_1)
_3=true}}}
if(!_3){this.logDebug("DynamicForm.handleFocusOut(): Received focusout notification for element:"+_1+". This doesn't appear to be a focus target for an item, so simply recording the event as a widget-level blur on the form itself.","nativeFocusIn");return this.Super("handleFocusOut",arguments)}},isc.A.elementFocus=function isc_DynamicForm_elementFocus(_1,_2){var _3=this.getItemById(_2);if(!this.hasFocus){isc.EventHandler.focusInCanvas(this,null,_3)}
var _4=isc.DynamicForm._getItemInfoFromElement(_1,this);var _5=_4.overIcon;this.setFocusItem(_3,_5);var _6=true,_7=false;if(this.$11w!=null){if(this.$11x!=_3){delete this.$11w;delete this.$11x}else{_7=true;this.$11w-=1;if(this.$11w<0){delete this.$11w;delete this.$11x}}}
_6=this.bubbleItemHandler(_2,"elementFocus",_7);return(_6!=false)},isc.A.elementBlur=function isc_DynamicForm_elementBlur(_1,_2){if(!isc.isA.FormItem(this.getItemById(_2)))return;var _3=true;if(this.$11v==null)_3=this.bubbleItemHandler(_2,"elementBlur");else{this.$11v-=1;if(this.$11v<0)delete this.$11v}
this.clearPrompt();return(_3!=false)},isc.A.handleKeyPress=function isc_DynamicForm_handleKeyPress(_1,_2){var _3=this.ns.EH,_4=_3.getKey(_1);if(_4===this.$10j){if(this.saveOnEnter){var _5=this.getFocusSubItem();if(_5&&_5.shouldSaveOnEnter()){this.submit()}}}
var _6=this.revertValueKey,_7=this.getFocusSubItem();if(_7!=null&&_6!=null&&_3.$160v(_6,_1))
{var _5=_7;while(_5.parentItem!=null)_5=_5.parentItem;_5.setValue(_5.$160w());isc.Hover.clear()}
if(_4===this.$51h&&!isc.DynamicForm.canEditField(_7,this))
{return false}
return this.Super("handleKeyPress",arguments)},isc.A.titleHoverHTML=function isc_DynamicForm_titleHoverHTML(_1){if(_1.prompt)return _1.prompt;if(_1.showClippedTitleOnHover&&this.shouldClipTitle(_1)&&this.titleClipped(_1))
{return _1.getTitle()}},isc.A.$119=function isc_DynamicForm__showItemHover(_1,_2){if(_2&&!isc.is.emptyString(_2)&&_1.showHover!=false){var _3=this.$1845(_1);isc.Hover.show(_2,_3,(_1.hoverRect||this.itemHoverRect))}else isc.Hover.clear()},isc.A.$1845=function isc_DynamicForm__getItemHoverProperties(_1){if(!isc.isA.FormItem(_1))_1=this.getItem(_1);while(_1.parentItem!=null)_1=_1.parentItem;var _2=this.$wc();if(_1){_2=isc.addProperties(_2,{align:(_1.hoverAlign!=null?_1.hoverAlign:this.itemHoverAlign),hoverDelay:(_1.hoverDelay!=null?_1.hoverDelay:this.itemHoverDelay),height:(_1.hoverHeight!=null?_1.hoverHeight:this.itemHoverHeight),opacity:(_1.hoverOpacity!=null?_1.hoverOpacity:this.itemHoverOpacity),baseStyle:(_1.hoverStyle!=null?_1.hoverStyle:this.itemHoverStyle),showHover:(_1.showHover!=null?_1.showHover:this.showHover),valign:(_1.hoverVAlign!=null?_1.hoverVAlign:this.itemHoverVAlign),width:(_1.hoverWidth!=null?_1.hoverWidth:this.itemHoverWidth),wrap:(_1.hoverWrap!=null?_1.hoverWrap:this.itemHoverWrap)})}else{_2=isc.addProperties(_2,{align:this.hoverAlign,hoverDelay:this.hoverDelay,height:this.hoverHeight,opacity:this.hoverOpacity,baseStyle:this.hoverStyle,valign:this.hoverVAlign,width:this.hoverWidth})}
_2.moveWithMouse=this.hoverMoveWithMouse;return _2},isc.A.showPrompt=function isc_DynamicForm_showPrompt(_1){window.status=_1},isc.A.clearPrompt=function isc_DynamicForm_clearPrompt(){window.status=""},isc.A.isMultipart=function isc_DynamicForm_isMultipart(){return!(this.encoding==isc.DynamicForm.NORMAL||this.encoding==isc.DynamicForm.NORMAL_ENCODING)},isc.A.itemIsLastInRow=function isc_DynamicForm_itemIsLastInRow(_1,_2){var _3=this.items.$8j,_4=_3[_2],_5=this.getItems().indexOf(_1);if(!_4||_5<0)return false;if(_4[this.numCols-1]==_5)return true;return false},isc.A.getColumnWidths=function isc_DynamicForm_getColumnWidths(){var _1=this.items.$8j,_2=[];_2.length=this.numCols;for(var j=0;j<_2.length;j++)_2[j]=0;for(var _4=0;_4<_1.length;_4++){var _5=_1[_4];for(var i=0;i<_5.length;i++){var _7=this.items.get(_5[i]);if(_7.colSpan&&_7.colSpan>1)continue;if(_7.showTitle&&(this.titleOrientation=="left"||!this.titleOrientation)){if(_7.getVisibleTitleWidth()>_2[i]){_2[i]=_7.getVisibleTitleWidth()}
i++}
if(_7.width>_2[i])_2[i]=_7.width;if(_7.showTitle&&_7.titleOrientation=="right"&&_7.getVisibleTitleWidth()>_2[i+1]){_2[++i]=_7.getVisibleTitleWidth()}}}
return _2},isc.A.getItemTableOffsets=function isc_DynamicForm_getItemTableOffsets(_1,_2){var _3=_2||this.items.$8j,_4=this.getItems().indexOf(_1),_5={};_5.itemIndex=_4
for(var _6=0;_6<_3.length;_6++){var _7=_3[_6],_8=_7.indexOf(_4),_9=_7.lastIndexOf(_4);if(_8>-1&&_9>-1){if(!_5.left||_8<_5.left)_5.left=_8;if(!_5.width||_5.width<_9-_8)_5.width=_9-_8+1;if(!_5.top||_6<_5.top)_5.top=_6;if(!_5.height||_5.height<_6-_5.top){_5.height=_6-_5.top+1}}}
return _5},isc.A.getItemDropIndex=function isc_DynamicForm_getItemDropIndex(_1,_2){if(!_1)return;if(!_2)_2="L";var _3=this.getItemTableOffsets(_1),_4=this.items.$8j;if(_2=="L")return _3.itemIndex;if(_2=="R"){if(this.itemIsLastInRow(_1)&&this.canAddColumns!=true){return _3.itemIndex+1}
return _3.itemIndex+1}
if(_2=="T"){return this.getItemIndexAtTableLocation(_3.top-(_3.top==0?0:1),_3.left)}
if(_2=="B"){var _5=_3.top+_3.height-1;var _6=this.getItemIndexAtTableLocation(_5+1,_3.left);if(_6==null){_6=this.items.length}
return _6}},isc.A.getItemIndexAtTableLocation=function isc_DynamicForm_getItemIndexAtTableLocation(_1,_2){var _3=this.items.$8j;if(!_3[_1])return;return _3[_1][_2]},isc.A.getItemAtPageOffset=function isc_DynamicForm_getItemAtPageOffset(_1,_2){this.items.$69e=this.getColumnWidths();var _3=this.items.$8j,_4=this.items.$69e,_5=this.items.$8s;var _6=this.inWhichPosition(_4,_1-this.getPageLeft()),_7=this.inWhichPosition(_5,_2-this.getPageTop());_6=_6==-1?0:_6==-2?_4.length:_6;_7=_7==-1?0:_7==-2?_5.length:_7;if(!_3[_7])return null;var _8=_3[_7][_6],_9=this.getItem(_8);if(_9!=null){_9.$69f=_7;_9.$69g=_6;_9.$69d=_8}
return _9},isc.A.getNearestItem=function isc_DynamicForm_getNearestItem(_1,_2){var _3=9999999999,_4;this.logDebug("Computing nearest item to ("+_1+","+_2+")","formItemDragDrop");for(var i=0;i<this.items.length;i++){var _6=this.items[i];var _7=_6.getPageRect(true),_8=_7[0],_9=_7[1],_10=_7[2],_11=_7[3],_12=0,_13=0;if(_1>=_8&&_1<=_8+_10&&_2>=_9&&_2<=_9+_11)
{return _6}
if(_1>_8){if(_1>_8+_10){_12=_1-(_8+_10)}}else{_12=_8-_1}
if(_2>_9){if(_2>_9+_11){_13=_2-(_9+_11)}}else{_13=_9-_2}
var _14=Math.sqrt(_12*_12+_13*_13);this.logDebug("Item "+_6.name+": (l,t,w,h) = "+_7,"formItemDragDrop");this.logDebug("XDelta: "+_12+", yDelta: "+_13+", straight line distance: "+_14,"formItemDragDrop");if(_14<_3){this.logDebug("Item "+_6.name+": distance is shorter than "+_3+", it is now the nearest item","formItemDragDrop");_3=_14;_4=_6}}
return _4},isc.A.showDragLineForItem=function isc_DynamicForm_showDragLineForItem(_1,_2,_3){this.makeDragLine();if(!_1){this._dragLine.hide();return}
var _4=_1.getPageRect(),_5=_4[0],_6=_4[1],_7=_4[2],_8=_1.getVisibleHeight(),_9=this.titleOrientation||"left",_10="dragLine";if(_1.showTitle!=false){if(_9=="left"||_9=="right")_7+=_1.getVisibleTitleWidth();if(_9=="left")_5-=_1.getVisibleTitleWidth()}
var _11;if(_2<=_5)_2=_5+1;else if(_2>=_5+_7){_2=_5+_7-1;_11=true}
var _12=_7/4;if(_12>20)_12=20;if(_3<=_6)_3=_6+1;else if(_3>=_6+_8)_3=_6+_8-1;var _13=_2-_5,_14=Math.round(_7/_13),_15=_3-_6,_16=Math.round(_8/_15),_17=(_5+_7)-_2,_18=Math.round(_7/_17),_19=(_6+_8)-_3,_20=Math.round(_8/_19),_21="R",_22,_23,_24,_25;_5--;_6--;if(_11||(Math.min(_14,_18)<Math.min(_16,_20)&&((_14>_18&&_13<_12)||(_18>_14&&_17<_12)))){_21=_11?"R":_14>_18?"L":"R";_23=3;_22=_8;_24=_21=="L"?_5:_5+_7-1;_25=_6;_10="dragLineVertical"}else{_21=_16>_20?"T":"B";_23=_7;_24=_5;_22=3;_25=_21=="T"?_6:_6+_8-1}
_1.dropSide=_21;if(this.itemIsLastInRow(_1,_1.$69f)&&!this.canAddColumns&&_1.dropSide=="R"){this.hideDragLine();this.setNoDropIndicator();this.$69h=this.currentCursor;this.setCursor("not-allowed")}
else{if(this.$uh){this.clearNoDropIndicator()
this.setCursor(this.$69h)}
var _26={left:_24,top:_25};this.adjustDragLinePosition(_26,_1,_21);_24=_26.left;_25=_26.top;this._dragLine.setStyleName(_10);this._dragLine.resizeTo(_23,_22);this._dragLine.setPageRect(_24,_25);this._dragLine.bringToFront();this._dragLine.show()}},isc.A.adjustDragLinePosition=function isc_DynamicForm_adjustDragLinePosition(_1,_2,_3){var _4=this.items.$8j,_5=this.items.indexOf(_2),_6,_7,_8;for(var i=0;i<_4.length;i++){if(_4[i].indexOf(_5)!=-1){_6=i;_7=_4[i].indexOf(_5);_8=_4[i].lastIndexOf(_5);break}}
if(_6==null||_7==null||_8==null)return;if(_3=="T"){if(_6==0)return;if(_4[_6-1][_7]==_4[_6-1][_8]&&_4[_6-1][_7-1]!=_4[_6-1][_7]&&_4[_6-1][_8+1]!=_4[_6-1][_7])
{var _10=this.items[_4[_6-1][_7]].getPageRect(true);var _11=_10[1]+_10[3];_1.top-=Math.round((_1.top-_11)/2)}}
if(_3=="B"){if(_6==_4.length-1)return;if(_4[_6+1][_7]==_4[_6+1][_8]&&_4[_6+1][_7-1]!=_4[_6+1][_7]&&_4[_6+1][_8+1]!=_4[_6+1][_7])
{var _10=this.items[_4[_6+1][_7]].getPageRect(true);var _11=_10[1];_1.top+=Math.round((_11-_1.top)/2)}}
if(_3=="L"){if(_7==0)return;var _10=this.items[_4[_6][_7-1]].getPageRect(true);var _12=_10[0]+_10[2];_1.left-=Math.round((_1.left-_12)/2)}
if(_3=="R"){if(_8==_4[_6].length-1)return;var _10=this.items[_4[_6][_8+1]].getPageRect(true);var _12=_10[0];_1.left+=Math.round((_12-_1.left)/2)}},isc.A.showDragLineForForm=function isc_DynamicForm_showDragLineForForm(){this.makeDragLine();this._dragLine.setStyleName("dragLineVertical");this._dragLine.resizeTo(3,this.getHeight());this._dragLine.setPageRect(this.getPageLeft(),this.getPageTop());this._dragLine.bringToFront();this._dragLine.show()},isc.A.enableField=function isc_DynamicForm_enableField(_1){if(_1==null||isc.isAn.emptyString(_1))return;var _2=this.getItem(_1);if(_2)_2.enable()},isc.A.disableField=function isc_DynamicForm_disableField(_1){if(_1==null||isc.isAn.emptyString(_1))return;var _2=this.getItem(_1);if(_2)_2.disable()},isc.A.showField=function isc_DynamicForm_showField(_1){if(_1==null||isc.isAn.emptyString(_1))return;var _2=this.getItem(_1);if(_2)_2.show()},isc.A.hideField=function isc_DynamicForm_hideField(_1){if(_1==null||isc.isAn.emptyString(_1))return;var _2=this.getItem(_1);if(_2)_2.hide()},isc.A.getSelectionChain=function isc_DynamicForm_getSelectionChain(){if(!this.selectionComponent)return[];var _1=[];var _2=this;while(_2.selectionComponent){_1.add(_2.selectionComponent);_2=_2.selectionComponent}
var _3=[];for(var i=_1.length-1;i>=0;i--){_3.add(_1[i].getRecordIndex(_1[i].getSelectedRecord()))}
return _3},isc.A.setCanEdit=function isc_DynamicForm_setCanEdit(_1){this.canEdit=_1;var _2=this.isDrawn();var _3=this.getItems();if(_3!=null){for(var i=0,_5=_3.length;i<_5;++i){var _6=_3[i];_6.updateCanEdit(_2)}}
if(_2)this.markForRedraw("setCanEdit")},isc.A.setFieldCanEdit=function isc_DynamicForm_setFieldCanEdit(_1,_2){if(_1==null||isc.isAn.emptyString(_1))return;var _3=this.getField(_1);if(_3){if(_3.setCanEdit)_3.setCanEdit(_2);else{_3.canEdit=_2;this.redraw()}}},isc.A.fieldIsEditable=function isc_DynamicForm_fieldIsEditable(_1){if(!isc.isAn.Object(_1))_1=this.getField(_1);return _1?isc.DynamicForm.canEditField(_1,this):false},isc.A.setReadOnlyDisplay=function isc_DynamicForm_setReadOnlyDisplay(_1){this.readOnlyDisplay=_1;var _2=(this.canEdit==false&&this.isDrawn());var _3=this.getItems();if(_3!=null){for(var i=0,_5=_3.length;i<_5;++i){var _6=_3[i];_6.updateReadOnlyDisplay(_2)}}
if(_2)this.markForRedraw("setReadOnlyDisplay")});isc.B._maxIndex=isc.C+278;isc.A=isc.DynamicForm;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.defaultFieldType="text";isc.A.$12a="link";isc.A.$gx="text";isc.A.$12b="select";isc.A.$12c="checkbox";isc.A.$12d="staticText";isc.A.$g2="boolean";isc.A.$gz="integer";isc.A.$12e="binary";isc.A.$12f="blob";isc.A.$52w="multifile";isc.A.$12g="multiupload";isc.A.$9i="upload";isc.A.$52x="file";isc.A.$51x="base64Binary";isc.A.$12h="enum";isc.A.$12i="CycleItem";isc.A.$12j="selectOther";isc.A.$12k="relation";isc.A.$67f="NestedEditorItem";isc.A.$67g="NestedListEditorItem";isc.A.$677="imageFile";isc.A.$678="ViewFileItem";isc.A.$77j="section";isc.A.$77k="SectionItem";isc.A.$77l="button";isc.A.$77m="ButtonItem";isc.A.$178h="FormItem";isc.A.$450="id";isc.A.compareValuesRecursive=true;isc.B.push(isc.A.sortItemsIntoTabOrder=function isc_c_DynamicForm_sortItemsIntoTabOrder(_1,_2){if(_2==null)_2=this;var _3=[],_4={};for(var i=0;i<_1.length;i++){var _6=_1[i],_7=_6.tabIndex;if(_7!=null&&_7!=-1){if(_3[_7]!=null){if(!_4[_7]){_2.logWarn("More than one item in this form have an explicitly specified tabIndex of '"+_7+"'. Tab order cannot be guaranteed within this form.");_4[_7]=true}
_6.$180n=true}
_3[_7]=_6}}
var _8=1,_9=[];for(var i=0;i<_1.length;i++){var _6=_1[i];if(!isc.isA.FormItem(_6)){if(_2.logIsInfoEnabled("TabIndexManager"))
_2.logInfo("dynamicForm.sortItemsIntoTabOrder() fired before all form items have been initialized"+this.getStackTrace());continue}
if(_6.tabIndex!=null&&!_6.$180n){_9[_6.tabIndex]=_6;continue}
_8+=1;while(_3[_8]!=null){_8+=1}
_6.$10p=_8;_9[_8]=_6}
return _9},isc.A.getEditorType=function isc_c_DynamicForm_getEditorType(_1,_2,_3){if(_1._constructor==isc.FormItem.Class)_1._constructor=null;var _4=_2.getDataSource();var _5=this.canEditField(_1,_2),_6=this.defaultFieldType,_7=_1.editorType;if(isc.isA.Class(_7)){_7=_7.getClassName()}
if(_7==this.$178h)_7=null;var _8=!_1.editNode||isc[_1._constructor];var _9=(_5==false&&_1.readOnlyEditorType)||_7||_1.formItemType||(_8&&_1._constructor);if(_9==null){_9=_2&&_2.getFieldType?_2.getFieldType(_1,_3):_1.type}
if(_9==null)_9=_6;if((_5==false&&_1.readOnlyEditorType)||_7||_1.formItemType||_1._constructor)
{return _9}
var _10=_9;var _11=null;var _12=(_9==this.$12e||_9==this.$52x||_9==this.$677);while(_10){if(_9==this.$12a){if(this.canEditField(_1,_2)&&_1.canEdit)_11=this.$gx;else _11=this.$12a}else if(_9==this.$g2){var _13=_1.valueMap;if(!isc.isAn.Array(_13)&&isc.isAn.Object(_13))_11=this.$12b;else _11=this.$12c}else if(_9==this.$12e||_9==this.$12f||_9==this.$52x||_9==this.$677)
{if(_1.dataSource)_11=this.$52w
else _11=this.$52x}else if(_9==this.$12g){_11=this.$52w}else if(_9==this.$51x){_11=this.$51x}else if(_9==this.$12h){if(_1.showValueIconOnly)_11=this.$12i
else _11=this.$12b}else if(isc.DataSource&&isc.isA.DataSource(_4)&&_4.fieldIsComplexType(_1.name)){_11=_1.multiple?_2.nestedListEditorType:_2.nestedEditorType}else{if(_10&&_10!=_6&&_10!=this.$gz&&(_10==this.$12j||(isc.FormItemFactory.getItemClass(_10)!=null)))
{_11=_10}else{_10=isc.SimpleType.getType(_10);if(_11){break}else if(_10==null||_10.inheritsFrom==null){if(_1.dataSource){_11=this.$12k}else if(_1.valueMap||_1.optionDataSource||_1.displayField){_11=(_1.showValueIconOnly?this.$12i:this.$12b)}else if(_2&&(_1.length&&_1.length>_2.longTextEditorThreshold))
{_11=_2.longTextEditorType}else{_11=_6}}else{_10=_10.inheritsFrom;_9=_10;_11=null;continue}}}
break}
return _11},isc.A._getItemInfoFromElement=function isc_c_DynamicForm__getItemInfoFromElement(_1,_2){var _3=_2?_2.getClipHandle():document,_4={},_5=isc.DynamicForm.$89,_6=isc.DynamicForm.$9a,_7=isc.DynamicForm.$9b,_8=isc.DynamicForm.$9c,_9=isc.DynamicForm.$9e,_10=isc.DynamicForm.$99r,_11=isc.DynamicForm.$9g,_12="eventpart",_13="valueicon";while(_1&&_1!=_3&&_1!=document){var _14=_1.getAttribute?_1.getAttribute(_5):null;if(_1.getAttribute&&(_1.getAttribute(_12)==_13))
{_4.overValueIcon=true}
if(_14!=null&&!isc.isAn.emptyString(_14)){var _15=window[_14];if(_15!=null&&!_15.destroyed&&(_2==null||_15.form===_2)){_4.item=_15;var _16=_15.$681(_1);if(_16!=null){if(this.logIsDebugEnabled("inactiveEditorHTML")){this.logDebug("Event occurred over inactive HTML for item:"+_15+" inactiveContext:"+this.echo(_16),"inactiveEditorHTML")}
_4.inactiveContext=_16}
var _17=_1.getAttribute(_6);if(_17==_7)_4.overElement=true;else if(_17==_11)_4.overTitle=true;else if(_17==_8)_4.overTextBox=true;else if(_17==_9)_4.overControlTable=true;else if(_17==_10)_4.overInlineError=true;else if(_17&&!isc.isAn.emptyString(_17))
_4.overIcon=_17;break}}
_1=_1.parentNode}
return _4},isc.A.$172c=function isc_c_DynamicForm__getEventTargetItem(_1){if(!_1)_1=isc.EH.lastEvent;var _2=_1.target,_3=_1.itemInfo;if(!_3||_1.$172d!=_1.DOMevent){_3=_2.$ne(_1)}
return _3&&_3.item&&_3.item.form==_2?_3.item:null},isc.A.getSimpleErrors=function isc_c_DynamicForm_getSimpleErrors(_1){var _2={};if(isc.isAn.Array(_1))_1=_1[0];for(var _3 in _1){var _4=_1[_3];if(_3=="recordPath"&&!isc.isAn.Object(_4))continue;if(isc.isAn.Array(_4)){_2[_3]=[];for(var i=0;i<_4.length;i++){var _6=_4[i];_2[_3][i]=isc.isAn.Object(_6)?isc.shallowClone(_6):{errorMessage:_6}}}else{_2[_3]=isc.isAn.Object(_4)?isc.shallowClone(_4):{errorMessage:_4}}}
return _2},isc.A.formatValidationErrors=function isc_c_DynamicForm_formatValidationErrors(_1){var _2={};if(isc.isAn.Array(_1))_1=_1[0];for(var _3 in _1){var _4=_1[_3];if(_3=="recordPath"&&!isc.isAn.Object(_4))continue;if(isc.isAn.Array(_4)){_2[_3]=[];for(var i=0;i<_4.length;i++){var _6=_4[i];if(isc.isAn.Object(_6))_6=_6.errorMessage;_2[_3][i]=_6}}else{_2[_3]=isc.isAn.Object(_4)?_4.errorMessage:_4}}
return _2},isc.A.compareValues=function isc_c_DynamicForm_compareValues(_1,_2,_3){if(isc.isA.Date(_1)&&isc.isA.Date(_2)){return(isc.DateUtil.compareDates(_1,_2)==0)}
if(_3&&_3.type){var _4=isc.SimpleType.getType(_3.type);if(_4&&_4.compareValues){return _4.compareValues(_1,_2,_3)==0}}
if(isc.isAn.Array(_1)&&isc.isAn.Array(_2)){if(_1.length!=_2.length)return false;for(var i=0;i<_1.length;i++){if(!isc.DynamicForm.compareValues(_1[i],_2[i]))return false}
return true}else{if(isc.isA.Number(_1)||isc.isA.String(_1)||isc.isA.Boolean(_1)){_1=_1.valueOf()}
if(isc.isA.Number(_2)||isc.isA.String(_2)||isc.isA.Boolean(_2)){_2=_2.valueOf()}
if(_1==_2)return true;if(isc.isAn.Object(_1)&&isc.isAn.Object(_2)){var _6=isc.DynamicForm.compareValuesRecursive;var _7=isc.addProperties({},_2);for(var _8 in _1){if(_6){if(!isc.DynamicForm.compareValues(_1[_8],_2[_8])){return false}}else{if(_2[_8]!=_1[_8])return false}
delete _7[_8]}
for(var _8 in _7){return false}
return true}}
return false},isc.A.valuesHaveChanged=function isc_c_DynamicForm_valuesHaveChanged(_1,_2,_3,_4,_5){var _6=_3,_7;for(var _8 in _4){if(!(_8 in _3)){if(_6===_3)_6=isc.addProperties({},_3);_6[_8]=_7}}
_3=_6;var _9=false,_10={};for(var _11 in _3){if(isc.isA.Function(_3[_11]))continue;if(_11==isc.gwtRef||_11==isc.gwtModule)continue;if(isc.isAn.Instance(_3[_11])||isc.isA.Class(_3[_11])||(_3[_11]&&_3[_11]._constructor))
{continue}
var _12=_5==null?_11:_5+"/"+_11;var _13=_1.getItem(_12);if(_13!=null){_9=!_13.compareValues(_3[_11],_4[_11]);if(_9&&_2)_10[_11]=_3[_11]}else{var _14=_3[_11],_15=_4[_11];var _16=isc.isA.Object(_14),_17=isc.isAn.Object(_15);if(_16&&(isc.isA.Number(_14)||isc.isA.String(_14)||isc.isA.Boolean(_14)))
{_14=_14.valueOf();_16=false}
if(_17&&(isc.isA.Number(_15)||isc.isA.String(_15)||isc.isA.Boolean(_15)))
{_15=_15.valueOf();_17=false}
if(_16&&!isc.isAn.Array(_14)&&!isc.isA.Date(_14)&&_17&&!isc.isAn.Array(_15)&&!isc.isA.Date(_15))
{var _18=this.valuesHaveChanged(_1,_2,_3[_11],_4[_11],_12);if(!_2&&_18){_9=true;break}else if(!isc.isAn.emptyObject(_18)){if(_10[_11]==null)_10[_11]={};isc.addProperties(_10[_11],_18)}}else{_9=!isc.DynamicForm.compareValues(_14,_15);if(_9&&_2)_10[_11]=_14}}
if(_9&&!_2){return true}}
return(_2?_10:_9)},isc.A.getFilterCriteria=function isc_c_DynamicForm_getFilterCriteria(){var _1={};for(var i=0;i<arguments.length;i++){var _3=arguments[i];if(_3==null)continue;if(_3.getValuesAsCriteria==null){this.logInfo("DynamicForm.getFilterCriteria() - unable to call 'getValuesAsCriteria()' on argument:"+this.echo(_3));continue}
isc.addProperties(_1,_3.getValuesAsCriteria())}
return _1},isc.A.$817=function isc_c_DynamicForm__getTopRowCellStart(){if(!this.$819){isc.Canvas.$816.add({target:this,methodName:"$82a"});this.$819=true}
if(this.$9x==null){this.$9x=["<TD style='",isc.Canvas.$42a,"font-size:0px;height:0px;overflow:hidden;padding:0px;' class='",null,"'>",(isc.Browser.isSafari||isc.Browser.isMoz?"<div style='overflow:hidden;height:0px'>":"")]}
return this.$9x},isc.A.$818=function isc_c_DynamicForm__getTitleInnerTableTemplate(){if(!this.$819){isc.Canvas.$816.add({target:this,methodName:"$82a"});this.$819=true}
if(this.$10b==null){this.$10b=["<TABLE height=",," border=0 cellspacing=0 cellpadding=0><tr><td class='",,"' style='"+isc.Canvas.$42a+"' ALIGN='",,"'>",null]}
return this.$10b},isc.A.$82a=function isc_c_DynamicForm__doublingStringsChanged(){this.$9x=null;this.$10b=null});isc.B._maxIndex=isc.C+12;isc.defineClass("InlineFormItem","DynamicForm");isc.A=isc.InlineFormItem.getPrototype();isc.A.position="relative";isc.A.writeFormTag=false;isc.A.canSubmit=true;isc.A.numCols=1;isc.A.autoDraw=true;isc.A=isc.InlineFormItem;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.create=function isc_c_InlineFormItem_create(_1,_2,_3,_4,_5,_6,_7,_8,_9,_10,_11,_12,_13){var _14=isc.addProperties({showTitle:false,validate:function(){this.form.validate()},destroy:function(){this.form.destroy();this.Super("destroy",arguments)}},_1,_2,_3,_4,_5,_6,_7,_8,_9,_10,_11,_12,_13);var _15=this.createRaw().completeCreation({fields:[_14],valuesManager:_14.valuesManager},_14.formProperties);return _15.getItem(0)});isc.B._maxIndex=isc.C+1;isc.A=isc.DynamicForm;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.makeInlineItem=function isc_c_DynamicForm_makeInlineItem(_1,_2,_3,_4){return isc.InlineFormItem.create({name:_1,type:_2,formProperties:_4},_3)},isc.A.getFormValues=function isc_c_DynamicForm_getFormValues(_1){return isc.Canvas.getFormValues(_1)});isc.B._maxIndex=isc.C+2;isc.DynamicForm.registerStringMethods({valuesChanged:"",itemChanged:"item,newValue",itemChange:"item,newValue,oldValue",itemKeyPress:"item,keyName,characterValue",showItemContextMenu:"item",submitValues:"values,form",handleHiddenValidationErrors:"errors",itemTabIndexUpdated:"item"});isc.ClassFactory.defineClass("FormItem");isc.A=isc.FormItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$68s=[null,"_inactiveContext",null];isc.A.$557=isc.Canvas.getPrototype().$557;isc.A.$63x=isc.Canvas.getPrototype().$63x;isc.A.reuseDOMIDs=false;isc.B.push(isc.A.$qs=function isc_FormItem__getDOMID(_1,_2,_3,_4){if(_4==null&&this.isInactiveHTML()){_4=this.$68u}
if(_4!=null){this.$68s[0]=_1;this.$68s[2]=_4;_1=this.$68s.join(isc.emptyString);if(this.logIsDebugEnabled("inactiveEditorHTML")){this.logDebug("$qs called for inactive HTML -- generated partName:"+_1,"inactiveEditorHTML")}
_2=false}
return isc.Canvas.getPrototype().$qs.apply(this,[_1,_2,_3])});isc.B._maxIndex=isc.C+1;isc.A=isc.FormItem;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.create=function isc_c_FormItem_create(_1,_2,_3,_4,_5,_6,_7,_8,_9,_10,_11,_12,_13){this.logWarn("Unsupported call to "+this.getClassName()+".create(). FormItems must be created by their containing form. To create form items, use the 'items' property of a DynamicForm instance. See documentation for more details.");return isc.addProperties({},_1,_2,_3,_4,_5,_6,_7,_8,_9,_10,_11,_12,_13)},isc.A.getNewTagID=function isc_c_FormItem_getNewTagID(){if(this.$12m==null)this.$12m=0;this.$12m+=1;return"isc_FormItemElement_ID_"+this.$12m},isc.A.setElementTabIndex=function isc_c_FormItem_setElementTabIndex(_1,_2){_1.tabIndex=_2;if(isc.Browser.isMoz){_1.style.MozUserFocus=(_2<0?"ignore":"normal")}},isc.A.$12n=function isc_c_FormItem__aboutToFireNativeElementFocus(_1){if(!isc.Browser.isIE)return;var _2=this.getActiveElement();if(_2&&_2.tagName==null)_2=null;if(_2&&((_2.tagName.toLowerCase()==this.$12o&&_2.type.toLowerCase()==this.$12p)||_2.tagName.toLowerCase()==this.$12q))
{var _3=_2.createTextRange();_3.execCommand("Unselect")}},isc.A.$12r=function isc_c_FormItem__textBasedItem(_1,_2){if(isc.isA.FormItem(_1))_1=_1.getClassName();if(!this.$12s){this.$12s={text:true,TextItem:true,textItem:true,textArea:true,TextAreaItem:true,textAreaItem:true}
this.$12t={popUpTextArea:true,PopUpTextAreaItem:true,popUpTextAreaItem:true}}
return this.$12s[_1]||(!_2||this.$12t[_1])},isc.A.$12u=function isc_c_FormItem__nativeFocusHandler(){if(!window.isc||!isc.DynamicForm)return;var _1=(isc.EH.useFocusInEvents&&isc.EH.synchronousFocusNotifications);if(_1)return isc.FormItem.$188m(this);isc.EH.$h1("IFCS");var _2;if(isc.Log.supportsOnError){_2=isc.FormItem.$763(this)}else{try{_2=isc.FormItem.$763(this)}catch(e){isc.Log.$am(e)}}
isc.EH.$h2();return _2},isc.A.$188m=function isc_c_FormItem___nativeAsyncFocusHandler(_1){var _2=(isc.EH.useFocusInEvents&&isc.EH.synchronousFocusNotifications);if(_2){var _3=isc.DynamicForm._getItemInfoFromElement(_1),_4=_3.item;if(_4){_4.$188n()}
return}},isc.A.$763=function isc_c_FormItem___nativeFocusHandler(_1){var _2=isc.DynamicForm._getItemInfoFromElement(_1),_3=_2.item;if(_3!=null){if(_3.renderAsDisabled()){_1.blur();return}
var _4=this.ns.EH;if(_4.mouseDownEvent!=null&&_4.$i2[_4.mouseDownEvent.DOMevent.type]===_4.TOUCH_START&&this.containerWidget!=null&&this.containerWidget.isDrawn())
{var _5=_4.mouseDownEvent.DOMevent,_6=(_5.target&&(_5.target.nodeType==1?_5.target:_5.target.parentElement));if(_6!=null&&!this.containerWidget.getClipHandle().contains(_6)){_1.blur();return}}
return _3.$12v(_1,_3)}
isc.EH.$h2()},isc.A.$12w=function isc_c_FormItem__nativeBlurHandler(){if(!window.isc||!isc.DynamicForm)return;if(isc.EH.useFocusInEvents&&isc.EH.synchronousFocusNotifications){return}
isc.EH.$h1("IBLR");var _1;if(isc.Log.supportsOnError){_1=isc.FormItem.$764(this)}else{try{_1=isc.FormItem.$764(this)}catch(e){isc.Log.$am(e)}}
isc.EH.$h2();return _1},isc.A.$764=function isc_c_FormItem___nativeBlurHandler(_1){var _2=isc.DynamicForm._getItemInfoFromElement(_1),_3=_2.item;if(_3&&_3.hasFocus){return _3.$12x(_1,_3)}},isc.A.$1851=function isc_c_FormItem__nativeCut(_1){if(!window.isc)return;var _2=this,_3=isc.DynamicForm._getItemInfoFromElement(_2),_4=_3.item;if(_4&&_4.hasFocus){return _4.$43a(_2,_4,true,_1)}},isc.A.$1852=function isc_c_FormItem__nativePaste(_1){if(!window.isc)return;var _2=this,_3=isc.DynamicForm._getItemInfoFromElement(_2),_4=_3.item;if(_4&&_4.hasFocus){return _4.$43a(_2,_4,false,_1)}},isc.A.$12y=function isc_c_FormItem__nativeChangeHandler(){if(!window.isc||!isc.DynamicForm)return;var _1=this,_2=isc.DynamicForm._getItemInfoFromElement(_1),_3=_2.item;if(_3)return _3.$12z()},isc.A.$120=function isc_c_FormItem__nativeIconFocus(){if(isc.EH.useFocusInEvents&&isc.EH.synchronousFocusNotifications)return;var _1=this,_2=isc.DynamicForm._getItemInfoFromElement(_1),_3=_2.item,_4=_2.overIcon;if(_3){if(_3.iconIsDisabled(_4))_1.blur();else return _3.$121(_4,_1)}},isc.A.$122=function isc_c_FormItem__nativeIconBlur(){if(!window.isc)return;if(isc.EH.useFocusInEvents&&isc.EH.synchronousFocusNotifications)return;var _1=this,_2=isc.DynamicForm._getItemInfoFromElement(_1),_3=_2.item,_4=_2.overIcon;if(_3&&!_3.iconIsDisabled(_4))return _3.$123(_4,_1)},isc.A.$124=function isc_c_FormItem__nativeIconClick(){return false},isc.A.$137y=function isc_c_FormItem__testStuckSelectionAfterRedraw(_1){if(!isc.Browser.isIE)return;this.$137z=_1;this.fireOnPause("testStuckSelection",{target:this,methodName:"$1370"})},isc.A.$1370=function isc_c_FormItem__testStuckSelection(){var _1=this.$137z;if(_1==null||_1.destroyed||!_1.isDrawn()||!_1.isVisible()||!_1.hasFocus)
{return}
if(_1.$100a()){_1.focusInItem()}},isc.A.getErrorPromptString=function isc_c_FormItem_getErrorPromptString(_1){var _2="";if(!isc.isAn.Array(_1))_1=[_1];for(var i=0;i<_1.length;i++){_2+=(i>0?"<br>":"")+_1[i].asHTML()};return _2},isc.A.$82b=function isc_c_FormItem__getOuterTableStartTemplate(){if(!this.$819){isc.Canvas.$816.add({target:this,methodName:"$82a"});this.$819=true}
if(this.$13y==null){this.$13y=["<TABLE role='presentation' CELLSPACING=0 CELLPADDING=0 BORDER=0 ID='",,"' STYLE='"+isc.Canvas.$42a,,"' CLASS='",,"'><TR>",,"<TD style='",,"' VALIGN=",,">"]}
return this.$13y},isc.A.$82c=function isc_c_FormItem__getIconsCellTemplate(){if(!this.$819){isc.Canvas.$816.add({target:this,methodName:"$82a"});this.$819=true}
if(this.$131==null){this.$131=["</TD><TD VALIGN=",,,," style='"+isc.Canvas.$42a+"line-height:",,"px' class='",,"' ID='",,"'>",null]}
return this.$131},isc.A.$82a=function isc_c_FormItem__doublingStringsChanged(){this.$13y=null;this.$131=null});isc.B._maxIndex=isc.C+22;isc.A=isc.FormItem;isc.A.$12o="input";isc.A.$12p="text";isc.A.$12q="textarea";isc.A.$15y={};isc.A.$132s={};isc.A=isc.FormItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$152o=null;isc.A.emptyDisplayValue="";isc.A.multipleValueSeparator=", ";isc.A.fetchMissingValues=true;isc.A.alwaysFetchMissingValues=false;isc.A.loadingDisplayValue="Loading...";isc.A.useShortDateFormat=true;isc.A.valueIconSize=16;isc.A.valueIconLeftPadding=0;isc.A.valueIconRightPadding=3;isc.A.showFocusedPickerIcon=false;isc.A.pickerIconHSpace=0;isc.A.pickerIconDefaults={click:function(_1,_2,_3){_2.showPicker()}};isc.A.pickerIconName="picker";isc.A.pickerIconSrc="";isc.A.visible=true;isc.A.disableIconsOnReadOnly=true;isc.A.accessKey=null;isc.A.changeOnKeypress=true;isc.A.maintainSelectionOnTransform=true;isc.A.dirtyOnKeyDown=true;isc.A.showTitle=true;isc.A.clipTitle=null;isc.A.width="*";isc.A.height=20;isc.A.titleColSpan=1;isc.A.colSpan=1;isc.A.rowSpan=1;isc.A.applyAlignToText=false;isc.A.left=0;isc.A.top=0;isc.A.browserInputTypeMap={"digits":"number","phone":"tel"};isc.A.icons=null;isc.A.$156h=null;isc.A.$156i=null;isc.A.$156j=0;isc.A.$156k=null;isc.A.$156l=0;isc.A.defaultIconSrc="[SKIN]/DynamicForm/default_formItem_icon.gif";isc.A.iconHSpace=3;isc.A.iconVAlign=isc.Canvas.BOTTOM;isc.A.iconWidth=20;isc.A.iconHeight=20;isc.A.iconPrompt="";isc.A.showIcons=true;isc.A.redrawOnShowIcon=false;isc.A.errorIconHeight=16;isc.A.errorIconWidth=16;isc.A.errorIconSrc="[SKIN]/DynamicForm/validation_error_icon.png";isc.A.showHint=true;isc.A.showFocused=false;isc.A.showDisabled=true;isc.A.showRTL=false;isc.A.showPending=null;isc.A.cellStyle="formCell";isc.A.hintStyle="formHint";isc.A.titleStyle="formTitle";isc.A.editPendingCSSText="color:#0066CC;";isc.A.valueDeselectedCSSText="color:#A8A8A8;text-decoration:line-through;";isc.A.showFocusedErrorState=false;isc.A.$125=false;isc.A.showClippedTitleOnHover=true;isc.A.showClippedValueOnHover=true;isc.B.push(isc.A.getReadOnlyDisplay=function isc_FormItem_getReadOnlyDisplay(){if(this.readOnlyDisplay!=null)return this.readOnlyDisplay;var _1=this;while(_1.parentItem!=null){_1=_1.parentItem;if(_1.readOnlyDisplay!=null)return _1.readOnlyDisplay}
var _2=this.form;if(_2!=null){return _2.readOnlyDisplay}
return isc.DynamicForm.$b4.readOnlyDisplay},isc.A.setReadOnlyDisplay=function isc_FormItem_setReadOnlyDisplay(_1){var _2=this.getReadOnlyDisplay();this.readOnlyDisplay=_1;_1=this.getReadOnlyDisplay();var _3=(_2!==_1&&this.isReadOnly()&&this.isDrawn());this.updateReadOnlyDisplay(_3);if(_3)this.redraw()},isc.A.updateReadOnlyDisplay=function isc_FormItem_updateReadOnlyDisplay(_1){var _2=this.$152o;var _3=this.$152o=this.getReadOnlyDisplay();if(_2!==_3){this.$152p(_3,_1)}},isc.A.$152p=function isc_FormItem__readOnlyDisplayChanged(_1,_2){if(this.readOnlyDisplayChanged!=null)this.readOnlyDisplayChanged(_1)},isc.A.getReadOnlyTextBoxStyle=function isc_FormItem_getReadOnlyTextBoxStyle(){return this.readOnlyTextBoxStyle||(this.form?this.form.readOnlyTextBoxStyle:"staticTextItem")},isc.A.$1617=function isc_FormItem__getClipStaticValue(){var _1=this;do{var _2=_1.clipStaticValue;if(_2!=null)return _2;_1=_1.parentElement}while(_1!=null);var _3=this.form;if(_3!=null){return!!_3.clipStaticValue}
return!!isc.DynamicForm.$b4.clipStaticValue},isc.A.fitWidthToValueIcon=function isc_FormItem_fitWidthToValueIcon(){return false},isc.A.valueIconClick=function isc_FormItem_valueIconClick(){},isc.A.isInGrid=function isc_FormItem_isInGrid(){return isc.isA.GridRenderer(this.containerWidget)},isc.A.getGridRowNum=function isc_FormItem_getGridRowNum(){return this.rowNum},isc.A.getGridColNum=function isc_FormItem_getGridColNum(){return this.colNum});isc.B._maxIndex=isc.C+11;isc.A=isc.FormItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$o5="height";isc.A.$o6="width";isc.A.$126="colSpan";isc.A.$127="rowSpan";isc.A.$pa="*";isc.A.$bv="_";isc.A.$128="value";isc.A.$129="dataElement";isc.A.$11="label";isc.A.$16ae=" for='";isc.A.$1566=" accesskey='";isc.A.$1567=["<label id='",,"'",,,,,,,">",,"</label>"];isc.A.$o9="%";isc.A.errorMessageWidth=80;isc.A.$170o="_label";isc.A.$68w=1;isc.A.$682=new RegExp(".*_inactiveContext(.*)$");isc.A.$13a="<DIV STYLE='position:absolute;z-index:";isc.A.$139w=";left:";isc.A.$13b="px;top:";isc.A.$13c="px;width:";isc.A.$13d="px;height:";isc.A.$13e="px;' ID='";isc.A.$13f="'>";isc.A.$13g="</DIV>";isc.A.$13h=["<SPAN style='",,"' eventProxy=",," "+isc.DynamicForm.$89+"='",,"' ID='",,"'>"];isc.A.$13i="</SPAN>";isc.A.$13j="$13k";isc.A.$13l="$13m";isc.A.$13n=["<DIV isDisabledEventMask='true' style='overflow:hidden;position:absolute;width:",null,"px;height:",null,"px' "+isc.DynamicForm.$89+"='",null,"' "+isc.DynamicForm.$9a+"='"+isc.DynamicForm.$9b+"' ID='",,"'>",null,"</DIV>"];isc.A.$13o="hiddenDataElement";isc.A.$13p="control";isc.A.$13q="textBox";isc.A.$169o="inlineiconswrapper";isc.A.$13r="pickerIconCell";isc.A.$59p="hintCell";isc.A.$13s="FormItemStyling";isc.A.$13t="deprecated";isc.A.$13u="Over";isc.A.$13v="Down";isc.A.$13w="Disabled";isc.A.$13x="valueIcon";isc.A.$169p=(!isc.Browser.isIE||isc.Browser.isIE11?"absolutePositioning":(isc.Browser.isIE&&isc.Browser.version>=7?"divStyledAsDataElement":null));isc.A.$13z="</TD></TR></TABLE>";isc.A.$130=["<TABLE role='presentation' ID='",,"' "+isc.DynamicForm.$89+"='",,"' "+isc.DynamicForm.$9a+"='"+isc.DynamicForm.$9e,"' CELLPADDING=0 CELLSPACING=0 STYLE='",,"' CLASS='",,"'><TR><TD style='",,"'>",,"</TD><TD ID='",,"' CLASS='",,"' STYLE='",,"'>",,"</TD></TR></TABLE>"];isc.A.$132=["<TD ID='",,"' CLASS='",,"' style='",,,,,"'",,">",,,,,null];isc.A.$169q=["<div id='",,"' class='",,"' style='position:relative;display:inline-block;",,"'>",,,,"</div>"];isc.A.$92q="iconCell";isc.A.$133="$134";isc.A.$160x="parentItemCell";isc.A.$160y="printTitle";isc.A.$160z="title";isc.A.$1600="printTextBox";isc.A.$1601="pickerIcon";isc.A.$135="white-space:normal;";isc.A.$136="white-space:nowrap;";isc.A.$137="min-width:";isc.A.$138="min-height:";isc.A.$93="width:";isc.A.$92="height:";isc.A.$38="px;";isc.A.$39=";";isc.A.$139={};isc.A.$14a="cursor:default;";isc.A.$1148="overflow:hidden;"+isc.Browser.$114w+":ellipsis;";isc.A.$14c="text-align:";isc.A.$1028="line-height:";isc.A.$1103="border-box";isc.A.$1106=isc.Element.$1434+":";isc.A.$14d="font-size:";isc.A.$14e=" ACCESSKEY='";isc.A.$14f=" TABINDEX='";isc.A.$ob="'";isc.A.$14g=["<DIV ID='",,"' "+isc.DynamicForm.$89+"='",,"' "+isc.DynamicForm.$9a+"='"+isc.DynamicForm.$9c,"' CLASS='",,"' STYLE='",,"'",,">",,,"</DIV>"];isc.A.$157e=["<table role='presentation' cellpadding='0' cellspacing='0' style='table-layout:fixed;overflow:hidden' width='",,"'",,"><tbody><tr><td",," id='",,"' "+isc.DynamicForm.$89+"='",,"' "+isc.DynamicForm.$9a+"='"+isc.DynamicForm.$9c,"' class='",,"' style='",,";overflow:hidden' valign='middle'",,">",,,"</td></tr></tbody></table>"];isc.A.$115o=" nowrap='true'";isc.A.errorIconName="isc_errorIcon";isc.A.$n3="drawing";isc.A.$14h="#";isc.A.$92r=(!isc.Browser.isSafari)&&(!isc.Browser.isMoz);isc.A.$156m="<table role='presentation' cellpadding=0 cellspacing=0 margin=0 style='";isc.A.$156n="'><tr>";isc.A.$156o="<td>";isc.A.$156p="</td>";isc.A.$156q="</table>";isc.A.$132t="rtl";isc.A.$132u="RTL";isc.A.$14i="vertical-align:";isc.A.$133c=[,,";margin-top:",,"px;margin-bottom:",,"px;",,,,"-webkit-touch-callout:none"];isc.A.$14j={};isc.A._$_iLink_="_iLink_";isc.A._$_iImg_="_iImg_";isc.A.$18q="true";isc.A.$18r="false";isc.A.$14k="cell";isc.A.$54t="&nbsp;";isc.A.canEscapeHTML=false;isc.A.applyStaticTypeFormat=true;isc.A.mapEmptyDisplayValue=true;isc.A.$14l="smart";isc.A.$172l=0;isc.A.$14m={"Tab":true,"Arrow_Left":true,"Arrow_Right":true,"Arrow_Up":true,"Arrow_Down":true,"Home":true,"End":true,"Page_Up":true,"Page_Down":true,"Enter":true};isc.A.shouldSaveValue=true;isc.A.$152q=null;isc.A.$122s=false;isc.A.$146q="setSelectionRange";isc.A.$14n="character";isc.A.allowTextSelection=null;isc.A.$146r="getSelectionRange";isc.A.$14o="EndToEnd";isc.A.$14p="EndToStart";isc.A.$119n="StartToEnd";isc.A.$119o="StartToStart";isc.A.$14n="character";isc.A.enforceLength=false;isc.A.$683={};isc.A.$115=isc.Class.NO_OP;isc.A.$10j="Enter";isc.A.$304="Space";isc.A.$20w="Escape";isc.A.iconClickOnEnter=true;isc.A.iconClickOnSpace=true;isc.A.$54n="img";isc.A.readOnlyCanSelectText=true;isc.A.supportsMultilineEntry=false;isc.A.$1160=isc.Class.NO_OP;isc.A.supportsCutPasteEvents=false;isc.A.$jf="Tab";isc.A.$145b={"Backspace":true,"Delete":true};isc.A.$145c={"Arrow_Up":true,"Arrow_Left":true,"Home":true};isc.A.$145d={"Arrow_Down":true,"Arrow_Right":true,"End":true};isc.A.stopCharacterKeyPressBubbling=false;isc.A.stopNavKeyPressBubbling=false;isc.A.$14q="$14r";isc.A.$1598="$149y";isc.A.$170p=["Tab","Arrow_Up","Arrow_Down","Arrow_Left","Arrow_Right","Insert","Home","End","Page_Up","Page_Down","Escape","Shift","Ctrl","Alt"];isc.A.$14s={colSpan:true,rowSpan:true,startRow:true,endRow:true,showTitle:true,showHint:true};isc.A.$59q={baseStyle:true,showErrorStyle:true,showFocused:true,showErrorStyle:true,controlStyle:true,pickerIconStyle:true,textBoxStyle:true};isc.A.$172o={readOnlyWhen:true,visibleWhen:true,requiredWhen:true,formula:true,textFormula:true};isc.A.$59r="itemCellStyle";isc.A.useWildCardsByDefault=true;isc.A.$87p="ZZZZZZZZZZ";isc.B.push(isc.A.init=function isc_FormItem_init(){if(isc.$cv)arguments.$cw=this;this.$152q=this.getCanEdit();this.$152o=this.getReadOnlyDisplay();if(this.ID==null||window[this.ID]!=this){isc.ClassFactory.addGlobalID(this)}
this.initializeTabPosition();if(this.options&&!this.valueMap){this.valueMap=this.options;delete this.options}
this.$14t(this.$o5);this.$14t(this.$o6);this.$14t(this.$126);this.$14t(this.$127);this._value=this.getDefaultValue();this.$14u=true;this.$14v();if((!this.validateOnExit||!this.synchronousValidation)&&this.validators&&this.validators.length>0)
{for(var i=0;i<this.validators.length;i++){if(this.validators[i].stopOnError){this.validateOnExit=true;this.synchronousValidation=true;break}}}
if((!this.validateOnExit||!this.synchronousValidation)&&((this.stopOnError==null&&this.form&&this.form.stopOnError)||this.stopOnError))
{this.validateOnExit=true;this.synchronousValidation=true}
if(this.__sgwtRelink)this.__sgwtRelink();this.onInit()},isc.A.initializeTabPosition=function isc_FormItem_initializeTabPosition(_1){var _2=this.form?this.form.getID():null;isc.TabIndexManager.addTarget(this.ID,true,_2,null,{target:this,methodName:"autoTabIndexUpdated"},{target:this,methodName:"syntheticShiftFocus"})},isc.A.onInit=function isc_FormItem_onInit(){},isc.A.isRTL=function isc_FormItem_isRTL(){return this.containerWidget==null?isc.Page.isRTL():this.containerWidget.isRTL()},isc.A.$14t=function isc_FormItem__convertRawToMeasure(_1){var _2=this[_1];if(_2==null||isc.isA.Number(_2)||_2==this.$pa)return _2;var _3=parseInt(_2);if(_3==_2){this[_1]=_3;return _2}
return _2},isc.A.destroy=function isc_FormItem_destroy(_1,_2,_3,_4,_5){if(this.destroyed)return;if(isc.FormItem.$92t==this){isc.FormItem.$92t.checkForEditorExit(true,true)}
this.invalidateDisplayValueCache(true);if(this.isDrawn())this.cleared();var _6=this.pickList;this.pickList=null;if(_6!=null){if(_6.formItem==this)delete _6.formItem;if(_6.isVisible())_6.hide();if(!this.reusePickList())_6.destroy();else if(_6.body)_6.body.$100r=true}
var _7=this.$542;if(_7!=null){for(var _8 in _7){var _9=_7[_8];for(var i=0,_11=_9.length;i<_11;++i){var _12=_9[i],_13=(_12?window[_12]:null)||this[_8];if(_13&&!_13.destroyed&&_13.destroy&&!_13.dontAutoDestroy){_13.destroy()}}
delete this[_8]}}
this.destroyed=true;this.form.$180m(this);this.form=null;this.$14x=null;isc.ClassFactory.dereferenceGlobalID(this);this.$63x();if(isc.EH.$52d==this)isc.EH.$52d=null;this.invokeSuper(isc.FormItem,"destroy",_1,_2,_3,_4,_5)},isc.A.clear=function isc_FormItem_clear(){if(this.picker)this.picker.clear()},isc.A.getDataSource=function isc_FormItem_getDataSource(){if(isc.isA.String(this.dataSource))return isc.DS.get(this.dataSource);return this.dataSource},isc.A.registerWithDataView=function isc_FormItem_registerWithDataView(_1){if(!this.inputDataPath)return;if(!_1){_1=this.form;while(_1&&!isc.isA.DataView(_1))_1=_1.parentElement}
if(!_1){this.logWarn("Component initialized with an inputDataPath property, but no DataView was found in the parent hierarchy. inputDataPath is only applicable to DataBoundComponents and FormItems being managed by a DataView");return}
_1.registerItem(this)},isc.A.$170g=function isc_FormItem__getNotificationCallback(_1){var _2=this;do{if(_1 in _2){return{target:_2,methodName:_1}}}while((_2=_2.parentItem)!=null);return null},isc.A.getFieldName=function isc_FormItem_getFieldName(){return this.name},isc.A.getDataPath=function isc_FormItem_getDataPath(){return this.dataPath},isc.A.getTrimmedDataPath=function isc_FormItem_getTrimmedDataPath(){var _1=this.getDataPath();if(_1&&this.form&&this.form.dataPath){_1=this.form.$840(_1)}
if(_1&&_1.endsWith("/"))_1=_1.substring(0,_1.length-1);return _1},isc.A.getFullDataPath=function isc_FormItem_getFullDataPath(){var _1=this.getDataPath()||this.getFieldName();if(!_1){if(this.shouldSaveValue){this.logWarn("Encountered field with neither name nor dataPath: "+this.echo(this))}
_1=""}
if(!isc.isA.String(_1))_1=_1+"";if(_1.startsWith(isc.Canvas.$70l))return _1;var _2=this.form.getFullDataPath();if(_2&&_2!=isc.Canvas.$70l){return _2+isc.Canvas.$70l+_1}
return _1},isc.A.shouldSaveOnEnter=function isc_FormItem_shouldSaveOnEnter(){var _1=this.saveOnEnter!=null?this.saveOnEnter:false;return _1},isc.A.getItemName=function isc_FormItem_getItemName(){return this.getFieldName()},isc.A.getElementName=function isc_FormItem_getElementName(){if(this.isInactiveHTML())return"";var _1=this.getFieldName();if(this.parentItem){var _2=this.parentItem.getElementName();if(_1==isc.emptyString)_1=_2;else _1=[_2,this.$bv,_1].join(isc.emptyString)}
if(_1==null||_1==this.getID()||_1==isc.emptyString){_1=this.$qs(this.$128)}
return _1},isc.A.getBrowserInputType=function isc_FormItem_getBrowserInputType(){var _1=this.browserInputType;if(_1==null)return null;if(this.browserInputTypeMap.hasOwnProperty(_1)){_1=this.browserInputTypeMap[_1]}
return _1},isc.A.getDataElementId=function isc_FormItem_getDataElementId(){if(this.isInactiveHTML())return this.$qs(this.$129);if(this.$14y==null){this.$14y=this.$qs(this.$129,true)}
return this.$14y},isc.A.getItemID=function isc_FormItem_getItemID(){return this.getID()},isc.A.getID=function isc_FormItem_getID(){if(this.ID==null){isc.ClassFactory.addGlobalID(this)}
return this.ID},isc.A.shouldShowTitle=function isc_FormItem_shouldShowTitle(){return this.showTitle},isc.A.$1568=function isc_FormItem__getLabelElementID(){return this.$qs(this.$11)},isc.A.getTitleHTML=function isc_FormItem_getTitleHTML(){var _1=this.$1567,_2=this.getTitle(),_3=null,_4=null;if(this.$kk()){_4=this.accessKey;if(_4!=null){_2=isc.Canvas.hiliteCharacter(_2,_4)}
if(this.hasDataElement())_3=this.getDataElementId()}
_1[1]=this.$1568();if(_3!=null){_1[3]=this.$16ae
_1[4]=_3;_1[5]=isc.apos}else{_1[5]=_1[4]=_1[3]=null}
if(_4!=null){_1[6]=this.$1566
_1[7]=_4;_1[8]=isc.apos}else{_1[8]=_1[7]=_1[6]=null}
_1[10]=_2;return _1.join(isc.$ad)},isc.A.getTitle=function isc_FormItem_getTitle(){var _1;if(!this.form)return;if(this[this.form.titleField]!==_1)return this[this.form.titleField];return this[this.form.fieldIdProperty]},isc.A.getTitleOrientation=function isc_FormItem_getTitleOrientation(){return this.form.getTitleOrientation(this)},isc.A.isVisible=function isc_FormItem_isVisible(_1){if(!_1&&!this.containerWidget.isVisible())return false;if(this.visible==false)return false;if(this.parentItem&&!this.parentItem.isVisible(_1))return false;return true},isc.A.getRowSpan=function isc_FormItem_getRowSpan(){return this.rowSpan},isc.A.getColSpan=function isc_FormItem_getColSpan(){if(this.colSpan==0)this.colSpan=1;return this.colSpan},isc.A.getTitleColSpan=function isc_FormItem_getTitleColSpan(){if(this.titleColSpan==0)this.titleColSpan=1;return this.titleColSpan},isc.A.isStartRow=function isc_FormItem_isStartRow(){return this.startRow},isc.A.isEndRow=function isc_FormItem_isEndRow(){return this.endRow},isc.A.getRect=function isc_FormItem_getRect(){return[this.getLeft(),this.getTop(),this.getVisibleWidth(),this.getVisibleHeight()]},isc.A.getPageRect=function isc_FormItem_getPageRect(_1){if(_1)return this.getPageRectIncludingTitle();return[this.getPageLeft(),this.getPageTop(),this.getVisibleWidth(),this.getVisibleHeight()]},isc.A.getPeerRect=function isc_FormItem_getPeerRect(){return this.getPageRect()},isc.A.getPageRectIncludingTitle=function isc_FormItem_getPageRectIncludingTitle(){var _1=this.getPageLeft(),_2=this.getPageTop(),_3=this.getVisibleWidth(),_4=this.getVisibleHeight();if(this.showTitle){var _5=this.getTitlePageLeft(),_6=this.getTitlePageTop(),_7=this.getVisibleTitleWidth(),_8=this.form.getTitleHeight(this);;if(this.titleOrientation=="left"||this.titleOrientation=="left"||this.titleOrientation==null)
{_1=_1<_5?_1:_5;_3+=_7}else{_1=_1<_5?_1:_5;_3=_3>_7?_3:_7;if(isc.isA.Number(_8))_4+=_8}}
return[_1,_2,_3,_4]},isc.A.getCellHeight=function isc_FormItem_getCellHeight(_1){if(isc.$cv)arguments.$cw=this;if(this.cellHeight!=null){return this.cellHeight}
var _2=this.getHeight(_1);if(!isc.isA.Number(_2))return _2;var _3=this.getIconsHeight();if(_2<_3){_2=_3}
if(this.pickerIconHeight&&this.$185k()){var _4=this.pickerIconHeight+this.$14z();if(_4>_2)_2=_4}
var _5=this.containerWidget;if(this.$11e()||!isc.isA.DynamicForm(_5))return _2;_2+=this.$140();if(this.showTitle&&this.form.getTitleOrientation(this)==isc.Canvas.TOP){_2+=this.form.getTitleHeight(this)}
return _2},isc.A.shouldFixRowHeight=function isc_FormItem_shouldFixRowHeight(){return this.cellHeight!=null||(!this.shouldApplyHeightToTextBox()&&this.getHeight()!=null)},isc.A.$140=function isc_FormItem__getCellVBorderPadSpacing(){var _1=0,_2=this.form,_3=this.getCellStyle();if(this.parentItem)_2=this.parentItem;_1+=2*_2.cellSpacing;var _4=isc.isA.Number(_2.cellPadding)?_2.cellPadding:0,_5=isc.Element.$tt(_3,true);if(_5==null)_5=_4
var _6=isc.Element.$tu(_3,true);if(_6==null)_6=_4;_1+=_5;_1+=_6;_1+=isc.Element.$ym(_3);return _1},isc.A.$141=function isc_FormItem__getCellHBorderPadSpacing(){var _1=0,_2=this.form,_3=this.getCellStyle();if(this.parentItem)_2=this.parentItem;if(isc.isA.Number(_2.cellSpacing))_1+=2*_2.cellSpacing;var _4=isc.isA.Number(_2.cellPadding)?_2.cellPadding:0,_5=isc.Element.$tr(_3,true);if(_5==null)_5=_4;var _6=isc.Element.$ts(_3,true);if(_6==null)_6=_4;_1+=_5;_1+=_6;_1+=isc.Element.$yn(_3);return _1},isc.A.getInnerHeight=function isc_FormItem_getInnerHeight(){var _1=this.containerWidget;if(this.$11e())return this.$11p(this.height,true);if(this.$8t==null&&this.height!=null&&isc.isA.String(this.height)&&this.containerWidget&&!isc.isA.DynamicForm(this.containerWidget)&&this.containerWidget.sizeFormItem!=null)
{this.containerWidget.sizeFormItem(this)}
if(this.$8t){var _2=this.$8t[1];if(!isc.isA.Number(_2))return _2;if(this.$142()){_2-=this.$140()}
return _2}
return this.getHeight()},isc.A.getInnerWidth=function isc_FormItem_getInnerWidth(_1){var _2=this.containerWidget;if(this.$11e())return this.$11p(this.width);if(this.$8t==null&&this.width!=null&&isc.isA.String(this.width)&&this.containerWidget&&!isc.isA.DynamicForm(this.containerWidget)&&this.containerWidget.sizeFormItem!=null)
{this.containerWidget.sizeFormItem(this)}
var _3=this.$8t?this.$8t[0]:this.width;if(!isc.isA.Number(_3)){return _3}
if(this.$142()){_3-=this.$141()}
return _3},isc.A.getColWidth=function isc_FormItem_getColWidth(){var _1=this.form?this.form.items:null;if(_1&&_1.$8r!=null&&this.$8m!=null){var _2=this.$8m[0],_3=this.$8m[2];if(this.showTitle){var _4=this.getTitleOrientation();if(_4==isc.Canvas.LEFT)_2+=1;else if(_4==isc.Canvas.RIGHT)_3-=1}
var _5=0;for(var c=_2;c<_3;c++){_5+=_1.$8r[c]}
return _5}
return null},isc.A.getMaxHeight=function isc_FormItem_getMaxHeight(){return this.maxHeight},isc.A.getMinHeight=function isc_FormItem_getMinHeight(){return this.minHeight},isc.A.$11e=function isc_FormItem__absPos(){return(this.containerWidget.$11e&&this.containerWidget.$11e())},isc.A.$142=function isc_FormItem__writtenIntoCell(){return(this.containerItem!=null||(this.form==this.containerWidget&&!this.$11e()))},isc.A.$11p=function isc_FormItem__getPercentCoord(_1,_2){if(isc.isA.String(_1)&&isc.endsWith(_1,this.$o9)){var _3=this.containerWidget,_4=_2?_3.getInnerHeight():_3.getInnerWidth();return Math.round((parseInt(_1,10)/100)*_4)}
return _1},isc.A.getElementWidth=function isc_FormItem_getElementWidth(){if(this.fitWidthToValueIcon()&&this.showValueIconOnly){var _1=this.$186i();if(this.$185k()){_1+=this.getPickerIconWidth();var _2=this.getPickerIcon();if(_2.hspace!=null)_1+=_2.hspace;if(this.pickerIconStyle)
_1+=isc.Element.$yp(this.getPickerIconStyle());if(this.controlStyle){_1+=isc.Element.$yp(this.getControlStyle())}}
return _1}
var _1=this.getInnerWidth();if(!isc.isA.Number(_1))return null;_1-=this.getTotalIconsWidth();return(isc.isA.Number(_1)?Math.max(_1,1):null)},isc.A.getTextBoxWidth=function isc_FormItem_getTextBoxWidth(_1){if(this.fitWidthToValueIcon()&&this.showValueIconOnly){return this.$186i()}
var _2=this.getElementWidth();if(!isc.isA.Number(_2))return _2;var _3=this.getTextBoxStyle();if(_3!=null){_2-=(isc.Element.$tf(_3)+isc.Element.$tg(_3));if(this.$143()){_2-=isc.Element.$yp(_3)}}
if(this.$185k()){_2-=this.getPickerIconWidth();var _4=this.getPickerIcon();if(_4.hspace!=null)_2-=_4.hspace;if(this.pickerIconStyle)
_2-=isc.Element.$yp(this.getPickerIconStyle());if(this.controlStyle){_2-=isc.Element.$yp(this.getControlStyle())}}
_2-=this.$156j+this.$156l;if(this.hasDataElement()&&this.$144(_1)){_2-=((this.getValueIconWidth()||0)+(this.valueIconLeftPadding+this.valueIconRightPadding))}
return _2-this.$672()},isc.A.getErrorWidth=function isc_FormItem_getErrorWidth(){var _1=0;if(this.form.showInlineErrors&&this.hasErrors()){var _2=this.getErrorOrientation();if(_2==isc.Canvas.LEFT||_2==isc.Canvas.RIGHT){if(this.shouldShowErrorText()){_1+=this.errorMessageWidth}else if(this.shouldShowErrorIcon()){_1+=this.errorIconWidth+this.iconHSpace}}}
return _1},isc.A.$672=function isc_FormItem__getErrorWidthAdjustment(){var _1=this.getErrorWidth();if(_1!=0&&this.expandHintAndErrors&&(this.getColWidth()!=null)){var _2=this.getColWidth()-this.getInnerWidth();if(_2>0)_1-=_2;if(_1<0)_1=0}
return _1},isc.A.shouldApplyHeightToTextBox=function isc_FormItem_shouldApplyHeightToTextBox(){if(this.applyHeightToTextBox!=null)return this.applyHeightToTextBox;if(this.renderAsStatic())return!!this.clipStaticValue;return true},isc.A.getTextBoxHeight=function isc_FormItem_getTextBoxHeight(_1){if(!this.shouldApplyHeightToTextBox()){return null}
var _2=this.getPixelHeight(true);if(!isc.isA.Number(_2))return _2;var _3=this.getTextBoxStyle();if(_3!=null){_2-=(isc.Element.$th(_3)+isc.Element.$ti(_3));if(this.$143()){_2-=isc.Element.$yo(_3)}}
if(this.$1857()&&this.controlStyle){_2-=isc.Element.$yo(this.getControlStyle())}
if(this.showTitle&&this.form.getTitleOrientation(this)==isc.Canvas.TOP&&!isc.isA.Number(this.getCellHeight()))
{_2-=this.form.getTitleHeight(this)}
return _2},isc.A.$143=function isc_FormItem__sizeTextBoxAsContentBox(){return!isc.Browser.isBorderBox},isc.A.getPickerIconWidth=function isc_FormItem_getPickerIconWidth(){var _1=this.pickerIconWidth!=null?this.pickerIconWidth:this.getPickerIconHeight(true);if(_1==null)_1=this.iconWidth;return _1},isc.A.getPickerIconHeight=function isc_FormItem_getPickerIconHeight(_1){if(this.pickerIconHeight!=null)return this.pickerIconHeight;else{var _2=(isc.isA.Number(this.getHeight())?this.getHeight():this.getInnerHeight());if(!_1&&_2==null)return this.iconHeight;if(!isc.isA.Number(_2))return null;_2-=this.$14z();this.pickerIconHeight=_2;return _2}},isc.A.$14z=function isc_FormItem__getPickerIconVPad(){var _1=0;if(this.controlStyle){_1+=isc.Element.$yo(this.controlStyle)}
if(this.pickerIconStyle){_1+=isc.Element.$yo(this.pickerIconStyle)}
return _1},isc.A.getHeight=function isc_FormItem_getHeight(){return(this.renderAsStatic()?(this.staticHeight||this.height):this.height)},isc.A.getPixelHeight=function isc_FormItem_getPixelHeight(_1){var _2=this.getHeight();if(!isc.isA.Number(_2)){var _3=this.getInnerHeight();if(this.cellHeight!=null&&isc.isA.String(_2)&&_2.endsWith("%"))
{var _4=parseInt(_2);if(isc.isA.Number(_3)){_2=Math.round(_3*(_4/100))}else{_2=_3}}else{_2=_3}}
if(!isc.isA.Number(_2))return _1?_2:-1;if(this.valueIcons!=null||this.getValueIcon!=null){var _5=this.getValueIconHeight();if(_5>_2)_2=_5}
return _2},isc.A.getVisibleHeight=function isc_FormItem_getVisibleHeight(){var _1=this.isDrawn()?this.getOuterElement():null;if(_1==null){this.logInfo("getVisibleHeight() - unable to determine drawn height for this item - returning pixel height from specified height","sizing");if(isc.isA.Number(this.height)){return this.height}
this.logWarn("getVisibleHeight() unable to determine height - returning zero","sizing");return 0}
return _1.offsetHeight},isc.A.getIconHeight=function isc_FormItem_getIconHeight(_1){if(_1==null&&this.icons!=null&&this.icons.getLength()>0)_1=this.icons[0];else if(!this.$145(_1)){this.logWarn("getIconHeight() passed invalid icon:"+isc.Log.echoAll(_1));return null}
return(_1.height!=null?_1.height:this.iconHeight)},isc.A.getTitleVisibleHeight=function isc_FormItem_getTitleVisibleHeight(){var _1=this.isDrawn()&&this.form?isc.Element.get(this.form.$427(this)):null;if(_1==null){var _2="getTitleHeight() Unable to determine position for "+(this.name==null?"this item ":this.name)+". ";if(this.isDrawn()){_2+="This method is not supported by items of type "+this.getClass()}else{_2+="Position cannot be determined before the element is drawn"}
_2+=" - returning zero.";this.form.logWarn(_2);return 0}
return isc.Element.getVisibleHeight(_1)},isc.A.getWidth=function isc_FormItem_getWidth(){return this.width},isc.A.getPixelWidth=function isc_FormItem_getPixelWidth(){var _1=this.getWidth();if(!isc.isA.Number(_1)){var _2=this.getInnerWidth();if(_2!=null)_1=_2}
return isc.isA.Number(_1)?_1:-1},isc.A.getVisibleWidth=function isc_FormItem_getVisibleWidth(){var _1=this.isDrawn()?this.getOuterElement():null;if(_1==null){this.logInfo("getVisibleWidth() - unable to determine drawn width for this item - returning pixel width from specified width","sizing");if(isc.isA.Number(this.width)){return this.width}else if(this.form&&this.form.items.$8r!=null){return this.form.items.$8r[this.form.getItems().indexOf(this)]}
this.logWarn("getVisibleWidth() unable to determine width - returning zero","sizing");return 0}
return _1.offsetWidth},isc.A.getVisibleTitleWidth=function isc_FormItem_getVisibleTitleWidth(_1){if(_1){var _2=isc.Element.get(this.$170q());if(_2==null){this.logInfo("getVisibleTitleWidth() was called with labelOnly: true, but this item ("+this.getID()+") has no label element.  Returning the width of the containing cell, as if labelOnly were false")}else{return _2.offsetWidth}}
var _2=this.isDrawn()&&this.form?isc.Element.get(this.form.$427(this)):null;if(_2==null){this.logInfo("getVisibleTitleWidth() - unable to determine drawn width for this item - returning 0","sizing");return 0}
return _2.offsetWidth},isc.A.$170q=function isc_FormItem__getTitleLabelID(){return this.getID()+this.$170o},isc.A.getIconWidth=function isc_FormItem_getIconWidth(_1){if(_1==null&&this.icons!=null&&this.icons.getLength()>0)_1=this.icons[0];else if(!this.$145(_1)){this.logWarn("getIconWidth() passed invalid icon:"+isc.Log.echoAll(_1));return null}
return(_1.width!=null?_1.width:this.iconWidth)},isc.A.setHeight=function isc_FormItem_setHeight(_1){if("100%"==_1){this.height="*"}else{this.height=_1}
this.redraw()},isc.A.setWidth=function isc_FormItem_setWidth(_1){if("100%"==_1){this.width="*"}else{this.width=_1}
this.redraw()},isc.A.setLeft=function isc_FormItem_setLeft(_1){this.left=_1;this.redraw()},isc.A.setTop=function isc_FormItem_setTop(_1){this.top=_1;this.redraw()},isc.A.moved=function isc_FormItem_moved(){},isc.A.visibilityChanged=function isc_FormItem_visibilityChanged(){},isc.A.zIndexChanged=function isc_FormItem_zIndexChanged(){},isc.A.getInactiveEditorHTML=function isc_FormItem_getInactiveEditorHTML(_1,_2,_3,_4){this.$68x=true;this.$68u=this.setupInactiveContext(_4);if(this.logIsDebugEnabled("inactiveEditorHTML")){this.logDebug("getInactiveEditorHTML() called - context passed in:"+this.echo(_4)+" generated context ID:"+this.$68u,"inactiveEditorHTML")}
var _5=this.getStandaloneItemHTML(_1,_2,_3);delete this.$68u;delete this.$68x;return _5},isc.A.setupInactiveContext=function isc_FormItem_setupInactiveContext(_1){if(_1==null)_1={};if(this.$68y())_1.isPrintHTML=true;var _2=this.$68w++;_1.inactiveContextID=_2;_1.formItem=this;if(!this.$68v)this.$68v={};this.$68v[_2]=_1;return _2},isc.A.clearAllInactiveEditorContexts=function isc_FormItem_clearAllInactiveEditorContexts(){delete this.$68v},isc.A.clearInactiveEditorContext=function isc_FormItem_clearInactiveEditorContext(_1){if(isc.isAn.Object(_1))_1=_1.inactiveContextID;if(this.$68v)delete this.$68v[_1]},isc.A.$681=function isc_FormItem__getInactiveContextFromElement(_1){if(_1&&_1.id!=null&&this.$68v!=null){var _2=_1.id,_3=this.$557(_2);if(_3){var _4=_3.match(this.$682);if(_4){return this.$68v[_4[1]]}}}
return null},isc.A.isInactiveHTML=function isc_FormItem_isInactiveHTML(){if(this.parentItem&&this.parentItem.isInactiveHTML())return true;return this.$68y()||this.$68x},isc.A.$68y=function isc_FormItem__isPrinting(){return this.containerWidget&&this.containerWidget.isPrinting});isc.evalBoundary;isc.B.push(isc.A.$187i=function isc_FormItem__cellNoWrap(){return false},isc.A.getStandaloneItemWrapCSS=function isc_FormItem_getStandaloneItemWrapCSS(){return"white-space:nowrap;"},isc.A.getStandaloneItemHTML=function isc_FormItem_getStandaloneItemHTML(_1,_2,_3){var _4=isc.SB.create(),_5=this.form;if(_5){if(this.$11e()){var _6=this.$11p(this.left),_7=this.$11p(this.top,true),_8=this.getInnerWidth(),_9=this.getInnerHeight();if(!isc.isA.Number(_6))_6=0;if(!isc.isA.Number(_7))_7=0;_4.append(this.$13a);_4.appendNumber(isc.Canvas._nextZIndex);_4.append(this.$139w);_4.appendNumber(_6);_4.append(this.$13b);_4.appendNumber(_7);if(isc.isA.Number(_8)){_4.append(this.$13c);_4.appendNumber(_8)}
if(isc.isA.Number(_9)){_4.append(this.$13d);_4.appendNumber(_9)}
_4.append(this.$13e,this.$146(),this.$13f)}
var _10=this.$13h,_11=_5.getID(),_12=this.getID();_10[1]=this.getStandaloneItemWrapCSS();_10[3]=_11;_10[5]=_12;_10[7]=this.$qs(this.$13j);_4.append(_10);_4.append(this.getInnerHTML(_1,_2,_3,true));_4.append(this.$13i);if(this.$11e()){_4.append(this.$13g)}}
return _4.release(false)},isc.A.$146=function isc_FormItem__getAbsDivID(){return this.$qs(this.$13l)},isc.A.getAbsDiv=function isc_FormItem_getAbsDiv(_1){if(this.$13m)return this.$13m;var _2=this.isDrawn();if(!_1&&!_2)return;var _3=isc.Element.get(this.$146());if(_2)this.$13m=_3;return _3},isc.A.$147=function isc_FormItem__hasExternalIcons(){var _1=this.icons;if(!_1)return false;var _2=this.$156r();for(var i=0;i<_1.length;i++){if(_2&&_1[i].inline)continue;if(!_1[i].writeIntoItem)return true}
return false},isc.A.useDisabledEventMask=function isc_FormItem_useDisabledEventMask(){return((isc.Browser.isMoz&&this.hasDataElement())||(isc.Browser.isIE&&isc.isA.TextItem(this)))&&this.getHeight()!=null},isc.A.renderDisabledEventMask=function isc_FormItem_renderDisabledEventMask(){return(this.isInactiveHTML()||this.renderAsDisabled())&&this.useDisabledEventMask()},isc.A.$148=function isc_FormItem__getEventMaskHTML(){var _1=this.$13n;_1[1]=this.$149();_1[3]=this.getHeight();_1[5]=this.getItemID();_1[7]=this.$qs("eventMask");_1[9]=this.$938();return _1.join(isc.emptyString)},isc.A.$938=function isc_FormItem__getEventMaskSpacerHTML(){return isc.Canvas.spacerHTML(1600,100)},isc.A.$43b=function isc_FormItem__getEventMaskElement(){return isc.Element.get(this.$qs("eventMask"))},isc.A.$149=function isc_FormItem__getEventMaskWidth(){var _1=this.getElementWidth();if(_1==null){if(isc.RadioItem&&isc.isA.RadioItem(this)&&this.parentItem!=null){_1=this.parentItem.getElementWidth()}
if(_1==null)return 0}else{if(this.form.showInlineErrors&&this.hasErrors()&&this.getErrorOrientation()==isc.Canvas.LEFT)
{_1-=this.getErrorWidth()}}
return _1},isc.A.getBrowserSpellCheck=function isc_FormItem_getBrowserSpellCheck(){if(this.browserSpellCheck!=null)return this.browserSpellCheck;return this.form.browserSpellCheck},isc.A.$11d=function isc_FormItem__useHiddenDataElement(){return(this.shouldSaveValue&&!this.hasDataElement()&&this.shouldSubmitValue())},isc.A.$15a=function isc_FormItem__getHiddenDataElementID(){return this.$qs(this.$13o)},isc.A.$15b=function isc_FormItem__getHiddenDataElement(){return this.$15c(this.$13o)},isc.A.$15c=function isc_FormItem__getHTMLPartHandle(_1){if(!this.isDrawn())return null;if(!this.$15d)this.$15d={};var _2=this.$15d[_1];if(_2==null){_2=isc.Element.get(this.$qs(_1));if(_2!=null)this.$15d[_1]=_2}
return _2},isc.A.$15e=function isc_FormItem__getControlTableID(){return this.$qs(this.$13p)},isc.A.$15f=function isc_FormItem__getControlTableElement(){return this.$15c(this.$13p)},isc.A.$15g=function isc_FormItem__getTextBoxID(){return this.$qs(this.$13q)},isc.A.$15h=function isc_FormItem__getTextBoxElement(){if(this.hasDataElement()&&this.$15i&&!this.renderAsStatic()){return this.getDataElement()}
return this.$15c(this.$13q)},isc.A.$169r=function isc_FormItem__getInlineIconsWrapperID(){return this.$qs(this.$169o)},isc.A.$169s=function isc_FormItem__getElementStyledAsTextBox(){if(this.$169t()&&this.$169p==="divStyledAsDataElement"){return this.$15c(this.$169o)}else{return this.$15h()}},isc.A.$15j=function isc_FormItem__getPickerIconCellID(){return this.$qs(this.$13r)},isc.A.$15k=function isc_FormItem__getPickerIconCellElement(){return this.$15c(this.$13r)},isc.A.$15l=function isc_FormItem__getHiddenDataElementHTML(){return"<INPUT type='hidden' name='"+this.getFieldName()+"' ID='"+this.$15a()+"'>"},isc.A.$59s=function isc_FormItem__getHintCellID(){return this.$qs(this.$59p)},isc.A.$59t=function isc_FormItem__getHintCellElement(){return this.$15c(this.$59p)},isc.A.updateStateForRollover=function isc_FormItem_updateStateForRollover(){this.$176a();this.$176b();var _1=this.$185k()?this.getPickerIcon():null;if(_1&&this.updatePickerIconOnOver!=false){this.$168v(_1,(this.$142q||this.$176c))}
var _2=this.icons;if(_2){for(var i=0;i<_2.length;i++){if(_2[i]==_1||_2[i]==null)continue;if(this.$165(_2[i])&&this.$176d(_2[i])==this.$13q)
{this.$168v(_2[i],(this.$142q||this.$176c))}}}},isc.A.updateState=function isc_FormItem_updateState(){if(!this.isDrawn())return;var _1=(this.containerWidget!=this.form||this.$11e());if(!_1){this.$176e();this.$176f()}
this.$176a();this.$176b()},isc.A.$176e=function isc_FormItem__updateCellState(){if(this.containerWidget!=this.form||this.$11e())return;var _1=this.logIsDebugEnabled(this.$13s);var _2=this.getCellStyle();if(_1)this.logDebug("About to apply basic cell style:"+_2,"FormItemStyling");var _3=this.getFormCell();if(_3)_3.className=_2;var _4=this.getOuterTableElement();if(_4)_4.className=_2},isc.A.$176f=function isc_FormItem__updateTitleCellState(){if(this.showTitle)this.form.updateTitleCellState(this)},isc.A.$176a=function isc_FormItem__updatePickerCellAndControlTableState(){var _1=this.logIsDebugEnabled(this.$13s);if(this.$1857()){var _2=this.getControlStyle(),_3=this.getPickerIconStyle();if(_1){this.logDebug("About to apply cell styles to control box and picker icon cell:"+[_2,_3],"FormItemStyling")}
var _4=this.$15f();if(_4)_4.className=_2;var _5=this.$15k();if(_5)_5.className=_3}},isc.A.$176b=function isc_FormItem__updateTextBoxState(){var _1=this.logIsDebugEnabled(this.$13s);var _2=!this.$1563?this.getTextBoxStyle():this.$66v();if(_1)this.logDebug("About to apply text box style:"+_2,"FormItemStyling");var _3=this.$169s();if(_3!=null){_3.className=_2}
var _4=this.$15h();if(_4!=null){if(this.getImplicitSave()){var _5=_4.style;if(this.awaitingImplicitSave){if(_5&&this.$95y!=true){this.$95y=true;this.$95z=""+_5.cssText;_5.cssText=""+_5.cssText+this.editPendingCSSText}}else{if(this.wasAwaitingImplicitSave==true&&this.$95z){delete this.$95y;delete this.wasAwaitingImplicitSave;_5.cssText=""+this.$95z;delete this.$95z}}}}
if(this.$15m()&&_4){if(!this.$15n){var _6=this.getValue();var _7=this.getTextBoxWidth(_6),_8=this.getTextBoxHeight(_6);_7+=isc.Element.getHBorderSize(_4)-2;if(_8!=null)_8+=isc.Element.getVBorderSize(_4)-2;var _9=this.$qs("focusOutline");isc.Element.insertAdjacentHTML(_4,"beforeBegin","<DIV ID='"+_9+(this.textBoxStyle?"' CLASS='"+this.textBoxStyle+"Focused'":"'")+" STYLE='background-image:none;background-color:transparent;position:absolute;width:"+_7+(_8==null?"px;":"px;height:"+_8)+"px;visibility:hidden;border:1px dotted white;z-index:100;'>&nbsp;</DIV>");this.$15n=isc.Element.get(_9)}
if(this.hasFocus)this.$15n.style.visibility="inherit";else this.$15n.style.visibility="hidden"}},isc.A.$15o=function isc_FormItem__warnDeprecated(_1,_2,_3){if(!this.logIsInfoEnabled(this.$13t))return;if(!this.$15p)this.$15p={};if(this.$15p[_1]==true)return;if(_3==null)_3="5.5";var _4=isc.SB.create();_4.append("Using '",_1,"': ",this[_1]," to style this form item.  This property is deprecated as of SmartClient Version ",_3," - we recommend removing this property and using '",_2,"' instead.");this.logInfo(_4.release(false),"deprecated");this.$15p[_1]=true},isc.A.getInnerHTML=function isc_FormItem_getInnerHTML(_1,_2,_3,_4){var _5,_6;if(this.isInactiveHTML()&&this.$68u==null){_5=true;var _7,_8=this.parentItem;if(_8!=null&&_8.isInactiveHTML()){if(_8.$68u==null){_8.setupInactiveContext();_6=true}
_7=_8.$68v[_8.$68u]}
this.$68u=this.setupInactiveContext(_7);if(this.logIsDebugEnabled("inactiveEditorHTML")){this.logDebug("getInnerHTML(): Item is marked as inactive - set up new inactive context ID:"+this.$68u,"inactiveEditorHTML")}}
this.$15q=_2&&!this.$712();var _9;if(this.$11d()){if(!_9)_9=isc.SB.create();_9.append(this.$15l())}
if(this.$712())_2=false;var _10=this.$15r(_1,_2,_3);var _11;if(_9!=null){_9.append(_10);if(_4){_11=_9.getArray().duplicate();_9.release(true)}else{_11=_9.release(false)}}else{_11=(_4?_10:_10.join(isc.emptyString))}
if(_5)delete this.$68u;if(this.parentItem&&_6)
delete this.parentItem.$68u;return _11},isc.A.$15s=function isc_FormItem__writeOuterTable(_1,_2){if(_2)return true;if(_1&&this.getHint()!=null)return true;if(this.$147())return true},isc.A.$157c=function isc_FormItem__getValueIconStateSuffix(){return((this.isDisabled()||this.isReadOnly())&&this.showValueIconDisabled?this.$13w:this.$15t)},isc.A.$144=function isc_FormItem__getValueIcon(_1){if(this.suppressValueIcon)return null;var _2;if(this.$68y()&&this.getPrintValueIcon!=null){_2=this.getPrintValueIcon(_1)}else if(this.getValueIcon!=null){_2=this.getValueIcon(_1)}else{if(_1==null)_2=this.emptyValueIcon;else if(this.valueIcons!=null)_2=this.valueIcons[_1]}
if(_2==null)return null;if(_2==isc.Canvas.$5w)return _2;var _3=this.$157c();if(_3!=null){if(!isc.CheckboxItem.$15u)isc.CheckboxItem.$15u={};var _4=isc.CheckboxItem.$15u[_2];if(!_4){_4={};var _5=isc.Canvas.$1861(_2);if(_5){_4.Over=isc.addProperties({},_5);_4.Down=isc.addProperties({},_5);_4.Disabled=isc.addProperties({},_5);if(_5.src){_4.Over.src=isc.Img.urlForState(_4.Over.src,false,false,this.$13u);_4.Down.src=isc.Img.urlForState(_4.Over.src,false,false,this.$13v);_4.Disabled.src=isc.Img.urlForState(_4.Over.src,false,false,this.$13w)}
if(_5.cssClass){_4.Over.cssClass+=this.$13u;_4.Down.cssClass+=this.$13v;_4.Disabled.cssClass+=this.$13w}}else{_4.Over=isc.Img.urlForState(_2,false,false,this.$13u);_4.Down=isc.Img.urlForState(_2,false,false,this.$13v);_4.Disabled=isc.Img.urlForState(_2,false,false,this.$13w)}
isc.CheckboxItem.$15u[_2]=_4}
_2=_4[_3]}
return _2},isc.A.$157d=function isc_FormItem__getValueIconStyle(_1){if(this.getValueIconStyle==null)return null;var _2;if(this.$68y()&&this.getPrintValueIconStyle!=null){_2=this.getPrintValueIconStyle(_1)}else{_2=this.getValueIconStyle(_1)}
if(_2!=null){var _3=this.$157c();if(_3!=null){_2+=_3}}
return _2},isc.A.getValueIconWidth=function isc_FormItem_getValueIconWidth(){var _1=this.valueIconWidth;if(_1==null)_1=this.valueIconSize;return _1},isc.A.$186i=function isc_FormItem__getValueIconAndPadWidth(){return this.getValueIconWidth()+(this.valueIconLeftPadding+this.valueIconRightPadding)},isc.A.getValueIconHeight=function isc_FormItem_getValueIconHeight(){var _1=this.valueIconHeight;if(_1==null)_1=this.valueIconSize;return _1},isc.A.$xq=function isc_FormItem__getValueIconHTML(_1){var _2=this.$144(_1);if(_2==null){return isc.emptyString}
if(this.imageURLSuffix!=null&&_2!=isc.Canvas.$5w){_2+=this.imageURLSuffix}
var _3=this.imageURLPrefix||this.baseURL||this.imgDir;var _4=this.$157d(_1);var _5=this.getValueIconWidth();var _6=this.getValueIconHeight();var _7=this.isRTL(),_8=_7?this.valueIconRightPadding:this.valueIconLeftPadding,_9=_7?this.valueIconLeftPadding:this.valueIconRightPadding;return isc.Canvas.$xq(_2,_3,_4,_5,_6,_8,_9,this.$qs(this.$13x),this.containerWidget)},isc.A.$15v=function isc_FormItem__getValueIconHandle(){if(!this.isDrawn())return null;var _1=isc.Element.get(this.$qs(this.$13x));return _1},isc.A.$156r=function isc_FormItem__supportsInlineIcons(){return false},isc.A.$169t=function isc_FormItem__haveInlineIcons(){return this.$156r()&&this.$156h!=null&&this.$156h.length>0},isc.A.$165z=function isc_FormItem__fillHintCellTemplate(_1,_2,_3){var _4=this.$132;_4[1]=this.$59s();_4[3]=_2;var _5=this.$1650();if(!_5){_4[5]="white-space:nowrap"}else{_4[5]=null}
var _6=this.$1651(),_7=!isc.Browser.isIE||isc.Browser.isIE8Strict||isc.Browser.isIE9;if(_5&&_6>0&&_7){_4[6]="min-width:";_4[7]=_6;_4[8]="px"}else{_4[6]=null;_4[7]=null;_4[8]=null}
_4[10]=_3;var _8=12
_4[_8+3]=_1;if(_5&&_6>0&&!_7){_4[_8]="<div style='width:";_4[_8+1]=_6;_4[_8+2]="px'>";_4[_8+4]="</div>"}else{_4[_8]=null;_4[_8+1]=null;_4[_8+2]=null;_4[_8+4]=null}
return _4},isc.A.$1650=function isc_FormItem__shouldWrapHintText(){var _1=this.wrapHintText;if(_1!=null)return _1;var _2=this.form;if(_2!=null)return!!_2.wrapHintText;return false},isc.A.$1651=function isc_FormItem__getMinHintWidth(){var _1=this.minHintWidth;if(_1!=null)return _1;var _2=this.form;if(_2!=null){_1=_2.minHintWidth;if(_1!=null)return _1}
return null},isc.A.$15r=function isc_FormItem__getTableHTML(_1,_2,_3){var _4=this.getErrorOrientation(),_5,_6=_4==isc.Canvas.LEFT,_7,_8=this.isReadOnly();if(_3&&(_6||_4==isc.Canvas.RIGHT))
{var _9=this.getErrors();if(_9){_5=true;_7=this.getErrorHTML(_9)}}
var _10=this.iconVAlign,_11=this.mapValueToDisplay(_1),_12=this.$15s(_2,_5),_13=this.$1857();var _14=_12?isc.FormItem.$82b():[];if(_12){_14.length=13;_14[1]=this.$15w();_14[3]=this.getOuterTableCSS();if(this.containerWidget==this.form&&!this.$11e()){_14[5]=this.getCellStyle()}else{_14[5]=null}
if(_5&&_6){_14[7]=isc.StringBuffer.concat("<TD STYLE='",isc.Canvas.$42a,"' CLASS='",this.getCellStyle(),"'>",_7,"</TD>")}else _14[7]=null;if(!_13)_14[9]=this.getTextBoxCellCSS();else _14[9]=isc.Canvas.$42a;_14[11]=_10}
if(this.renderDisabledEventMask()){_14[_14.length]=this.$148()}
var _15=(_8?this.getReadOnlyHTML(_11,_1):this.getElementHTML(_11,_1));if(this.$169t()){var _16=this.isRTL(),_17=this.getTextBoxStyle(),_18=this.getPixelHeight(true),_19=this.$169b(_17),_20=this.$169c(_17);if(this.$169p==="absolutePositioning"){var _21=isc.Element.$tl(_17)+_19,_22=isc.Element.$tm(_17)+_20;_15="<div id='"+this.$169r()+"' style='position:relative;display:inline-block'>"+_15;_15+=this.getIconsHTML(false,_16?this.$156k:this.$156i,"position:absolute;top:0px;left:"+_21+"px;height:"+_18+"px");_15+=this.getIconsHTML(false,_16?this.$156i:this.$156k,"position:absolute;top:0px;right:"+_22+"px;height:"+_18+"px");_15+="</div>"}else{var _23=0;if(isc.Browser.isIE&&!isc.Browser.isStrict){_23=isc.Element.$tt(_17);_18-=_23+isc.Element.$tu(_17)}
var _24=this.$169q;_24[1]=this.$169r();_24[3]=_17;_24[5]=null;if(!_8){var _25=this.getTextBoxWidth(_1);_25+=this.$156j+this.$156l;if(isc.isA.Number(_25)){if(isc.Browser.isIE&&!isc.Browser.isStrict){_25+=isc.Element.$yn(_17)+_19+_20}
if((isc.Browser.isOpera||isc.Browser.isMoz||isc.Browser.isSafari||isc.Browser.isIE9)&&!this.$1618()){_24[5]=this.$137+_25+this.$38}else{_24[5]=this.$93+_25+this.$38}}}
_24[7]=this.getIconsHTML(false,_16?this.$156k:this.$156i,"position:absolute;top:"+_23+"px;left:"+_19+"px;height:"+_18+"px");_24[8]=_15;_24[9]=this.getIconsHTML(false,_16?this.$156i:this.$156k,"position:absolute;top:"+_23+"px;right:"+_20+"px;height:"+_18+"px");_15=_24.join(isc.$ad);_24[8]=null}}
if(!_13){_14[_14.length]=_15}else{var _26=this.getPickerIconStyle(),_27=this.getID(),_28=this.getControlStyle(),_29=this.$130,_30=this.$15e(),_31=this.$15g(),_32=this.$15j();_29[1]=_30;_29[3]=_27;_29[6]=this.getControlTableCSS();if(_28==null&&this.containerWidget==this.form&&!this.$11e()){_29[8]=this.getCellStyle();_29[6]+=isc.Canvas.$42a}else{_29[8]=_28}
_29[10]=this.getTextBoxCellCSS();_29[12]=_15;if(_13){_29[14]=_32;_29[16]=_26;_29[18]=this.getPickerIconCellCSS();_29[20]=this.$186d()}else{_29[14]=_29[16]=null;_29[18]=_29[20]=null}
for(var i=0;i<_29.length;i++){_14[_14.length]=_29[i]}}
if(_12){if(this.$147()){var _34=isc.FormItem.$82c();_34[1]=_10;_34[5]=this.iconHeight;_34[7]=this.getCellStyle();_34[9]=this.getIconCellID();_34[11]=this.getIconsHTML();for(var i=0;i<_34.length;i++){_14[_14.length]=_34[i]}}
var _35=(_5&&!_6);var _36;if(_2){_36=this.getHint();if(isc.isA.emptyString(_36))_36=null}
if(_36||_35){var _37=(_36!=null&&!isc.isAn.emptyString(_36)),_38=_35&&_7!=null&&!isc.isAn.emptyString(_7);if(_37){_14.add("</TD>");var _39=this.$165z(_36,this.getHintStyle());_14.push.apply(_14,_39)}
if(_38){_14.add(isc.StringBuffer.concat("<TD STYLE='",isc.Canvas.$42a,"' CLASS='",this.getCellStyle(),"'>",_7))}}
_14[_14.length]=this.$13z}
return _14},isc.A.$186d=function isc_FormItem__getPickerIconCellValue(){if(this.$185k()){var _1=this.getPickerIcon(),_2=this.$16j(true),_3=_2&&this.$54o(_1,true);return this.getIconHTML(_1,null,this.iconIsDisabled(_1),!!_3)}else{return null}},isc.A.$169b=function isc_FormItem__getInlineLeftPadding(_1){return isc.Element.$tr(_1)},isc.A.$169c=function isc_FormItem__getInlineRightPadding(_1){return isc.Element.$ts(_1)},isc.A.getIconCellID=function isc_FormItem_getIconCellID(){return this.$qs(this.$92q)},isc.A.$15w=function isc_FormItem__getOuterTableID(){return this.$qs(this.$133)},isc.A.$15x=function isc_FormItem__getCellStyle(_1,_2){if(this.$161p()&&this.pendingStatus&&!this.$1602){_1=this.$1603(_1,_2)}
if(_1==null)return null;var _3=this.hasErrors(),_4=this.showRTL&&this.isRTL();var _5;if(_4){_5=isc.FormItem.$132s[_1];if(!_5){_5=isc.FormItem.$132s[_1]={Normal:_1+"RTL",Error:_1+"ErrorRTL",Over:_1+"OverRTL",Focused:_1+"FocusedRTL",ErrorFocused:_1+"ErrorFocusedRTL",ErrorOver:_1+"ErrorOverRTL",FocusedOver:_1+"FocusedOverRTL",ErrorFocusedOver:_1+"ErrorFocusedOverRTL",Disabled:_1+"DisabledRTL"}}}else{_5=isc.FormItem.$15y[_1];if(!_5){_5=isc.FormItem.$15y[_1]={Normal:_1,Error:_1+"Error",Over:_1+"Over",Focused:_1+"Focused",ErrorFocused:_1+"ErrorFocused",ErrorOver:_1+"ErrorOver",FocusedOver:_1+"FocusedOver",ErrorFocusedOver:_1+"ErrorFocusedOver",Disabled:_1+"Disabled"}}}
var _6;var _7=this.showFocused&&this.hasFocus&&!this.isInactiveHTML();if(_2==this.$1601&&_7){_7=this.showFocusedPickerIcon}
var _8=false;if(this.showOver&&!this.isInactiveHTML()&&!this.isDisabled()&&(this.$142q||this.$176c))
{switch(_2){case this.$13q:_8=this.updateTextBoxOnOver!=false;break;case this.$13p:case this.$1601:_8=this.updateControlOnOver!=false;break}}
if(_3&&this.shouldShowErrorStyle()&&this.form.showInlineErrors){_6=this.showFocusedErrorState&&this.hasFocus&&!this.isInactiveHTML()?(_8?_5.ErrorFocusedOver:_5.ErrorFocused):_5.Error}else{if(_7){_6=_8?_5.FocusedOver:_5.Focused}else if(this.showDisabled&&this.renderAsDisabled()){_6=_5.Disabled}else{_6=_8?_5.Over:_5.Normal}}
if(this.getCustomState){var _9=_6.substring(_1.length);_9=this.getCustomState(_2?_2:this.$14k,_9,this);if(_9)_6=_1+_9}
return _6},isc.A.$1603=function isc_FormItem__getPendingBaseStyle(_1,_2){if(_2===this.$160y||_2===this.$160z||_2===this.$14k||_2===this.$1600||_2===this.$13q)
{return _1+"Pending"}
return _1},isc.A.getCellStyle=function isc_FormItem_getCellStyle(){if(this.parentItem!=null){if(this.parentItem.itemCellStyle)return this.$15x(this.parentItem.itemCellStyle,this.$160x)}
var _1=this.$15x(this.cellStyle,this.$14k);if(!this.hasErrors()){if(this.cellClassName!=null){this.$15o("cellClassName","cellStyle");_1=this.cellClassName}}else{if(this.errorCellClassName!=null){this.$15o("errorCellClassname","cellStyle");_1=this.errorCellClassName}}
return _1},isc.A.setCellStyle=function isc_FormItem_setCellStyle(_1){var _2=this.cellStyle;this.cellStyle=_1;if(_2!=_1)this.updateState()},isc.A.getTitleStyle=function isc_FormItem_getTitleStyle(){if(this.$68y()&&this.printTitleStyle){return this.$15x(this.printTitleStyle,this.$160z)}
var _1=this.getErrors();if(_1==isc.emptyString)_1=null;var _2=this.$15x(this.titleStyle,"title");if(!_1){if(this.titleClassName!=null){this.$15o("titleClassName","titleStyle");_2=this.titleClassName}}else{if(this.titleErrorClassName!=null){this.$15o("titleErrorClassName","titleStyle");_2=this.titleErrorClassName}}
return _2},isc.A.getHintStyle=function isc_FormItem_getHintStyle(){if(this.hintClassName!=null){this.$15o("hintClassName","hintStyle");return this.hintClassName}
if(this.hintStyle!=null)return this.hintStyle},isc.A.getTextBoxStyle=function isc_FormItem_getTextBoxStyle(){if(this.$68y()&&this.printTextBoxStyle){return this.$15x(this.printTextBoxStyle,this.$1600)}
var _1=(this.getCanEdit()==false&&this.renderAsStatic()?this.getReadOnlyTextBoxStyle():this.textBoxStyle),_2=this.$15x(_1,this.$13q);if(this.elementClassName!=null){this.$15o("elementClassName","textBoxStyle");_2=this.elementClassName}
return _2},isc.A.getPickerIconStyle=function isc_FormItem_getPickerIconStyle(){if(this.pickerIconStyle!=null)return this.$15x(this.pickerIconStyle,this.$1601);return null},isc.A.getControlStyle=function isc_FormItem_getControlStyle(){if(this.controlStyle!=null)return this.$15x(this.controlStyle,this.$13p);return null},isc.A.getOuterTableCSS=function isc_FormItem_getOuterTableCSS(){return this.$135},isc.A.getControlTableCSS=function isc_FormItem_getControlTableCSS(){var _1=isc.SB.create();_1.append(this.$14a);var _2=this.getElementWidth()-this.$672();if(isc.isA.Number(_2))_1.append(this.$93,_2,this.$38);return _1.release(false)},isc.A.$167v=function isc_FormItem__getTextAlign(){var _1=this.textAlign;if(_1==null){if(this.applyAlignToText&&this.align!=null){return this.align}else if(this.icons!=null&&this.icons.length>0){return this.isRTL()?"right":"left"}}
return _1},isc.A.getTextBoxCellCSS=function isc_FormItem_getTextBoxCellCSS(){return this.textBoxCellCSS!=null?this.textBoxCellCSS:isc.Canvas.$42a},isc.A.getTextBoxCSS=function isc_FormItem_getTextBoxCSS(_1){var _2=isc.SB.create(),_3=this.$157f(),_4=this.$1618();if(!_3){var _5=this.$68y();if(!_5||isc.isA.Number(this.width)){var _6=this.getTextBoxWidth(_1);if(isc.isA.Number(_6)){if((isc.Browser.isOpera||isc.Browser.isMoz||isc.Browser.isSafari||isc.Browser.isIE9)&&!_4){_2.append(this.$137,_6,this.$38)}else{_2.append(this.$93,_6,this.$38)}}}
var _7=this.getTextBoxHeight(_1),_8=isc.isA.Number(_7);if(_8&&(!this.$169t()||this.$169p!=="divStyledAsDataElement")){if(!_5&&isc.Browser.isMoz&&!_4){_2.append(this.$138,_7,this.$38)}else{_2.append(this.$92,_7,this.$38);if(_5)_2.append(this.$1028,_7,this.$38)}}}
if(_4)_2.append(this.$1148);if(this.wrap){_2.append(this.$135)}else{_2.append(this.$136);if(this.$157g()&&!_3){if(isc.Browser.isMoz)_2.append(this.$1028,"-moz-block-height;");else if(_8)_2.append(this.$1028,_7,this.$38)}}
var _9=this.$167v();if(_9!=null){_2.append(this.$14c,_9,this.$39)}
if(isc.Browser.isBorderBox){_2.append(this.$1106,this.$1103,this.$39)}
return _2.release(false)},isc.A.getPickerIconCellCSS=function isc_FormItem_getPickerIconCellCSS(){if(isc.Browser.isIE)return isc.emptyString;var _1=this.getPickerIconHeight();if(isc.isA.Number(_1)&&_1<this.getInnerHeight()){return this.$14d+_1+this.$38}
return isc.emptyString},isc.A.getPickerIcon=function isc_FormItem_getPickerIcon(){var _1={showFocused:this.showFocusedPickerIcon,hspace:this.pickerIconHSpace,width:this.getPickerIconWidth(),height:this.getPickerIconHeight(),src:this.pickerIconSrc,prompt:this.pickerIconPrompt};if(this.$150==null){var _2=isc.addProperties({},this.pickerIconDefaults,this.pickerIconProperties,{pickerIcon:true,writeIntoItem:true,inline:false},_1);this.$753(_2,this.pickerIconName);this.setupPickerIconTabPosition(_2);this.$150=_2;if(this.iconIsDisabled(_2))_2.$153=true}else{isc.addProperties(this.$150,_1)}
return this.$150},isc.A.$157g=function isc_FormItem__shouldVerticallyCenterTextBox(){return false});isc.evalBoundary;isc.B.push(isc.A.$157f=function isc_FormItem__needTextBoxTable(){return(this.$157g()&&!this.$68y()&&isc.Browser.isIE&&((!isc.Browser.isStrict&&7<=isc.Browser.version&&isc.Browser.version<=8)||isc.Browser.version<=6))},isc.A.getElementHTML=function isc_FormItem_getElementHTML(_1,_2){var _3=isc.SB.create(),_4=this.$15m();var _5=this.$872(),_6,_7,_8=this.getTextBoxStyle();if(this.$1441){_8=this.$66v()}
if(_5){var _9=this.$154(),_10=this.renderAsDisabled()?null:this.accessKey;if(_4){_7=isc.Canvas.getFocusProxyString(this.getID(),false,0,0,this.getTextBoxWidth(_2),this.getTextBoxHeight(_2),this.isVisible(),!this.renderAsDisabled(),_9,_10,false)}else{var _11=isc.SB.create();if(_10!=null)_11.append(this.$14e,_10,this.$ob);_11.append(this.$14f,_9,this.$ob);_6=_11.release()}}
if(_7!=null)_3.append(_7);var _12,_13;if(this.$157f()){_12=this.$157e;_13=6;var _14=this.getTextBoxWidth(_2);if(isc.Browser.isIE6&&isc.Browser.isStrict){_14+=isc.Element.$yp(_8)}
_12[1]=_14;var _15=this.getTextBoxHeight(_2);if(isc.isA.Number(_15)){if(isc.Browser.isIE6&&isc.Browser.isStrict){_15+=isc.Element.$yo(_8)}
_12[3]=" height='"+_15+"'"}else{_12[3]=null}
_12[5]=this.wrap?null:this.$115o}else{_12=this.$14g;_13=0}
_12[_13+1]=this.$15g();_12[_13+3]=this.getID();_12[_13+6]=String.asAttValue(_8);_12[_13+8]=this.getTextBoxCSS(_2);_12[_13+10]=_6;_12[_13+12]=this.$xq(_2);_12[_13+13]=(this.showValueIconOnly?null:_1);_3.append(_12);return _3.release(false)},isc.A.getReadOnlyHTML=function isc_FormItem_getReadOnlyHTML(_1,_2){return this.getElementHTML(_1,_2)},isc.A.getPrintHTML=function isc_FormItem_getPrintHTML(_1,_2){var _3=this.getValue();var _4=this[this.isReadOnly()?"getReadOnlyHTML":"getElementHTML"](this.mapValueToDisplay(_3),_3);if(_4==null)_4=isc.emptyString;return _4},isc.A.$15m=function isc_FormItem__writeOutFocusProxy(){if(this.useFocusProxy!=null)return this.useFocusProxy;return(isc.Browser.isMoz&&isc.Browser.geckoVersion<20051111)&&this.$kk()&&!this.hasDataElement()},isc.A.$155=function isc_FormItem__getItemElementAttributeHTML(){if(!isc.FormItem.$156){isc.FormItem.$156=[" ",isc.DynamicForm.$89,"='",null,"' ",isc.DynamicForm.$9a,"='",isc.DynamicForm.$9b,"'"]}
isc.FormItem.$156[3]=this.getItemID();return isc.FormItem.$156.join(isc.emptyString)},isc.A.isValid=function isc_FormItem_isValid(){var _1=this.getErrors();if(_1==null||isc.isAn.emptyObject(_1)){return true}
return false},isc.A.getErrors=function isc_FormItem_getErrors(){if(this.form)return this.form.getFieldErrors(this)},isc.A.getError=function isc_FormItem_getError(){this.logWarn("call to deprecated method FormItem.getError(). Use FormItem.getErrors() instead.");return this.getErrors()},isc.A.getErrorMessage=function isc_FormItem_getErrorMessage(_1){var _2=this.$158i();return(isc.isAn.Array(_1)?"<ul id='"+_2+"'><li>"+_1.join("</li><li>")+"</li></ul>":"<span id='"+_2+"'>"+_1+"</span>")},isc.A.$158i=function isc_FormItem__getErrorMessageID(){return this.$qs("errorMessage")},isc.A.shouldShowErrorIcon=function isc_FormItem_shouldShowErrorIcon(){return this.showErrorIcon!=null?this.showErrorIcon:this.form.showErrorIcons},isc.A.shouldShowErrorText=function isc_FormItem_shouldShowErrorText(){return this.showErrorText!=null?this.showErrorText:this.form.showErrorText},isc.A.shouldShowErrorStyle=function isc_FormItem_shouldShowErrorStyle(){return this.showErrorStyle!=null?this.showErrorStyle:this.form.showErrorStyle},isc.A.shouldShowErrorIconPrompt=function isc_FormItem_shouldShowErrorIconPrompt(){return this.shouldShowErrorIcon&&!this.shouldShowErrorText()},isc.A.getErrorOrientation=function isc_FormItem_getErrorOrientation(){return this.errorOrientation!=null?this.errorOrientation:this.form.errorOrientation},isc.A.getErrorHTML=function isc_FormItem_getErrorHTML(_1){var _2=this.shouldShowErrorText(),_3=this.shouldShowErrorIcon();if(!_2&&!_3)return isc.emptyString;var _4=this.form,_5=(isc.Browser.isStrict?_3:_3&&_2),_6=!_5&&_3&&((this.getErrorOrientation()==isc.Canvas.LEFT)||(this.getErrorOrientation()==isc.Canvas.RIGHT)),_7=(_2&&this.form.showTitlesWithErrorMessages&&this.getTitle()!=null?this.getTitle()+": ":null),_8,_9=_2?this.getErrorMessage(_1):null;if(!_5){_8=isc.SB.concat("<DIV ",this.$99s(),(_6?"style='display:inline;'":null)," CLASS='",this.getCellStyle(),"'>",(_3?this.getErrorIconHTML(_1)+"&nbsp;":null),_7,_9,"</DIV>")}else{_8=isc.SB.concat("<TABLE ",this.$99s(),"' role='presentation' WIDTH=100% CELLSPACING=0 CELLPADDING=0><TR>","<TD WIDTH=",this.errorIconWidth,">",this.getErrorIconHTML(_1),"</TD><TD STYLE='",isc.Canvas.$42a,"' CLASS='",this.getCellStyle(),"'>&nbsp;",_7,_9,"</TD></TR></TABLE>")}
return _8},isc.A.$158j=function isc_FormItem__getInlineErrorHandleID(){return this.$qs("inlineErrorHandle")},isc.A.$99s=function isc_FormItem__getInlineErrorHandleAttributes(){if(this.$99t==null){this.$99t=isc.SB.concat("ID='",this.$158j(),"' ",isc.DynamicForm.$89,"='",this.getID(),"' ",isc.DynamicForm.$9a,"='",isc.DynamicForm.$99r,"' ")}
return this.$99t},isc.A.getInlineErrorHandle=function isc_FormItem_getInlineErrorHandle(){return this.getDocument().getElementById(this.$158j())},isc.A.getErrorIconHTML=function isc_FormItem_getErrorIconHTML(_1){this.$79u=_1;var _2=this.getErrorIconId();var _3="";if(_1!=null&&isc.Canvas.ariaEnabled()&&!isc.Canvas.useLiteAria()){if(isc.isAn.Array(_1))_1=_1.join(",");_3=" aria-label='"+String.asAttValue(String.htmlStringToString(_1))+"'"}
return this.$157(_2,this.errorIconWidth,this.errorIconHeight,"top",0,null,null,this.form.getImgURL(this.errorIconSrc),true,isc.DynamicForm.$89+"='"+this.getID()+"' "+isc.DynamicForm.$9a+"='"+this.errorIconName+"'"+_3)},isc.A.getErrorIconId=function isc_FormItem_getErrorIconId(){return this.$qs("error")},isc.A.getHint=function isc_FormItem_getHint(){if(!this.showHint||!this.hint)return null;return this.hint},isc.A.itemVisibilityChanged=function isc_FormItem_itemVisibilityChanged(_1){this.visibilityChanged()},isc.A.drawing=function isc_FormItem_drawing(_1){if(this.logIsInfoEnabled(this.$n3)){this.logInfo("About to draw this form item."+(_1?" [Item added / visibility changed].":" [ContainerWidget drawn]."),"drawing")}
this.$185l()},isc.A.drawn=function isc_FormItem_drawn(){if(this.logIsInfoEnabled(this.$n3)){this.logInfo("Form item drawn "+(this.containerWidget==this.form?"in form "+this.form.getID():"in container widget "+this.containerWidget.getID())+(this.logIsDebugEnabled("drawing")?this.getStackTrace():""),"drawing")}
if(this.$145l()){var _1=this.containerWidget;while(_1!=null){_1.$144z();_1=_1.parentElement}}
this.$if=true;if(this.$15q)this.$158=true;this.$15q=null;this.$159();this.$142r();if(isc.screenReader)this.addContentRoles()},isc.A.redrawing=function isc_FormItem_redrawing(){if(this.logIsInfoEnabled(this.$n3)){this.logInfo("About to redraw this form item.","drawing")}
if(isc.Browser.isIE&&this.hasFocus&&this.form&&!this.form.$10u){this.form.elementChanged(this)}
if(this.$16j(true)){this.$516()}
this.form.clearingElement(this);this.$13m=null;this.$185l()},isc.A.redrawn=function isc_FormItem_redrawn(){if(this.logIsInfoEnabled("drawing")){this.logInfo("Form item redrawn "+(this.containerWidget==this.form?"in form "+this.form.getID():"in container widget "+this.containerWidget.getID())+(this.logIsDebugEnabled("drawing")?this.getStackTrace():""),"drawing")}
this.$16a();this.$159();this.$142r(true);if(isc.screenReader)this.addContentRoles();if(this.$16j(true)){this.$109()}},isc.A.$142r=function isc_FormItem__showValueAfterDraw(_1){if(!this.valueHasChanged()&&(this.isSetToDefaultValue()||this._value==null))
{this.setValue()}else{this.$124t(this._value)}},isc.A.valueHasChanged=function isc_FormItem_valueHasChanged(){return this.form.valueHasChanged(this.name)},isc.A.$516=function isc_FormItem__storeFocusForRedraw(){this.$105=true;this.rememberSelection();if(this.items){for(var i=0;i<this.items.length;i++){if(this.items[i].hasFocus){return this.items[i].$516()}}}
var _2=this.$166();if(_2!=null&&_2!=this.getFocusElement()){var _3=this.getPickerIcon();if(_3!=null&&this.$16g(_3)==_2){this.$65o=_3}else if(this.icons){for(var i=0;i<this.icons.length;i++){if(this.$16g(this.icons[i])==_2){this.$65o=this.icons[i];break}}}}},isc.A.$109=function isc_FormItem__refocusAfterRedraw(){var _1=this.isDrawn()&&this.isVisible();if(_1){var _2=isc.EH.getFocusCanvas();if(_2!=null&&_2!=this.form){_1=false}else{var _3=this.form.getFocusSubItem();if(_3!==this&&_3!=this.parentItem&&(!this.items||this.items.contains(_3)))
{_1=false}}}
delete this.$105;if(_1&&isc.Browser.isIE){isc.FormItem.$137y(this)}
if(_1){this.form.$65n(this);this.containerWidget.notifyAncestorsAboutToReflow()}
var _4=false;if(this.$65o){var _5=this.getIcon(this.$65o);delete this.$65o;if(_5){if(_1){this.focusInIcon(_5)}
_4=true}}
if(_1&&!_4){this.$93l=true;this.focusInItem()}
if(_1){this.containerWidget.notifyAncestorsReflowComplete();if(isc.EH.useFocusInEvents&&isc.EH.synchronousFocusNotifications)
{this.containerWidget.notifyAncestorsAboutToReflow();this.$188o=true}}},isc.A.$159=function isc_FormItem__applyHandlersToElement(){if(this.$kk()){var _1=this.getFocusElement();if(!_1){if(this.$872()){this.logWarn("Attempting to apply event handlers to this item. Unable to get a pointer to this item's focus element");return}}else{if(this.$105m){if(this.multiple){_1.multiple=this.multiple}else{_1.multiple=false}}
if(this.accept){_1.accept=this.accept}
_1.onfocus=isc.FormItem.$12u;_1.onblur=isc.FormItem.$12w;if(this.supportsCutPasteEvents){_1.onpaste=isc.FormItem.$1852;_1.oncut=isc.FormItem.$1851}
if(this.$16b){for(var _2 in this.$16b){if(this.$16b[_2]==null)continue;_1[_2]=this.$16b[_2]}}}}
this.$16c()},isc.A.$16c=function isc_FormItem__setUpIconEventHandlers(){if(this.showPickerIcon){var _1=this.getPickerIcon();if(_1&&_1.visible){this.$16d(this.getPickerIcon())}}
if(this.showIcons&&this.icons&&this.icons.length>0){for(var i=0;i<this.icons.length;i++){var _3=this.icons[i];if(_3&&(this.$16e(_3)||_3.visible)){this.$16d(_3)}}}},isc.A.$16d=function isc_FormItem__iconDrawn(_1){if(!_1.imgOnly){var _2=this.$16g(_1);if(_2){_2.onfocus=isc.FormItem.$120
_2.onblur=isc.FormItem.$122
if(this.$92r){_2.href=this.$14h;_2.onclick=isc.FormItem.$124}}}},isc.A.clearing=function isc_FormItem_clearing(_1){if(this.logIsInfoEnabled("drawing")){this.logInfo("About to clear this form item"+(_1?" [Item removed / visibility changed].":" [ContainerWidget cleared]."),"drawing")}},isc.A.cleared=function isc_FormItem_cleared(){if(this.logIsInfoEnabled("drawing")){this.logInfo("Form item cleared "+(this.containerWidget==this.form?"from within form "+this.form.getID():"from within container widget "+this.containerWidget.getID())+(this.logIsDebugEnabled("drawing")?this.getStackTrace():""),"drawing")}
if(this.$145l()){var _1=this.containerWidget;while(_1!=null){_1.$1440();_1=_1.parentElement}}
this.form.clearingElement(this);this.$16a();this.$158=false;this.$15q=false;this.$if=false},isc.A.$16a=function isc_FormItem__clearCachedHandles(){this.$14x=null;this.$13m=null;this.$16i=null;this.$15d={}},isc.A.isDrawn=function isc_FormItem_isDrawn(){return this.$if},isc.A.$14v=function isc_FormItem__setUpIcons(){this.$156h=null;this.$156i=null;this.$156j=0;this.$156k=null;this.$156l=0;var _1=this.icons;if(_1==null)return;var _2=_1.length;for(var i=0;i<_2;++i){var _4=_1[i];this.$36c(_4)}
if(this.$156r()){var _5=this.$156h=[],_6=this.$156i=[],_7=this.$156k=[];for(var i=0;i<_2;++i){var _4=_1[i];if(_4.inline){_5.add(_4)}}
var _8=_5.length;for(var j=0;j<_8;++j){var _4=_5[j];if(_4.inlineIconAlign==null||(_4.inlineIconAlign!=="left"&&_4.inlineIconAlign!=="right"))
{_4.inlineIconAlign=(j==0?"left":"right")}
if(_4.inlineIconAlign==="left"){_6.add(_4)}else{_7.add(_4)}}}},isc.A.$180o=function isc_FormItem__removeIcons(){if(!this.icons||this.icons.length==0)return;for(var i=this.icons.length-1;i>=0;i--){isc.TabIndexManager.removeTarget(this.getTabIndexIdentifierForIcon(this.icons[i]))}
this.icons=null},isc.A.$156s=function isc_FormItem__recomputeLeftAndRightInlineIconsWidth(){this.$156j=0;this.$156l=0;if(this.$156r()&&this.$156h!=null){var _1=this.$156i,_2=_1.length;for(var i=0;i<_2;++i){var _4=_1[i];if(_4.visible){this.$156j+=_4.width+_4.hspace}}
_1=this.$156k;_2=_1.length;for(var i=0;i<_2;++i){var _4=_1[i];if(_4.visible){this.$156l+=_4.width+_4.hspace}}}},isc.A.$36c=function isc_FormItem__setUpIcon(_1){this.$753(_1);this.setupIconTabPosition(_1);if(this.iconIsDisabled(_1))_1.$153=true;if(_1.width==null)_1.width=this.iconWidth;if(_1.height==null)_1.height=this.iconHeight;if(_1.hspace==null)_1.hspace=this.iconHSpace;_1.hspace=Math.max(0,_1.hspace)},isc.A.getIconTabPosition=function isc_FormItem_getIconTabPosition(_1){var _2=this.icons.indexOf(_1);if(this.showPickerIcon)_2++;return _2},isc.A.setupIconTabPosition=function isc_FormItem_setupIconTabPosition(_1){var _2=this.getIconTabPosition(_1);if(_2==-1){this.logWarn("Icon passed to setupIconTabPosition is not present in this.icons:"+this.echo(_1),"TabIndexManager");return}
isc.TabIndexManager.addTarget(this.getTabIndexIdentifierForIcon(_1),true,this.ID,_2,{target:this,methodName:"iconAutoTabIndexUpdated"},{target:this,methodName:"iconSyntheticShiftFocus"})},isc.A.getTabIndexIdentifierForIcon=function isc_FormItem_getTabIndexIdentifierForIcon(_1){if(this.$180p==null)this.$180p={};if(this.$180p[_1.name]==null){this.$180p[_1.name]="$"+this.ID+"_"+_1.name}
return this.$180p[_1.name]},isc.A.getIconFromTabIndexIdentifier=function isc_FormItem_getIconFromTabIndexIdentifier(_1){if(this.$180p==null)return null;for(var _2 in this.$180p){if(this.$180p[_2]==_1)return _2}},isc.A.getPickerIconTabPosition=function isc_FormItem_getPickerIconTabPosition(){return 0},isc.A.setupPickerIconTabPosition=function isc_FormItem_setupPickerIconTabPosition(_1){var _2=this.getPickerIconTabPosition();isc.TabIndexManager.addTarget(this.getTabIndexIdentifierForIcon(_1),true,this.ID,_2,{target:this,methodName:"iconAutoTabIndexUpdated"},{target:this,methodName:"pickerIconSyntheticShiftFocus"})},isc.A.iconAutoTabIndexUpdated=function isc_FormItem_iconAutoTabIndexUpdated(_1){var _2=this.getIconFromTabIndexIdentifier(_1),_3=_2?this.getIcon(_2):null;if(_3){var _4=this.$16g(_3);if(_4){isc.FormItem.setElementTabIndex(_4,this.$16p(_3))}}},isc.A.getIconsHTML=function isc_FormItem_getIconsHTML(_1,_2,_3){if(!this.showIcons)return isc.emptyString;var _4=this.$16j(true),_5=_1&&this.$185k();if((this.icons==null||this.icons.length==0)&&!_5){return isc.emptyString}
var _6=isc.SB.create(),_7=false;if(_2==null){var _2=[];if(_1){var _8=this.getPickerIcon();if(_8&&_8.visible){_2=[_8]}}
_2.addList(this.icons);if(this.$169t()){var k=0;for(var i=0;i<_2.length;++i){var _11=_2[i];if(_11.inline){++k}else if(k>0){_2[i-k]=_11}}
_2.setLength(_2.length-k)}}
for(var i=0;i<_2.length;i++){var _11=_2[i];if(!_11.visible||this.$16e(_11)){continue}
if(_7==false){_7=true;_6.append(this.$156m,_3,this.$156n)}
_6.append(this.$156o);var _12=_4&&this.$54o(_11,true);_6.append(this.getIconHTML(_11,null,this.iconIsDisabled(_11),!!_12));_6.append(this.$156p)}
if(_7)_6.append(this.$156q);return _6.release(false)},isc.A.$16j=function isc_FormItem__hasRedrawFocus(_1){var _2=this.hasFocus||this.$105;if(_1&&!_2&&this.items!=null){for(var i=0;i<this.items.length;i++){if(this.items[i].hasFocus||this.items[i].$105)_2=true;break}}
return!!_2},isc.A.$753=function isc_FormItem__setupIconName(_1,_2){if(_2==null)_2=_1.name;if(_2==null&&_1.$151!=null){this.logWarn("Attempting to use '$151' property as icon name - this property has been deprecated in favor of 'name'");_2=_1.$151}
if(_2!=null){var _3=this.icons?this.icons.findAll("name",_2):[];if(_3!=null&&_3.length>0&&(_3.length>1||_3[0]!=_1))
{this.logWarn("This form item has more than one icon with the same specified name:"+_2+". Ignoring this name and using an auto-generated one instead.");_2=null}else{_1.name=_2;return _1}}
if(this.$16k==null)this.$16k=0;_1.name="_"+this.$16k++;return _1},isc.A.$16l=function isc_FormItem__getIconVAlign(_1){if(this.$150&&(_1==this.$150))return null;var _2=this.iconVAlign;if(_2==isc.Canvas.TOP){return"top"}else if(_2==isc.Canvas.BOTTOM){return(isc.Browser.isSafari?"bottom":"text-bottom")}else if(_2==isc.Canvas.CENTER){return"middle"}
return _2},isc.A.$16m=function isc_FormItem__getIconVMargin(){return 0},isc.A.$1681=function isc_FormItem__getIconTextAlign(_1){return this.$1682},isc.A.getIconPrompt=function isc_FormItem_getIconPrompt(_1){if(this.iconIsDisabled(_1))return null;return _1.prompt||this.iconPrompt},isc.A.getIconURL=function isc_FormItem_getIconURL(_1,_2,_3,_4){var _5=_1.src||this.defaultIconSrc;if(_5==isc.Canvas.$5w)return isc.Canvas.$wz;_3=this.showDisabled&&(_3||this.iconIsDisabled(_1));var _6=_3?isc.StatefulCanvas.STATE_DISABLED:_2?isc.StatefulCanvas.STATE_OVER:null,_7=(_1.showRTL&&this.isRTL()?this.$132t:null),_8=_1.customState;var _9=isc.Canvas.$1861(_5);if(_9!=null){if(_9.src!=null){_9.src=isc.Img.urlForState(_9.src,false,_4,_6,_7,_8)}
if(_9.cssClass!=null){if(_3){_9.cssClass+=isc.StatefulCanvas.STATE_DISABLED}else{if(_4)_9.cssClass+=isc.StatefulCanvas.FOCUSED;if(_2)_9.cssClass+=isc.StatefulCanvas.STATE_OVER}
if(_7!=null)_9.cssClass+=_7
if(_8!=null)_9.cssClass+=_8}
return _9}else{_5=isc.Img.urlForState(_5,false,_4,_6,_7,_8);return _5}},isc.A.getIconStyle=function isc_FormItem_getIconStyle(_1,_2,_3,_4){if(!_1||_1.baseStyle==null)return null;var _5=_1.baseStyle;if(this.showDisabled&&(_3||this.iconIsDisabled(_1))){_5+=isc.StatefulCanvas.STATE_DISABLED}else{if(_4)_5+=isc.StatefulCanvas.FOCUSED;if(_2)_5+=isc.StatefulCanvas.STATE_OVER}
if(_1.showRTL&&this.isRTL())_5+=this.$132u;if(_1.customState!=null)_5+=_1.customState;return _5},isc.A.getIconHTML=function isc_FormItem_getIconHTML(_1,_2,_3,_4){var _5=_1.inline&&this.$156r(),_6=this.getIconWidth(_1),_7=this.getIconHeight(_1),_8=(_1.hspace!=null?_1.hspace:this.iconHSpace),_9=_1.backgroundColor,_10=this.form.getID(),_11=this.getItemID(),_12=_1.name,_13=this.getIconStyle(_1,_2,_3,_4),_3=this.iconIsDisabled(_1),_14=(this.canTabToIcons==null&&this.form!=null)?this.form.canTabToIcons:this.canTabToIcons,_15=_3||_14==false?-1:this.$16p(_1);if(_5&&_1.inlineIconAlign==="left"){_8*=-1}
if(_5&&_1.text!=null){var _16=this.isRTL();if(_8<0){_8*=-1;_16=!_16}
var _17=this.$16m(_1);var _18="<div role='button' id='"+this.$16q(_12)+"'";if(_13!=null)_18+=" class='"+_13+"'";var _19=this.$1681(_1);_18+=" style='display:inline-block";if(isc.Browser.isIE&&isc.Browser.version<=7){if(_13!=null){_6=Math.max(0,_6-isc.Element.$yp(_13));_7=Math.max(0,_7-isc.Element.$yo(_13))}}else{_18+=";"+isc.Element.$1434+":border-box"}
_18+=";width:"+_6+"px;height:"+_7+"px;line-height:"+_7+"px;vertical-align:"+this.$16l(_1)+(_19?";text-align: "+_19:"")+";margin-top:"+_17+"px;margin-bottom:"+_17+"px;"+(_16?"margin-right:":"margin-left:")+_8+"px";if(_9!=null){_18+=";background-color:"+_9}
_18+=";overflow:hidden'";if(isc.Canvas.ariaEnabled()){_18+=" aria-label='"+String.asAttValue(String.htmlStringToString(_1.prompt))+"'";if(_3)_18+=" aria-disabled='true'"}
if(_3)_18+=" disabled='disabled'";_18+=" tabindex='"+_15+"'";_18+=" "+isc.DynamicForm.$89+"='"+_11+"'";_18+=" "+isc.DynamicForm.$9a+"='"+_12+"'";_18+=" handleNativeEvents='false'";_18+=">"+_1.text+"</div>";return _18}
var _20=this.getIconURL(_1,_2,_3,_4),_21=(_13==null?isc.emptyString:" class='"+_13+this.$ob);if(_1.imgOnly){var _22=((_21==null?"":_21+" ")+isc.DynamicForm.$89+"='"+_11+"' "+isc.DynamicForm.$9a+"='"+_12+"'");return this.$157(this.$16n(_12),_6,_7,this.$16l(_1),this.$16m(_1),_8,_9,_20,null,_22)}else{if(isc.FormItem.$16o==null){isc.FormItem.$950=" style='margin-left:";isc.FormItem.$951=" style='margin-right:";isc.FormItem.$16o=[(this.$92r?"<a role='button' ID='":"<span role='button' ID='"),,"'",isc.FormItem.$950,,"px;"+(isc.Browser.isMoz?"-moz-user-focus:":""),,,"' tabIndex=",," ",isc.DynamicForm.$89,"='",,"' ",isc.DynamicForm.$9a,"='",,"' handleNativeEvents=false>",,(this.$92r?"</a>":"</span>")]}
var _23=isc.FormItem.$16o;_23[1]=this.$16q(_12);var _24=this.$16r(_1);if(_24){if(this.isRTL()){_23[3]=isc.FormItem.$951}else{_23[3]=isc.FormItem.$950}
_23[4]=_8}else{_23[4]="0"}
if(isc.Browser.isMoz)_23[6]=(_15<0?"ignore;":"normal;");_23[7]=_3?"cursor:default;":"cursor:"+isc.Canvas.HAND;_23[9]=_15;_23[10]=" ";if(isc.Canvas.ariaEnabled()&&!isc.Canvas.useLiteAria()){if(_1.prompt){_23[10]=" aria-label='"+String.asAttValue(String.htmlStringToString(_1.prompt))+"' "}
if(_3)_23[10]+=" aria-disabled='true' "}
_23[13]=_11;_23[17]=_12;_23[19]=this.$157(this.$16n(_12),_6,_7,this.$16l(_1),this.$16m(_1),(!_24?_8:null),_9,_20,null,_21);return _23.join(isc.emptyString)}},isc.A.$16r=function isc_FormItem__applyIconHSpaceToLink(_1){return(!isc.Browser.isIE&&!isc.Browser.isSafari&&!_1.imgOnly&&!isc.Browser.isStrict)},isc.A.$157=function isc_FormItem__getIconImgHTML(_1,_2,_3,_4,_5,_6,_7,_8,_9,_10){var _11=this.$133c;if(_4!=null){_11[0]=this.$14i;_11[1]=_4}else{_11[0]=null;_11[1]=null}
_11[3]=_5;_11[5]=_5;if(_6!=null){var _12=this.isRTL();if(_6<0){_6*=-1;_12=!_12}
_11[7]=(_12?"margin-right:":"margin-left:")+_6+"px;"}else{_11[7]=null}
_11[8]=(_7!=null?"background-color:"+_7+";":null);if(isc.Browser.isStrict&&!isc.Browser.isTransitional&&!_9&&(!((isc.Browser.isIE&&isc.Browser.version>=8)||(isc.Browser.isChrome&&isc.Browser.version==36))||isc.isA.SpinnerItem(this)))
{_11[9]="display:block;"}else{_11[9]=null}
var _13=_11.join(isc.$ad);if(_10==null){_10=" id='"+_1+"'"}else{_10+=" id='"+_1+"'"}
var _14=isc.FormItem.$4s=isc.FormItem.$4s||{align:isc.Browser.isSafari?"absmiddle":"TEXTTOP"};_14.src=_8;_14.width=_2;_14.height=_3;_14.extraCSSText=_13;_14.extraStuff=_10;return isc.Canvas.imgHTML(_14)},isc.A.$16q=function isc_FormItem__getIconLinkId(_1){if(this.isInactiveHTML()){return this.$qs(this._$_iLink_+_1)}
if(!this.$16t)this.$16t={};var _2=this.$16t;if(!_2[_1]){_2[_1]=this.$qs(this._$_iLink_+_1,true)}
return _2[_1]},isc.A.$16n=function isc_FormItem__getIconImgId(_1){if(this.isInactiveHTML()){return this.$qs(this._$_iImg_+_1)}
if(!this.$16u)this.$16u={};var _2=this.$16u;if(!_2[_1]){_2[_1]=this.$qs(this._$_iImg_+_1,true)}
return _2[_1]},isc.A.$16g=function isc_FormItem__getIconLinkElement(_1){_1=this.getIcon(_1);if(_1==null||_1.imgOnly)return null;var _2=this.$16q(_1.name);return isc.Element.get(_2)},isc.A.$16v=function isc_FormItem__getIconImgElement(_1){var _2=this.getIcon(_1);if(_2==null){if(_1==this.errorIconName){return isc.Element.get(this.getErrorIconId())}
return null}
var _3=this.$16n(_2.name);return isc.Element.get(_3)},isc.A.$16w=function isc_FormItem__getTargetIcon(_1){if(!_1||!this.icons)return null;var _2=isc.DynamicForm._getItemInfoFromElement(_1);if(!_2||_2.item!=this)return null;return _2.icon},isc.A.isPickerIcon=function isc_FormItem_isPickerIcon(_1){if(isc.isAn.Object(_1))return _1.pickerIcon;var _2=this.getPickerIcon();return(_2&&_2.name==_1)},isc.A.$184e=function isc_FormItem__getShowIconOnFocus(_1){var _2=_1.showOnFocus;if(_2==null){_2=_1.pickerIcon?this.showPickerIconOnFocus:this.showIconsOnFocus}
return!!_2},isc.A.$184f=function isc_FormItem__getShowDisabledIconOnFocus(_1){var _2=_1.showDisabledOnFocus;if(_2==null){_2=_1.pickerIcon?this.showDisabledPickerIconOnFocus:this.showDisabledIconsOnFocus}
return _2});isc.evalBoundary;isc.B.push(isc.A.$185l=function isc_FormItem__resolveIconsVisibility(){if(this.showPickerIcon){var _1=this.getPickerIcon();_1.visible=this.$16f(_1)}
if(!this.icons)return;var _2=this.icons,_3=false;for(var i=0;i<_2.length;i++){var _5=_2[i];if(_5.name==null){this.$185m(_5)}
var _6=_5.visible,_7=this.$16f(_5);if(_6!=_7){_5.visible=_7}
if(_5.inline){if(_5.inline)_3=true}}
if(_3){this.$156s()}},isc.A.$16f=function isc_FormItem__shouldShowIcon(_1,_2){if(_1==null)return false;if(_1.pickerIcon&&!this.showPickerIcon)return false;if(!_1.pickerIcon&&this.$185n)return false;if(this.$184e(_1)){if(_2==null)_2=this.$16j(true);if(_2==false&&!this.$19g)return false;if(this.iconIsDisabled(_1)&&!this.$184f(_1)){return false}}
return this.$1858(_1)},isc.A.$1858=function isc_FormItem__evaluateIconShowIf(_1){if(this.$68y()||(this.renderAsStatic()&&_1.pickerIcon)){return false}
if(_1.showIf==null)return true;if(_1.showIf===true||_1.showIf==this.$18q)return true;if(_1.showIf===false||_1.showIf==this.$18r)return false;isc.Func.replaceWithMethod(_1,"showIf","form,item");return!!_1.showIf(this.form,this)},isc.A.$185k=function isc_FormItem__pickerIconVisible(){if(!this.showPickerIcon)return false;var _1=this.getPickerIcon();if(_1&&_1.visible)return true;return false},isc.A.$1857=function isc_FormItem__writeControlTable(){if(this.$185k())return true;if(this.alwaysShowControlBox!=null)return this.alwaysShowControlBox;if(this.showPickerIcon){var _1=this.getPickerIcon();if(_1&&this.$1858(_1))return true}
return false},isc.A.$16e=function isc_FormItem__writeIconIntoItem(_1){if(_1.writeIntoItem)return true;return false},isc.A.$16x=function isc_FormItem__mayShowIcons(){return this.showIcons&&this.icons!=null},isc.A.getTotalIconsWidth=function isc_FormItem_getTotalIconsWidth(){if(!this.$16x())return 0;var _1=0,_2=this.$16j(true),_3=this.$156r();for(var i=0;i<this.icons.length;i++){var _5=this.icons[i];if(!_5.visible||this.$16e(_5)||(_3&&_5.inline))
{continue}
_1+=(_5.width!=null?_5.width:this.iconWidth)+(_5.hspace!=null?_5.hspace:this.iconHSpace)}
return _1},isc.A.getIconsHeight=function isc_FormItem_getIconsHeight(){if(!this.$16x())return 0;var _1=0,_2=this.$16j(true);for(var i=0;i<this.icons.length;i++){var _4=this.icons[i];if(!_4.visible||this.$16e(_4)){continue}
var _5=(_4.height!=null?_4.height:this.iconHeight);_5+=this.$16m()*2;if(_5>_1)_1=_5}
return _1},isc.A.setIcons=function isc_FormItem_setIcons(_1){this.$180o();this.icons=_1;this.$14v();this.redraw()},isc.A.addIcon=function isc_FormItem_addIcon(_1){if(this.icons==null)this.icons=[];this.icons.add(_1);this.setIcons(this.icons);return _1},isc.A.getIconByProperty=function isc_FormItem_getIconByProperty(_1,_2){if(this.icons!=null)return this.icons.find(_1,_2)},isc.A.setIconEnabled=function isc_FormItem_setIconEnabled(_1){_1=this.getIcon(_1);if(!_1)return;var _2=!this.iconIsDisabled(_1);if(!!_1.$153!=_2)return;if(!_2)_1.$153=true;else delete _1.$153;if(!this.isDrawn())return;var _3=this.$16g(_1),_4=this.$16v(_1);if(_3!=null){if(!_2){isc.FormItem.setElementTabIndex(_3,-1);_3.style.cursor="default"}else{isc.FormItem.setElementTabIndex(_3,this.$16p(_1))
_3.style.cursor=""}
if(isc.Canvas.ariaEnabled())_3.setAttribute("aria-disabled",!_2);_3.disabled=!_2;if(_1.inline&&this.$156r()&&_1.text!=null){var _5=this.getIconStyle(_1,null,!_2);if(_5!=null)_3.className=_5}}
if(_4!=null){var _6=this.getIconURL(_1,null,!_2);isc.Canvas.$wg(_4,_6);var _5=this.getIconStyle(_1,null,!_2);if(_5!=null)_4.className=_5;_4.style.cursor=!_2?"default":isc.Canvas.HAND}},isc.A.setIconDisabled=function isc_FormItem_setIconDisabled(_1,_2){_1=this.getIcon(_1);if(!_1)return;var _3=this.iconIsDisabled(_1);_1.disabled=_2;if(_3!=_2){this.setIconEnabled(_1)}},isc.A.enableIcon=function isc_FormItem_enableIcon(_1){this.setIconDisabled(_1,false)},isc.A.disableIcon=function isc_FormItem_disableIcon(_1){this.setIconDisabled(_1,true)},isc.A.$181b=function isc_FormItem__setIconVisibilityRequiresRedraw(_1,_2){var _3=_2&&this.$156r()&&_1.inline;return this.redrawOnShowIcon||_3||_1.writeIntoItem||_1.redrawOnShowIcon},isc.A.showIcon=function isc_FormItem_showIcon(_1){if(isc.isA.String(_1)||isc.isA.Number(_1))_1=this.getIcon(_1);if(!isc.isAn.Object(_1))return;if(_1.name==null){this.$185m(_1)}
var _2=_1.visible;_1.showIf=this.$18q;if(!_2&&this.$16f(_1)){var _3=this.$16j(true),_4=_3&&this.$54o(_1,true);this.$185o(_1,_4)}},isc.A.$185o=function isc_FormItem__showIcon(_1,_2){_1.visible=true;if(!this.showIcons||!this.containerWidget.isDrawn()||!this.isVisible())return;if(this.$181b(_1,true)||this.containerWidget.isDirty())
{this.redraw();return}
var _3=isc.Element.get(this.getIconCellID());if(_3!=null){if(_3.childNodes.length==0){_3.innerHTML=this.getIconsHTML(!!_1.pickerIcon)}else{var _4=this.getIconHTML(_1,null,this.renderAsDisabled(),_2),_5="<td>"+_4+"</td>",_6=_3.firstChild,_7=0;for(var i=0;i<this.icons.length;i++){if(this.icons[i]==_1)break;if(this.icons[i].visible){_7++}}
if(_7==0){isc.Element.insertAdjacentHTML(_6.rows[0],"afterBegin",_5)}else{isc.Element.insertAdjacentHTML(_6.rows[0].cells[_7-1],"afterEnd",_5)}}
this.$16z();this.$16d(_1)}else{this.logInfo("showIcon(): Unable to dynamically update icon visibility - redrawing the form","formItemIcons");this.redraw()}},isc.A.hideIcon=function isc_FormItem_hideIcon(_1){if(isc.isA.String(_1)||isc.isA.Number(_1))_1=this.getIcon(_1);if(!isc.isAn.Object(_1))return;if(_1.name==null){this.$185m(_1)}
var _2=_1.visible;_1.showIf=this.$18r;if(_2&&!this.$16f(_1)){this.$185p(_1)}},isc.A.$185p=function isc_FormItem__hideIcon(_1){_1.visible=false;if(!this.showIcons||!this.containerWidget.isDrawn()||!this.isVisible())return;if(this.$181b(_1,false)||this.containerWidget.isDirty())
{this.redraw();return}
var _2=_1.imgOnly?this.$16v(_1):this.$16g(_1);if(_2==null){this.logInfo("hideIcon(): Unable to dynamically update icon visibility - redrawing the form");this.redraw();return}
var _3=_2.parentNode;if(_3.tagName!="TD"){isc.Element.clear(_2)}else{_3.parentNode.removeChild(_3)}
var _4=this.$156r()&&_1.inline;if(_4)this.$156s();this.$16z()},isc.A.setIconShowOnFocus=function isc_FormItem_setIconShowOnFocus(_1,_2){_1.showOnFocus=_2;this.$181c([_1])},isc.A.setShowIconsOnFocus=function isc_FormItem_setShowIconsOnFocus(_1){this.showIconsOnFocus=_1;this.$181c()},isc.A.setShowPickerIconOnFocus=function isc_FormItem_setShowPickerIconOnFocus(_1){this.showPickerIconOnFocus=_1;this.$181c([this.getPickerIcon()])},isc.A.$16z=function isc_FormItem__iconVisibilityChanged(){this.$160()},isc.A.$1809=function isc_FormItem__setIconVisibilityForFocus(_1,_2){var _3;_1=!!_1;if(!_1)delete this.$185n;var _4=_2?_2:[];if(!_2){if(this.showPickerIcon)_4.add(this.getPickerIcon())
if(this.icons!=null){_4.addList(this.icons)}}
if(_4.length==0){return}
var _5=[],_6=[],_7=this.showIcons,_8=this.$19g;var _9=this.logIsDebugEnabled("icons");for(var i=0;i<_4.length;i++){var _11=_4[i],_12=_11.visible,_13=this.$16f(_4[i],_1);if(_9){this.logDebug("Setting icons visibility for focus - icon "+(_11.pickerIcon?"(picker)":this.icons.indexOf(_11))+((_12==_13)?" visibility unchanged.":(_13?" showing.":" hiding.")),"icons")}
if(_13==_12){if(_12){this.$181e(_11,_1)}
continue}
var _14=this.$181b(_11,_13);if(_14){if(_9){this.logDebug("Set icon visibility requires item redraw","icons")}
this.redraw();return}
if(_13){_5.add(_11)}else{_6.add(_11)}}
for(var i=0;i<_5.length;i++){var _15=this.$54o(_5[i],_1);this.$185o(_5[i],_1&&_15)}
if(_6.length>0&&!_2){for(var i=0;i<_6.length;i++){this.$185p(_6[i])}}},isc.A.$185q=function isc_FormItem__hideIconsForKeypress(){this.$185n=true;var _1=this.icons;if(!_1||_1.length==0){return}
var _2=[];for(var i=0;i<_1.length;i++){var _4=_1[i];if(!_4.visible)continue;if(this.$181b(_4,false)||this.containerWidget.isDirty())
{this.redraw();return}
_2.add(_4)}
for(var i=0;i<_2.length;i++){this.$185p(_2[i])}},isc.A.$181c=function isc_FormItem__updateOnFocusIconVisibility(_1){var _2=this.$16j(true);if(!_2)this.$1809(false,_1)},isc.A.getIcon=function isc_FormItem_getIcon(_1){if(_1==null)return;var _2;if(this.icons){if(isc.isA.Number(_1)){return this.icons[_1]}
for(var i=0;i<this.icons.length;i++){if(this.icons[i]==_1||this.icons[i].name==_1)_2=this.icons[i]}}
if(!_2&&this.showPickerIcon){if(this.isPickerIcon(_1))_2=this.getPickerIcon()}
if(!_2){this.logInfo("FormItem unable to get pointer to icon with name:"+_1+" - Invalid name, or icons array has been inappropriately modified. To update icon[s] for some form item, use the method 'setIcons()'.")}
return _2},isc.A.$168v=function isc_FormItem__setIconState(_1,_2,_3){if(_3==null)_3=this.hasFocus&&this.$54o(_1,true);_3=_3&&!this.iconIsDisabled(_1);var _4=this.getIconStyle(_1,_2,null,_3);if(_1.inline&&this.$156r()&&_1.text!=null){var _5=this.$16g(_1);if(_5!=null&&_4!=null)_5.className=_4}else{var _6=this.$16v(_1);if(_6!=null){var _7=this.getIconURL(_1,_2,null,_3);isc.Canvas.$1865(_6,_7,null,null,_4)}}},isc.A.$165=function isc_FormItem__iconShouldShowOver(_1){if(!_1||this.iconIsDisabled(_1))return false;if(_1.showOver!=null)return _1.showOver;if(this.showOver&&(this.updatePickerIconOnOver!=false)&&this.isPickerIcon(_1))
{return true}
return this.showOverIcons},isc.A.$176d=function isc_FormItem__iconShowOverWhen(_1){if(_1.showOverWhen)return _1.showOverWhen;return"icon"},isc.A.$54o=function isc_FormItem__iconShouldShowFocused(_1,_2){if(!_1||this.iconIsDisabled(_1))return false;if(_2&&_1.showFocusedWithItem==false)return false;if(_1.showFocused!=null)return _1.showFocused;return this.showFocusedIcons},isc.A.setIconBackgroundColor=function isc_FormItem_setIconBackgroundColor(_1,_2){_1.backgroundColor=_2;var _3;if(_1.inline&&this.$156r()&&_1.text!=null){_3=this.$16g(_1)}else{_3=this.$16v(_1)}
if(_3!=null){try{_3.style.backgroundColor=_2==null?"":_2}catch(e){}}},isc.A.setIconCustomState=function isc_FormItem_setIconCustomState(_1,_2){if(_1.customState!=_2){_1.customState=_2;this.$168v(_1)}},isc.A.showPicker=function isc_FormItem_showPicker(_1,_2,_3,_4){var _5=this.picker;_3=isc.addProperties(_3||{},{callingForm:this.form,callingFormItem:this});if(isc.isA.String(_5)&&isc.isA.Canvas(window[_5])){_5=this.picker=window[_5]}
if(!_5){_5=this.picker=this.createPicker(_3);if(!isc.isA.Function(_5.dataChanged)){_5.dataChanged=isc.Class.NO_OP}
_5.observe(_5,"resized","observed.placeNear(observed.lastShowRect)");if(this.pickerDataChanged&&_5.dataChanged){this.observe(_5,"dataChanged","observer.pickerDataChanged(observed)")}}else{isc.addProperties(_5,_3)}
var _6=_5.getID();if(!_4){if(this.getPickerRect){_4=this.getPickerRect()}else if(_2){var _7=this.getIconPageRect(_2);_4=[_7[0],_7[1]]}
else _4=[isc.EH.getX(),isc.EH.getY()]}
_5.lastShowRect=_4;_5.setRect(_4);if(!_5.isDrawn()){_5.moveTo(null,-9999);_5.draw()}
this.picker.placeNear(_4);if(isc.isA.Function(_5.setData)){if(_5.$1275){delete _5.$1275}else{if(isc.isA.Function(this.getPickerData)){_5.setData(this.getPickerData(_5))}else _5.setData(this.getValue(_5))}}
var _8=_1?null:_6+".hide()";if(_1&&isc.isA.Function(_5.clickMaskClicked))
_8=_6+".clickMaskClicked()";_5.showClickMask(_8,!_1,_5);if(_1!=null&&_5.isModal==null)_5.isModal=_1;_5.show();_5.bringToFront();_5.focus();return false},isc.A.createPicker=function isc_FormItem_createPicker(_1){return this.createAutoChild("picker",_1)},isc.A.hidePicker=function isc_FormItem_hidePicker(){if(!this.picker)return;this.picker.hideClickMask();this.picker.hide()},isc.A.redraw=function isc_FormItem_redraw(_1){if(!this.isDrawn())return;if(this.hasFocus){this.$105=true}
if(!this.hasFocus&&this.items!=null){for(var i=0;i<this.items.length;i++){if(this.items[i].hasFocus)this.$105=true}}
if(this.containerWidget.redrawFormItem){this.containerWidget.redrawFormItem(this,_1)}else{this.containerWidget.markForRedraw("Form item redrawn"+(_1?": "+_1:isc.emptyString))}},isc.A.adjustOverflow=function isc_FormItem_adjustOverflow(_1){if(!this.$43c){this.$43c=[this.getID(),"  overflow changed: "]}
if(_1==null)this.$43c[2]="No Reason Specified.";else this.$43c[2]=_1;if(isc.isA.DynamicForm(this.containerWidget)){this.containerWidget.$103();this.containerWidget.adjustOverflow(this.$43c.join(isc.emptyString))}},isc.A.show=function isc_FormItem_show(_1){if(this.visible==true)return;this.visible=true;if(!_1)this.showIf=null;if(this.containerWidget.redrawFormItem)this.containerWidget.redrawFormItem(this,"showing form item");else this.containerWidget.markForRedraw("showing form item");this.itemVisibilityChanged(true)},isc.A.hide=function isc_FormItem_hide(_1){if(this.visible==false)return;this.visible=false;if(!_1)this.showIf=null;if(this.containerWidget.redrawFormItem)this.containerWidget.redrawFormItem(this,"hiding form item");else this.containerWidget.markForRedraw("hiding form item");this.itemVisibilityChanged(false)},isc.A.$145l=function isc_FormItem__needHideUsingDisplayNone(){return false},isc.A.$104=function isc_FormItem__updateHTMLForPageLoad(){if(!isc.Browser.isSafari||!this.isDrawn())return;this.$160()},isc.A.$160=function isc_FormItem__resetWidths(){if(!this.isDrawn())return;var _1=this.$1618();if(this.$1857()){var _2=this.$15f();if(_2)_2.style.width=this.getElementWidth()+"px";var _3=this.getPickerIcon(),_4=this.$16v(_3);if(_4){_4.style.height=_3.height;_4.style.width=_3.width}}
var _5=this.getValue(),_6=this.getTextBoxWidth(_5),_7=(_6==null?isc.emptyString:_6+isc.px),_8=this.getTextBoxHeight(_5),_9=(_8==null?isc.emptyString:_8+isc.px),_10=this.$15h();if(_10){if(_1)_10.style.width=_7;else _10.style.minWidth=_7;if(!this.$169t()||this.$169p!=="divStyledAsDataElement"){_10.style.height=_9}}
if(this.$15m()){var _11=this.getFocusElement()
if(_11){_11.style.width=_7;_11.style.height=_9}}},isc.A.hasElement=function isc_FormItem_hasElement(){return this.hasDataElement()},isc.A.hasDataElement=function isc_FormItem_hasDataElement(){if(this.showValueIconOnly)return false;return this.$125},isc.A.getElement=function isc_FormItem_getElement(_1){return this.getDataElement(_1)},isc.A.getFocusElement=function isc_FormItem_getFocusElement(){if(!this.isDrawn()||!this.$kk())return null;if(this.hasDataElement())return this.getDataElement();if(this.$15m()){if(!this.$16i){this.$16i=isc.Element.get(this.getID()+"__focusProxy")}
return this.$16i}
return this.$872()?this.$15h():null},isc.A.$166=function isc_FormItem__getCurrentFocusElement(){if(this.hasFocus==null&&!isc.EH.$vm==this){return null}
var _1=this.$167;if(isc.Browser.isIE&&!isc.EH.synchronousFocusNotifications&&_1!=this.getActiveElement()){this.logInfo("not returning focus element "+this.echoLeaf(_1)+" since it's not active"+isc.EH.$lb(),"nativeFocus");if(this.hasFocus){this.hasFocus=false;this.elementBlur()}
this.$167=null;return null}
return _1},isc.A.getDataElement=function isc_FormItem_getDataElement(_1){if(_1==null){var _2=this}else{var _2=this.form.getItem(_1)}
if(!_2.hasDataElement())return null;if(!this.isDrawn())return;var _3=this.$14x;if(_3==null){_3=(this.$14x=isc.Element.get(this.getDataElementId()))}
return _3},isc.A.getOuterElement=function isc_FormItem_getOuterElement(){if(!this.isDrawn())return null;var _1=this.$158;if(this.$15s(_1)){return this.getOuterTableElement()}
if(this.$1857()){return this.$15f()}
var _2=this.$15h();if(_2==null){_2=this.getHandle()}
return _2},isc.A.getHandle=function isc_FormItem_getHandle(){if(!this.isDrawn())return null;if(this.$11e())return this.getAbsDiv();if(this.containerWidget==this.form)return this.getFormCell();return isc.Element.get(this.$qs(this.$13j))},isc.A.getOuterTableElement=function isc_FormItem_getOuterTableElement(){return this.$15c(this.$133)},isc.A.$168=function isc_FormItem__overElement(_1){if(!_1)_1=isc.EH.lastEvent;var _2=_1.itemInfo;return(_2&&_2.overElement)},isc.A.$169=function isc_FormItem__overTextBox(_1){if(!_1)_1=isc.EH.lastEvent;var _2=_1.itemInfo;return(_2&&(_2.overTextBox||_2.overElement))},isc.A.$17a=function isc_FormItem__overControlTable(_1){if(!_1)_1=isc.EH.lastEvent;var _2=_1.itemInfo;return(_2&&(_2.overControlTable||this.$169(_1)||(_2.overIcon&&this.getIcon(_2.overIcon)==this.getPickerIcon())))},isc.A.getFormCellID=function isc_FormItem_getFormCellID(){return this.$qs(this.$14k)},isc.A.getFormCell=function isc_FormItem_getFormCell(){return isc.Element.get(this.getFormCellID())},isc.A.getDisplayValue=function isc_FormItem_getDisplayValue(_1){var _2;if(this.multiple){var _3=false;if(_1===_2){_1=this.getValue();_3=true}
if(!(_1==null||isc.isAn.Array(_1))){if(_3){this.logWarn("getDisplayValue - this is a multiple FormItem but the value obtained from getValue() was not null and was not an array.");_1=[_1]}else{return this.mapValueToDisplay(_1)}}
if(_1!=null){var _4=[];for(var i=0,_6=_1.length;i<_6;i++){_4[i]=this.mapValueToDisplay(_1[i])}
return _4}}
return this.mapValueToDisplay(_1!==_2?_1:this.getValue())},isc.A.mapValueToDisplay=function isc_FormItem_mapValueToDisplay(_1,_2){var _3=this.getCanEscapeHTML()&&(this.escapeHTML||this.outputAsHTML||this.asHTML);var _4;if(this.multiple&&isc.isAn.Array(_1)){var _5=_1.length;var _6=new Array(_5);for(var i=0;i<_5;++i){var _8=_1[i];_4="";if(_5>1){var _9=this.$xq(_8);if(_9!=null)_4+=_9}
if(this.autoTrimMultipleValues&&_8&&_8.trim)_8=_1[i]=_8.trim();_4+=this.mapValueToDisplay(_8,true);_6[i]=_4}
if(!_2)_4=this.$161q(_6,_1);else _4=_6.join(this.multipleValueSeparator)}else{_4=this.$17b(_1,true);var _10=this.getDisplayFieldName();if(_10!=null){var _11=this.getOptionDataSource();var _12=(_11==null?null:_11.getField(_10));if(_12!=null&&this.getCanEscapeHTML()&&_12.escapeHTML){_3=true}
if(_4==null){var _13=(_11==null||this.suppressOptionDSCacheAccess?null:_11.getCacheData());if(_13!=null){var _14=_13.find(this.getValueFieldName(),_1);if(_14!=null)_4=_14[_10]}}}
_4=this.$17c(_4!=null?_4:_1);if(this.multiple&&_4&&_4.trim)_4=_4.trim();var _15=(_1==null||_1==isc.emptyString);if(!_15&&(_4==isc.emptyString)){_4=this.getEmptyStringDisplayValue()}else{if(_3&&(_1==null||_1==isc.emptyString)&&(_4==this.$54t||_4==this.emptyDisplayValue))
{_3=false}
if(_3){_4=(_4==null?null:String(_4).asHTML())}}
_4=this.$1604(_4,_1)}
return _4},isc.A.getCanEscapeHTML=function isc_FormItem_getCanEscapeHTML(){return this.canEscapeHTML},isc.A.$161q=function isc_FormItem__finishMapMultipleValueToDisplay(_1,_2){return _1.join(this.multipleValueSeparator)},isc.A.$1604=function isc_FormItem__finishMapValueToDisplay(_1,_2){return _1},isc.A.$1605=function isc_FormItem__getDisplayValueForOldValueHover(_1,_2){return this.mapValueToDisplay(_1)},isc.A.shouldApplyStaticTypeFormat=function isc_FormItem_shouldApplyStaticTypeFormat(){if(this.applyStaticTypeFormat)return true;if(this.formatOnBlur){var _1=this.hasFocus;return!_1}
return false},isc.A.$17c=function isc_FormItem__formatDataType(_1,_2){if(_2==null){_2=this.shouldApplyStaticTypeFormat()}
var _3=this;var _4=this.getOptionDataSource(),_5=this.getDisplayFieldName();if(_4&&_5){var _6=_4.getField(_5);if(_6!=null){_3=_6}}
if(_2){if(this.formatValue!=null){var _7=this.form,_8=this.form?this.form.values:{};return this.formatValue(_1,_8,_7,this)}else{var _9=this.format||_3.format;if(_9!=null&&(isc.isA.Number(_1)||isc.isA.Date(_1))){return isc.isA.Number(_1)?isc.NumberUtil.format(_1,this.format):isc.DateUtil.format(_1,this.format)}else{var _10=_3.$62;if(_10&&_10.format){if(isc.isA.Number(_1)||isc.isA.Date(_1)){return isc.isA.Number(_1)?isc.NumberUtil.format(_1,_10.format):isc.DateUtil.format(_1,_10.format)}}}}}else if(this.formatEditorValue!=null){var _7=this.form,_8=this.form?this.form.values:{};return this.formatEditorValue(_1,_8,_7,this)}else{var _10=_3.$62;if(_10&&_10.editFormatter){var _7=this.form,_8=this.form?this.form.values:{};return _10.editFormatter(_1,this,_7,_8)}}
if(isc.isA.Date(_1)){if(this.$851(_3)){var _11=this.$30o();var _12=isc.SimpleType.inheritsFrom(this.getDisplayFieldType(),"time");return isc.Time.toTime(_1,_11,_12)}else{var _11=this.$45i();var _13=this.getDisplayFieldType(),_14=isc.SimpleType.inheritsFrom(_13,"date"),_15=isc.SimpleType.inheritsFrom(_13,"datetime");if(_14&&!_15){return _1.toShortDate(_11,false)}else{if(this.useShortDateFormat){return _15?_1.toShortDatetime(_11,true):_1.toShortDate(_11,true)}else{return _1.toNormalDate(_11)}}}}
if(_3.$62&&isc.isA.Function(_3.$62.normalDisplayFormatter)&&_2)
{_1=_3.$62.normalDisplayFormatter(_1,_3,this.form,this.form.values)}else if(_1!=null){if(this.isSimpleTypeValue(_1)){_1=isc.iscToLocaleString(_1)}}
if(_1==null)_1=this.emptyDisplayValue;return _1},isc.A.isSimpleTypeValue=function isc_FormItem_isSimpleTypeValue(_1){return((isc.DS&&isc.DS.isSimpleTypeValue(_1))||(_1!=null&&(!isc.isAn.Object(_1)||isc.isA.Date(_1))))},isc.A.getEmptyStringDisplayValue=function isc_FormItem_getEmptyStringDisplayValue(){return this.emptyDisplayValue},isc.A.$851=function isc_FormItem__formatAsTime(){var _1=null;if(this.timeFormatter==null&&this.dateFormatter!=null)_1=false;if(this.dateFormatter==null&&this.timeFormatter!=null)_1=true;if(_1==null){var _2=this.getDisplayFieldType(),_3=isc.SimpleType.inheritsFrom(_2,"time");_1=_3}
return _1},isc.A.$45i=function isc_FormItem__getDateFormatter(){if(this.dateFormatter!=null)return this.dateFormatter;if(this.format!=null)return this.format;var _1=this.getDisplayFieldType(),_2=isc.SimpleType.inheritsFrom(_1,"date"),_3=isc.SimpleType.inheritsFrom(_1,"datetime");if(_2&&this.displayFormat!=null)return this.displayFormat;if(_3&&this.form.datetimeFormatter!=null)return this.form.datetimeFormatter;return this.form.dateFormatter},isc.A.$30o=function isc_FormItem__getTimeFormatter(){if(this.timeFormatter!=null)return this.timeFormatter;if(this.displayFormat!=null&&isc.SimpleType.inheritsFrom(this.type,"time")){return this.displayFormat}
return this.form.timeFormatter},isc.A.mapDisplayToValue=function isc_FormItem_mapDisplayToValue(_1){_1=this.$79d(_1);if(this.mapEmptyDisplayValue||(_1!=this.emptyDisplayValue))_1=this.$17d(_1);return _1},isc.A.forceTimeConversion=function isc_FormItem_forceTimeConversion(){return false},isc.A.$79d=function isc_FormItem__parseDisplayValue(_1,_2){var _3=this.shouldApplyStaticTypeFormat();if(!_3){if(this.parseEditorValue!=null){_1=this.parseEditorValue(_1,this.form,this)}else if(this.$62&&this.$62.parseInput){var _4=this.form,_5=_4?_4.values:{};if(_2||!this.$85m()){_1=this.$62.parseInput(_1,this,_4,_5)}}
if(_1!=null&&isc.isA.String(_1)){var _6=this.getType();var _7=isc.SimpleType.inheritsFrom(_6,"date"),_8=isc.SimpleType.inheritsFrom(_6,"time"),_9=_7&&isc.SimpleType.inheritsFrom(_6,"datetime"),_10=(_1=="");if(_7||_8){if(this.$851()){if(_10&&this.allowEmptyValue){_1=null}else{var _11;if(!_8&&isc.isA.Date(this._value)){_11=this._value}
var _12=isc.Time.parseInput(_1,!this.forceTimeConversion(),false,!_8,_11);if(isc.isA.Date(_12))_1=_12}}else{var _13=this.inputFormat;if(_13==null){_13=isc.DateUtil.mapDisplayFormatToInputFormat(this.$45i())}
var _14=_7&&!_9;var _15=isc.DateUtil.parseInput(_1,_13,this.centuryThreshold,false,!_14);if(isc.isA.Date(_15))_1=_15}}}}
return _1},isc.A.getType=function isc_FormItem_getType(){var _1=this.form?this.form.getFieldType(this):null;return _1||this.defaultType},isc.A.getDisplayFieldType=function isc_FormItem_getDisplayFieldType(){var _1=this.getOptionDataSource(),_2=this.getDisplayFieldName();if(_1&&_2){var _3=_1.getField(_2);if(_3!=null&&_3.type!=null){return _3.type}}
return this.getType()},isc.A.setToZeroTime=function isc_FormItem_setToZeroTime(_1){isc.DateUtil.setToZeroTime(_1)},isc.A.$17b=function isc_FormItem__mapKey(_1,_2){var _3=_2?null:_1;var _4=this.getAllValueMappings();if(!_4)return _3;if(isc.isA.String(_4))_4=this.getGlobalReference(_4);if(isc.isAn.Array(_4))return _3;return isc.getValueForKey(_1,_4,_3)},isc.A.$17d=function isc_FormItem__unmapKey(_1,_2){var _3=_2?null:_1;var _4=this.getAllValueMappings();if(!_4)return _2?null:_1;if(isc.isA.String(_4))_4=this.getGlobalReference(_4);if(isc.isAn.Array(_4))return _1;var _5=isc.getKeyForValue(_1,_4,_3);if(_5!=null&&_5==_1&&_5===this.emptyDisplayValue){_5="";var _6=this.getValueFieldName();if(_6!=null){var _7=this.getOptionDataSource();var _8=(_7==null||this.suppressOptionDSCacheAccess?null:_7.getCacheData());if(_8!=null){var _9=_8.find(this.getDisplayFieldName(),_1);if(_9!=null){_5=_9[_6]}}}}
return _5},isc.A.setValueMap=function isc_FormItem_setValueMap(_1){this.valueMap=_1;this.updateValueMap()},isc.A.setOptionDataSource=function isc_FormItem_setOptionDataSource(_1){if(isc.isA.String(_1))_1=isc.DataSource.get(_1);if(this.getOptionDataSource()==_1){return}
this.ignoreOptionDataSource();this.optionDataSource=_1;this.invalidateDisplayValueCache()});isc.evalBoundary;isc.B.push(isc.A.setValueIcons=function isc_FormItem_setValueIcons(_1){this.valueIcons=_1;if(this.isDrawn())this.redraw()},isc.A.setOptions=function isc_FormItem_setOptions(_1){return this.setValueMap(_1)},isc.A.updateValueMap=function isc_FormItem_updateValueMap(_1){if(_1!=false&&!this.$1563){this.$952(this.getDisplayValue(),this.getValue())}
if(this.hasElement())this.setElementValueMap(this.getValueMap())},isc.A.setElementValueMap=function isc_FormItem_setElementValueMap(_1){},isc.A.getAllValueMappings=function isc_FormItem_getAllValueMappings(){var _1=this.getValueMap();var _2=!isc.isAn.Array(this.specialValues)?this.specialValues:null;if(_2!=null){if(_1==null)_1=_2;else{if(isc.isAn.Array(_1)){var _3=_1;_1={};for(var i=0;i<_3.length;i++){_1[_3[i]]=_3[i]}}
_1=isc.addProperties({},_1);var _5;for(var _6 in _2){if(_1[_6]===_5)_1[_6]=_2[_6]}}}
return _1},isc.A.getValueMap=function isc_FormItem_getValueMap(){var _1=this.valueMap;if(isc.isA.String(_1)){_1=this.getGlobalReference(_1)}
var _2=this.$43d;if(_2!=null){if(_1==null)_1=_2;else{if(isc.isAn.Array(_1)){var _3=_1;_1={};for(var i=0;i<_3.length;i++){_1[_3[i]]=_3[i]}}
_1=isc.addProperties({},_1);var _5;for(var _6 in _2){if(_1[_6]===_5)_1[_6]=_2[_6]}}}
return _1},isc.A.getValueFieldName=function isc_FormItem_getValueFieldName(){if(this.valueField)return this.valueField;if(this.form&&this.form.dataSource&&this.foreignKey)
return isc.DS.getForeignFieldName(this,this.form.dataSource);var _1=this.getFieldName();return _1||"name"},isc.A.getDisplayFieldName=function isc_FormItem_getDisplayFieldName(){var _1=this.getOptionDataSource(),_2=this.form.getDataSource();if(_1){if(this.foreignDisplayField){return this.foreignDisplayField}else if(_2==null&&this.displayField){return this.displayField}}else if(this.displayField){return this.displayField}
if(this.displayField){var _3=_2.getField(this.getFieldName()),_4=_3?_3.displayField:null;if(this.displayField!=_4||_1.getField(this.displayField)!=null)
{return this.displayField}else{this.logInfo("Ignoring specified displayField:"+this.displayField+" - this doesn't  match any fields present in our optionDataSource:"+_1)}}
var _5=this.getValueFieldName();if(_1&&_1!=isc.DataSource.getDataSource(this.form.dataSource)&&(this.displayField!=null||(_1.getField(_5)&&_1.getField(_5).hidden==true))){return _1.getTitleField()}},isc.A.$426=function isc_FormItem__displayFieldValueFromFormValues(){if(this.displayField!=null){var _1=this.form.getValues();var _2,_3=this.getFieldName();if(_1[_3]!==_2){var _4=this.getValueFieldName(),_5=this.displayField,_6=this.getDisplayFieldName(),_7;if(_4!=_3||(_5!=null&&_6!=_5))
{_7={};_7[_4]=_1[_3];_7[_6]=_1[_5]}else{_7=isc.addProperties({},_1)}
this.$848([_7]);this.updateDisplayValueMap(true)}}},isc.A.getOptions=function isc_FormItem_getOptions(){return this.getValueMap()},isc.A.getOptionDataSource=function isc_FormItem_getOptionDataSource(){var _1=this.optionDataSource;if(_1==null){var _2=this.form?this.form.getDefaultOptionDataSource(this):null;if(this.foreignKey)_1=isc.DS.getForeignDSName(this,_2);if(_1==null&&_2)_1=_2}
if(isc.isA.String(_1))_1=isc.DataSource.getDataSource(_1);return _1},isc.A.getValueMapTitle=function isc_FormItem_getValueMapTitle(_1){var _2=this.getAllValueMappings();if(isc.isAn.Array(_2))return(_2.contains(_1)?_1:"");return _2[_1]},isc.A.setOptionCriteria=function isc_FormItem_setOptionCriteria(_1){this.optionCriteria=_1;this.$172t=null},isc.A.getOptionCriteriaCopy=function isc_FormItem_getOptionCriteriaCopy(){if(this.optionCriteria==null)return null;if(this.$172t){return this.$172t}
var _1=isc.addProperties({},this.optionCriteria);if(!isc.DS.isAdvancedCriteria(_1)){if(_1.operator&&_1.criteria){_1._constructor="AdvancedCriteria";this.$172t=_1}else if(_1.fieldName&&_1.operator){_1={_constructor:"AdvancedCriteria",operator:"and",criteria:isc.isAn.Array(_1)?_1:[_1]};this.$172t=_1}else{this.$172t=this.optionCriteria}}
return _1},isc.A.saveValue=function isc_FormItem_saveValue(_1,_2){this.$172m=this.$172l;var _3;this._value=_1;this.$14u=_2;if(this.isDrawn()){if(this.$11d())this.$17e(_1)}
var _4=this.form;if(_4==null)return;if(_1==_3&&this.$17f){_4.clearItemValue(this)}else{_4.saveItemValue(this,_1)}
if(this.$161p())this.updatePendingStatus(_1)},isc.A.$161p=function isc_FormItem__getShowPending(){var _1=this.parentItem;if(_1!=null)return _1.$161p();var _2=this.form;if(this.showPending==null&&_2!=null)return!!_2.showPending;else return!!this.showPending},isc.A.$161r=function isc_FormItem__getShowDeletions(){var _1=this.parentItem;if(_1!=null)return _1.$161r();var _2,_3;if((_2=this.showDeletions)!=null){return!!_2}else if((_3=this.form)!=null&&(_2=_3.showDeletions)!=null)
{return!!_2}else{return this.$161p()}},isc.A.setFixedPendingStatus=function isc_FormItem_setFixedPendingStatus(_1){this.fixedPendingStatus=_1;if(this.$161p()){this.$1606=true;this.updatePendingStatus(this._value);this.$1606=false}},isc.A.updatePendingStatus=function isc_FormItem_updatePendingStatus(_1){var _2=this.form;var _3=!!this.pendingStatus,_4=this.$160w(),_5=this.compareValues(_4,_1),_6=(this.fixedPendingStatus!=null?!!this.fixedPendingStatus.valueOf():!_5);var _7=this.form&&this.form.valuesManager;if(_7&&(_7.$180b||_7.$181w)){_6=false}
this.pendingStatus=_6;if(_3!=_6){if(!_6)isc.Hover.clear();this.$1607(_6)}},isc.A.$1607=function isc_FormItem__pendingStatusChanged(_1){var _2=(this.pendingStatusChanged!=null&&this.pendingStatusChanged(this.form,this,_1,this._value,this.$160w())==false);this.$1602=_2;if(!_2){this.$1608(_1)}},isc.A.$1608=function isc_FormItem__defaultPendingStatusChangedBehavior(_1){this.updateState()},isc.A.$17e=function isc_FormItem__setHiddenDataElementValue(_1){var _2=this.$15b();if(_2)_2.value=_1},isc.A.setValue=function isc_FormItem_setValue(_1,_2,_3,_4){this.$17g=true;var _5=!_4&&(this.maintainSelectionOnTransform&&this.hasFocus&&(this.$17h()!=this.$14l));if(_5&&!isc.EH.synchronousFocusNotifications&&isc.Browser.isIE){if(!this.$820()){_5=false}}
if(_5)this.rememberSelection(_3);if(this.$17i!=null){isc.Timer.clearTimeout(this.$17i);this.$17i=null}
var _6;if(_1==null&&!_2){var _7=this.getDefaultValue();if(_7!=null){_6=true;_1=_7}}
if(this.multiple&&_1!=null&&!isc.isAn.Array(_1)){_1=[_1]}
if(this.enforceLength&&this.length!=null&&_1!=null){var _8=isc.isA.Number(_1);if(_8){if(this.$184w){_1=this.$184w(_1)}else{_1=""+_1}}
if(isc.isA.String(_1)&&_1.length>this.length){_1=_1.substring(0,this.length)}
if(_8)_1=this.mapDisplayToValue(_1,true)}
this.saveValue(_1,_6);this.$124t(_1,_5);return _1},isc.A.$124t=function isc_FormItem__showValue(_1,_2){if(this.destroyed)return;if(_1!=null){if(this.multiple){var _3=[];for(var i=0,_5=_1.length;i<_5;++i){var _6=_1[i];if(_6!=null&&this.shouldFetchMissingValue(_6)){_3.push(_6)}}
this.$78w();this.$43f(_3)}else if(this.shouldFetchMissingValue(_1)){this.$78w();this.$43f(_1)}}else{if(this.$78y==null||!this.compareValues(this.$78y,this._value))
{this.$846()}}
var _7=this.getDisplayValue(_1);this.$952(_7,_1);if(_2){this.resetToLastSelection(true)}},isc.A.shouldFetchMissingValue=function isc_FormItem_shouldFetchMissingValue(_1){var _2=this.$128s(_1,this.getValueFieldName());if(_2!=null){return _2}
if(!(this.isReadOnly())&&this.$1709)return false;if(this.getDisplayFieldName()==null)return false;var _3=(this.$17b(_1,true)!=null);return!_3},isc.A.shouldFetchMissingDisplayValue=function isc_FormItem_shouldFetchMissingDisplayValue(_1){var _2=this.getDisplayFieldName();if(_2==null)return false;var _3=this.$128s(_1,_2);if(_3!=null)return _3;var _4=(this.$17d(_1,true)!=null);return!_4},isc.A.$128s=function isc_FormItem__shouldFetchMissingValue(_1,_2){if(this.fetchMissingValues==false)return false;if(this.getOptionDataSource()==null)return false;var _3=this.getValueFieldName(),_4=(_3==_2);if(this.$145o&&_4&&this.$145o[_1]!=null)
{return false}
if(!_4){var _5=this.getDisplayFieldName();if(this.$145p&&_2==_5&&this.$145p[_1]!=null)
{return false}}
var _6=false;if(this.$847!=null&&(this.$43e||this.$847.find(_2,_1)!=null))
{_6=true}
if(_6)return false;if(this.alwaysFetchMissingValues)return true;return null},isc.A.setDefaultValue=function isc_FormItem_setDefaultValue(_1){var _2=this.defaultValue,_3;this.defaultValue=_1;if(this.isSetToDefaultValue()||(this._value==null&&_2===_3))
this.clearValue()},isc.A.$43f=function isc_FormItem__checkForDisplayFieldValue(_1){if(!this.$128t)this.$128t={};return this.$128u(_1,this.getValueFieldName(),this.$128t)},isc.A.$128v=function isc_FormItem__checkForValueFieldValue(_1){if(!this.$128w)this.$128w={};return this.$128u(_1,this.getDisplayFieldName(),this.$128w,true)},isc.A.$128u=function isc_FormItem__checkForTargetFieldValue(_1,_2,_3,_4){var _5=false;if(isc.isAn.Array(_1)){for(var i=0,_7=_1.length;i<_7;++i){var _8=_1[i];if(!_3[_8]){_5=true;_3[_8]=++this.$172l}}}else if(!_3[_1]){_5=true;_3[_1]=++this.$172l}
if(_5){if(!_4)this.$127k();var _9=this.getOptionCriteriaCopy();if(!this.filterLocally){var _10={};if(isc.isAn.Array(_1)&&_1.length==1){_10[_2]=_1[0]}else{_10[_2]=_1}
_9=isc.DataSource.combineCriteria(_9,_10)}
var _11=isc.addProperties({},this.optionFilterContext,{showPrompt:false,internalClientContext:{newValue:_1,filterLocally:this.filterLocally,targetField:_2,fetchingMissingValues:_3},componentId:this.containerWidget.getID(),componentContext:this.getFieldName(),textMatchStyle:"exact"});var _12;if(this.optionOperationId!==_12){_11.operationId=this.optionOperationId}
this.getOptionDataSource().fetchData(_9,{target:this,methodName:"fetchMissingValueReply"},_11)}
return!_5},isc.A.fetchMissingValueReply=function isc_FormItem_fetchMissingValueReply(_1,_2,_3){var _4=_1.internalClientContext,_5=_4.newValue,_6=_4.targetField,_7=_4.fetchingMissingValues,_8=_4.filterLocally,_9=(this.$128t===_7),_10;if(!_9){var _11=_1.internalClientContext.newValue;_10=false;if(this.$128w&&this.$128w[_11])
{_10=true;var _12=this.$128w[_11]
if(_12<=this.$172m){_10=false}else{for(var _13 in this.$128w){if(this.$128w[_13]>_12){_10=false;break}}}}else{}}
if(!isc.isAn.Array(_5))_5=[_5];var _14;if(!_8){_14=[]}
var _15=0,_16=[];for(var i=0,_18=_5.length;i<_18;++i){if(!_7||!_5||!_5[i]){this.logWarn("fetchMissingValueReply returned unexpected data: "+this.echo(_4))}
delete _7[_5[i]];var _19=_2?_2.find(_6,_5[i]):null;if(!_19){if(_9){this.logInfo("Unable to retrieve display value for data value:"+_5[i]+" from dataSource "+this.getOptionDataSource())}
_16.add(_5[i]);++_15}else if(!_8){_14.push(_19)}}
var _20=_2?_2.getLength():0,_21=_5.getLength();if(!_8&&(_20>(_21-_15))){if(_9){this.logWarn("FetchMissingValues - filterLocally is false yet optionDataSource fetch included records that do not match our current data value. Ignoring these values.","fetchMissingValues")}
this.logDebug("Data returned:"+this.echoAll(_2),"fetchMissingValues");_2=_14}
if(_9){this.$128x(_1,_2,_3,_15,_16)}else if(this.$128w===_7){this.$128y(_1,_2,_3,_15,_16,_10)}},isc.A.$128x=function isc_FormItem__fetchMissingDisplayFieldValueReply(_1,_2,_3,_4,_5,_6){if(_5!=null&&_5.length>0){this.$145q(_5,_6)}
var _7=this.$848(_2);var _8=_7&&this.$849();if(_1.internalClientContext.filterLocally)this.$43e=true;this.updateDisplayValueMap(_8,_5);if(this.$1441){if(!_6){this.$127l(_4)}else{if(!this.$127i(true)){this.logWarn("Possible confusion: Callback fired from 'fetchMissingValueFieldValue()' [attempt to map user-entered display value to a data value]. The loadingDisplayValue is currently showing. This should only be shown when the fetching a display value from a data value. This can occur with overlapping fetches but we do not appear to have an outstanding fetch for display field values.","loadingDisplayValue")}}}
if(_7)this.form.itemDisplayValueModified(this,this._value);if(this.$179r){delete this.$179r;this.selectValue()}},isc.A.$145q=function isc_FormItem__cacheNoMatchDisplayValues(_1,_2){if(this.$145p==null){this.$145p={}}
if(this.$145o==null){this.$145o={}}
var _3=_2?this.$145p:this.$145o;if(_1!=null&&_1.length>0){for(var i=0;i<_1.length;i++){_3[_1[i]]=true}}},isc.A.$127m=function isc_FormItem__clearPendingMissingValue(_1){if(this.$128w)delete this.$128w[_1]},isc.A.$127i=function isc_FormItem__fetchMissingValueInProgress(_1,_2){var _3=_1?this.$128t:this.$128w;if(_2!=null){return _3!=null&&(_3[_2]>0)}
return(_3!=null&&!isc.isAn.emptyObject(_3))},isc.A.$127k=function isc_FormItem__setLoadingDisplayValue(){this.logDebug("showing loadingDisplayValue. Value specified as: "+this.loadingDisplayValue,"loadingDisplayValue");if(this.loadingDisplayValue!=null){if(!this.isReadOnly()){this.$148w=this.canEdit;this.setCanEdit(false);this.$127n=true}
if(this.$1441){this.logInfo("$127k called, but the value is already showing. This may be valid if we have a second fetch kicked off before the first completes (due to 2 calls to 'setValue()', say)","loadingDisplayValue")}
this.$1441=true;this.$66s();this.setElementValue(this.loadingDisplayValue)}},isc.A.$127l=function isc_FormItem__clearLoadingDisplayValue(_1){this.logDebug("clearLoadingDisplayValue called","loadingDisplayValue");var _2=this.$1441
if(!_2){this.logInfo("$1442 value called without a prior call to show the loading display value","loadingDisplayValue")}
var _3=this.getValue();var _4;if(this.multiple&&isc.isAn.Array(_3)){for(var i=0;i<_3.length;i++){_4=_4||this.$127i(true,_3[i])}}else{_4=this.$127i(true,_3)}
if(!_4){this.logDebug("clearLoadingDisplayValue() - no outstanding fetch for display value, so clearing loading marker","loadingDisplayValue");this.$1441=false;if(this.$127n){delete this.$127n;this.setCanEdit(this.$148w)}
if(_2){var _6=this.getDisplayValue();this.$952(_6,this._value)}}else{this.logInfo("clearLoadingDisplayValue(): Still has outstanding fetch for display value- leaving loading marker visible","loadingDisplayValue")}},isc.A.$128y=function isc_FormItem__fetchMissingValueFieldValueReply(_1,_2,_3,_4,_5,_6){this.$128x(_1,_2,_3,_4,_5,true);if(_6){var _7=_1.internalClientContext.newValue;this.$10y(_7);this.$846()}},isc.A.$953=function isc_FormItem__addRecordToDisplayFieldCache(_1){this.logInfo("Adding Record to displayFieldCache:"+this.echo(_1),"displayFieldCache");var _2=_1==null?null:[_1];return this.$848(_2)},isc.A.$848=function isc_FormItem__addDataToDisplayFieldCache(_1){this.logInfo("Adding Data to displayFieldCache"+(this.logIsDebugEnabled("displayFieldCache")?this.echoAll(_1):""),"displayFieldCache");return this.$954(_1,true,true,false,true)},isc.A.$955=function isc_FormItem__removeValueFromDisplayFieldCache(_1){var _2=this.$847;if(_2){var _3=this.getValueFieldName(),_4=_2.find(_3,_1);if(_4!=null){this.logInfo("Removing record from displayFieldCache"+this.echo(_4),"displayFieldCache");return this.$954([_4],false,false,true,true)}}
return false},isc.A.$954=function isc_FormItem__modifyDataInDisplayFieldCache(_1,_2,_3,_4,_5){var _6=false;if(_1==null)return _6;if(this.$847==null){this.$847=[]}
var _7=this.$847,_8=this.getValueFieldName(),_9=this.getDisplayFieldName(),_10=(_9!=_8),_11=_2&&!(_3||_4);if(_5){var _12=this.getValue();if(!isc.isAn.Array(_12))_12=[_12]}
for(var i=0;i<_1.length;i++){var _14=_1[i],_15=_14[_8],_16=_14[_9],j=_7.findIndex(_8,_15),_18=false;if(this.$145o&&this.$145o[_15])
{delete this.$145o[_15]}
if(_10&&this.$145p&&this.$145p[_16])
{delete this.$145p[_16]}
if(j==-1){if(_2){_7.push(_14);_18=true}}else if(_3||_4){var _19=_7[j],_20=(_14[_9]!=_19[_9]);if(_3&&_20){_7[j]=_14;_18=true}else if(_4){_7.splice(j,1);_18=true}}
if(_5&&_18&&!_6){_6=(_12.indexOf(_15)!=-1)}}
var _21=this.getOptionDataSource();if(_21&&!this.isObserving(_21,"dataChanged")){this.observe(_21,"dataChanged","observer.dataSourceDataChanged(observed,dsRequest,dsResponse)")}
if(_5)return _6},isc.A.$849=function isc_FormItem__refreshForDisplayValueChange(){return true},isc.A.updateDisplayValueMap=function isc_FormItem_updateDisplayValueMap(_1){this.$846();var _2=this.$847,_3=this.getDisplayFieldName(),_4=this.getValueFieldName();var _5=this.$43d={};if(_2!=null){var _6;for(var i=0;i<_2.length;i++){var _8=_2[i];var _9=_8[_4],_10=_8[_3];if(_9==null||_5[_9]!==_6){if(_5[_9]!=_10){this.logWarn("Deriving valueMap for '"+_4+"' from dataSource based on displayField '"+_3+"'. This dataSource contains more than one record with "+_4+" set to "+_9+" with differing "+_3+" values. Derived valueMap is therefore unpredictable.","fetchMissingValues")}
continue}
_5[_8[_4]]=_3!=null?_10:_9}}
this.updateValueMap(_1)},isc.A.invalidateDisplayValueCache=function isc_FormItem_invalidateDisplayValueCache(_1){this.$43d=null;this.$847=null;this.$145p=null;this.$145o=null;this.$78w();this.$43e=false;this.ignoreOptionDataSource();if(_1)return;if(this.form.$425(this)){this.$426()}else if(this._value!=null&&this.shouldFetchMissingValue(this._value)){this.$78w();this.$43f(this._value)}
this.updateValueMap()},isc.A.ignoreOptionDataSource=function isc_FormItem_ignoreOptionDataSource(){var _1=this.getOptionDataSource();if(_1!=null&&this.isObserving(_1,"dataChanged")){this.ignore(_1,"dataChanged")}},isc.A.dataSourceDataChanged=function isc_FormItem_dataSourceDataChanged(_1,_2,_3){var _4=this.logIsDebugEnabled("fetchMissingValues");if(_4){this.logDebug("dataSourceDataChanged is firing for request:"+this.echo(_2),"fetchMissingValues")}
var _5=this.$847;if(_5==null)return;if(_3.invalidateCache){if(_4){this.logDebug("Request had invalidateCache set, dropping cached display values","fetchMissingValues")}
this.invalidateDisplayValueCache()}else{var _6=this.getDisplayFieldName(),_7=this.getValueFieldName();var _8=_1.getUpdatedData(_2,_3,true),_9=_2.operationType=="add",_10=_2.operationType=="update",_11=_2.operationType=="remove";if(_4){this.logDebug("Operation type:"+_2.operationType+", updateData:"+this.echoAll(_8),"fetchMissingValues")}
if(_8==null||(!_9&&!_11&&!_10))return;if(!isc.isAn.Array(_8)){_8=[_8]}
var _12=false;var _13=(_7!=_6);if(_9){_5.addList(_8)}
var _14=_1.getPrimaryKeyFields();var _15=this._value;if(this.multiple&&!(_15==null||isc.isAn.Array(_15))){this.logWarn("dataSourceDataChanged - this is a multiple FormItem but this._value is not null and is not an array.");_15=[_15]}
for(var i=0;i<_8.length;i++){var _17=_8[i];if(!_11){if(this.$145o&&this.$145o[_17[_7]])
{delete this.$145o[_17[_7]]}
if(_13&&this.$145p&&this.$145p[_17[_6]])
{delete this.$145p[_17[_6]]}}else{if(this.$145o==null){this.$145o={}}
this.$145o[_17[_7]]=true;if(_13){if(this.$145p==null){this.$145p={}}
this.$145p[_17[_6]]=true}}
var _18;if(_9){_18=_17[_7]}else{var _19=isc.applyMask(_17,_14);var _20=_1.findByKeys(_19,_5);if(_20==-1){if(_11)continue;_5.add(_17)}else{if(_11){_18=_5[_20][_7];_5.removeAt(_20)}else{_5[_20]=_17;_18=_5[_20][_7]}}}
if(_18!=null){if(this.multiple){if(_15!=null){var _21=_15.getLength();for(var k=0;!_12&&k<_21;++k){_12=_18==_15[k]}}}else if(_18==this._value){_12=true}}}
this.updateDisplayValueMap(_12&&this.$849());if(_12)this.form.itemDisplayValueModified(this,this._value)}},isc.A.getSelectedRecord=function isc_FormItem_getSelectedRecord(){if(this.$78y!=null){if(!this.compareValues(this.$78y,this._value)){this.logInfo("getSelectedRecord - cached record doesn't match new value - dropping","fetchMissingValues");this.$78w()}}
return this.$751},isc.A.$846=function isc_FormItem__updateSelectedRecord(){if(this._value==null||this.$847==null){this.$78w()}else{var _1=this.getValueFieldName();this.$78y=this._value;if(this.multiple){var _2=this._value;if(!(_2==null||isc.isAn.Array(_2))){this.logWarn("$846 - this is a multiple FormItem but this._value is not null and is not an array");_2=[_2]}
if(_2==null){this.$751=null}else{this.$751=[];for(var i=0,_4=_2.length;i<_4;++i){this.$751.push(this.$847.find(_1,_2[i]))}}}else{this.$751=this.$847.find(_1,this._value)}}},isc.A.$78w=function isc_FormItem__clearSelectedRecord(){delete this.$751;delete this.$78y},isc.A.clearValue=function isc_FormItem_clearValue(){this.$17f=true;this.setValue();delete this.$17f},isc.A.$952=function isc_FormItem__setElementValue(_1,_2){if(this.multiple&&_1!=null&&isc.isAn.Array(_1)){_1=this.$161q(_1,_2)}
return this.setElementValue(_1,_2)},isc.A.setElementValue=function isc_FormItem_setElementValue(_1,_2){if(!this.isDrawn())return;var _3;if(_2===_3){_2=this._value}
_1=this.$170f(_1,_2);if(this.hasDataElement()){var _4=this.getDataElement();if(_4!=null){this.$17j(_2);if(_4.value!==_1){var _5=_4.scrollLeft,_6=_4.scrollTop;var _7=isc.Browser.isIE&&isc.isA.TextItem(this);_4.value=(_7&&_1==null)?isc.emptyString:_1;if(isc.Browser.isIE&&isc.Browser.version>=10){_4.scrollLeft=_5;_4.scrollTop=_6}}
if(_1==null||isc.isAn.emptyString(_1)){this.$1563=false}
return _1}}else if(this.$11d()){this.$17e(_2)}
var _8=this.$15h();if(_8!=null){if(this.showValueIconOnly)_1=isc.emptyString;var _9=this.$xq(_2);if(_9!=null)
_1=_9+(_1!=null?_1:isc.emptyString);if(isc.Browser.isIE){if(_1&&_1.startsWith("<nobr>"))
_1=_1.substring(6);if(_1&&_1.endsWith("</nobr>"))
_1=_1.substring(0,_1.length-7);try{_8.innerHTML=_1}catch(e){var _10=document.createElement("span");_10.innerHTML=_1;_8.innerHTML="";_8.appendChild(_10)}}else{_8.innerHTML=_1}
if(!this.$1618()||this.height==null||this.width==null){this.adjustOverflow("textBox value changed")}}},isc.A.$170f=function isc_FormItem__convertDisplayToLoadingValue(_1,_2){if(!this.$127i(true)){return _1}
var _3;if(_2===_3){_2=this.mapDisplayToValue(_1)}
if(this.loadingDisplayValue!=null){var _4=false;if(this.multiple&&isc.isAn.Array(_2)){for(var i=0;i<_2.length;i++){if(this.$127i(true,_2[i])){_4=true;break}}}else{if(this.$127i(true,_2)){_4=true}}
if(_4){if(!this.$1441||_1!=this.loadingDisplayValue){this.logInfo("setElementValue() called while attempting to fetch missing display-value / record from DataSource. "+(_1!=this.loadingDisplayValue?" Specified element value is :"+_1+" (doesn't match this.loadingDisplayValue).":"")+(!this.$1441?"  setLoadingDisplayValue() hasn't yet been called.":"")+" Will set value to loadingDisplayValue and mark showingLoadingDisplayValue as true","loadingDisplayValue")}
this.$1441=true;_1=this.loadingDisplayValue}}
return _1});isc.evalBoundary;isc.B.push(isc.A.$17j=function isc_FormItem__updateValueIcon(_1){if(this.suppressValueIcon||!this.isDrawn())return;var _2=this.$144(_1),_3=this.$15v();if(_2!=null){if(_3!=null){var _4=isc.Canvas.$1861(_2);if(this.imageURLSuffix!=null&&_2!=isc.Canvas.$5w){if(_4){if(_4.src&&_4.src!=isc.Canvas.$5w){_4.src+=this.imageURLSuffix}}else{_2+=this.imageURLSuffix}}
var _5=this.imageURLPrefix||this.baseURL||this.imgDir;isc.Canvas.$1865(_3,_2,_5,this.$157d(_1))}else{var _6=false;if(this.hasDataElement()){var _7=this.getDataElement();if(_7!=null){isc.Element.insertAdjacentHTML(_7,"beforeBegin",this.$xq(_1));var _8=this.getTextBoxWidth(_1);_7.style.width=(isc.isA.Number(_8)?_8+isc.px:_8);_6=true}}else{var _9=this.$15h();if(_9!=null){isc.Element.insertAdjacentHTML(_9,"afterBegin",this.$xq(_1));_6=true}}
if(!_6)this.redraw()}}else if(_3!=null&&!(isc.isAn.Array(_1)&&_1.length>1)){isc.Element.clear(_3);if(this.hasDataElement()){var _7=this.getDataElement(),_8=this.getTextBoxWidth(_1);_7.style.width=(isc.isA.Number(_8)?_8+isc.px:_8)}}},isc.A.setPrompt=function isc_FormItem_setPrompt(_1){this.prompt=_1},isc.A.setHint=function isc_FormItem_setHint(_1){if(this.hint==_1)return;this.hint=_1;if(this.showHint){var _2;if(this.$712()&&this.$1564()&&(_2=this.getDataElement())!=null)
{_2.placeholder=String.htmlStringToString(_1)}else{this.redraw()}}},isc.A.setHintStyle=function isc_FormItem_setHintStyle(_1){if(!this.$712()&&this.getHint()){var _2=this.$59t();if(_2)_2.className=_1}},isc.A.$66t=function isc_FormItem__showInFieldHint(){if(!this.$1563&&!this.hasFocus){var _1=String.htmlStringToString(this.getHint());var _2=this.getDataElement();if(_2!=null){_2.className=this.$66v();if(isc.isA.PasswordItem&&isc.isA.PasswordItem(this)){if(!isc.Browser.isIE||isc.Browser.isIE9){try{var _3=_2.type;_2.type="text";this.$857=_3}catch(e){}}
if(_2.type!=="text")_1=""}}else{var _4=this.$169s();if(_4!=null){_4.className=this.$66v()}}
this.setElementValue(_1);this.$1563=true}},isc.A.$66s=function isc_FormItem__hideInFieldHint(_1){if(this.$1563){var _2=this.getDataElement();if(_2!=null){_2.className=this.getTextBoxStyle();if(this.$857!=null){try{_2.type=this.$857}catch(e){}
this.$857=null}}else{var _3=this.$169s();if(_3!=null){_3.className=this.getTextBoxStyle()}}
if(!_1)this.setElementValue(isc.emptyString);this.$1563=false}},isc.A.$66v=function isc_FormItem__getInFieldHintStyle(){var _1=this.showRTL&&this.isRTL();if((this.showDisabled&&this.renderAsDisabled())||(this.isReadOnly()&&this.useDisabledHintStyleForReadOnly))
{return this.textBoxStyle+(_1?"DisabledHintRTL":"DisabledHint")}else{return this.textBoxStyle+(_1?"HintRTL":"Hint")}},isc.A.$712=function isc_FormItem__getShowHintInField(){return false},isc.A.$176g=function isc_FormItem__getShowHintTextInDataElement(){return this.$712()&&!this.$1564()},isc.A.$1564=function isc_FormItem__getUsePlaceholderForHint(){return false},isc.A.getDefaultValue=function isc_FormItem_getDefaultValue(){if(this.defaultDynamicValue){this.convertToMethod("defaultDynamicValue");var _1=this,_2=this.form,_3=this.form.getValues();return this.defaultDynamicValue(_1,_2,_3)}
return this.defaultValue},isc.A.setToDefaultValue=function isc_FormItem_setToDefaultValue(){return this.clearValue()},isc.A.isSetToDefaultValue=function isc_FormItem_isSetToDefaultValue(){return(this.$14u==true)},isc.A.updateValue=function isc_FormItem_updateValue(){if(this.$149z!=null)delete this.$149z;if(this.$1441)return;if(!this.hasElement()||this.getDataElement()==null)return;if(this.getCanEdit()==false)return;var _1=this.getElementValue();return this.$10y(_1)},isc.A.$1748=function isc_FormItem__remappedDisplayValueUnchanged(_1){if(this.getDisplayFieldName()!=null){var _2=this.mapValueToDisplay(this._value);if(_2==_1&&(_2!=this._value||this.getSelectedRecord()!=null))
{return true}
return false}},isc.A.$10y=function isc_FormItem__updateValue(_1,_2){if(this.$1441&&_1==this.$172a){return}
if(this.$17k){_1=this.$17l(_1)}
if(this.$1748(_1))return;_1=this.mapDisplayToValue(_1);return this.storeValue(_1)},isc.A.storeValue=function isc_FormItem_storeValue(_1,_2){if(this.compareValues(_1,this._value)){return true}
if(this.$17m){if(this.compareValues(_1,this.$17n)){return true}}
var _3=this.handleChange(_1,this._value);if(!_3)return false;if(this.destroyed)return;_1=this.$17n;this.updateAppearance(_1);if(!this.compareValues(_1,this._value)){if(!(this._value==null&&_1&&_1==this.emptyDisplayValue)){this.saveValue(_1)}}
delete this.$17n;this.handleChanged(this._value);if(_2)this.$124t(_1);return _3},isc.A.handleChanged=function isc_FormItem_handleChanged(_1){if(this.form.rulesEngine!=null){this.form.rulesEngine.processChanged(this.form,this)}
if(this.changed)this.changed(this.form,this,_1);if(this.form){this.form.$167p(this,_1);this.checkForImplicitSave()}},isc.A.checkForImplicitSave=function isc_FormItem_checkForImplicitSave(){if(this.getImplicitSave()){var _1=this;this.form.$95x(this);this.form.awaitingImplicitSave=true;this.form.fireOnPause("fiImplicitSave",function(){if(_1.form.awaitingImplicitSave){_1.form.performImplicitSave(_1,true)}},this.form.implicitSaveDelay)}},isc.A.updateAppearance=function isc_FormItem_updateAppearance(_1){if(this.valueIcons||this.getValueIcon){this.$17j(_1)}},isc.A.getValue=function isc_FormItem_getValue(){if(this.destroyed||this.destroying)return;var _1;if(this._value!==_1){return this._value}
return this.form.getSavedItemValue(this)},isc.A.$160w=function isc_FormItem__getOldValue(){var _1=this.form;if(_1==null)return;var _2=this.getTrimmedDataPath()||this[_1.fieldIdProperty];return _1.$10s&&_1.$10s[_2]},isc.A.getElementValue=function isc_FormItem_getElementValue(){if(this.$1563)return this.emptyDisplayValue;var _1=this.getDataElement();if(!_1)return null;var _2="";if(this.$105m&&_1.files&&_1.files.length>1){for(var i=0;i<_1.files.length;i++){if(_2!="")_2+=this.multipleValueSeparator;_2+=_1.files[i].name}}else{_2=_1.value}
return _2},isc.A.resetValue=function isc_FormItem_resetValue(){var _1=this.form.$10s[this.getFieldName()];this.setValue(_1)},isc.A.shouldSubmitValue=function isc_FormItem_shouldSubmitValue(){return this.form.$11q()},isc.A.applyFormula=function isc_FormItem_applyFormula(){if(!this.form)return;var _1=this.form.getRulesEngine();if(!_1)return;var _2=this.getTrimmedDataPath()||this.getFieldName(),_3=this.form.$177w(this),_4=(this.formula?"formula":"textFormula"),_5=this.form.$1638(_3,_4,_2);if(!_5)return;var _6=_1.getRule(_5);if(_6){this.$176n=true;_1.processRules([_6])}},isc.A.getCanEdit=function isc_FormItem_getCanEdit(){return!this.isReadOnly()},isc.A.setCanEdit=function isc_FormItem_setCanEdit(_1){if(this.$127n==true){this.$148w=_1;return}
var _2=this.getCanEdit();this.canEdit=_1;_1=this.getCanEdit();var _3=_2!=_1;this.updateCanEdit(_3);if(_3){this.redraw()}},isc.A.renderAsStatic=function isc_FormItem_renderAsStatic(){return this.getCanEdit()==false&&this.getReadOnlyDisplay()=="static"},isc.A.renderAsReadOnly=function isc_FormItem_renderAsReadOnly(){return this.getCanEdit()==false&&this.getReadOnlyDisplay()=="readOnly"},isc.A.renderAsDisabled=function isc_FormItem_renderAsDisabled(){return(this.isDisabled()||(this.getCanEdit()==false&&this.getReadOnlyDisplay()=="disabled"))},isc.A.updateCanEdit=function isc_FormItem_updateCanEdit(_1){var _2=this.$152q;var _3=this.$152q=this.getCanEdit();if(_2!=_3){if(!this.renderAsDisabled()&&!_1){var _4=!_3;this.setElementReadOnly(_4);this.$177();this.$17j(this.getValue());this.updateState()}
this.$152r(_3,_1)}},isc.A.$152r=function isc_FormItem__canEditChanged(_1,_2){if(this.canEditChanged)this.canEditChanged(_1)},isc.A.setElementReadOnly=function isc_FormItem_setElementReadOnly(_1){if(this.hasDataElement())this.redraw()},isc.A.$86y=function isc_FormItem__setElementReadOnly(_1){if(this.hasDataElement()){var _2=this.getDataElement();if(_2){if(!_1&&!_2.readOnly){_2.disabled=_1}else{_2.readOnly=_1;if(isc.screenReader){if(_2.setAttribute)_2.setAttribute("aria-readonly","true")}}
_2.tabIndex=this.$154()}}else if(this.$kk()){var _2=this.getFocusElement();if(_2)_2.tabIndex=this.$154()}},isc.A.isReadOnly=function isc_FormItem_isReadOnly(){var _1=this;while(_1.parentItem!=null){if(_1.canEdit!=null){return!_1.canEdit}
_1=_1.parentItem}
return!isc.DynamicForm.canEditField(_1,this.form)},isc.A.isEditable=function isc_FormItem_isEditable(){return true},isc.A.getCriteriaFieldName=function isc_FormItem_getCriteriaFieldName(){var _1=this.criteriaField||this.includeFrom||this.getDataPath()||this.getFieldName();if(this.form.dataPath!=null){_1=this.form.$840(_1);if(_1.endsWith("/"))_1=_1.substring(0,_1.length-1)}
return _1},isc.A.getCriteriaValue=function isc_FormItem_getCriteriaValue(_1){var _2;if(this.canEditOpaqueValues){var _3=isc.SimpleType.getType(this.type);if(_3&&_3.getAtomicValue){_2=_3.getAtomicValue(this.getValue(),"criteria")}else{_2=this.getValue()}}else{_2=this.getValue()}
if(!_1){_2=this.performTypeConversion(_2)}
return _2},isc.A.performTypeConversion=function isc_FormItem_performTypeConversion(_1){var _2=this.getType();if(_2!=null){if(isc.isA.String(_1)){if(isc.SimpleType.inheritsFrom(_2,"integer",this.form.getDataSource()))
{var _3=parseInt(_1);if(_3==_1)_1=_3}else if(isc.SimpleType.inheritsFrom(_2,"float",this.form.getDataSource()))
{var _4=parseFloat(_1);if(_4==_1)_1=_4}}}
return _1},isc.A.hasAdvancedCriteria=function isc_FormItem_hasAdvancedCriteria(){var _1=this._value==null?null:this._value;var _2=isc.DS.$57z[this.getOperator()];if(_2&&_2.valueType=="none")return true;var _3=this.$122s||(_1!=null&&(this.operator!=null||this.$85m()));return _3},isc.A.$85m=function isc_FormItem__shouldAllowExpressions(){var _1=isc.isA.TextItem(this)||isc.isA.TextAreaItem(this)||isc.isA.CanvasItem(this)||isc.isA.ContainerItem(this)||isc.isA.DateItem(this);if(!_1)return false;_1=this.allowExpressions;if(this.form==null){return _1}
if(_1==null)_1=this.form.allowExpressions;return _1},isc.A.getOperator=function isc_FormItem_getOperator(_1,_2){if(this.operator){return this.operator}else{return this.getDefaultOperator(_1,_2)}},isc.A.getDefaultOperator=function isc_FormItem_getDefaultOperator(_1,_2){var _3;if(_2){_3="inSet"}else{var _4=this.getType();if(this.valueMap||this.optionDataSource||isc.SimpleType.inheritsFrom(_4,"enum")||isc.SimpleType.inheritsFrom(_4,"boolean")||isc.SimpleType.inheritsFrom(_4,"float")||isc.SimpleType.inheritsFrom(_4,"integer")||isc.SimpleType.inheritsFrom(_4,"time"))
{_3="equals"}else{var _5="iContains";if(this.form){_5=this.form.defaultSearchOperator||(this.form.allowExpressions?"iContainsPattern":"iContains");var _6=this.form.getDataSource(),_7=_6&&_6.getFieldOperators(this.name),_8=_7&&_7.contains(_5);if(!_8&&_7)_5=_7[0]}
_3=isc.DataSource.getCriteriaOperator(null,_1,_5)}}
return _3},isc.A.canEditCriterion=function isc_FormItem_canEditCriterion(_1,_2){if(_1.valuePath!=null)return;var _3=this.getOperator(null,isc.isAn.Array(_1.value));var _4=this.getCriteriaFieldName();if(_1.fieldName!=null&&_1.fieldName==_4&&_1.operator==_3)
{return true}
var _5=this.$85m();if(this.multiple||_5){var _6=_5?this.form.expressionDataSource:null;_6=_6||this.form.dataSource;var _7=isc.DS.getCriteriaFields(_1,_6,true);if(_5){return _7.contains(_4)}else{var _8=isc.DS.isAdvancedCriteria(_1);if(_8&&_1.operator=="or"){return _7.contains(_4)&&_7.getUniqueItems().length==1}}}
return false},isc.A.canEditSimpleCriterion=function isc_FormItem_canEditSimpleCriterion(_1){var _2=this.getCriteriaFieldName();return _2==_1},isc.A.setSimpleCriterion=function isc_FormItem_setSimpleCriterion(_1,_2){this.setValue(_1)},isc.A.getCriterion=function isc_FormItem_getCriterion(_1,_2){var _3=this.getOperator(_1,isc.isAn.Array(this.getValue())),_4=isc.DataSource.$57z[_3],_5=this.getCriteriaFieldName();if(!_4)return;var _6=this.getType(),_7=this.form.getDataSource();var _8=(!_6||!_7||(!_7.getTypeOperators(_6).contains(_3)&&_7.getTypeOperators("text").contains(_3)))||(this.form&&this.form.allowExpressions);var _9=this.getCriteriaValue(_8);if(_4.valueType=="criteria"&&isc.isA.String(_9)){return this.parseValueExpressions(_9,_5,_4)}
if(_4.valueType!="none"&&!_2&&(_9==null||isc.is.emptyString(_9))){return}
if(isc.isAn.Array(_9)){var _10=_9.getUniqueItems();if(_9.length==0||(_10.length==1&&isc.isA.String(_9[0])&&isc.is.emptyString(_9[0])))return}
var _11={fieldName:_5,operator:_3};if(_4.valueType!="none")_11.value=_9;if(this.$85m()){var _12=this.parseValueExpressions(_9,_5,_3);if(_12!=null)_11=_12}
return _11},isc.A.setCriterion=function isc_FormItem_setCriterion(_1){var _2=this.$85m(),_3=_1?_1.value:null;var _4=isc.DS.isAdvancedCriteria(_1);if(_2){var _5=isc.DS.$57z[_1.operator];var _6=this.form&&this.form.grid;if(_4||_5.valueType=="valueRange"||_6&&_6.shouldAllowFilterOperators&&!_6.shouldAllowFilterOperators())
{_3=this.buildValueExpressions(_1)}}else{if(this.multiple){if(_4&&_1.operator=="or"){var _7=[],_8=_1.criteria,_9=this.getCriteriaFieldName(),_10=_8[0]?_8[0].operator:null,_11=false;for(var i=0;i<_8.length;i++){var _13=_8[i];if(_13.criteria||_13.fieldName!=_9||_13.operator!=_10)
{_11=true;break}
_7.add(_13.value)}
if(!_11)_3=_7}}}
this.setValue(_3)},isc.A.$1156=function isc_FormItem__getTextBoxScrollWidth(_1){return _1.scrollWidth},isc.A.$1618=function isc_FormItem__getClipValue(){return(this.renderAsStatic()?this.$1617():!!this.clipValue)},isc.A.valueClipped=function isc_FormItem_valueClipped(){var _1=this.$1618(),_2;return(_1&&(_2=this.$15h())!=null&&isc.Element.getClientWidth(_2)<this.$1156(_2))},isc.A.clearErrors=function isc_FormItem_clearErrors(_1){var _2=this.getFieldName();if(_2)this.form.clearFieldErrors(_2,true,_1)},isc.A.setErrors=function isc_FormItem_setErrors(_1){var _2=this.getFieldName();if(_2)this.form.setFieldErrors(_2,_1,true)},isc.A.setError=function isc_FormItem_setError(_1){var _2=this.getFieldName();if(_2)this.form.setError(_2,_1)},isc.A.hasErrors=function isc_FormItem_hasErrors(){if(this.parentItem!=null)return this.parentItem.hasErrors();var _1=this.getFieldName();if(_1&&this.form)return this.form.hasFieldErrors(_1);var _2=this.getDataPath();if(_2&&this.form)return this.form.hasFieldErrors(_2);return false},isc.A.validate=function isc_FormItem_validate(){var _1=this.hasErrors(),_2=[],_3=null,_4=false;var _5=isc.rpc.startQueue();var _6=this.getValue(),_7=this.form.$181h(true),_8={unknownErrorMessage:this.form.unknownErrorMessage,typeValidationsOnly:this.form.validateTypeOnly};var _9=this.form.validateFieldAndDependencies(this,this.validators,_6,_7,_8);var _10=this.name;if(_10==null)_10=this.getDataPath();if(_10==null){this.logWarn("item has no specified name or dataPath - unable to meaningfully store validation errors.")}
if(!_5)isc.rpc.sendQueue();if(_9!=null){if(_9.resultingValue!=null){this.setValue(_9.resultingValue)}
if(!_9.valid){_2=_9.errors[_10];if(_2==null)_2=[]}
_4=_9.stopOnError;_3=_9.errors}
var _11=false;if(_2.length>0||_1){if(_2.length>0){this.form.setFieldErrors(_10,_2,false)}else{this.form.clearFieldErrors(_10,false)}
_11=true;if(_4)this.focusInItem()}
if(_3){for(var _12 in _3){if(_12!=_10){var _13=_3[_12];if((_13!=null&&!isc.isAn.emptyObject(_13))||this.form.hasFieldErrors(_12))
{this.form.setFieldErrors(_12,_13,false);_11=true}}}}
if(_11){this.redraw()}
return(_2.length==0)},isc.A.setRequired=function isc_FormItem_setRequired(_1){if(_1==this.required)return;this.required=_1;if(this.form==null)return;if(_1){var _2=this.form.getRequiredValidator(this);this.addValidator(_2)}else{this.removeValidator({type:"required"})}
this.redraw()},isc.A.addValidator=function isc_FormItem_addValidator(_1){if(this.validators==null)this.validators=[];else if(!isc.isAn.Array(this.validators))this.validators=[this.validators];if(this.validators.$69){this.validators=this.validators.duplicate()}
this.validators.add(_1)},isc.A.removeValidator=function isc_FormItem_removeValidator(_1){if(this.validators==null)return;if(!isc.isAn.Array(this.validators))this.validators=[this.validators];if(this.validators.$69){this.validators=this.validators.duplicate()}
var _2=this.validators.find(_1);this.validators.remove(_2)},isc.A.setAutoComplete=function isc_FormItem_setAutoComplete(_1){this.autoComplete=_1;this.$10q()},isc.A.$10q=function isc_FormItem__handleAutoCompleteChange(){var _1=this.$17h();if(isc.Browser.isIE&&this.hasDataElement()){var _2=this.getDataElement();if(_2)_2.autoComplete=(_1=="native"?"":"off")}},isc.A.$17h=function isc_FormItem__getAutoCompleteSetting(){if(this.autoComplete!=null)return this.autoComplete;return this.form?this.form.autoComplete:null},isc.A.autoCompleteEnabled=function isc_FormItem_autoCompleteEnabled(){if(isc.Browser.isSafari)return false;return this.$17h()=="smart"},isc.A.uniqueMatchOnly=function isc_FormItem_uniqueMatchOnly(){if(this.uniqueMatch!=null)return this.uniqueMatch;return this.form.uniqueMatch},isc.A.getCandidates=function isc_FormItem_getCandidates(){var _1=this.autoCompleteCandidates;if(_1==null){var _2=this.getAllValueMappings();if(_2!=null){if(isc.isAn.Array(_2))_1=_2;else _1=isc.getValues(_2)}else if(this.form.grid){var _3=this.form.grid.data;if(isc.isA.ResultSet!=null&&isc.isA.ResultSet(_3))_1=_3.getValuesList(this.name);else _1=_3.getProperty(this.name)}}
if(_1!=null)_1=_1.getUniqueItems();return _1},isc.A.getCompletion=function isc_FormItem_getCompletion(_1){if(_1==null)return;var _2=this.getCandidates();if(_2==null||_2.length==0)return;var _3=_1.toUpperCase(),_4=this.uniqueMatchOnly(),_5;for(var i=0;i<_2.length;i++){var _7=_2[i],_8=_7!=null?_7.toUpperCase():null;if(_8==_3)return null;if(isc.startsWith(_8,_3)){if(!_4)return _7;if(_5!=null)return null;_5=_7}}
return _5},isc.A.showCompletion=function isc_FormItem_showCompletion(_1){this.clearCompletion();if(!this.canAutoComplete||!this.hasDataElement()||!this.autoCompleteEnabled())return;var _2=isc.EH.lastEvent.keyName;if(_2=="Backspace"||_2=="Delete")return;var _3=this.getCompletion(_1);if(_3==null){return}
this.form.$106();this.form.$11b(this);this.setElementValue(_1+_3.substring(_1.length));this.$17o=_1;this.$17k=_3;if(this.$173y()){this.setSelectionRange(_1.length,_3.length)}},isc.A.$17l=function isc_FormItem__handleChangeWithCompletion(_1){var _2=this.$17k,_3=isc.EH.lastEvent.keyName;if(this.$14m[_3]==true){this.acceptCompletion(_3==this.$10j);return _2}
var _4=_2.substring(this.$17o.length);if(!_1.endsWith(_4)){this.clearCompletion();return _1}
if(this.getSelectedText()==_4){return this.$17o}
this.clearCompletion();return _1},isc.A.clearCompletion=function isc_FormItem_clearCompletion(){delete this.$17k;delete this.$17o},isc.A.acceptCompletion=function isc_FormItem_acceptCompletion(_1){var _2=this.$17k;if(!_2)return;if(this.autoCompleteEnabled()){var _3=_1?[_2.length,_2.length]:null;if(this.getElementValue()!=_2){if(!_1&&this.$173y()){_3=this.getSelectionRange()}
this.setElementValue(_2)}
if(this.hasFocus&&_3&&this.$173y()){this.setSelectionRange(_3[0],_3[1])}}
this.clearCompletion()},isc.A.$173y=function isc_FormItem__canSetSelectionRange(){if(!isc.isA.TextItem(this)&&!isc.isA.TextAreaItem(this))return false;return true},isc.A.setSelectionRange=function isc_FormItem_setSelectionRange(_1,_2){if(!this.$173y())return;if(!this.isDrawn())return;if(!isc.isA.Number(_1))_1=0;if(!isc.isA.Number(_2))_2=0;if(_1>_2){var _3=_2;_2=_1;_1=_3}
var _4=this.getDataElement();if(_4==null)return;var _5=this.ns.EH,_6=_5.mouseDownEvent&&_5.mouseDownEvent.DOMevent;if(_6!=null&&_5.$129k()&&_5.$145u(_4)){var _7=(_6.target&&(_6.target.nodeType==1?_6.target:_6.target.parentElement));if(_7!=null&&_4.contains(_7)){return}}
if(this.logIsInfoEnabled("nativeFocus")&&!this.$820()){this.logInfo("setSelectionRange() about to change focus "+isc.EH.$lb()+(this.logIsDebugEnabled("traceFocus")?this.getStackTrace():""),"nativeFocus")}
var _8=this.$1621;this.$1621=true;var _9;if(isc.Browser.isIE){this.$180c(_1,_2)}else{if(!this.hasFocus){_4.focus()}
isc.EH.$904=true;_4.setSelectionRange(_1,_2);_9=isc.EH.$904}
if(!_8)delete this.$1621;if(_2>_1)this.$1161=[_1,_2];return _9},isc.A.$180c=function isc_FormItem__selectIETextRange(_1,_2,_3){if(this.$180d){isc.Timer.clear(this.$180d);delete this.$180d}
isc.EH.$904=true;var _4=this.getDataElement();if(_4==null)return;var _5=true,_6=_4.createTextRange();_6.collapse(true);_6.moveStart(this.$14n,_1);_6.moveEnd(this.$14n,(_2-_1));try{_6.select()}
catch(err){_5=false;this.logWarn("Text selection failure: '"+err.message+"'.  "+(!_3?"Retrying selection in another thread.":"Retry failed - no selection will be made."))}
delete isc.EH.$904;if(!_5&&!_3){this.$180d=isc.Timer.setTimeout(this.getID()+".$180c("+_1+","+_2+",true)",0)}},isc.A.selectValue=function isc_FormItem_selectValue(){var _1=this.getElementValue(),_2=isc.isA.String(_1)?_1.length:0;this.setSelectionRange(0,_2)},isc.A.deselectValue=function isc_FormItem_deselectValue(_1){if(!this.hasFocus)return;if(_1)this.setSelectionRange(0,0);else{var _2=this.getElementValue(),_3=isc.isA.String(_2)?_2.length:0;this.setSelectionRange(_3,_3)}},isc.A.getSelectionRange=function isc_FormItem_getSelectionRange(_1){if(!this.$173y())return;if(isc.isA.UploadItem(this))return;if(!this.allowTextSelection){var _2=this.browserInputType=="time"||this.browserInputType=="date"||this.browserInputType=="datetime-local";if((isc.Browser.isChrome&&(this.browserInputType=="digits"||this.browserInputType=="number"||this.browserInputType=="email"||_2))||(isc.Browser.isEdge&&_2))
{return}}
var _3=this.getDataElement();if(_3==null)return;if(isc.Browser.isIE&&isc.Browser.version<10){if(!this.$820())return null;var _4=this.$17p();if(_4==null)return null;if(isc.isA.TextAreaItem(this)){if(!this.supportsSelectionRange)return null;var _5=_4.duplicate();_5.moveToElementText(_3);var _6=_5.text.length;_5.setEndPoint(this.$119o,_4);var i=_6-_5.text.length;return[i,i+_4.text.length]}else{var _8=[],_5=_3.createTextRange();if(_5==null)return null;if(_5.compareEndPoints(this.$14o,_4)==0){_8[1]=_5.text.length}else{_5.setEndPoint(this.$14o,_4);_8[1]=_5.text.length}
_5.setEndPoint(this.$14p,_4);_8[0]=_5.text.length;return _8}}else if(isc.Browser.isMoz||isc.Browser.isSafari||isc.Browser.isOpera||isc.Browser.isIE){return[_3.selectionStart,_3.selectionEnd]}},isc.A.getCursorPosition=function isc_FormItem_getCursorPosition(){var _1=this.getSelectionRange();return _1?_1[0]:null},isc.A.$820=function isc_FormItem__hasNativeFocus(){var _1=this.getFocusElement(),_2=this.getActiveElement();return(_1==_2)},isc.A.getSelectedText=function isc_FormItem_getSelectedText(){if(!isc.isA.TextItem(this)&&!isc.isA.TextAreaItem(this)){return}
if(isc.Browser.isIE){var _1=this.$17p();if(_1)return _1.text}else if(isc.Browser.isMoz||isc.Browser.isSafari){var _2=this.getElement();if(_2!=null){return _2.value.substring(_2.selectionStart,_2.selectionEnd)}}},isc.A.$100a=function isc_FormItem__IESelectionStuck(){if(!isc.Browser.isIE)return false;if(isc.Browser.version>9)return false;try{var _1=document.selection?document.selection.typeDetail:null}catch(e){this.logDebug("Internet explorer native 'stuck focus' state detected");return true}
return false},isc.A.$17p=function isc_FormItem__getIESelectionRange(){if(!isc.Browser.isIE)return;if(isc.isA.TextAreaItem(this)&&!this.supportsSelectionRange)return null;var _1=this.getDocument().selection,_2=(_1!=null?_1.createRange():null);if(_2!=null&&_2.parentElement().id==this.getDataElementId())return _2;return null},isc.A.rememberSelection=function isc_FormItem_rememberSelection(_1){if(!this.isDrawn()||!this.$173y())return;if((!isc.isA.TextItem(this)&&!isc.isA.TextAreaItem(this))||isc.isAn.UploadItem(this))
{return}
var _2=this.getElementValue();if(_2==isc.emptyString)return;this.$17q=_2;var _3=this.getSelectionRange(_1);if(_3){this.$17r=_3[0];this.$17s=_3[1]}},isc.A.resetToLastSelection=function isc_FormItem_resetToLastSelection(_1){if(!this.isDrawn()||this.$17r==null)return;var _2,_3=this.getElementValue(),_4=this.$17q;if(_4==null||_3==null){_2=false}else if(!_1){_2=(_3==_4)}else{_2=true;if(this.$17r==0&&this.$17s==_4.length){this.$17s=_3.length}else{if(_3.toLowerCase()!=_4.toLowerCase()){this.$17r=this.$17s=_3.length}}}
if(_2&&this.$173y()){this.setSelectionRange(this.$17r,this.$17s)}
delete this.$17r;delete this.$17s;delete this.$17q},isc.A.handleChange=function isc_FormItem_handleChange(_1,_2){var _3=this.form.getFieldErrors(this.name);if(this.$17m&&this.compareValues(_1,this.$17n))return true;this.$17m=true;this.$17n=_1;var _4=_1;if(isc.isA.Date(_4))_4=_4.duplicate();else if(isc.isAn.Array(_4))_4=_4.duplicate();else if(isc.isAn.Object(_4))_4=isc.addProperties({},_4);if(this.transformInput){_1=this.transformInput(this.form,this,_1,_2)}
var _5=this.hasErrors(),_6=false,_7=[],_8=null,_9,_10;this.$17g=false;var _11=this.$1490(_1,_2);if(_11!=_1){_1=_11;_6=(_1==_2)}
if(!_6){var _12=isc.rpc.startQueue();var _13=this.form.$181h(),_14={unknownErrorMessage:this.form.unknownErrorMessage,changing:true};_10=this.form.validateFieldAndDependencies(this,this.validators,_1,_13,_14);if(!_12)isc.rpc.sendQueue();var _15=false;if(_10!=null){_15=!_10.valid;if(_10.resultingValue!=null){_9=_10.resultingValue}
if(!_10.valid){_7=_10.errors[this.name];if(_7==null)_7=[]}
_8=_10.errors}
var _16;if(_15&&_9===_16&&this.$65v())
{_6=true;_9=_2;if(_2==null)_9=null}
if(_9!==_16)_1=_9;var _17;if(_15){if(!isc.isAn.Array(_3)){_3=_3==null?[]:[_3]}
var _18=_7;if(!isc.isAn.Array(_18)){_18=[_18]}
var _17=_18.length!=_3.length;if(!_17){for(var i=0;i<_3.length;i++){if(!_18.contains(_3[i])){_17=true;break}}}
if(_17){this.clearErrors(true);this.setError(_7)}}else if(_10!=null&&_5){_17=true;this.clearErrors(true)}
if((!_15||this.changeOnError)){if(this.change!=null){if(this.change(this.form,this,_1,_2)==false){_1=_2;_6=true}}
if(this.destroyed)return;if(!_6&&this.form&&this.form.itemChange!=null){if(this.form.itemChange(this,_1,_2)==false){_1=_2;_6=true}}}}
var _20=this.$17g;var _21=!this.compareValues(_1,_4);if((_6||_21)&&!_20)
{this.setValue(_1,null,true,_6);if(_6&&this.maintainSelectionOnTransform){this.$17t()}}
if(this.$17g)this.$17n=this._value;if(this.redrawOnChange||_17){this.redraw()}
if(_8){for(var _22 in _8){if(_22!=this.name){this.form.setFieldErrors(_22,_8[_22],true)}}}
if(!_6&&this.hasFocus)this.showCompletion(_1);delete this.$17m;return(!_6)});isc.evalBoundary;isc.B.push(isc.A.$1490=function isc_FormItem__enforceLengthOnEdit(_1,_2){if(this.enforceLength&&this.length!=null&&_1!=null){var _3=isc.isA.Number(_1);if(_3){if(this.$184w){_1=this.$184w(_1)}else{_1=""+_1}}
if(isc.isA.String(_1)&&_1.length>this.length){if(_3){if(isc.isA.Number(_2)){_2=this.$184w(_2,true)}}
var _4=_2!=null&&isc.isA.String(_2)&&_2.length==this.length;if(_4){_1=_2}else{_1=_1.substring(0,this.length)}}
if(_3)_1=this.mapDisplayToValue(_1,true)}
return _1},isc.A.$65v=function isc_FormItem__rejectInvalidValueOnChange(){return(this.rejectInvalidValueOnChange!=null)?this.rejectInvalidValueOnChange:this.form.rejectInvalidValueOnChange},isc.A.compareValues=function isc_FormItem_compareValues(_1,_2){var _3=isc.DynamicForm.compareValues;if(this.multiple){if(!(_1==null||isc.isAn.Array(_1))){if(!this.$105m)this.logWarn("compareValues - this is a multiple FormItem but compareValues was called with a non-null first argument `value1` that is not an array.");_1=[_1]}
if(!(_2==null||isc.isAn.Array(_2))){if(!this.$105m)this.logWarn("compareValues - this is a multiple FormItem but compareValues was called with a non-null second argument `value2` that is not an array.");_2=[_2]}
if(_1==null&&_2==null){return true}else if(_1==null||_2==null){return false}
if(_1.length!=_2.length){return false}
var i=0,_5=_1.length;while(i<_5&&_3(_1[i],_2[i],this)){++i}
return(i==_5)}
return _3(_1,_2,this)},isc.A.elementChanged=function isc_FormItem_elementChanged(){var _1=(isc.EH.$lc!=null);if(!_1)isc.EH.$h1("ICHG");this.logDebug("native change");if(isc.Log.supportsOnError){this.updateValue()}else{try{this.updateValue()}catch(e){isc.Log.$am(e)}}
if(!_1)isc.EH.$h2();return true},isc.A.$680=function isc_FormItem__handleInactiveEditorEvent(_1,_2,_3){if(this.logIsDebugEnabled("inactiveEditorHTML")){this.logDebug("handling inactive editor event:"+_1+", inactive context:"+this.echo(_2),"inactiveEditorHTML")}
var _4=this.$683[_1];if(_4==null){_4=this.$683[_1]="inactiveEditor"+_1.substring(0,1).toUpperCase()+_1.substring(1)}
if(this[_4]!=null){return this[_4](_2,_3)}},isc.A.$17u=function isc_FormItem__fireStandardHandler(_1){this.convertToMethod(_1);return this[_1](this.form,this,isc.EH.lastEvent)},isc.A.handleTitleClick=function isc_FormItem_handleTitleClick(){if(this.isDisabled())return;if(this.editingOn){this.editProxy.click();this.handleClick();return false}
return this.$17u("titleClick")},isc.A.handleTitleDoubleClick=function isc_FormItem_handleTitleDoubleClick(){if(this.isDisabled())return;return this.$17u("titleDoubleClick")},isc.A.handleClick=function isc_FormItem_handleClick(){if(this.editingOn){isc.EditContext.selectCanvasOrFormItem(this,true);return false}
if(this.isDisabled())return;var _1=this.$17u("click");if(this.$173z){delete this.$173z;if(_1!=false){this.selectValue()}}
return _1},isc.A.handleDoubleClick=function isc_FormItem_handleDoubleClick(){if(this.isDisabled())return;return this.$17u("doubleClick")},isc.A.handleShowContextMenu=function isc_FormItem_handleShowContextMenu(){return this.$17u("showContextMenu")},isc.A.handleCellClick=function isc_FormItem_handleCellClick(){if(this.isDisabled())return;return this.$17u("cellClick")},isc.A.handleCellDoubleClick=function isc_FormItem_handleCellDoubleClick(){if(this.isDisabled())return;return this.$17u("cellDoubleClick")},isc.A.$12z=function isc_FormItem__handleElementChanged(){return this.form.elementChanged(this.getID())},isc.A.handleMouseMove=function isc_FormItem_handleMouseMove(){var _1=isc.EH.lastEvent.itemInfo;if(!this.isDisabled()&&(this.showValueIconOver||this.showValueIconDown)){var _2=(_1.overElement||_1.overTextBox||_1.overControlTable),_3=this.$15t;if(_2){if(this.$j6&&this.showValueIconDown){if(_3!=this.$13v){this.$15t=this.$13v;this.$17j(this.getValue())}}else{if(this.showValueIconOver&&_3!=this.$13u){this.$15t=this.$13u;this.$17j(this.getValue())}}}else{var _4=(this.showValueIconFocused&&this.showValueIconOver&&this.hasFocus)?this.$13u:null;if(_3!=_4){this.$15t=_4;this.$17j(this.getValue())}}}
var _5=this.$142q,_6=this.$176c;this.$142q=_1&&(_1.overElement||_1.overTextBox);if(!this.$142q&&_1&&_1.overIcon){var _7=this.getIcon(_1.overIcon);if(_7&&_7.inline&&this.$156r()){this.$142q=true}}
this.$176c=this.$142q||(_1&&_1.overControlTable)||(_1.overIcon&&this.getIcon(_1.overIcon)==this.getPickerIcon());if(this.showOver&&(_6!=this.$176c)){this.updateStateForRollover()}
if(this.$17u("mouseMove")==false)return false;if(this.$142q){if(!_5){if(this.handleTextBoxOver()==false)return false}
if(this.handleTextBoxMove()==false)return false}else if(_5){this.handleTextBoxOut()}},isc.A.handleMouseOver=function isc_FormItem_handleMouseOver(){isc.Hover.setAction(this,this.$wb,null,this.$17v());return this.$17u("mouseOver")},isc.A.handleMouseOut=function isc_FormItem_handleMouseOut(){var _1=(this.showValueIconFocused&&this.showValueIconOver&&this.hasFocus)?this.$13u:null;if(this.$15t!=_1){this.$15t=_1;this.$17j(this.getValue())}
this.stopHover();var _2=this.$17u("mouseOut");var _3=this.$142q,_4=this.$176c;this.$142q=this.$176c=false;if(_4){this.updateStateForRollover()}
if(_3){var _5=this.handleTextBoxOut();_2=_5==null?_2:(_2&&_5)}
return _2},isc.A.handleMouseDown=function isc_FormItem_handleMouseDown(){this.$j6=true;isc.Page.setEvent(isc.EH.MOUSE_UP,this,isc.Page.FIRE_ONCE,"$17w");var _1=isc.EH.lastEvent.itemInfo,_2=_1.inactiveContext;if(_2!=null){return this.form.bubbleInactiveEditorEvent(this,"mouseDown",_1)}
if(!this.isDisabled()&&this.showValueIconDown){var _3=(_1.overElement||_1.overTextBox||_1.overControlTable);if(_3){this.$15t=this.$13v;this.$17j(this.getValue())}}
var _4;if(this.mouseDown)_4=this.$17u("mouseDown");var _5=this._value,_6=this.getDisplayValue();if(_1&&_1.overElement&&!this.hasFocus&&_4!=false&&this.$1730()&&this.$173y()&&((_5!=null&&_5!==isc.emptyString)||(_6!=null&&_6!==isc.emptyString)))
{this.setSelectionRange(0,0);this.$173z=true}
return _4},isc.A.$178s=function isc_FormItem__stopBubblingMouseWheelEvent(_1,_2){return false},isc.A.stopHover=function isc_FormItem_stopHover(){isc.Hover.clear()},isc.A.$17w=function isc_FormItem__clearMouseDown(){this.$j6=null;if(this.$15t==this.$13v){this.$15t=this.showValueIconOver?this.$13u:null;this.$17j(this.getValue())}},isc.A.handleMouseStillDown=function isc_FormItem_handleMouseStillDown(_1){if(this.mouseStillDown){return this.$17u("mouseStillDown")}},isc.A.$17v=function isc_FormItem__getHoverDelay(){return this.hoverDelay!=null?this.hoverDelay:this.form.itemHoverDelay},isc.A.handleTitleMove=function isc_FormItem_handleTitleMove(){return this.$17u("titleMove")},isc.A.handleTitleOver=function isc_FormItem_handleTitleOver(){isc.Hover.setAction(this,this.$17x,null,this.$17v());return this.$17u("titleOver")},isc.A.handleTitleOut=function isc_FormItem_handleTitleOut(){this.stopHover();return this.$17u("titleOut")},isc.A.handleTextBoxMove=function isc_FormItem_handleTextBoxMove(){return this.$17u("textBoxMove")},isc.A.handleTextBoxOver=function isc_FormItem_handleTextBoxOver(){isc.Hover.setAction(this,this.$1149,null,this.$17v());return this.$17u("textBoxOver")},isc.A.handleTextBoxOut=function isc_FormItem_handleTextBoxOut(){this.stopHover();return this.$17u("textBoxOut")},isc.A.$121=function isc_FormItem__iconFocus(_1,_2){var _3=this.getIcon(_1);if(_3!=null){var _4=(_3.prompt!=null?_3.prompt:this.iconPrompt)
window.status=_4;if(this.$54o(_3)){this.$168v(_3,false,true)}
else if(this.$165(_3))this.$168v(_3,true)}
return this.$12v(_2,this)},isc.A.$123=function isc_FormItem__iconBlur(_1,_2){var _3=this.getIcon(_1);if(_3!=null){window.status="";var _4=this.$54o(_3),_5=_3.showFocusedWithItem!=false,_6=_3.showOnFocus||_3.showOnFocus==null&&this.showIconsOnFocus;if(_4&&(!_6||!_5)){this.$168v(_3,false,false)}
if(this.$165(_3))this.$168v(_3,false,false)}
return this.$12x(_2,this)},isc.A.$113=function isc_FormItem__iconMouseOver(_1){if(_1==this.errorIconName)return this.$17y();var _2=this.getIcon(_1);if(_2!=null){if(this.$165(_2))this.$168v(_2,true);this.$17z=_2;isc.Hover.setAction(this,this.$170,null,this.$17v());var _3=(_2.prompt!=null?_2.prompt:this.iconPrompt)
window.status=_3;return true}},isc.A.$114=function isc_FormItem__iconMouseOut(_1){if(_1==this.errorIconName)return this.$171();var _2=this.getIcon(_1);if(_2!=null){window.status="";if(this.$165(_2))this.$168v(_2,false);delete this.$17z;isc.Hover.setAction(this,this.$wb,null,this.$17v());return true}},isc.A.$116=function isc_FormItem__iconClick(_1){var _2=this.getIcon(_1);if(_2==null)return;if(this.iconIsDisabled(_2))return;if(_2.click!=null){if(!isc.isA.Function(_2.click)){isc.Func.replaceWithMethod(_2,"click","form,item,icon")}
if(_2.click(this.form,this,_2)==false)return false}
if(_2.pickerIcon&&this.pickerIconClick)this.pickerIconClick(this.form,this,_2);if(this.iconClick)this.iconClick(this.form,this,_2)},isc.A.$172=function isc_FormItem__iconKeyPress(_1){var _2=this.getIcon(_1);if(_2){var _3=isc.EH.getKey(),_4=isc.EH.getKeyEventCharacter();if(_2.keyPress){if(!isc.isA.Function(_2.keyPress)){isc.Func.replaceWithMethod(_2,"keyPress","keyName, character,form,item,icon")}
if(_2.keyPress(_3,_4,this.form,this,_2)==false)
return false}
if(this.iconKeyPress)this.iconKeyPress(_3,_4,this.form,this,_2);if((this.iconClickOnEnter&&_3==this.$10j)||(this.iconClickOnSpace&&_3==this.$304))
{if(this.$116(_2)==false)return false}}},isc.A.$17y=function isc_FormItem__handleErrorIconMouseOver(){isc.Hover.setAction(this,this.$79v,null,this.$17v())},isc.A.$171=function isc_FormItem__handleErrorIconMouseOut(){isc.Hover.setAction(this,this.$wb,null,this.$17v())},isc.A.$79v=function isc_FormItem__handleErrorIconHover(){if(this.itemHover&&this.itemHover(this,this.form)==false)return false;var _1=this.shouldShowErrorIconPrompt()?isc.FormItem.getErrorPromptString(this.$79u):isc.emptyString;if(_1&&!isc.is.emptyString(_1))
isc.Hover.show(_1,this.form.$1845(this));else isc.Hover.setAction(this,this.$wb,null,this.$17v())},isc.A.$wb=function isc_FormItem__handleHover(){var _1=this.form,_2=this.$170g("itemHover");if(_2!=null&&this.fireCallback(_2,null,[_2.target,_1])==false)
{return false}
var _3;if(this.showOldValueInHover!=null){_3=this.showOldValueInHover}else if(_1.showOldValueInHover!=null){_3=_1.showOldValueInHover}else{_3=this.$161p()}
var _4;if(this.originalValueMessage!=null)_4=this.originalValueMessage;else if(_1.originalValueMessage!=null)_4=_1.originalValueMessage;var _5,_6=this.$170g("itemHoverHTML");if(_6!=null){_5=this.fireCallback(_6,null,[_6.target,_1])}else if(_3&&_4!=null&&this.pendingStatus){var _7=this;while(_7.parentItem!=null)_7=_7.parentItem;_5=_4.replace(/(\$?)\$(value|newValue)/g,function(_8,_9,_10,_11,_4){if(_9==="$")return"$"+_10;else if(_10==="value")return _7.$1605(_7.$160w());else if(_10==="newValue")return _7.$1605(_7._value)})}else if(_1.itemHoverHTML===isc.DynamicForm.$1145){_5=isc.DynamicForm.$1145(this)}else{var _7=this;while(_7.parentItem!=null)_7=_7.parentItem;_5=_1.itemHoverHTML(_7,_1)}
this.form.$119(this,_5)},isc.A.$17x=function isc_FormItem__handleTitleHover(_1){if(this.titleHover&&this.titleHover(this,this.form)==false)return false;var _2;if(this.titleHoverHTML)_2=this.titleHoverHTML(this,this.form);else _2=this.form.titleHoverHTML(this,this.form);this.form.$119(this,_2)},isc.A.$1149=function isc_FormItem__handleTextBoxHover(){var _1=isc.EH.lastEvent.itemInfo,_2=this.getIcon(_1&&_1.overIcon);if(_2&&_2==this.$17z&&_2.inline){var _3=this.getIconPrompt(_2);if(_3&&!isc.is.emptyString(_3)){return this.$170()}}
var _4=this.$170g("valueHover");if((this.$170g("itemHoverHTML")!=null||this.form.itemHoverHTML!==isc.DynamicForm.$1145)&&_4==null&&this.form.valueHoverHTML===isc.DynamicForm.$1146)
{return this.$wb()}
if(!this.showClippedValueOnHover||!this.valueClipped()){return this.$wb()}
if(_4!=null&&this.fireCallback(_4,null,[_4.target,this.form])==false)
{return false}
var _5,_6=this.$170g("valueHoverHTML");if(_6!=null){_5=this.fireCallback(_6,null,[_6.target,this.form])}else{var _7=this;while(_7.parentItem!=null)_7=_7.parentItem;_5=this.form.valueHoverHTML(_7,this.form)}
this.form.$119(this,_5)},isc.A.$170=function isc_FormItem__handleIconHover(){if(this.itemHover&&this.itemHover(this,this.form)==false){return false}
var _1=this.$17z,_2=this.getIconPrompt(_1);if(_2&&!isc.is.emptyString(_2))
isc.Hover.show(_2,this.form.$1845(this));else isc.Hover.setAction(this,this.$wb,null,this.$17v())},isc.A.getGlobalTabIndex=function isc_FormItem_getGlobalTabIndex(){if(this.form&&this.form.$167w){return-1}
if(this.globalTabIndex==null){if(this.tabIndex==-1)this.globalTabIndex=-1;else{return isc.TabIndexManager.getTabIndex(this.ID)}}
return this.globalTabIndex},isc.A.getTabIndex=function isc_FormItem_getTabIndex(){if(this.tabIndex!=null)return this.tabIndex;if(this.globalTabIndex||!this.$kk())return null;if(this.$10p==null){return null}
return this.$10p},isc.A.setGlobalTabIndex=function isc_FormItem_setGlobalTabIndex(_1){this.globalTabIndex=_1;this.$173(_1)},isc.A.setTabIndex=function isc_FormItem_setTabIndex(_1){this.globalTabIndex=null;this.tabIndex=_1;this.form.assignItemsTabPosition();this.$173(this.getGlobalTabIndex())},isc.A.$154=function isc_FormItem__getElementTabIndex(_1){if(this.isInactiveHTML()||(!_1&&this.renderAsDisabled()))
{return-1}
return this.getGlobalTabIndex()},isc.A.$173=function isc_FormItem__setElementTabIndex(_1,_2){if(!this.$kk()||!this.isDrawn())return;if(this.getFocusElement()!=null){isc.FormItem.setElementTabIndex(this.getFocusElement(),_1);if(!_2)this.$175()}else{this.redraw("set tab index")}},isc.A.$16p=function isc_FormItem__getIconTabIndex(_1){if(_1.tabIndex==-1||this.iconIsDisabled(_1))return-1;if(this.globalTabIndex!=null){return this.$154(true)}
return isc.TabIndexManager.getTabIndex(this.getTabIndexIdentifierForIcon(_1))},isc.A.$175=function isc_FormItem__updateIconTabIndices(){var _1=[];if(this.$185k())_1.add(this.getPickerIcon());_1.addList(this.icons);for(var i=0;i<_1.length;i++){var _3=_1[i];if(!_3||_3.imgOnly)continue;var _4=this.$16g(_3)||this.$16v();if(_4!=null){isc.FormItem.setElementTabIndex(_4,this.$16p(_3))}}},isc.A.setDisabled=function isc_FormItem_setDisabled(_1){var _2=this.isDisabled();this.disabled=_1;var _3=this.isDisabled();if(_2!=_3)this.updateDisabled()},isc.A.setShowDisabled=function isc_FormItem_setShowDisabled(_1){this.showDisabled=_1;this.updateDisabled()},isc.A.updateDisabled=function isc_FormItem_updateDisabled(){var _1=this.isDisabled();this.$176(!_1);this.$177();this.$17j(this.getValue());if(this.showDisabled)this.updateState()},isc.A.setEnabled=function isc_FormItem_setEnabled(_1){return this.setDisabled(!_1)},isc.A.isDisabled=function isc_FormItem_isDisabled(){if(this.form==null)return this.disabled;var _1=this.disabled;if(!_1){if(this.parentItem!=null)_1=this.parentItem.isDisabled();else{_1=this.form.isDisabled();if(!_1&&this.containerWidget!=this.form)_1=this.containerWidget.isDisabled()}}
return _1},isc.A.enable=function isc_FormItem_enable(){this.setDisabled(false)},isc.A.disable=function isc_FormItem_disable(){this.setDisabled(true)},isc.A.$176=function isc_FormItem__setElementEnabled(_1){if(this.hasDataElement()){var _2=this.getDataElement();if(_2){_2.disabled=!_1;_2.tabIndex=this.$154();if(this.useDisabledEventMask()&&!this.renderDisabledEventMask()){var _3=this.$43b();if(_3&&(!_3.getAttribute||_3.getAttribute("isDisabledEventMask")!="true"))
{_3=null}
if(_1&&_3){isc.Element.clear(_3)}else if(!_1&&!_3){isc.Element.insertAdjacentHTML(_2,"beforeBegin",this.$148())}}}}else if(this.$kk()){var _2=this.getFocusElement();if(_2)_2.tabIndex=this.$154()}},isc.A.$177=function isc_FormItem__setIconsEnabled(){if(this.showPickerIcon){var _1=this.getPickerIcon();this.setIconEnabled(_1)}
if(!this.icons||this.icons.length<1)return;for(var i=0;i<this.icons.length;i++){this.setIconEnabled(this.icons[i])}},isc.A.iconIsDisabled=function isc_FormItem_iconIsDisabled(_1){_1=this.getIcon(_1);if(!_1)return;if(this.containerWidget&&this.containerWidget.isDisabled())return true;if(_1.neverDisable)return false;if(this.isDisabled()||_1.disabled)return true;var _2=_1.disableOnReadOnly;if(_2==null){_2=this.disableIconsOnReadOnly}
if(_2)return this.isReadOnly();return false},isc.A.$kk=function isc_FormItem__canFocus(){if(this.canFocus!=null)return this.canFocus;return this.hasDataElement()},isc.A.$872=function isc_FormItem__canFocusInTextBox(){return this.$kk()&&!this.renderAsStatic()},isc.A.getCanFocus=function isc_FormItem_getCanFocus(){return this.$kk()},isc.A.$884=function isc_FormItem__shouldSelectOnFocus(){if(this.$1621){return false}
var _1=this.selectOnFocus;if(_1==null&&this.form)_1=this.form.selectOnFocus;if(_1){var _2=isc.EH.isMouseEvent()&&(this.containerWidget.contains(isc.EH.lastEvent.target,true));if(_2)_1=false}
return _1},isc.A.$1730=function isc_FormItem__shouldSelectOnClick(){var _1=this.selectOnClick;if(_1==null&&this.form)_1=this.form.selectOnClick;return _1},isc.A.focusAtEnd=function isc_FormItem_focusAtEnd(_1){return isc.TabIndexManager.shiftFocusWithinGroup(this.getID(),null,_1)},isc.A.focusInItem=function isc_FormItem_focusInItem(){var _1=this.isVisible()&&this.$kk()&&!this.renderAsDisabled(),_2=_1?this.getFocusElement():null;var _3=this.$93l;if(!_1||!_2){return}
var _4=this.form;if(isc.EH.targetIsMasked(_4,null,null,this)&&!_4.$1196){var _5=isc.EH.clickMaskRegistry.last();isc.EH.setMaskedFocusCanvas(_4,_5);_4.setFocusItem(this);return}
if(this.hasFocus){this.logDebug("focusInItem() not calling element.focus() as element already has native focus","nativeFocus")}
var _6=this.ns.EH,_7=_6.mouseDownEvent&&_6.mouseDownEvent.DOMevent;if(_7!=null&&_6.$129k()&&_6.$145u(_2)){var _8=(_7.target&&(_7.target.nodeType==1?_7.target:_7.target.parentElement));if(_8!=null&&_2.contains(_8)){return}}
if(_2.focus){var _9=false;if(this.$100a()){try{document.selection.clear()}catch(e){this.logInfo("Internet explorer error calling document.selection.clear()."+e.message)}
this.logDebug("focusInItem(): Internet Explorer selection is currently wedged due to a native bug tripped by synchronous focus manipulation and redraw. Explicitly clearing selection before resetting native focus.","nativeFocus")}else if(isc.Browser.isIE&&_2==this.getActiveElement()){_9=true}
if(!_9){this.logInfo("about to call element.focus() "+isc.EH.$lb()+(this.logIsDebugEnabled("traceFocus")?this.getStackTrace():""),"nativeFocus");isc.FormItem.$12n(this);isc.EventHandler.$lg=this;_2.focus()}else{this.logInfo("element already focused, not focus()ing","nativeFocus")}
if(isc.Browser.isIE&&isc.EH.synchronousFocusNotifications){isc.EH.$vm=this;this.$167=_2}}else{this.logInfo("can't call element focus, no element","nativeFocus")}
var _10=this.$884();if(_3){this.resetToLastSelection(true)}else if(_10&&_2.select){_2.select()}},isc.A.blurItem=function isc_FormItem_blurItem(_1){if(!this.isVisible()||!(this.hasFocus||isc.EH.$vm==this))return;var _2=this.$166();if(_2&&_2.blur){this.logInfo("about to call element blur"+isc.EH.$lb()+(this.logIsDebugEnabled("traceBlur")?this.getStackTrace():""),"nativeFocus");isc.EH.$ld=this;if(isc.Browser.isIE){try{_2.blur()}catch(e){}}else{_2.blur()}}else{this.logInfo("can't call element blur, no element","nativeFocus")}},isc.A.focusInIcon=function isc_FormItem_focusInIcon(_1){_1=this.getIcon(_1);if(_1==null||_1.imgOnly)return false;var _2=this.$16g(_1);if(_2!=null){this.logDebug("focusInIcon() about to call native focus()","nativeFocus");_2.focus();return true}
return false},isc.A.blurIcon=function isc_FormItem_blurIcon(_1){if(isc.isA.String(_1))_1=this.getIcon(_1);if(_1==null||!this.icons||!this.icons.contains(_1)||_1.imgOnly)return;var _2=this.$16g(_1);if(_2!=null){this.logDebug("blurIcon() about to call native blur()","nativeFocus");_2.blur()}},isc.A.isFocused=function isc_FormItem_isFocused(){return this.hasFocus},isc.A.$12v=function isc_FormItem__nativeElementFocus(_1,_2){if(this.$93l)delete this.$93l;if(isc.EH.$lg==this)delete isc.EH.$lg
isc.EH.$la(this,true);if(isc.Browser.isMoz&&!this.isVisible()){this.logWarn("calling element.blur() to correct focus in hidden item: "+this,"nativeFocus");_1.blur();return}
this.hasFocus=true;this.$167=_1;var _3=this.form.elementFocus(_1,_2);return _3},isc.A.$188n=function isc_FormItem__handleAsyncFocusNotification(){if(this.$188o){delete this.$188o;this.containerWidget.notifyAncestorsReflowComplete()}},isc.A.$12x=function isc_FormItem__nativeElementBlur(_1,_2){if(isc.EH.$ld==this)delete isc.EH.$ld
if(this.$17i!=null){isc.Timer.clearTimeout(this.$17i);this.$14r()}
isc.EH.$la(this);this.hasFocus=false;delete this.$167;var _3=this.form.elementBlur(_1,_2);return _3},isc.A.elementFocus=function isc_FormItem_elementFocus(_1){if(this.prompt)this.form.showPrompt(this.prompt);if(!_1)this.$1809(true);if(this.formatOnBlur){var _2=this.getDisplayValue();this.$952(_2,this._value)}
if(this.showFocused)this.updateState();if(this.showValueIconFocused&&this.showValueIconOver&&this.$15t==null){this.$15t=this.$13u;this.$17j(this.getValue())}
if(_1)return;if((this.grid&&this.grid.blockOnFieldBusy(this))||(!this.grid&&this.form.blockOnFieldBusy(this)))
{return false}
this.handleEditorEnter()
if(this.focus){this.convertToMethod("focus");return this.focus(this.form,this)}
return true},isc.A.$181e=function isc_FormItem__updateIconForFocus(_1,_2){if(this.$54o(_1,true)){if(_1.inline&&this.$156r()&&_1.text!=null){var _3=this.$16g(_1);if(_3!=null){var _4=this.getIconStyle(_1,false,null,_2);if(_4!=null)_3.className=_4}
return}
var _5=this.$16v(_1);if(_5!=null){isc.Canvas.$wg(_5,this.getIconURL(_1,false,null,_2));var _4=this.getIconStyle(_1,false,null,_2);if(_4!=null)_5.className=_4}}},isc.A.elementBlur=function isc_FormItem_elementBlur(){if(this.prompt)this.form.clearPrompt();if(this.formatOnBlur){var _1=this.getDisplayValue();this.$952(_1,this._value)}
if(this.showFocused){this.updateState()}
if(this.$15t==this.$13u){this.$15t=null
this.$17j(this.getValue())}
this.acceptCompletion();this.checkForEditorExit();if(this.blur){this.convertToMethod("blur");return this.blur(this.form,this)}
return true},isc.A.checkForEditorExit=function isc_FormItem_checkForEditorExit(_1,_2){if(!_1){isc.FormItem.$92t=this;this.$92u=this.delayCall("checkForEditorExit",[true]);return}
if(_2&&this.$92u!=null){isc.Timer.clearTimeout(this.$92u)}
this.$92u=null;if(isc.FormItem.$92t==this){isc.FormItem.$92t=null}
var _3=false;var _4=this.getActiveElement();if(_4!=null){var _5=isc.DynamicForm._getItemInfoFromElement(_4);if(_5!=null){var _6=_5.item;while(_6){if(_6==this)return;if(_6.parentItem==null){_3=(_6.form==this.form)}
_6=_6.parentItem}}}
if(this.form.hasFocus&&!_3){isc.EH.blurFocusCanvas(this.form,false)}
this.handleEditorExit()});isc.evalBoundary;isc.B.push(isc.A.focusAfterItem=function isc_FormItem_focusAfterItem(_1){isc.TabIndexManager.shiftFocusAfterGroup(this.getID(),_1)},isc.A.$kf=function isc_FormItem__focusInNextTabElement(_1){return this.$180q(_1,false)},isc.A.$180q=function isc_FormItem___focusInNextTabElement(_1,_2){var _3=this.$184c()||this.getID();var _4;if(_2){_4=isc.TabIndexManager.shiftFocusWithinGroup(this.getID(),_3,_1)}else{_4=isc.TabIndexManager.shiftFocus(_3,_1)}
return _4},isc.A.$184c=function isc_FormItem__getCurrentFocusTargetID(){var _1=this.getFocusIconIndex(true),_2;if(_1!=null){if(this.$150!=null){if(_1==0)_2=this.$150;else _1--}
if(_2==null)_2=this.icons[_1]}
if(_2!=null)return this.getTabIndexIdentifierForIcon(_2);return this.getID()},isc.A.autoTabIndexUpdated=function isc_FormItem_autoTabIndexUpdated(_1){if(this.form!=null){this.form.itemAutoTabIndexUpdated(_1)}},isc.A.syntheticShiftFocus=function isc_FormItem_syntheticShiftFocus(_1){if(!this.isValidTabStop())return false;this.focusInItem();return true},isc.A.isValidTabStop=function isc_FormItem_isValidTabStop(_1){if(!this.isDrawn()||!this.isVisible()||this.isDisabled()||!this.$kk()||(!_1&&!this.$872())||this.getTabIndex()==-1){return false}
var _2=this.form.$1096();if(_2!=null&&isc.EH.targetIsMasked(this.form,_2))return false;return true},isc.A.pickerIconSyntheticShiftFocus=function isc_FormItem_pickerIconSyntheticShiftFocus(){if(!this.isValidTabStop(true))return false;var _1=this.$150,_2=(this.canTabToIcons==null&&this.form!=null)?this.form.canTabToIcons:this.canTabToIcons;if(_2!=false&&_1&&_1.visible&&!_1.imgOnly&&_1.tabIndex!=-1)
{this.logInfo("Moving to picker icon","syntheticTabIndex");return this.focusInIcon(_1)}
return false},isc.A.iconSyntheticShiftFocus=function isc_FormItem_iconSyntheticShiftFocus(_1){if(!this.isValidTabStop(true))return false;var _2,_3=(this.canTabToIcons==null&&this.form!=null)?this.form.canTabToIcons:this.canTabToIcons;if(_3!=false&&this.showIcons&&this.icons!=null){var _4=this.getIconFromTabIndexIdentifier(_1),_2=_4?this.getIcon(_4):null;if(_2&&_2.visible&&!_2.imgOnly&&_2.tabIndex!=-1)
{this.logInfo("Moving to icon:"+this.echo(_2),"syntheticTabIndex");return this.focusInIcon(_2)}}
if(_2==null){this.logInfo("Synthetic ShiftFocus failed to find target icon matching ID:"+_1,"syntheticTabIndex")}
return false},isc.A.$11s=function isc_FormItem__moveFocusWithinItem(_1){return this.$180q(_1,true)},isc.A.getFocusIconIndex=function isc_FormItem_getFocusIconIndex(_1){var _2=this.$166();var _3;if(_1&&this.$150!=null){_3=[this.$150];_3.addList(this.icons)}else{_3=this.icons}
if(_2==null||_3==null||_3.length==0)return null;for(var i=0;i<_3.length;i++){if(this.$16g(_3[i])==_2)return i}
return null},isc.A.$kr=function isc_FormItem__allowNativeTextSelection(_1,_2){if(_2.overTitle)return;if(_2.overIcon){return true}
if(_1==null)_1=isc.EH.lastEvent;if(_1.nativeTarget&&(_1.nativeTarget.tagName.toLowerCase()==this.$54n))
return false;if(this.getCanEdit()==false){return this.getReadOnlyDisplay()=="disabled"?false:this.readOnlyCanSelectText}
return this.canSelectText!=false},isc.A.$188y=function isc_FormItem__allowNativeDrag(_1,_2){if(_2.overIcon){return false}
return this.$kr(_1,_2)},isc.A.handleEditorExit=function isc_FormItem_handleEditorExit(){if(!this.form)return;if(!this.$178)return;this.$178=null;if(!this.$16j(true)){this.$1809(false)}
var _1=this.getValue();if(!this.$843)this.$844(_1);if(!this.form.implicitSaveInProgress&&this.getImplicitSaveOnBlur()){this.form.performImplicitSave(this,false)}
if(this.editorExit)this.editorExit(this.form,this,_1)},isc.A.getImplicitSave=function isc_FormItem_getImplicitSave(){if(this.form==null)return false;return!!(this.implicitSave!=null?this.implicitSave:this.form.implicitSave)},isc.A.getImplicitSaveOnBlur=function isc_FormItem_getImplicitSaveOnBlur(){if(this.form==null)return false;return!!(this.implicitSaveOnBlur!=null?this.implicitSaveOnBlur:this.form.implicitSaveOnBlur)},isc.A.$844=function isc_FormItem__performValidateOnEditorExit(_1){if(this.form==null)return;if(this.validateOnExit||this.form.validateOnExit){if(this.$84r||(this.form.getSaveOperationType&&this.form.getSaveOperationType()!="update")||!this.compareValues(_1,this.$75h))
{this.validate()}
this.$84r=null;this.$75h=null}
var _2=this.form.rulesEngine;if(_2!=null){_2.processEditorExit(this.form,this)}},isc.A.handleEditorEnter=function isc_FormItem_handleEditorEnter(){if(isc.FormItem.$92t!=null){isc.FormItem.$92t.checkForEditorExit(true,true)}
if(this.$178)return;this.$178=true;var _1=this.getValue();if(this.validateOnExit||this.form.validateOnExit)this.$75h=_1;if(this.editorEnter)this.editorEnter(this.form,this,_1);if(this.form.rulesEngine!=null){this.form.rulesEngine.processEditorEnter(this.form,this)}},isc.A.$179=function isc_FormItem__setupFocusCheck(){var _1=this;this.$18a=isc.Page.setEvent(isc.EH.MOUSE_UP,function(){if(!_1.destroyed)_1.$18b()})},isc.A.$18b=function isc_FormItem__checkNativeFocus(){isc.Page.clearEvent(isc.EH.MOUSE_UP,this.$18a);delete this.$18a;if(this.getActiveElement()==document.body){this.focusInItem()}},isc.A.$1550=function isc_FormItem__manageCharacterInput(){return!!this.mask},isc.A.$429=function isc_FormItem__willHandleInput(){return false},isc.A._handleInput=function isc_FormItem__handleInput(){isc.EH.$h1("INP");this.$105w();isc.EH.$h2()},isc.A.$105w=function isc_FormItem___handleInput(){if(!this.$1550()){if(this.$1853){this.logDebug("Native input event from cut","cutpaste");this.$1854=true}
delete this.$1853;if(this.$1855){this.logDebug("Native input event from paste","cutpaste");this.$1856=true}
delete this.$1855;if(this.$1856){this.fireTransformPaste()}
if(this.changeOnKeypress){if(isc.Log.supportsOnError){this.updateValue()}else{try{this.updateValue()}catch(e){isc.Log.$am(e)}}}else{var _1=this.getElementValue();this.$122m(_1)}
delete this.$1856;delete this.$1854}},isc.A.fireTransformPaste=function isc_FormItem_fireTransformPaste(){if(!this.transformPastedValue)return;var _1=this.$186u();if(_1==null)return;var _2=this.getElementValue()||"";var _3=this.getSelectionRange()[0];var _4=this.$187h,_5=this.supportsMultilineEntry;if(_4==null||_4==-1||_3<=_4){this.logWarn("Paste event occurred, but unable to determine pasted text position in element value. Skipping transformPastedValue()","cutpaste");return}
if(!_5){var _6=_1.indexOf("\r"),_7=_1.indexOf("\n"),_8=_6>=0?Math.min(_6,_7):_7;if(_8>=0){this.logDebug("Multi-line paste into single-line item detected.","cutpaste")}}
var _9=this.transformPastedValue(this,this.form,_1);if(_9!=null&&_9!=_1){if(!_5&&(_9.contains("\n")||_9.contains("\r")))
{this.logWarn("transformPastedValue() returned multi-line value. This is not supported for this item type. Value may be natively truncated or modified.","cutpaste")}
var _10=_2.substring(_3);this.setElementValue(_2.substring(0,_4)+_9+_10);var _11=this.getElementValue(),_12=_11.lastIndexOf(_10);if(_12!=-1){this.setSelectionRange(_12,_12)}}},isc.A.$186u=function isc_FormItem__getPastedValue(){return this.$186v},isc.A.$122m=function isc_FormItem__minimalUpdateValue(_1){var _2=this.$149z;if(_2==null)_2=this._value;var _3=this.$1490(_1,_2);if(_3!=_1){this.setElementValue(_3);if(_3==_2)this.$17t()}
this.$149z=_3},isc.A.$1162=function isc_FormItem__handleSelect(){isc.EH.$h1("SEL");this.$1160();isc.EH.$h2()},isc.A.$43a=function isc_FormItem__nativeCutPaste(_1,_2,_3,_4){this.logDebug("Native "+(_3?"oncut":"onpaste")+" event received","cutpaste");if(!_3){var _5=_4?_4.clipboardData||window.clipboardData:window.clipboardData;if(_5&&_5.getData){this.$186v=_5.getData(isc.Browser.isIE?'Text':'text/plain');this.logDebug("Native Paste event - got pasted value from clipboard data:"+this.$186v,"cutpaste");var _6=this.getSelectionRange();if(_6!=null){this.$187h=_6[0]}}}
if(!this.$429()){if(this.changeOnKeypress){this.$18c(_3,!_3)}else{this.$1491(_3,!_3)}}else{if(_3){this.$1853=true}else{this.$1855=true}}},isc.A.isCutEvent=function isc_FormItem_isCutEvent(){return(!!this.$1854)},isc.A.isPasteEvent=function isc_FormItem_isPasteEvent(){return(!!this.$1856)},isc.A.handleKeyPress=function isc_FormItem_handleKeyPress(_1,_2){if(!this.form)return;var _3=this.form.$ne(_1),_4=_1.keyName;if(_3.overIcon){if(this.$172(_3.overIcon)==false)return false}else{if(!this.$429()){if(this.changeOnKeypress){this.$18c()}else{this.$1491()}}else{this.rememberSelectionForUpdate()}
if(this.hideIconsOnKeypress&&_4!=this.$jf){this.$185q()}}
var _5=_1.characterValue;var _6=this.$18d(this,this.form,_4,_5);if(_6!==false&&this.shouldStopKeyPressBubbling(_4,_5)){_6=isc.EH.STOP_BUBBLING}
return _6},isc.A.shouldStopKeyPressBubbling=function isc_FormItem_shouldStopKeyPressBubbling(_1,_2){if(_1=="Tab")return true;var _3=[this.$20w,this.$10j];if(this.stopCharacterKeyPressBubbling&&!this.isReadOnly()&&!isc.EH.ctrlKeyDown()&&!isc.EH.altKeyDown()&&(this.$145b[_1]||(_2!=null&&_2!=0&&(!_3.contains(_1)))))
{return true}
if(this.stopNavKeyPressBubbling&&!isc.EH.altKeyDown()){if(this.$145c[_1]){if(!this.$173y()){return true}
var _4=this.getSelectionRange();if(_4){if(_4[0]==0&&_4[1]==0)return false;return true}}
if(this.$145d[_1]){if(!this.$173y())return true;var _4=this.getSelectionRange();if(_4){var _5=this.getElementValue().length;if(_4[0]==_5&&_4[1]==_5)return false;return true}}}},isc.A.$18d=function isc_FormItem__fireKeyPressHandlers(_1,_2,_3,_4){if(this.keyPress!=null&&this.keyPress(_1,_2,_3,_4)==false){return false}
if(!this.form)return false;if(this.$86z!=null&&this.$86z(_1,_2,_3,_4)==false)
{return false}
if(this.parentItem==null&&this.form.itemKeyPress!=null){return this.form.itemKeyPress(_1,_3,_4)}},isc.A.$18c=function isc_FormItem__queueForUpdate(_1,_2){if(this.$17i!=null){isc.Timer.clearTimeout(this.$17i);this.$14r()}
this.rememberSelectionForUpdate();if(_1)this.$1853=true;if(_2)this.$1855=true;this.$17i=this.delayCall("$14r",[],0)},isc.A.rememberSelectionForUpdate=function isc_FormItem_rememberSelectionForUpdate(){if(this.maintainSelectionOnTransform&&(this.$17h()!=this.$14l))
{this.$18e()}},isc.A.$14r=function isc_FormItem__delayedUpdate(){if(this.$1853)this.$1854=true;delete this.$1853;if(this.$1855)this.$1856=true;delete this.$1855;if(this.$1856){this.fireTransformPaste()}
this.updateValue();this.$18f();delete this.$1856;delete this.$1854},isc.A.$1491=function isc_FormItem__queueForMinimalUpdate(_1,_2){if(this.$17i!=null){isc.Timer.clearTimeout(this.$17i);this.$14r(_1,_2)}
if(!this.$1492){this.rememberSelectionForUpdate();this.$1492=isc.Timer.setTimeout({target:this,methodName:this.$1598},0)}
if(_1)this.$1853=true;if(_2)this.$1855=true},isc.A.$149y=function isc_FormItem__delayedMinimalUpdate(){delete this.$1492;if(this.$1853)this.$1854=true;delete this.$1853;if(this.$1855)this.$1856=true;delete this.$1855;if(this.$1856){this.fireTransformPaste()}
this.$122m(this.getElementValue());this.$18f();delete this.$1856;delete this.$1854},isc.A.$18e=function isc_FormItem__rememberPreChangeSelection(){if(!this.$173y())return;var _1=this.getSelectionRange(true);if(_1){this.$18g=_1[0];this.$18h=_1[1]}},isc.A.$17t=function isc_FormItem__revertToPreChangeSelection(){if(this.$18g==null)return;if(this.$173y()){this.setSelectionRange(this.$18g,this.$18h)}},isc.A.$18f=function isc_FormItem__clearPreChangeSelection(){delete this.$18g;delete this.$18h},isc.A.handleKeyDown=function isc_FormItem_handleKeyDown(_1,_2){var _3=_1.keyName,_4=this.$170p.contains(_3);if(this.dirtyOnKeyDown&&!_4){this.$18i()}else{}
var _5=this,_6=this.form;if(this.keyDown!=null&&this.keyDown(_5,_6,_3)==false)return false},isc.A.$10v=function isc_FormItem__itemValueIsDirty(){return this.$18j==true},isc.A.$18i=function isc_FormItem__markValueAsDirty(){this.$18j=true},isc.A.$10x=function isc_FormItem__markValueAsNotDirty(){this.$18j=false},isc.A.handleKeyUp=function isc_FormItem_handleKeyUp(_1,_2){if(!this.form)return;var _3=this,_4=this.form,_5=_1.keyName;if(this.keyUp!=null&&this.keyUp(_3,_4,_5)==false)return false},isc.A.getSerializeableFields=function isc_FormItem_getSerializeableFields(_1,_2){_1=_1||[];_1.addList(["form"]);return this.Super("getSerializeableFields",[_1,_2],arguments)},isc.A.getLeft=function isc_FormItem_getLeft(){var _1=this.isDrawn()?this.getOuterElement():null;if(_1==null){var _2="getLeft() Unable to determine position for "+(this.name==null?"this item ":this.name)+". ";if(this.isDrawn()){_2+="This method is not supported by items of type "+this.getClass()}else{_2+="Position cannot be determined before the element is drawn"}
_2+=" - returning zero.";this.form.logWarn(_2);return 0}
return this.$18k(_1)},isc.A.getTitleLeft=function isc_FormItem_getTitleLeft(){var _1=this.isDrawn()&&this.form?isc.Element.get(this.form.$427(this)):null;if(_1==null){var _2="getTitleLeft() Unable to determine position for "+(this.name==null?"this item ":this.name)+". ";if(this.isDrawn()){_2+="This method is not supported by items of type "+this.getClass()}else{_2+="Position cannot be determined before the element is drawn"}
_2+=" - returning zero.";this.form.logWarn(_2);return 0}
return this.$18k(_1)},isc.A.$18k=function isc_FormItem__getElementLeft(_1){var _2=_1.offsetParent,_3=this.containerWidget.getClipHandle(),_4=_3.offsetParent,_5=isc.Element.getOffsetLeft(_1);while(_2&&_2!=_3&&_2!=_4){_5+=isc.Element.getOffsetLeft(_2)
_5-=(_2.scrollLeft||0);var _6=parseInt(isc.Element.getComputedStyleAttribute(_2,"borderLeftWidth"));if(isc.isA.Number(_6))_5+=_6;var _7=parseInt(isc.Element.getComputedStyleAttribute(_2,"marginLeft"));if(isc.isA.Number(_7))_5+=_7;_2=_2.offsetParent}
if(_2==_4){_5-=isc.Element.getOffsetLeft(_3)}
return _5},isc.A.$145=function isc_FormItem__isValidIcon(_1){return(_1!=null&&(this.icons&&this.icons.contains(_1)||this.showPickerIcon&&this.getPickerIcon()==_1))},isc.A.getIconLeft=function isc_FormItem_getIconLeft(_1){if(_1==null&&this.icons!=null&&this.icons.getLength()>0)_1=this.icons[0];else if(!this.$145(_1)){this.logWarn("getIconLeft() passed invalid icon:"+isc.Log.echoAll(_1));return null}
var _2;if(_1.inline&&this.$156r()&&_1.text!=null){_2=this.$16g(_1)}else{_2=this.$16v(_1)}
if(_2==null){this.logWarn("getIconLeft() unable to return position of icon - this icon is not currently drawn into the page. Returning null");return null}
return isc.Element.getLeftOffset(_2,this.containerWidget.getClipHandle())},isc.A.getTop=function isc_FormItem_getTop(){var _1=this.isDrawn()?this.getOuterElement():null;if(_1==null){var _2="getTop() Unable to determine position for "+(this.name==null?"this item ":this.name)+". ";if(this.isDrawn()){_2+="This method is not supported by items of type "+this.getClass()}else{_2+="Position cannot be determined before the element is drawn"}
_2+=" - returning zero.";this.form.logWarn(_2);return 0}
var _3=this.$18l(_1);return _3},isc.A.getTitleTop=function isc_FormItem_getTitleTop(){var _1=this.isDrawn()&&this.form?isc.Element.get(this.form.$427(this)):null;if(_1==null){var _2="getTitleTop() Unable to determine position for "+(this.name==null?"this item ":this.name)+". ";if(this.isDrawn()){_2+="This method is not supported by items of type "+this.getClass()}else{_2+="Position cannot be determined before the element is drawn"}
_2+=" - returning zero.";this.form.logWarn(_2);return 0}
return this.$18l(_1)},isc.A.$18l=function isc_FormItem__getElementTop(_1){var _2=this.containerWidget.getClipHandle(),_3=_2.offsetParent,_4=_1.offsetParent,_5=isc.Element.getOffsetTop(_1);while(_4&&_4!=_2&&_4!=_3){_5+=isc.Element.getOffsetTop(_4)
_5-=(_4.scrollTop||0);var _6=(isc.Browser.isMoz?0:(isc.Browser.isIE?parseInt(_4.currentStyle.borderTopWidth):parseInt(isc.Element.getComputedStyleAttribute(_4,"borderTopWidth"))));if(isc.isA.Number(_6))_5+=_6;var _7=(isc.Browser.isIE?parseInt(_4.currentStyle.marginTop):parseInt(isc.Element.getComputedStyleAttribute(_4,"marginTop")));if(isc.isA.Number(_7))_5+=_7;_4=_4.offsetParent}
if(_4==_3){_5-=isc.Element.getOffsetTop(_2)}
return _5},isc.A.getIconTop=function isc_FormItem_getIconTop(_1){if(_1==null&&this.icons!=null&&this.icons.getLength()>0)_1=this.icons[0];else if(!this.$145(_1)){this.logWarn("getIconTop() passed invalid icon:"+isc.Log.echoAll(_1));return null}
var _2;if(_1.inline&&this.$156r()&&_1.text!=null){_2=this.$16g(_1)}else{_2=this.$16v(_1)}
if(_2==null){this.logWarn("getIconTop() unable to return position of icon - this icon is not currently drawn into the page. Returning null");return null}
return isc.Element.getTopOffset(_2,this.containerWidget.getClipHandle())},isc.A.getPageLeft=function isc_FormItem_getPageLeft(){var _1=this.containerWidget;var _2=(this.isRTL()&&_1.overflow!=isc.Canvas.VISIBLE);if(!_2){return this.getLeft()+((this.containerWidget.getPageLeft()+this.containerWidget.getLeftMargin()+this.containerWidget.getLeftBorderSize())
-this.containerWidget.getScrollLeft())}else{var _3=_1.getScrollRight();return this.getLeft()+(this.containerWidget.getPageLeft()+this.containerWidget.getLeftMargin()+this.containerWidget.getLeftBorderSize()+(_1.vscrollOn?_1.getScrollbarSize():0))
-(_1.getScrollLeft()-_3)}},isc.A.getPageTop=function isc_FormItem_getPageTop(){return this.getTop()+((this.containerWidget.getPageTop()+this.containerWidget.getTopMargin()+this.containerWidget.getTopBorderSize())
-this.containerWidget.getScrollTop())},isc.A.getTitlePageLeft=function isc_FormItem_getTitlePageLeft(){return this.getTitleLeft()+((this.containerWidget.getPageLeft()+this.containerWidget.getLeftMargin()+this.containerWidget.getLeftBorderSize())
-this.containerWidget.getScrollLeft())},isc.A.getTitlePageTop=function isc_FormItem_getTitlePageTop(){return this.getTitleTop()+((this.containerWidget.getPageTop()+this.containerWidget.getTopMargin()+this.containerWidget.getTopBorderSize())
-this.containerWidget.getScrollTop())},isc.A.getIconRect=function isc_FormItem_getIconRect(_1){return[this.getIconLeft(_1),this.getIconTop(_1),this.getIconWidth(_1),this.getIconHeight(_1)]},isc.A.getIconPageRect=function isc_FormItem_getIconPageRect(_1){var _2=this.getIconRect(_1);_2[0]+=this.containerWidget.getPageLeft();_2[1]+=this.containerWidget.getPageTop();return _2},isc.A.propertyChanged=function isc_FormItem_propertyChanged(_1,_2){if(this.destroyed)return;if(this.$14s[_1]==true)this.$18m=true;if(this.$59q[_1]==true)this.updateState();if(this.$172o[_1]==true&&this.form)this.form.$172p(this,_1);if(_1==this.$59r&&this.items){for(var i=0;i<this.items.length;i++){this.items[i].updateState()}}},isc.A.doneSettingProperties=function isc_FormItem_doneSettingProperties(){if(this.$18m){var _1=this.form,_2=_1.items;_2.$8j=null;_1.markForRedraw()}
delete this.$18m},isc.A.parseValueExpressions=function isc_FormItem_parseValueExpressions(_1,_2,_3){var _4=this.getType(),_5=isc.SimpleType.inheritsFrom(_4,"time"),_6=(isc.SimpleType.inheritsFrom(_4,"integer")||isc.SimpleType.inheritsFrom(_4,"float")),_7=(isc.SimpleType.inheritsFrom(_4,"date")||_5||_6),_8=isc.DynamicForm.getOperatorIndex(),_9=isc.getKeys(_8),_10={operator:"and",criteria:[]},_11=_10.criteria,_12=[],_13=this.$85m(),_14=isc.DS.get(this.form.expressionDataSource||this.form.dataSource);if(!_1)_1=this.getValue();if(!_1)return;if(!isc.isA.String(_1))_1+="";if(_5){_1=isc.Time.$111q(_1)}
var _15=this.getOperator();if(_15)_9.add(_15);var _16=_14?_14.getSearchOperator(_15):{id:_15};var _17=_16.caseInsensitive;if(_7&&_1.contains(" and ")){_12=_1.split(" and ")}else if(_7&&_1.contains(" or ")){_12=_1.split(" or ");_10.operator="or"}else if(_1.contains("...")){_12=_1.split("...");if(_12.length==2){var _18=_8["..."],_19;if(_18)_19=(_17?_18.find("caseInsensitive",true):_18[0]);var _20=_14?_14.getField(_2):null;if(_20){if(_6){_12[0]=this.$79d(_12[0],true);_12[1]=this.$79d(_12[1],true)}else if(isc.SimpleType.inheritsFrom(_20.type,"date")){_12[0]=new Date(Date.parse(_12[0]));_12[0].logicalDate=true;_12[1]=new Date(Date.parse(_12[1]));_12[1].logicalDate=true}else if(isc.SimpleType.inheritsFrom(_20.type,"time")){var _21=isc.Time.createLogicalTime(0,0,0,0);_12[0]=isc.Time.parseInput(_12[0],false,false,false,_21);_21.setSeconds(59,999);_12[1]=isc.Time.parseInput(_12[1],false,false,false,_21)}else if(_20.type=="text"){if(!_12[1].endsWith(this.$87p)){_12[1]+=this.$87p}}}
return{fieldName:_2,operator:_19.ID,start:_12[0],end:_12[1]}}}else{_12=[_1]}
var _22=[" and "," or "];for(var i=0;i<_12.length;i++){var _24=_12[i],_25={fieldName:_2}
_20=_14?_14.getField(_2):null,_26=(_20?_20.type&&isc.SimpleType.inheritsFrom(_20.type,"date"):false),_27=(_20?_20.type&&isc.SimpleType.inheritsFrom(_20.type,"time"):false),_28=false;var _29=null;for(var _30 in _8){if(!_30)continue;if(isc.isA.String(_24)&&_24.startsWith(_30)){_29=_30;break}}
for(var _30 in _8){if(!_30)continue;if(_29&&_30!=_29)continue;var _31=_8[_30],_32=false,_33;if(_30=="=="&&isc.isA.String(_24)&&_24.startsWith("=")&&!_24.startsWith("==")&&!_24.startsWith("=("))
{_32=true}
if(_31&&_31.length){var _34=_31.findAll("caseInsensitive",_17);if(_34==null||_34.length==0)_34=_31;if(_34.length>1){}
_33=_34[0]}
if(!_33||!_33.symbol||_22.contains(_33.symbol)){continue}
if(_9.contains(_33.symbol)&&((isc.isA.String(_24)&&(_24.startsWith(_33.symbol)||(_33.symbol=="..."&&_24.contains(_33.symbol))))||_32))
{_28=true;if(_24.startsWith(_33.symbol)){_24=_24.substring(_33.symbol.length-(_32?1:0))}
if(_33.closingSymbol){if(_24.endsWith(_33.closingSymbol)){_24=_24.substring(0,_24.length-_33.closingSymbol.length)}}
if(_24.contains("...")){var _35=_24.split("...");if(_35.length==2){var _18=_8["..."],_19;if(_18)_19=(_17?_18.find("caseInsensitive",true):_18[0]);var _20=_14?_14.getField(_2):null;if(_20){if(isc.SimpleType.inheritsFrom(_20.type,"date")){_35[0]=new Date(Date.parse(_35[0]));_35[0].logicalDate=true;_35[1]=new Date(Date.parse(_35[1]));_35[1].logicalDate=true}else if(isc.SimpleType.inheritsFrom(_20.type,"time")){var _21=isc.Time.createLogicalTime(0,0,0,0);_35[0]=isc.Time.parseInput(_35[0],false,false,false,_21);_21.setSeconds(59,999);_35[1]=isc.Time.parseInput(_35[1],false,false,false,_21)}else if(_20.type=="text"){if(!_35[1].endsWith(this.$87p)){_35[1]+=this.$87p}}}
_10.criteria.add({fieldName:_2,operator:_19.ID,start:_35[0],end:_35[1]});continue}}
if(_26){_24=new Date(Date.parse(_24));_24.logicalDate=true}else if(_27){var _21=null;if(_33.upperBounds){if(_33.inclusive)_21=isc.Time.createLogicalTime(0,0,59,999);else _21=isc.Time.createLogicalTime(0,0,0,0)}else if(_33.lowerBounds){if(_33.inclusive)_21=isc.Time.createLogicalTime(0,0,0,0);else _21=isc.Time.createLogicalTime(0,0,59,999)}
_24=isc.Time.parseInput(_24,false,false,false,_21)}else{_24=this.$79d(_24,true)}
_25.operator=_33.ID;if(_33.processValue){_24=_33.processValue(_24,_14)}
if(_33.wildCard&&isc.isA.String(_24)&&_24.contains(_33.wildCard)){var _36=_14?_14.patternMultiWildcard:"*";_36=isc.isA.Array(_36)?_36[0]:_36;var _37=_24.replaceAll(_33.wildCard,_36);var _33=_17?"iMatchesPattern":"matchesPattern";if(_3){_33=_3}
_10.criteria.add({operator:_33,fieldName:_2,value:_37});_25.operator=null;this.$877=true}else{if(_33.valueType!="none")_25.value=_24}
break}}
if(!_28){_25.operator=_15;_25.value=this.$79d(_24,true)}
if(_25.operator)_10.criteria.add(_25)}
if(_10.criteria.length==1)_10=_10.criteria[0];if(_10.criteria&&_10.criteria.length==0)_10=null;if(_10.criteria&&!_10._constructor)_10._constructor="AdvancedCriteria";return _10},isc.A.flattenExpressionCriteria=function isc_FormItem_flattenExpressionCriteria(_1){var _2=[];for(var i=0;i<_1.length;i++){var _4=_1[i];if(!_4.criteria){_2.add(_4)}else{_2.addList(this.flattenExpressionCriteria(_4.criteria))}}
return _2});isc.evalBoundary;isc.B.push(isc.A.buildValueExpressions=function isc_FormItem_buildValueExpressions(_1){var _2=_1,_3=isc.shallowClone(_2),_4=" "+_3.operator+" ",_5=[_4],_6=[],_7="",_8=isc.DS.get(this.form.expressionDataSource||this.form.dataSource);if(_2.criteria){_3.criteria=this.flattenExpressionCriteria(_2.criteria)}
var _9=isc.DynamicForm.getOperatorIndex(),_10=isc.getKeys(_9),_11=this.validOperators;if(!_11){_11=[];for(var j=0;j<_10.length;j++){var _13=_9[_10[j]];_11.addList(_13.getProperty("ID"))}}
var _14=this.getOperator();if(_14)_11.add(_14);var _15=_8?_8.getSearchOperator(_14):{id:_14};var _16=_15.caseInsensitive,_17=false,_18;if(!_3.criteria){var _19=[_3];_3={criteria:_19}}
var _20=["startsWith","iStartsWith","contains","iContains","endsWith","iEndsWith"];if(this.useWildCardsByDefault&&this.type=="text"&&(_3.criteria.length>1||(_3.criteria.length==1&&_20.contains(_3.criteria[0].operator)&&_3.criteria[0].value&&_3.criteria[0].value.startsWith("=")&&!_3.criteria[0].value.startsWith("==")&&!_3.criteria[0].value.startsWith("=("))||this.$877))
{_17=true;var _13=_9["=="];var _21=_13.find({"ID":"equals"});_18=_21.wildCard;_5[0]=""}
var _22=0;var _23=["between","iBetween","betweenInclusive","iBetweenInclusive"];for(var i=0;i<_3.criteria.length;i++){var _25=_3.criteria[i],_26=_25.operator,_27=_25.value,_28=_8?_8.getField(_25.fieldName):null;for(var j=0;j<_10.length;j++){var _13=_9[_10[j]];var _29=_13.find({"ID":_26});if(_29){_26=_29;break}}
if(i>0){_5.add(_4)}
if(isc.isA.String(_26)){this.logWarn("Unknown filter-expression operator: '"+_26+"'")}else if(_17){if(_26.ID=="contains"||_26.ID=="iContains"){if(_6[_6.length-1]!=_18)_6.add(_18);_6.add(_25.value);_6.add(_18)}else if(_26.ID=="startsWith"||_26.ID=="iStartsWith"){_6.add(_25.value);_6.add(_18)}else if(_26.ID=="endsWith"||_26.ID=="iEndsWith"){if(_6[_6.length-1]!=_18)_6.add(_18);_6.add(_25.value)}}else if(_26.ID==_14&&!_23.contains(_26.ID)){_6.add(this.$111i(_25.value))}else if(_23.contains(_26.ID)){if(_3.criteria.length>1)_5.addAt(_26.symbol,_22);else _5[_22]=_26.symbol
_22++;var _30=_25.end;if(_28&&_28.type=="text"){if(_30&&_30.endsWith(this.$87p)){_30=_30.replace(this.$87p,"")}}
var _31=this.$111i(_25.start);_30=this.$111i(_30);if(_31!=_30)_6.addList([_31,_30]);else _6.add(_31)}else if(_26.ID=="isBlank"||_26.ID=="notBlank"||_26.ID=="isNull"||_26.ID=="notNull"){_6.add(_26.symbol)}else if(_11.contains(_26.ID)){var _32=_26;if(isc.isAn.Array(_27))_27=_27.join(_26.valueSeparator);if(_32.ID!=_15){_27=(_32&&_32.symbol?_32.symbol:"")+this.$111i(_27);if(_32.closingSymbol)_27+=_32.closingSymbol}
_6.add(_27)}else if(_26.ID.startsWith("i")){var _33=_26.ID.substring(1),_34=_33.charAt(0);_33=_34.toLowerCase()+_33.substring(1)
if(_11.contains(_33)){var _35=_10.find("ID",_33);if(_35.ID!=_15){_27=(_32&&_32.symbol?_32.symbol:"")+this.$111i(_27);if(_32.closingSymbol)_27+=_32.closingSymbol}
_6.add(_27)}}
_22++}
if(_17)_6.addAt("=",0);if(_5.length>1){for(var i=0;i<_6.length;i++){_7+=_6[i];if(i<_6.length-1)_7+=_5[i]}}else{_7=_6.join((_6.length>1?_5[0]:""))}
delete this.$877;return _7.length>0?_7:null},isc.A.enteredCompleteExpression=function isc_FormItem_enteredCompleteExpression(){var _1=isc.DynamicForm.getOperatorIndex(),_2=isc.getKeys(_1),_3=this.validOperators,_4=this._value;if(!_3){_3=[];for(var j=0;j<_2.length;j++){var _6=_1[_2[j]];_3.addList(_6.getProperty("symbol"))}}
if(!isc.isA.String(_4)){this.$1464=true;return true}
if(this.$1464&&(_4==null||isc.isAn.emptyString(_4))){delete this.$1464;return true}
var _7=!["#","!#"].contains(_4),_8=true;if(_8&&_3.contains(_4)&&_7){_8=false}
if(_8&&_4.contains("=(")&&!_4.contains(")")){_8=false}
if(_8&&_7){for(var j=0;j<_3.length;j++){var _9=_3[j];if(_9.startsWith(_4)){_8=false;break}}}
this.$1464=_8;return this.$1464},isc.A.$111i=function isc_FormItem__formatCriterionValue(_1){return String(_1)});isc.B._maxIndex=isc.C+596;isc.FormItem.registerStringMethods({showIf:"item,value,form,values",defaultDynamicValue:"item,form,values",focus:"form,item",blur:"form,item",editorEnter:"form,item,value",editorExit:"form,item,value",click:"form,item",doubleClick:"form,item",showContextMenu:"form,item",pickerIconClick:"form,item,pickerIcon",iconClick:"form,item,icon",iconKeyPress:"keyName,character,form,item,icon",change:"form,item,value,oldValue",changed:"form,item,value",pendingStatusChanged:"form,item,pendingStatus,newValue,value",transformInput:"form,item,value,oldValue",cellClick:"form,item",cellDoubleClick:"form,item",titleClick:"form,item",titleDoubleClick:"form,item",mouseMove:"form,item",mouseOver:"form,item",mouseOut:"form,item",titleMove:"form,item",titleOver:"form,item",titleOut:"form,item",textBoxMove:"form,item",textBoxOver:"form,item",textBoxOut:"form,item",itemHover:"item,form",titleHover:"item,form",valueHover:"item,form",keyPress:"item, form, keyName, characterValue",keyDown:"item,form,keyName",keyUp:"item,form,keyName",transformPastedValue:"item,form,pastedValue",getValueIcon:"value",formSaved:"request,response,data",formatValue:"value,record,form,item",formatEditorValue:"value,record,form,item",parseEditorValue:"value,form,item"});isc.FormItem.getPrototype().toString=function(){return"["+this.Class+" ID:"+this.ID+(this.name!=null?" name:"+this.name:"")+"]"};isc.ClassFactory.defineClass("FormItemFactory");isc.A=isc.FormItemFactory;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$gx="text";isc.A.$18n="Item";isc.A.$18o="TextareaItem";isc.A.$679="TextAreaItem";isc.A.$68a="DatetimeItem";isc.A.$68b="DateTimeItem";isc.A.$18p={};isc.B.push(isc.A.getItemClassName=function isc_c_FormItemFactory_getItemClassName(_1,_2,_3,_4){if(_2==null)_2=_1.editorType||_1.formItemType||_1.type;if(isc.isA.String(_2)){var _5=_2.toLowerCase();if(_5.contains(isc.DynamicForm.$12b)){if(_5=="selectother"||_5=="selectotheritem"){_5="select";if(!_4)_1.isSelectOther=true}
if(_5=="select"||_5=="selectitem"){_3=_1.form||_3;var _6=(!isc.ListGrid||(_1.multiple&&_1.multipleAppearance=="grid")||(_3?_3.useNativeSelectItems:false));if(_6)_2="NativeSelectItem"
else _2="SelectItem"}}
if(_5==isc.DynamicForm.$52w)_2="MultiFileItem";else if(_5==isc.DynamicForm.$12g)_2="MultiUploadItem";else if(_5==isc.DynamicForm.$51x.toLowerCase())_2="SOAPUploadItem"}
return _2},isc.A.getItemClass=function isc_c_FormItemFactory_getItemClass(_1){var _2=isc.ClassFactory.getClass(_1);if(!_2||!isc.isA.FormItem(_2)){if(isc.SGWTFactory&&isc.isA.SGWTFactoryObject(_2))return _2;if(_1!=null&&_1.startsWith("T")){var _3=_1.substring(1),_2=isc.ClassFactory.getClass(_3);if(isc.isA.FormItem(_2))return _2}
if(_1==null)_1=this.$gx;var _4=this.$18p,_5=_4[_1];if(!_5){_5=_4[_1]=_1.substring(0,1).toUpperCase()+_1.substring(1)+this.$18n}
if(_5==this.$18o)_5=this.$679;if(_5==this.$68a)_5=this.$68b;_2=isc.ClassFactory.getClass(_5)}
return _2},isc.A.makeItem=function isc_c_FormItemFactory_makeItem(_1){if(_1==null)return null;if(isc.isA.FormItem(_1)){return _1}
var _2=this.getItemClassName(_1),_3=this.getItemClass(_2);if(!_3){this.logWarn("makeItem(): type "+_1.type+" not recognized, using TextItem");_3=isc.TextItem}
return isc.ClassFactory.newInstance(_3,_1)});isc.B._maxIndex=isc.C+3;isc.ClassFactory.defineClass("Validator");isc.Validator.addProperties({})
isc.A=isc.Validator;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.notABoolean="Must be a true/false value";isc.A.notAString="Must be a string.";isc.A.notAnInteger="Must be a whole number.";isc.A.notADecimal="Must be a valid decimal.";isc.A.notADate="Must be a date.";isc.A.notATime="Must be a time.";isc.A.notAnIdentifier="Identifiers must start with a letter, underscore or $ character, and may contain only letters, numbers, underscores or $ characters.";isc.A.notARegex="Must be a valid regular expression.";isc.A.notAColor="Must be a CSS color identifier.";isc.A.mustBeLessThan="Must be no more than ${max}";isc.A.mustBeGreaterThan="Must be at least ${min}";isc.A.mustBeLaterThan="Must be later than ${min.toShortDate()}";isc.A.mustBeLaterThanTime="Must be later than ${isc.Time.toShortTime(min)}";isc.A.mustBeEarlierThan="Must be earlier than ${max.toShortDate()}";isc.A.mustBeEarlierThanTime="Must be earlier than ${isc.Time.toShortTime(max)}";isc.A.mustBeShorterThan="Must be no more than ${max} characters";isc.A.mustBeLongerThan="Must be at least ${min} characters";isc.A.mustBeExactLength="Must be exactly ${max} characters";isc.A.notAMeasure='Must be a whole number, percentage, "*" or "auto"';isc.A.requiredField="Field is required";isc.A.requiredFile="Non-empty file required";isc.A.notOneOf="Not a valid option";isc.A.notAFunction='Must be a function.';isc.A.maxFileSizeExceeded="Size of '${fileName}' (${isc.NumberUtil.toMiBString(fileSize, maxFileSize)} MiB) exceeds maximum allowed file size of ${isc.NumberUtil.toMiBString(maxFileSize, fileSize)} MiB.";isc.A.$18q="true";isc.A.$18r="false";isc.A.$605=".";isc.A.READONLY="readOnly";isc.A.HIDDEN="hidden";isc.A.DISABLED="disabled";isc.A.$74u={isBoolean:{type:"isBoolean",description:"Value is boolean",valueType:"none",dataType:"none",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(isc.isA.Boolean(_3))return true;if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.notABoolean}
if(isc.isA.String(_3)){var _4=isc.Validator;_2.resultingValue=(_3==_4.$18q);return(_3==_4.$18q||_3==_4.$18r)}else if(isc.isA.Number(_3)){_2.resultingValue=(_3!=0);return(_3==0||_3==1)}
_2.resultingValue=!!_3;return false}},isString:{type:"isString",description:"Value is a string",valueType:"none",dataType:"none",condition:function(_1,_2,_3){if(_3==null||isc.isA.String(_3))return true;if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.notAString;_2.resultingValue=isc.iscToLocaleString(_3);return true}},isInteger:{type:"isInteger",description:"Value is a whole number",valueType:"none",dataType:"none",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.notAnInteger;if(isc.isA.String(_3)){_3=_3.trim();if(_3.length==0){_2.resultingValue=null;return false}}
if(isNaN(_3)){_2.resultingValue=null;return false}
if(_1&&isc.booleanValue(_1.stringInBrowser)===true&&isc.isA.String(_3)){_2.resultingValue=_3;return true}
if(_1&&_1.type&&_1.type.startsWith("locale")&&isc.isA.String(_3)){var _4=isc.NumberUtil.parseLocaleInt(_3);if(isNaN(_4)){_2.resultingValue=null;return false}else{_2.resultingValue=_4;return true}}
var _4=parseInt(_3,10),_5=(_3==_4),_6=!(_3==_4.toString());if(!_5){if(_2.convertToInteger){var _7=parseFloat(_3);_4=Math.round(_7);_2.resultingValue=_4;return true}else{_2.resultingValue=_4;return false}}else{if(_1&&isc.booleanValue(_1.stringInBrowser,true)!==false){if(isc.isA.String(_3)&&_6){var r=new RegExp('^([+|-](?=\\d))?(\\d*)');var _9=r.exec(_3);if(_9[2]==null)_9[2]='';_9[2]=_9[2].replace(/^0+/,'');var _10=r.exec(_4.toString());if(_10[2]==null)_10[2]='';_10[2]=_10[2].replace(/^0+/,'');_6=!(_9[2]==_10[2])}
if(isc.isA.String(_3)&&_6){_2.resultingValue=_3;return true}}
if(_4==Number.POSITIVE_INFINITY||_4==Number.NEGATIVE_INFINITY){_2.resultingValue=null;return false}
_2.resultingValue=_4;return true}}},isFloat:{type:"isFloat",description:"Value is a floating point number",valueType:"none",dataType:"none",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.notADecimal;if(isc.isA.String(_3)){_3=_3.trim();if(_3.length==0){_2.resultingValue=null;return false}}
if(isNaN(_3)){_2.resultingValue=null;return false}
if(_1&&isc.booleanValue(_1.stringInBrowser)===true&&isc.isA.String(_3)){_2.resultingValue=_3;return true}
var _4;if(_3==isc.Validator.$605){_4="0."}else if(_1&&_1.type&&_1.type.startsWith("locale")&&isc.isA.String(_3)){_4=isc.NumberUtil.parseLocaleFloat(_3);if(isNaN(_4)){return false}}else{_4=parseFloat(_3);var _5=!(_3==_4.toString());if(isc.isA.String(_3)&&_5){var r=new RegExp('^([+|-](?=\\d|(?:\\.(?=\\d))))?(\\d*)(\\.(?=\\d)\\d*)?(?:e([+|-])?(\\d+))?','i');var _7=r.exec(_3);if(_7[2]==null)_7[2]='';_7[2]=_7[2].replace(/^0+/,'');if(_7[3]==null)_7[3]='';if(_7[3].indexOf('.')==0)_7[3]=_7[3].substring(1);_7[3]=_7[3].replace(/0+$/,'');var _8=_7[2]+_7[3];if(_8.length<=16){var _8=_7[2]+_7[3]+'0000000000000000';_8=_8.substring(0,16);var _9=r.exec(_4.toExponential(16));if(_9[2]==null)_9[2]='';_9[2]=_9[2].replace(/^0+/,'');if(_9[3]==null)_9[3]='';if(_9[3].indexOf('.')==0)_9[3]=_9[3].substring(1);var _10=_9[2]+_9[3]+'0000000000000000';_10=_8.substring(0,16);_5=!(_8==_10)}else{_5=true}}
if(_1&&isc.booleanValue(_1.stringInBrowser,true)!==false&&isc.isA.String(_3)&&_5){_2.resultingValue=_3;return true}
if((_4==Number.POSITIVE_INFINITY||_4==Number.NEGATIVE_INFINITY)){_2.resultingValue=null;return false}}
_2.resultingValue=_4;return true}},isDate:{type:"isDate",description:"Value is a date",valueType:"none",dataType:"none",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3)||isc.isA.Date(_3))return true;if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.notADate;var _4=isc.Validator.$93n?isc.DateUtil.parseInput(_3):isc.DateUtil.parseSchemaDate(_3);if(_4==null||isNaN(_4.getTime()))return false;_2.resultingValue=_4;return true}},isTime:{type:"isTime",description:"Value is a logical Time value",valueType:"none",dataType:"none",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3)||isc.isA.Date(_3))return true;if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.notATime;var _4=isc.Time.parseInput(_3,true);if(_4==null){_4=isc.DateUtil.parseSchemaDate(_3)}
if(_4!=null){_2.resultingValue=_4;return true}
return false}},isIdentifier:{type:"isIdentifier",valueType:"none",dataType:"none",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.notAnIdentifier}
return _3.match(/^[a-zA-Z_\$][\w\$]*$/)!=null}},isRegexp:{type:"isRegexp",valueType:"none",dataType:"none",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.notARegex;if(typeof _3=='object'&&_3.constructor==RegExp)return true;if(isc.Browser.isDOM){if(!isc.Validator.$18t){isc.Validator.$18t=isc.$aq("value","try{var regex=new RegExp(value)}catch(e){return false}return true")}
return isc.Validator.$18t(_3)}else{var _4=new RegExp(_3);return true}}},isFunction:{type:"isFunction",valueType:"none",dataType:"none",condition:function(_1,_2,_3){if(_3==null||isc.isAn.emptyString(_3)||_3===isc.Class.NO_OP||isc.isA.Function(_3)||isc.isA.StringMethod(_3))
{return true}
if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.notAFunction;if(isc.isAn.Array(_3)){if(!_1.multiple)return false;var _4=new Array(_3.length);for(var i=0;i<_3.length;++i){var _6=_3[i];if(_6==null||isc.isAn.emptyString(_6)||_6===isc.Class.NO_OP||isc.isA.Function(_6)||isc.isA.StringMethod(_6))
{_4[i]=_6}else{try{isc.Func.expressionToFunction("",_6)}catch(e){return false}
if(_6.iscAction)_6=_6.iscAction;_4[i]=isc.StringMethod.create({value:_6})}}
_2.resultingValue=_4;return true}else{try{isc.Func.expressionToFunction("",_3)}catch(e){return false}
if(_3.iscAction)_3=_3.iscAction;_2.resultingValue=isc.StringMethod.create({value:_3});return true}}},isColor:{type:"isColor",valueType:"none",dataType:"text",condition:function(_1,_2,_3){if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.notAColor;if(!_3)return true;return isc.isA.color(_3)}},isMeasure:{type:"isMeasure",valueType:"none",dataType:["integer","string"],condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3)||_3=="*")return true;if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.notAMeasure;if(isc.isA.String(_3)&&_3.charAt(_3.length-1)=='%'){_3=_3.slice(0,-1);return _3.match(/\d+\.?\d*/)!=null}
return isc.Validator.processValidator(_1,_2,_3,"integerOrAuto")}},integerOrAuto:{type:"integerOrAuto",valueType:"none",dataType:["integer","string"],condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3)||(isc.isA.String(_3)&&_3.toLowerCase()=="auto"))return true;return isc.Validator.processValidator(_1,_2,_3,"isInteger")}},integerOrIdentifier:{type:"integerOrIdentifier",valueType:"none",dataType:["integer","string"],condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(_3.match(/^[a-zA-Z_\$][\w\$]*$/)!=null)return true;return isc.Validator.processValidator(_1,_2,_3,"isInteger")}},integerRange:{type:"integerRange",title:"Value in range",description:"Value is an integer within the specified range",valueType:"valueRange",dataType:"integer",rangeStartAttribute:"min",rangeEndAttribute:"max",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(isc.isA.String(_3)){_3=_3.trim();if(_3.length==0){return true}}
if(isNaN(_3))return true;var _4;if(isc.isA.Number(_3)){_4=_3}else{_4=parseInt(_3,10)}
if(_1&&isc.booleanValue(_1.stringInBrowser)===true&&isc.isA.String(_3)){return true}
_2.dynamicErrorMessageArguments={validator:_2,max:_2.max,min:_2.min}
if(_1&&isc.booleanValue(_1.stringInBrowser,true)!==false&&isc.isA.String(_3)&&!(_3==_4.toString())){var _5=isc.BigDecimal.create(_3);if(isc.isA.Number(_2.max)&&((!_2.exclusive&&_5.compareTo(_2.max)>0)||(_2.exclusive&&_5.compareTo(_2.max)>=0)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeLessThan}
return false}
if(isc.isA.Number(_2.min)&&((!_2.exclusive&&_5.compareTo(_2.min)<0)||(_2.exclusive&&_5.compareTo(_2.min)<=0)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeGreaterThan}
return false}
return true}
if(isc.isA.Number(_2.max)&&((!_2.exclusive&&_4>_2.max)||(_2.exclusive&&_4>=_2.max)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeLessThan}
return false}
if(isc.isA.Number(_2.min)&&((!_2.exclusive&&_4<_2.min)||(_2.exclusive&&_4<=_2.min)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeGreaterThan}
return false}
return true}},lengthRange:{type:"lengthRange",title:"String length in range",description:"Value is a string whose length falls within the specified range",valueType:"valueRange",dataType:"text",rangeStartAttribute:"min",rangeEndAttribute:"max",editorTitle:"Range",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(!isc.isA.String(_3))return true;_2.dynamicErrorMessageArguments={validator:_2,max:_2.max,min:_2.min}
var _4=_3.length,_5=_2.max!=null?parseInt(_2.max,10):null,_6=_2.min!=null?parseInt(_2.min,10):null;if(!isc.isA.Number(_5))_5=null;if(!isc.isA.Number(_6))_6=null;if(_5!=null&&_4>_5){_2.defaultErrorMessage=(_5==_6?isc.Validator.mustBeExactLength:isc.Validator.mustBeShorterThan);return false}
if(_6!=null&&_4<_6){_2.defaultErrorMessage=(_5==_6?isc.Validator.mustBeExactLength:isc.Validator.mustBeLongerThan);return false}
return true}},contains:{type:"contains",title:"String contains substring",description:"Value contains the specified substring",valueType:"fieldType",dataType:"text",valueAttribute:"substring",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(!isc.isA.String(_3))_3=isc.iscToLocaleString(_3);return _3.indexOf(_2.substring)>-1}},doesntContain:{type:"doesntContain",shortName:"Doesn't Contain",title:"String does not contain substring",description:"Value does not contain the specified substring",valueType:"fieldType",dataType:"text",valueAttribute:"substring",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(!isc.isA.String(_3))_3=isc.iscToLocaleString(_3);return _3.indexOf(_2.substring)==-1}},substringCount:{type:"substringCount",title:"String contains substring multple times",description:"Value contains a specified substring multiple times",valueType:"custom",dataType:"text",editorType:"SubstringCountEditor",editorTitle:"Substring",getAttributesFromEditor:function(_1,_2){var _3=_2.canvas;return _3.getValues()},setEditorAttributes:function(_1,_2,_3){var _4=_2.canvas;if(_3==null){_4.clearValues();return}
_4.setValue("substring",_3.substring);_4.setValue("count",_3.count);_4.setValue("operator",_3.operator)},condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;var _4=_2.substring;for(var _5=0,_6=0;_5<_3.length;_5++){_5=_3.indexOf(_4,_5);if(_5>-1)_6++;else break}
var _7=_2.operator,_8=_2.count;if(!_7)_7="==";if(!_8)_8=0;switch(_7){case"==":return _6==_8;case"!=":return _6!=_8;case"<":return _6<_8;case"<=":return _6<=_8;case">":return _6>_8;case">=":return _6>=_8}
return false}},regexp:{type:"regexp",title:"Value matches regex",description:"Value matches a regular expression",valueType:"fieldType",dataType:"text",valueAttribute:"expression",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;var _4=_2.expression;if(isc.isA.String(_4)){_4=new RegExp(_4)}
_4.lastIndex=0;return _4.test(_3)}},mask:{type:"mask",title:"Values matches regex mask",description:"Value matches a regular expression mask",valueType:"custom",dataType:"text",editorType:"MaskRuleEditor",getAttributesFromEditor:function(_1,_2){var _3=_2.canvas;return _3.getValues()},setEditorAttributes:function(_1,_2,_3){var _4=_2.canvas;if(_3==null){_4.clearValues();return}
_4.setValue("mask",_3.mask);_4.setValue("transformTo",_3.transformTo)},condition:function(_1,_2,_3){if(_3==null)return true;if(!isc.isA.String(_3)&&isc.isA.Function(_3.toString))
_3=_3.toString();if(isc.is.emptyString(_3))return true;var _4=_2.mask;if(isc.isA.String(_4))_4=_2.mask=new RegExp(_4);_4.lastIndex=0;if(!_4.test(_3)){return false}else{if(_2.transformTo){_2.resultingValue=_3.replace(_4,_2.transformTo)}}
return true}},dateRange:{type:"dateRange",title:"Value in range",description:"Value is a date within the specified range",valueType:"valueRange",dataType:"date",rangeStartAttribute:"min",rangeEndAttribute:"max",editorType:"RelativeDateItem",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(!isc.isA.Date(_3))return false;var _4=_2.min,_5=_2.max;if(_4!=null&&!isc.isA.Date(_4)){_4=_2.min=isc.DateUtil.parseSchemaDate(_4)}
if(_5!=null&&!isc.isA.Date(_5)){_5=_2.max=isc.DateUtil.parseSchemaDate(_5)}
_2.dynamicErrorMessageArguments={validator:_2,max:_5,min:_4}
if(isc.isA.Date(_4)&&((!_2.exclusive&&_3.getTime()<_4.getTime())||(_2.exclusive&&_3.getTime()<=_4.getTime())))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeLaterThan}
return false}
if(isc.isA.Date(_5)&&((!_2.exclusive&&_3.getTime()>_5.getTime())||(_2.exclusive&&_3.getTime()>=_5.getTime())))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeEarlierThan}
return false}
return true}},timeRange:{type:"timeRange",title:"Value in range",description:"Value is a logical time value within the specified range",valueType:"valueRange",dataType:"time",rangeStartAttribute:"min",rangeEndAttribute:"max",condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(!isc.isA.Date(_3))return false;var _4=_2.min,_5=_2.max;if(_4!=null&&!isc.isA.Date(_4)){if(isc.isA.String(_4)&&_4.contains(":")){var _6=_4.split(":"),_7=_6[0]||0,_8=_6[1]||0,_9=_6[2]||0,_10=_6[3]||0;_4=_2.min=new Date(0,0,0,_7,_8,_9,_10)}else{_4=_2.min=isc.DateUtil.parseSchemaDate(_4)}}
if(_5!=null&&!isc.isA.Date(_5)){if(isc.isA.String(_5)&&_5.contains(":")){var _6=_5.split(":"),_7=_6[0]||0,_8=_6[1]||0,_9=_6[2]||0,_10=_6[3]||0;_5=_2.max=new Date(0,0,0,_7,_8,_9,_10)}else{_5=_2.max=isc.DateUtil.parseSchemaDate(_5)}}
_2.dynamicErrorMessageArguments={validator:_2,max:_5,min:_4};_4.setFullYear(_3.getFullYear());_4.setMonth(_3.getMonth());_4.setDate(_3.getDate());_5.setFullYear(_3.getFullYear());_5.setMonth(_3.getMonth());_5.setDate(_3.getDate());if(isc.isA.Date(_4)&&((!_2.exclusive&&_3<_4)||(_2.exclusive&&_3<=_4)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeLaterThanTime}
return false}
if(isc.isA.Date(_5)&&((!_2.exclusive&&_3>_5)||(_2.exclusive&&_3>=_5)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeEarlierThanTime}
return false}
return true}},floatLimit:{type:"floatLimit",valueType:"custom",dataType:"float",condition:function(_1,_2,_3){var _4;if(_2.precision!=null){if(_2.roundToPrecision==null)_2.roundToPrecision=true;if(!isc.Validator.processValidator(_1,_2,_3,"floatPrecision"))
return false;if(_2.resultingValue!=null)
_3=_4=_2.resultingValue}
if(_2.min!=null||_2.max!=null){if(!isc.Validator.processValidator(_1,_2,_3,"floatRange")){return false}else{if(_4!=null&&_2.resultingValue==null&&_2.roundToPrecision)
_2.resultingValue=_4}}
return true}},floatRange:{type:"floatRange",title:"Value in range",description:"Value is a floating point number within the specified range",valueType:"custom",dataType:"float",editorType:"FloatRangeEditor",getAttributesFromEditor:function(_1,_2){var _3=_2.canvas;return _3.getValues()},setEditorAttributes:function(_1,_2,_3){var _4=_2.canvas;if(_3==null){_4.clearValues();return}
_4.setValue("min",_3.min);_4.setValue("max",_3.max);_4.setValue("exclusive",!!_3.exclusive)},condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(isc.isA.String(_3)){_3=_3.trim();if(_3.length==0){return true}}
if(isNaN(_3))return true;var _4;if(isc.isA.Number(_3)){_4=_3}else{_4=parseFloat(_3)}
if(_1&&isc.booleanValue(_1.stringInBrowser)===true&&isc.isA.String(_3)){return true}
_2.dynamicErrorMessageArguments={validator:_2,max:_2.max,min:_2.min}
var _5,_6;if(_2.max!=null){_5=isc.isA.Number(_2.max)?_2.max:parseFloat(_2.max)}
if(_2.min!=null){_6=isc.isA.Number(_2.min)?_2.min:parseFloat(_2.min)}
if(_1&&isc.booleanValue(_1.stringInBrowser,true)!==false&&isc.isA.String(_3)&&!(_3==_4.toString())){var _7=isc.BigDecimal.create(_3);if(isc.isA.Number(_5)&&((!_2.exclusive&&_7.compareTo(_5)>0)||(_2.exclusive&&_7.compareTo(_5)>=0)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeLessThan}
return false}
if(isc.isA.Number(_6)&&((!_2.exclusive&&_7.compareTo(_6)<0)||(_2.exclusive&&_7.compareTo(_6)<=0)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeGreaterThan}
return false}
return true}
if(isc.isA.Number(_5)&&(_4>Number.MAX_VALUE||_4==Number.POSITIVE_INFINITY||(!_2.exclusive&&_4>_5)||(_2.exclusive&&_4>=_5)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeLessThan}
return false}
if(isc.isA.Number(_6)&&(_4<-Number.MAX_VALUE||_4==Number.NEGATIVE_INFINITY||(!_2.exclusive&&_4<_6)||(_2.exclusive&&_4<=_6)))
{if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.mustBeGreaterThan}
return false}
return true}},floatPrecision:{type:"floatPrecision",title:"Floating point number precision check",description:"Value is a floating point number specified to the appropriate precision",valueType:"custom",dataType:"float",editorType:"FloatPrecisionEditor",getAttributesFromEditor:function(_1,_2){var _3=_2.canvas;return _3.getValues()},setEditorAttributes:function(_1,_2,_3){var _4=_2.canvas;if(_3==null){_4.clearValues();return}
_4.setValue("precision",_3.precision);_4.setValue("roundToPrecision",_3.roundToPrecision)},condition:function(_1,_2,_3){if(_3==null||isc.is.emptyString(_3))return true;if(isc.isA.String(_3)){_3=_3.trim();if(_3.length==0){return false}}
if(isNaN(_3))return false;var _4=parseFloat(_3);if(_1&&isc.booleanValue(_1.stringInBrowser)===true&&isc.isA.String(_3)){return true}
if(_1&&isc.booleanValue(_1.stringInBrowser,true)!==false){var _5=!(_3==_4.toString());if(isc.isA.String(_3)&&_5){var r=new RegExp('^([+|-](?=\\d|(?:\\.(?=\\d))))?(\\d*)(\\.(?=\\d)\\d*)?(?:e([+|-])?(\\d+))?','i');var _7=r.exec(_3);if(_7[2]==null)_7[2]='';_7[2]=_7[2].replace(/^0+/,'');if(_7[3]==null)_7[3]='';if(_7[3].indexOf('.')==0)_7[3]=_7[3].substring(1);_7[3]=_7[3].replace(/0+$/,'');var _8=_7[2]+_7[3];if(_8.length<=16){var _8=_7[2]+_7[3]+'0000000000000000';_8=_8.substring(0,16);var _9=r.exec(_4.toExponential(16));if(_9[2]==null)_9[2]='';_9[2]=_9[2].replace(/^0+/,'');if(_9[3]==null)_9[3]='';if(_9[3].indexOf('.')==0)_9[3]=_9[3].substring(1);var _10=_9[2]+_9[3]+'0000000000000000';_10=_8.substring(0,16);_5=!(_8==_10)}else{_5=true}}
if(isc.isA.String(_3)&&_5){return true}}
if(isc.isA.Number(_2.precision)){var _11=Math.pow(10,_2.precision);var _12=(Math.round(_4*_11))/_11;if(_2.roundToPrecision){_2.resultingValue=_12;return true}else{return(_4==_12)}}}},requiredIf:{type:"requiredIf",description:"Conditionally required field",valueType:"fieldType",dataType:"none",valueAttribute:"expression",editorType:"TextAreaItem",condition:function(_1,_2,_3,_4){if(_2.expression!=null&&!isc.isA.Function(_2.expression)){isc.Func.replaceWithMethod(_2,"expression","item,validator,value,record")}
var _5=_2.expression(_1,_2,_3,_4);var _6,_7,_8;if(_5&&(_6=isc.Validator.$1610(_1))!=null&&(_7=_6.getFocusElement())!=null&&(_8=_7.files)!=null)
{if(!_2.errorMessage){_2.errorMessage=isc.Validator.requiredFile}
var _9=_8.length;for(var i=0;i<_9;++i){var _11=_8[i],_12=_11.size||_11.fileSize;if(_12>0)return true}
return false}else{if(!_2.errorMessage){_2.errorMessage=isc.Validator.requiredField}
return!_5||(_3!=null&&!isc.isAn.emptyString(_3))}}},isOneOf:{type:"isOneOf",title:"Value in list",description:"Is one of list",valueType:"valueSet",dataType:"none",valueAttribute:"list",editorTitle:"Values",condition:function(_1,_2,_3,_4){if(_3==null||isc.is.emptyString(_3))return true;var _5=_2.list||(_1?(_1.getValueMap?_1.getValueMap():_1.valueMap):null),_6=_5;if(!isc.isAn.Array(_5)&&isc.isAn.Object(_5)){_6=isc.getKeys(_5)}
if(_6!=null){for(var i=0,_8=_6.length;i<_8;i++){if(_6[i]==_3)return true}}else{isc.Log.logWarn("isOneOf validator specified with no specified list of options or valueMap - validator will always fail. Field definition:"+isc.Log.echo(_1),"validation")}
if(!_2.errorMessage){_2.defaultErrorMessage=isc.Validator.notOneOf}
return false}},required:{type:"required",title:"Required",description:"Required field",valueType:"none",dataType:"none",condition:function(_1,_2,_3,_4){var _5=isc.Validator.$1610(_1),_6,_7;if(_5!=null&&(_6=_5.getFocusElement())!=null&&(_7=_6.files)!=null)
{if(!_2.errorMessage){_2.errorMessage=isc.Validator.requiredFile}
var _8=_7.length;for(var i=0;i<_8;++i){var _10=_7[i],_11=_10.size||_10.fileSize;if(_11>0)return true}
return false}else{if(!_2.errorMessage){_2.errorMessage=isc.Validator.requiredField}
var _12=(_3!=null&&!isc.is.emptyString(_3));if(_12&&_1&&_1.multiple){if(isc.isAn.Array(_3)&&_3.isEmpty())_12=false}
return _12}},action:function(_1,_2,_3,_4,_5){if(_2&&!_2.required){_2.$11m=(_1!=null)}}},matchesField:{type:"matchesField",title:"Match another field",description:"Matches another field value",valueType:"fieldName",dataType:"none",valueAttribute:"otherField",editorTitle:"Field Name",condition:function(_1,_2,_3,_4){if(_2.otherField==null){isc.logWarn("matchesField validator is missing 'otherField' definition. Validator forced false.");return false}
var _5;if(isc.isA.String(_2.otherField)){_5=_2.otherField}else{_5=_2.otherField.dataPath||_2.otherField.name}
var _6=(isc.DataSource!=null?isc.DataSource.getPathValue(_4,_5,_2.otherField):_4[_5]);return(_3==_6)},getDependentFields:function(_1,_2){if(!_1.otherField||_1.otherField=="")return _1.fieldName;return[_1.fieldName,_1.otherField]}},isUnique:{type:"isUnique",valueType:"none",dataType:"none",title:"Value is unique",description:"Validate field value is unique on DataSource",requiresServer:true},hasRelatedRecord:{type:"hasRelatedRecord",valueType:"none",dataType:"none",title:"Value exists on related DataSource",description:"Validate field value exists on the related DataSource",requiresServer:true},serverCustom:{type:"serverCustom",valueType:"none",dataType:"none",description:"Validate field value using a custom server expression",requiresServer:true},maxFileSize:{type:"maxFileSize",description:"Size of file to be uploaded does not exceed maxFileSize",valueType:"custom",dataType:"binary",condition:function(_1,_2,_3,_4){if(!_2.errorMessage)_2.defaultErrorMessage=isc.Validator.maxFileSizeExceeded;_2.dynamicErrorMessageArguments=null;var _5=_2.maxFileSize;if(_5==null){isc.logWarn("maxFileSize validator specified with no maxFileSize. Field definition:"+isc.Log.echo(_1),"validation");return false}
var _6=isc.Validator.$1610(_1);if(_6==null){isc.logWarn("maxFileSize validator supported on UploadItem and FileItem only. Field definition:"+isc.Log.echo(_1),"validation");return false}
var _7=_6.getFocusElement();if(_7==null)return true;var _8=_7.files,_9;if(_8==null||(_9=_8.length)==0)return true;for(var i=0;i<_9;++i){var _11=_8[i];var _12=_11.size||_11.fileSize;if(_12==null)continue;if(_12>=_5){var _13=_11.webkitRelativePath||_11.name||_11.fileName;_2.dynamicErrorMessageArguments={uploadedFileName:String(_13).asHTML(),uploadedFileSize:_12,maxFileSize:_5};return false}}
return true}},message:{type:"message",title:"Display message",description:"Displays an informational or warning message",valueType:"none",dataType:"none",isRule:true,supportedTargets:["FormItem"],action:function(_1,_2,_3,_4,_5){var _6=_3.displayMode,_7=(_3.message==null?"errorMessage":"message"),_8=isc.Validator.getErrorMessage(_3,_7);if(_6=="form"){if(!_5.addFieldErrors){return}
if(_1==true){_5.addFieldErrors(_2.name,_8,true)}else{_5.setFieldErrors(_2.name,null,true)}}else if(_6=="transient"){if(_1==true){var _9=function(){if(_5&&_5.hasFocus)_5.blur();isc.showFadingPrompt(_8,_3.duration)};isc.Page.setEvent("idle",_9,isc.Page.FIRE_ONCE)}}else{var _10=_3.severity;if(_1==true){var _9=function(){if(_5&&_5.hasFocus)_5.blur();if(_10=="warning"){isc.warn(_8)}else{isc.say(_8)}};isc.Page.setEvent("idle",_9,isc.Page.FIRE_ONCE)}}}},populate:{type:"populate",title:"Populate value",description:"Populates a target field with a value calculated based on values in other fields",valueType:"custom",dataType:"none",editorType:"PopulateRuleEditor",getAttributesFromEditor:function(_1,_2){return _2.getValue()},setEditorAttributes:function(_1,_2,_3){if(_3!=null&&_3.formula!=null){_2.setValue({formula:_3.formula,formulaVars:_3.formulaVars})}else{_2.clearValue()}},isRule:true,supportedTargets:["FormItem"],action:function(_1,_2,_3,_4,_5){if(_1!=true)return;if(_3.$89d==null){var _6={};_6.text=_3.formula;if(_3.allowEscapedKeys)_6.allowEscapedKeys=_3.allowEscapedKeys;var _7=[];if(_3.targetRuleScope){_3.$89d=isc.FormulaBuilder.generateRuleScopeFunction(_6,_3.targetRuleScope,_5)}else{var _8=_6.formulaVars=_3.formulaVars;for(var _9 in _8){var _10={};_10.mappingKey=_9;_10.name=_8[_9];_7.add(_10)}
_3.$89d=isc.FormulaBuilder.generateFunction(_6,_7)}}
var _11=_3.$89d(_4,_5);if(isNaN(_11)){var _12;_11=_12}
if(_2&&_2.setValue){var _13=_2.getValue(),_14=_2.$176o,_15=(_14==null),_16=(_3.autoPopulateClearedFlag!=false&&_14!=null&&_13==null&&!_2.hasFocus),_17=!_3.overwriteInvalidValue||_15||_16;if(_2.$176n){_17=true;delete _2.$176n}
if(!_17&&_2.form&&_14!=null){_17=true;if(_13!=_14){var _18={skipServerValidation:true},_19=_2.form.validateField(_2,_2.validators,_13,_2.form.getValues(),_18);_17=(_19&&!_19.valid)}}
if(_17&&_13!=_11){_2.setValue(_11);_2.$176o=_11;if(_2.form&&_2.form.rulesEngine){isc.Class.delayCall("processChanged",[_2.form,_2],0,_2.form.rulesEngine)}}}else if(_2&&_5&&_5.setValue){var _20=_2.fieldName;if(_20==null)_20=_2.dataPath;var _13=_5.getValue(_20);if(_13!=_11){_5.setValue(_20,_11)}}},getDependentFields:function(_1,_2){if(_1.formulaVars==null||!isc.isAn.Object(_1.formulaVars))return null;var _3=[];for(var _4 in _1.formulaVars){_3.add(_1.formulaVars[_4])}
return _3}},populateText:{type:"populateText",title:"Populate text value",description:"Populates a target field with a text value formatted from values in other fields",valueType:"custom",dataType:"none",editorType:"PopulateTextRuleEditor",getAttributesFromEditor:function(_1,_2){return _2.getValue()},setEditorAttributes:function(_1,_2,_3){if(_3!=null&&_3.formula!=null){_2.setValue({formula:_3.formula,formulaVars:_3.formulaVars})}else{_2.clearValue()}},isRule:true,supportedTargets:["FormItem"],action:function(_1,_2,_3,_4,_5){if(_1!=true)return;if(_3.$176p==null){if(_3.formulaVars&&_3.formulaVars.length==0)_3.formulaVars=null;var _6={};var _7=_6.summaryVars=_3.formulaVars;_6.text=_3.formula;if(_3.targetRuleScope){_3.$176p=isc.SummaryBuilder.generateRuleScopeFunction(_6,_3.targetRuleScope,_5)}else{var _8=[];for(var _9 in _7){var _10={};_10.mappingKey=_9;_10.name=_7[_9];_8.add(_10)}
_3.$176p=isc.SummaryBuilder.generateFunction(_6,_8,null,true)}}
var _11=_3.$176p(_4,_2.name,_5);if(_2.setValue){var _12=_2.getValue(),_13=_2.$176o,_14=(_13==null),_15=(_3.autoPopulateClearedFlag!=false&&_13!=null&&_12==null&&!_2.hasFocus),_16=!_3.overwriteInvalidValue||_14||_15;if(_2.$176n){_16=true;delete _2.$176n}
if(!_16&&_2.form&&_13!=null){_16=true;if(_12!=_13){var _17={skipServerValidation:true},_18=_2.form.validateField(_2,_2.validators,_12,_2.form.getValues(),_17);_16=(_18&&!_18.valid)}}
if(_16&&_12!=_11){_2.setValue(_11);_2.$176o=_11;if(_2.form&&_2.form.rulesEngine){isc.Class.delayCall("processChanged",[_2.form,_2],0,_2.form.rulesEngine)}}}else if(_5&&_5.setValue){var _19=_2.fieldName;if(_19==null)_19=_2.dataPath;var _12=_5.getValue(_19);if(_12!=_11){_5.setValue(_19,_11)}}},getDependentFields:function(_1,_2){if(_1.formulaVars==null||!isc.isAn.Object(_1.formulaVars)||isc.isAn.emptyArray(_1.formulaVars))return null;var _3=[];for(var _4 in _1.formulaVars){_3.add(_1.formulaVars[_4])}
return _3}},populateExpression:{type:"populateExpression",title:"Populate expression",description:"Populates a target field with a value calculated based on values in other fields",valueType:"custom",dataType:"none",editorType:"PopulateRuleEditor",getAttributesFromEditor:function(_1,_2){return _2.getValue()},setEditorAttributes:function(_1,_2,_3){if(_3!=null&&_3.formula!=null){_2.setValue({formula:_3.formula,formulaVars:_3.formulaVars})}else{_2.clearValue()}},isRule:true,supportedTargets:["FormItem"],action:function(_1,_2,_3,_4,_5){if(_1!=true)return;if(_3.$89d==null){var _6={allowEscapedKeys:true};_6.text=_3.formula;var _7=[];if(_3.targetRuleScope){_3.$89d=isc.FormulaBuilder.generateRuleScopeFunction(_6,_3.targetRuleScope,_5)}else{var _8=_6.formulaVars=_3.formulaVars;for(var _9 in _8){var _10={};_10.mappingKey=_9;_10.name=_8[_9];_7.add(_10)}
_3.$89d=isc.FormulaBuilder.generateFunction(_6,_7)}}
var _11=function(_22,_23,_24){return _22=="date"?(isc.DateUtil.compareDates(_23,_24)==0):(_23==_24)};var _12=_3.$89d(_4,_5);if(_2.setValue){var _13=_2.type||_2.defaultType,_14=_2.getValue(),_15=_2.$176o,_16=(_15==null),_17=(_3.autoPopulateClearedFlag!=false&&_15!=null&&_14==null&&!_2.hasFocus),_18=!_3.overwriteInvalidValue||_16||_17;if(_2.$176n){_18=true;delete _2.$176n}
if(!_18&&_2.form&&_15!=null){_18=true;if(!_11(_13,_14,_15)){var _19={skipServerValidation:true},_20=_2.form.validateField(_2,_2.validators,_14,_2.form.getValues(),_19);_18=(_20&&!_20.valid)}}
if(_18&&!_11(_13,_14,_12)){_2.setValue(_12);_2.$176o=_12;if(_2.form&&_2.form.rulesEngine){isc.Class.delayCall("processChanged",[_2.form,_2],0,_2.form.rulesEngine)}}}else if(_5&&_5.setValue){var _21=_2.fieldName;if(_21==null)_21=_2.dataPath;var _14=_5.getValue(_21);if(_14!=_12){_5.setValue(_21,_12)}}},getDependentFields:function(_1,_2){if(_1.formulaVars==null||!isc.isAn.Object(_1.formulaVars))return null;var _3=[];for(var _4 in _1.formulaVars){_3.add(_1.formulaVars[_4])}
return _3}},setRequired:{type:"setRequired",title:"Set required",description:"Set field required state",valueType:"none",dataType:"none",isRule:true,supportedTargets:["FormItem"],action:function(_1,_2,_3,_4,_5){var _6=!!_1;var _7=_2;if(!_7.setRequired&&_5.getItem){_7=_5.getItem(_2.name||_2.dataPath)}
if(_7&&_7.setRequired){_7.setRequired(_6)}else{_2.required=_6}}},readOnly:{type:"readOnly",valueType:"custom",dataType:"none",editorType:"ReadOnlyRuleEditor",valueAttribute:"fieldAppearance",title:"Set read-only appearance",description:"Set field read-only state/appearance",isRule:true,supportedTargets:["FormItem","Canvas","Section"],action:function(_1,_2,_3,_4,_5,_6){if(_2.editingOn)_1=false;if(_3.fieldAppearance==isc.Validator.HIDDEN){if(_1==true){if(_5==null){if(_2.hide)_2.hide()}else{if(_6=="Section"){_5.hideSection(_2)}else if(_6=="FormItem"){_5.hideItem(_2)}}}else{if(_5==null){if(_2.show)_2.show()}else{if(_6=="Section"){_5.showSection(_2)}else{_5.showField(_2)}}}}else if(_3.fieldAppearance==isc.Validator.DISABLED){if(_1==true){if(_5==null){_2.disable()}else{if(_6=="Section"){_2.disable();if(_2.items){for(var i=0;i<_2.items.length;i++){_2.items[i].disable()}}}else{_5.disableField(_2)}}}else{if(_5==null){_2.enable()}else{if(_6=="Section"){_2.enable();if(_2.items){for(var i=0;i<_2.items.length;i++){_2.items[i].enable()}}}else{_5.enableField(_2)}}}}else{if(_6!="FormItem"){isc.logWarn("ReadOnly rule with fieldAppearance set to '"+_3.fieldAppearance+"' not supported for specified locator:"+_3.locator)}
if(_1==true)_5.setFieldCanEdit(_2.name,false);else _5.setFieldCanEdit(_2.name,true)}}},visibility:{type:"visibility",valueType:"custom",dataType:"none",title:"Set visibility",description:"Set field visibility",isRule:true,supportedTargets:["FormItem","FormItemIcon","Canvas","Section"],action:function(_1,_2,_3,_4,_5,_6){if(_2.editingOn)_1=true;if(_1==true){if(_5==null){if(_2.show)_2.show()}else{if(_6=="Section"){_5.showSection(_2)}else if(_6=="FormItemIcon"){_5.showIcon(_2)}else{_5.showField(_2)}}}else{if(_5==null){if(_2.hide)_2.hide()}else{if(_6=="Section"){_5.hideSection(_2)}else if(_6=="FormItemIcon"){_5.hideIcon(_2)}else if(_6=="FormItem"){_5.hideItem(_2)}}}}},enable:{type:"enable",valueType:"custom",dataType:"none",title:"Enable/disable",description:"Enable/disable field",isRule:true,supportedTargets:["FormItem","FormItemIcon","Canvas","Section","MenuItem"],action:function(_1,_2,_3,_4,_5,_6){if(_1==true){if(_5==null){_2.enable()}else{if(_6=="Section"){_2.enable();if(_2.items){for(var i=0;i<_2.items.length;i++){_2.items[i].enable()}}}else if(_6=="FormItemIcon"){_5.setIconDisabled(_2,false)}else if(_6=="MenuItem"){_5.setItemEnabled(_2)}else{_5.enableField(_2)}}}else{if(_5==null){_2.disable()}else{if(_6=="Section"){_2.disable();if(_2.items){for(var i=0;i<_2.items.length;i++){_2.items[i].disable()}}}else if(_6=="FormItemIcon"){_5.setIconDisabled(_2,true)}else if(_6=="MenuItem"){_5.setItemEnabled(_2,false)}else{_5.disableField(_2)}}}}}};isc.A.$93n=false;isc.B.push(isc.A.$1610=function isc_c_Validator__getUploadItem(_1){if(!isc.isAn.UploadItem||!(isc.isAn.UploadItem(_1)||(isc.isA.FileItem&&isc.isA.FileItem(_1)&&isc.isAn.UploadItem(_1.uploadItem))))
{return null}
var _2=_1;if(isc.isA.FileItem&&isc.isA.FileItem(_1)){_2=_1.uploadItem}
return _2});isc.evalBoundary;isc.B.push();isc.B._maxIndex=isc.C+1;isc.A=isc.Validator;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.create=function isc_c_Validator_create(_1,_2,_3,_4,_5,_6,_7,_8,_9,_10,_11,_12,_13){this.logWarn("A Validator shouldn't be created directly. Instead pass properties as each Validator in a FormItem's validators property or wherever a Validator is needed.");return isc.addProperties({},_1,_2,_3,_4,_5,_6,_7,_8,_9,_10,_11,_12,_13)},isc.A.getValidatorType=function isc_c_Validator_getValidatorType(_1){var _2=_1.type;if(_2==null&&_1._constructor)_2=_1._constructor;return _2},isc.A.isServerValidator=function isc_c_Validator_isServerValidator(_1){if(_1.serverOnly)return true;var _2=this.$74u[this.getValidatorType(_1)];if(_2!=null&&_2.requiresServer)return true;return false},isc.A.processValidator=function isc_c_Validator_processValidator(_1,_2,_3,_4,_5){if(_2.serverOnly)return true;if(_4==null)_4=isc.Validator.getValidatorType(_2);var _6=true;var _7;if(_4!=null)_7=this.$74u[_4];if(_2.isRule||(_7&&_7.isRule)){return true}
var _8;if(_7==null){if(_2.condition){if(!isc.isA.Function(_2.condition)){this.logDebug("Creating function for validation condition:\r"+_2.condition);isc.Func.replaceWithMethod(_2,"condition","item,validator,value,record")}
_8=_2.condition}}else{if(_7.requiresServer==true){return true}
_8=_7.condition;if(!_2.errorMessage){_2.defaultErrorMessage=_7.defaultErrorMessage}}
if(_8!=null){var _9=_2.validateEachItem;if(_9==null&&_1)_9=_1.validateEachItem;if(_1&&_1.multiple&&_9&&isc.isAn.Array(_3)){var _10=[];for(var i=0;i<_3.length;i++){delete _2.resultingValue;_6=_6&&_8(_1,_2,_3[i],_5);_10[i]=(_2.resultingValue!=null?_2.resultingValue:_3[i])}
_2.resultingValue=_10}else{delete _2.resultingValue;_6=_8(_1,_2,_3,_5)}}else{this.logWarn("validator not understood on item: "+isc.echo(_1)+":\r"+isc.echoFull(_2))}
return _6},isc.A.performAction=function isc_c_Validator_performAction(_1,_2,_3,_4,_5,_6){var _7=this.getValidatorType(_3);var _8;if(_7!=null)_8=this.$74u[_7];if(_6==null)_6="FormItem";var _9=_3.isRule,_10=_3.supportedTargets;var _11;if(_8!=null){_11=_8.action;if(_9==null)_9=_8.isRule;if(_9&&_10==null){_10=_8.supportedTargets||["FormItem"]}}
if(_9&&!_10.contains(_6)){this.logWarn("Rule of type:"+_7+" called for target object "+_2+", of type:"+_6+". This is not a valid target for this rule. Ignoring.")}
if(_11==null&&_3.action){if(!isc.isA.Function(_3.action)){this.logDebug("Creating function for validation action:\r"+_3.action);isc.Func.replaceWithMethod(_3,"action","result,item,validator,record,component,targetObjectType")}
_11=_3.action}
if(_11!=null){_11(_1,_2,_3,_4,_5,_6)}},isc.A.getErrorMessage=function isc_c_Validator_getErrorMessage(_1,_2){var _3=_2?_1[_2]:_1.errorMessage;if(_3==null)_3=_1.defaultErrorMessage;if(_3&&_1.dynamicErrorMessageArguments){_3=_3.evalDynamicString(null,_1.dynamicErrorMessageArguments)}
return _3},isc.A.getShortName=function isc_c_Validator_getShortName(_1){var _2=(this.$179e?this.$179e[_1]:null);if(!_2){_2=isc.DS.getAutoTitle(_1);if(!this.$179e)this.$179e={};this.$179e[_1]=_2}
return _2},isc.A.addValidator=function isc_c_Validator_addValidator(_1,_2){if(isc.isA.String(_1)){var _3={};_3[_1]=_2;return this.addValidators(_3)}},isc.A.addValidators=function isc_c_Validator_addValidators(_1){for(var _2 in _1){var _3={};_3.type=_2;_3.condition=_1[_2];if(!isc.isA.Function(_3.condition)){isc.Func.replaceWithMethod(_3,"condition","item,validator,value")}
_1[_2]=_3}
this.addValidatorDefinitions(_1)},isc.A.addValidatorDefinition=function isc_c_Validator_addValidatorDefinition(_1,_2){if(!isc.isAn.Object(_2)){isc.logWarn("Invalid validator in call to addValidatorDefinition. Ignored.")}
var _3={};_3[_1]=_2;return this.addValidatorDefinitions(_3)},isc.A.addValidatorDefinitions=function isc_c_Validator_addValidatorDefinitions(_1){if(!_1||!isc.isAn.Object(_1))return;for(var _2 in _1){if(this.$74u[_2]){isc.logWarn("addValidatorDefinitions: Validator definition already exists for type "+_2+". Replacing.")}}
isc.addProperties(this.$74u,_1)},isc.A.getValidatorDefinition=function isc_c_Validator_getValidatorDefinition(_1){return this.$74u[_1]});isc.B._maxIndex=isc.C+12;isc.Validator.addValidatorDefinition("regex",isc.Validator.getValidatorDefinition("regexp"));isc.ClassFactory.defineClass("ContainerItem","FormItem");isc.A=isc.ContainerItem.getPrototype();isc.A.cellSpacing=0;isc.A.cellPadding=2;isc.A.cellBorder=0;isc.A.recalculateItemsOnRedraw=false;isc.A.$125=false;isc.A.changeOnKeypress=false;isc.ContainerItem.addMethods(isc.applyMask(isc.DynamicForm.getPrototype(),["getTableStartHTML","$174w","$11n","$11o","getCellStartHTML","$11g","getCellEndHTML","$11h","getTitleAlign","getItemPromptHTML","getTitleCellHTML","$11i","$427","isRTL","getItem","fieldIdProperty"]))
isc.A=isc.ContainerItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$63z="$428";isc.A.writeOutLabelTag=true;isc.A.$9z="<br>";isc.B.push(isc.A.init=function isc_ContainerItem_init(){this.Super("init",arguments);this.setItems(this.items?this.items:null)},isc.A.destroy=function isc_ContainerItem_destroy(){if(this.items){for(var i=0;i<this.items.length;i++){this.items[i].destroy()}}
this.Super("destroy",arguments)},isc.A.setItems=function isc_ContainerItem_setItems(_1){var _2=this.items?this.items:null;if(_1)this.items=_1;else _1=this.items;if(!this.items)return null;this.logDebug("Creating "+this.items.length+" contained items");var _3=false;for(var _4=0;_4<_1.length;_4++){var _5=_1[_4];if(!_5){_1.removeItem(_4--);continue}
isc.addMethods(_5,{handleKeyPress:function(){var _6=this.Super("handleKeyPress",arguments);if(_6==false)return false;return true}});_5.containerWidget=this.containerWidget;_5.parentItem=this;_5.eventParent=this;_5.form=this.form;_5.showTitle=_5.showTitle!=null?_5.showTitle:false;if(!isc.isA.FormItem(_5))_1[_4]=_5=isc.FormItemFactory.makeItem(_5);if(this.accessKey!=null&&!_3&&_5.$kk()){_5.accessKey=this.accessKey;_3=true}
if(_5.name!=null)this[_5.name]=_5}
if(this.isDrawn()){if(_2&&_2!=this.items){if(this.$60r==null)this.$60r={};for(var i=0;i<_2.length;i++){var _8=_2[i];if(!_1.contains(_2[i])){this.$60r[_2[i].getID()]=_2[i]}}}}
this.assignItemsTabPosition();this.redraw()},isc.A.syntheticShiftFocus=function isc_ContainerItem_syntheticShiftFocus(_1){return false},isc.A.$184c=function isc_ContainerItem__getCurrentFocusTargetID(){var _1=this.form&&this.form.$10n;if(_1!=null){var _2=_1,_3=false;while(_2.parentItem!=null){if(_2.parentItem==this){_3=true;break}
_2=_2.parentItem}
if(_3)return _2.$184c()}
return this.Super("$184c",arguments)},isc.A.assignItemsTabPosition=function isc_ContainerItem_assignItemsTabPosition(){var _1=this.items;if(!_1||_1.length==0)return;var _2=this.sortItemsIntoTabOrder();for(var i=0,_4=0;i<_2.length;i++){var _5=_2[i];if(_5==null)continue;isc.TabIndexManager.moveTarget(_5.ID,this.ID,_4);_4++}},isc.A.sortItemsIntoTabOrder=function isc_ContainerItem_sortItemsIntoTabOrder(){return isc.DynamicForm.sortItemsIntoTabOrder(this.items,this)},isc.A.getPickerIconTabPosition=function isc_ContainerItem_getPickerIconTabPosition(){return this.items?this.items.length:0},isc.A.getIconTabPosition=function isc_ContainerItem_getIconTabPosition(_1){var _2=this.items?this.items.length:0;return this.Super("getIconTabPosition",arguments)+_2},isc.A.getItems=function isc_ContainerItem_getItems(){return this.items},isc.A.handleKeyPress=function isc_ContainerItem_handleKeyPress(){var _1=this.Super("handleKeyPress",arguments);if(_1==false||_1==isc.EH.STOP_BUBBLING)return _1;var _2=isc.EH.lastEvent.keyTarget;if(_2&&_2!=this){if(_2.shouldStopKeyPressBubbling(isc.EH.getKey(),isc.EH.characterValue)){return isc.EH.STOP_BUBBLING}}
return _1},isc.A.getTitleHTML=function isc_ContainerItem_getTitleHTML(){var _1,_2;var _3=this.getTitle();if(!this.writeOutLabelTag||!this.getCanFocus()){return _3}
if(this.accessKey!=null){_3=isc.Canvas.hiliteCharacter(_3,this.accessKey)}
for(var i=0;i<this.items.length;i++){if(this.items[i].getCanFocus()&&this.items[i].hasDataElement()){_2=this.items[i];break}}
if(!_2){return _3}
return isc.SB.concat("<LABEL FOR=",_2.getDataElementId(),">",_3,"</LABEL>")},isc.A.$173=function isc_ContainerItem__setElementTabIndex(_1){if(!this.isVisible()||!this.containerWidget.isDrawn())return;for(var i=0;i<this.items.length;i++){if(this.items[i].$kk())this.items[i].$173(_1)}
if(!this.form.isDirty()){this.$175()}},isc.A.isEditable=function isc_ContainerItem_isEditable(){return false},isc.A.$kk=function isc_ContainerItem__canFocus(){if(!this.items)return false;for(var i=0;i<this.items.length;i++){if(this.items[i].$kk())return true}
return false},isc.A.focusInItem=function isc_ContainerItem_focusInItem(){if(!this.isVisible()||!this.$kk())return;for(var i=0;i<this.items.length;i++){if(this.items[i].$kk()){this.items[i].focusInItem();break}}},isc.A.blurItem=function isc_ContainerItem_blurItem(){for(var i=0;i<this.items.length;i++){if(this.items[i].hasFocus){this.items[i].blurItem();break}}},isc.A.$159=function isc_ContainerItem__applyHandlersToElement(){this.$16c()},isc.A.drawing=function isc_ContainerItem_drawing(_1){this.Super("drawing",arguments);var _2=this.items;if(!_2)return;for(var i=0;i<_2.length;i++){if(_2[i].visible!=false)_2[i].drawing(_1)}},isc.A.drawn=function isc_ContainerItem_drawn(){var _1=this.items;if(!_1)return;for(var i=0;i<_1.length;i++){if(_1[i].visible!=false)_1[i].drawn()}
return this.Super("drawn",arguments)},isc.A.redrawing=function isc_ContainerItem_redrawing(){this.Super("redrawing",arguments);var _1=this.items;if(!_1)return;for(var i=0;i<_1.length;i++){var _3=_1[i];if(_3.visible!=false){if(!_3.isDrawn())_3.drawing();else _3.redrawing()}else{if(_3.isDrawn())_3.clearing}}},isc.A.redrawn=function isc_ContainerItem_redrawn(){var _1=this.items;if(!_1)return;for(var i=0;i<_1.length;i++){var _3=_1[i];if(_3.visible!=false){if(!_3.isDrawn())_3.drawn();else _3.redrawn()}else{if(_3.isDrawn())_3.cleared()}}
this.notifyRemovedItems();return this.Super("redrawn",arguments)},isc.A.clearing=function isc_ContainerItem_clearing(_1){this.Super("clearing",arguments);var _2=this.items;if(!_2)return;for(var i=0;i<_2.length;i++){if(_2[i].isDrawn())_2[i].clearing(_1)}},isc.A.cleared=function isc_ContainerItem_cleared(){var _1=this.items;if(!_1)return;for(var i=0;i<_1.length;i++){if(_1[i].isDrawn())_1[i].cleared()}
this.notifyRemovedItems();return this.Super("cleared",arguments)},isc.A.notifyRemovedItems=function isc_ContainerItem_notifyRemovedItems(){if(this.$60r==null)return;for(var _1 in this.$60r){var _2=this.$60r[_1];if(this.items.contains(_2))continue;if(_2.destroyed||_2.destroying)continue;_2.cleared()}},isc.A.makeNamedItem=function isc_ContainerItem_makeNamedItem(_1,_2){if(!this.itemCache)this.itemCache={};var _3=this.itemCache[_1];if(!_3){_3=(this[_1]||this.getClass()[_1]);if(_2!=null){_3=isc.addProperties({},_3,_2)}
_3=this.itemCache[_1]=isc.FormItemFactory.makeItem(_3)}
return _3},isc.A.$166d=function isc_ContainerItem__appendHintOrErrorCell(_1,_2,_3,_4,_5){var _6=" rowspan='"+_4+"' colspan='"+_5+"'",_7=this.getHint(),_8=!_1?_2:null,_9=(_7&&_8)?_7+_8:(_7||_8);if(_9&&!isc.isAn.emptyString(_9)){var _10=this.$165z(_9,_7?this.getHintStyle():null,_6);_3.append(_10);_3.append("</TD>")}},isc.A.getInnerHTML=function isc_ContainerItem_getInnerHTML(_1,_2,_3,_4){if(!_1)_1={};if(!this.items||this.recalculateItemsOnRedraw||!isc.isA.FormItem(this.items[0]))this.setItems();if(!this.items)return"No items set for containerItem "+this;var _5;if(this.isInactiveHTML()&&this.$68u==null){_5=true;this.$68u=this.setupInactiveContext(null);if(this.logIsDebugEnabled("inactiveEditorHTML")){this.logDebug("getInnerHTML(): Item is marked as inactive - set up new inactive context ID:"+this.$68u,"inactiveEditorHTML")}}
var _6=this.getErrorOrientation(),_7,_8=_6==isc.Canvas.LEFT,_9;if(_3&&(_8||_6==isc.Canvas.RIGHT))
{var _10=this.getErrors();if(_10){_7=true;_9=this.getErrorHTML(_10)}}
var _11=isc.StringBuffer.create();if(this.$11d()){_11.append(this.$15l())}
var _12=this.$8t?this.$8t[0]:null;var _13=(_12!=null)&&this.$174z();if(_13){_11.append("<div style='width:"+this.width+"px;'>")}
_11.append(this.getTableStartHTML());var _14=this.items;for(var _15=0;_15<_14.length;_15++){var _16=_14[_15];_16.$10x()
_16.form=this.form;if(_16.showIf){if(!isc.isA.Function(_16.showIf)){isc.Func.replaceWithMethod(_16,"showIf","item,value,form")}
var _17=this.getItemValue(_16,_1);var _18=(_16.showIf(_16,_17,this.form)!=false);if(_18!=_16.visible){_16.visible=_18}}}
var _19=true,_20=true,_14=this.items,_21=_14.length,_22=1,_23=1,_24=[1];for(var _15=1;_15<_21;++_15){var _16=_14[_15];if(!_16)continue;if(_16.$8l){_23=Math.max(_23,_24[_22-1]);++_22;_24[_22-1]=1}else{++_24[_22-1]}}
_23=Math.max(_23,_24[_22-1]);for(var _15=0;_15<_21;_15++){var _16=_14[_15];if(!_16)continue;if(!_16.visible)continue;var _17=this.getItemValue(_16,_1);if(_16.$8l||_19){if(!_19){if(_20&&(_2||(_7&&!_8))){this.$166d(_8,_9,_11,_22,_23-_24[0]+1)}
_20=false;_11.append("</TR>")}
_11.append("<TR>")}
if(_19&&_7&&_8){_11.append("<TD ROWSPAN=",_22,">",_9,"</TD>")}
_19=false;var _25=_16.getErrors();if(_16.titleOrientation==isc.Canvas.LEFT){_11.append(this.getTitleCellHTML(_16,_25))}
_11.append(this.getCellStartHTML(_16));if(_16.titleOrientation==isc.Canvas.TOP){_11.append(this.getTitleSpanHTML(_16,_25),this.$9z)}
_11.append(_16.getInnerHTML(_17,true));_11.append(this.getCellEndHTML(_16))}
var _26=this.$185k();if(_26||(this.showIcons&&this.icons!=null)){var _12=this.getTotalIconsWidth();if(_26)_12+=this.getPickerIconWidth();var _27=this.icons&&(_26||this.icons.length>1);_11.append(this.$11g((this.form.isRTL()?isc.Canvas.RIGHT:isc.Canvas.LEFT),null,this.getCellStyle(),1,1,_12,null,null,isc.Canvas.$42a,null,null,null,_27));_11.append(this.getIconsHTML(true));_11.append(this.$11h(_27))}
if(_20&&(_2||(_7&&!_8))){this.$166d(_8,_9,_11,_22,_23-_24[0]+1)}
_11.append("</TR></TABLE>");if(_13){_11.append("</div>")}
if(_5)delete this.$68u;return _11.release(false)},isc.A.$160=function isc_ContainerItem__resetWidths(){this.Super("$160",arguments);for(var i=0;i<this.items.length;i++){this.items[i].$160()}},isc.A.$174z=function isc_ContainerItem__writeSizingDiv(){return false},isc.A.getPickerIcon=function isc_ContainerItem_getPickerIcon(){var _1=this.Super("getPickerIcon",arguments);_1.writeIntoItem=false;return _1},isc.A.getItemValue=function isc_ContainerItem_getItemValue(_1,_2){if(_2==null)_2={};if(!isc.isA.FormItem(_1))_1=this.getItem(_1);if(!_1)return null;var _3=_1.getFieldName(),_4=null;if(_1.value!=null)_4=_1.value;if(_4==null&&_3){_4=_2[_3]}
if(_4==null){_4=_1.getValue()}
return _4},isc.A.$10v=function isc_ContainerItem__itemValueIsDirty(){if(this.items==null)return false;for(var i=0;i<this.items.length;i++){if(this.items[i].$10v())return true}
return this.$18j},isc.A.$10x=function isc_ContainerItem__markValueAsNotDirty(){this.$18j=false;for(var i=0;i<this.items.length;i++){this.items[i].$10x()}},isc.A.updateDisabled=function isc_ContainerItem_updateDisabled(_1){this.Super("updateDisabled",arguments);if(this.items){for(var i=0;i<this.items.length;i++)this.items[i].updateDisabled(_1)}},isc.A.getTextDirection=function isc_ContainerItem_getTextDirection(){return this.form.getTextDirection()},isc.A.getLeft=function isc_ContainerItem_getLeft(){var _1=this.$11o();if(_1==null){this.logWarn("getLeft() Unable to determine position for "+(this.name==null?"this item ":this.name)+". Position cannot be determined before the item is drawn - returning zero");return 0}
return this.$18k(_1)},isc.A.getTop=function isc_ContainerItem_getTop(){var _1=this.$11o();if(_1==null){this.logWarn("getTop() Unable to determine position for "+(this.name==null?"this item ":this.name)+". Position cannot be determined before the item is drawn - returning zero");return 0}
return this.$18l(_1)},isc.A.getVisibleWidth=function isc_ContainerItem_getVisibleWidth(){var _1=this.$11o();if(_1==null)return this.Super("getVisibleWidth",arguments);return _1.offsetWidth},isc.A.getVisibleHeight=function isc_ContainerItem_getVisibleHeight(){var _1=this.$11o();if(_1==null)return this.Super("getVisibleHeight",arguments);return _1.offsetHeight},isc.A.getTitleSpanHTML=function isc_ContainerItem_getTitleSpanHTML(_1,_2){var _3=isc.StringBuffer.create();_3.append("<SPAN ",this.$11i(_1)," CLASS='",_1.getTitleStyle(),"' ALIGN='",this.getTitleAlign(_1),"'>");_3.append(_1.getTitleHTML());_3.append("</SPAN>");return _3.release(false)},isc.A.$1608=function isc_ContainerItem__defaultPendingStatusChangedBehavior(_1){this.Super("$1608",arguments);this.$1609()},isc.A.$1609=function isc_ContainerItem__updatePendingStatuses(){var _1=this.$161p()&&this.pendingStatus;var _2=this.items;if(_2!=null){for(var i=0,_4=_2.length;i<_4;++i){var _5=_2[i];_5.setFixedPendingStatus(_1)}}},isc.A.$152p=function isc_ContainerItem__readOnlyDisplayChanged(_1,_2){var _3=this.items;if(_3!=null){for(var i=0,_5=_3.length;i<_5;++i){var _6=_3[i];_6.updateReadOnlyDisplay(_2)}}
this.Super("$152p",arguments)},isc.A.$152r=function isc_ContainerItem__canEditChanged(_1,_2){var _3=this.items;if(_3!=null){for(var i=0,_5=_3.length;i<_5;++i){var _6=_3[i];_6.updateCanEdit(_2)}}
this.Super("$152r",arguments)});isc.B._maxIndex=isc.C+45;isc.ClassFactory.defineClass("CanvasItem","FormItem");isc.A=isc.CanvasItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.width="*";isc.A.height=null;isc.A.shouldSaveValue=false;isc.A.autoDestroy=false;isc.B.push(isc.A.$952=function isc_CanvasItem__setElementValue(_1,_2){var _3;if(_2===_3){_2=this._value}
this.showValue(_1,_2,this.form,this)},isc.A.showValue=function isc_CanvasItem_showValue(_1,_2){},isc.A.$142r=function isc_CanvasItem__showValueAfterDraw(_1){if(_1){return}
return this.Super("$142r",arguments)},isc.A.$18v=function isc_CanvasItem__canvas_resized(_1,_2,_3){this.Super("resized",arguments);if(!this.dragResizing()&&this.canvasItem&&(this.canvasItem.canvas==this)){this.canvasItem.canvasResized(_1,_2,_3)}},isc.A.$18w=function isc_CanvasItem__canvas_dragResized(){this.canvasItem.canvasResized(1,1);return this.Super("dragResized",arguments)});isc.B._maxIndex=isc.C+5;isc.A=isc.CanvasItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.sizeCanvasAsTextBox=true;isc.A.editCriteriaInInnerForm=true;isc.A.applyPromptToCanvas=true;isc.B.push(isc.A.init=function isc_CanvasItem_init(){this.Super("init",arguments);this.$18y(this.form,this);this.canvasInitialized=true},isc.A.isEditable=function isc_CanvasItem_isEditable(){return false},isc.A.$kk=function isc_CanvasItem__canFocus(){if(this.canFocus==true)return this.canFocus;var _1=this.canvas;if(_1&&_1.$kk)return _1.$kk();return false},isc.A.getOuterElement=function isc_CanvasItem_getOuterElement(_1,_2,_3){var _4=this.$15c("spacerParent");if(_4&&_4.firstChild)_4=_4.firstChild;return _4?_4:this.invokeSuper(isc.CanvasItem,"getOuterElement",_1,_2,_3)},isc.A.$18y=function isc_CanvasItem__createCanvas(){if(this.createCanvas!=null){var _1=this.canvas;this.canvas=this.fireCallback("createCanvas","form,item",arguments);if(this.canvas==null)this.canvas=_1}
if(!isc.isAn.Object(this.canvas)&&!this.canvasProperties&&!window[this.canvas]){this.logInfo("CanvasItem: "+(this.getFieldName()?this.getFieldName():this.getID())+" defined with no canvas property - creating a default canvas for this item.")}
if(!isc.isAn.Object(this.canvas)&&isc.isA.Canvas(window[this.canvas])){this.canvas=window[this.canvas]}
var _2={_redrawWithParent:false,destroyWithParent:false};_2.resized=this.$18v;_2.dragResized=this.$18w;_2.handleClick=function(){var _3=this.Super("handleClick",arguments);if(!isc.isA.StatefulCanvas(this)&&this.canvasItem){_3=this.canvasItem.handleClick()&&_3}
return _3}
_2.handleActivate=function(){var _3=this.Super("handleActivate",arguments);if(this.canvasItem)_3=this.canvasItem.handleClick()&&_3;return _3}
_2.handleDoubleClick=function(){var _3=this.Super("handleDoubleClick",arguments);if(this.canvasItem)_3=this.canvasItem.handleDoubleClick()&&_3;return _3}
_2.handleKeyPress=function(){var _3=this.Super("handleKeyPress",arguments);if(this.canvasItem){var _4=this.canvasItem.$18d(this.canvasItem,this.canvasItem.form,isc.EH.getKey(),isc.EH.getKeyEventCharacterValue());if(_4==false)_3=false}
return _3}
_2.handleKeyDown=function(_10,_11){var _3=this.Super("handleKeyDown",arguments);if(this.canvasItem){var _4=this.canvasItem.handleKeyDown(_10,_11);if(_4==false)_3=false}
return _3}
_2.handleKeyUp=function(_10,_11){var _3;if(this.keyUp!=null){_3=this.keyUp(_10,_11)}
if(this.canvasItem){var _4=this.canvasItem.handleKeyUp(_10,_11);if(_4==false)_3=false}
return _3}
if(this.dataSource)_2.dataSource=this.dataSource;if(this.prompt&&this.applyPromptToCanvas)_2.prompt=this.prompt;if(this.overflow!=null)_2.overflow=this.overflow;if(this.accessKey!=null)_2.accessKey=this.accessKey;if(this.showFocused!=null)_2.showFocused=this.showFocused;if(this.showFocusedAsOver!=null)_2.showFocusedAsOver=this.showFocusedAsOver;if(isc.isA.String(this.canvas)&&window[this.canvas])this.canvas=window[this.canvas];if(!isc.isA.Canvas(this.canvas)){isc.addProperties(_2,this.canvas,{canvasItem:this});if(_2.ID!=null)_2.ID=null;this.autoDestroy=true;this.canvas=this.createAutoChild("canvas",_2,isc.Canvas)}else{var _5={};for(var _6 in _2){_5[_6]=this.canvas[_6]}
this.canvas.$906=_5
if(this.applyPromptToCanvas)this.canvas.setPrompt(this.prompt);this.canvas.setAccessKey(this.accessKey);isc.addProperties(this.canvas,_2,{canvasItem:this});if(_2.dataSource)this.canvas.bindToDataSource()}
if(isc.isA.DynamicForm(this.canvas)){this.canvas.setReadOnlyDisplay(this.getReadOnlyDisplay());this.canvas.setCanEdit(this.getCanEdit())}
this.canvas.setDisabled(this.shouldDisableCanvas());if(this.canvas!=null){this.canvas.$129a=this.canvas.percentBox;this.canvas.percentBox="custom"}
this.updateCanvasTabPosition();if(this.containerWidget!=this.form){if(isc.EH.clickMaskUp()){var _7=isc.EH.getAllClickMaskIDs();for(var i=_7.length-1;i>=0;i--){var _9=isc.EH.targetIsMasked(this.containerWidget,_7[i]);if(!_9){isc.EH.addUnmaskedTarget(this.canvas,_7[i]);break}}}}
if(this.canvas){this.observe(this.canvas,"$lf","observer.canvasFocusChanged()");this.observe(this.canvas,"$170y","observer.canvasChildFocusChanged()")}
if(isc.isA.DynamicForm(this.canvas)){this.observe(this.canvas,"setFocusItem","observer.nestedFormSetFocusItem()")}},isc.A.updateCanvasTabPosition=function isc_CanvasItem_updateCanvasTabPosition(){var _1=this.canvas;if(_1!=null){_1.updateTabPositionOnDraw=false;_1.updateTabPositionOnReparent=false;isc.TabIndexManager.moveTarget(_1.ID,this.ID,0);if(this.globalTabIndex!=null){this.canvas.setTabIndex(this.globalTabIndex)}}},isc.A.getPickerIconTabPosition=function isc_CanvasItem_getPickerIconTabPosition(){return this.canvas?1:0},isc.A.getIconTabPosition=function isc_CanvasItem_getIconTabPosition(_1){var _2=this.canvas?1:0;return this.Super("getIconTabPosition",arguments)+_2},isc.A.$184c=function isc_CanvasItem__getCurrentFocusTargetID(){if(isc.isA.Canvas(this.canvas)&&isc.EH.$ke!=null&&this.canvas.contains(isc.EH.$ke))
{return isc.EH.$ke.getID()}
return this.Super("$184c",arguments)},isc.A.setCanvas=function isc_CanvasItem_setCanvas(_1){if(isc.isA.Canvas(this.canvas)){if(this.canvas!=_1){this.$112n()}else{return}}
if(_1)this.canvas=_1;if(this.canvasInitialized){this.$18y();if(this.containerWidget&&this.containerWidget.isDrawn()&&this.isDrawn()){var _2=this.containerWidget;var _3=_1?_1.getParentCanvas():null;if(_1&&_3!==_2){if(_3!=null&&this.isObserving(_3,"$807")){this.ignore(_3,"$807")}
_2.addChild(_1)}
this.containerWidget.markForRedraw()}}},isc.A.$152r=function isc_CanvasItem__canEditChanged(_1,_2){var _3=this.canvas;if((this.canEditChanged==null||this.canEditChanged(_1)!=false)&&_3!=null)
{if(isc.isA.DynamicForm(_3)){_3.setCanEdit(_1)}
_3.setDisabled(this.shouldDisableCanvas())}},isc.A.$152p=function isc_CanvasItem__readOnlyDisplayChanged(_1,_2){var _3=this.canvas;if((this.readOnlyDisplayChanged==null||this.readOnlyDisplayChanged(_1)!=false)&&_3!=null)
{if(isc.isA.DynamicForm(_3)){_3.setReadOnlyDisplay(_1)}}},isc.A.drawing=function isc_CanvasItem_drawing(_1){var _2=this.canvas,_3=this.containerWidget;if(_2&&_2.destroyed){this.$18y()}
_2=this.canvas;var _4=_2?_2.getParentCanvas():null;if(_2&&_4!==_3){if(_4!=null&&this.isObserving(_4,"$807")){this.ignore(_4,"$807")}
_3.addChild(_2)}
this.Super("drawing",arguments)},isc.A.itemVisibilityChanged=function isc_CanvasItem_itemVisibilityChanged(_1){if(!_1&&this.canvas&&this.containerWidget&&!this.containerWidget.isDrawn()&&this.canvas.getParentCanvas()==this.containerWidget)
{this.canvas.deparent()}},isc.A.destroy=function isc_CanvasItem_destroy(){this.$112n();return this.Super("destroy",arguments)},isc.A.$112n=function isc_CanvasItem__destroyCanvas(){if(this.canvas){delete this.canvas.canvasItem;var _1=this.canvas.getParentCanvas();delete this.canvas.parentElement;if(_1==this.containerWidget){if(this.isObserving(this.containerWidget,"$807")){this.ignore(this.containerWidget,"$807")}
this.containerWidget.removeChild(this.canvas)}
if(this.autoDestroy){this.canvas.destroy(true)}else{isc.$1025=true;isc.addProperties(this.canvas,this.canvas.$906);delete this.canvas.$906;delete isc.$1025;if(this.canvas.isDrawn()){this.canvas.clear()}
this.canvas.deparent();this.ignore(this.canvas,"$lf");if(isc.isA.DynamicForm(this.canvas)){this.ignore(this.canvas,"setFocusItem")}
this.canvas.percentBox=this.canvas.$129a;delete this.canvas.$129a;this.canvas=null}}},isc.A.placeCanvas=function isc_CanvasItem_placeCanvas(_1){var _2=this.canvas;if(!_2)return;if(_2.destroyed)return;if(this.visible==false){return}
if(this.form&&!this.form.isDrawn()&&this.form.position==isc.Canvas.RELATIVE){_2.hide();return}
var _3=this.containerWidget;if(!_3.isVisible()){if(!this.isObserving(_3,"$807")){this.observe(_3,"$807",this.$156d)}
return}
var _4=_3.getHandle(),_5=isc.Element.get(this.getID()+"$18z");if(isc.Browser.isIE&&!isc.Browser.isStrict&&isc.Browser.version>=9){_5=_5&&_5.firstChild}
var _6=_5?isc.Element.getOffsets(_5,_4):[0,0],_7=_6[isc.Canvas.LEFT]+_3.getScrollLeft(),_8=_6[isc.Canvas.TOP]+_3.getScrollTop();if(!_3.$113l){var _9=_3.$tj();_7-=_9.left;_8-=_9.top}
var _10=_2.getParentCanvas();if(_10!==_3){if(_10!=null&&this.isObserving(_10,"$807")){this.ignore(_10,"$807")}
_3.addChild(_2)}
_2.moveTo(_7,_8);if(this.$11e()){var _11=this.getAbsDiv(true);if(_11&&_11.style){var _12=parseInt(_11.style.zIndex);if(_2.getZIndex()<_12){_2.setZIndex(_12+1)}}}
if(_2.visibility==isc.Canvas.HIDDEN){_2.show()}
if(!_2.isDrawn()){_2.draw()}
if(!_1&&isc.Browser.isMac&&isc.Browser.isMoz&&_7==0&&_8==0){isc.Timer.setTimeout({target:this,methodName:"$180"},0)}},isc.A.$180=function isc_CanvasItem__delayedPlaceCanvas(){this.placeCanvas(true)},isc.A.$156d=function isc_CanvasItem__containerWidgetVisibilityChanged(){if(this.containerWidget.isVisible())this.placeCanvas()},isc.A.cleared=function isc_CanvasItem_cleared(_1){this.Super("cleared",arguments);if(this.canvas&&this.canvas.isDrawn()){this.canvas.clear();if(_1){if(this.isObserving(this.containerWidget,"$807")){this.ignore(this.containerWidget,"$807")}
this.containerWidget.removeChild(this.canvas);this.containerWidget.$t5=true;this.containerWidget.$t6("CanvasItem canvas cleared")}}},isc.A.moved=function isc_CanvasItem_moved(){if(this.isDrawn()||(this.containerWidget!=null&&this.containerWidget.isDrawn())){this.placeCanvas()}},isc.A.checkCanvasOverflow=function isc_CanvasItem_checkCanvasOverflow(){return this.sizeCanvas(true)},isc.A.$143=function isc_CanvasItem__sizeTextBoxAsContentBox(){return false},isc.A.sizeCanvas=function isc_CanvasItem_sizeCanvas(_1){var _2=this.canvas;if(!_2)return;if(_1&&!(_2.overflow==isc.Canvas.VISIBLE||_2.overflow==isc.Canvas.CLIP_H))
{this.logDebug("ignoring first pass, can't overflow","canvasItemSizing");return}
var _3=this.getValue(),_4=this.sizeCanvasAsTextBox?this.getTextBoxWidth(_3):this.getInnerWidth(),_5=this.sizeCanvasAsTextBox?this.getTextBoxHeight(_3):this.getInnerHeight(),_6,_7;if(this.heightIncludesTitle&&this.showTitle&&this.getTitleOrientation()==isc.Canvas.TOP)
{_5-=this.form.getTitleHeight(this)}
_7=_5;var _8=_2.$pn||this.width;_6=(_8==null||_8=="*"||_8=="100%"?_4:_8);var _9=_2._percent_width,_10=_2._percent_height;var _11;if(_4!=null&&_9!=null&&_9.endsWith("%")&&!window.isNaN(_11=parseInt(_9)))
{_6=Math.round(_4*(_11/100))}
if(!_2.isDirty()&&(_6==null||_6<=_2.getVisibleWidth())&&_2.getHeight()<_2.getVisibleHeight()&&_7<=_2.getVisibleHeight())
{this.logDebug("not applying height: "+_7+" to overflowed Canvas with height: "+_2.getVisibleHeight(),"canvasItemSizing");_7=null}
if(!isc.isA.Number(_6))_6=null;if(!isc.isA.Number(_7))_7=null;this.$602(_6,_7,_9,_10);this.logDebug("this.$8t: "+this.$8t+", policy size: "+[_4,_5]+", specifiedSize: "+[_8,_2.$po||this.height]+", Resized Canvas to: "+[_6,_7],"canvasItemSizing");if(!_2.isDrawn()){var _12=this.containerWidget.getDrawnState();if(_12==isc.Canvas.COMPLETE||_12==isc.Canvas.HANDLE_DRAWN){isc.Canvas.moveOffscreen(_2);_2.draw()}}else _2.redrawIfDirty("CanvasItem getting new size");var _13=_2.getVisibleWidth(),_14=_2.getVisibleHeight();this.logDebug("visible size of embedded Canvas: "+[_13,_14],"canvasItemSizing");if(!_1)this.$168w=null;else this.$168w=_14>_2.getHeight()?_14:null;if(_14>_5)return true},isc.A.$602=function isc_CanvasItem__setCanvasSize(_1,_2,_3,_4){this.$181=true;this.canvas.resizeTo(_1,_2);if(_3!=null)this.canvas._percent_width=_3;if(_4!=null)this.canvas._percent_height=_4;this.$181=false},isc.A.getElementHTML=function isc_CanvasItem_getElementHTML(_1){var _2=this.canvas;if(!_2)return null;this.sizeCanvas();var _3="";if(isc.Browser.isIE&&isc.Browser.isTransitional){_3="border:0px solid transparent;"}
return"<SPAN style='padding:0px;margin:0px;"+_3+"' ID='"+this.getID()+"$18z'>"+isc.Canvas.spacerHTML(_2.getVisibleWidth(),_2.getVisibleHeight())+"</SPAN>"},isc.A.getPrintHTML=function isc_CanvasItem_getPrintHTML(_1,_2){if(this.canvas==null)return isc.nbsp;return this.canvas.getPrintHTML(_1,_2)},isc.A.$159=function isc_CanvasItem__applyHandlersToElement(){this.$16c()},isc.A.getHeight=function isc_CanvasItem_getHeight(_1){var _2=this.canvas;if(_2==null){return this.Super("getHeight",arguments)}
if(_1){var _3=_2.getVisibleHeight();if(_3>_2.getHeight())return _3}
return _2.$po||this.height||_2.defaultHeight},isc.A.getWidth=function isc_CanvasItem_getWidth(){return this.canvas==null?this.Super("getWidth",arguments):(this.canvas.$pn||this.width||this.canvas.defaultWidth)},isc.A.setWidth=function isc_CanvasItem_setWidth(_1){this.Super("setWidth",arguments);this.canvas.setWidth(Math.max(1,this.getInnerWidth()-this.getTotalIconsWidth()))},isc.A.setHeight=function isc_CanvasItem_setHeight(_1){this.Super("setHeight",arguments);this.canvas.setHeight(this.getInnerHeight())},isc.A.getMaxHeight=function isc_CanvasItem_getMaxHeight(){return this.maxHeight!=null?this.maxHeight:this.canvas.maxHeight},isc.A.getMinHeight=function isc_CanvasItem_getMinHeight(){var _1=this.minHeight!=null?this.minHeight:this.canvas.minHeight;return this.$168w==null?_1:Math.max(_1,this.$168w)},isc.A.canvasResized=function isc_CanvasItem_canvasResized(_1,_2,_3){if(this.$181)return;var _4=this.canvas;if(!isc.isA.Canvas(_4)){this.logWarn("canvasItem canvasResized notification fired, but this.canvas is not a live Canvas instance. Ignoring.");return}
var _5=Math.max(1,_4.getWidth()),_6=_4.getHeight();if(_3!="init"&&_3!="overflow"&&_3!="Overflow on initial draw")
{if(_1!=null&&_1!=0){_4.updateUserSize(_5,_4.$o6)}
if(_2!=null&&_2!=0){_4.updateUserSize(_6,_4.$o5)}}
this.logDebug("canvas resized: new specified sizes: "+[_5,_6],"canvasItemSizing");if(!_4.isDrawn())return;this.redraw()},isc.A.shouldDisableCanvas=function isc_CanvasItem_shouldDisableCanvas(){var _1=this.canvas;if(_1==null)return false;if(isc.isA.DynamicForm(_1)){return this.isDisabled()}else{return this.isDisabled()||this.isReadOnly()}},isc.A.updateDisabled=function isc_CanvasItem_updateDisabled(_1){this.Super("updateDisabled",arguments);this.canvas.setDisabled(this.shouldDisableCanvas(),_1)},isc.A.setElementReadOnly=function isc_CanvasItem_setElementReadOnly(){this.$176(!this.isReadOnly()&&!this.isDisabled())},isc.A.focusInItem=function isc_CanvasItem_focusInItem(){if(this.canvas!=null&&isc.isA.Canvas(this.canvas)){var _1=this.canvas.getID();this.logDebug("CanvasItem.focusInItem(): Asking TabIndexManager to shift focus into:"+_1,"syntheticTabIndex");return isc.TabIndexManager.shiftFocus(this.getID(),true,this.getID())}else{return this.Super("focusInItem",arguments)}},isc.A.syntheticShiftFocus=function isc_CanvasItem_syntheticShiftFocus(_1){return false},isc.A.blurItem=function isc_CanvasItem_blurItem(_1){if(!_1&&this.canvas)this.canvas.blur();return this.Super("blurItem",arguments)},isc.A.canvasFocusChanged=function isc_CanvasItem_canvasFocusChanged(){this.$170z()},isc.A.canvasChildFocusChanged=function isc_CanvasItem_canvasChildFocusChanged(){this.$170z()},isc.A.$170z=function isc_CanvasItem__canvasFocusChanged(){var _1=this.canvas&&this.canvas.containsFocus();if(_1!=this.hasFocus){this.hasFocus=_1;var _2=this.form;if(this.canvas.containsFocus()){if(_2.getFocusSubItem()!==this){_2.setFocusItem(this);this.elementFocus()}}else{this.elementBlur();if(_2.getFocusSubItem()===this)_2.setFocusItem(null)}}},isc.A.isFocused=function isc_CanvasItem_isFocused(){if(this.canvas&&this.canvas.containsFocus())return true;return this.Super("isFocused",arguments)},isc.A.nestedFormSetFocusItem=function isc_CanvasItem_nestedFormSetFocusItem(){this.form.setFocusItem(this)},isc.A.hasAdvancedCriteria=function isc_CanvasItem_hasAdvancedCriteria(){if(this.editCriteriaInInnerForm&&isc.isA.DynamicForm(this.canvas))return true;return this.Super("hasAdvancedCriteria",arguments)},isc.A.canEditCriterion=function isc_CanvasItem_canEditCriterion(_1){if(this.editCriteriaInInnerForm&&isc.isA.DynamicForm(this.canvas)){if(_1.operator!=this.canvas.operator)return false;for(var i=0;i<_1.criteria;i++){var _3=this.canvas.getItems(),_4;for(var _5=0;_5<_3.length;_5++){if(_3[_5].canEditCriterion(_1.criteria[i])){_4=true;break}}
if(!_4)return false}
return true}
return this.Super("canEditCriterion",arguments)},isc.A.getCriterion=function isc_CanvasItem_getCriterion(){if(this.editCriteriaInInnerForm&&isc.isA.DynamicForm(this.canvas)){return this.canvas.getValuesAsAdvancedCriteria()}else return this.Super("getCriterion",arguments)},isc.A.setCriterion=function isc_CanvasItem_setCriterion(_1){if(this.editCriteriaInInnerForm&&isc.isA.DynamicForm(this.canvas)){this.canvas.setValuesAsCriteria(_1,true)}else return this.Super("setCriterion",arguments)},isc.A.setPrompt=function isc_CanvasItem_setPrompt(_1){this.Super("setPrompt",_1);if(this.applyPromptToCanvas&&this.canvas){if(isc.isA.Canvas(this.canvas))this.canvas.setPrompt(_1);else this.canvas.prompt=_1}});isc.B._maxIndex=isc.C+51;isc.CanvasItem.registerStringMethods({createCanvas:"form,item",showValue:"displayValue,dataValue,form,item"});isc.ClassFactory.defineClass("TextItem","FormItem");isc.A=isc.TextItem;isc.A.DEFAULT="default";isc.A.UPPER="upper";isc.A.LOWER="lower";isc.A.$713={'0':{charFilter:"[0-9+\\-]"},'#':{charFilter:"[0-9]"},'9':{charFilter:"[0-9 ]"},'L':{charFilter:"[A-Za-z]"},'?':{charFilter:"[A-Za-z ]"},'a':{charFilter:"[0-9A-Za-z]"},'A':{charFilter:"[0-9A-Za-z]"},'C':{charFilter:"."}};isc.A.$126z=isc.Browser.isIE&&isc.Browser.version<=9&&(isc.Browser.version<=7||!isc.Browser.isStrict);isc.A=isc.TextItem.getPrototype();isc.A.width=150;isc.A.height=isc.Browser.isSafari?22:19;isc.A.textBoxStyle="textItem";isc.A.length=null;isc.A.enforceLength=true;isc.A.canAutoComplete=true;isc.A.$183="TEXT";isc.A.$125=true;isc.A.$15i=true;isc.A.emptyStringValue=null;isc.A.redrawOnShowIcon=false;isc.A.clipValue=true;isc.A.$16b={onmousedown:(isc.Browser.isIE?function(){var _1=this,_2=isc.DynamicForm._getItemInfoFromElement(_1),_3=_2.item;if(_3)_3.$179()}:isc.Browser.isIPhone&&isc.Browser.iOSVersion<5?function(_1){var _2=isc.EventHandler;_2.DOMevent=_1;var _3=_2.getMouseEventProperties(_1);return _2.handleMouseDown(_1,_3)}:null),onmouseup:(isc.Browser.isIPhone&&isc.Browser.iOSVersion<5?function(_1){var _2=isc.EventHandler;_2.DOMevent=_1;var _3=_2.getMouseEventProperties(_1);return _2.handleMouseUp(_1,_3)}:null)};isc.A.supportsCutPasteEvents=true;isc.A.$1709=true;isc.A.usePlaceholderForHint=true;isc.A.printFullText=false;isc.A.saveOnEnter=true;isc.A=isc.TextItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$1565={"email":true,"number":(!isc.Browser.isAndroidWebView||!(2.3<isc.Browser.androidMinorVersion&&isc.Browser.androidMinorVersion<4.2)),"password":true,"search":true,"tel":true,"text":true,"url":true};isc.A.$1163="$105x";isc.A.$1164=null;isc.A.$186=[,"<INPUT TYPE=",," NAME='",,"' ID='",,"' handleNativeEvents=false"];isc.A.$14f=" TABINDEX=";isc.A.$oa=">";isc.A.$pi=" DISABLED ";isc.A.$187="native";isc.A.$188=" AUTOCOMPLETE=OFF ";isc.A.$14e=" ACCESSKEY=";isc.A.$19a=[" CLASS='",,"' STYLE='",,,,,,,,,,,,,,,,(isc.Browser.isMoz?"-moz-user-focus:":null),,,"' "];isc.A.$19b="normal;";isc.A.$19c="ignore;";isc.A.$78v="margin-top:-1px;margin-bottom:-1px;";isc.A.$1619="INPUT";isc.A.$162a="TEXTAREA";isc.A.applyStaticTypeFormat=false;isc.A.characterCasing=isc.TextItem.DEFAULT;isc.A.stopNavKeyPressBubbling=true;isc.A.stopCharacterKeyPressBubbling=true;isc.A.formatOnFocusChange=false;isc.A.maskPadChar=" ";isc.A.maskPromptChar="_";isc.B.push(isc.A.$712=function isc_TextItem__getShowHintInField(){return!!(this.showHint&&this.getHint()&&this.showHintInField)},isc.A.$1564=function isc_TextItem__getUsePlaceholderForHint(){if(!this.usePlaceholderForHint)return false;return this.$1560()},isc.A.$1560=function isc_TextItem__supportsPlaceholderAttribute(){if(!isc.Browser.$1560)return false;var _1=this.$156t();if(_1==null)return true;_1=_1.toLowerCase();return this.$1565.hasOwnProperty(_1)},isc.A.$1550=function isc_TextItem__manageCharacterInput(){return(!!this.mask||!!this.$66y||this.characterCasing==isc.TextItem.UPPER||this.characterCasing==isc.TextItem.LOWER)},isc.A.$429=function isc_TextItem__willHandleInput(){return!isc.Browser.isIE},isc.A.$43a=function isc_TextItem__nativeCutPaste(){if(this.$1164!=null){isc.Timer.clearTimeout(this.$1164)}
this.$1164=isc.Timer.setTimeout({target:this,methodName:this.$1163},0);return this.Super("$43a",arguments)},isc.A.$105w=function isc_TextItem___handleInput(){if(isc.Browser.isIE&&isc.Browser.version>=10){if(this.$1164==null&&!this.getElementValue()){this.updateValue()}}else{this.$105x();return this.Super("$105w",arguments)}},isc.A.$1160=function isc_TextItem___handleSelect(){if(this.$1550()){this.$1161=this.getSelectionRange()}
return this.Super("$1160",arguments)},isc.A.$105x=function isc_TextItem__fixMaskAfterCutPaste(){delete this.$1164;if(this.$1550()){var _1=this.getValue();if(!_1)_1="";else _1=String(_1);var _2=(this.mask?this.$714(_1):_1),_3=this.getElementValue();if(!_3){if(this.changeOnKeypress){this.updateValue()}else{this.$122m(_3)}
return}
var _4=this.getSelectionRange(),_5=_3.length-_2.length,_6;if((isc.Browser.iOSVersion<7&&isc.Browser.isMobileWebkit&&!isc.Browser.isChrome)||(isc.Browser.isSafari&&!isc.Browser.isChrome&&isc.Browser.version<6))
{_6=_4[0]+_5}else if(isc.Browser.isAndroid&&isc.Browser.androidMinorVersion>=4.4&&isc.Browser.isMobileWebkit)
{_6=_4[1]}else if(_2!=_3&&this.$1161&&this.$1161[0]<this.$1161[1])
{if(isc.Browser.isSafari&&!isc.Browser.isChrome&&isc.Browser.minorVersion<6.1&&this.$1161[1]==_2.length)
{_6=_4[0]+_5}else{_6=_4[0]}}else{_6=_4[0]}
if(_5<0&&!this.mask){if(this.changeOnKeypress){this.updateValue()}else{this.$122m(_3)}
return}
var _7=_6-_5;_1=_3.substring(0,_7);if(!_2.startsWith(_1)){for(_7=0;_7<_1.length&&_7<_2.length;++_7)
{if(_1.charAt(_7)!=_2.charAt(_7)){break}}
if(!this.mask)_5=_6-_7;_1=_3.substring(0,_7)}
this.setElementValue(_1);this.$72a(_7);if(this.mask){var _8,_9;if(_6>_7){_9=this.$180z(_3.substring(_7,_6),_7);var _4=this.$72c();_8=this.$1800(_6-_5,_4.begin)}else{_9=_6;this.$72a(_6);_8=-this.$1800(_6,_6-_5)}
var _10=this.$1801(_2,_8,_6,_5);this.$180z(_10);this.$72a(_9)}else{var _11=_3.substring(_7);var _12=0;for(var i=0;i<_11.length;++i){var c=_11[i];var _15=c;if(!this.mask)_15=this.$72j(c,this.characterCasing);if(this.$66y&&!this.$66y.test(_15)){++_12;continue}
_1+=_15}
if(this.changeOnKeypress){this.setElementValue(_1);this.updateValue()}else{this.setValue(_1)}
this.$72a(_6-_12)}}},isc.A.$180z=function isc_TextItem__insertTextAtSelectionStart(_1,_2){var _3=_2,_4=false;for(var i=0;i<_1.length;++i){var c=_1.charAt(i),_7=_1.charCodeAt(i);if(i==0)this.$1165(_7);var _8=this.$1166(_7,true,false);if(_8===false){_4=true}else if(!_4){_3=_8}}
return _3},isc.A.$1800=function isc_TextItem__getMaskSlots(_1,_2){var _3=0;if(_1<_2){if(_2>this.$718)_2=this.$1802;for(var i=_1;i<_2;i++){if(this.$72i[i]!=null)_3++}}else{if(_1>this.$718)_1=this.$1802;for(var i=_2;i<_1;i++){if(this.$72i[i]!=null)_3--}}
return _3},isc.A.$1801=function isc_TextItem__getReplaySuffixForCutPaste(_1,_2,_3,_4){var _5=isc.StringBuffer.create(),_6=_5.getArray();if(_2>0){for(var i=_3-_4;i<_1.length;i++){if(this.$72i[i]==null)continue;if(_2>0&&(this.maskOverwriteMode||_1.charAt(i)==this.maskPromptChar))
{_2--;continue}
_6[_6.length]=_1.charAt(i)}}else{for(var i=_3-_4;i<_1.length;i++){if(this.$72i[i]==null)continue;if(_2<0&&!this.maskOverwriteMode&&_1.charAt(i)==this.maskPromptChar)
{for(var j=0;j<-_2;j++){_6[_6.length]=this.maskPromptChar}
_2=0}
_6[_6.length]=_1.charAt(i)}
if(_2<0){for(var j=0;j<-_2;j++){_6[_6.length]=this.maskPromptChar}}}
return _5.toString()},isc.A.getTextBoxCellCSS=function isc_TextItem_getTextBoxCellCSS(){return this.$136},isc.A.setElementReadOnly=function isc_TextItem_setElementReadOnly(_1){this.$86y(_1)},isc.A.$156r=function isc_TextItem__supportsInlineIcons(){if(this.$169p==null)return false;var _1=this.$156t();if(_1!=null)_1=_1.toLowerCase();var _2=isc.TextItem.$b4;return((_1==null||_1==="text"||_1==="password")&&this.getElementStyleHTML===_2.getElementStyleHTML&&this.getIconHTML===_2.getIconHTML&&this.getIconsHTML===_2.getIconsHTML)},isc.A.$16z=function isc_TextItem__iconVisibilityChanged(){var _1=this.getDataElement();if(_1!=null&&this.$169t()){if(this.$169p==="absolutePositioning"){var _2=this.getTextBoxStyle(),_3=this.isRTL(),_4=(_3?this.$156l:this.$156j),_5=(_3?this.$156j:this.$156l),_6=isc.Element.$tr(_2)+_4,_7=isc.Element.$ts(_2)+_5,_8=_1.style;_8.paddingRight=_7+"px";_8.paddingLeft=_6+"px"}else{this.redraw("iconVisibilityChanged, 'divStyledAsDataElement' inline icons markup approach")}}
this.Super("$16z",arguments)},isc.A.$15s=function isc_TextItem__writeOuterTable(){var _1=this.Super("$15s",arguments);if(_1)return true;var _2=this.$xq(this.getValue());if(_2!=null&&_2!=""){return true}
return false},isc.A.$156t=function isc_TextItem__getInputType(){var _1=this.$183;if(this.browserInputType!=null){_1=this.getBrowserInputType()}
return _1},isc.A.getElementHTML=function isc_TextItem_getElementHTML(_1,_2){var _3=this.$xq(_2);if(this.showValueIconOnly)return _3;var _4;if(this.$68y()||this.renderAsStatic()){if(this.printFullText){_4=isc.StringBuffer.concat("<SPAN ",this.getElementStyleHTML(_1),">",_2==null?"&nbsp;":_2.asHTML(),"</SPAN>")}else{_4=this.Super("getElementHTML",arguments)}}else{var _5=this.$186,_6=_5.length,_7=this.form,_8=_7.getID(),_9=this.getItemID();_5[0]=_3;var _10=this.$156t();_5[2]=_10;_5[4]=this.getElementName();_5[6]=this.getDataElementId();_5[8]=this.$155();if(isc.Browser.isMoz||isc.Browser.isSafari){if(this.getBrowserSpellCheck())_5[_5.length]=" spellcheck=true";else _5[_5.length]=" spellcheck=false"}
if(isc.Browser.isSafari){if(this.browserAutoCapitalize==false){_5[_5.length]=" autocapitalize=off"}
if(this.browserAutoCorrect!=null){_5[_5.length]=this.browserAutoCorrect?" autocorrect='on'":" autocorrect='off'"}
if(this.browserInputType=="digits"){_5[_5.length]=" pattern='\\d*'"}}
if(this.$429()||(isc.Browser.isIE&&isc.Browser.version>=10)){_5[_5.length]=" ONINPUT='"
_5[_5.length]=this.getID()
_5[_5.length]="._handleInput()'"}
_5[_5.length]=" ONSELECT='if (window.";_5[_5.length]=this.getID()
_5[_5.length]=" == null) return;";_5[_5.length]=this.getID();_5[_5.length]=".$1162()'";if(this.renderAsDisabled()||(this.$183=="FILE"&&this.isReadOnly())){_5[_5.length]=this.$pi}
if(this.$1397()){_5[_5.length]=" READONLY=TRUE";if(isc.screenReader)_5[_5.length]=" aria-readonly=true"}
if(this.isInactiveHTML()&&_1!=null&&_1!=isc.emptyString){_5[_5.length]=" value='"+String.asAttValue(_1)+"'"}
if(this.$17h()!=this.$187){_5[_5.length]=this.$188}
if(this.$712()&&this.$1564()){var _11=this.getHint();_5[_5.length]=" placeholder='"+String.asAttValue(String.htmlStringToString(_11))+"'"}
_5[_5.length]=this.getElementStyleHTML(_2);var _12=this.$154();if(_12!=null){var _13=_5.length;_5[_13]=this.$14f;isc.$bk(_5,_12,_13+1,5)}
if(this.showTitle==false&&this.accessKey!=null){_5[_5.length]=this.$14e;_5[_5.length]=this.accessKey}
_5[_5.length]=this.$oa;_4=_5.join(isc.emptyString);_5.length=_6}
return _4},isc.A.$1397=function isc_TextItem__elementIsReadOnly(){return this.isInactiveHTML()||this.isReadOnly()},isc.A.$143=function isc_TextItem__sizeTextBoxAsContentBox(){if(this.$68y()){return this.Super("$143",arguments)}
return isc.Browser.isStrict},isc.A.$12x=function isc_TextItem__nativeElementBlur(_1,_2){if(this.form&&!this.form.$10u){this.form.elementChanged(this)}
var _3=this.Super("$12x",arguments);if(!this.isReadOnly()&&(this.formatOnFocusChange||this.mask!=null||this.$84f==null||this.$84f!=this.getEnteredValue()))
{this.refreshDisplayValue()}
if(this.$712()&&!this.$1564()){var _4=this.getElementValue();if(_4==null||isc.isAn.emptyString(_4)){this.$66t()}}
if(this.$85u!=null){isc.Timer.clear(this.$85u);this.$85u=null}
return _3},isc.A.refreshDisplayValue=function isc_TextItem_refreshDisplayValue(){var _1=this.getValue();if(this.mapValueToDisplay){_1=this.mapValueToDisplay(_1)}
if(!this.hasFocus&&this.$712()&&!this.$1564()&&(_1==null||isc.isAn.emptyString(_1)))
{this.$66t()}else{this.setElementValue(_1)}},isc.A.getTextBoxStyle=function isc_TextItem_getTextBoxStyle(){if((!this.hasFocus&&this.$712()&&!this.$1564()&&this._value==null)||(this.$1441))
{return this.$66v()}else{return this.Super("getTextBoxStyle",arguments)}},isc.A.getElementStyleHTML=function isc_TextItem_getElementStyleHTML(_1){var _2=this.$68y()&&this.printFullText;var _3=this.$19a,_4=this.getTextBoxWidth(_1),_5=this.getTextBoxHeight(_1),_6=this.getTextBoxStyle(),_7=this.$169t();_3[1]=_6;if(isc.isA.Number(_4)){_3[3]=this.$93;isc.$bk(_3,_4,4,4);_3[8]=this.$38}else{_3[3]=_3[4]=_3[5]=_3[6]=_3[7]=_3[8]=null}
if(isc.isA.Number(_5)&&(!_7||this.$169p!=="divStyledAsDataElement")){_3[9]=this.$92;isc.$bk(_3,_5,10,4);_3[14]=this.$38}else{_3[9]=_3[10]=_3[11]=_3[12]=_3[13]=_3[14]=null}
if(this.textAlign){_3[15]=this.$14c;_3[16]=this.textAlign;_3[17]=this.$39}else{_3[15]=_3[16]=_3[17]=null}
if(isc.TextItem.$126z){_3[18]=_2?null:this.$78v}
if(isc.Browser.isMoz&&!_2){_3[19]=(this.$154()>0?this.$19b:this.$19c)}
if(this.$169t()){var _8=this.isRTL(),_9=_8?this.$156l:this.$156j;if(this.$169p==="absolutePositioning"){var _10=isc.Element.$tr(_6)+_9,_11=_8?this.$156j:this.$156l,_12=isc.Element.$ts(_6)+_11;_3[20]="padding-right:"+_12+"px;padding-left:"+_10+"px"}else{if(isc.Browser.isIE&&!isc.Browser.isStrict){_3[20]=isc.Canvas.$42a+"position:relative;left:"+_9+"px"}else{_3[20]=isc.Canvas.$42a+"position:relative;top:0px;bottom:0px;left:"+_9+"px"}}}else{_3[20]=null}
return _3.join(isc.emptyString)},isc.A.$104v=function isc_TextItem__getMeasureCanvas(){return isc.TextItem.$78l||(isc.TextItem.$78l=isc.Canvas.create({_generated:true,top:-1000,ariaState:{hidden:true},overflow:"visible",autoDraw:true,height:1,width:1,markForRedraw:function(){}}))},isc.A.$1156=function isc_TextItem__getTextBoxScrollWidth(_1,_2,_3,_4){var _5=_1.tagName;if((_5===this.$1619||_5===this.$162a)&&(isc.Browser.isEdge||isc.Browser.isIE10||isc.Browser.isMoz||(this.textAlign!=null&&this.textAlign!=(this.isRTL()?"right":"left"))))
{var _6=this.getTextBoxStyle(),_7=this.getElementValue();if(_7==null)_7="";else _7=String(_7);if(this.$1157==null||this.$1157.textBoxStyle!=_6||this.$1157.elementValue!=_7)
{var _8=this.$104v();if(_8.styleName!=_6)_8.setStyleName(_6);_8.setContents("<span style='white-space:nowrap'>"+isc.makeXMLSafe(_7)+"</span>");_8.redraw("value scrollWidth measurement: "+_7);var _9=_8.getScrollWidth(true);this.$1157={width:_9,textBoxStyle:_6,elementValue:_7}}
return this.$1157.width}else{return this.invokeSuper(isc.TextItem,"$1156",_1,_2,_3,_4)}},isc.A.getEnteredValue=function isc_TextItem_getEnteredValue(){return this.getElementValue()},isc.A.mapValueToDisplay=function isc_TextItem_mapValueToDisplay(_1,_2){var _3;if(this.mask&&this.hasFocus&&!_2){_3=this.$715()}else{_3=isc.FormItem.$b4.mapValueToDisplay.call(this,_1);if(_3==null)return isc.emptyString;if(this.mask){_3=this.$714(_3)}}
return _3},isc.A.mapDisplayToValue=function isc_TextItem_mapDisplayToValue(_1){var _2;if(this.mask){_2=this.$716(_1)}else{if(this.mapEmptyDisplayValue||(_1!=this.emptyDisplayValue)){_2=this.$17d(_1)}}
_2=this.$79d(_2);if(isc.is.emptyString(_2))_2=this.emptyStringValue;return _2},isc.A.saveValue=function isc_TextItem_saveValue(_1,_2){if(this.mask)this.$714(_1);this.Super("saveValue",arguments)},isc.A.setValue=function isc_TextItem_setValue(_1,_2,_3,_4){this.$66s();var _5;if(this.emptyStringValue===null||this.emptyStringValue===_5){if(_1==null||isc.is.emptyString(_1)){this.emptyStringValue=_1}}
if(_1!==_5&&_1!=null&&this.characterCasing!=isc.TextItem.DEFAULT){if(this.characterCasing==isc.TextItem.UPPER){if(isc.isA.Array(_1))
this.arrayToUpperCase(_1);else
_1=_1.toUpperCase()}else if(this.characterCasing==isc.TextItem.LOWER){if(isc.isA.Array(_1))
this.arrayToLowerCase(_1);else
_1=_1.toLowerCase()}}
_1=this.invokeSuper(isc.TextItem,"setValue",_1,_2,_3,_4);if(!this.hasFocus&&this.$712()&&!this.$1564()){var _6=this.getElementValue();if(_6==null||isc.isAn.emptyString(_6)){this.$66t()}else{var _7=this.getDataElement();if(_7!=null)_7.className=this.getTextBoxStyle()}}else if(this.hasFocus&&this.mask&&(_1==null||isc.isAn.emptyString(_1))){this.$72a(this.$72g==null?0:this.$72g)}
return _1},isc.A.$124t=function isc_TextItem__showValue(_1,_2){var _3=false;if(!this.hasFocus&&this.$712()&&!this.$1564()){var _4=this.getDisplayValue(_1);if(_4==null||isc.isAn.emptyString(_4)){_3=true}}
if(_3){if(this.$1563&&this.getElementValue()!=String.htmlStringToString(this.getHint())){this.$1563=false}
this.$66t()}else{if(this.$1563)this.$1563=false;return this.Super("$124t",arguments)}},isc.A.arrayToUpperCase=function isc_TextItem_arrayToUpperCase(_1){for(var i=0;i<_1.length;i++){_1[i]=_1[i].toUpperCase()}},isc.A.arrayToLowerCase=function isc_TextItem_arrayToLowerCase(_1){for(var i=0;i<_1.length;i++){_1[i]=_1[i].toLowerCase()}},isc.A.getCriteriaFieldName=function isc_TextItem_getCriteriaFieldName(){if(this.criteriaField)return this.criteriaField;if(this.displayField)return this.displayField;return this.Super("getCriteriaFieldName",arguments)},isc.A.$12v=function isc_TextItem__nativeElementFocus(_1,_2){var _3=this.$93l;var _4=this.Super("$12v",arguments);var _5=this.$1563;this.$66s();if(this.mask&&this.mapValueToDisplay){this.mapValueToDisplay(this.getValue(),true)}
if(this.isReadOnly())return _4;var _6=this.$j6;var _7;if(this.formatOnFocusChange||this.formatOnBlur){var _8=this.getElementValue();this.refreshDisplayValue()
if((isc.Browser.isIE10||(isc.Browser.isIE&&_8!=this.getElementValue())))
{_7=true}}
if(this.mask){this.$717(false);var _9=0;var _10=this.$718;var _11=!_6&&!_3&&this.$884();if(!_11){_9=this.$719();var _12=this.getValue();if(_12!=null&&_9==0&&_12.length>0){_9=_6?this.getSelectionRange()[0]:0}
_10=_9}
if(!this.$85u){this.$85u=this.delayCall("$85v",[_9,_10],50)}}else{var _11=!_6&&!_3&&this.$884();var _12=this.getEnteredValue();if(_11){if(_12!=null&&!this.$85u){this.$85u=this.delayCall("$85w")}}else if(_7){var _8=this.getElementValue();if(_8.length>0){this.setSelectionRange(_8.length,_8.length)}}
this.$84f=_12}
return _4},isc.A.$85v=function isc_TextItem__delayed_setSelection(_1,_2){this.$85u=null;if(!this.$820())return;this.$72a(_1,_2)},isc.A.$85w=function isc_TextItem__delayed_selectValue(){this.$85u=null;if(!this.$820())return;this.selectValue()},isc.A.setKeyPressFilter=function isc_TextItem_setKeyPressFilter(_1){if(this.mask){this.logWarn("setKeyPressFilter() ignored because mask is enabled");return}
this.keyPressFilter=_1;this.$66y=null;if(this.keyPressFilter){this.$66y=new RegExp(this.keyPressFilter)}},isc.A.init=function isc_TextItem_init(){this.Super("init",arguments);if(this.inputDataType!=null&&this.browserInputType==null){this.browserInputType=this.inputDataType}
if(this.mask){if((isc.ComboBoxItem&&isc.isA.ComboBoxItem(this))||(isc.SpinnerItem&&isc.isA.SpinnerItem(this)))
{this.logWarn("item.mask is unsupported for this FormItem type. This item has mask specified as '"+this.mask+"' - ignoring.");this.mask=null}else if(this.browserInputType=="digits"||this.browserInputType=="number"){this.logWarn("item.mask is unsupported for a FormItem with browserInputType '"+this.browserInputType+"'. Ignoring.");this.mask=null}else{this.$72b();if(this.keyPressFilter){this.logWarn("init: keyPressFilter ignored because mask is enabled")}}}else if(this.keyPressFilter){this.$66y=new RegExp(this.keyPressFilter)}},isc.A.handleKeyPress=function isc_TextItem_handleKeyPress(_1,_2){var _3=this.Super("handleKeyPress",arguments);if(_3==false){return false}
if(this.isReadOnly())return _3;var _4=_1.keyName;if((isc.EventHandler.ctrlKeyDown()||isc.EventHandler.altKeyDown()||isc.EH.metaKeyDown())&&(_2.characterValue===null||_2.characterValue<128)){if(this.mask&&(_4.startsWith("Arrow_")||_4=="Home"||_4=="End")&&!isc.EH.shiftKeyDown())
{delete this.$1161}
return _3}
if((!this.characterCasing||this.characterCasing==isc.TextItem.DEFAULT)&&!this.$66y&&!this.mask)
{return _3}
var _5=_1.characterValue;if(this.mask){var _6=this.$72c();var _7=isc.Browser.isSafari;var _8=_6.begin;if(_4=="Backspace"||_4=="Delete"){if((_6.begin-_6.end)!=0||(_7&&this.$72d))
{if(isc.Browser.isSafari&&this.$72d){_6=this.$72d;this.$72d=null}
if(this.maskOverwriteMode){this.$72e(_6.begin,_6.end)}else{var _9=_6.end-_6.begin;this.$72f(_6.begin,_9)}
this.$717(true);this.$73t(_6.begin,0)}else{if(_4=="Backspace"){var _10=_8-1;if(_10>=0){if(this.maskOverwriteMode){while(!this.$72i[_10]&&_10>=0)_10--;this.$72l[_10]=this.maskPromptChar}else{this.$72f(_10)}
this.$717(true);this.$73t(_10,-1)}}else{if(this.maskOverwriteMode){if(_8<this.$718&&_8==this.$72h(_8-1)){this.$72l[_8]=this.maskPromptChar}}else{this.$72f(_8)}
this.$717(true);this.$73t(_8,0)}}
return false}else if((_4.startsWith("Arrow_")||_4=="Home"||_4=="End")&&!isc.EH.shiftKeyDown())
{delete this.$1161}
this.$1165(_5);if(_4=="Escape"){this.$72e(0,this.$718)
this.$717(true);this.$72a(this.$72g==null?0:this.$72g);return false}}
if(this.$1166(_5)==false){return false}else{if(_3!=false)delete this.$1161;return _3}},isc.A.$1166=function isc_TextItem__insertCharacterValue(_1,_2){var _3=this.$72c(),_4=_3.begin;if((this.mask&&!this.$660(_1))||(!this.mask&&((!this.$66y&&!this.$66z(_1))||(this.$66y&&!this.$660(_1)))))
{return true}
var c=String.fromCharCode(_1);if(this.mask){var p=this.$72h(_4-1);if(p<this.$718){var _7=this.$72i[p];if(_7!=null){if(c!==this.maskPromptChar&&_7.casing!=null){c=this.$72j(c,_7.casing).charAt(0)}
if(_7.filter.test(c)||c===this.maskPromptChar){if(!this.maskOverwriteMode&&!_2){this.$72k(p)}
this.$72l[p]=c;var _8=p;if(this.$717(true)){_8=this.$72h(p)}
this.$72a(_8);if(_2&&c!==this.maskPromptChar)return _8}}}
return false}
var _9=c;if(!this.mask)_9=this.$72j(c,this.characterCasing);if(c==_9&&!this.$66y)return true;if(this.$66y){if(this.$660(_1)&&!this.$66y.test(_9)){return false}}
if(c==_9)return true;var _10=this.getValue()||"";if(!this.changeOnKeypress){_10=this.getElementValue()||""}
_3=this.getSelectionRange();if((_3[0]-_3[1])!=0){_10=_10.substring(0,_3[0])+_9+_10.substring(_3[1]+1)}else{_10=_10.substring(0,_3[0])+_9+_10.substring(_3[1])}
if(this.changeOnKeypress){this.setElementValue(_10);this.updateValue()}else{this.setValue(_10)}
this.setSelectionRange(_3[0]+1,_3[0]+1);return false},isc.A.$1165=function isc_TextItem__setUpInsertCharacterValue(_1){if(this.mask){var _2=this.$72c();var _3=isc.Browser.isSafari;if(this.$660(_1)&&((_2.begin-_2.end)!=0||(_3&&this.$72d)))
{if(isc.Browser.isSafari&&this.$72d){_2=this.$72d;this.$72d=null}
if(this.maskOverwriteMode){this.$72e(_2.begin,_2.end)}else{var _4=_2.end-_2.begin;this.$72f(_2.begin,_4)}}
if(_3&&(_2.begin-_2.end)!=0&&!this.$660(_1))
{this.$72d=_2}else{this.$72d=null}}},isc.A.$660=function isc_TextItem__isTypableCharacter(_1){return((_1>=32&&_1<=126)||_1>127)},isc.A.$66z=function isc_TextItem__isAlphaCharacter(_1){return(_1>=65&&_1<=90)||(_1>=97&&_1<=122)},isc.A.$72j=function isc_TextItem__mapCharacterCase(_1,_2){if(_2==isc.TextItem.UPPER){_1=_1.toUpperCase()}else if(_2==isc.TextItem.LOWER){_1=_1.toLowerCase()}
return _1},isc.A.setMask=function isc_TextItem_setMask(_1){if(isc.isA.ComboBoxItem(this)||isc.isA.SpinnerItem(this)){return}
if(!this.mask!=!_1&&this.$85u!=null){isc.Timer.clear(this.$85u);this.$85u=null}
this.mask=_1;this.$72b();if(this.keyPressFilter){this.$66y=null;this.logWarn("setMask: keyPressFilter ignored because mask is enabled")}
this.setValue("")},isc.A.$72b=function isc_TextItem__parseMask(){var _1=this.mask;if(!_1)return;this.$72i=[];this.$72g=null;this.$72l=[];this.$718=0;var _2=null;var _3=false;var _4=false;var _5="";for(var i=0,_7=_1.length;i<_7;++i){var c=_1.charAt(i);if(!_4){if(!_3&&c==="\\"){_3=true}else if(_3){this.$72m(c,_2);_3=false}else if(c==="<"){_2=(_2==isc.TextItem.LOWER?null:isc.TextItem.LOWER)}else if(c===">"){_2=(_2==isc.TextItem.UPPER?null:isc.TextItem.UPPER)}else if(c==="["){_4=true;_5+=c}else{this.$72n(c,_2)}}else{if(c==="]"){_4=false;_5+=c;this.$1628(_5,_2);_5=""}else{_5+=c}}}
if(!_4){if(_3){this.logWarn("Invalid mask syntax: Trailing backslash");this.$72m("\\",_2);_3=false}}else{this.logWarn("Invalid mask syntax: Character class regular expression was not terminated");_4=false;_5+="]";this.$1628(_5,_2);_5=""}},isc.A.$72m=function isc_TextItem__addLiteralToMask(_1,_2){this.$72i.push(null);this.$72l.push(_1);this.$718++},isc.A.$1628=function isc_TextItem__addCustomRegexToMask(_1,_2){this.$72i.add({filter:new RegExp(_1),casing:_2});if(this.$72g==null){this.$72g=this.$72i.length-1}
this.$72l.push(this.maskPromptChar);this.$718++});isc.evalBoundary;isc.B.push(isc.A.$72n=function isc_TextItem__addUnknownToMask(_1,_2){var _3=isc.TextItem.$713[_1];if(_3){this.$72i.push({filter:new RegExp(_3.charFilter),casing:_2});if(this.$72g==null){this.$72g=this.$72i.length-1}
this.$72l.push(this.maskPromptChar)}else{this.$72i.push(null);this.$72l.push(_1)}
this.$718++},isc.A.$72c=function isc_TextItem__getSelection(){var _1=this.getSelectionRange();if(_1==null)_1=[0,0];return{begin:_1[0],end:_1[1]}},isc.A.$72a=function isc_TextItem__setSelection(_1,_2){if(this.hasFocus){_2=(isc.isA.Number(_2)?_2:_1);this.setSelectionRange(_1,_2)}},isc.A.$72h=function isc_TextItem__getNextEntryPosition(_1){while(++_1<this.$718){if(this.$72i[_1])return _1}
return this.$718},isc.A.$719=function isc_TextItem__getEndPosition(){var _1=0;for(var i=this.$718-1;i>=0;i--){if(this.$72i[i]){if(this.$72l[i]==this.maskPromptChar)
_1=i;else
break}}
return _1},isc.A.$714=function isc_TextItem__maskValue(_1){var _2=_1||"";if(this.canEditOpaqueValues&&isc.isAn.Object(_2)){if(isc.SimpleType){var _3=isc.SimpleType.getType(this.type)
if(_3&&_3.getAtomicValue){_2=_3.getAtomicValue(_2,"mask")}}}
if(!isc.isA.String(_2))_2=_2.toString();this.$72e(0,this.$718);var _4=-1;if(this.maskSaveLiterals){for(var i=0,_6=0;i<_2.length;i++){if(this.$72i[i]){var c=_2.charAt(i);if(c==" "){this.$72l[i]=this.hasFocus?this.maskPromptChar:this.maskPadChar}else if(this.$72i[i].filter.test(c)){this.$72l[i]=c;_4=i}}}}else{for(var i=0,_6=0;i<this.$718;i++){if(this.$72i[i]){while(_6<_2.length){var c=_2.charAt(_6++);var _8=this.$72i[i];if(c==" "){this.$72l[i]=this.hasFocus?this.maskPromptChar:this.maskPadChar;break}else if(_8.filter.test(c)){this.$72l[i]=_8.casing?this.$72j(c,_8.casing):c;_4=i;break}}
if(_6>_2.length)break}}}
_2=this.$715();if(!this.hasFocus){if(_4>=0){for(var i=_4+1;i<this.$718;i++){if(this.$72i[i])break;_4++}}
_2=_2.substring(0,_4+1)}
return _2},isc.A.$716=function isc_TextItem__unmaskValue(_1){if(_1==null)_1="";var _2=false;var _3=-1;var _4="";for(var i=0,_6=0;i<_1.length;i++){var c=_1.charAt(i);if(this.$72i[i]){if(c!=this.maskPromptChar&&this.$72i[i].filter.test(c)){_4+=c;_2=true;_3=_6++}else{_4+=this.maskPadChar;_6++}}else if(this.maskSaveLiterals){_4+=c;_3=_6++}}
if(!_2){_4=""}else{_4=_4.substring(0,_3+1)}
return _4},isc.A.$715=function isc_TextItem__getMaskBuffer(){if(this.$72l==null)return"";return this.$72l.join('')},isc.A.$72e=function isc_TextItem__clearMaskBuffer(_1,_2){for(var i=_1;i<_2&&i<this.$718;i++){if(this.$72i[i])this.$72l[i]=this.maskPromptChar}},isc.A.$717=function isc_TextItem__saveMaskBuffer(_1){var _2=this.$715();this.setElementValue(_2);if(_1&&this.changeOnKeypress){var _3=this.$716(_2);var _4=this.handleChange(_3,this._value);if(this.destroyed)return;_3=this.$17n;this.updateAppearance(_3);this.saveValue(_3);this.handleChanged(_3);return _4}
return true},isc.A.$73t=function isc_TextItem__positionCaret(_1,_2){if(_2<0){while(!this.$72i[_1]&&_1>=0)_1--}else{while(!this.$72i[_1]&&_1<this.$718)_1++}
this.$72a(_1)},isc.A.$72f=function isc_TextItem__shiftMaskBufferLeft(_1,_2){if(!_2)_2=1;while(!this.$72i[_1]&&_1>=0)_1--;for(var i=_1,_4=i+_2-1;i<this.$718;i++,_4=j){if(this.$72i[i]){this.$72l[i]=this.maskPromptChar;var j=this.$72h(_4++);var _6=this.$72i[i];var c=this.$72l[j];if(j<this.$718&&_6.filter.test(c)){if(_6.casing){c=this.$72j(c,_6.casing)}
this.$72l[i]=c}else{while(i<j){if(this.$72i[i])this.$72l[i]=this.maskPromptChar;i++}
break}}}},isc.A.$72k=function isc_TextItem__shiftMaskBufferRight(_1){for(var i=_1,c=this.maskPromptChar;i<this.$718;i++){var _4=this.$72i[i];if(_4){if(_4.casing){c=this.$72j(c,_4.casing)}
var j=this.$72h(i);var t=this.$72l[i];this.$72l[i]=c;if(j<this.$718&&this.$72i[j].filter.test(t)){c=t}else{break}}}});isc.B._maxIndex=isc.C+64;isc.ClassFactory.defineClass("IntegerItem","TextItem");isc.A=isc.IntegerItem.getPrototype();isc.A.defaultType="integer";isc.A=isc.IntegerItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.getValueAsInteger=function isc_IntegerItem_getValueAsInteger(){var _1=this.getValue(),_2=parseInt(_1);return isNaN(_2)||_2.toString()!=_1?null:_2},isc.A.$184w=function isc_IntegerItem__getFormattedNumberString(_1){return""+_1});isc.B._maxIndex=isc.C+2;isc.ClassFactory.defineClass("FloatItem","TextItem");isc.A=isc.FloatItem.getPrototype();isc.A.$956=false;isc.A.defaultType="float";isc.A.$84r=true;isc.A=isc.FloatItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.mapValueToDisplay=function isc_FloatItem_mapValueToDisplay(_1){if(!this.$956){var _2=null;if(isc.isA.String(_1)&&(this.type==null||!this.type.startsWith("locale"))){var _3=window.parseFloat(_1);if(!window.isNaN(_3)&&_3==_1){_2=_3}}else if(isc.isA.Number(_1)){_2=_1}
if(_2!=null){if(this.format){return isc.NumberUtil.format(_2,this.format)}else if(this.$62!=null&&this.$62.editFormatter!=null){var _4=this.form,_5=_4?_4.values:{};return this.$62.editFormatter(_1,this,_4,_5)}else if(this.$184w){var _6=this.$184w(_2);if(_6)return _6}}}
return this.Super("mapValueToDisplay",arguments)},isc.A.$184w=function isc_FloatItem__getFormattedNumberString(_1){if(this.decimalPrecision!=null||this.decimalPad!=null){return isc.Canvas.getFloatValueAsString(_1,this.decimalPrecision,this.decimalPad)}else if(this.precision!=null){return isc.Canvas.getNumberValueAsString(_1,this.precision,"float")}
return""+_1},isc.A.handleEditorEnter=function isc_FloatItem_handleEditorEnter(){this.$956=true;var _1=this.getValue(),_2=this.mapValueToDisplay(_1);var _3=this.getEnteredValue();if(_3!=_2){var _4=this.getSelectionRange(),_5;if(_3.length==_2.length||(_4[0]==0&&_4[1]==0))
{_5=_4}else if(_4[1]==_3.length){if(_4[0]==0){_5=[0,_2.length]}else if(_4[0]==_3.length){_5=[_2.length,_2.length]}}
this.setElementValue(_2,_1);if(_5!=null){this.setSelectionRange(_5[0],_5[1])}}
this.Super("handleEditorEnter",arguments)},isc.A.handleEditorExit=function isc_FloatItem_handleEditorExit(){this.Super("handleEditorExit",arguments);this.$956=false;var _1=this.getValue(),_2=this.mapValueToDisplay(_1);this.setElementValue(_2,_1)},isc.A.getValueAsFloat=function isc_FloatItem_getValueAsFloat(){var _1=this.getValue(),_2=parseFloat(_1);return isNaN(_2)?null:_2});isc.B._maxIndex=isc.C+5;isc.ClassFactory.defineClass("DoubleItem","FloatItem");isc.A=isc.DoubleItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.getValueAsDouble=function isc_DoubleItem_getValueAsDouble(){var _1=this.getValue(),_2=parseFloat(_1);return isNaN(_2)?null:_2});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("BlurbItem","FormItem");isc.A=isc.BlurbItem.getPrototype();isc.A.shouldSaveValue=false;isc.A.height=null;isc.A.showTitle=false;isc.A.colSpan="*";isc.A.startRow=true;isc.A.endRow=true;isc.A.textBoxStyle="staticTextItem";isc.A.canSelectText=true;isc.A.emptyDisplayValue="&nbsp;";isc.A.clipValue=false;isc.ClassFactory.defineClass("ButtonItem","CanvasItem");isc.A=isc.ButtonItem.getPrototype();isc.A.canFocus=true;isc.A.shouldSaveValue=false;isc.A.height=null;isc.A.width=null;isc.A.titleStyle=null;isc.A.showTitle=false;isc.A.startRow=true;isc.A.endRow=true;isc.A.buttonConstructor=isc.Button;isc.A.autoFit=true;isc.A.buttonDefaults={getTitle:function(){return this.canvasItem.getTitle()},showFocusedAsOver:this.showFocusedAsOver};isc.A.autoDestroy=true;isc.A.readOnlyDisplay="disabled";isc.A.showFocusedAsOver=false;isc.A=isc.ButtonItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$19d={width:true,height:true,icon:true};isc.B.push(isc.A.getTitleHTML=function isc_ButtonItem_getTitleHTML(){return this.getTitle()},isc.A.setTitle=function isc_ButtonItem_setTitle(_1){this.title=_1;if(this.canvas)this.canvas.setTitle(_1)},isc.A.$18y=function isc_ButtonItem__createCanvas(){var _1={canFocus:this.$kk(),width:this.width};if(this.height!=null)_1.height=this.height;if(this.icon)_1.icon=this.icon;if(this.titleStyle)_1.titleStyle=this.titleStyle;if(this.baseStyle)_1.baseStyle=this.baseStyle;if(this.autoFit!=null)_1.autoFit=this.autoFit;if(this.showFocusedAsOver!=null)_1.showFocusedAsOver=this.showFocusedAsOver;this.canvas=this.button=this.createAutoChild("button",_1,this.buttonConstructor);this.Super("$18y",arguments);if(this.form&&this.form.itemLayout=="absolute")this.canvas.bringToFront()},isc.A.$602=function isc_ButtonItem__setCanvasSize(_1,_2,_3,_4){if(_1==null&&_2==null)return;return this.invokeSuper(isc.ButtonItem,"$602",_1,_2,_3,_4)},isc.A.propertyChanged=function isc_ButtonItem_propertyChanged(_1,_2){if(this.canvas!=null&&this.$19d[_1]){this.canvas.setProperty(_1,_2)}
this.Super("propertyChanged",arguments)},isc.A.$85m=function isc_ButtonItem__shouldAllowExpressions(){return false},isc.A.setShowFocusedAsOver=function isc_ButtonItem_setShowFocusedAsOver(_1){this.showFocusedAsOver=_1;if(this.button)this.button.setShowFocusedAsOver(_1)});isc.B._maxIndex=isc.C+7;if(isc.ListGrid){isc.ClassFactory.defineInterface("PickList");isc.ClassFactory.defineClass("PickListMenu","ScrollingMenu");isc.A=isc.PickListMenu;isc.A.$51t={};isc.A.pickListCacheLimit=50;isc.A=isc.PickListMenu.getPrototype();isc.A.useAllDataSourceFields=false;isc.A.tabIndex=-1;isc.A.canResizeFields=false;isc.A.canFreezeFields=false;isc.A.styleName="pickListMenu";isc.A.bodyStyleName="pickListMenuBody";isc.A.normalCellHeight=16;isc.A.scrollToCellXPosition="left";isc.A.scrollToCellYPosition="top";isc.A.animateTransitions=!isc.Browser.isMobileIE;isc.A.skinUsesCSSTransitions=false;isc.A.animateDuration=350;isc.A=isc.PickListMenu.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.showOverAsSelected=true;isc.A.$19e="background-color:";isc.A.$19f="color:";isc.B.push(isc.A.getTransformCSS=function isc_PickListMenu_getTransformCSS(){if(!this.$1484||!isc.Browser.$139c||!this.animateTransitions||!this.skinUsesCSSTransitions){return null}else{var y=!this.$148a?"100%":"0px";return";"+isc.Element.$159t+": translateY("+y+");"}},isc.A.handleTransitionEnd=function isc_PickListMenu_handleTransitionEnd(_1,_2){if(_2.target===this&&this.$1484!=null){this.$1393();if(!this.$148a){this.$1484.hide()}else{if(this.showModal)this.body.focus()}}},isc.A.$vl=function isc_PickListMenu__readyToSetFocus(_1){if(_1&&isc.Browser.$139c&&this.animateTransitions&&this.skinUsesCSSTransitions&&this.$148a)
{return false}
return this.Super("$vl",arguments)},isc.A.$148c=function isc_PickListMenu__animateShow(){if(!isc.Canvas.$151r(this.$1484)){this.$1484.bringToFront()}
this.$1484.show();if(!this.isDrawn())this.draw();if(!isc.Browser.$139c||!this.animateTransitions||!this.skinUsesCSSTransitions){this.show();this.moveTo(0,this.getInnerHeight());this.animateMove(0,0,function(){},this.animateDuration)}else{this.$148a=true;this.show();this.delayCall("$151v")}},isc.A.$151v=function isc_PickListMenu___animateShow(){this.$1392();isc.Element.$136r(this,"translateY(0px)")},isc.A.$148d=function isc_PickListMenu__animateHide(){if(!isc.Browser.$139c||!this.animateTransitions||!this.skinUsesCSSTransitions){var _1=this.$1484;this.animateMove(0,this.getInnerHeight(),function(){_1.hide()},this.animateDuration)}else{this.$148a=false;this.delayCall("$155u",null,100)}},isc.A.$155u=function isc_PickListMenu___animateHide(){this.$1392();isc.Element.$136r(this,"translateY(100%)");if(this.$1484)this.$1484.resizeTo(1,1)},isc.A.getValueIcon=function isc_PickListMenu_getValueIcon(_1,_2,_3){var _4=this.formItem;var _5=_4&&!_4.suppressValueIcons&&(_4.valueIcons!=null||_4.getValueIcon!=null);if(_5){var _6=_4.getValueFieldName(),_7=_4.valueIconField||_4.getDisplayFieldName()||_6;if(this.getFieldName(_1)==_7){return _4.$144(_3[_6])}}
return this.Super("getValueIcon",arguments)},isc.A.getArrowKeyAction=function isc_PickListMenu_getArrowKeyAction(){return this.allowMultiSelect?"focus":"select"},isc.A.rowClick=function isc_PickListMenu_rowClick(_1,_2,_3,_4){this.$119p=_4;this.Super("rowClick",arguments);delete this.$119p},isc.A.recordClick=function isc_PickListMenu_recordClick(_1,_2,_3,_4,_5,_6,_7){var _8=false;if(this.allowMultiSelect&&this.formItem.specialValues&&!this.separateSpecialValues){var _9=this.formItem.specialValues,_10=this.formItem.getValueFieldName(),_6=_2[_10];if(isc.isAn.Array(_9)){for(var i=0;i<_9.length;i++){if(_9[i]==_6){_8=true;break}}}else if(isc.isAn.Object(_9)){if(_9[_6]!=null)_8=true}}
if(!_8&&_2[_1.recordCanSelectProperty]==false)return;var _12;if(this.$119p){var _13=this.ns.EH.getKey(),_14=(_13=="Enter");if(!_14){var _15=this.formItem;if(isc.Canvas.ariaEnabled()&&_15!=null&&_15.ariaRole==="combobox"&&this.body!=null)
{var _16=this.body.getDrawArea()[0];var _17=this.getRowElementId(_3,_3-_16);_15.setAriaState("activedescendant",_17)}
if(_13!="Space"||!_15.allowMultiSelect)return;_12=false}else{_12=true}}else{_12=!this.allowMultiSelect}
if(_8||_12)this.hide();if(_2!=null)this.itemClick(_2)},isc.A.selectOnGeneratedCellClick=function isc_PickListMenu_selectOnGeneratedCellClick(_1,_2,_3,_4){if(this.allowMultiSelect&&isc.EH.getKey()=="Enter")return false;return this.Super("selectOnGeneratedCellClick",arguments)},isc.A.headerClick=function isc_PickListMenu_headerClick(_1,_2){var _3=this.Super("headerClick",arguments);var _4=this.getField(_1);if(this.isCheckboxField(_4)&&this.allowMultiSelect){this.multiSelectChanged()}
return _3},isc.A.multiSelectChanged=function isc_PickListMenu_multiSelectChanged(){var _1=this.formItem,_2=_1.getValueFieldName(),_3=this.getSelection(),_4=!_3||_3.length==0?null:_3.getProperty(_2);_1.pickValue(_4)},isc.A.itemClick=function isc_PickListMenu_itemClick(_1){var _2=this.formItem,_3=_2.getValueFieldName(),_4=_1[_3],_5=null,_6=false,_7=_2.separateValuesList&&_2.separateValuesList.getData().length>0;if(_7){_5=_2.separateValuesList.find(_1)}else if(_2.specialValues){var _8=_2.specialValues;if(isc.isAn.Array(_8)){for(var i=0;i<_8.length;i++){if(_8[i]==_4){_6=true;break}}}else if(isc.isAn.Object(_8)){if(_8[_4]!=null)_6=true}}
if(((_7&&_5==null)||(!_6&&_5==null)||(!_6&&!_7))&&this.allowMultiSelect)
{this.multiSelectChanged()}else{var _3=_2.getValueFieldName();var _10=_2.getDisplayFieldName();var _4=_1[_3];if(isc.PickList.selectAllStoredValue&&_4==isc.PickList.selectAllStoredValue){var _11=this,_8=this.getData(),_12=_2.specialValues||[],_13=[],_14;if(!isc.isAn.Array(_12)){var _15=0;for(var _16 in _12){_13[_15]=_16;_15++}}else{_13=_12}
if(isc.ResultSet&&isc.isA.ResultSet(_8)){if(_8.allMatchingRowsCached()){_14=_8.getAllRows()}else{_14=_8.getAllLoadedRows();isc.warn("<b>selectAllStoredValue</b> is not valid when data paging is enabled. Selecting all loaded rows, behavior from now on is undefined")}}else{_14=_8}
var _17=0;if(!_2.separateSpecialValues)_17=_13.length;for(var i=_17;i<_14.length;i++){_2.pickList.selectRecord(i)}
var _18=_2.pickList.getSelection(),_4=_18.getProperty(_3);_2.setValue(_4)}else{if(isc.PickList.emptyStoredValue&&_4==isc.PickList.emptyStoredValue){_2.pickList.deselectAllRecords();_4=null}
_2.pickValue(_4)}}},isc.A.hide=function isc_PickListMenu_hide(_1,_2,_3,_4){var _5=this.isVisible()&&this.isDrawn();if(this.$1484){this.$148d()}else{this.invokeSuper(isc.PickListMenu,"hide",_1,_2,_3,_4)}
if(!this.formItem)return;if(_5&&this.showModal)this.formItem.focusInItem();this.formItem.$19g=null;if(_5)this.formItem.$19h();delete this.formItem.$19i;this.clearLastHilite()},isc.A.show=function isc_PickListMenu_show(){var _1=this.isVisible()&&this.isDrawn();this.generateClickOnEnter=true;this.generateClickOnSpace=this.allowMultiSelect;if(this.parentElement==null)this.bringToFront();this.Super("show",arguments);if(!_1){this.formItem.$19j()}},isc.A.showClickMask=function isc_PickListMenu_showClickMask(){if(this.$1484){return}
if(!this.clickMaskUp(this.getID())){var _1=this.Super("showClickMask",arguments);if(this.formItem){var _2=this.formItem.form,_3=isc.EH.clickMaskRegistry.find("ID",_1);if(_3.$li)_3.$li=null}}},isc.A.getBaseStyle=function isc_PickListMenu_getBaseStyle(_1,_2,_3,_4,_5,_6){var _7=this.invokeSuper(isc.PickListMenu,"getBaseStyle",_1,_2,_3,_4,_5,_6);var _8=this.formItem;if(isc.isA.SelectItem&&isc.isA.SelectItem(_8)&&_8.multiple&&!_8.$1602&&_8.$161p())
{var _9=this.getField(_3),_10=_8.getValueFieldName();if(this.getField(_10)===_9){var _11=_8.$161a;if(this.isSelected(_1)){if(!_11.has(_1[_10]))_7+="Pending"}else{if(_8.$161r()&&_11.has(_1[_10])){_7+="Deselected"}}}}
return _7},isc.A.getCellCSSText=function isc_PickListMenu_getCellCSSText(_1,_2,_3){if(this.selection!=null&&_1==this.selection.getSelectedRecord()){var _4=[];if(this.hiliteColor!=null){_4[0]=this.$19e;_4[1]=this.hiliteColor;_4[2]=isc.semi}
if(this.hiliteTextColor!=null){_4[3]=this.$19f;_4[4]=this.hiliteTextColor;_4[5]=isc.semi}
return _4.join(isc.emptyString)}},isc.A.keyDown=function isc_PickListMenu_keyDown(){var _1=isc.EH.lastEvent.keyName;if(_1=="Tab"){this.hide();return false}},isc.A.$315=function isc_PickListMenu__formatCellValue(_1,_2,_3,_4,_5){if(this.formItem==null)return this.Super("$315",arguments);var _6=this.getFieldName(_5);_1=this.formItem.formatPickListValue(_1,_6,_2);return this.Super("$315",[_1,_2,_3,_4,_5])},isc.A.bodyKeyPress=function isc_PickListMenu_bodyKeyPress(_1,_2){var _3=isc.EH.lastEvent.keyName;if(isc.Browser.isSafari){if(_3=="Tab"){this.hide();return false}}
var _4=isc.EH.getKeyEventCharacterValue();if(_4!=null){var _5=this.formItem.getAllLocalOptions();if(!_5||_5.length<1){if(this.data&&this.data.localData)_5=this.data.localData}
if(isc.isAn.Array(_5)&&_5.length>1){var _6=String.fromCharCode(_4).toLowerCase(),_7=this.formItem,_8=_7.getValueFieldName(),_9=this.getArrowKeyAction(),_10=_9=="focus"?this.getFocusRow():null;if(_10==null||_10<0){var _11=this.getSelectedRecord();if(_11)_10=_5.indexOf(_11);if(_10==null)_10=-1}
var _12=_10<(_5.length-1)?_10+1:0;var _13=_10>0;var _14=_6;if(_7&&_7.$177l){_7.$177l(_4,true);_14=_7.$177m;if(_14.endsWith(_6+_6)){_7.$177m="";_7.$177l(_4,true);_14=_7.$177m}}
while(_12!=_10){if(_10<0)_10=0;if(!_5[_12]){if(_13){_13=false;_12=0;continue}
return}
var _15=_5[_12][_8];_15=_7.mapValueToDisplay(_15);var _16=_15.replace(/<(?:.|\n)*?>/gm,'').toLowerCase();if(isc.isA.String(_15)&&_15.length>0&&_16.startsWith(_14)){if(!_7.multiple)this.deselectAllRecords();this.scrollRecordIntoView(_12);if(_9=="focus"){this.$88(_12)}else{this.$24x(_12,null,true)}
return}
_12+=1;if(_12>=_5.length)_12=0}}}
if(this.getFocusRow()==null&&_3=="Enter"){this.cancel();return false}
return this.Super("bodyKeyPress",arguments)},isc.A.dataChanged=function isc_PickListMenu_dataChanged(_1,_2,_3,_4){var _5=this.data;if(!_5)return;var _5=this.requestVisibleRows();if(_5&&Array.isLoading(_5[0])){return}
this.Super("dataChanged",arguments);var _6=this.formItem;if(_2&&this.getSelectedRecord()==_2&&_6){var _7=this.data.indexOf(_2),_8=_7==-1?null:this.data.get(_7);if(_8){var _9=_6.getValueFieldName();_6.setValue(_8[_9])}else{_6.clearValue()}}},isc.A.createBodies=function isc_PickListMenu_createBodies(){if(this.body&&this.body.$100r)delete this.body.$100r;this.Super("createBodies",arguments)});isc.B._maxIndex=isc.C+25;isc.PickListMenu.changeDefaults("bodyDefaults",{remapOverStyles:[0,2,2,2,4,6,6,6,8,10,10,10,12],getCellStyleName:function(_1,_2,_3,_4){if(this.grid&&this.grid.showOverAsSelected){_1=this.remapOverStyles[_1]}
return this.Super("getCellStyleName",[_1,_2,_3,_4],arguments)}});isc.PickList.addInterfaceProperties({pickListHeight:300,emptyPickListHeight:100,emptyPickListMessage:"No items to show",pickListMaxWidth:400,pickListBaseStyle:"pickListCell",pickListApplyRowNumberStyle:false,animatePickList:null,pickListAnimationTime:200,fetchDelay:200,pickListCellHeight:16,pickListHeaderHeight:22,allowMultiSelect:true,separateValuesListDefaults:{showHeader:false,autoFitData:"vertical",height:1,_constructor:isc.ListGrid,width:"100%",minHeight:null,leaveScrollbarGap:false,alternateRecordStyles:false,styleName:"pickListMenu",bodyStyleName:"pickListMenuBody",normalCellHeight:16,showOverAsSelected:true,bodyDefaults:{remapOverStyles:[0,2,2,2,4,6,6,6,8,10,10,10,12],getCellStyleName:function(_1,_2,_3,_4){if(this.grid&&this.grid.showOverAsSelected){_1=this.remapOverStyles[_1]}
return this.Super("getCellStyleName",[_1,_2,_3,_4],arguments)}},recordClick:function(_1,_2,_3,_4,_5,_6,_7){if(_2[_1.recordCanSelectProperty]==false)return;_1.pickList.hide();if(_2!=null)_1.pickList.itemClick(_2)},rowOver:function(_1,_2,_3){if(this.pickList.enableSelectOnRowOver)this.pickList.deselectAllRecords()}},fillScreenContainerDefaults:{width:"100%",height:"100%",overflow:"hidden",autoDraw:false},fillScreenContainerConstructor:"Layout",pickListConstructor:"PickListMenu",getPickListClass:function(){if(isc.isA.ClassObject(this.pickListConstructor)){return this.pickListConstructor}else if(isc.isA.String(this.pickListConstructor)){var _1;_1=isc.ClassFactory.getClass(this.pickListConstructor);if(!isc.isAn.Object(_1))_1=isc.PickListMenu;return _1}}});isc.PickList.addInterfaceMethods({showPickList:function(_1,_2){this.$19g=true;var _3=!this.pickList||(this.pickList.formItem!=this);if(!this.pickList)this.makePickList(_1,null,_2);else this.setUpPickList(_1,_2);if(!_1&&(_3||!this.$128z())){this.$19l()}},$19l:function(){var _1=this.pickList;if(!this.isDrawn()||(this.shouldHideEmptyPickList()&&_1.getTotalRows()<1)){return}
this.placePickList();if(!this.$128z()){if(this.separateSpecialValues){if(this.separateValuesList.data&&this.separateValuesList.data.length>0){this.$161l(true)}else if(this.separateValuesList.isVisible()){this.$161l(false)}}else{this.$161l(false)}
if(this.animatePickList){if(_1.$1484){_1.$148c()}else{_1.bringToFront();_1.animateShow("wipe",null,this.pickListAnimationTime)}}else
_1.show()}},$161l:function(_1){var _2=this.pickList,_3=this.separateValuesList,_4=_2.children.find("$161m",true)||_2.gridComponents.find("$161m",true);if(_4==null){this.logWarn("Unable to find container for 'separateValuesList'");return}
if(_3==null){this.logWarn("SeparateValues list not defined for this item")}
if(_1){if(!_4.contains(_3)){if(_4.children.length>0){_4.children[0].deparent()}
_4.addChild(_3)}
_4.setVisibility("inherit")}else{_4.setVisibility("hidden")}},setSeparateSpecialValues:function(_1){this.separateValuesList.setData(_1);if(this.$128z()){this.$161l(true)}},fetchData:function(_1,_2,_3){if(this.getOptionDataSource()==null){this.logWarn("fetchData() called for a non-databound pickList. Ignoring");return}
if(_2==null)_2={};if(_1!=null){_2.internalClientContext={$03:_1}}
_2.componentContext=this.form.ID+"."+this.name;if(!this.pickList){this.makePickList(false,_2,false,!_3)}else{this.setUpPickList(false,false,_2,!_3)}},mapValueToDisplay:function(_1,_2,_3,_4){if(this.isSelectOther){if(_1==this.otherValue)return this.otherTitle;if(_1==this.separatorValue)return this.separatorTitle}
return this.invokeSuper(isc.SelectItem,"mapValueToDisplay",_1,_2,_3,_4)},makePickList:function(_1,_2,_3,_4){var _5=isc.timeStamp();if(!this.separateValuesList){var _6=[];if(this.displayField)_6.add({name:this.displayField});else if(this.valueField)_6.add({name:this.valueField});else _6.add({name:this.name});this.separateValuesList=this.createAutoChild("separateValuesList",{fields:_6,formItem:this,showModal:false,normalBaseStyle:this.pickListBaseStyle,tallBaseStyle:(this.pickListTallBaseStyle||this.pickListBaseStyle),hiliteColor:this.pickListHiliteColor,hiliteTextColor:this.pickListHiliteTextColor})}
var _7=this.reusePickList();if(_7){var _8=this.getSharedPickList();if(_8&&_8.Class==this.getPickListClass().Class)this.pickList=_8}
var _9=this.pickList!=null;if(!this.pickList){var _10=this.pickListProperties||{};if(this.multiple){if(_10.noDoubleClicks==null){_10.noDoubleClicks=true}}else{if(_10.noDoubleClicks==null){_10.noDoubleClicks=false}}
var _11=isc.Canvas.create({autoDraw:false,height:1,overflow:"visible"});if(this.hasPopOutPicker()){if(!this.pickerNavigationBar)this.createPickerNavigationBar();_11.addChild(this.pickerNavigationBar)}else{_11.visibility="hidden"}
var _12=isc.Canvas.create({$161m:true,autoDraw:false,height:1,overflow:"visible",visibility:"hidden"});_12.addChild(this.separateValuesList);var _13=[_11,_12,"filterEditor","header","body","summaryRow"];this.pickList=this.getPickListClass().create({headerHeight:this.pickListHeaderHeight,gridComponents:_13},_10);this.pickList.pickerNavigationBarParent=_11;var _14=this.pickList.dataProperties||{};if(this.filterLocally)_14.fetchMode="local";if(this.useClientFiltering!=null){_14.useClientFiltering=this.useClientFiltering}
_14.fetchRemoteDataReply=function(_17,_14,_2){this.Super("fetchRemoteDataReply",arguments);if(this.$175m){isc.PickList.$85b(this,_17,_14,_2)}}
this.pickList.dataProperties=_14;if(_7)this.storeSharedPickList()}
this.separateValuesList.pickList=this.pickList;if(this.fetchDisplayedFieldsOnly&&this.optionDataSource&&(!this.optionFilterContext||!this.optionFilterContext.outputs))
{var _6=this.pickListFields?this.pickListFields.duplicate():[];if(this.valueField)_6.add(this.valueField);if(this.displayField)_6.add(this.displayField);if(_6.length>0){if(!this.optionFilterContext)this.optionFilterContext={};var _15=[];for(var i=0;i<_6.length;i++){if(isc.isA.String(_6[i])){_15.add(_6[i])}else{_15.add(_6[i].name)}}
this.optionFilterContext.outputs=_15.getUniqueItems().join(',')}}
this.setUpPickList(_1,_3,_2,_4);if(this.logIsInfoEnabled("timing"))
this.logInfo("Time to initially create pickList:"+(isc.timeStamp()-_5),"timing")},cachePickListResults:true,reusePickList:function(){return this.pickListProperties==null&&this.cachePickListResults},getSharedPickList:function(){if(this.$19m()){var _1=this.getOptionDataSource().getID(),_2=isc.PickListMenu.$51t[_1];if(_2){for(var i=0;i<_2.length;i++){if(_2[i].$51u==this.pickListFields){_2[i].$511=isc.timeStamp();var _4=_2[i].$51v;if(_4.destroyed){_2.removeAt(i);this.$82l(_4);i--;continue}
return _4}}}
return null}else{if(isc.PickList.$14w&&isc.PickList.$14w.destroyed){this.$82l(isc.PickList.$14w);isc.PickList.$14w=null;return null}
return isc.PickList.$14w}},$82l:function(_1){if(_1.$513!=null){for(var _2 in _1.$513){if(window[_2]&&window[_2].pickList==_1){delete window[_2].pickList}}}},storeSharedPickList:function(){if(this.$19m()){var _1=this.getOptionDataSource().getID(),_2=isc.PickListMenu.$51t;if(!_2[_1])_2[_1]=[];var _3={$51v:this.pickList,$51u:this.pickListFields,$511:isc.timeStamp()}
_2[_1].add(_3);if(isc.PickListMenu.$512==null){isc.PickListMenu.$512=1}else{isc.PickListMenu.$512+=1;if(isc.PickListMenu.$512>isc.PickListMenu.pickListCacheLimit){var _4,_5=isc.timeStamp();for(var _1 in _2){var _6=_2[_1];for(var i=0;i<_6.length;i++){var _8=_6[i];if(_8.$511<=_5&&(_8!=_3)){_4=_8;_5=_8.$511}}}
if(_4){isc.PickListMenu.$512-=1;var _9=_4.$51v;var _6=_2[_9.getDataSource().getID()];_6.remove(_4);if(_9.$513!=null){for(var _10 in _9.$513){if(window[_10]&&window[_10].pickList==_9)
delete window[_10].pickList}}
_4.$51v.delayCall("destroy")}}}}else{isc.PickList.$14w=this.pickList}},getPickListCellHeight:function(){var _1=this.pickListCellHeight;if(this.pickListProperties&&this.pickListProperties.cellHeight!=null){_1=this.pickListProperties.cellHeight}
if(this.valueIcons!=null||this.getValueIcon!=null){var _2=this.getValueIconHeight();if(_2>_1)_1=_2}
return _1},$152n:function(){if(this.initialSort){if(!isc.isAn.Array(this.initialSort))this.initialSort=[this.initialSort];return this.initialSort.duplicate()}
var _1=this.sortField==null?this.sortFieldNum:this.sortField;if(_1==null)return null;if(isc.isA.Number(_1)){_1=this.sortField=this.getFieldName(_1)}
if(!isc.isAn.Array(_1))_1=[_1];var _2=[];for(var i=0;i<_1.length;i++){_2.add({property:_1[i],direction:this.sortDirection})}
return _2.duplicate()},setUpPickList:function(_1,_2,_3,_4){var _5=this.pickList;if(_5.formItem!==this&&_5.isDrawn()){_5.clear()}
var _6=this.getPickListCellHeight();_5.setCellHeight(_6);if(this.separateValuesList){this.separateValuesList.setCellHeight(_6)}
this.$19n();this.setUpPickListFields();var _7=(this.isEntryTooShortToFilter&&this.isEntryTooShortToFilter());if(!_5.originalEmptyMessage)_5.originalEmptyMessage=_5.emptyMessage;var _8=_5.emptyMessage=(_7?this.getEntryTooShortMessage():this.emptyPickListMessage)||_5.originalEmptyMessage;_5.emptyMessage=_8;var _9=this.$152n();if(_9&&_9.length>0){var _10=this.$19m();var _11=false;if(this.pickList.data&&isc.isA.ResultSet(this.pickList.data)){var _12=this.getOptionDataSource();if(this.pickList.getDataSource()!=_12){_11=true}else{var _13=this.getPickListFilterCriteria(),_14={textMatchStyle:this.textMatchStyle,showPrompt:false};if(this.form){_13=isc.DataSource.resolveDynamicCriteria(_13,this.form.getRuleContext())}
if(this.optionFilterContext!=null){isc.addProperties(_14,this.optionFilterContext)}
if(this.optionOperationId!=null){_14.operationId=this.optionOperationId}
if(_3!=null){isc.addProperties(_14,_3)}
if(!this.pickList.useExistingDataModel(_13,_14.operationId,_14))
{_11=true}}}
if(_11)this.pickList.setData([]);this.pickList.setSort(_9)}
this.filterPickList(_1,_2,_3,_4);this.pickList.emptyMessageHeight=this.emptyPickListHeight;if(!this.hasPopOutPicker()){this.pickList.setWidth(Math.max(1,this.pickListWidth||this.getElementWidth()));var _15,_16=this.pickListProperties;if(_16&&_16.autoFitFieldWidths!=null)_15=_16.autoFitFieldWidths;else _15=this.autoSizePickList&&!this.pickList.showHeader;this.pickList.autoFitFieldWidths=_15;this.pickList.setAutoFitData(_15?"both":"vertical");var _17=1;if(this.pickList.showHeader)_17+=this.pickList.headerHeight;if(this.pickList.showFilterEditor)_17+=this.pickList.filterEditorHeight;this.pickList.setHeight(_17);this.pickList.setAutoFitMaxHeight(this.pickListHeight);this.pickList.setAutoFitMaxWidth(this.pickListMaxWidth)}},$19n:function(){var _1=this.pickList.formItem;if(_1==this)return;var _2={};isc.addProperties(_2,{formItem:this,normalBaseStyle:this.pickListBaseStyle,tallBaseStyle:(this.pickListTallBaseStyle||this.pickListBaseStyle),applyRowNumberStyle:this.pickListApplyRowNumberStyle,hiliteColor:this.pickListHiliteColor,hiliteTextColor:this.pickListHiliteTextColor,showModal:this.modalPickList,dateFormatter:this.dateFormatter,dataArrived:function(_5,_6){if(isc.$cv)arguments.$cw=this;this.Super("dataArrived",arguments);if(this.formItem)this.formItem.handleDataArrived(_5,_6,this.data)},dataChanged:function(_5,_6,_7,_8,_9,_10){this.Super("dataChanged",arguments);if(_5=="remove"&&_6&&this.formItem)this.formItem.handleDataRemoved(_6)},fireSelectionUpdated:function(){if(!this.$188c){this.Super("fireSelectionUpdated",arguments)}}});if(this.multiple&&this.multipleAppearance=="picklist"&&this.allowMultiSelect)
{_2.selectionAppearance="checkbox";_2.allowMultiSelect=true;_2.enableSelectOnRowOver=false;_2.selectionType="simple";_2.$859=false;_2.styleName=isc.ListGrid.getInstanceProperty("styleName");_2.bodyStyleName=isc.ListGrid.getInstanceProperty("bodyStyleName")||"gridBody"}else{_2.selectionAppearance="rowStyle";_2.allowMultiSelect=false;_2.enableSelectOnRowOver=this.pickList.getClass().getInstanceProperty("enableSelectOnRowOver");_2.selectionType="single";_2.$859=true;_2.styleName=this.pickList.getClass().getInstanceProperty("styleName");_2.bodyStyleName=this.pickList.getClass().getInstanceProperty("bodyStyleName")}
if(this.animatePickList)_2.styleName+="Animated";if(this.pickListProperties){isc.addProperties(_2,this.pickListProperties)}
this.pickList.setProperties(_2);if(this.pickList.dataProperties==null)this.pickList.dataProperties={};this.pickList.dataProperties.formItem=this;if(this.pickList.data!=null){this.pickList.data.formItem=this}
if(!this.pickList.$513)this.pickList.$513={};this.pickList.$513[this.getID()]=true;if(_1){if(this.pickList.isObserving(_1.containerWidget,"hide")){this.pickList.ignore(_1.containerWidget,"hide")}
if(this.pickList.isObserving(_1.containerWidget,"clear")){this.pickList.ignore(_1.containerWidget,"clear")}}
if(!this.pickList.isObserving(this.containerWidget,"hide")){this.pickList.observe(this.containerWidget,"hide","observer.hide();")}
if(!this.pickList.isObserving(this.containerWidget,"clear")){this.pickList.observe(this.containerWidget,"clear","if(observer.isDrawn())observer.clear();")}
var _3=this.pickList.pickerNavigationBarParent;if(this.hasPopOutPicker()){if(!this.pickerNavigationBar){this.createPickerNavigationBar()}
var _4=this.getPickerNavigationBarIcons();this.pickerNavigationBar.setIcons(_4);if(!_3.contains(this.pickerNavigationBar)){if(_3.children!=null&&_3.children.length==1){_3.removeChild(_3.children[0])}
_3.addChild(this.pickerNavigationBar)}
_3.setVisibility("inherit")}else{_3.setVisibility("hidden")}
this.pickList.markForRedraw()},iconPlacement:"both",getPickerNavigationBarIcons:function(){if(!this.icons)return null;var _1=[],_2=this.$16j(true);for(var i=0;i<this.icons.length;i++){var _4=this.icons[i];if(!this.$16f(_4,_2,true)||this.$16e(_4))
{continue}
_1.add(_4)}
return(_1.length>0?_1:null)},$128m:function(_1){if(this.$128n)return this.$128n;var _2=null;if(this.specialValues){_2=isc.PickList.optionsFromValueMap(this,this.specialValues);this.$128n=_2}else if(_1&&this.allowEmptyValue&&!this.multiple){var _3=this.getValueFieldName(),_4=this.getDisplayFieldName();var _5={};_5[_3]=null;_2=[_5]}
return _2},getPickListFields:function(){if(this.pickListFields){var _1=this.emptyDisplayValue;if(_1!=null){var _2=this.pickListFields,_3=this.getValueFieldName(),_4=this.getDisplayFieldName(),_5,_6;if((_5=_2.find("name",_4))!=null&&_5.emptyCellValue===_6)_5.emptyCellValue=_1;else if((_5=_2.find("name",_3))!=null&&_5.emptyCellValue===_6)_5.emptyCellValue=_1}
return this.pickListFields}
var _4=this.getDisplayFieldName(),_7;if(_4!=null){_7={width:"*",name:_4}}else{_7={width:"*",name:this.getValueFieldName(),valueMap:this.getAllValueMappings()}}
if(this.canEscapeHTML&&(this.escapeHTML||this.outputAsHTML||this.asHTML))
{_7.escapeHTML=true}
if(this.emptyDisplayValue!=null){_7.emptyCellValue=(this.canEscapeHTML?this.emptyDisplayValue:String(this.emptyDisplayValue).asHTML())}
if(this.dateFormatter!=null){_7.type="date"}
if(this.imageURLPrefix)_7.imageURLPrefix=this.imageURLPrefix;if(this.imageURLSuffix)_7.imageURLSuffix=this.imageURLSuffix;_7.$720=true;return[_7]},formatPickListValue:function(_1,_2,_3){if(this.pickList.getField(_2).$720){return this.$17c(_1)}
return _1},getPickListFilterCriteria:function(){var _1=this.getOptionCriteriaCopy(),_2=isc.DataSource.combineCriteria(_1,this.pickListCriteria,null,this.textMatchStyle);if(_2&&this.form){_2=isc.DataSource.resolveDynamicCriteria(_2,this.form.getRuleContext())}
return _2},getAllLocalOptions:function(){return this.$19m()?null:this.getClientPickListData()},$19o:function(_1,_2,_3){var _4=this.getOptionDataSource(),_5=this.getDisplayFieldName(),_6=this.getValueFieldName();if(_5==null&&_4==null){return}
if((_4==null||!_3)&&(_5==null||_5==_6))return _1;var _7=this.getPickListResultSet();var _8;if(_7!=null){if(isc.isAn.Array(_7)){_8=_7}else{_8=_7.allRows||_7.localData}}
var _9=(_4&&!this.suppressOptionDSCacheAccess?_4.getCacheData():null);if(_8==null){_8=_9;if(_8==null)return}
var _10=(_2?_6:_5||_6),_11=(_2?_5||_6:_6);var _12;if(isc.isAn.Array(_1)){_12="";var _13=isc.shallowClone(_1);for(var i=0;i<_1.length;i++){var _15=_13[i];var _16=_8.find(_11,_1[i]);if(_16==null&&_9!=null&&_8!=_9){_16=_9.find(_11,_1[i])}
if(_16!=null){_12+=_16[_10]}else continue;if(i!=_1.length-1)_12+=this.multipleValueSeparator}}else{var _16=_8.find(_11,_1);if(_16==null&&_9!=null&&_8!=_9){_16=_9.find(_11,_1)}
if(_16!=null){_12=_16[_10]}}
return _12},getPickListResultSet:function(){var _1=this.pickList&&this.pickList.formItem==this&&!this.pickList.destroyed?(this.pickList.originalData||this.pickList.data):null;return _1},$18q:"true",setUpPickListFields:function(){var _1=this.pickList,_2=this.getPickListFields(),_3=_1.fields;var _4=!_3||(_3.length!=_2.length);if(!_4){for(var i=0;i<_2.length;i++){var _6=_2[i],_7=_3[i];for(var _8 in _6){if(_6[_8]!=_7[_8]){_4=true;break}}
if(_4)break}}
if(!_4)return;for(var i=0;i<_2.length;i++){if(_2[i].showIf==null){_2[i].showIf=this.$18q}}
if(this.valueIcons!=null||this.getValueIcon!=null){for(var i=0;i<_2.length;i++){var _6=_2[i];if(_6[this.form.fieldIdProperty]==this.getValueFieldName()){if(_6.valueIconHeight==null)
_6.valueIconHeight=this.valueIconHeight;if(_6.valueIconWidth==null)
_6.valueIconWidth=this.valueIconWidth;if(_6.valueIconSize==null)
_6.valueIconSize=this.valueIconSize;if(_6.imageURLPrefix==null)
_6.imageURLPrefix=this.imageURLPrefix||this.baseURL||this.imgDir;if(_6.imageURLSuffix==null)
_6.imageURLSuffix=this.imageURLSuffix}}}
_1.setFields(_2);var _9;if(this.pickListHeaderHeight==0)_9=false;else if(this.pickListProperties){if(this.pickListProperties.showHeader!=null){_9=this.pickListProperties.showHeader}else if(this.pickListProperties.headerHeight==0){_9=false}};if(_9==null){var _10=_1.getFields();var _11=(this.multiple&&this.multipleAppearance=="picklist"&&this.allowMultiSelect==true)?2:1;_9=(_10.length>_11)}
if(_9){_1.setHeaderHeight(this.pickListHeaderHeight);_1.setShowHeader(true)}else{_1.setShowHeader(false)}},$19m:function(){if(this.optionDataSource)return true;if((this.showOptionsFromDataSource||!this.valueMap)&&this.getOptionDataSource()!=null)return true;return false},$1280:"fetch",$1281:"$19p",filterPickList:function(_1,_2,_3,_4){if(!_2)
this.$19p(_1,_3,null,_4);else{this.$82m=true;this.$43i=_1;this.fireOnPause(this.$1280,{target:this,methodName:this.$1281,args:[null,_3,true,_4]},this.fetchDelay)}},$1282:function(){return this.pendingActionOnPause(this.$1280)},$19p:function(_1,_2,_3,_4){if(_3&&this.pickList.formItem!=this)return;this.$82m=null;if(_3)_1=this.$43i;delete this.$43i;this.$19i=_1;var _5=this.$19m();if(_5){var _6=this.getOptionDataSource();if(this.pickList.getDataSource()!=_6){this.pickList.setDataSource(_6,(this.pickList.completeFields||this.pickList.fields))}
this.filterDataBoundPickList(_2,_4)}else{var _7=this.filterClientPickListData();if(this.pickList.data!=_7)this.pickList.setData(_7);this.filterComplete()}},$61x:function(_1){if(!this.$19m()||!_1)return;var _2=this.getOptionDataSource();if(_1.getDataSource()==_2&&_1.data){var _3=_1.data.context,_4=_1.data.criteria;if(_3&&_3.textMatchStyle!=this.textMatchStyle)return true;if(this.optionFilterContext!=null){for(var _5 in this.optionFilterContext){if(this.optionFilterContext[_5]!=_3[_5])return true}}
var _6=this.getPickListFilterCriteria();if(_6==null)_6={};if(_2.compareCriteria(_4,_6,_3)==0){return false}}
return true},getFirstOptionValue:function(){var _1;if(this.$19m()){var _2=this.pickList||(this.reusePickList()?this.getSharedPickList():null);if(_2&&!this.$61x(_2)){var _3=_2.data.get(0);if(_3==null||Array.isLoading(_3)){_1=null}else{_1=_3[this.getValueFieldName()]}}else{this.fetchData(null,null,true)}}else{var _4=this.valueMap;if(isc.isAn.Array(_4))_1=_4[0];else if(isc.isAn.Object(_4)){for(var _5 in _4){_1=_5;break}}}
if(this.multiple)return[_1];else return _1},getClientPickListData:function(){return isc.PickList.optionsFromValueMap(this)},$957:function(_1){var _2=["moved","parentMoved","scrolled","parentScrolled"];for(var i=0;i<_2.length;i++){var _4=this.pickList.isObserving(this.containerWidget,_2[i]);if(_1){if(!_4)this.pickList.observe(this.containerWidget,_2[i],_1)}else{if(_4)this.pickList.ignore(this.containerWidget,_2[i])}}},$19h:function(){if(isc.Canvas.ariaEnabled()){this.setAriaState("expanded",false);this.clearAriaState("owns");this.clearAriaState("activedescendant")}
this.$957();if(this.pickListHidden)this.pickListHidden()},$19j:function(){if(isc.Canvas.ariaEnabled()){this.setAriaState("expanded",true);this.setAriaState("owns",this.pickList.$16aj())}
this.$957("observer.moveBy(deltaX,deltaY)");if(this.pickListShown)this.pickListShown()},selectDefaultItem:function(){if(this.pickList==null)return false;this.pickList.deselectAllRecords();return this.selectItemFromValue(this.getValue())},selectItemFromValue:function(_1,_2){if(this.pickList)this.pickList.clearLastHilite();if(!isc.isAn.Array(_1))_1=[_1];var _3=this.pickList.getSelection(),_4=this.getValueFieldName(),_5=true,_6,_7=false;var _8=this.getType(),_9=isc.SimpleType.inheritsFrom(_8,"text")||isc.SimpleType.inheritsFrom(_8,"integer")||isc.SimpleType.inheritsFrom(_8,"float"),_10=_9?null:this.compareValues;if(this.pickList.allowMultiSelect){var _11=this.pickList.$188c;this.pickList.$188c=true}
for(var i=0;i<_1.length;i++){var _13=_1[i],_14;if(this.separateValuesList){var _15=this.separateValuesList.getData(),_16=_15!=null&&_15.find(_4,_13);if(_16){this.separateValuesList.selectSingleRecord(_16);_7=true}}
if(_3.find(_4,_13))continue;var _15=this.pickList.getData();if(isc.ResultSet&&isc.isA.ResultSet(_15)){var _17=_15.localData;if(_17)_14=_17.find(_4,_13,_10)}else{_14=_15.find(_4,_13,_10)}
if(_14&&_14!=Array.LOADING){if(this.pickList.allowMultiSelect){this.pickList.selectRecord(_14)}else{this.pickList.selection.selectSingle(_14);this.pickList.fireSelectionUpdated()}
_6=_15.indexOf(_14)}else{_5=false}}
if(!_2&&_6!=null)this.pickList.scrollRecordIntoView(_6);if(!_7&&this.selection!=null){this.separateValuesList.deselectAllRecords()}
if(this.pickList.allowMultiSelect){this.pickList.$188c=_11}
return _5},filterComplete:function(_1,_2,_3,_4){if(!_4&&_3!=null&&_3.clientContext!=null){var _5=this.$84p,_6=_3.clientContext.fetchID;if(_5==null||_5<_6){this.$84p=_6}else{this.logWarn("Server returned out of order responses for databound fetch requests. Ignoring superceded request results");return}}
this.$43j=false;if(this.pickList.$85a!=null&&this.getID()!==this.pickList.$85a)
{}else{if(this.getID()===this.pickList.$85a){this.pickList.$85a=null}
this.$958=true;this.$82n(_1,_2,_3);this.pickList.$188c=true;this.$82o(_1,_2,_3);this.pickList.$188c=false;this.$958=false;if(isc.Canvas.ariaEnabled()){if(this.pickList.$85a==null||this.getID()===this.pickList.$85a||_4)
{this.pickList.clearAriaState("busy")}}}
var _7=(_3&&_3.internalClientContext?_3.internalClientContext.$03:null);if(_7){this.fireCallback(_7,"item,dsResponse,data,dsRequest",[this,_1,_2,_3]);if(_3&&_3.internalClientContext){delete _3.internalClientContext.$03}}},$82n:function(_1,_2,_3){var _4=this.pickList;if(!_4||_4.destroyed)return;if(_4.formItem!=this)return;var _5=_4.hasFocus||(_4.body&&_4.body.hasFocus);var _2=_4.getData();if(this.hasPopOutPicker())return;if(_2.getLength()==0&&this.$128z()){if(this.hideEmptyPickList){_4.hide();if(_5)this.focusInItem()}else if(this.allowPickListToClip){var _6=this.getPickListPosition();_4.setRect([_6[0],_6[1]])}else{isc.PickList.$114o(this,_4,this.separateValuesList)}}else{if(this.$19i)this.$19l();else if(this.$128z())this.placePickList();_4.setHeight(1);_4.setAutoFitData(_4.autoFitData);delete this.$19i}},$82o:function(_1,_2,_3){this.selectDefaultItem();if(_1!=null&&_2!=null){this.$848(_2);this.updateDisplayValueMap(false)}
if(this.$43k){delete this.$43k;this.$43f(this._value)}
this.$19v()},isUnknownValue:function(_1){var _2=this.getValueMap();if(_2!=null){if(isc.isAn.Array(_2)){if(_2.contains(_1))return false}else if(isc.isAn.Object(_2)){for(var _3 in _2){if(_2[_3]==_1)return false}}}
var _4=this.getOptionDataSource();if(_4!=null){return this.$19o(_1,true,true)==null}
return true},$19v:function(){if(this.isDrawn()&&this.getValueFieldName()!=null&&this.$19m())
{if(this.isA("ComboBoxItem")){if(this.changeOnKeypress&&this.addUnknownValues==true&&!this.isUnknownValue(this.getElementValue()))
{this.updateValue()}
if(this.hasFocus)return}
var _1;if(!this.$10v())_1=this.getValue();else{if(this.isA("SelectItem"))_1=this.$19w;else _1=this.mapDisplayToValue(this.getElementValue())}
var _2=this.getSelectedRecord();if(_2){var _3=this.mapValueToDisplay(_1);if(this.$19z!=_3){this.$127m(_1);this.setElementValue(_3);this.$127l()}}}},$84q:0,filterDataBoundPickList:function(_1,_2){if(isc.$cv)arguments.$cw=this;if(this.isEntryTooShortToFilter&&this.isEntryTooShortToFilter()){var _3=this.pickList.originalData||this.pickList.data;if(_3&&isc.ResultSet&&isc.isA.ResultSet(_3)){this.pickList.setData([])}
this.filterComplete();return}
var _4=this.getPickListFilterCriteria(),_5={textMatchStyle:this.textMatchStyle,showPrompt:false};if(this.form){_4=isc.DataSource.resolveDynamicCriteria(_4,this.form.getRuleContext())}
if(this.pickList.ignoreEmptyCriteria){_4=isc.DataSource.filterCriteriaForFormValues(_4)}
if(this.optionFilterContext!=null)isc.addProperties(_5,this.optionFilterContext);if(this.optionOperationId!=null)_5.operationId=this.optionOperationId;if(_1!=null){isc.addProperties(_5,_1)}
var _6=false,_7=false;var _3=this.pickList.originalData||this.pickList.data;if(_3&&isc.ResultSet&&isc.isA.ResultSet(_3)){_3.$1283=true;if(_2){_3.$394()}else{if(!_3.willFetchData(_4,this.textMatchStyle)){if(!_3.lengthIsKnown()||(_3.getLength()!=0&&!_3.rowIsLoaded(0))){_6=true}else{_7=true}}}
if(!_6){_5.fetchID=this.$84q++;_3.$175m=false}}
this.pickList.filterData(_4,{target:this,methodName:"filterComplete"},_5);if(_7&&this.pickList.data.getLength()>0&&(this.pickList.data.rowIsLoaded&&!this.pickList.data.rowIsLoaded(0)))
{this.logInfo("filterData with new criteria caused async fetch even though data.willFetchData() returned false.","pickListFilter");_7=false}
if(_7)this.filterComplete();else{this.$43j=true;if(isc.Canvas.ariaEnabled()){this.pickList.setAriaState("busy",true);this.clearAriaState("activedescendant")}
var _8=this.pickList.data;if(!_6){this.pickList.$85a=this.getID();this.pickList.$39v=_8.$39r}else{_8.$175m=true;if(_3!=_8)_3.$175m=false;this.pickList.$85a=this.getID();this.pickList.$85c=_8.$39r}}},handleDataArrived:function(_1,_2,_3){if(this.defaultToFirstOption&&this.getValue()==null&&_1==0){this.setToDefaultValue()}
this.$19v();this.$848(_3.getRange(_1,_2));var _4=this.$958;this.$958=true;this.updateDisplayValueMap(false);this.$958=_4;if(this.dataArrived)this.dataArrived(_1,_2,_3)},dataArrived:function(_1,_2,_3){},handleDataRemoved:function(_1){if(this.$128n==null)return;var _2=this.getValueFieldName(),_3=this.getDisplayFieldName(),_4=_1[_2],_5=this.$128n;for(var i=0;i<_5.length;i++){var _7=_5[i];if(_7[_2]==_4){_5.removeAt(i);if(this.pickList.isVisible()&&this.pickList.isDrawn()){if(!this.separateSpecialValues){this.filterPickList()}}
break}}},textMatchStyle:"startsWith",$19q:"substring",separatorRows:[{isSeparator:true}],filterClientPickListData:function(){if(this.isEntryTooShortToFilter&&this.isEntryTooShortToFilter())return null;var _1=this.getClientPickListData();var _2=this.getPickListFilterCriteria();if(_2==null||isc.isA.emptyObject(_2))return _1;var _3=[],_4;if(this.showAllOptions)_4=this.separatorRows.duplicate();var _5=false;for(var _6 in _2){var _7=_2[_6];if(!_7||isc.isA.emptyString(_7))continue;_5=true;if(!isc.isAn.Array(_7))_7=[_7];for(var _8=0;_8<_7.length;_8++){var _9=_7[_8];if(!isc.isA.String(_9))_9+=isc.emptyString;_9=_9.toLowerCase();var _10=_1.getLength(),_11=this.getValueFieldName();for(var i=0;i<_10;i++){var _13=_1[i][_6];if(this.filterDisplayValue&&_6==_11){_13=this.mapValueToDisplay(_13)}
if(!isc.isA.String(_13))_13+="";_13=_13.toLowerCase();if((this.textMatchStyle==this.$19q&&!_13.contains(_9))||(this.textMatchStyle!=this.$19q&&!isc.startsWith(_13,_9)))
{if(this.showAllOptions)_4.add(_1[i])}else{_3.add(_1[i])}}}}
if(!_5)_3=_1.duplicate();if(this.showAllOptions&&_4.length>1)_3.addList(_4);return _3},shouldHideEmptyPickList:function(){if(this.hideEmptyPickList!=null)return this.hideEmptyPickList;return!this.$19m()},$128z:function(){var _1=this.pickList;return(_1==null?false:_1.isDrawn()&&_1.isVisible())},getPickListPosition:function(){var _1=this.getPageLeft();if(this.containerWidget.isRTL()&&this.pickList){_1+=this.getWidth();_1-=this.pickList.getVisibleWidth()}
return[this.getPageLeft(),this.getPageTop()+this.getHeight()]},placePickList:function(){var _1=this.pickList;var _2=this.getPickListPlacement();if(_2!="nearOrigin"){var _3;if(_2=="halfScreen"){_3=[isc.Page.getScrollLeft(),isc.Page.getScrollTop()+parseInt(isc.Page.getHeight()/2),isc.Page.getWidth(),isc.Page.getHeight()/2]}else{var _4;if(isc.isA.Canvas(_2))_4=_2;else if(_2=="fillPanel"){_4=this.containerWidget;while(_4!=null){if(isc.isA.SplitPane(_4)){if(_4.navigationPane&&_4.navigationPane.contains(this.containerWidget))
{_4=_4.navigationPane}else if(_4.listPane&&_4.listPane.contains(this.containerWidget))
{_4=_4.listPane}else if(_4.detailPane&&_4.detailPane.contains(this.containerWidget))
{_4=_4.detailPane}
break}else{_4=_4.getParentCanvas()}}}
if(_4!=null){_3=_4.getPageRect()}else{_3=[isc.Page.getScrollLeft(),isc.Page.getScrollTop(),isc.Page.getWidth(),isc.Page.getHeight()];var _5=this.$1485();if(_5){_5.setRect(_3)}}}
_1.setRect(_3)}else{if(_1.isDirty()||(_1.body&&_1.body.isDirty())){_1.redraw("Refreshing stale pickList content before positioning")}else if(!_1.isDrawn()){isc.Canvas.moveOffscreen(_1);_1.setVisibility("hidden");_1.draw()}
if(this.allowPickListToClip){var _6=this.getPickListPosition(),_7=_6[0],_8=_6[1];_1.setRect([_7,_8])}else{isc.PickList.$114o(this,_1,this.separateValuesList)}}},$1485:function(){if(this.animatePickList&&this.pickList.$1484==null){this.pickList.$1484=this.createAutoChild("fillScreenContainer",{children:[this.pickList]})}
return this.pickList.$1484},pickValue:function(_1){},getPickListPlacement:function(){if(this.pickListPlacement!=null){var _1=this.pickListPlacement;if(isc.isA.String(_1)){var _2=isc.Canvas.getById(_1);if(_2!=null)_1=_2}
return _1}
return isc.Browser.isHandset||isc.Browser.isTablet?"fillPanel":"nearOrigin"},pickerNavigationBarConstructor:isc.NavigationBar,pickerNavigationBarDefaults:{getIconButton:function(_1){if(this.$146w==null)this.$146w=[];for(var i=0;i<this.$146w.length;i++){if(_1==this.$146w[i].icon){return this.$146w[i].iconButton}}
var _3=this.creator;var _4=false,_5=_3.$54o(_1,true),_6=_3.iconIsDisabled(_1);var _7=this.createAutoChild("iconButton",{_constructor:isc.Img,icon:_1,src:_3.getIconURL(_1,_4,_6,_5),styleName:_3.getIconStyle(_1,_4,_6,_5),backgroundColor:_1.backgroundColor,height:_3.getIconHeight(_1),width:_3.getIconWidth(_1),prompt:_3.getIconPrompt(_1),layoutAlign:"center",canFocus:!_1.imgOnly,click:function(){_3.$116(this.icon)},keyPress:function(){_3.$172(this.icon)}});this.$146w.add({icon:_1,iconButton:_7});return _7},setIcons:function(_1){if(this.iconButtons!=null){this.removeMembers(this.iconButtons);for(var i=0;i<this.iconButtons.length;i++){var _3=this.iconButtons[i];if(isc.isA.LayoutSpacer(_3))_3.destroy();if(!this.icons||!this.icons.contains(_3.icon)){var _4=_3.icon;_3.destroy();this.$146w.removeWhere("icon",_4)}}}
if(_1==null){this.iconButtons=null}else{this.iconButtons=[];for(var i=0;i<_1.length;i++){if(_1[i].hspace){this.iconButtons.add(isc.LayoutSpacer.create({width:_1[i].hspace}))}
this.iconButtons.add(this.getIconButton(_1[i]))}
this.addMembers(this.iconButtons)}}},createPickerNavigationBar:function(){this.pickerNavigationBar=this.createAutoChild("pickerNavigationBar")},hasPopOutPicker:function(){var _1=this.getPickListPlacement();return(_1!="nearOrigin")}});isc.A=isc.PickList;isc.A.selectAllStoredValue="**selectAllValues**";isc.A.emptyStoredValue="**emptyValue**";isc.A.$146x={$16f:function pickListInterface_shouldShowIcon(_1,_2,_3){if(!this.Super("$16f",arguments)){return false}
if(_1==this.getPickerIcon())return!_3;var _4=_1.iconPlacement;if(_4==null)_4=this.iconPlacement;if(_4=="both")return true;return _3?(_4=="pickerNavigationBar"):(_4=="formItem")}};isc.A=isc.PickList;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.$85b=function isc_c_PickList__sharedPickListFetchComplete(_1,_2,_3,_4){var _5=_4.componentId,_6=window[_5];if(_6==null){this.logWarn("$85b - unable to get shared pickList which initialized fetch");return}
if(_6.$85c!=_4.internalClientContext.requestIndex){return}
var _7=_6.$85a;if(!_7){this.logWarn("$85b - unable to determine current target formItem");return}
_7=window[_7];_1.$175m=false;if(!_7){return}
_7.filterComplete(_2,_3,_4,true)},isc.A.optionsFromValueMap=function isc_c_PickList_optionsFromValueMap(_1,_2,_3){var _4=_2||_1.getValueMap(),_5=[];if(_4==null)_4=[];var _6=_1.getValueFieldName(),_7=_1.getDisplayFieldName();if(isc.isAn.Array(_4)){for(var i=0;i<_4.length;i++){_5[i]={};var _9=_4[i];if(_3&&_9==_3)_9=null;_5[i][_6]=_9;if(_7!=null)_5[i][_7]=_9}
_5.$882=true}else if(isc.isAn.Object(_4)){var i=0;var _10=_1.getType(),_11,_12,_13;if(_10!=null){if(isc.SimpleType.inheritsFrom(_10,"integer"))
{_11=true}else if(isc.SimpleType.inheritsFrom(_10,"float")){_12=true}else if(isc.SimpleType.inheritsFrom(_10,"boolean")){_13=true}}
for(var j in _4){_5[i]={};var _15=j;if(_11){var _16=parseInt(_15);if(_16==_15)_15=_16}else if(_12){var _17=parseFloat(_15);if(_17==_15)_15=_17}else if(_13){var _18=(_15=="true"?true:(_15=="false"?false:null));if(_18!=null)_15=_18}
_5[i][_6]=_15;if(_7!=null)_5[i][_7]=_4[j];i++}
_5.$882=true}
return _5},isc.A.$114p=function isc_c_PickList__placePickListRect(_1,_2,_3,_4,_5,_6){var _7=isc.Page.getWidth(),_8=isc.Page.getHeight(),_9=isc.Page.getScrollLeft(true),_10=isc.Page.getScrollTop(),_11=(_7+_9),_12=(_8+_10),_13=Math.max(_9,Math.min(_11,_3[0])),_14=Math.max(_10,Math.min(_12,_3[1])),_15=Math.max(_9,Math.min(_11,_3[0]+_3[2])),_16=Math.max(_10,Math.min(_12,_3[1]+_3[3]));var _17=0,_18=null,_19=1;for(var i=0;i<4;++i){var _21=((i%2==0)!=_6?_11-_13:_15-_9),_22=(i<2?_12-_16:_14-_10),_23=Math.min(_1,_21),_24=Math.min(_2,_22);if(_23==_1&&_24==_2){_17=i;break}
if(_23>=_4&&_24>=_5){var _25=_23*_24;if(_18==null||_25>_18){_18=_25;_17=i}}}
var _26=((_17%2==0)!=_6?_11-_13:_15-_9),_27=(_17<2?_12-_16:_14-_10),_28=Math.min(_1,_26),_29=Math.min(_2,_27),_30=((_17%2==0)!=_6?_13:_15-_28),_31=(_17<2?_16:_14-_29);return[_30,_31,_28,_29]},isc.A.$114o=function isc_c_PickList__placeAdjacent(_1,_2,_3){var _4=_2.getPeerRect(),_5=_4[2],_6=_4[3],_7=_1.getPeerRect(),_8=(_3&&_3.data&&_3.data.getLength()>0?_3.getVisibleHeight():0),_9=((!_1.shouldHideEmptyPickList()&&_2.getTotalRows()<1&&_1.emptyPickListHeight)||0),_10=Math.max(1,_9,_2.getHeaderHeight()+_8),_11=Math.max(1,_1.pickListWidth||0),_12=_1.containerWidget.isRTL(),_13=isc.PickList.$114p(_5,_6,_7,_11,_10,_12);var _14=_13[2],_15=_13[3];if(_5>_14){_2.setAutoFitMaxWidth(_14)}
if(_6>_15){_2.setAutoFitMaxHeight(_15-_8)}else{_13[3]-=_8}
_2.setPageRect(_13)});isc.B._maxIndex=isc.C+4}
isc.ClassFactory.defineClass("NativeSelectItem","FormItem");isc.A=isc.NativeSelectItem;isc.A.DEFAULT_ROW_COUNT=6;isc.A.instances=[];isc.NativeSelectItem.addProperties(isc.$19s)
isc.A=isc.NativeSelectItem.getPrototype();isc.A.height=null;isc.A.stopNavKeyPressBubbling=true;isc.A.$125=true;isc.A.$15i=true;isc.A.textBoxStyle="nativeSelectItem";isc.A.showRTL=true;isc.A.$16b={onchange:isc.FormItem.$12y};isc.A=isc.NativeSelectItem;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.getOptionsHTML=function isc_c_NativeSelectItem_getOptionsHTML(_1,_2){var _3=isc.SB.create();if(isc.isAn.Array(_1)){for(var i=0,_5=_1.length;i<_5;i++){var _6=_1[i];_3.append(this.$196(_6,_6,_2))}}else{for(var _6 in _1){var _7=_1[_6];_3.append(this.$196(_6,_7,_2))}}
return _3.release(false)},isc.A.$196=function isc_c_NativeSelectItem__getOptionHTML(_1,_2,_3){var _4=this.$197;if(!_4){this.$198=" SELECTED ";_4=this.$197=[];_4[0]="<OPTION ";_4[2]=' VALUE="';_4[4]='">';_4[6]="</OPTION>"}
_4[1]=(_1==_3?this.$198:null);_4[3]=_1;_4[5]=_2;return _4.join(isc.$ad)},isc.A.getOptionCount=function isc_c_NativeSelectItem_getOptionCount(_1){if(isc.isAn.Array(_1)){return _1.length}else{var _2=0;for(var _3 in _1){_2++}
return _2}});isc.B._maxIndex=isc.C+3;isc.A=isc.NativeSelectItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.textMatchStyle="startsWith";isc.B.push(isc.A.getPickListFilterCriteria=function isc_NativeSelectItem_getPickListFilterCriteria(){var _1=this.optionCriteria||{};return isc.addProperties(_1,this.pickListCriteria)},isc.A.init=function isc_NativeSelectItem_init(){this.Super("init",arguments);isc.NativeSelectItem.instances.add(this);if(this.optionDataSource){var _1=this.getOptionDataSource();var _2=this.getValueFieldName();var _3=this.getDisplayFieldName();var _4=this;var _5={textMatchStyle:this.textMatchStyle,showPrompt:false};if(this.optionFilterContext!=null)isc.addProperties(_5,this.optionFilterContext);if(this.optionOperationId!=null)_5.operationId=this.optionOperationId;var _6=this.getPickListFilterCriteria();_1.fetchData(_6,function(_10,_11){var _7;if(!_3)_7=[];else _7={};for(var i=0;i<_11.getLength();i++){var _9=_11[i];if(!_3){_7.add(_9[_2])}else{_7[_9[_2]]=_9[_3]}}
_4.setValueMap(_7)},_5)}},isc.A.destroy=function isc_NativeSelectItem_destroy(){isc.NativeSelectItem.instances.remove(this);this.Super("destroy",arguments)},isc.A.getTextBoxCellCSS=function isc_NativeSelectItem_getTextBoxCellCSS(){return this.$136},isc.A.setElementReadOnly=function isc_NativeSelectItem_setElementReadOnly(_1){this.$176(!_1&&!this.isDisabled())},isc.A.getElementHTML=function isc_NativeSelectItem_getElementHTML(_1,_2){this.$199=false;var _3=this.form,_4=_3.getID(),_5=isc.StringBuffer.create(),_6=this.getItemID(),_7=isc.$ad,_8=this.$xq(_2),_9="";if(this.showValueIconOnly)return _8;if(_8!=null)_5.append(_8);if(this.$68y()||this.renderAsStatic()){if(this.printFullText){_9=isc.StringBuffer.concat("<SPAN ",this.getElementStyleHTML(),">",_2==null?"&nbsp;":_2.asHTML(),"</SPAN>")}else{_9=isc.StaticTextItem.$b4.getElementHTML.apply(this,arguments)}}else{_5.append("<SELECT"," NAME=",this.getElementName()," ID=",this.getDataElementId(),this.$155(),(!this.showTitle&&this.accessKey!=null?" ACCESSKEY="+this.accessKey:_7),((this.isReadOnly()||this.isDisabled())?" DISABLED ":_7),this.getElementStyleHTML(),(this.multiple?" MULTIPLE":_7)," TABINDEX=",this.$154()," handleNativeEvents=false>");_5.append(this.getOptionsHTML(this.getValueMap()));_5.append("</SELECT>");_9=_5.release(false)}
return _9},isc.A.$12z=function isc_NativeSelectItem__handleElementChanged(_1){if(isc.Browser.isIE&&!_1){isc.Timer.setTimeout(this.getID()+".$12z(true)",10);return true}
return this.form.elementChanged(this.getID())},isc.A.$12x=function isc_NativeSelectItem__nativeElementBlur(_1,_2){var _3=this.Super("$12x",arguments);if(this.changeOnBlur)this.form.elementChanged(this)},isc.A.getOptionsHTML=function isc_NativeSelectItem_getOptionsHTML(_1){var _2=isc.NativeSelectItem.getOptionsHTML(_1?_1:this.getValueMap());if(this.isSelectOther){_2+="<OPTION VALUE=\""+this.separatorValue+"\">"+this.separatorTitle+"<OPTION VALUE=\""+this.otherValue+"\">"+this.otherTitle}
return _2},isc.A.getOptionCount=function isc_NativeSelectItem_getOptionCount(_1){return isc.NativeSelectItem.getOptionCount(_1?_1:this.getValueMap())},isc.A.getTextBoxStyle=function isc_NativeSelectItem_getTextBoxStyle(){if(this.$68y())return isc.TextItem.getInstanceProperty("textBoxStyle");else return this.Super("getTextBoxStyle",arguments)},isc.A.getElementStyleHTML=function isc_NativeSelectItem_getElementStyleHTML(){var _1=isc.SB.create(),_2=isc.SB.create();if(this.textBoxStyle!=null)_1.append(" CLASS='",this.getTextBoxStyle(),"' ");if(this.multiple||this.rows){var _3=this.rows;if(!isc.isA.Number(_3)||_3<1)
_3=Math.min(isc.NativeSelectItem.DEFAULT_ROW_COUNT,this.getOptionCount());if(this.height){if(isc.isA.Number(this.height))_2.append("HEIGHT:",this.height,"px;")}
_1.append(" SIZE=",_3)}
if(isc.Browser.isDOM){var _4=this.getElementWidth();if(isc.isA.Number(_4)){_4=Math.max(_4,1);_2.append("WIDTH:",_4,"px;")}
if(isc.Browser.isMoz){_2.append("-moz-user-focus:",(this.$154()>0?"normal;":"ignore;"))}
_2.append("margin-top:0px;margin-bottom:0px;");_2=_2.release(false);if(_2.length>0)_1.append(" STYLE='",_2,"'")}
return _1.release(false)},isc.A.$16z=function isc_NativeSelectItem__iconVisibilityChanged(){if(!isc.isA.Number(this.width))return;return this.Super("$16z",arguments)},isc.A.$16m=function isc_NativeSelectItem__getIconVMargin(){return 0},isc.A.mapValueToDisplay=function isc_NativeSelectItem_mapValueToDisplay(_1){if(isc.isAn.Array(_1)){var _2=[];for(var i=0;i<_1.length;i++){_2[i]=this.mapValueToDisplay(_1[i])}
return _2}
return this.Super("mapValueToDisplay",arguments)},isc.A.setElementValue=function isc_NativeSelectItem_setElementValue(_1,_2){if(arguments.length==1)_2=_1;var _3=this.getDataElement();if(!_3)return null;var _4=_3.options;if(!_4){this.logDebug("setElementValue(): element.options is null. ???");return null}
this.$17j(_2);if(!this.multiple){if(_2==null)_2="";for(var i=0;i<_4.length;i++){if(_4[i].value==_2){if(_3.selectedIndex!=i){_3.selectedIndex=i}
return _3.selectedIndex}}
for(var i=0;i<_4.length;i++){if(_4[i].text==_2){if(_3.selectedIndex!=i){_3.selectedIndex=i}
_3.selectedIndex=i;return _3.selectedIndex}}
if(this.addUnknownValues){if(isc.Browser.isIE){var _6=0;if(this.$199){_4[_6].text=_1;_4[_6].value=_2}else{_4.add(new Option(_2,_1),_6);this.$199=true}}else{if(this.$199){var _6=_4.length-1;_4[_6].value=_2;_4[_6].text=_1}else{var _6=_4.length;_4[_6]=new Option(_2,_1);this.$199=true}}
if(_3.selectedIndex!=_6){_3.selectedIndex=_6}
return _3.selectedIndex}else{return null}}else{if(_2==null){_2=[]}else if(isc.isA.String(_2)&&_2.contains(",")){_2=_2.split(",")}else if(!isc.isAn.Array(_2)){_2=[_2]}else{_2=_2.duplicate()}
if(_1==null){_1=[]}else if(isc.isA.String(_1)&&_1.contains(",")){_1=_1.split(",")}else if(!isc.isAn.Array(_1)){_1=[_1]}else{_1=_1.duplicate()}
for(var i=0;i<_4.length;i++){var _7=_3.options[i];var _8=_2.indexOf(_7.value);if(_8>-1){if(_7.selected!=true)_7.selected=true;_2.removeItem(_8)}else{if(_7.selected!=false)_7.selected=false}}
if(_2.length!=0){for(var i=0;i<_4.length;i++){var _7=_3.options[i];var _8=_2.indexOf(_7.text);if(_8>-1){if(_7.selected!=true)_7.selected=true;_2.removeItem(_8)}}}
if(_2.length!=0&&this.addUnknownValues){for(var i=0;i<_2.length;i++){var _9=_4[_4.length]=new Option(_2[i],_1[i]);_9.selected=true}}
return _2}},isc.A.getElementValue=function isc_NativeSelectItem_getElementValue(){var _1=this.getDataElement();if(!_1)return null;var _2=_1.options;if(!_2||_2.length==0)return null;if(!this.multiple){var _3=_2[_1.selectedIndex];if(!_3)return null;return(_3.value!=null?_3.value:_3.text)}else{var _4=[];for(var i=0;i<_2.length;i++){var _3=_2[i];if(_3.selected){_4.add(_3.value!=null?_3.value:_3.text)}}
if(_4.length==0)return null;return _4}},isc.A.setElementValueMap=function isc_NativeSelectItem_setElementValueMap(_1){this.$199=false;this.Super("setElementValueMap",arguments);var _2=this.getDataElement();if(_2==null)return;var _3=_2.options;_3.length=0;if(isc.isAn.Array(_1)){for(var i=0;i<_1.length;i++){_3[i]=new Option(_1[i],_1[i])}}else{for(var _5 in _1){_3[_3.length]=new Option(_1[_5],_5)}}
if(this.isSelectOther){_3[_3.length]=new Option(this.separatorTitle,this.separatorValue);_3[_3.length]=new Option(this.otherTitle,this.otherValue)}},isc.A.updateValue=function isc_NativeSelectItem_updateValue(){if(this.isSelectOther){if(!this.hasElement()||this.getDataElement()==null)return;var _1=this._value,_2=this.getElementValue();if(_2==this.separatorValue){this.setValue(_1);return false}
if(_2==this.otherValue){var _3=this.getValueMapTitle(_1);_2=prompt("Other value for \r'"+this.getTitle()+"'?",(_3?_3:""));if(_2==null){this.setValue(_1);return false}
this.setElementValue(_2)}}
return this.Super("updateValue",arguments)});isc.B._maxIndex=isc.C+19;if(isc.ListGrid!=null){isc.ClassFactory.defineClass("SelectItem","FormItem");isc.defer("if (isc.SelectItem.$b4.animatePickList == null) isc.SelectItem.addProperties({ animatePickList: isc.Browser.isHandset || isc.Browser.isTablet });");if(isc.PickList)isc.SelectItem.addMethods(isc.PickList.$146x)
isc.$19s={textBoxStyle:"selectItemText",printTextBoxStyle:"textItem",height:19,width:150,dirtyOnKeyDown:false,changeOnKeypress:false,redrawOnShowIcon:false,addUnknownValues:true,autoSizePickList:true,multipleAppearance:"picklist",separatorTitle:"--------------------",separatorValue:"----",otherTitle:"Other...",otherValue:"***other***"};isc.SelectItem.addProperties(isc.$19s)
isc.A=isc.SelectItem.getPrototype();isc.A.showPickerIcon=true;isc.A.emptyDisplayValue="&nbsp;";isc.A.controlStyle="selectItemControl";isc.A.pickerIconStyle="selectItemPickerIcon";isc.A.canFocus=true;isc.A.showFocused=true;isc.A.pickerIconSrc="[SKIN]/DynamicForm/SelectItem_PickButton_icon.gif";isc.A.pickerIconDefaults={tabIndex:-1,click:isc.Class.NO_OP};isc.A.clipValue=true;isc.A.showOver=true;isc.A.updateTextBoxOnOver=false;isc.A.updateControlOnOver=false;isc.A.modalPickList=true;isc.A.changeOnValueChange=true;isc.A.changeOnKeyboardNavigation=true;isc.A.canSelectText=false;isc.A.allowEmptyValue=false;isc.A.autoFetchData=true;isc.A.saveOnEnter=true;isc.A.openOnSpace=false;isc.A.openOnDownArrow=false;isc.A=isc.SelectItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$20u="Page_Up";isc.A.$20v="Page_Down";isc.A.pickerExitButtonDefaults={_constructor:"NavigationButton",click:function(){this.creator.pickerExitButtonClick()}};isc.A.pickerExitButtonTitle="Done";isc.A.emptyPickListMessage="No items to show";isc.A.allowMultiCharSearch=true;isc.A.$177n=500;isc.A.selectOtherPrompt="Other value for <br>${item.getTitle()}?";isc.A.dialogWidth=250;isc.A.canEscapeHTML=true;isc.A.$161s=new String("<span aria-hidden='true'>");isc.A.$161t=new String("</span>");isc.B.push(isc.A.init=function isc_SelectItem_init(){if(this.specialValues&&this.allowEmptyValue){this.logWarn("Both specialValues and allowEmptyValue properties set. allowEmptyValue will be ignored.");this.allowEmptyValue=false}
if(this.hiliteOnFocus!=null){this.$15o("hiliteOnFocus","showFocused");this.showFocused=this.hiliteOnFocus}
if(this.pickButtonWidth!=null){this.$15o("pickButtonWidth","pickerIconWidth");this.pickerIconWidth=this.pickButtonWidth}
if(this.pickButtonHeight!=null){this.$15o("pickButtonHeight","pickerIconHeight");this.pickerIconHeight=this.pickButtonHeight}
if(this.pickButtonSrc!=null){this.$15o("pickButtonSrc","pickerIconSrc");this.pickerIconSrc=this.pickButtonSrc}
if(this.multiple)this.$161a=isc.Set.create();return this.Super("init",arguments)},isc.A.$712=function isc_SelectItem__getShowHintInField(){return!!(this.showHint&&this.getHint()&&this.showHintInField)},isc.A.$157g=function isc_SelectItem__shouldVerticallyCenterTextBox(){return true},isc.A.drawn=function isc_SelectItem_drawn(_1,_2,_3,_4){this.invokeSuper(isc.SelectItem,"drawn",_1,_2,_3,_4);if(this.autoFetchData&&this.$19m()){this.fetchData(null,null,true)}},isc.A.$16m=function isc_SelectItem__getIconVMargin(){return 0},isc.A.$121=function isc_SelectItem__iconFocus(_1,_2){var _3=this.getIcon(_1);if(_3==this.getPickerIcon()){_2.blur();this.focusInItem();return}
return this.Super("$121",arguments)},isc.A.setElementReadOnly=function isc_SelectItem_setElementReadOnly(_1){},isc.A.$1603=function isc_SelectItem__getPendingBaseStyle(_1,_2){if(this.multiple&&(_2===this.$13q||_2===this.$1600))
{return _1}
return this.Super("$1603",arguments)},isc.A.handleClick=function isc_SelectItem_handleClick(){if(!(this.isDisabled())&&!(this.isReadOnly())){this.focusInItem();this.showPicker()}
return this.Super("handleClick",arguments)},isc.A.handleKeyPress=function isc_SelectItem_handleKeyPress(_1,_2){var _3=this.Super("handleKeyPress",arguments);if(_3==false)return false;if((this.isDisabled())||(this.isReadOnly()))return _3;var _4=_1.keyName;if(_4=="Enter"&&this.isSelectOther){if(this.$19u!=null)this.updateValue()}else if(_4=="Arrow_Down"){if(this.openOnDownArrow){this.showPicker()}else{if(isc.EH.altKeyDown())this.showPicker();else this.moveToNextValue(1)}
_3=false}else if(_4=="Arrow_Up"){if(isc.EH.altKeyDown())this.showPicker();else this.moveToNextValue(-1);_3=false}else if(_4==this.$20u){this.moveToNextPage(-1);_3=false}else if(_4==this.$20v){this.moveToNextPage(1);_3=false}else if(_4=="Home"){this.moveToFirstValue();_3=false}else if(_4=="End"){this.moveToLastValue();_3=false}else if(_4=="Space"&&this.openOnSpace){this.showPicker()}else{var _5=_1.characterValue;if(_5!=null){this.$177l(_5)}}
return _3},isc.A.$12x=function isc_SelectItem__nativeElementBlur(_1,_2){var _3=this.Super("$12x",arguments);if(this.changeOnBlur||this.$10v()||this.$19u){if(isc.Browser.isMoz&&this.$19u==this.otherValue)
this.form.$11w=true;this.updateValue()}
return _3},isc.A.showPicker=function isc_SelectItem_showPicker(_1,_2){this.showPickList(_1,_2)},isc.A.showPickList=function isc_SelectItem_showPickList(_1,_2){var _3=isc.PickList.getPrototype().showPickList;_3.apply(this,arguments);if(this.pickList){this.pickList.$188c=true;this.pickList.deselectAllRecords();this.pickList.$188c=false;if(this.getValue()!=null)this.selectItemFromValue(this.getValue())}},isc.A.handleEditorExit=function isc_SelectItem_handleEditorExit(){if(this.$19g)return;return this.Super("handleEditorExit",arguments)},isc.A.$19j=function isc_SelectItem__pickListShown(){this.handleEditorEnter();var _1=isc.PickList.getPrototype().$19j;_1.apply(this,arguments)},isc.A.$19h=function isc_SelectItem__pickListHidden(){if(this.fireChangeOnSelect==false)this.updateValue();var _1=isc.PickList.getPrototype().$19h;_1.apply(this,arguments)},isc.A.createPickerNavigationBar=function isc_SelectItem_createPickerNavigationBar(){if(this.pickerExitButton==null){this.pickerExitButton=this.createAutoChild("pickerExitButton",{title:this.pickerExitButtonTitle})}
if(this.pickerNavigationBar==null){this.pickerNavigationBar=this.createAutoChild("pickerNavigationBar",{controls:[this.pickerExitButton]})}else{this.pickerNavigationBar.setControls([this.pickerExitButton])}},isc.A.pickerExitButtonClick=function isc_SelectItem_pickerExitButtonClick(){this.pickList.hide()},isc.A.getAllLocalOptions=function isc_SelectItem_getAllLocalOptions(_1){var _2;if(this.$19m()){if(!this.pickList||this.pickList.destroyed)return;var _3=this.pickList.getOriginalData();if(!_3||!_3.lengthIsKnown()||!_3.allMatchingRowsCached())return;var _4=this.getPickListFilterCriteria();if(this.form){_4=isc.DataSource.resolveDynamicCriteria(_4,this.form.getRuleContext())}
if(_3.compareCriteria(_4,_3.criteria)!=0){if(!_3.allRowsCached()||!_3.useClientFiltering)return;this.filterPickList(false,false)}
_2=_3.getAllRows()}else{_2=this.getClientPickListData()}
var _5=[];if(_1){var _6=this.getRecordEnabledProperty(),_7=this.getCanSelectRecordProperty();for(var i=0;i<_2.length;i++){if(_2[i][_6]==false)continue;if(_2[i][_7]==false)continue;_5[_5.length]=_2[i]}}else{_5=_2}
return _5},isc.A.getRecordEnabledProperty=function isc_SelectItem_getRecordEnabledProperty(){if(this.pickList!=null)return this.pickList.recordEnabledProperty;if(this.pickListProperties&&this.pickListProperties.recordEnabledProperty){return this.pickListProperties.recordEnabledProperty}
if(this.pickListDefaults&&this.pickListDefaults.recordEnabledProperty){return this.pickListDefaults.recordEnabledProperty}
return isc.PickListMenu.getPrototype().recordEnabledProperty},isc.A.getCanSelectRecordProperty=function isc_SelectItem_getCanSelectRecordProperty(){if(this.pickList!=null)return this.pickList.recordCanSelectProperty;if(this.pickListProperties&&this.pickListProperties.recordCanSelectProperty){return this.pickListProperties.recordCanSelectProperty}
if(this.pickListDefaults&&this.pickListDefaults.recordCanSelectProperty){return this.pickListDefaults.recordCanSelectProperty}
return isc.PickListMenu.getPrototype().recordCanSelectProperty},isc.A.$177l=function isc_SelectItem__setClearMoveToTimer(_1,_2){var _3=String.fromCharCode(_1);if(_3==null)return;if(this.$177o){isc.Timer.clear(this.$177o);delete this.$177o}
if(!this.$177m||!this.allowMultiCharSearch)this.$177m="";this.$177m+=_3;if(!_2){if(!this.moveToBuffer(this.$177m)){if(this.$177m.endsWith(_3+_3)){this.$177m=_3;this.moveToBuffer(this.$177m)}}}
if(this.allowMultiCharSearch){this.$177o=isc.Timer.setTimeout(this.getID()+".$177p()",this.$177n)}},isc.A.$177p=function isc_SelectItem__$delayedClearMoveTo(){isc.Timer.clear(this.$177o);delete this.$177o;delete this.$177m},isc.A.moveToBuffer=function isc_SelectItem_moveToBuffer(_1){var _2=this.getAllLocalOptions(true);if(!_2||_2.length<1){if(this.pickList&&this.pickList.data&&this.pickList.data.localData){_2=this.pickList.data.localData}}
if(_2==null||_2.length<1)return false;var _3=_1;if(_3==null)return false;_3=_3.toLowerCase();var _4=(this.isSelectOther&&this.$19u!=null)?this.$19u:(this.$10v()?this.$19w:this.getValue()),_5=this.getValueFieldName(),_6=isc.isAn.Array(_4)?_4[0]:_4,_7=_2.findIndex(_5,_6),i=(_7==_2.length-1?0:_7+1),_9=_7>0;while(i!=_7||(this.multiple&&this.openPickListOnKeyPress&&i<_2.length))
{if(_7<0)_7=0;if(!_2[i]){if(_9){_9=false;i=0;continue}
return false}
var _10=_2[i][this.getValueFieldName()],_11=this.mapValueToDisplay(_10);if(isc.isA.String(_11)){var _12=_11.replace(/<(?:.|\n)*?>/gm,'').toLowerCase();if(_12.startsWith(_3)){var _13=_10;if(this.openPickListOnKeyPress){this.showPicker();this.pickList.scrollRecordIntoView(i);this.pickList.$88(i)}else{this.changeToValue(_13,(this.changeOnValueChange&&this.changeOnKeyboardNavigation))}
return true}}
i+=1;if(i>=_2.length)i=0}
return false},isc.A.moveToNextPage=function isc_SelectItem_moveToNextPage(_1){var _2;if(this.isSelectOther&&this.$19u!=null)_2=this.$19u;else _2=(this.$10v()?this.$19w:this.getValue());var _3=this.getValueFieldName();var _4=-1,_5;var _6=this.getAllLocalOptions(true);if(!_6||_6.length<1){if(this.$19m()&&this.pickList&&!this.pickList.destroyed){var _7=this.pickList.getOriginalData();var _8=this.getPickListFilterCriteria();if(this.form){_8=isc.DataSource.resolveDynamicCriteria(_8,this.form.getRuleContext())}
if(_7&&_7.compareCriteria(_8,_7.criteria)!=0){this.filterPickList(false,false)}
_6=_7}}
if(_6==null||_6.length<1)return;var _4=_6.findIndex(_3,_2),_5=_6.getLength(),_9=this.dataPageSize;if(_9==null)_9=this.pickList?this.pickList.dataPageSize||10:10;if(_1<0)_9*=-1;_4+=_9;if(_4<0)_4=0;if(_4>=_5)_4=_5-1;var _10=_6.get(_4);if(_10!=null&&!Array.isLoading(_10)){var _11=_10[_3]
this.changeToValue(_11,(this.changeOnValueChange&&this.changeOnKeyboardNavigation))}},isc.A.moveToNextValue=function isc_SelectItem_moveToNextValue(_1){var _2;if(this.isSelectOther&&this.$19u!=null)_2=this.$19u;else _2=(this.$10v()?this.$19w:this.getValue());var _3=this.getValueFieldName();var _4=-1,_5;var _6=this.getAllLocalOptions(true);if(!_6||_6.length<1){if(this.$19m()&&this.pickList&&!this.pickList.destroyed){var _7=this.pickList.getOriginalData();var _8=this.getPickListFilterCriteria();if(this.form){_8=isc.DataSource.resolveDynamicCriteria(_8,this.form.getRuleContext())}
if(_7&&_7.compareCriteria(_8,_7.criteria)!=0){this.filterPickList(false,false)}
_6=_7}}
if(_6==null||_6.length<1)return;var _4=_6.findIndex(_3,_2);_5=_6.getLength();_4+=_1;if(_5==null||_4>=_5||_4<0)return;var _9=_6.get(_4);if(_9!=null&&!Array.isLoading(_9)){var _10=_9[_3]
this.changeToValue(_10,(this.changeOnValueChange&&this.changeOnKeyboardNavigation))}},isc.A.moveToFirstValue=function isc_SelectItem_moveToFirstValue(){if(this.optionDataSource)return;var _1=this.getClientPickListData(),_2=this.getValueFieldName(),_3=_1[0][_2];this.changeToValue(_3,(this.changeOnValueChange&&this.changeOnKeyboardNavigation))},isc.A.moveToLastValue=function isc_SelectItem_moveToLastValue(){if(this.optionDataSource)return;var _1=this.getClientPickListData(),_2=this.getValueFieldName(),_3=_1[_1.length-1][_2]
this.changeToValue(_3,(this.changeOnValueChange&&this.changeOnKeyboardNavigation))},isc.A.$kk=function isc_SelectItem__canFocus(){return true},isc.A.$19x=function isc_SelectItem__getIconMouseDownFunction(){if(!this.$19y){this.$19y=isc.$aq("if(window."+this.getID()+")window."+this.getID()+".$19g=true;")}
return this.$19y},isc.A.$159=function isc_SelectItem__applyHandlersToElement(_1,_2,_3,_4){this.invokeSuper(isc.SelectItem,"$159",_1,_2,_3,_4);if(isc.Browser.isIE){var _5=this.$16v(this.getPickerIcon());if(_5){_5.onmousedown=this.$19x()}}},isc.A.$1607=function isc_SelectItem__pendingStatusChanged(_1){if(this.multiple&&!_1){var _2=this.$161a;_2.clear();var _3=this._value;if(isc.isAn.Array(_3)){var _4=_3.length;for(var i=0;i<_4;++i){_2.add(_3[i])}}else{_2.add(_3)}
this.setLocalValue(_3)}
this.Super("$1607",arguments)},isc.A.makePickList=function isc_SelectItem_makePickList(_1){if(this.progressiveLoading===true||this.progressiveLoading===false){if(this.pickListProperties==null)this.picklistProperties={};this.picklistProperties.progressiveLoading=this.progressiveLoading}
if(!this.filterLocally&&(this.allowEmptyValue||(this.specialValues&&!this.separateSpecialValues))&&this.$19m())
{if(this.pickListProperties==null)
this.pickListProperties={};if(this.pickListProperties.dataProperties==null)
this.pickListProperties.dataProperties={};this.pickListProperties.dataProperties.fetchMode="basic"}
var _2=isc.PickList.getPrototype().makePickList;var _3=_2.apply(this,arguments);if(this.multiple&&this.pickList&&this.pickList.showFilterEditor){this.logWarn("SelectItem defined with multiple set to true, and showFilterEditor enabled on the pick-list. This combination of settings is not supported as it can lead to ambiguity if a user selects an item, then re-filters such that the item is no longer visible and attempts to modify the selection.")}
return _3},isc.A.changeToValue=function isc_SelectItem_changeToValue(_1,_2){var _3=(this.$19u||this.$19w||this.getValue());if(_3==_1)return;if(this.isSelectOther&&(_1==this.separatorValue||_1==this.otherValue))
{this.$952(this.mapValueToDisplay(_1),_1);this.$19u=_1;return}else{delete this.$19u}
this.setLocalValue(_1);if(_2)this.updateValue()},isc.A.setLocalValue=function isc_SelectItem_setLocalValue(_1){this.$19w=_1;if(this.isVisible()&&this.containerWidget.isDrawn()){if(_1==null)_1=null;this.$952(this.mapValueToDisplay(_1),_1)}
this.$18i()},isc.A.setElementValue=function isc_SelectItem_setElementValue(_1,_2,_3,_4,_5){var _6=(_1==null||isc.isAn.emptyString(_1)||_1==this.emptyDisplayValue);if(isc.Canvas.ariaEnabled()&&this.outerAriaRole==="listbox"){this.setAriaRole(_6?"presentation":"option")}
if(!this.$127p&&!this.$127q&&this.$712())
{if(_6){var _7=this.$15h();if(_7!=null)
_7.className=this.$66v();var _8=this.getHint();_1=String.htmlStringToString(_8);this.$1563=true}else{if(this.$1563){var _7=this.$15h();if(_7!=null)_7.className=this.getTextBoxStyle()}
this.$1563=false}}
_1=this.$170f(_1,_2);this.$19z=_1;return this.invokeSuper(isc.SelectItem,"setElementValue",_1,_2,_3,_4,_5)},isc.A.$66t=function isc_SelectItem__showInFieldHint(){if(this.$127p){return}
this.$127p=true;this.Super("$66t",arguments);this.$127p=false},isc.A.$66s=function isc_SelectItem__hideInFieldHint(_1){if(this.$127q){return}
this.$127q=true;this.Super("$66s",arguments);this.$127q=false},isc.A.updateValue=function isc_SelectItem_updateValue(){if(this.isSelectOther&&this.$19u!=null){var _1=this.getSelectOtherValue(this.$19u);delete this.$19u;this.setLocalValue(_1)}
if(!this.$10v())return;var _2=this.$19w;this.$10y(_2)},isc.A.mapDisplayToValue=function isc_SelectItem_mapDisplayToValue(_1){return _1},isc.A.getSelectOtherValue=function isc_SelectItem_getSelectOtherValue(_1){if(_1==this.separatorValue)return true;if(_1==this.otherValue){var _2=this.$19w||this.getValue(),_3=(_2==null?"":this.mapValueToDisplay(_2)),_4=this.selectOtherPrompt.evalDynamicString(null,{item:this,value:_2}),_5=isc.addProperties({width:this.dialogWidth},this.dialogDefaults,this.dialogProperties);isc.askForValue(_4,this.getID()+".getSelectOtherValueCallback(value)",_5);return true}},isc.A.getSelectOtherValueCallback=function isc_SelectItem_getSelectOtherValueCallback(_1){if(_1!=null){_1=this.mapDisplayToValue(_1);this.changeToValue(_1,this.changeOnValueChange)}},isc.A.setValue=function isc_SelectItem_setValue(_1,_2,_3,_4){_1=this.$190(_1);var _5,_6=this.$19w;if(_6===_5)_6=this._value;this.invokeSuper(isc.SelectItem,"setValue",_1,_2,_3,_4);_1=this.getValue();if(_1!=_6)this.setLocalValue(_1);if(this.pickList&&this.pickList.isDrawn()&&this.pickListVisible()){this.setUpPickList(true)}
if(!this.hasFocus&&this.$712()){if(_1==null||isc.isAn.emptyString(_1)){this.$66t()}else{this.$66s(true)}}
return _1},isc.A.saveValue=function isc_SelectItem_saveValue(_1,_2,_3,_4,_5){var _6=this._value;if(this.$191(_6,_1))delete this.$192;return this.invokeSuper(isc.SelectItem,"saveValue",_1,_2,_3,_4,_5)},isc.A.$191=function isc_SelectItem__dropCacheOnValueChange(_1,_2){return(this.addUnknownValues&&this.$192&&((_1!=null&&!this.$193(_1))||(_2!=null&&!this.$193(_2))))},isc.A.$10x=function isc_SelectItem__markValueAsNotDirty(_1,_2,_3,_4){this.invokeSuper(isc.SelectItem,"$10x",_1,_2,_3,_4);delete this.$19w},isc.A.getDefaultValue=function isc_SelectItem_getDefaultValue(){var _1=this.Super("getDefaultValue",arguments);if(_1==null&&this.defaultToFirstOption)_1=this.getFirstOptionValue();return this.$190(_1)},isc.A.$190=function isc_SelectItem__getValidValue(_1){if(!this.$194(_1)){var _2=this.$195;this.$195=true;var _3;if(_2)_3=_1;else _3=this.$19w||this.getValue();if(_1==_3||!this.$194(_3)){_3=null}
_1=_3}
return _1},isc.A.$194=function isc_SelectItem__valueIsValid(_1){if(this.addUnknownValues||this.getOptionDataSource())return true;if(_1==null)return true;if(isc.isAn.Array(_1)){for(var i=0;i<_1.length;i++){if(!this.$193(_1[i]))return false}
return true}else{return this.$193(_1)}},isc.A.$193=function isc_SelectItem__valueInValueMap(_1){var _2=this.getAllValueMappings(),_3;if(isc.isAn.Array(_2)){return _2.contains(_1)}else if(isc.isAn.Object(_2)){return(_2[_1]!==_3)}
return false},isc.A.mapValueToDisplay=function isc_SelectItem_mapValueToDisplay(_1,_2,_3,_4){if(this.isSelectOther){if(_1==this.otherValue)return this.otherTitle;if(_1==this.separatorValue)return this.separatorTitle}
return this.invokeSuper(isc.SelectItem,"mapValueToDisplay",_1,_2,_3,_4)},isc.A.$161q=function isc_SelectItem__finishMapMultipleValueToDisplay(_1,_2){if(this.multiple&&this.$161r()){var _3=[];var _4=this.$160w();var _5;if(_4==null)_5=0;else if(!isc.isAn.Array(_4)){_4=[_4];_5=1}else{_5=_4.length}
var _6=(_2==null?0:_2.length);var _7=this.$161a,i=0,j=0,_10=false;while(i<_5&&j<_6){var _11=_4[i],_12=_2[j];if(_7.has(_12)){if(_2.contains(_11)){if(_10){_3.add(this.$161t);_10=false}
_3.add(_1[j]);++i;++j}else{if(!_10){_3.add(this.$161s);_10=true}
_3.add("<span style='"+String.asAttValue(this.valueDeselectedCSSText)+"'>"+this.mapValueToDisplay(_11)+"</span>");++i}}else{if(_10){_3.add(this.$161t);_10=false}
_3.add(_1[j]);++j}}
if(i<_5){if(!_10){_3.add(this.$161s);_10=true}
do{_3.add("<span style='"+String.asAttValue(this.valueDeselectedCSSText)+"'>"+this.mapValueToDisplay(_4[i])+"</span>")}while(++i<_5);_3.add(this.$161t);_10=false}else if(j<_6){if(_10){_3.add(this.$161t);_10=false}
do{_3.add(_1[j])}while(++j<_6)}
for(var _13=_3.length,_14=_13;_14>1;--_14){var _15=_3[_14-1];if(_15===this.$161s){if(_14>=2)_3.addAt(this.multipleValueSeparator,_14-1)}else if(_15===this.$161t){if(_14<_13){_3.addAt(this.multipleValueSeparator,_14-1)}}else{if(_3[_14-2]!==this.$161s&&_3[_14-2]!==this.$161t)
{_3.addAt(this.multipleValueSeparator,_14-1)}}}
return _3.join(isc.emptyString)}else return _1.join(this.multipleValueSeparator)},isc.A.$1604=function isc_SelectItem__finishMapValueToDisplay(_1,_2){if(this.multiple){if(_2!=null&&!this.$1602&&this.$161p()&&!this.$161a.has(_2))
{_1=("<span style='"+String.asAttValue(this.editPendingCSSText)+"'>"+_1+"</span>")}else if(_2==null&&this.$161r()){var _3=this.$161q(null,null);if(_3)_1=_3}}
return _1},isc.A.getSelectedRecord=function isc_SelectItem_getSelectedRecord(){if(this.pickList==null||this.pickList.destroyed)this.makePickList(false);var _1,_2=this.$19w;if(_2===_1)_2=this.getValue();if(this.selectItemFromValue(_2,true)){return this.pickList.getSelectedRecord()}
return this.Super("getSelectedRecord",arguments)},isc.A.getSelectedRecords=function isc_SelectItem_getSelectedRecords(){var _1=this.$19w;this.selectItemFromValue(_1,true);var _2=this.pickList.getSelection();return(_2.length>0?_2:null)},isc.A.$17b=function isc_SelectItem__mapKey(_1,_2,_3,_4,_5,_6){var _7=this.invokeSuper(isc.SelectItem,"$17b",_1,true,_3,_4,_5,_6);if(_7==null&&this.getDisplayFieldName()!=null){var _8=this.$19o(_1,false),_9;if(_8!==_9){_7=_8}else if(this.specialValues){var _10=this.specialValues;if(isc.isA.String(_10))_10=this.getGlobalReference(_10);if(!isc.isAn.Array(_10)){if(isc.PickList.emptyStoredValue&&_1===null)_1=isc.PickList.emptyStoredValue;_7=isc.getValueForKey(_1,_10,_1)}}}
if(_7==null&&!_2)_7=_1;return _7},isc.A.$43f=function isc_SelectItem__checkForDisplayFieldValue(_1,_2){var _3=false;if(this.multiple){for(var i=0,_5=_1.getLength();!_3&&i<_5;++i){_3=(this.$17b(_1[i],true)!=null)}}else{_3=(this.$17b(_1,true)!=null)}
if(_3)return;if(this.$43j){this.$43k=true;return}
this.invokeSuper(isc.SelectItem,"$43f",_1)},isc.A.$127i=function isc_SelectItem__fetchMissingValueInProgress(_1,_2){var _3;if(_2!==_3&&_1&&this.$43d&&isc.propertyDefined(this.$43d,_2))
{return false}
if(this.$43k&&_1){return true}
return this.Super("$127i",arguments)},isc.A.getClientPickListData=function isc_SelectItem_getClientPickListData(){if(this.$192)return this.$192;var _1=isc.PickList.optionsFromValueMap(this),_2=this.getValueFieldName();var _3=this.$128m(true);if(_3){if(this.separateSpecialValues){this.setSeparateSpecialValues(_3)}else{if(this.multiple){for(var i=0;i<_3.length;i++){_3[i]=isc.addProperties(_3[i],{canSelect:false})}}
_1.addListAt(_3,0)}}
var _5=this.getValue();if(_5!=null&&!isc.isAn.Array(_5)){if(_1.find(_2,_5)==null){var _6={};_6[_2]=_5;_1.addAt(_6,0)}}
if(this.isSelectOther){var _7={},_8={};_7[_2]=this.separatorValue;_8[_2]=this.otherValue;_1.addListAt([_7,_8],_1.length)}
this.$192=_1;return _1},isc.A.updateDisplayValueMap=function isc_SelectItem_updateDisplayValueMap(_1){this.Super("updateDisplayValueMap",arguments);if(this.$128n&&this.$847){var _2=this.getDisplayFieldName();if(_2){var _3=this.$847,_4=this.getValueFieldName(),_5=this.$128n,_6=false;for(var i=0;i<_5.length;i++){var _8=_5[i],_9=_8[_4],_10=_3.find(_4,_9);if(this.multiple&&!this.separateSpecialValues){_8=isc.addProperties(_8,{canSelect:false})}
if(_10!=null){_8[_2]=_10[_2];_6=true}}
if(_6&&this.separateSpecialValues){if(this.separateValuesList)this.separateValuesList.markForRedraw()}}}},isc.A.formatPickListValue=function isc_SelectItem_formatPickListValue(_1,_2,_3){if(this.isSelectOther&&(_2==this.getValueFieldName())){if(_1==this.otherValue)return this.otherTitle;if(_1==this.separatorValue)return this.separatorTitle}
if(this.pickList.getField(_2).$720){return this.$17c(_1)}
return _1},isc.A.pickValue=function isc_SelectItem_pickValue(_1){if(this.isSelectOther){if(this.getSelectOtherValue(_1))return}
this.changeToValue(_1,(this.changeOnValueChange&&this.fireChangeOnSelect!=false))},isc.A.getPickListPosition=function isc_SelectItem_getPickListPosition(){var _1=this.getPageTop(),_2=_1+this.getHeight(),_3=this.getPageLeft(),_4=isc.Page.getScrollTop(),_5=isc.Page.getHeight()+_4;var _6;if(!this.pickList.isDrawn()){var _7=this.pickList.data;if(_7==null||_7.getLength()==0){_6=this.emptyPickListHeight}else{_6=Math.min((_7.getLength()*this.pickList.cellHeight)+(this.pickList.showHeader?this.pickList.headerHeight:0)+(this.pickList.showFilterEditor?this.pickList.filterEditorHeight:0),this.pickListHeight)}}else{_6=this.pickList.getVisibleHeight()}
if(_2+_6>_5){_2=Math.max(_4,(_1-_6))}
if(this.containerWidget.isRTL()){_3+=this.getVisibleWidth();_3-=this.pickList.getVisibleWidth()}
return[_3,_2]},isc.A.updateValueMap=function isc_SelectItem_updateValueMap(_1){this.Super("updateValueMap",arguments);if(this.$958)return;if(this.$192)delete this.$192;var _2=false;if(this.hasPickList()&&(!this.getOptionDataSource()||(this.pickList.getDataSource()!=this.getOptionDataSource())))
{if(this.pickList.isVisible()&&this.pickList.isDrawn()){this.hidePicker();_2=true}
delete this.pickList.formItem}
var _3=this.getValue(),_4=this.$190(_3);if(_3!=_4){this.setValue(_4)}else{this.$952(this.mapValueToDisplay(_4),_4)}
if(_2)this.showPicker()},isc.A.hasPickList=function isc_SelectItem_hasPickList(){return(this.pickList&&!this.pickList.destroyed&&this.pickList.formItem==this)},isc.A.pickListVisible=function isc_SelectItem_pickListVisible(){return(this.hasPickList()&&this.pickList.isDrawn()&&this.pickList.isVisible())},isc.A.cleared=function isc_SelectItem_cleared(){var _1=this.Super("cleared",arguments);if(this.pickListVisible())this.pickList.hide();return _1},isc.A.filterComplete=function isc_SelectItem_filterComplete(){var _1=this.$128m(true);if(_1){if(this.specialValues&&this.separateSpecialValues){this.setSeparateSpecialValues(_1)}else{var _2=this.pickList.getOriginalData();if(isc.isA.ResultSet(_2)){var _3=_2.addSpecialValueRecords(this.getValueFieldName(),this.getDisplayFieldName(),_1);if(_3){if(this.pickListVisible())this.pickList.markForRedraw()}}}}
var _4=isc.PickList.getPrototype().filterComplete;_4.apply(this,arguments)});isc.B._maxIndex=isc.C+68;isc.ClassFactory.mixInInterface("SelectItem","PickList");isc.SelectItem.registerStringMethods({dataArrived:"startRow,endRow,data",getPickListFilterCriteria:""})}else{isc.Log.logInfo("Source for standard SelectItem class included in this module, but required related class (ListGrid) is not loaded. This can occur if the Forms module is loaded without the Grids module. SelectItem class will be defined as a subclass of NativeSelectItem.","moduleDependencies");isc.ClassFactory.defineClass("SelectItem","NativeSelectItem")}
isc.defineClass("CycleItem","FormItem");isc.A=isc.CycleItem.getPrototype();isc.A.canSelectText=false;isc.A.canFocus=true;isc.A.iconVAlign="middle";isc.A=isc.CycleItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.handleKeyPress=function isc_CycleItem_handleKeyPress(){var _1=isc.EH.getKey();var _2=this.isReadOnly();if(!_2&&_1=="Space"){this.advanceValue();return false}
return this.Super("handleKeyPress",arguments)},isc.A.handleClick=function isc_CycleItem_handleClick(){if(this.isDisabled()||this.isReadOnly())return;if(!this.hasFocus)this.focusInItem();this.advanceValue()},isc.A.handleDoubleClick=function isc_CycleItem_handleDoubleClick(){if(this.isDisabled()||this.isReadOnly())return;this.advanceValue()},isc.A.advanceValue=function isc_CycleItem_advanceValue(){var _1=this.getValueMap(),_2=isc.isAn.Array(_1),_3;if(_1==null||(_3=(_2?_1:isc.getKeys(_1))).length<2)
{this.logInfo("CycleItem is non interactive as there are no options for this item.");return}
var _4=this.getValue(),_5=_3.indexOf(_4);if(_5<0){var _6;if(_4===_6)_4=false;if(_3.length==2&&!!_3[0]!=!!_3[1])
{if(_2){_5=(!!_4==!!_1[0]?0:1)}else{_5=(!!_1[_4]==!!_1[_3[0]]?0:1)}}else{if(_2){for(_5=0;_5<_3.length;++_5){if(_4==_1[_5]){break}}}else{for(_5=0;_5<_3.length;++_5){if(_1[_4]==_1[_3[_5]]){break}}}
_5=Math.min(_5,_3.length-1)}
_4=_3[_5]}
var _7=(_5+1)%_3.length;var _8=_3[_7];if(!this.compareValues(_8,this._value)){var _9=this.mapValueToDisplay(_8);this.setElementValue(_9,_8);if(isc.Canvas.ariaEnabled())this.setAriaState("checked",!!(_2?_8:_1[_8]));this.$10y(_8)}},isc.A.setElementReadOnly=function isc_CycleItem_setElementReadOnly(_1){this.$176(!_1&&!this.isDisabled())});isc.B._maxIndex=isc.C+5;isc.defineClass("CheckboxItem","CycleItem");isc.addGlobal("BooleanItem",isc.CheckboxItem);isc.A=isc.CheckboxItem;isc.A.trueFalseValueMap=[true,false];isc.A.trueFalseNullValueMap=[true,false,null];isc.A=isc.CheckboxItem.getPrototype();isc.A.defaultType="boolean";isc.A.textBoxStyle="labelAnchor";isc.A.width=150;isc.A.showLabel=true;isc.A.height=20;isc.A.requiredTitlePrefix="<b>";isc.A.requiredTitleSuffix="</b>";isc.A.valueIconLeftPadding=4;isc.A.valueIconRightPadding=3;isc.A.showValueIconOver=true;isc.A.showValueIconFocused=true;isc.A.showValueIconDown=true;isc.A.showValueIconDisabled=true;isc.A.checkedImage="[SKINIMG]/DynamicForm/checked.gif";isc.A.uncheckedImage="[SKINIMG]/DynamicForm/unchecked.gif";isc.A.partialSelectedImage="[SKINIMG]/DynamicForm/partialcheck.gif";isc.A.unsetImage="[SKINIMG]/DynamicForm/unsetcheck.gif";isc.A.checkedDescription="checked";isc.A.uncheckedDescription="unchecked";isc.A.partialSelectedDescription="partially selected";isc.A.unsetDescription="unset";isc.A.valueIconWidth=13;isc.A.valueIconHeight=13;isc.A=isc.CheckboxItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.allowEmptyValue=false;isc.A.$18q="true";isc.A.$18r="false";isc.A.emptyValueKey="**NULL**";isc.A.applyHeightToTextBox=false;isc.A.sizeToCheckboxImage=true;isc.B.push(isc.A.getValueMap=function isc_CheckboxItem_getValueMap(){if(this.$20b)return this.$20b;var _1=this.Super("getValueMap",arguments);if(_1!=null){var _2=false,_3=isc.isAn.Object(_1);if(isc.isAn.Array(_1)){_3=false;if(_1.length!=2){_1=null}else{var _4=_1.indexOf(this.$18r);if(_4!=-1)_1[_4]=false;var _5=_1.indexOf(this.$18q);if(_5!=-1)_1[_5]=true;if(!((_1[0]&&!_1[1])||(!_1[0]&&_1[1]))){this.logInfo("Checkbox item created with valueMap:"+_1+"which has no explicit true/false display values. Mapping the first value to true and the second to false.");var _6={};_6[_1[0]]=true;_6[_1[1]]=false;this.valueMap=_1=_6;_3=true}else{_2=true}}}
if(_3){var _7=[],_8=[],_9;for(var _10 in _1){if(_7.length==2){_9=true;break}
var _11=_1[_10];if(_10==this.$18r)_10=false;else if(_10==this.$18q)_10=true;if(_11==this.$18r){_11=_1[_10]=false}else if(_11==this.$18q){_11=_1[_10]=true}
_8[_8.length]=_10;_7[_7.length]=_11}
if(_7.length!=2)_9=true;if(!_9){if((_7[0]&&!_7[1])||(!_7[0]&&_7[1])){}else if((_8[0]&&!_8[1])||(!_8[0]&&_8[1])){_1=_8}else _9=true}
if(_9)_1=null}else if(!_2){_1=null}}
if(_1&&this.allowEmptyValue){if(_2)_1.add(null);else _1[this.emptyValueKey]=null}
return(this.$20b=_1||(this.allowEmptyValue?isc.CheckboxItem.trueFalseNullValueMap:isc.CheckboxItem.trueFalseValueMap))},isc.A.$17d=function isc_CheckboxItem__unmapKey(){var _1=this.Super("$17d",arguments);if(_1==this.emptyValueKey)_1=null;return _1},isc.A.setValueMap=function isc_CheckboxItem_setValueMap(){this.$20b=null;return this.Super("setValueMap",arguments)},isc.A.init=function isc_CheckboxItem_init(_1,_2,_3,_4){this.invokeSuper(isc.CheckboxItem,"init",_1,_2,_3,_4);if(this.showValueIconOnly==null)this.showValueIconOnly=!this.showLabel;if(this.textAlign==null&&this.align!=null){this.textAlign=this.align}
var _5=this.booleanBaseStyle;if(_5!=null){this.$161b=_5+"True";this.$161c=_5+"False";this.$161d=_5+"Partial";this.$161e=_5+"Unset"}
var _6=this.printBooleanBaseStyle;if(_6!=null){this.$163j=_6+"True";this.$163k=_6+"False";this.$163l=_6+"Partial";this.$163m=_6+"Unset"}else if(_5!=null){this.$163j=this.$161b;this.$163k=this.$161c;this.$163l=this.$161d;this.$163m=this.$161e}},isc.A.setShowLabel=function isc_CheckboxItem_setShowLabel(_1){this.showLabel=_1;this.showValueIconOnly=!_1;if(this.isDrawn())this.redraw()},isc.A.mapValueToDisplay=function isc_CheckboxItem_mapValueToDisplay(_1,_2,_3,_4){if(this.labelAsTitle)return isc.emptyString;var _5=this.invokeSuper(isc.CheckboxItem,"getTitleHTML",_1,_2,_3,_4);var _6=this.form;if((this.required||this.$11m)&&_6&&_6.hiliteRequiredFields){_5=this.requiredTitlePrefix+_5+this.requiredTitleSuffix}
return _5},isc.A.$161f=function isc_CheckboxItem__mapValue(_1,_2,_3,_4,_5){var _6=this.getValueMap();if(!isc.isAn.Array(_6)&&isc.isAn.Object(_6))_1=_6[_1];if(_1)return _2;else if(_1===false)return _3;else{if(this.showUnsetImage!=null){return this.showUnsetImage?_5:_3}
return this.allowEmptyValue?_5:_3}},isc.A.$1605=function isc_CheckboxItem__getDisplayValueForOldValueHover(_1){return this.$161f(_1,this.checkedDescription,this.uncheckedDescription,this.partialSelectedDescription,this.unsetDescription)},isc.A.getValueIcon=function isc_CheckboxItem_getValueIcon(_1){return this.$161f(_1,this.checkedImage,this.uncheckedImage,this.partialSelectedImage,this.unsetImage)},isc.A.getValueIconStyle=function isc_CheckboxItem_getValueIconStyle(_1){if(this.booleanBaseStyle==null)return null;return this.$161f(_1,this.$161b,this.$161c,this.$161d,this.$161e)},isc.A.getPrintValueIcon=function isc_CheckboxItem_getPrintValueIcon(_1){return this.$161f(_1,this.printCheckedImage||this.checkedImage,this.printUncheckedImage||this.uncheckedImage,this.printPartialSelectedImage||this.partialSelectedImage,this.printUnsetImage||this.unsetImage)},isc.A.getPrintValueIconStyle=function isc_CheckboxItem_getPrintValueIconStyle(_1){if(this.printBooleanBaseStyle==null&&this.booleanBaseStyle==null){return null}
return this.$161f(_1,this.$163j,this.$163k,this.$163l,this.$163m)},isc.A.getTitleHTML=function isc_CheckboxItem_getTitleHTML(_1,_2,_3){if(this.labelAsTitle)return this.invokeSuper(isc.CheckboxItem,"getTitleHTML",_1,_2,_3);return isc.emptyString},isc.A.$15s=function isc_CheckboxItem__writeOuterTable(){return true},isc.A.fitWidthToValueIcon=function isc_CheckboxItem_fitWidthToValueIcon(){return this.sizeToCheckboxImage},isc.A.$85m=function isc_CheckboxItem__shouldAllowExpressions(){return false},isc.A.getValueAsBoolean=function isc_CheckboxItem_getValueAsBoolean(){var _1,_2=this.getValue();if(_2===_1)return this.allowEmptyValue?null:false;else return isc.isA.Boolean(_2)?_2:null});isc.B._maxIndex=isc.C+17;isc.ClassFactory.defineClass("NativeCheckboxItem","FormItem");isc.A=isc.NativeCheckboxItem.getPrototype();isc.A.textBoxStyle="labelAnchor";isc.A.implementsPromptNatively=isc.screenReader;isc.A.$183="CHECKBOX";isc.A.$125=true;isc.A.showLabel=true;isc.A.$16b={onclick:isc.FormItem.$12y};isc.A=isc.NativeCheckboxItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$20c=["<TABLE role='presentation' CELLSPACING=0 CELLPADDING=0 BORDER=0 ID='",,"' class='",,"'><TR>","<TD WIDTH=20><INPUT TYPE=",," NAME=",," ID=",,,,,,," handleNativeEvents=false ",,,," TABINDEX=",,(isc.Browser.isMoz?" STYLE='-moz-user-focus:":null),,"></TD>",,"</TR></TABLE>"];isc.A.$20d=["<TD CLASS='",,"' ALIGN=LEFT",,,,," style='"+isc.Canvas.$42a,,"'>",,"</TD>"];isc.A.$20e=["<A HREF='javascript:void ",,".boxTitleClick()' ONMOUSEOVER='window.status = \"",,"\"; return true' ONMOUSEOUT='window.status = \"\"; return true' CLASS='",,"' title=\"",,"\">",,"</A>"];isc.B.push(isc.A.getInnerWidth=function isc_NativeCheckboxItem_getInnerWidth(_1,_2,_3,_4){if(!this.showLabel||this.showValueIconOnly){return 20}
return this.invokeSuper(isc.NativeCheckboxItem,"getInnerWidth",_1,_2,_3,_4)},isc.A.getElementHTML=function isc_NativeCheckboxItem_getElementHTML(_1){var _2=this.form.getID(),_3=this.getItemID(),_4=this.$20c,_5=this.getAnchorTitle();_4[1]=this.$qs("checkboxTable");_4[3]=this.getTextBoxStyle();_4[6]=this.$183;_4[8]=this.getElementName();_4[10]=this.getDataElementId();_4[11]=this.$155();if(this.value!=null){_4[12]=" VALUE='";_4[13]=this.value;_4[14]="'";if(this.containerWidget&&this.containerWidget.isPrinting){if(_1==this.value)_4[14]+=" CHECKED='true'"}}else{_4[12]=null;_4[13]=null;_4[14]=null}
if(this.isDisabled()||this.isReadOnly())_4[15]=" DISABLED";else _4[15]=null;if(this.implementsPromptNatively){if(this.prompt!=null){_4[17]=" TITLE='";_4[18]=this.prompt;_4[19]="'"}else{_4[17]=_4[18]=_4[19]=null}}
var _6=this.$154();_4[21]=_6;if(isc.Browser.isMoz){_4[23]=(_6>0?"normal;'":"ignore;'")}
if(this.showLabel&&!this.showValueIconOnly){var _7=this.getElementWidth(),_8=this.getInnerHeight();if(isc.isA.Number(_7))_7=Math.max(20,_7-20);if(isc.Browser.isSafari&&!this.renderAsDisabled()&&(isc.Browser.isChrome?isc.Browser.safariVersion<535:isc.Browser.safariVersion<534.5))
{var _9=this.$20e;_9[1]=_3;_9[3]=this.prompt;_9[5]=this.getTextBoxStyle();_9[7]=this.prompt;_9[9]=_5;_5=_9.join(isc.emptyString)}
var _10=this.$20d;_10[1]=this.getTextBoxStyle();if(_7!=null){_10[3]=" WIDTH=";_10[4]=_7}else{_10[3]=null;_10[4]=null}
if(_8!=null){_10[5]=" HEIGHT=";_10[6]=_8}else{_10[5]=null;_10[6]=null}
if(this.wrap==false){_10[8]=this.$136}else{_10[8]=null}
_10[10]=_5;_4[25]=_10.join(isc.emptyString)}else{_4[25]=null}
return _4.join(isc.emptyString)},isc.A.getOuterElement=function isc_NativeCheckboxItem_getOuterElement(_1,_2,_3){if(!this.isDrawn())return null;if(!this.$15s(this.$158)&&!this.showPickerIcon){var _4=this.getCheckboxTableElement();if(_4==null){_4=this.getDataElement()}
return _4}
return this.invokeSuper(isc.NativeCheckboxItem,"getOuterElement",_1,_2,_3)},isc.A.getCheckboxTableElement=function isc_NativeCheckboxItem_getCheckboxTableElement(){var _1=this.$qs("checkboxTable");return isc.Element.get(_1)},isc.A.getTitleHTML=function isc_NativeCheckboxItem_getTitleHTML(){return""},isc.A.getAnchorTitle=function isc_NativeCheckboxItem_getAnchorTitle(_1,_2,_3,_4){return this.invokeSuper(isc.NativeCheckboxItem,"getTitleHTML",_1,_2,_3,_4)},isc.A.setElementValue=function isc_NativeCheckboxItem_setElementValue(_1){var _2=this.getDataElement();if(!_2)return null;return _2.checked=(_1&&_1!="false")},isc.A.getElementValue=function isc_NativeCheckboxItem_getElementValue(){var _1=this.getDataElement();if(!_1)return null;return(_1.checked==true)},isc.A.boxTitleClick=function isc_NativeCheckboxItem_boxTitleClick(){var _1=this.getDataElement();if(_1)_1.checked=!_1.checked;this.form.elementChanged(this.getItemID())},isc.A.setElementReadOnly=function isc_NativeCheckboxItem_setElementReadOnly(_1){var _2=this.isDisabled()||_1;this.$176(!_2)},isc.A.updateState=function isc_NativeCheckboxItem_updateState(){this.Super("updateState",arguments);var _1=this.getCheckboxTableElement();if(_1){var _2=this.getTextBoxStyle();_1.className=_2;if(this.showLabel&&!this.showValueIconOnly){var _3=_1.rows[0].cells[1];_3.className=_2}}});isc.B._maxIndex=isc.C+11;isc.ClassFactory.defineClass("HeaderItem","FormItem");isc.A=isc.HeaderItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.shouldSaveValue=false;isc.A.defaultValue="Header";isc.A.height=20;isc.A.showTitle=false;isc.A.textBoxStyle="headerItem";isc.A.canSelectText=true;isc.A.colSpan="*";isc.A.startRow=true;isc.A.endRow=true;isc.A.applyAlignToText=true;isc.A.emptyDisplayValue="&nbsp;";isc.B.push(isc.A.isEditable=function isc_HeaderItem_isEditable(){return false});isc.B._maxIndex=isc.C+1;isc.defineClass("SectionItem","CanvasItem");isc.A=isc.SectionItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.shouldSaveValue=false;isc.A.defaultValue="Section Header";isc.A.sectionVisible=true;isc.A.sectionExpanded=true;isc.A.sectionHeaderClass="SectionHeader";isc.A.canCollapse=true;isc.A.autoDestroy=true;isc.A.showTitle=false;isc.A.startRow=true;isc.A.endRow=true;isc.A.colSpan="*";isc.A.width="*";isc.A.height=20;isc.A.readOnlyDisplay="readOnly";isc.B.push(isc.A.renderAsDisabled=function isc_SectionItem_renderAsDisabled(){return(this.isDisabled()||(this.canEdit==false&&this.getReadOnlyDisplay()=="disabled"))},isc.A.isReadOnly=function isc_SectionItem_isReadOnly(){return this.renderAsDisabled()});isc.B._maxIndex=isc.C+2;isc.addGlobal("GroupItem",isc.SectionItem);isc.A=isc.SectionItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.init=function isc_SectionItem_init(){if(this.sectionVisible==false)this.sectionExpanded=false;this.Super("init",arguments)},isc.A.$18y=function isc_SectionItem__createCanvas(){var _1=isc.ClassFactory.getClass(this.sectionHeaderClass,true),_2={autoDraw:false,section:this,title:this.value!=null?this.value:this.defaultValue,expanded:this.sectionExpanded,layout:this,height:this.height,canCollapse:this.canCollapse,canDrag:false,getCurrentCursor:function(){if(this.canvasItem&&this.canvasItem.cursor!=null)return this.canvasItem.cursor;return this.canCollapse==false?isc.Canvas.DEFAULT:isc.Canvas.HAND}};if(this.baseStyle!=null)_2.baseStyle=this.baseStyle;if(this.printStyleName!=null)_2.printStyleName=this.printStyleName;isc.addProperties(_2,this.canvasDefaults,this.canvasProperties);var _3=_1.create(_2);this.canvas=_3;this.Super("$18y",arguments)},isc.A.isEditable=function isc_SectionItem_isEditable(){return false},isc.A.isExpanded=function isc_SectionItem_isExpanded(){return this.sectionExpanded==true?true:false},isc.A.setValue=function isc_SectionItem_setValue(_1){this.Super("setValue",arguments);if(this.canvas)this.canvas.setTitle(this.getValue())},isc.A.sectionHeaderClick=function isc_SectionItem_sectionHeaderClick(){this.cellClick();return false},isc.A.getDragResizeTarget=function isc_SectionItem_getDragResizeTarget(_1){return null},isc.A.cellClick=function isc_SectionItem_cellClick(){if(!this.canCollapse)return;if(this.sectionExpanded){this.collapseSection()}else{this.expandSection()}},isc.A.expandSection=function isc_SectionItem_expandSection(){this.form.$100(this);this.$20f();if(this.itemIds==null){this.logWarn("sectionItem defined with no items or itemIds");return}
for(var i=0;i<this.itemIds.length;i++){var _2=this.itemIds[i],_3=this.form.getItem(_2);if(_3==null){this.logWarn("expandSection: no such item: "+_2);continue}
if(_3.showIf==null&&_3.$20g!=null)_3.showIf=_3.$20g;_3.show(true)}
this.canvas.setExpanded(true);this.sectionExpanded=true;this.form.$10m=true},isc.A.$20f=function isc_SectionItem__createItems(){if(this.items!=null&&!this.$20h){this.form.addItems(this.items,this.form.items.indexOf(this)+1);this.itemIds=[];for(var i=0;i<this.items.length;i++){this.itemIds[i]=this.items[i].getFieldName();if(this.itemIds[i]==null){this.logWarn("unable to include item:"+this.items[i]+" with no name in section")}}
this.$20h=true}},isc.A.addItem=function isc_SectionItem_addItem(_1,_2){this.form.addItems(_1,this.form.items.indexOf(this)+1+(_2||0));this.itemIds=this.itemIds||[];this.itemIds.add(_1.name)},isc.A.removeItem=function isc_SectionItem_removeItem(_1){var _2=(isc.isA.Object(_1)?_1.name:_1);this.itemIds.remove(_2);this.form.removeItems(_1)},isc.A.getItem=function isc_SectionItem_getItem(_1){return this.form.getItem(_1)},isc.A.collapseSection=function isc_SectionItem_collapseSection(){this.form.$101(this);if(this.itemIds==null){if(this.items==null||this.$20h){this.logWarn("collapseSection with no sectionItem.itemIds");return}}else{for(var i=0;i<this.itemIds.length;i++){var _2=this.itemIds[i],_3=this.form.getItem(_2);if(_3==null){this.logWarn("collapseSection: no such item: "+_2);continue}
if(_3.showIf!=null)_3.$20g=_3.showIf;_3.hide()}}
this.canvas.setExpanded(false);this.sectionExpanded=false;this.form.$10m=true},isc.A.$85m=function isc_SectionItem__shouldAllowExpressions(){return false});isc.B._maxIndex=isc.C+15;isc.ClassFactory.defineClass("HiddenItem","FormItem");isc.A=isc.HiddenItem.getPrototype();isc.A.showTitle=false;isc.A.cellStyle=null;isc.A.width=0;isc.A.height=0;isc.A.colSpan=0;isc.A.rowSpan=0;isc.A.$125=true;isc.A.canFocus=false;isc.A.shouldPrint=false;isc.A.fetchMissingValues=false;isc.A=isc.HiddenItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.isEditable=function isc_HiddenItem_isEditable(){return false},isc.A.getInnerHTML=function isc_HiddenItem_getInnerHTML(_1){var _2=isc.StringBuffer.concat("<INPUT ID='",this.getDataElementId(),"' TYPE=HIDDEN NAME=",this.getElementName(),">");return _2.toString()},isc.A.getRowSpan=function isc_HiddenItem_getRowSpan(){return 0},isc.A.getColSpan=function isc_HiddenItem_getColSpan(){return 0},isc.A.shouldShowTitle=function isc_HiddenItem_shouldShowTitle(){return false},isc.A.getErrorHTML=function isc_HiddenItem_getErrorHTML(_1){this.logError("Error in hidden field '"+this.getFieldName()+"':\r  "+_1);return null},isc.A.isStartRow=function isc_HiddenItem_isStartRow(){return false},isc.A.isEndRow=function isc_HiddenItem_isEndRow(){return false});isc.B._maxIndex=isc.C+8;isc.ClassFactory.defineClass("StaticTextItem","FormItem");isc.A=isc.StaticTextItem.getPrototype();isc.A.height=null;isc.A.applyHeightToTextBox=false;isc.A.applyAlignToText=true;isc.A.wrap=true;isc.A.clipValue=false;isc.A.textBoxStyle="staticTextItem";isc.A.canSelectText=true;isc.A.redrawOnShowIcon=false;isc.A.useShortDateFormat=false;isc.A.canEscapeHTML=true;isc.A.escapeHTML=null;isc.A.emptyDisplayValue="&nbsp;";isc.A=isc.StaticTextItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.isEditable=function isc_StaticTextItem_isEditable(){return false},isc.A.$1618=function isc_StaticTextItem__getClipValue(){return!!this.clipValue||this.$1617()},isc.A.$kk=function isc_StaticTextItem__canFocus(){if(this.canFocus!=null)return this.canFocus;return isc.screenReader},isc.A.mapValueToDisplay=function isc_StaticTextItem_mapValueToDisplay(_1){if(isc.SimpleType.inheritsFrom(this.type,"float")){var _2=null;if(isc.isA.String(_1)&&(this.type==null||!this.type.startsWith("locale"))){var _3=window.parseFloat(_1);if(!window.isNaN(_3)&&_3==_1){_2=_3}}else if(isc.isA.Number(_1)){_2=_1}
if(_2!=null){if(this.format){return isc.NumberUtil.format(_2,this.format)}else if(this.$62!=null&&this.$62.editFormatter!=null){var _4=this.form,_5=this.form?this.form.values:{};return this.$62.editFormatter(_1,this,_4,_5)}else if(this.decimalPrecision!=null||this.decimalPad!=null){return isc.Canvas.getFloatValueAsString(_2,this.decimalPrecision,this.decimalPad)}else if(this.precision!=null){return isc.Canvas.getNumberValueAsString(_2,this.precision,"float")}}}
return this.Super("mapValueToDisplay",arguments)});isc.B._maxIndex=isc.C+4;isc.ClassFactory.defineClass("LinkItem","TextItem");isc.A=isc.LinkItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.disableIconsOnReadOnly=false;isc.A.wrap=false;isc.A.clipValue=false;isc.A.iconVAlign="center";isc.A.height=null;isc.A.applyHeightToTextBox=false;isc.A.canEdit=false;isc.B.push(isc.A.shouldApplyStaticTypeFormat=function isc_LinkItem_shouldApplyStaticTypeFormat(){return!this.canEdit});isc.B._maxIndex=isc.C+1;isc.A=isc.LinkItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$14g=["<DIV ID='",,"' "+isc.DynamicForm.$89+"='",,,"' CLASS='",,"' STYLE='",,"'>",,"</DIV>"];isc.A.inactiveEditorLinkDisabled=true;isc.A.$1465=[" onclick='if(window.",null,") return ",null,null,null,isc.DynamicForm.$9a,"='",isc.DynamicForm.$9c,"'",null];isc.A.$1466="javascript";isc.A.$1467="javascript:void";isc.A.$1468=".$94a(event); ";isc.A.$1469="else {if (event.preventDefault != null) event.preventDefault(); return false}' ";isc.A.$147a=".$30i(event);' ";isc.A.$12a="link";isc.B.push(isc.A.$15m=function isc_LinkItem__writeOutFocusProxy(){return(this.isReadOnly()?false:this.Super("$15m",arguments))},isc.A.$20i=function isc_LinkItem__getLinkElement(){if(!this.isReadOnly())return this.Super("$20i",arguments);if(!this.isDrawn())return null;return(isc.Element.get(this.$qs(this.$12a)))},isc.A.getFocusElement=function isc_LinkItem_getFocusElement(){return(this.isReadOnly()?this.$20i():this.Super("getFocusElement",arguments))},isc.A.hasDataElement=function isc_LinkItem_hasDataElement(){return!this.isReadOnly()},isc.A.$kk=function isc_LinkItem__canFocus(){return(this.isReadOnly()?true:this.Super("$kk",arguments))},isc.A.getTextBoxStyle=function isc_LinkItem_getTextBoxStyle(){if(!this.isReadOnly())return this.Super("getTextBoxStyle",arguments);if(this.$68y()&&this.printTextBoxStyle){return this.$15x(this.printTextBoxStyle)}
return(this.readOnlyTextBoxStyle?this.$15x(this.readOnlyTextBoxStyle):null)},isc.A.$94a=function isc_LinkItem__inactiveLinkClicked(_1){if(!this.inactiveEditorLinkDisabled){return this.$30i(_1)}
if(!isc.Browser.isIE){_1.preventDefault()}
return false},isc.A.$30i=function isc_LinkItem__linkClicked(_1){var _2=(this.destroyed||!this.isDrawn()||!this.isVisible()||this.renderAsDisabled());if(!_2){_2=isc.EH.targetIsMasked(this.containerWidget);if(_2&&(this.form!=this.containerWidget)){_2=isc.EH.targetIsMasked(this.form)}}
if(!_2&&this.target=="javascript"){_2=true;this.handleClick()}
if(_2){if(!isc.Browser.isIE){_1.preventDefault()}
return false}
return true},isc.A.getReadOnlyHTML=function isc_LinkItem_getReadOnlyHTML(_1){this.$68x=true;var _2=this.getLinkHTML(_1);var _3=this.$14g;_3[1]=this.$15g();_3[3]=this.getID();_3[6]=this.getReadOnlyTextBoxStyle();_3[8]=this.getTextBoxCSS(_1);_3[10]=_2;delete this.$68x;return _3.join(isc.emptyString)},isc.A.updateDisabled=function isc_LinkItem_updateDisabled(){this.Super("updateDisabled",arguments);this.redraw()},isc.A.getLinkHTML=function isc_LinkItem_getLinkHTML(_1){var _2=this.$xq(this._value);if(this.showValueIconOnly)return _2;if(_1!=null)_1=isc.iscToLocaleString(_1);if(_1==null)_1=isc.emptyString;var _3=this.linkTitle;if(_3==null)_3=_1;var _4=this.target,_5=(_4===this.$1466);if(_5){_1=this.$1467}
var _6=this.$1465;_6[3]=_6[1]=this.getID()
if(this.isInactiveHTML()){_6[4]=this.$1468;_6[5]=this.$1469}else{_6[4]=this.$147a;_6[5]=null}
if(isc.Browser.isMobileWebkit){if(_5){_6[10]=" style='-webkit-touch-callout:none'"}else{_6[10]=" style='-webkit-touch-callout:default'"}}else{_6[10]=null}
var _7=_6.join(isc.emptyString);if(!this.renderAsDisabled()){_1=isc.Canvas.linkHTML(_1,_3,_4,this.$qs(this.$12a),this.getGlobalTabIndex(),this.accessKey,_7)}else{_1="<span style='text-decoration: underline;'>"+_3+"</span>"}
if(_2!=null){_1=_2+_1}
return _1},isc.A.setElementValue=function isc_LinkItem_setElementValue(_1){if(!this.isDrawn())return;if(!this.isReadOnly())return this.Super("setElementValue",arguments);if(this.hasFocus)this.blurItem();var _2=this.$15h();if(_2){_2.innerHTML=this.getLinkHTML(_1);this.$159()}},isc.A.setLinkTitle=function isc_LinkItem_setLinkTitle(_1){this.linkTitle=_1;this.redraw()},isc.A.setElementReadOnly=function isc_LinkItem_setElementReadOnly(_1){this.redraw()},isc.A.$872=function isc_LinkItem__canFocusInTextBox(){if(this.renderAsDisabled())return false;return this.Super("$872",arguments)});isc.B._maxIndex=isc.C+15;isc.defineClass("PasswordItem","TextItem");isc.A=isc.PasswordItem;isc.A.$1158="\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022";isc.A=isc.PasswordItem.getPrototype();isc.A.$183="PASSWORD";isc.A.showClippedValueOnHover=false;isc.A=isc.PasswordItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.valueHoverHTML=function isc_PasswordItem_valueHoverHTML(){var _1=this.getElementValue();if(_1==null)_1="";var _2=isc.PasswordItem.$1158;while(_2.length<_1.length)isc.PasswordItem.$1158=_2+=_2;return _2.substring(0,_1.length)});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("RadioGroupItem","ContainerItem");isc.A=isc.RadioGroupItem.getPrototype();isc.A.itemHeight=20;isc.A.vertical=true;isc.A.fillHorizontalSpace=false;isc.A.prompt=null;isc.A.textBoxStyle="labelAnchor";isc.A.writeOutLabelTag=false;isc.A=isc.RadioGroupItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$145e={Arrow_Left:true,Arrow_Right:true,Arrow_Up:true,Arrow_Down:true};isc.B.push(isc.A.init=function isc_RadioGroupItem_init(){if(this.disabledValues!=null){this.$821={};for(var i=0;i<this.disabledValues.length;i++){var _2=this.disabledValues[i];this.$821[_2]=true}}
return this.Super("init",arguments)},isc.A.setTextBoxStyle=function isc_RadioGroupItem_setTextBoxStyle(_1){this.textBoxStyle=_1;var _2=this.items;if(_2!=null){for(var i=0,_4=_2.length;i<_4;++i){var _5=_2[i];var _6=_5.textBoxStyle;_5.textBoxStyle=_1;if(_6!=_1)_5.updateState()}}},isc.A.$1609=function isc_RadioGroupItem__updatePendingStatuses(){var _1=this.$161p()&&this.pendingStatus;var _2=this.itemForValue(this._value);if(_2!=null){_2.setFixedPendingStatus(_1)}},isc.A.$11d=function isc_RadioGroupItem__useHiddenDataElement(){return false},isc.A.setItems=function isc_RadioGroupItem_setItems(){var _1=isc.SimpleType.inheritsFrom(this.getType(),"boolean");if(_1)this.initBooleanValueMap();var _2=this.getValueMap();if(!this.itemCache)this.itemCache={};var _3=[];if(isc.isAn.Array(_2)){for(var i=0;i<_2.length;i++){var _5=_2[i];_3.add(this.$20k(_5,_5))}}else{var _6=isc.getKeys(_2);for(var i=0;i<_6.length;i++){var _5=_6[i];var _7=_2[_5];if(_1&&!isc.isA.Boolean(_5)){if(isc.isA.String(_5))_5=_5.toLowerCase();if(_5=="false")_5=false;else if(_5=="true")_5=true;else if(_6.length==2)_5=(i==0)}
_3.add(this.$20k(_7,_5))}}
return this.Super("setItems",[_3])},isc.A.$20k=function isc_RadioGroupItem__getRadioItem(_1,_2){var _3=(this.$161p()&&this.pendingStatus);var _4=this.itemCache[_2+"|"+_1];if(_4){if(_2!=_4._value){delete _4._value;delete _4.$105}
delete _4.hasFocus;delete _4.disabled;_4.setFixedPendingStatus(_3&&_2==this._value)}else{var _5;if(this.itemPrompt){var _6=new RegExp("\\*","g");_5=this.itemPrompt.replace(_6,_1)}
var _7={type:"radio",name:"$540"+_2,_autoAssignedName:true,value:_2,getElementName:function(){return this.parentItem.getElementName()},title:_1,prompt:_5,height:this.itemHeight,$8l:this.vertical,fixedPendingStatus:_3&&_2==this._value,textBoxStyle:this.textBoxStyle,wrap:this.wrap,updateValue:function(){this.parentItem.updatePreviousSelection(this.value);return this.Super("updateValue",arguments)},setDisabled:function(_9){this.parentItem.$822(this.value,_9);return this.Super("setDisabled",arguments)},shouldSaveValue:false,suppressItemChanged:true};isc.addProperties(_7,this.itemProperties);var _8=this;if(!_7.itemHoverHTML&&this.valueHoverHTML){_7.itemHoverHTML=function(){return _8.valueHoverHTML(_2,_8,_8.form)}}
_7.form=this.form;_4=this.itemCache[_2+"|"+_1]=isc.FormItemFactory.makeItem(_7)}
if(this.$821!=null&&this.$821[_2]!=null){_4.disabled=this.$821[_2]}
return _4},isc.A.getItemValue=function isc_RadioGroupItem_getItemValue(_1){var _2=_1.value;if(_2==this.getValue())return _2;return _1.unselectedValue},isc.A.itemForValue=function isc_RadioGroupItem_itemForValue(_1){return this["$540"+_1]},isc.A.setValueDisabled=function isc_RadioGroupItem_setValueDisabled(_1,_2){if(this.$821!=null&&this.$821[_1]==_2)return;var _3=this.itemForValue(_1);if(_3&&this.items.contains(_3)){_3.setDisabled(_2)}else{this.$822(_1,_2)}},isc.A.$822=function isc_RadioGroupItem__itemDisabled(_1,_2){if(this.$821==null)this.$821={};this.$821[_1]=_2},isc.A.getTitleHTML=function isc_RadioGroupItem_getTitleHTML(){var _1=this.getTitle();return isc.SB.concat("<label id=",this.$1568(),">",_1,"</label>")},isc.A.getInnerHTML=function isc_RadioGroupItem_getInnerHTML(_1){this.setItems();return this.Super("getInnerHTML",arguments)},isc.A.$174w=function isc_RadioGroupItem__writeWidthAttribute(){if(this.writeWidthAttribute)return true;return this.fillHorizontalSpace},isc.A.$174z=function isc_RadioGroupItem__writeSizingDiv(){return!this.$174w()},isc.A.isEditable=function isc_RadioGroupItem_isEditable(){return true},isc.A.setElementReadOnly=function isc_RadioGroupItem_setElementReadOnly(_1){},isc.A.initBooleanValueMap=function isc_RadioGroupItem_initBooleanValueMap(){var _1=isc.SimpleType.inheritsFrom(this.getType(),"boolean");if(_1&&isc.isAn.Array(this.valueMap)&&this.valueMap.length==2){this.valueMap={"true":this.valueMap[0],"false":this.valueMap[1]}}},isc.A.setValue=function isc_RadioGroupItem_setValue(_1){this.$17g=true;var _2=(this.valueMap==null)||(isc.isAn.Array(this.valueMap)?!this.valueMap.contains(_1):!isc.propertyDefined(this.valueMap,_1));if(_1==null||_2){_1=this.getDefaultValue()}
if(this.items!=null){var _3=this.itemForValue(_1);if(_3!=null){this.itemForValue(_1).setValue(_1);_3.setFixedPendingStatus(this.$161p()&&this.pendingStatus)}
var _4;if(this._value!=null&&this._value!=_1){_4=this.itemForValue(this._value)}else if(this.$17m){_4=this.itemForValue(this.$17n)}
if(_4!=null){_4.setValue(null);_4.setFixedPendingStatus(false)}}
this.saveValue(_1)},isc.A.updatePreviousSelection=function isc_RadioGroupItem_updatePreviousSelection(_1){var _2=this.itemForValue(_1);_2.setFixedPendingStatus(this.$161p()&&this.pendingStatus);var _3=this.getValue();if(isc.isA.String(_1))_3=_3+"";var _4;if(_3==null||_1==_3||(_4=this.itemForValue(_3))==null)
{return}
_4.updateValue();_4.setFixedPendingStatus(false)},isc.A.updateValue=function isc_RadioGroupItem_updateValue(){var _1;for(var i=0;i<this.items.length;i++){_1=this.items[i].getValue();if(_1!=null){break}}
if(_1==this._value)return;if(this.handleChange(_1,this._value)==false){return}
_1=this.$17n;this.saveValue(_1);this.handleChanged(_1)},isc.A.setValueMap=function isc_RadioGroupItem_setValueMap(_1){this.Super("setValueMap",arguments);this.redraw()},isc.A.getHeight=function isc_RadioGroupItem_getHeight(){var _1=isc.isA.Number(this.cellPadding)?this.cellPadding:0;if(!this.vertical)return this.itemHeight+_1*2;var _2=this.getValueMap(),_3=0;if(isc.isAn.Array(_2)){_3=_2.length}else{for(var _4 in _2){_3++}}
return _3*(this.itemHeight+_1*2)},isc.A.shouldStopKeyPressBubbling=function isc_RadioGroupItem_shouldStopKeyPressBubbling(_1,_2){if(this.$145e[_1])return true;return this.Super("shouldStopKeyPressBubbling",arguments)});isc.B._maxIndex=isc.C+23;isc.ClassFactory.defineClass("RadioItem","NativeCheckboxItem");isc.A=isc.RadioItem.getPrototype();isc.A.$183="RADIO";isc.A.value=true;isc.A.defaultValue=null;isc.A=isc.RadioItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.setElementValue=function isc_RadioItem_setElementValue(_1){var _2=this.getDataElement();if(!_2)return null;if(isc.isA.String(this.value))_1=(_1+"");return _2.checked=(this.value==_1)},isc.A.getElementValue=function isc_RadioItem_getElementValue(){var _1=this.getDataElement(),_2=this.value,_3=this.unselectedValue;if(!_1)return _3;return(_1.checked?_2:_3)},isc.A.boxTitleClick=function isc_RadioItem_boxTitleClick(){var _1=this.getDataElement();if(_1&&!_1.checked){_1.checked=true;this.form.elementChanged(this.getItemID())}},isc.A.mapValueToDisplay=function isc_RadioItem_mapValueToDisplay(_1){return _1},isc.A.mapDisplayToValue=function isc_RadioItem_mapDisplayToValue(_1){return _1},isc.A.setElementReadOnly=function isc_RadioItem_setElementReadOnly(_1){this.$176(!_1&&!this.isDisabled())});isc.B._maxIndex=isc.C+6;isc.ClassFactory.defineClass("ResetItem","ButtonItem");isc.A=isc.ResetItem.getPrototype();isc.A.title="Reset";isc.A=isc.ResetItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.handleClick=function isc_ResetItem_handleClick(){if(this.Super("handleClick",arguments)==false)return false;this.form.resetValues()});isc.B._maxIndex=isc.C+1;if(isc.ListGrid){isc.defineClass("NativeDateItem","TextItem");isc.A=isc.NativeDateItem.getPrototype();isc.A.ariaRole="range";isc.A.browserInputType="date";isc.A.textBoxStyle="nativeDateItem";isc.A.inFieldHintStyle="nativeDateItemInFieldHint";isc.A.showClippedValueOnHover=false;isc.A=isc.NativeDateItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$118w="wrapper";isc.A.$118x="hint";isc.A.operaForegroundColor="black";isc.B.push(isc.A.$118y=function isc_NativeDateItem__getWrapperElementId(){if(this.isInactiveHTML())return this.$qs(this.$118w);if(this.$118z==null){this.$118z=this.$qs(this.$118w,true)}
return this.$118z},isc.A.$1180=function isc_NativeDateItem__getHintElementId(){if(this.isInactiveHTML())return this.$qs(this.$118x);if(this.$1181==null){this.$1181=this.$qs(this.$118x,true)}
return this.$1181},isc.A.$1182=function isc_NativeDateItem__getInFieldHintElemStyle(){if(this.showDisabled&&this.renderAsDisabled())return this.inFieldHintStyle+"Disabled";return this.inFieldHintStyle},isc.A.getElementHTML=function isc_NativeDateItem_getElementHTML(_1,_2){if(!this.$712())return this.Super("getElementHTML",arguments);var _3=this.getHeight();return"<div id='"+this.$118y()+"' class='"+this.$15x(this.$118w)+"' style='display:inline-block;position:relative;height:"+_3+"px'>"+this.Super("getElementHTML",arguments)+"<span id='"+this.$1180()+"' class='"+this.$1182()+"' style='line-height:"+_3+"px'></span></div>"},isc.A.getElementStyleHTML=function isc_NativeDateItem_getElementStyleHTML(){var _1=this.Super("getElementStyleHTML",arguments);if(isc.Browser.isOpera){_1=_1.substring(0,_1.length-2)+";color:"+this.operaForegroundColor+_1.substring(_1.length-2)}
var _2=isc.DateUtil.getLogicalDateOnly(this.getStartDate()),_3=isc.DateUtil.getLogicalDateOnly(this.getEndDate());if(_2!=null)_1+="min='"+this.mapValueToDisplay(_2)+"' ";if(_3!=null)_1+="max='"+this.mapValueToDisplay(_3)+"' ";return _1},isc.A.getElementValue=function isc_NativeDateItem_getElementValue(){var _1=this.getDataElement(),_2;if(!_1||!(_2=_1.value))return null;return isc.DateUtil.createLogicalDate(parseInt(_2,10),parseInt(_2.substring(5),10)-1,parseInt(_2.substring(8),10))},isc.A.setElementValue=function isc_NativeDateItem_setElementValue(_1,_2){if(!this.isDrawn())return;var _3;if(_2===_3){_2=this._value}
var _4=this.getDataElement();if(_4!=null){_4.value=_1}},isc.A.getStartDate=function isc_NativeDateItem_getStartDate(){var _1=this.startDate;if(_1!=null&&!isc.isA.Date(_1)){_1=isc.DateItem.DEFAULT_START_DATE}
return _1},isc.A.getEndDate=function isc_NativeDateItem_getEndDate(){var _1=this.endDate;if(_1!=null&&!isc.isA.Date(_1)){_1=isc.DateItem.DEFAULT_END_DATE}
return _1},isc.A.mapValueToDisplay=function isc_NativeDateItem_mapValueToDisplay(_1){if(isc.isA.Date(_1)){_1=isc.DateUtil.getLogicalDateOnly(_1);return _1.toSchemaDate()}
return _1},isc.A.$66t=function isc_NativeDateItem__showInFieldHint(){var _1=isc.Element.get(this.$1180());if(_1!=null){this.getDataElement().className=this.$66v();_1.className=this.$1182();var _2=this.getHint();_1.innerText=String.htmlStringToString(_2);this.$66u=true}},isc.A.$66s=function isc_NativeDateItem__hideInFieldHint(_1){var _2=isc.Element.get(this.$1180());if(_2!=null){this.getDataElement().className=this.getTextBoxStyle();_2.className=this.$1182();_2.innerText=isc.emptyString;this.$66u=false}},isc.A.updateState=function isc_NativeDateItem_updateState(){this.Super("updateState",arguments);if(this.$66u){var _1=isc.Element.get(this.$1180());if(_1!=null)_1.className=this.$1182()}});isc.B._maxIndex=isc.C+13;isc.defineClass("NativeDateTimeItem","NativeDateItem");isc.A=isc.NativeDateTimeItem.getPrototype();isc.A.browserInputType="datetime-local";isc.A.textBoxStyle="nativeDatetimeItem";isc.A.inFieldHintStyle="nativeDatetimeItemInFieldHint";isc.A=isc.NativeDateTimeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.getElementValue=function isc_NativeDateTimeItem_getElementValue(){var _1=this.getDataElement(),_2;if(!_1||!(_2=_1.value))return null;var _3=parseInt(_2,10),_4=parseInt(_2.substring(5),10)-1,_5=parseInt(_2.substring(8),10),h=parseInt(_2.substring(11),10),m=parseInt(_2.substring(14),10),s=(_2.length>=19?parseInt(_2.substring(17),10):0);return new Date(Date.UTC(_3,_4,_5,h,m,s))},isc.A.mapDisplayToValue=function isc_NativeDateTimeItem_mapDisplayToValue(_1){if(isc.Time.$854&&isc.isA.Date(_1)){return isc.DateUtil.createDatetime(_1.getUTCFullYear(),_1.getUTCMonth(),_1.getUTCDate(),_1.getUTCHours(),_1.getUTCMinutes(),_1.getUTCSeconds(),_1.getUTCMilliseconds())}
return _1},isc.A.mapValueToDisplay=function isc_NativeDateTimeItem_mapValueToDisplay(_1){if(isc.isA.Date(_1)){var _2=_1.toSerializeableDate();return _2.substring(0,10)+"T"+_2.substring(11)}
return _1});isc.B._maxIndex=isc.C+3;isc.defineClass("DateItem","ContainerItem");isc.A=isc.DateItem;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.mapCache={};isc.A.DAY_MONTH_YEAR="DMY";isc.A.MONTH_DAY_YEAR="MDY";isc.A.YEAR_MONTH_DAY="YMD";isc.A.DAY_MONTH="DM";isc.A.MONTH_DAY="MD";isc.A.YEAR_MONTH="YM";isc.A.MONTH_YEAR="MY";isc.A.DEFAULT_START_DATE=isc.DateUtil.createLogicalDate(new Date().getYear()+1890,0,1);isc.A.DEFAULT_END_DATE=isc.DateUtil.createLogicalDate(new Date().getYear()+1905,11,31);isc.A.DEFAULT_CENTURY_THRESHOLD=25;isc.A.chooserWidth=150;isc.A.chooserHeight=175;isc.B.push(isc.A.getChooserWidth=function isc_c_DateItem_getChooserWidth(){return(isc.DateChooser.getPrototype().width||isc.DateItem.chooserWidth)},isc.A.getChooserHeight=function isc_c_DateItem_getChooserHeight(){return(isc.DateChooser.getPrototype().height||isc.DateItem.chooserHeight)});isc.B._maxIndex=isc.C+2;isc.A=isc.DateItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.defaultType="date";isc.A.textFieldDefaults={name:"dateTextField",type:"text",changeOnBlur:true,width:"100%",$712:function(){return this.parentItem.$712()},$1564:function(){if(!this.parentItem.usePlaceholderForHint)return false;return this.$1560()},getHint:function(){if(this.$712())return this.parentItem.hint;return null},changeOnKeypress:true,changed:function(){this.isDirty=true},blur:function(){this.isDirty=false;if(this.parentItem)this.parentItem.updateValue()},shouldSaveValue:false,getTextBoxStyle:function(){var _1=this.parentItem;return _1&&!_1.$1188()?_1.getTextItemTextBoxStyle():this.Super("getTextBoxStyle",arguments)},getTextBoxWidth:function(_1){if(this.parentItem)return this.parentItem.getTextBoxWidth(_1);return this.Super("getTextBoxWidth",arguments)},$887:true,getDefaultValue:function(){if(this.parentItem)return this.parentItem.getDefaultValue();return this.Super("getDefaultValue",arguments)},itemHoverHTML:function(_1,_2){if(this.parentItem)return this.parentItem.subItemHoverHTML(_1,_2)}};isc.A.textBoxStyle="textItem";isc.A.wrapHintText=false;isc.A.usePlaceholderForHint=true;isc.A.daySelectorDefaults={name:"daySelector",title:"Day",prompt:"Choose a day",type:"select",valueMap:"this.parentItem.getDayOptions()",shouldSaveValue:false,updateValue:function(){this.Super("updateValue",arguments);this.parentItem.updateValue()},getErrorWidth:function(){return 0},width:45,suppressItemChanged:true,itemHoverHTML:function(_1,_2){if(this.parentItem)return this.parentItem.subItemHoverHTML(_1,_2)}};isc.A.monthSelectorDefaults={name:"monthSelector",title:"Month",prompt:"Choose a month",type:"select",valueMap:"this.parentItem.getMonthOptions()",shouldSaveValue:false,updateValue:function(){this.Super("updateValue",arguments);this.parentItem.updateValue()},getErrorWidth:function(){return 0},width:55,suppressItemChanged:true,pickListHeight:1000,itemHoverHTML:function(_1,_2){if(this.parentItem)return this.parentItem.subItemHoverHTML(_1,_2)}};isc.A.yearSelectorDefaults={name:"yearSelector",title:"Year",prompt:"Choose a year",type:"select",valueMap:"this.parentItem.getYearOptions()",shouldSaveValue:false,updateValue:function(){this.Super("updateValue",arguments);this.parentItem.updateValue()},getErrorWidth:function(){return 0},width:60,suppressItemChanged:true,itemHoverHTML:function(_1,_2){if(this.parentItem)return this.parentItem.subItemHoverHTML(_1,_2)}};isc.A.width=150;isc.A.cellPadding=0;isc.A.useSharedPicker=true;isc.A.pickerConstructor="DateChooser";isc.A.pickerDefaults={border:"1px solid black;",showCancelButton:true,autoHide:true,closeOnEscapeKeypress:true};isc.A.textAlign=isc.Page.isRTL()?isc.Canvas.LEFT:isc.Canvas.RIGHT;isc.A.enforceDate=false;isc.A.invalidDateStringMessage="Invalid date";isc.A.showPickerIcon=true;isc.A.pickerIconWidth=20;isc.A.pickerIconHeight=20;isc.A.pickerIconSrc="[SKIN]/DynamicForm/DatePicker_icon.gif";isc.A.pickerIconHSpace=3;isc.A.pickerIconPrompt="Show Date Chooser";isc.A.centuryThreshold=isc.DateItem.DEFAULT_CENTURY_THRESHOLD;isc.A.use24HourTime=true;isc.A.showPickerTimeItem=true;isc.B.push(isc.A.$143=function isc_DateItem__sizeTextBoxAsContentBox(){return isc.Browser.isStrict},isc.A.getTextItemTextBoxStyle=function isc_DateItem_getTextItemTextBoxStyle(){if(this.textField==null)return this.getTextBoxStyle();if(this.$68y()&&this.printTextBoxStyle){return this.$15x(this.printTextBoxStyle,this.$1600)}
var _1=(this.getCanEdit()==false&&this.renderAsStatic()?this.getReadOnlyTextBoxStyle():this.textBoxStyle),_2=this.textField.$15x(_1,this.$13q);return _2},isc.A.getOperator=function isc_DateItem_getOperator(_1){if(!this.operator)return"equals";return this.operator},isc.A.$16f=function isc_DateItem__shouldShowIcon(_1,_2){if(_1&&_1.pickerIcon){if(this.$1188())return false;if(isc[this.pickerConstructor]==null){this.logWarn("Date Item pickerConstructor class '"+this.pickerConstructor+"' is not loaded. This property may have been modified incorrectly  or a required module may not be loaded. Suppressing the pickerIcon.");return false}}
return this.Super("$16f",arguments)});isc.B._maxIndex=isc.C+4;isc.A=isc.DateItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$g4="date";isc.A.$68l="datetime";isc.A.$792="[01][0-9]";isc.A.$793="[0-3]#";isc.A.$794="####";isc.A.$73d="[0-2][0-9]:[0-6][0-9]";isc.A.$73r={"MDY":"toUSShortDate","DMY":"toEuropeanShortDate","YMD":"toJapanShortDate"};isc.A.selectorPadding=2;isc.A.showChooserFiscalYearPicker=false;isc.A.showChooserWeekPicker=false;isc.B.push(isc.A.init=function isc_DateItem_init(){if(this.useTextField==null)this.useTextField=this.useMask||false;else if(!this.useTextField&&this.showTime){this.logWarn("When showing the time component, useTextField must be true.");this.useTextField=true}
if(this.selectorFormat){if(!this.selectorFormat.toUpperCase||this.selectorFormat.length==0){this.selectorFormat=null}else{var _1=this.selectorFormat.toUpperCase();if(!_1.match("^[DMY]*$")){this.selectorFormat=null}}}
if(this.useTextField){this.saveOnEnter=true;this.textFieldDefaults.readOnlyDisplay=this.readOnlyDisplay}
if(this.showTime&&!this.dateFormatter&&!this.timeFormatter){if(this.$180y()){if(this.use24HourTime){this.timeFormatter="toShort24HourTime"}else{this.timeFormatter="toShortPaddedTime"}}}
return this.Super("init",arguments)},isc.A.$180y=function isc_DateItem__hasCustomUse24HourTimeFlag(){return this.getClass().getInstanceProperty("use24HourTime")!=this.use24HourTime},isc.A.$1609=function isc_DateItem__updatePendingStatuses(){var _1=this.$161p()&&this.pendingStatus;if(this.useTextField){var _2=this.textField;if(_2!=null)_2.setFixedPendingStatus(_1)}else{var _3=this.$160w(),_4;if(!isc.isA.Date(_3))_4=null;else if(_3.logicalDate)_4=_3;else _4=isc.DateUtil.getLogicalDateOnly(_3);var _5=this._value,_6;if(!isc.isA.Date(_5))_6=null;else{_6=_5}
var _7=this.daySelector;if(_7!=null){_7.setFixedPendingStatus(_1&&(_4==null||_6==null||_4.getDate()!=_6.getDate()))}
var _8=this.monthSelector;if(_8!=null){_8.setFixedPendingStatus(_1&&(_4==null||_6==null||_4.getMonth()!=_6.getMonth()))}
var _9=this.yearSelector;if(_9!=null){_9.setFixedPendingStatus(_1&&(_4==null||_6==null||_4.getFullYear()!=_6.getFullYear()))}}},isc.A.$712=function isc_DateItem__getShowHintInField(){return!!(this.useTextField&&this.showHint&&this.hint&&this.showHintInField&&!(isc.Browser.isOpera&&this.$1189()))},isc.A.getHint=function isc_DateItem_getHint(){if(!this.showHint||!this.hint||this.$712())return null;return this.hint},isc.A.$1188=function isc_DateItem__useNativeInput(){var _1=this.getBrowserInputType();return this.useTextField&&(_1==this.$g4||_1==this.$68l)},isc.A.$1189=function isc_DateItem__useNativeDatetimeInput(){return this.useTextField&&this.getBrowserInputType()==this.$68l},isc.A.getSelectorFormat=function isc_DateItem_getSelectorFormat(){if(this.selectorFormat){return this.selectorFormat}else if(this.inputFormat&&isc.isA.String(this.inputFormat)){return this.inputFormat}else{var _1=isc.DateUtil.getInputFormat();if(isc.isA.String(_1))return _1;this.logInfo("DateItem selectorFormat unspecified - assuming US format");return"MDY"}},isc.A.getInputFormatMask=function isc_DateItem_getInputFormatMask(_1){var _2=this.maskDateSeparator||this.$79w();var _3;if(_1=="YMD"){_3=[this.$794,_2,this.$792,_2,this.$793]}else if(_1=="DMY"){_3=[this.$793,_2,this.$792,_2,this.$794]}else{_3=[this.$792,_2,this.$793,_2,this.$794]}
if(isc.isA.DateTimeItem(this)){_3.addList([" ",this.$73d])}
return _3.join("")},isc.A.$79w=function isc_DateItem__getDefaultDateSeparator(){return isc.DateUtil.getDefaultDateSeparator()},isc.A.$79x=function isc_DateItem__getDefaultDateSeparatorRegex(){var _1=this.$79w();return new RegExp(_1,"/g")},isc.A.setItems=function isc_DateItem_setItems(_1){var _2=isc.DateItem,_3=this.getSelectorFormat();if(_1!=null&&_1.length!=0){this.logWarn("setItems() called for dateItem with itemList:"+_1+" - ignoring, and making use of default date fields")}
_1=this.items=[];if(this.useTextField){var _4={textAlign:this.textAlign,emptyDisplayValue:this.emptyDisplayValue,operator:this.operator,title:this.title};var _5=isc.addProperties({},this.textFieldDefaults,_2.TEXT_FIELD,this.textFieldProperties);var _6={};if(this.$1188()){_6.textAlign=this.isRTL()?isc.Canvas.RIGHT:isc.Canvas.LEFT;_6.editorType=(this.$1189()?isc.NativeDateTimeItem:isc.NativeDateItem);_6.startDate=this.getStartDate(true);_6.endDate=this.getEndDate(true)}else if(this.useMask){var _7=this.getInputFormat();if(!_7)_7="MDY";var _8=this.getInputFormatMask(_7);_6.mask=_8;_6.maskSaveLiterals=true;if(_5.maskOverwriteMode==null)_5.maskOverwriteMode=true;if(this.inputFormat){this.dateFormatter=this.$73r[_7]}}
var _9=isc.addProperties({},_4,_5,_6);_9.name="dateTextField";if(this.textField){_9.height=this.textField.height}else if(this.height&&(!this.textFieldProperties||!this.textFieldProperties.height))
{_9.height=this.getInnerHeight()}
_1.add(_9);var _10;this.daySelector=this.yearSelector=this.monthSelector=_10}else{var _11=isc.SelectItem.getInstanceProperty("textBoxStyle"),_12=isc.SelectItem.getInstanceProperty("pickerIconWidth")+isc.Element.$tf(_11)+isc.Element.$tg(_11)+isc.Element.$yp(_11)+4;for(var i=0;i<_3.length;i++){var _14=_3.charAt(i);var _15,_16,_17,_18=null;if(_14=="D"){var _15;if(this.daySelectorProperties!=null){_15=isc.addProperties({},this.daySelectorDefaults,_2.DAY_SELECTOR,this.daySelectorProperties)}else{_15=isc.addProperties({},this.daySelectorDefaults,_2.DAY_SELECTOR)}
if(!_15.width){if(this.$1770==null){var _19=this.getDayOptions().join("<br>");this.$1770=isc.Canvas.measureContent(_19,_15.styleName||_11)+_12}
_15.width=this.$1770;_15.minWidth=this.$1770}
_15.name="daySelector";_18=_15;_1.add(_15)}else if(_14=="M"){var _16;if(this.monthSelectorProperties!=null){_16=isc.addProperties({},this.monthSelectorDefaults,_2.MONTH_SELECTOR,this.monthSelectorProperties)}else{_16=isc.addProperties({},this.monthSelectorDefaults,_2.MONTH_SELECTOR)}
if(!_16.width){if(this.$1771==null){var _19=isc.getValues(this.getMonthOptions()).join("<br>");this.$1771=isc.Canvas.measureContent(_19,_16.styleName||_11)+_12}
_16.width=this.$1771;_16.minWidth=this.$1771}
_16.name="monthSelector";_18=_16;_1.add(_16)}else if(_14=="Y"){var _17;if(this.yearSelectorProperties!=null){_17=isc.addProperties({},this.yearSelectorDefaults,_2.YEAR_SELECTOR,this.yearSelectorProperties)}else{_17=isc.addProperties({},this.yearSelectorDefaults,_2.YEAR_SELECTOR)}
if(!_17.width){if(this.$1772==null){var _19=this.getYearOptions().join("<br>");this.$1772=isc.Canvas.measureContent(_19,_17.styleName||_11)+_12}
_17.width=this.$1772;_17.minWidth=this.$1772}
_17.name="yearSelector";_18=_17;_1.add(_17)}
if(i>0&&_18){if(_18.cssText==null){_18.cssText="padding-left:3px;"}}}}
this.Super("setItems",[_1],arguments);if(this.$161p())this.$1609();if(this.useTextField){this.textField=this.dateTextField}},isc.A.subItemHoverHTML=function isc_DateItem_subItemHoverHTML(_1,_2){if(this.itemHoverHTML){return this.itemHoverHTML(this,_2)}
return _2.itemHoverHTML(_1)},isc.A.getInnerWidth=function isc_DateItem_getInnerWidth(){if(this.useTextField){return this.Super("getInnerWidth",arguments)}
var _1=0,_2=0;if(this.daySelector){_2+=1;_1+=this.daySelector.width}
if(this.monthSelector){_2+=1;_1+=this.monthSelector.width}
if(this.yearSelector){_2+=1;_1+=this.yearSelector.width}
if(this.showPickerIcon)_1+=this.getPickerIconWidth();if(_2>0)_1+=(_2-1)*this.selectorPadding;return _1},isc.A.isEditable=function isc_DateItem_isEditable(){return true},isc.A.getEnteredValue=function isc_DateItem_getEnteredValue(){if(this.useTextField&&this.textField!=null){return this.textField.getEnteredValue()}
return this.getValue()},isc.A.setElementReadOnly=function isc_DateItem_setElementReadOnly(_1){},isc.A.setValue=function isc_DateItem_setValue(_1){this.$17g=true;var _2=false;if(_1==null){var _3=this.getDefaultValue();var _4;if(_3!==_4){_1=_3;_2=true}}
var _5=isc.isA.Date(_1)&&isc.isA.Date(this._value)?(this.useLogicalDates()?isc.DateUtil.compareLogicalDates(_1,this._value)==0:isc.DateUtil.compareDates(_1,this._value)==0):_1==this._value;var _6,_7;if(isc.is.emptyString(_1))_1=null;if(_1==null){_7=true;_6=_1;if(this.$119h)delete this.$119h}else{_6=this.parseDate(_1);if(_6==null){_7=true;_6=_1}}
if(_7){var _8;if(!this.useTextField){_8=true}else if(this.enforceDate&&_1!=null){var _9=this.dateTextField;_8=!this.$20m||!_9||(_9.getValue()!=_1)}
if(_8){this.logInfo("dateItem.setValue(): invalid date passed: '"+_1+"'.  Ignoring this value. Non date values are only supported  for dateItems where useTextField is true and enforceDate is false.");return false}}
if(!_7&&this.$20m){delete this.$20m;this.clearErrors();this.redraw()}
this.saveValue(_6,_2);this.$20l=true;if(this.useTextField){if(this.dateTextField){if(_5&&this.dateTextField.isDirty){this.dateTextField.setValue(this.dateTextField._value)}else{var _10=_7?_6:this.formatDate(_6);this.dateTextField.setValue(_10);delete this.dateTextField.isDirty}}}else{if(this.daySelector!=null)this.daySelector.setValue(_6.getDate());if(this.monthSelector!=null)this.monthSelector.setValue(_6.getMonth());if(this.yearSelector!=null)this.yearSelector.setValue(_6.getFullYear())}
delete this.$20l;if(this.$161p())this.$1609();return true},isc.A.$17e=function isc_DateItem__setHiddenDataElementValue(_1){var _2=this.$15b();if(_2!=null){if(isc.isA.Date(_1))_2.value=_1.toDBDate();else _2.value=_1}},isc.A.getCellHeight=function isc_DateItem_getCellHeight(){var _1=this.Super("getCellHeight",arguments);if(isc.Browser.isIE&&this.useTextField&&isc.isA.Number(_1))_1+=2;return _1},isc.A.elementChanged=function isc_DateItem_elementChanged(){return},isc.A.getCriteriaValue=function isc_DateItem_getCriteriaValue(){return this.parseDate(this.getValue())},isc.A.updateValue=function isc_DateItem_updateValue(){if(this.$20l)return;this.$20l=true;var _1;if(this.useTextField){this.dateTextField.updateValue();var _2=this.dateTextField.getValue(),_3=this.$1188(),_4;var _5=_2;if(_2==isc.emptyString||_2==null)_1=null;else if(_3){_1=_2;_5=this.formatDate(_2)}else{_1=this.parseDate(_2);if(_1==null){_4=true;_1=_2}else{_5=this.formatDate(_1);if(_2!=_5){this.dateTextField.setValue(_5)}}}
if(this._value==_1||(isc.isA.Date(this._value)&&(this.formatDate(this._value)==_5)))
{delete this.$20l;return}
if(!_3&&this.enforceDate){if(this.$20m&&!_4){delete this.$20m;this.clearErrors();this.redraw()}else if(_4){this.logWarn("Invalid date string entered in date text field :"+_1);if(!this.$20m){this.$20m=true;this.setError(this.invalidDateStringMessage);this.redraw()}}}}else{_1=(this._value||this.getDefaultValue());_1=_1.duplicate();var _6=_1.getDate(),_7=this.daySelector,_8=_1.getMonth(),_9=this.monthSelector,_10=_1.getFullYear(),_11=this.yearSelector;if(_7!=null){_6=this.daySelector.getValue();if(_6==null)_6=_1.getDate()}
_1.setDate(1);if(_11!=null){_10=_11.getValue()
if(_10!=null)_1.setFullYear(_10);else _10=_1.getFullYear()}
if(_9!=null){_8=_9.getValue();if(_8!=null)_1.setMonth(_8);else _8=_1.getMonth()}
_1.setDate(_6);if(_8!=_1.getMonth()){_6=_6-_1.getDate();if(_7!=null)_7.setValue(_6);_1.setMonth(_8);_1.setDate(_6)}
if(isc.SimpleType.inheritsFrom(this.type,"datetime")){var _12=this.$119h?this.$119h:isc.isA.Date(this._value)?this._value:null;if(_12){var _13=isc.DateUtil.getLogicalTimeOnly(_12);_1=isc.DateUtil.combineLogicalDateAndTime(_1,_13)}}}
delete this.$20l;return this.storeValue(_1)},isc.A.saveValue=function isc_DateItem_saveValue(_1){if(isc.isA.Date(_1)&&_1.logicalDate==null&&_1.logicalTime==null){if(this.useLogicalDates())_1.logicalDate=true}
var _2=this.Super("saveValue",arguments);if(this.$161p())this.$1609();return _2},isc.A.resetValue=function isc_DateItem_resetValue(){var _1=this.form.$10s[this.getFieldName()];if(isc.isA.Date(_1)&&isc.isA.Date(this._value))
_1=this._value.setTime(_1.getTime());this.setValue(_1)},isc.A.getItemValue=function isc_DateItem_getItemValue(_1,_2){if(isc.isAn.emptyObject(_2))_2=null;var _3=isc.isA.Date(_2),_4=isc.isA.Date(this._value);if(_2==this._value||(_3&&_4&&(isc.DateUtil.compareDates(_2,this._value)==0)))
{return _1.getValue()}
if(_1==this.dateTextField)return _3?this.formatDate(_2):_2;else if(_1==this.daySelector)return _3?_2.getDate():null;else if(_1==this.monthSelector)return _3?_2.getMonth():null;else if(_1==this.yearSelector)return _3?_2.getFullYear():null},isc.A.getDisplayValue=function isc_DateItem_getDisplayValue(){var _1=this.getValue();if(!isc.isA.Date(_1))return this.Super("getDisplayValue",arguments);if(this.useTextField||!this.items){return this.formatDate(_1)}else{if(!this.isDrawn()){if(this.yearSelector)this.yearSelector.setValue(_1.getFullYear());if(this.monthSelector)this.monthSelector.setValue(_1.getMonth());if(this.daySelector)this.daySelector.setValue(_1.getDate())}
return this.items.callMethod("getDisplayValue").join(" ")}},isc.A.getDefaultValue=function isc_DateItem_getDefaultValue(){var _1=this.Super("getDefaultValue");if(!isc.isA.Date(_1)){var _2=this.parseDate(_1);if(isc.isA.Date(_2))_1=_2;else if(!this.useTextField||this.enforceDate){var _3;if(_1!=null){this.logWarn("Default DateItem value provided as:"+_1+". This is not recognized as a valid date - defaulting to a new date");_3=this.defaultValue==_1}
if(!this.useTextField)_1=this.$603();if(_3)this.defaultValue=_1}}
return _1},isc.A.$603=function isc_DateItem__getEmptyDate(){var _1=isc.DateUtil.createLogicalDate();return _1},isc.A.useLogicalDates=function isc_DateItem_useLogicalDates(){var _1=this.getType(),_2=isc.SimpleType.inheritsFrom(_1,"date"),_3=isc.SimpleType.inheritsFrom(_1,"datetime");return _1!=null&&_2&&!_3},isc.A.getStartDate=function isc_DateItem_getStartDate(_1){var _2=this.startDate;if(isc.isA.String(_2))_2=this.parseDate(this.startDate);if((_2==null&&!_1)||!isc.isA.Date(_2)){if(_2!=null){this.logWarn("startDate was not in valid date format - using default start date")}
_2=isc.DateItem.DEFAULT_START_DATE}
return _2},isc.A.setStartDate=function isc_DateItem_setStartDate(_1){this.startDate=_1;var _2=this.dateTextField;if(_2&&this.$1188()){_1=this.getStartDate(true);_2.startDate=_1;var _3=_2.getDataElement();if(_1==null)_3.removeAttribute("min");else{_3.min=_2.mapValueToDisplay(_1)}}
this.updateValue()},isc.A.getEndDate=function isc_DateItem_getEndDate(_1){var _2=this.endDate;if(isc.isA.String(_2))_2=this.parseDate(this.endDate);if((_2==null&&!_1)||!isc.isA.Date(_2)){if(_2!=null){this.logWarn("endDate was not in valid date format - using default end date")}
_2=isc.DateItem.DEFAULT_END_DATE}
return _2},isc.A.setEndDate=function isc_DateItem_setEndDate(_1){this.endDate=_1;var _2=this.dateTextField;if(_2&&this.$1188()){_1=this.getEndDate(true);_2.endDate=_1;var _3=_2.getDataElement();if(_1==null)_3.removeAttribute("max");else{_3.max=_2.mapValueToDisplay(_1)}}
this.updateValue()},isc.A.$kk=function isc_DateItem__canFocus(){if(this.canFocus!=null)return this.canFocus;return true},isc.A.focusInItem=function isc_DateItem_focusInItem(){if(!this.isVisible())return;if(this.useTextField){if(this.dateTextField)this.dateTextField.focusInItem()}else{var _1=this.getSelectorFormat(),_2=_1.charAt(0);if(_2=="D"&&this.daySelector)this.daySelector.focusInItem();if(_2=="M"&&this.monthSelector)this.monthSelector.focusInItem();if(_2=="Y"&&this.yearSelector)this.yearSelector.focusInItem()}},isc.A.setSelectionRange=function isc_DateItem_setSelectionRange(_1,_2){if(this.dateTextField)return this.dateTextField.setSelectionRange(_1,_2)},isc.A.getSelectionRange=function isc_DateItem_getSelectionRange(){if(this.dateTextField)return this.dateTextField.getSelectionRange()},isc.A.selectValue=function isc_DateItem_selectValue(){if(this.dateTextField)return this.dateTextField.selectValue()},isc.A.deselectValue=function isc_DateItem_deselectValue(_1){if(this.dateTextField)return this.dateTextField.deselectValue()},isc.A.getDayOptions=function isc_DateItem_getDayOptions(){var _1=this.getStartDate(),_2=this.getEndDate();var _3=1,_4=31;if(_1.getYear()==_2.getYear()&&_1.getMonth()==_2.getMonth())
{_3=_1.getDate()
_4=_2.getDate()}
var _5="day."+_3+"."+_4;if(isc.DateItem.mapCache[_5])return isc.DateItem.mapCache[_5];var _6=isc.DateItem.mapCache[_5]=[];for(var i=_3;i<=_4;i++)_6[i-_3]=i;return _6},isc.A.getMonthOptions=function isc_DateItem_getMonthOptions(){var _1=this.getStartDate(),_2=this.getEndDate();var _3=0,_4=11;if(_1.getYear()==_2.getYear()){_3=_1.getMonth()
_4=_2.getMonth()}
var _5="month."+_3+"."+_4;if(isc.DateItem.mapCache[_5])return isc.DateItem.mapCache[_5];var _6=isc.DateItem.mapCache[_5]={};var _7=isc.DateUtil.getShortMonthNames();for(;_3<=_4;_3++){_6[_3]=_7[_3]}
return _6},isc.A.getYearOptions=function isc_DateItem_getYearOptions(){var _1=this.getStartDate().getFullYear(),_2=this.getEndDate().getFullYear();var _3="year."+_1+"."+_2;if(isc.DateItem.mapCache[_3])return isc.DateItem.mapCache[_3];var _4=isc.DateItem.mapCache[_3]=[];for(var i=_1;i<=_2;i++){_4[i-_1]=i}
return _4},isc.A.parseDate=function isc_DateItem_parseDate(_1,_2){if(isc.isA.Date(_1))return _1;if(this.parseEditorValue!=null){var _3=this.parseEditorValue(_1,this.form,this);return _3}
if(_2==null)_2=this.getInputFormat();var _4=this.useLogicalDates();var _5=isc.DateUtil.parseInput(_1,_2,this.centuryThreshold,true,!_4);return _5},isc.A.formatDate=function isc_DateItem_formatDate(_1){if(this.formatEditorValue!=null){var _2=this.form?this.form.values:{};return this.formatEditorValue(_1,_2,this.form,this)}
if(!isc.isA.Date(_1))return _1;if(this.format&&!this.getCanEdit()){return isc.DateUtil.format(_1,this.format)}
var _3=this.$45i(),_4=this.getType(),_5=isc.SimpleType.inheritsFrom(_4,"date"),_6=isc.SimpleType.inheritsFrom(_4,"datetime");if(this.showTime){if(this.$180y()&&!_3){var _7=this.timeFormatter||"toShortPaddedTime";var _8=_1.toShortDate()+" "+isc.Time.format(_1,_7);return _8}
return _1.toShortDatetime(_3,_6||!_5)}else{return _1.toShortDate(_3,_6||!_5)}},isc.A.getInputFormat=function isc_DateItem_getInputFormat(){if(this.inputFormat)return this.inputFormat;var _1=this.$45i();return isc.DateUtil.mapDisplayFormatToInputFormat(_1)},isc.A.getPickerIcon=function isc_DateItem_getPickerIcon(_1,_2,_3,_4){var _5=this.invokeSuper(isc.DateItem,"getPickerIcon",_1,_2,_3,_4);if(_5.prompt==null)_5.prompt=this.pickerIconPrompt;return _5},isc.A.getFiscalCalendar=function isc_DateItem_getFiscalCalendar(){return this.fiscalCalendar||isc.DateUtil.getFiscalCalendar()},isc.A.setFiscalCalendar=function isc_DateItem_setFiscalCalendar(_1){this.fiscalCalendar=_1},isc.A.showPicker=function isc_DateItem_showPicker(){if(isc[this.pickerConstructor]==null){this.logWarn("Date Item pickerConstructor class '"+this.pickerConstructor+"' is not loaded. This property may have been modified incorrectly  or a required module may not be loaded. Refusing to show picker.");return}
if(!this.form.$10u)this.updateValue();var _1={};if(isc.Browser.isHandset){_1.width=isc.Page.getWidth();_1.height=isc.Page.getHeight();_1.left=0;_1.top=0}
var _2=isc.addProperties({},this.pickerDefaults,_1,this.pickerProperties);var _3=this.shouldShowPickerTimeItem();if(!this.picker){if(this.useSharedPicker){var _4=isc.addProperties({},{fiscalCalendar:this.getFiscalCalendar(),showFiscalYearChooser:this.showChooserFiscalYearPicker,showWeekChooser:this.showChooserWeekPicker,showTimeItem:_3,use24HourTime:this.use24HourTime},_2);this.picker=isc[this.pickerConstructor].getSharedDateChooser(_4)}else{this.picker=isc[this.pickerConstructor].create(isc.addProperties({},_2,{border:"none",_generated:true,autoHide:true,showCancelButton:true,closeOnEscapeKeypress:true}))}
if(!this.picker.isDrawn()){this.picker.moveTo(null,-9999);this.picker.draw()}}else{if(isc.getKeys(_2).length>0){this.picker.setProperties(_2)}}
var _5=this.picker;var _6=_5.callingFormItem;if(_6!=this){if(_6)_6.ignore(_5,"dataChanged");this.observe(_5,"dataChanged","observer.pickerDataChanged(observed)");_5.callingFormItem=this;_5.callingForm=this.form;_5.locatorParent=this.form}
_5.startYear=this.getStartDate().getFullYear();_5.endYear=this.getEndDate().getFullYear();_5.fiscalCalendar=this.getFiscalCalendar();_5.showFiscalYearChooser=this.showChooserFiscalYearPicker;_5.showWeekChooser=this.showChooserWeekPicker;_5.showTimeItem=_3;_5.use24HourTime=this.use24HourTime;if(this.pickerTimeItemProperties)_5.timeItemProperties=this.pickerTimeItemProperties;if(this.shouldShowPickerTimeItem()&&this.picker.timeLayout.visibility==isc.Canvas.HIDDEN){this.picker.timeLayout.show();_5.reflowNow()}else{_5.reflowNow();if(!this.shouldShowPickerTimeItem()&&this.picker.timeLayout.visibility!=isc.Canvas.HIDDEN)
this.picker.timeLayout.hide()}
var _7=this.Super("showPicker",arguments);if(_5.updateUI)_5.updateUI();return _7},isc.A.shouldShowPickerTimeItem=function isc_DateItem_shouldShowPickerTimeItem(){if(this.showPickerTimeItem==false)return false;return isc.SimpleType.inheritsFrom(this.type,"datetime")},isc.A.getPickerRect=function isc_DateItem_getPickerRect(){var _1=this.getPageLeft(),_2=this.getPageTop(),_3=isc.DateItem.getChooserWidth()+3,_4=isc.DateItem.getChooserHeight()+3;_1+=Math.round((this.getVisibleWidth()-(this.getPickerIconWidth()/2))-
(_3/2));_2+=Math.round((this.getPickerIconHeight()/2)-(_4/2));return[_1,_2]},isc.A.pickerDataChanged=function isc_DateItem_pickerDataChanged(_1){var _2=_1.getData(),_3=isc.DateUtil.getLogicalDateOnly(_2),_4=_3.getFullYear(),_5=_3.getMonth(),_6=_3.getDate(),_7=_2.getTime();var _8=this.useLogicalDates();if(!_8){}
this.$20l=true;if(this.useTextField){var _9=this.formatDate(_2);this.dateTextField.setValue(_9)}else{var _10=this._value||this.getDefaultValue(),_11;if(this.yearSelector)this.yearSelector.setValue(_4);else{_10.setFullYear(_4);_11=true}
if(this.monthSelector)this.monthSelector.setValue(_5);else{_10.setMonth(_5-1);_11=true}
if(this.daySelector)this.daySelector.setValue(_6);else{_10.setDate(_6);_11=true}
if(isc.SimpleType.inheritsFrom(this.type,"datetime")){var _12=isc.DateUtil.getLogicalTimeOnly(_2);this.$119h=_12}
if(_11){this._value=_10}}
this.$20l=false;this.updateValue();if(!this.hasFocus)this.focusInItem();var _13=this.getErrors();if(_13&&_13.length>0)this.validate();if(this.validateOnExit||(this.form&&this.form.validateOnExit)){this.$84r=true}},isc.A.setHint=function isc_DateItem_setHint(_1){if(this.useTextField&&this.$712()){this.dateTextField.setHint(_1)}else{this.Super("setHint",arguments)}},isc.A.getPickerData=function isc_DateItem_getPickerData(){var _1=this.getValue();if(_1!=null){if(!isc.isA.Date(_1)){if(isc.isA.String(_1))_1=this.parseDate(_1);else _1=new Date(_1)}
if(isc.isA.Date(_1)&&!isNaN(_1.getTime()))return _1}
return this.getDefaultChooserDate()},isc.A.getDefaultChooserDate=function isc_DateItem_getDefaultChooserDate(){return this.defaultChooserDate},isc.A.$85m=function isc_DateItem__shouldAllowExpressions(){if(this.useTextField){return this.Super("$85m",arguments)}else{return false}},isc.A.propertyChanged=function isc_DateItem_propertyChanged(_1){if(_1=="useTextField"||_1=="useMask"){this.setItems()}
this.Super("propertyChanged",arguments)});isc.B._maxIndex=isc.C+58}
if(isc.ListGrid){isc.defineClass("DateTimeItem","DateItem");isc.A=isc.DateTimeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.useTextField=true;isc.A.showTime=true;isc.A.defaultType="datetime";isc.B.push(isc.A.shouldShowPickerTimeItem=function isc_DateTimeItem_shouldShowPickerTimeItem(){return this.showPickerTimeItem});isc.B._maxIndex=isc.C+1}
isc.ClassFactory.defineClass("SpacerItem","FormItem");isc.A=isc.SpacerItem.getPrototype();isc.A.shouldSaveValue=false;isc.A.showTitle=false;isc.A.width=20;isc.A.height=20;isc.A.showHint=false;isc.A.showIcons=false;isc.A=isc.SpacerItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.isEditable=function isc_SpacerItem_isEditable(){return false},isc.A.getElementHTML=function isc_SpacerItem_getElementHTML(_1){return isc.Canvas.spacerHTML(this.width,this.height)},isc.A.shouldShowTitle=function isc_SpacerItem_shouldShowTitle(){return false});isc.B._maxIndex=isc.C+3;isc.ClassFactory.defineClass("RowSpacerItem","SpacerItem");isc.A=isc.RowSpacerItem.getPrototype();isc.A.showTitle=false;isc.A.colSpan="*";isc.A.startRow=true;isc.A.endRow=true;isc.A.width=20;isc.A.height=20;isc.ClassFactory.defineClass("SubmitItem","ButtonItem");isc.A=isc.SubmitItem.getPrototype();isc.A.title="Submit";isc.A=isc.SubmitItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.handleClick=function isc_SubmitItem_handleClick(){if(this.Super("handleClick",arguments)==false)return false;this.form.submit();this.form.completeEditing()});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("CancelItem","ButtonItem");isc.A=isc.CancelItem.getPrototype();isc.A.title="Cancel";isc.A=isc.CancelItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.handleClick=function isc_CancelItem_handleClick(){if(this.Super("handleClick",arguments)==false)return false;this.form.cancelEditing()});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("TextAreaItem","FormItem");isc.A=isc.TextAreaItem;isc.A.OFF="OFF";isc.A.SOFT="SOFT";isc.A.VIRTUAL="SOFT";isc.A.ON="HARD";isc.A.HARD="HARD";isc.A.PHYSICAL="HARD";isc.A=isc.TextAreaItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.wrap=isc.TextAreaItem.VIRTUAL;isc.A.width=150;isc.A.height=100;isc.A.staticHeight=1;isc.A.textBoxStyle="textItem";isc.A.length=null;isc.A.enforceLength=false;isc.A.redrawOnShowIcon=false;isc.A.clipValue=true;isc.A.$125=true;isc.A.$15i=true;isc.A.emptyStringValue=null;isc.A.lineBreakValue="\n";isc.A.iconVAlign=isc.Canvas.TOP;isc.A.$16b={onmousedown:(isc.Browser.isIE?function(){var _1=this,_2=isc.DynamicForm._getItemInfoFromElement(_1),_3=_2.item;if(_3)_3.$179()}:null)};isc.A.supportsCutPasteEvents=true;isc.A.supportsSelectionRange=true;isc.A.usePlaceholderForHint=true;isc.A.printFullText=true;isc.A.showClippedValueOnHover=false;isc.B.push(isc.A.getEnteredValue=function isc_TextAreaItem_getEnteredValue(){return this.getElementValue()});isc.B._maxIndex=isc.C+1;isc.A=isc.TextAreaItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.escapeHTML=true;isc.A.allowNativeResize=false;isc.A.minHeight=16;isc.A.supportsMultilineEntry=true;isc.A.applyStaticTypeFormat=false;isc.A.stopNavKeyPressBubbling=true;isc.A.stopCharacterKeyPressBubbling=true;isc.A.$145f="Page_Up";isc.A.$145g="Page_Down";isc.A.$10j="Enter";isc.B.push(isc.A.$712=function isc_TextAreaItem__getShowHintInField(){return!!(this.showHint&&this.getHint()&&this.showHintInField)},isc.A.$1564=function isc_TextAreaItem__getUsePlaceholderForHint(){if(!this.usePlaceholderForHint)return false;return this.$1560()},isc.A.$1560=function isc_TextAreaItem__supportsPlaceholderAttribute(){return isc.Browser.$1560},isc.A.getTextBoxCellCSS=function isc_TextAreaItem_getTextBoxCellCSS(){return this.$136},isc.A.$143=function isc_TextAreaItem__sizeTextBoxAsContentBox(){return isc.Browser.isStrict},isc.A.$145l=function isc_TextAreaItem__needHideUsingDisplayNone(){return isc.Browser.isTouch},isc.A.$429=function isc_TextAreaItem__willHandleInput(){return!isc.Browser.isIE},isc.A.setElementReadOnly=function isc_TextAreaItem_setElementReadOnly(_1){this.$86y(_1)},isc.A.getCanEscapeHTML=function isc_TextAreaItem_getCanEscapeHTML(){if((this.$68y()&&this.printFullText)||this.renderAsStatic()){return true}
return this.canEscapeHTML},isc.A.$1618=function isc_TextAreaItem__getClipValue(){if(this.$68y()&&this.printFullText)return false;return this.Super("$1618",arguments)},isc.A.getElementHTML=function isc_TextAreaItem_getElementHTML(_1,_2){var _3=this.form,_4=_3.getID(),_5=this.getItemID(),_6=isc.StringBuffer.create(),_7=this.$xq(_2);if(_7!=null)_6.append(_7);if(!this.showValueIconOnly){var _8=this.$68y(),_9=(_8&&this.printFullText)||this.renderAsStatic();if(_9){var _10=this.Super("getElementHTML",[_1.asHTML(),_2],arguments);return _10}else{_6.append("<TEXTAREA NAME=",this.getElementName()," ID=",this.getDataElementId(),this.$155(),this.getElementStyleHTML(_2),(this.renderAsDisabled()?" DISABLED ":""),(this.$17h()!="native"?" AUTOCOMPLETE=OFF ":""),(this.$712()&&this.$1564()?" placeholder='"+String.asAttValue(String.htmlStringToString(this.getHint()))+"'":null),((isc.Browser.isMoz||isc.Browser.isSafari)?(this.getBrowserSpellCheck()?" spellcheck=true":" spellcheck=false"):null),(isc.Browser.isSafari&&this.browserAutoCapitalize==false?" autocapitalize='off'":null),(isc.Browser.isSafari&&this.browserAutoCorrect!=null?(this.browserAutoCorrect?" autocorrect='on'":" autocorrect='off'"):null)," WRAP=",this.wrap," TABINDEX=",this.$154(),(this.showTitle==false&&this.accessKey!=null?" ACCESSKEY="+this.accessKey:""),(this.$429()?" ONINPUT='"+this.getID()+"._handleInput()'":null),(this.isReadOnly()||this.isInactiveHTML()?(isc.Canvas.ariaEnabled()?" aria-readonly='true' READONLY=TRUE":" READONLY=TRUE"):null)," handleNativeEvents=false>",(this.isInactiveHTML()?_1:null),"</TEXTAREA>")}}
return _6.release(false)},isc.A.handleMouseMove=function isc_TextAreaItem_handleMouseMove(){var _1=this.Super("handleMouseMove",arguments);if(_1==false||!this.allowNativeResize)return false;if(isc.EH.mouseIsDown()&&this.$90g==null){this.$90g=isc.Page.setEvent("idle",this.getID()+".$90h()")}},isc.A.$90h=function isc_TextAreaItem__checkForElementResize(){var _1=false;var _2=this.getDataElement();if(_2){var _3=this.getValue();if(_2.offsetWidth!=this.getTextBoxWidth(_3))_1=true;if(_2.offsetHeight!=this.getTextBoxHeight(_3))_1=true}
if(_1)this.$90i();if(!isc.EH.mouseIsDown()){isc.Page.clearEvent("idle",this.$90g);this.$90g=null}},isc.A.$90i=function isc_TextAreaItem__nativeElementResize(){var _1=this.containerWidget;if(_1)_1.$t6("Native textarea resize")},isc.A.$12v=function isc_TextAreaItem__nativeElementFocus(_1,_2){var _3=this.Super("$12v",arguments);this.$66s();this.$84f=this.getEnteredValue();return _3},isc.A.$12x=function isc_TextAreaItem__nativeElementBlur(_1,_2){this.form.elementChanged(this);var _3=this.Super("$12x",arguments);if(this.$84f==null||this.$84f!=this.getEnteredValue())
{var _4=this.getValue();if(this.mapValueToDisplay){_4=this.mapValueToDisplay(_4)}
this.setElementValue(_4)}
if(this.$712()&&!this.$1564()){var _4=this.getElementValue();if(_4==null||isc.isAn.emptyString(_4)){this.$66t()}}
return _3},isc.A.getElementStyleHTML=function isc_TextAreaItem_getElementStyleHTML(_1){var _2=this.getTextBoxWidth(_1),_3=this.getTextBoxHeight(_1);return isc.StringBuffer.concat(" CLASS='"+this.getTextBoxStyle(),(isc.Browser.isMoz&&isc.isA.String(this.wrap)&&this.wrap.toLowerCase()!="off"?"' ROWS=10 COLS=10":"'")," STYLE='",this.getElementCSSText(_2,_3),"' ")},isc.A.getElementCSSText=function isc_TextAreaItem_getElementCSSText(_1,_2){if(isc.isA.Number(_1)&&_1<=0)_1=1;if(isc.isA.Number(_2)&&_2<this.minHeight)_2=this.minHeight;return isc.StringBuffer.concat(this.allowNativeResize?null:"resize:none;",(isc.TextItem.$126z?"margin-top:-1px;margin-bottom:-1px;margin-left:0px;margin-right:0px;":"margin:0px;"),(isc.isA.Number(_1)?"WIDTH:"+_1+"px;":""),(isc.isA.Number(_2)?"HEIGHT:"+_2+"px;":""),(this.textAlign?"text-align:"+this.textAlign+";":""),(isc.Browser.isChrome?"display:block;":""),this.wrap&&this.wrap.toUpperCase()==isc.TextAreaItem.OFF?"white-space:pre;":"white-space:pre-wrap;",(isc.Browser.isMoz?"-moz-user-focus:"+(this.$154()>0?"normal;":"ignore;"):""))},isc.A.getStandaloneItemWrapCSS=function isc_TextAreaItem_getStandaloneItemWrapCSS(){if(isc.Browser.isIE)return null;return this.Super("getStandaloneItemWrapCSS",arguments)},isc.A.$187i=function isc_TextAreaItem__cellNoWrap(){return true},isc.A.mapValueToDisplay=function isc_TextAreaItem_mapValueToDisplay(_1,_2,_3,_4,_5){var _6=this.invokeSuper(isc.TextAreaItem,"mapValueToDisplay",_1,_2,_3,_4,_5);if(_6==null)_6=isc.emptyString;return _6},isc.A.mapDisplayToValue=function isc_TextAreaItem_mapDisplayToValue(_1){var _2=this.$79d(_1);_2=this.$17d(_2);if(isc.is.emptyString(_2))_2=this.emptyStringValue;return _2},isc.A.setValue=function isc_TextAreaItem_setValue(_1){this.$66s();var _2;if(this.emptyStringValue===null||this.emptyStringValue===_2){if(_1==null||isc.is.emptyString(_1)){this.emptyStringValue=_1}}
delete this.$20n;_1=this.Super("setValue",arguments);if(!this.hasFocus&&this.$712()&&!this.$1564()){if(_1==null||isc.isAn.emptyString(_1)){this.$66t()}}
return _1},isc.A.updateValue=function isc_TextAreaItem_updateValue(){this.$20n=true;return this.Super("updateValue",arguments)},isc.A.compareValues=function isc_TextAreaItem_compareValues(_1,_2){if(_1==null&&_2==null)return true;else if(_1==null||_2==null)return false;if(isc.isA.String(_2)){if(isc.isA.Number(_1)||isc.isA.SpecialNumber(_1)){return String(_1)==_2}}else if(isc.isA.String(_1)){if(isc.isA.Number(_2)||isc.isA.SpecialNumber(_2)){return _1==String(_2)}}
return this.Super("compareValues",arguments)},isc.A.getValue=function isc_TextAreaItem_getValue(){var _1=this.Super("getValue",arguments);if(this.$20n&&isc.isA.String(_1)){if(!this.$20o)
this.$20o=new RegExp("(\\r\\n|[\\r\\n])","g");_1=""+_1;_1=_1.replace(this.$20o,this.lineBreakValue)}
return _1},isc.A.shouldStopKeyPressBubbling=function isc_TextAreaItem_shouldStopKeyPressBubbling(_1,_2){if(_1==this.$10j)return true;if(_1==this.$145f)return this.getScrollTop()!=0;if(_1==this.$145g){var _3=this.$15h();if(_3){return(_3.scrollHeight-_3.clientHeight)>this.getScrollTop()}}
return this.Super("shouldStopKeyPressBubbling",arguments)},isc.A.getScrollHeight=function isc_TextAreaItem_getScrollHeight(){var _1=this.$15h();if(_1==null)return this.getHeight();return _1.scrollHeight},isc.A.getScrollWidth=function isc_TextAreaItem_getScrollWidth(){var _1=this.$15h();if(_1==null)return this.getWidth();return _1.scrollWidth},isc.A.$20p=function isc_TextAreaItem__hscrollOn(){var _1=this.$15h();return _1&&_1.scrollWidth>_1.clientWidth},isc.A.$20q=function isc_TextAreaItem__vscrollOn(){var _1=this.$15h();return _1&&_1.scrollHeight>_1.clientHeight},isc.A.getScrollTop=function isc_TextAreaItem_getScrollTop(){var _1=this.$15h();if(_1==null)return 0;return _1.scrollTop},isc.A.getScrollLeft=function isc_TextAreaItem_getScrollLeft(){var _1=this.$15h();if(_1==null)return 0;return _1.scrollLeft},isc.A.scrollTo=function isc_TextAreaItem_scrollTo(_1,_2){var _3=this.$15h();if(_3==null)return;if(_1!=null)_3.scrollLeft=_1;if(_2!=null)_3.scrollTop=_2},isc.A.scrollToTop=function isc_TextAreaItem_scrollToTop(){this.scrollTo(null,0)},isc.A.scrollToBottom=function isc_TextAreaItem_scrollToBottom(){var _1=this.getScrollBottom();if(_1>=0){this.scrollTo(null,_1)}},isc.A.getScrollBottom=function isc_TextAreaItem_getScrollBottom(){var _1=this.$15h();if(_1==null)return 0;return _1.scrollHeight-_1.clientHeight},isc.A.$178s=function isc_TextAreaItem__stopBubblingMouseWheelEvent(_1,_2){var _3=this.$142q,_4=false;if(_3&&this.$20q()){if(this.$178t==null){var _5=this.getScrollTop(),_6=isc.EH.getWheelDelta();if(_6==0){return true}
var _7=(_6<0)?(_5==0):(_5>=this.getScrollBottom());this.$178t=_7?"parent":"textbox"}
_4=(this.$178t=="textbox");isc.EH.fireOnPause("clearCurrentScrollTargetElement",{target:this,methodName:"clearCurrentScrollTargetElement"},200)}
return _4},isc.A.clearCurrentScrollTargetElement=function isc_TextAreaItem_clearCurrentScrollTargetElement(){delete this.$178t});isc.B._maxIndex=isc.C+39;isc.ClassFactory.defineClass("AutoFitTextAreaItem","TextAreaItem");isc.A=isc.AutoFitTextAreaItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.supportsSelectionRange=true;isc.B.push(isc.A.getTestBox=function isc_AutoFitTextAreaItem_getTestBox(_1){var _2=this.getValue();var _3=this.mapValueToDisplay(_2);var _4=isc.AutoFitTextAreaItem;if(!_4.$552){_4.$552=isc.Canvas.create({autoDraw:true,overflow:"hidden",left:0,top:-100,ariaState:{hidden:true},contents:["<textarea ID='isc_autoFitTextArea_sizeTester' role='presentation' ","style='overflow:hidden;",(isc.Browser.isIE?"margin-top:-1px;margin-bottom:-1px;margin-left:0px;margin-right:0px;":"margin:0px;"),"'></textarea>"].join("")})}
var _5=isc.Element.get("isc_autoFitTextArea_sizeTester");if(_4.currentItem!=this||_1){_5.className=this.getTextBoxStyle();if(isc.Browser.isMoz){if(isc.isA.String(this.wrap)&&this.wrap.toLowerCase()!="off"){_5.rows=5;_5.cols=10}else{_5.rows="";_5.cols=""}}
_5.setAttribute("wrap",this.wrap);var _6=this.getTextBoxWidth(_2),_7=this.getTextBoxHeight(_2);_4.$552.$u9(_5.style,"width",_6);_4.$552.$u9(_5.style,"height",_7);_5.style.textAlign=this.textAlign||"";_5.cssText=this.getElementCSSText(_6,_7);_4.currentItem=this}
_5.value=_3;var _8=_5.scrollHeight;return _5},isc.A.getScrollHeight=function isc_AutoFitTextAreaItem_getScrollHeight(_1){var _2=this.getTestBox(_1);return _2.scrollHeight},isc.A.getScrollWidth=function isc_AutoFitTextAreaItem_getScrollWidth(_1){var _2=this.getTestBox(_1);return _2.scrollWidth},isc.A.getElementCSSText=function isc_AutoFitTextAreaItem_getElementCSSText(_1,_2){var _3=this.Super("getElementCSSText",arguments);_3+="overflow:hidden;"
return _3},isc.A.$553=function isc_AutoFitTextAreaItem__getTextBoxHPadding(){if(this.$554!=null)return this.$554;var _1=this.getDataElement();if(!_1)return 0;var _2=parseInt(isc.Element.getComputedStyleAttribute(_1,"paddingLeft")),_3=parseInt(isc.Element.getComputedStyleAttribute(_1,"paddingRight")),_4=(isc.isA.Number(_2)?_2:0)+(isc.isA.Number(_3)?_3:0);this.$554=_4;return _4},isc.A.$555=function isc_AutoFitTextAreaItem__getTextBoxVPadding(){if(this.$556!=null)return this.$556;var _1=this.getDataElement();if(!_1)return 0;if(isc.Browser.isIE&&_1.currentStyle==null)return 0;var _2=parseInt(isc.Element.getComputedStyleAttribute(_1,"paddingTop")),_3=parseInt(isc.Element.getComputedStyleAttribute(_1,"paddingBottom")),_4=(isc.isA.Number(_2)?_2:0)+(isc.isA.Number(_3)?_3:0);this.$556=_4;return _4},isc.A.getMaxHeight=function isc_AutoFitTextAreaItem_getMaxHeight(){return this.maxHeight},isc.A.getMaxWidth=function isc_AutoFitTextAreaItem_getMaxWidth(){return this.maxWidth},isc.A.updateSize=function isc_AutoFitTextAreaItem_updateSize(_1){var _2=this.getDataElement();if(!_2)return;var _3,_4;var _5=this.getTextBoxHeight(),_6=this.$555(),_7=this.getScrollHeight(_1),_8=_2.offsetHeight-_6,_9=_7,_10=this.getMaxHeight();if(this.$143())_9-=_6;if(_10!=null&&_10<_9){_9=_10}
if(_9>_8){_2.style.height=""+_9+"px";_4=true}else if(_9<_8&&_8>_5){if(_9<_8){_3=true;_2.style.height=""+Math.max(_9,_5)+"px"}
_4=true}
var _11=this.getTextBoxWidth(this.getValue()),_12=isc.Browser.isIE?0:this.$553(),_13=this.getScrollWidth(_1),_14=_2.offsetWidth,_15=_12+_13,_16=this.getMaxWidth();if(_16!=null&&_15>_16)_15=_16;if(_15>_14){_2.style.width=_15;_4=true}else if(_15<_14&&_14>_11){_2.style.width=Math.max(_11,_15);_3=true
_4=true}
if(_3)this.containerWidget.$t5=true;if(_4)this.adjustOverflow("Updated size to fit content")},isc.A.handleChanged=function isc_AutoFitTextAreaItem_handleChanged(){this.updateSize();return this.Super("handleChanged",arguments)},isc.A.drawn=function isc_AutoFitTextAreaItem_drawn(){this.Super("drawn",arguments);delete this.$554;delete this.$556;this.updateSize(true)},isc.A.redrawn=function isc_AutoFitTextAreaItem_redrawn(){this.Super("redrawn",arguments);delete this.$554;delete this.$556;this.updateSize(true)},isc.A.$160=function isc_AutoFitTextAreaItem__resetWidths(){this.Super("$160",arguments);this.updateSize(true)},isc.A.setValue=function isc_AutoFitTextAreaItem_setValue(){this.Super("setValue",arguments);this.updateSize(true)});isc.B._maxIndex=isc.C+14;isc.defineClass("NativeTimeItem","TextItem");isc.A=isc.NativeTimeItem.getPrototype();isc.A.ariaRole="range";isc.A.browserInputType="time";isc.A.textBoxStyle="nativeTimeItem";isc.A.inFieldHintStyle="nativeTimeItemInFieldHint";isc.A.showClippedValueOnHover=false;isc.A=isc.NativeTimeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$118w="wrapper";isc.A.$118x="hint";isc.B.push(isc.A.getHint=function isc_NativeTimeItem_getHint(){if(this.hint!=null)return this.hint;if(isc.Browser.isChrome)return isc.TimeItem.getInstanceProperty("shortTimeFormat");return isc.TimeItem.getInstanceProperty("short24TimeFormat")},isc.A.$118y=function isc_NativeTimeItem__getWrapperElementId(){if(this.isInactiveHTML())return this.$qs(this.$118w);if(this.$118z==null){this.$118z=this.$qs(this.$118w,true)}
return this.$118z},isc.A.$1180=function isc_NativeTimeItem__getHintElementId(){if(this.isInactiveHTML())return this.$qs(this.$118x);if(this.$1181==null){this.$1181=this.$qs(this.$118x,true)}
return this.$1181},isc.A.$1182=function isc_NativeTimeItem__getInFieldHintElemStyle(){if(this.showDisabled&&this.renderAsDisabled())return this.inFieldHintStyle+"Disabled";return this.inFieldHintStyle},isc.A.getElementHTML=function isc_NativeTimeItem_getElementHTML(_1,_2){if(!this.$712())return this.Super("getElementHTML",arguments);var _3=this.getHeight();return"<div id='"+this.$118y()+"' class='"+this.$15x(this.$118w)+"' style='display:inline-block;position:relative;height:"+_3+"px'>"+this.Super("getElementHTML",arguments)+"<span id='"+this.$1180()+"' class='"+this.$1182()+"' style='line-height:"+_3+"px'></span></div>"},isc.A.getElementValue=function isc_NativeTimeItem_getElementValue(){var _1=this.getDataElement(),_2;if(!_1||!(_2=_1.value))return null;var h=parseInt(_2,10),m=parseInt(_2.substring(3),10),s=(_2.length>=8?parseInt(_2.substring(6),10):0);return isc.Time.createLogicalTime(h,m,s)},isc.A.setElementValue=function isc_NativeTimeItem_setElementValue(_1,_2){if(!this.isDrawn())return;var _3;if(_2===_3){_2=this._value}
var _4=this.getDataElement();if(_4!=null){_4.value=_1}},isc.A.mapValueToDisplay=function isc_NativeTimeItem_mapValueToDisplay(_1){if(isc.isA.Date(_1))return isc.Time.toShortTime(_1,"toTimestamp");return _1},isc.A.$66t=function isc_NativeTimeItem__showInFieldHint(){var _1=isc.Element.get(this.$1180());if(_1!=null){this.getDataElement().className=this.$66v();_1.className=this.$1182();var _2=this.getHint();_1.innerText=String.htmlStringToString(_2);this.$66u=true}},isc.A.$66s=function isc_NativeTimeItem__hideInFieldHint(_1){var _2=isc.Element.get(this.$1180());if(_2!=null){this.getDataElement().className=this.getTextBoxStyle();_2.className=this.$1182();_2.innerText=isc.emptyString;this.$66u=false}},isc.A.updateState=function isc_NativeTimeItem_updateState(){this.Super("updateState",arguments);if(this.$66u){var _1=isc.Element.get(this.$1180());if(_1!=null)_1.className=this.$1182()}});isc.B._maxIndex=isc.C+11;isc.ClassFactory.defineClass("TimeItem","ContainerItem");isc.A=isc.TimeItem;isc.A.DEFAULT_TIME="00:00:00";isc.A=isc.TimeItem.getPrototype();isc.A.textFieldDefaults={name:"timeTextField",type:"text",changeOnBlur:true,$712:function(){return this.parentItem.$712()},$1564:function(){if(!this.parentItem.usePlaceholderForHint)return false;return this.$1560()},getHint:function(){if(this.$712()){return(this.parentItem.hint!=null?this.parentItem.hint:this.parentItem.getDefaultHint())}
return null},changeOnKeypress:false,shouldSaveValue:false,getTextBoxStyle:function(){var _1=this.parentItem;if(_1!=null&&_1.textBoxStyle!=null){return _1.invokeSuper(isc.TimeItem,"getTextBoxStyle")}
return this.Super("getTextBoxStyle",arguments)},getTextBoxWidth:function(_1){if(this.parentItem){return this.parentItem.getTextBoxWidth(_1)}
return this.Super("getTextBoxWidth",arguments)},$887:true,handleKeyPress:function(){var _1=this.Super("handleKeyPress",arguments);if(_1!=false){var _2=isc.EH.getKey();if(_2=="Enter"&&!this.useMask){if(this.parentItem)this.parentItem.updateValue();this.setElementValue(this.mapValueToDisplay(this.getValue()))}}
return _1},setMask:function(_1){this.logWarn("setMask: custom mask ignored")},shouldApplyStaticTypeFormat:function(){if(this.isReadOnly())return true;return this.Super("shouldApplyStaticTypeFormat",arguments)}};isc.A.wrapHintText=false;isc.A.usePlaceholderForHint=true;isc.A.showHourItem=true;isc.A.hourItemDefaults={name:"hourItem",type:"select",titleOrientation:"top",showTitle:true,addUnknownValues:false,titleAlign:"center",valueMap:"this.parentItem.getHourValues()",shouldSaveValue:false,align:"center",defaultDynamicValue:"(this.parentItem.defaultValue && this.parentItem.getDefaultValue().getHours()) || this.parentItem.getHourValues()[0]",saveValue:function(){this.Super("saveValue",arguments);this.parentItem.updateValue()},getErrorWidth:function(){return 0},suppressItemChanged:true};isc.A.hourItemTitle="Hour";isc.A.hourItemPrompt="Choose hours";isc.A.showMinuteItem=true;isc.A.minuteItemDefaults={name:"minuteItem",type:"select",titleOrientation:"top",showTitle:true,addUnknownValues:false,titleAlign:"center",align:"center",defaultDynamicValue:"(this.parentItem.defaultValue && this.parentItem.getDefaultValue().getMinutes()) || this.parentItem.getMinuteValues()[0]",valueMap:"this.parentItem.getMinuteValues()",shouldSaveValue:false,saveValue:function(){this.Super("saveValue",arguments);this.parentItem.updateValue()},getErrorWidth:function(){return 0},suppressItemChanged:true};isc.A.minuteItemTitle="Min";isc.A.minuteItemPrompt="Choose minutes";isc.A.showSecondItem=true;isc.A.secondItemDefaults={name:"secondItem",type:"select",titleOrientation:"top",showTitle:true,addUnknownValues:false,titleAlign:"center",valueMap:"this.parentItem.getSecondValues()",shouldSaveValue:false,align:"center",defaultDynamicValue:"(this.parentItem.defaultValue && this.parentItem.getDefaultValue().getSeconds()) || this.parentItem.getSecondValues()[0]",saveValue:function(){this.Super("saveValue",arguments);this.parentItem.updateValue()},getErrorWidth:function(){return 0},width:40,suppressItemChanged:true};isc.A.secondItemTitle="Sec";isc.A.secondItemPrompt="Choose seconds";isc.A.showMillisecondItem=false;isc.A.showMillisecondItem=false;isc.A.millisecondItemDefaults={name:"millisecondItem",type:"select",titleOrientation:"top",showTitle:true,addUnknownValues:false,titleAlign:"center",align:"center",defaultDynamicValue:"(this.parentItem.defaultValue && this.parentItem.getDefaultValue().getMilliseconds()) || this.parentItem.getMillisecondValues()[0]",valueMap:"this.parentItem.getMillisecondValues()",shouldSaveValue:false,saveValue:function(){this.Super("saveValue",arguments);this.parentItem.updateValue()},getErrorWidth:function(){return 0},width:42,suppressItemChanged:true};isc.A.millisecondItemTitle="Ms";isc.A.millisecondItemPrompt="Choose milliseconds";isc.A.ampmItemDefaults={name:"ampmItem",prompt:"Choose AM or PM",type:"select",titleOrientation:"top",showTitle:true,addUnknownValues:false,titleAlign:"center",valueMap:"this.parentItem.getAmpmOptions()",shouldSaveValue:false,align:"center",defaultDynamicValue:"this.parentItem.getAmpmOptions()[0]",saveValue:function(){this.Super("saveValue",arguments);this.parentItem.updateValue()},getErrorWidth:function(){return 0},width:40,suppressItemChanged:true};isc.A.ampmItemTitle="AM/PM";isc.A.timeFormatter24Hour="toShort24HourTime";isc.A.timeFormatter12Hour="toShortTime";isc.A.allowEmptyValue=true;isc.A.width=120;isc.A.cellPadding=0;isc.A.useTextField=true;isc.A.textAlign=isc.Page.isRTL()?isc.Canvas.RIGHT:isc.Canvas.LEFT;isc.A.invalidTimeStringMessage="Invalid time";isc.A.use24HourTime=true;isc.A=isc.TimeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.textBoxStyle=null;isc.A.hourMinValue=null;isc.A.hourMaxValue=null;isc.A.hourIncrement=1;isc.A.minuteMinValue=null;isc.A.minuteMaxValue=null;isc.A.minuteIncrement=1;isc.A.secondMinValue=null;isc.A.secondMaxValue=null;isc.A.secondIncrement=1;isc.A.millisecondMinValue=null;isc.A.millisecondMaxValue=null;isc.A.millisecondIncrement=1;isc.A.selectorFormat="HMSL";isc.B.push(isc.A.getTextBoxStyle=function isc_TimeItem_getTextBoxStyle(){if(this.useTextField&&this.textField){return this.textField.getTextBoxStyle()}
return this.Super("getTextBoxStyle",arguments)},isc.A.$143=function isc_TimeItem__sizeTextBoxAsContentBox(){if(this.useTextField&&this.textField){return this.textField.$143()}
return this.Super("$143",arguments)},isc.A.showing24HourTime=function isc_TimeItem_showing24HourTime(){return this.use24HourTime},isc.A.getSubItemValues=function isc_TimeItem_getSubItemValues(_1){var _2=this[_1+"Values"],_3=_1.substring(0,1).toUpperCase()+_1.substring(1,_1.length);if(!_2){_2=[];var _4=this["get"+_3+"MinValue"](),_5=this["get"+_3+"MaxValue"](),_6=0;for(var i=_4;i<=_5;i+=this[_1+"Increment"]){if(i<10)_2.add(isc.NumberUtil.stringify(i,2));else _2.add(isc.NumberUtil.stringify(i));_6++}
this[_1+"Values"]=_2}
return this[_1+"Values"]},isc.A.setHourValues=function isc_TimeItem_setHourValues(_1){this.hourValues=_1;if(this.hourItem)this.hourItem.setValueMap(this.getHourValues())},isc.A.getHourValues=function isc_TimeItem_getHourValues(){return this.getSubItemValues("hour")},isc.A.getHourMinValue=function isc_TimeItem_getHourMinValue(){if(this.hourMinValue==null)this.hourMinValue=(this.showing24HourTime()?0:1);return this.hourMinValue},isc.A.getHourMaxValue=function isc_TimeItem_getHourMaxValue(){if(this.hourMaxValue==null)this.hourMaxValue=(this.showing24HourTime()?23:12);return this.hourMaxValue},isc.A.setMinuteValues=function isc_TimeItem_setMinuteValues(_1){this.minuteValues=_1;if(this.minuteItem)this.minuteItem.setValueMap(this.getMinuteValues())},isc.A.getMinuteValues=function isc_TimeItem_getMinuteValues(){return this.getSubItemValues("minute")},isc.A.getMinuteMinValue=function isc_TimeItem_getMinuteMinValue(){if(this.minuteMinValue==null)this.minuteMinValue=0;return this.minuteMinValue},isc.A.getMinuteMaxValue=function isc_TimeItem_getMinuteMaxValue(){if(this.minuteMaxValue==null)this.minuteMaxValue=59;return this.minuteMaxValue},isc.A.setSecondValues=function isc_TimeItem_setSecondValues(_1){this.secondValues=_1;if(this.secondItem)this.secondItem.setValueMap(this.getSecondValues())},isc.A.getSecondValues=function isc_TimeItem_getSecondValues(){return this.getSubItemValues("second")},isc.A.getSecondMinValue=function isc_TimeItem_getSecondMinValue(){if(this.secondMinValue==null)this.secondMinValue=0;return this.secondMinValue},isc.A.getSecondMaxValue=function isc_TimeItem_getSecondMaxValue(){if(this.secondMaxValue==null)this.secondMaxValue=59;return this.secondMaxValue},isc.A.setMillisecondValues=function isc_TimeItem_setMillisecondValues(_1){this.millisecondValues=_1;if(this.millisecondItem)this.millisecondItem.setValueMap(this.getMillisecondValues())},isc.A.getMillisecondValues=function isc_TimeItem_getMillisecondValues(){return this.getSubItemValues("millisecond")},isc.A.getMillisecondMinValue=function isc_TimeItem_getMillisecondMinValue(){if(this.millisecondMinValue==null)this.millisecondMinValue=0;return this.millisecondMinValue},isc.A.getMillisecondMaxValue=function isc_TimeItem_getMillisecondMaxValue(){if(this.millisecondMaxValue==null)this.millisecondMaxValue=999;return this.millisecondMaxValue},isc.A.getAmpmOptions=function isc_TimeItem_getAmpmOptions(){if(this.ampmValues)return this.ampmValues;var _1=["AM","PM"];return _1},isc.A.setHours=function isc_TimeItem_setHours(_1){if(this.useTextField){var _2=this.textField.getValue();if(_2==null){var _3=isc.DateUtil.create();_2=isc.DateUtil.createLogicalTime(_1,_3.getMinutes(),0)}else{_2.setHours(_1)}
this.textField.setValue(_2)}else{if(!this.getHourValues().contains(_1)){this.logWarn("setHours: "+_1+" is not a valid option")}else{this.hourItem.setValue(_1)}}},isc.A.setMinutes=function isc_TimeItem_setMinutes(_1){if(this.useTextField){var _2=this.textField.getValue();if(_2==null){var _3=isc.DateUtil.create();_2=isc.DateUtil.createLogicalTime(_3.getHours(),_1,0)}else{_2.setMinutes(_1)}
this.textField.setValue(_2)}else{if(!this.getMinuteValues().contains(_1)){this.logWarn("setMinutes: "+_1+" is not a valid option")}else{this.minuteItem.setValue(_1)}}},isc.A.setSeconds=function isc_TimeItem_setSeconds(_1){if(this.useTextField){var _2=this.textField.getValue();_2.setSeconds(_1);this.textField.setValue(_2)}else{if(!this.getSecondValues().contains(_1)){this.logWarn("setSeconds: "+_1+" is not a valid option")}else{this.secondItem.setValue(_1)}}},isc.A.setMilliseconds=function isc_TimeItem_setMilliseconds(_1){if(this.useTextField){var _2=this.textField.getValue();_2.setMilliseconds(_1);this.textField.setValue(_2)}else{if(!this.getMillisecondValues().contains(_1)){this.logWarn("setMilliseconds: "+_1+" is not a valid option")}else{this.millisecondItem.setValue(_1)}}},isc.A.getSelectorFormat=function isc_TimeItem_getSelectorFormat(){return this.selectorFormat},isc.A.getDuration=function isc_TimeItem_getDuration(_1){_1=_1||this.getDefaultDurationTimeUnit();var _2=this.getValue();if(!isc.isA.Date(_2))return null;var _3=_2.getHours(),_4=_2.getMinutes(),_5=_2.getSeconds(),_6=_2.getMilliseconds(),_7=(_3*60*60*1000)+(_4*60*1000)+(_5*1000)+_6;if(_1=="second")return _7/1000;else if(_1=="minute")return _7/1000/60;else if(_1=="hour")return _7/1000/60/60;else return _7},isc.A.getDefaultDurationTimeUnit=function isc_TimeItem_getDefaultDurationTimeUnit(){if(this.millisecondItem&&this.millisecondItem.isVisible())return"millisecond";if(this.secondItem&&this.secondItem.isVisible())return"second";if(this.minuteItem&&this.minuteItem.isVisible())return"minute";if(this.hourItem&&this.hourItem.isVisible())return"hour"},isc.A.setItems=function isc_TimeItem_setItems(_1){var _2=isc.TimeItem,_3=this.getSelectorFormat();if(_1!=null&&_1.length!=0){this.logWarn("setItems() called for timeItem with itemList:"+_1+" - ignoring, and making use of default date fields")}
_1=this.items=[];if(this.useTextField){var _4={textAlign:this.textAlign,emptyDisplayValue:this.emptyDisplayValue,invalidTimeStringMessage:this.invalidTimeStringMessage,operator:this.operator,title:this.title,allowEmptyValue:this.allowEmptyValue,getDefaultValue:function(){return this.parentItem.getDefaultValue()},validateOnChange:this.validateOnChange,validators:this.validators,type:this.type,parentItem:this};var _5=isc.addProperties({},this.textFieldDefaults,_2.TEXT_FIELD,this.textFieldProperties);var _6;if(this.$119a()){_6={textAlign:this.isRTL()?isc.Canvas.RIGHT:isc.Canvas.LEFT,editorType:isc.NativeTimeItem,browserInputType:this.getBrowserInputType()}}else{_6={type:"time",editorType:isc.TextItem,useMask:this.useMask,formatterMap:this.formatterMap,$30o:function(){return this.parentItem.$30o()},getDisplayValue:function(_20){return this.parentItem.getDisplayValue(_20)}};if(this.useMask){var _7=this.$30o(),_8=this.formatterMap[_7];if(_8==null){_6.useMask=false;_6.mask=null;this.logWarn("Mask will not be used because timeFormatter "+_7+" is not recognized")}else{if(_8.formatter)this.timeFormatter=_8.formatter;_6.mask=_8.mask}
if(_6.mask){_6.maskSaveLiterals=true;if(_5.maskOverwriteMode==null)_5.maskOverwriteMode=true}}else{_6.mask=null}}
if(this.format)_6.format=this.format;var _9=isc.addProperties({},_4,_5,_6);_9.name="timeTextField";if(this.height&&(!this.textFieldProperties||!this.textFieldProperties.height))
{_9.height=this.getTextBoxHeight()}
if(!this.$119a()){if(this.parseEditorValue){_9.parseEditorValue=function innerTimeTextItem_parseEditorValue(_20,_21,_18){var _10=this.parentItem.parseEditorValue(_20,_21,this.parentItem);if(_10!=null&&!isc.isA.Date(_10)){var _11=_10;_10=isc.Time.parseInput(_10,true);if(_10==null)_10=_11}
return _10}}
if(this.formatEditorValue){_9.formatEditorValue=function innerTimeTextItem_formatEditorValue(_20,_21,_22,_18){var _12=this.parentItem.formatEditorValue(_20,_21,_22,this.parentItem);if(isc.isA.Date(_12)){_12=isc.Time.format(_12,this.$30o())}
return _12}}}
_1.add(_9);var _13;this.hourItem=this.minuteItem=this.secondItem=this.millisecondItem=this.ampmItem=_13}else{var _14=isc.SelectItem.getInstanceProperty("textBoxStyle"),_15=isc.SelectItem.getInstanceProperty("pickerIconWidth")+isc.Element.$tf(_14)+isc.Element.$tg(_14)+isc.Element.$yp(_14)+4;for(var i=0;i<_3.length;i++){var _17=_3.charAt(i);var _18=null;if(_17=="H"&&this.showHourItem!=false){_18=isc.addProperties({title:this.hourItemTitle,titleStyle:this.titleStyle,prompt:this.hourItemPrompt},this.hourItemDefaults,_2.HOUR_ITEM,this.hourItemProperties,{name:"hourItem"});if(!_18.width){if(this.$178x==null){var _19=this.getHourValues().join("<br>");this.$178x=isc.Canvas.measureContent(_19,_18.styleName||_14)+_15}
_18.width=this.$178x;_18.minWidth=this.$178x}}else if(_17=="M"&&this.showMinuteItem!=false){_18=isc.addProperties({title:this.minuteItemTitle,titleStyle:this.titleStyle,prompt:this.minuteItemPrompt},this.minuteItemDefaults,_2.MINUTE_ITEM,this.minuteItemProperties,{name:"minuteItem"});if(!_18.width){if(this.$178y==null){var _19=this.getMinuteValues().join("<br>");this.$178y=isc.Canvas.measureContent(_19,_18.styleName||_14)+_15}
_18.width=this.$178y;_18.minWidth=this.$178y}}else if(_17=="S"&&this.showSecondItem!=false){_18=isc.addProperties({title:this.secondItemTitle,titleStyle:this.titleStyle,prompt:this.secondItemPrompt},this.secondItemDefaults,_2.SECOND_ITEM,this.secondItemProperties,{name:"secondItem"});if(!_18.width){if(this.$178z==null){var _19=this.getSecondValues().join("<br>");this.$178z=isc.Canvas.measureContent(_19,_18.styleName||_14)+_15}
_18.width=this.$178z;_18.minWidth=this.$178z}}else if((_17=="L"||_17=="m")&&this.showMillisecondItem!=false){_18=isc.addProperties({title:this.millisecondItemTitle,titleStyle:this.titleStyle,prompt:this.millisecondItemPrompt},this.millisecondItemDefaults,_2.MILLISECOND_ITEM,this.millisecondItemProperties,{name:"millisecondItem"})}
if(_18){if(_1.length>0){if(_18.cssText==null){_18.cssText="padding-left:3px;"}}
_1.add(_18)}}
if(!this.showing24HourTime()){_18=isc.addProperties({title:this.ampmItemTitle},this.ampmItemDefaults,_2.AMPM_SELECTOR,this.ampmItemProperties,{name:"ampmItem"});if(!_18.width){if(this.$180w==null){var _19=this.getAmpmOptions().join("<br>");this.$180w=isc.Canvas.measureContent(_19,_18.styleName||_14)+_15}
_18.width=this.$180w;_18.minWidth=this.$180w}
if(_18.cssText==null){_18.cssText="padding-left:3px;"}
_1.add(_18)}}
this.Super("setItems",[_1],arguments);if(this.$161p())this.$1609();if(this.useTextField){this.textField=this.timeTextField}});isc.B._maxIndex=isc.C+29;isc.A=isc.TimeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.short24TimeFormat="HH:MM";isc.A.shortTimeFormat="HH:MM [am|pm]";isc.A.long24TimeFormat="HH:MM:SS";isc.A.longTimeFormat="HH:MM:SS [am|pm]";isc.A.full24TimeFormat="HH:MM:SS.lll";isc.A.fullTimeFormat="HH:MM:SS.lll [am|pm]";isc.A.$g5="time";isc.A.formatterMap={toTime:{mask:"[0-1]#:[0-6]#:[0-6]# [ap]m",formatter:"toPaddedTime"},to24HourTime:{mask:"[0-2]#:[0-6]#:[0-6]#",formatter:"toPadded24HourTime"},toPaddedTime:{mask:"[0-1]#:[0-6]#:[0-6]# [ap]m"},toPadded24HourTime:{mask:"[0-2]#:[0-6]#:[0-6]#"},toShortTime:{mask:"[0-1]#:[0-6]# [ap]m",formatter:"toShortPaddedTime"},toShort24HourTime:{mask:"[0-2]#:[0-6]#",formatter:"toShortPadded24HourTime"},toShortPaddedTime:{mask:"[0-1]#:[0-6]# [ap]m"},toShortPadded24HourTime:{mask:"[0-2]#:[0-6]#"}};isc.A.validators=[{type:"isTime"}];isc.B.push(isc.A.$1609=function isc_TimeItem__updatePendingStatuses(){var _1=this.$161p()&&this.pendingStatus;if(this.useTextField){var _2=this.textField;if(_2!=null)_2.setFixedPendingStatus(_1)}else{var _3=this.$160w(),_4;if(!isc.isA.Date(_3))_4=null;else if(_3.logicalTime)_4=_3;else _4=isc.DateUtil.getLogicalTimeOnly(_3);var _5=this._value,_6;if(!isc.isA.Date(_5))_6=null;else{_6=_5}
var _7=this.hourItem;if(_7!=null){if(!_1){_7.setFixedPendingStatus(false)}else if(_4==null||_6==null){_7.setFixedPendingStatus(true)}else{var _8=_4.getHours(),_9=_6.getHours();if(!this.showing24HourTime()){_8=_8%12;_9=_9%12}
_7.setFixedPendingStatus(_8!=_9)}}
var _10=this.minuteItem;if(_10!=null){_10.setFixedPendingStatus(_1&&(_4==null||_6==null||_4.getMinutes()!=_6.getMinutes()))}
var _11=this.secondItem;if(_11!=null){_11.setFixedPendingStatus(_1&&(_4==null||_6==null||_4.getSeconds()!=_6.getSeconds()))}
var _12=this.millisecondItem;if(_12!=null){_12.setFixedPendingStatus(_1&&(_4==null||_6==null||_4.getMilliseconds()!=_6.getMilliseconds()))}
var _13=this.ampmItem;if(_13!=null){_13.setFixedPendingStatus(_1&&(_4==null||_6==null||(_4.getHours()<12)!=(_6.getHours()<12)))}}},isc.A.$85m=function isc_TimeItem__shouldAllowExpressions(){if(!this.useTextField)return false;return(this.allowExpressions!=false)},isc.A.getOperator=function isc_TimeItem_getOperator(_1){if(!this.operator)return"equals";return this.operator},isc.A.$712=function isc_TimeItem__getShowHintInField(){return!!(this.useTextField&&this.showHint&&this.hint&&this.showHintInField)},isc.A.getHint=function isc_TimeItem_getHint(){if(!this.showHint||this.$712())return null;if(this.hint!=null)return this.hint;return this.getDefaultHint()},isc.A.getDefaultHint=function isc_TimeItem_getDefaultHint(){if(!this.useTextField)return null;var _1=this.$30o();switch(_1){case"to24HourTime":case"toPadded24HourTime":return this.long24TimeFormat;case"toTime":case"toPaddedTime":return this.longTimeFormat;case"toShort24HourTime":case"toShortPadded24HourTime":return this.short24TimeFormat;case"toShortTime":case"toShortPaddedTime":return this.shortTimeFormat;case"toFullTime":case"toFullPaddedTime":return this.fullTimeFormat}
return null},isc.A.$119a=function isc_TimeItem__useNativeTimeInput(){return this.useTextField&&this.getBrowserInputType()==this.$g5},isc.A.getDefaultValue=function isc_TimeItem_getDefaultValue(){var _1=this.defaultValue;if(!_1&&!this.allowEmptyValue)_1=isc.TimeItem.DEFAULT_TIME;if(_1&&!isc.isA.Date(_1))
_1=isc.Time.parseInput(_1);return _1},isc.A.getCriteriaValue=function isc_TimeItem_getCriteriaValue(){if(this.$85m())return this.textField.getElementValue();var _1=this.getValue();if(_1==null||isc.is.emptyString(_1))return null;if(!isc.isA.Date(_1))_1=isc.Time.parseInput(String(_1));return _1},isc.A.getCriterion=function isc_TimeItem_getCriterion(_1){var _2,_3=this.getOperator(_1,isc.isAn.Array(_5)),_4=this.getCriteriaFieldName();var _5=this.getCriteriaValue();if(_5==null||isc.is.emptyString(_5))return;if(this.$85m()){_2=this.parseValueExpressions(_5,_4,_3);if(_2!=null){if("equals"!=_2.operator){return _2}
_5=_2.value}}
if(isc.isA.String(_5)){_5=isc.Time.parseInput(_5)}
if(isc.isA.Date(_5)&&"exact"!=_1){_2={_constructor:"AdvancedCriteria",fieldName:_4,operator:"betweenInclusive",start:isc.Time.createLogicalTime(_5.getHours(),_5.getMinutes(),0,0),end:isc.Time.createLogicalTime(_5.getHours(),_5.getMinutes(),59,999),value:_5};return _2}
_2={fieldName:_4,operator:_3,value:_5};return _2},isc.A.canEditCriterion=function isc_TimeItem_canEditCriterion(_1,_2){if(_1.fieldName!=null&&_1.fieldName==this.getCriteriaFieldName()&&isc.isA.Date(_1.value))
{return true}
return this.Super("canEditCriterion",arguments)},isc.A.$111i=function isc_TimeItem__formatCriterionValue(_1){return this.mapValueToDisplay(_1)},isc.A.updateValue=function isc_TimeItem_updateValue(){if(this.$20l)return;this.$20l=true;var _1;if(this.useTextField){this.timeTextField.updateValue();_1=this.timeTextField.getValue();if(_1==isc.emptyString)_1=null}else{var _2,_3,_4,_5;if(this.hourItem!=null){_2=+this.hourItem.getValue()}
if(this.minuteItem!=null){_3=+this.minuteItem.getValue()}
if(this.secondItem!=null){_4=+this.secondItem.getValue()}
if(this.millisecondItem!=null){_5=+this.millisecondItem.getValue()}
if(this.ampmItem!=null){var _6=this.ampmItem.getValue(),_7=this.getAmpmOptions();if(_6==_7[1]&&_2<12)_2+=12;else if(_6==_7[0]&&_2==12)_2=0}
_1=isc.DateUtil.createLogicalTime(_2,_3,_4,_5)}
delete this.$20l;return this.storeValue(_1)},isc.A.saveValue=function isc_TimeItem_saveValue(_1){var _2=this.Super("saveValue",arguments);if(this.$161p())this.$1609();return _2},isc.A.setValue=function isc_TimeItem_setValue(_1){var _2=_1,_3;if(isc.isA.String(_2)){var _4=isc.Time.parseInput(_2,true);if(isc.isA.Date(_4))_2=_4}else if(_1===_3&&!this.useTextField){_2=this.getDefaultValue();if(_2===_3)_2=isc.Time.parseInput(isc.TimeItem.DEFAULT_TIME)}
if(this.useTextField){this.textField.setValue(_2)}else if(isc.isA.Date(_2)){var _5=_2.getHours(),_6=_2.getMinutes(),_7=_2.getSeconds();if(!this.showing24HourTime()){if(_5>11)_5-=12;if(_5==0)_5=12}
if(_5<10)_5=isc.NumberUtil.stringify(_5,2);if(this.hourItem)this.hourItem.setValue(_5);if(_6<10)_6=isc.NumberUtil.stringify(_6,2);if(this.minuteItem)this.minuteItem.setValue(_6);if(_7<10)_7=isc.NumberUtil.stringify(_7,2);if(this.secondItem)this.secondItem.setValue(_7);if(this.millisecondItem)this.millisecondItem.setValue(_2.getMilliseconds());var _8=this.ampmItem,_9=this.getAmpmOptions();if(_8)_8.setValue(_2.getHours()>11?_9[1]:_9[0])}
return this.Super("setValue",[_2],arguments)},isc.A.getValue=function isc_TimeItem_getValue(){if(this.useTextField){var _1=this.textField.getValue();var _2=isc.Time.parseInput(String(_1),true);if(_2!=null)_1=_2;return _1}
var h=this.hourItem?+this.hourItem.getValue():0,m=this.minuteItem?+this.minuteItem.getValue():0,s=this.secondItem?+this.secondItem.getValue():0,_6=this.millisecondItem?+this.millisecondItem.getValue():0;var _7=this.ampmItem;if(_7!=null){var _8=_7.getValue(),_9=this.getAmpmOptions();if(_8==_9[1]&&h<12)h+=12;else if(_8==_9[0]&&h==12)h=0}
return isc.DateUtil.createLogicalTime(h,m,s,_6)},isc.A.getEnteredValue=function isc_TimeItem_getEnteredValue(){if(this.useTextField&&this.textField!=null){return this.textField.getEnteredValue()}
return this.getValue()},isc.A.compareValues=function isc_TimeItem_compareValues(_1,_2){if(_1==_2)return true;if(isc.isA.Date(_1)&&isc.isA.Date(_2)&&isc.Time.compareTimes(_1,_2))return true;return false},isc.A.$30o=function isc_TimeItem__getTimeFormatter(){var _1=this.timeFormatter;if(_1==null){_1=this.use24HourTime?this.timeFormatter24Hour:this.timeFormatter12Hour}
if(_1==null&&this.displayFormat!=null&&isc.SimpleType.inheritsFrom(this.type,"time"))
{_1=this.displayFormat}else{if(_1==null)_1=this.form.timeFormatter}
return _1},isc.A.$851=function isc_TimeItem__formatAsTime(){return true},isc.A.$kk=function isc_TimeItem__canFocus(){if(this.canFocus!=null)return this.canFocus;return true},isc.A.focusInItem=function isc_TimeItem_focusInItem(){if(!this.isVisible())return;if(this.useTextField){if(this.textField)this.textField.focusInItem()}else{var _1=this.getSelectorFormat(),_2=_1.charAt(0);if(_2=="H"&&this.hourItem)this.hourItem.focusInItem();if(_2=="M"&&this.minuteItem)this.minuteItem.focusInItem();if(_2=="S"&&this.secondItem)this.secondItem.focusInItem();if(_2=="L"&&this.millisecondItem)this.millisecondItem.focusInItem()}},isc.A.setSelectionRange=function isc_TimeItem_setSelectionRange(_1,_2){if(this.textField)return this.textField.setSelectionRange(_1,_2)},isc.A.getSelectionRange=function isc_TimeItem_getSelectionRange(){if(this.textField)return this.textField.getSelectionRange()},isc.A.selectValue=function isc_TimeItem_selectValue(){if(this.textField)return this.textField.selectValue()},isc.A.deselectValue=function isc_TimeItem_deselectValue(_1){if(this.textField)return this.textField.deselectValue()},isc.A.setHint=function isc_TimeItem_setHint(_1){if(this.useTextField&&this.showHintInField){this.textField.setHint(_1)}else{this.Super("setHint",arguments)}});isc.B._maxIndex=isc.C+27;isc.ClassFactory.defineClass("ToolbarItem","CanvasItem");isc.A=isc.ToolbarItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.canFocus=true;isc.A.shouldSaveValue=false;isc.A.showTitle=false;isc.A.buttonSpace=4;isc.A.startRow=true;isc.A.endRow=true;isc.A.colSpan="*";isc.A.canvasConstructor=isc.Toolbar;isc.A.vertical=false;isc.A.buttonConstructor=isc.AutoFitButton;isc.B.push(isc.A.isEditable=function isc_ToolbarItem_isEditable(){return false});isc.B._maxIndex=isc.C+1;isc.A=isc.ToolbarItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.$18y=function isc_ToolbarItem__createCanvas(){var _1=(this.buttons||this.items||[]),_2=this.buttonProperties||{};isc.addProperties(_2,{handleActivate:function(){var _3=this.parentElement.canvasItem,_4=_3.form;if(this.click!=null)return this.click(_4,_3)}});if(this.buttonBaseStyle&&!_2.baseStyle){_2.baseStyle=this.buttonBaseStyle}
if(this.buttonTitleStyle&&!_2.titleStyle){_2.titleStyle=this.buttonTitleStyle}
this.$20r(_1);this.canvas={overflow:isc.Canvas.VISIBLE,buttons:_1,membersMargin:this.buttonSpace,vertical:this.vertical,buttonProperties:_2};var _5=this.height,_6=this.width;if(!isc.isA.Number(_6)&&this.$8t)
_6=isc.isA.Number(this.$8t[0])?this.$8t[0]:null;if(!isc.isA.Number(_5)&&this.$8t)
_5=isc.isA.Number(this.$8t[1])?this.$8t[1]:null;if(_5)this.canvas.height=_5;if(_6)this.canvas.width=_6;if(this.buttonConstructor!=null)
this.canvas.buttonConstructor=this.buttonConstructor;if(this.createButtonsOnInit!=null){this.canvas.createButtonsOnInit=this.createButtonsOnInit}
return this.Super("$18y",arguments)},isc.A.$20r=function isc_ToolbarItem__updateButtons(_1){if(!_1||_1.length==0)return;for(var i=0;i<_1.length;i++){if(_1[i].click&&isc.isA.String(_1[i].click)){_1[i].click=isc.Func.expressionToFunction("form,item",_1[i].click)}}},isc.A.getButton=function isc_ToolbarItem_getButton(_1){return isc.Class.getArrayItem(_1,this.buttons,"name")},isc.A.addButton=function isc_ToolbarItem_addButton(_1,_2){this.buttons=this.buttons||[];this.buttons.addAt(_1,_2);this.setButtons(this.buttons)},isc.A.removeButton=function isc_ToolbarItem_removeButton(_1){var _2=isc.Class.getArrayItemIndex(_1,this.buttons,"name");if(_2!=-1){this.buttons.removeAt(_2);this.setButtons(this.buttons)}},isc.A.setButtons=function isc_ToolbarItem_setButtons(_1){this.$20r(_1);this.buttons=_1;if(!this.canvas)return;this.canvas.setButtons(_1)},isc.A.setItems=function isc_ToolbarItem_setItems(_1){return this.setButtons(_1)});isc.B._maxIndex=isc.C+7;isc.ClassFactory.defineClass("UploadItem","TextItem");isc.A=isc.UploadItem.getPrototype();isc.A.$183="FILE";isc.A.textBoxStyle="uploadItem";isc.A.$16b={onchange:isc.FormItem.$12y};isc.A.$105m=true;isc.A.multiple=true;isc.A.maintainSelectionOnTransform=false;isc.A=isc.UploadItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.writeTextBoxWidth=isc.Browser.isMoz&&isc.Browser.version>=22;isc.B.push(isc.A.shouldFixRowHeight=function isc_UploadItem_shouldFixRowHeight(){return true},isc.A.shouldWriteTextBoxWidth=function isc_UploadItem_shouldWriteTextBoxWidth(){if(this.writeTextBoxWidth!=null)return this.writeTextBoxWidth;return false},isc.A.shouldWriteTextBoxHeight=function isc_UploadItem_shouldWriteTextBoxHeight(){if(this.writeTextBoxHeight!=null)return this.writeTextBoxHeight;return false},isc.A.getTextBoxWidth=function isc_UploadItem_getTextBoxWidth(_1){if(!this.shouldWriteTextBoxWidth())return null;return this.Super("getTextBoxWidth",arguments)},isc.A.getTextBoxHeight=function isc_UploadItem_getTextBoxHeight(_1){if(!this.shouldWriteTextBoxHeight())return null;return this.Super("getTextBoxHeight",arguments)},isc.A.$143=function isc_UploadItem__sizeTextBoxAsContentBox(){return false},isc.A.$149=function isc_UploadItem__getEventMaskWidth(){var _1=this.getElementWidth();if(!isc.isA.Number(_1))_1=185;return _1},isc.A.$10y=function isc_UploadItem__updateValue(_1){_1=this.mapDisplayToValue(_1);if(_1==this._value)return true;var _2=this.handleChange(_1,this._value);if(this.$17n!=_1){this.logWarn("Upload Items do not support programmatically modifying the value entered by the user. Ignoring attempt to update from change handler")}
this.saveValue(this.mapDisplayToValue(this.getElementValue()));delete this.$17n;this.handleChanged(this._value);return _2},isc.A.redrawn=function isc_UploadItem_redrawn(){this.Super("redrawn",arguments);this.updateValue(this.getElementValue())},isc.A.setElementReadOnly=function isc_UploadItem_setElementReadOnly(_1){this.$176(!_1&&!this.isDisabled())},isc.A.setValue=function isc_UploadItem_setValue(_1){var _2=this.getValue();if(_1==null||isc.isAn.emptyString(_1)){if(_2==null||isc.isAn.emptyString(_2))return;return this.Super("setValue",arguments)}
if(_1!=_2){this.logWarn("Attempting to set the value for an upload form item. This is disallowed for security reasons - returning the current value of the form item")}
return _2},isc.A.$12z=function isc_UploadItem__handleElementChanged(){this.Super("$12z",arguments);this.checkForImplicitSave()},isc.A.setElementValue=function isc_UploadItem_setElementValue(_1){if(_1==null||isc.isAn.emptyString(_1)){if(isc.Browser.isIE){this.redraw();return}
return this.Super("setElementValue",arguments)}
var _2=this.getElementValue();if(_1!=_2){this.logInfo("Attempting to set the value for an upload form item. This is disallowed for security reasons - returning the current value of the form item")}
return _2},isc.A.refreshDisplayValue=function isc_UploadItem_refreshDisplayValue(){},isc.A.$85m=function isc_UploadItem__shouldAllowExpressions(){return false},isc.A.$884=function isc_UploadItem__shouldSelectOnFocus(){return false});isc.B._maxIndex=isc.C+16;isc.UploadItem.markUnsupportedMethods(null,["getSelectionRange","setSelectionRange","selectValue","deselectValue"]);isc.defineClass("ComboBoxItem","TextItem","PickList");isc.defer("if (isc.ComboBoxItem.$b4.animatePickList == null) isc.ComboBoxItem.addProperties({ animatePickList: isc.Browser.isHandset || isc.Browser.isTablet });");if(isc.PickList)isc.ComboBoxItem.addMethods(isc.PickList.$146x)
isc.A=isc.ComboBoxItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.autoSizePickList=true;isc.A.pickerSearchFieldDefaults={width:"*",height:"100%",editorType:"TextItem",showTitle:false,showHintInField:true,browserAutoCorrect:false,getHint:function(){return this.creator.addUnknownValues?this.creator.pickerSearchOrNewValueFieldHint:this.creator.pickerSearchFieldHint}};isc.A.pickerSearchFieldHint="Search";isc.A.pickerSearchOrNewValueFieldHint="Search or enter new value";isc.A.pickerSearchFormConstructor=isc.DynamicForm;isc.A.pickerSearchFormDefaults={numCols:1,width:"100%",height:25,cellPadding:0,cellSpacing:0,layoutAlign:"middle",leftPadding:5,rightPadding:5,overflow:"hidden"};isc.A.pickerExitButtonConstructor=isc.NavigationButton;isc.A.pickerExitButtonTitle="Cancel";isc.A.pickerSaveButtonConstructor=isc.NavigationButton;isc.A.pickerSaveButtonTitle="Accept";isc.A.emptyPickListMessage="No items to show";isc.A.showPickerIcon=true;isc.A.pickerIconWidth=15;isc.A.pickerIconHeight=null;isc.A.textBoxStyle="selectItemText";isc.A.pickerIconSrc="[SKIN]/DynamicForm/ComboBoxItem_PickButton_icon.gif";isc.A.pickerIconProperties={tabIndex:-1,showOver:true};isc.A.modalPickList=false;isc.A.showPickListOnKeypress=true;isc.A.saveOnEnter=true;isc.A.$20s="Arrow_Up";isc.A.$20t="Arrow_Down";isc.A.$20u="Page_Up";isc.A.$20v="Page_Down";isc.A.$20w="Escape";isc.A.$10j="Enter";isc.A.$jf="Tab";isc.A.addUnknownValues=true;isc.A.allowEmptyValue=true;isc.A.mapEmptyDisplayValue=false;isc.A.$27r="none";isc.A.$1709=false;isc.A.filterDisplayValue=true;isc.A.autoFetchData=false;isc.A.filterWithValue=false;isc.A.searchStringTooShortMessage="Enter a longer search string to search";isc.B.push(isc.A.init=function isc_ComboBoxItem_init(){if(this.specialValues&&this.allowEmptyValue){this.allowEmptyValue=false}
return this.Super("init",arguments)},isc.A.$1397=function isc_ComboBoxItem__elementIsReadOnly(){var _1=this.Super("$1397",arguments);if(!_1&&this.hasPopOutPicker()){_1=true}
return _1},isc.A.createPickerNavigationBar=function isc_ComboBoxItem_createPickerNavigationBar(){var _1=isc.addProperties({},this.pickerSearchFieldDefaults,this.pickerSearchFieldProperties,{name:"s",handleKeyPress:function(){var _2=this.Super("handleKeyPress",arguments);if(_2!=false){var _3=this.creator.pickerSearchFieldKeyPress(this);_2=_3==null?_2:_3}
return _2},handleChanged:function(_5,_6){var _4=this.Super("handleChanged",arguments);this.creator.pickerSearchFieldChanged(this);return _4},creator:this});this.pickerSearchForm=this.createAutoChild("pickerSearchForm",{layoutAlign:"center",items:[_1]});this.pickerSearchField=this.pickerSearchForm.getItem("s");this.pickerExitButton=this.createAutoChild("pickerExitButton",{title:this.pickerExitButtonTitle,click:function(){this.creator.pickerExitButtonClick()}});this.pickerSaveButton=this.createAutoChild("pickerSaveButton",{title:this.pickerSaveButtonTitle,click:function(){this.creator.pickerSaveButtonClick()},disabled:true,visibility:this.addUnknownValues?isc.Canvas.INHERIT:isc.Canvas.HIDDEN});this.pickerNavigationBar=this.createAutoChild("pickerNavigationBar",{controls:[this.pickerSearchForm,this.pickerSaveButton,this.pickerExitButton]})},isc.A.pickerSearchFieldKeyPress=function isc_ComboBoxItem_pickerSearchFieldKeyPress(_1,_2,_3,_4,_5){return this.handleSearchItemKeyPress(_1)},isc.A.pickerSearchFieldChanged=function isc_ComboBoxItem_pickerSearchFieldChanged(_1){this.$143h(_1.getEnteredValue());if(this.pickerSaveButton&&this.pickerSaveButton.isVisible()){this.pickerSaveButton.setDisabled(false)}},isc.A.pickerExitButtonClick=function isc_ComboBoxItem_pickerExitButtonClick(){this.pickList.hide()},isc.A.pickerSaveButtonClick=function isc_ComboBoxItem_pickerSaveButtonClick(){var _1=this.pickerSearchForm.getValue("s");this.setElementValue(_1==null?"":_1);this.pickList.hide();this.updateValue()},isc.A.setAddUnknownValues=function isc_ComboBoxItem_setAddUnknownValues(_1){this.addProperties({addUnknownValues:_1,changeOnKeypress:!_1});this.setValue(null);if(this.pickerSaveButton){this.pickerSaveButton.setVisibility(_1)}},isc.A.drawn=function isc_ComboBoxItem_drawn(_1,_2,_3,_4){this.invokeSuper(isc.ComboBoxItem,"drawn",_1,_2,_3,_4);if(this.autoFetchData&&this.$19m()){this.filterWithValue=false;this.fetchData(null,null,true)}},isc.A.pickListShown=function isc_ComboBoxItem_pickListShown(){if(this.pickList.isVisible()){this.$20x=this.ns.Page.setEvent("mouseDown",this,null,"$143i")}},isc.A.$143i=function isc_ComboBoxItem__mouseDownWithPickList(){var _1=this.pickList;if(!_1||!_1.isVisible())return;var _2=isc.EH.lastEvent.target;if(!_1.contains(_2,true)&&(!_1.$314||!_1.$314.contains(_2,true))&&(!_1.filterEditor||_1.filterEditor.getEditForm()!=_2))
{var _3=false;if(_1.filterEditor){var _4=_1.filterEditor.getEditForm().getItems().getProperty("pickList");_4.addList(_1.filterEditor.getEditForm().getItems().getProperty("picker"));for(var i=0;i<_4.length;i++){if(_4[i]&&_4[i].contains(_2)){_3=true;break}}}
if(!_3){_1.hide()}}
if(!this.$143j){this.$143j=this.ns.Page.setEvent("mouseUp",this,isc.Page.FIRE_ONCE,"$143k")}
if(!this.$43m){this.$43m=this.ns.Page.setEvent("dragStop",this,isc.Page.FIRE_ONCE,"$43n")}},isc.A.$143k=function isc_ComboBoxItem__mouseUpWithPickList(){if(this.form.$ne().item==this){this.ns.Page.clearEvent("dragStop",this.$43m);delete this.$43m;delete this.$143j;return false}
if(!isc.Browser.isMobile||!this.hasPopOutPicker()){this.$43n(true)}},isc.A.$43n=function isc_ComboBoxItem__refocusFromPLMouseUp(_1){if(_1==true){this.ns.Page.clearEvent("dragStop",this.$43m)}else{this.ns.Page.clearEvent("mouseUp",this.$143j)}
delete this.$43m;delete this.$143j;var _2=isc.EH.getTarget();if(this.pickList&&this.pickList.isVisible()&&this.pickList.contains(_2,true)&&(!this.pickerSearchForm||!this.pickerSearchForm.contains(_2,true)))
{this.focusInItem()}},isc.A.pickListHidden=function isc_ComboBoxItem_pickListHidden(){if(this.$20x)this.ns.Page.clearEvent("mouseDown",this.$20x);delete this.$20x;delete this.$111h},isc.A.handleKeyPress=function isc_ComboBoxItem_handleKeyPress(){if(!this.hasFocus||this.isReadOnly())return this.Super("handleKeyPress",arguments);var _1=this.handleSearchItemKeyPress(this);if(_1!=false)_1=this.Super("handleKeyPress",arguments);return _1},isc.A.handleSearchItemKeyPress=function isc_ComboBoxItem_handleSearchItemKeyPress(_1){var _2=isc.EH.lastEvent.keyName,_3=this.pickList,_4=(_3?(_3.isDrawn()&&_3.isVisible()):false);if(_4&&(_2==this.$20v||_2==this.$20u)){return _3.body.handleKeyPress(isc.EH.lastEvent)}
var _5=_1.getEnteredValue(),_6=this.getValue(),_7=(!_5||_5==isc.emptyString);if(_1==this&&_2==this.$20t&&isc.EH.altKeyDown()){this.$84k=_5;this.$200=_7;this.filterWithValue=false;this.showPickList();return false}
if(_2==this.$20w&&this.addUnknownValues==false){var _8=this.getDisplayValue(_6);if(isc.isAn.emptyString(_8)&&this.$176g())
{this.$66t()}else{this.setElementValue(_8)}}
var _9=_2==this.$10j,_10=false;if(_9&&(_4||this.addUnknownValues==true)){_10=this.shouldCompleteOnEnter()}
var _11=_4&&(_2==this.$20t||_2==this.$20s);this.$823=_11;if(_4){if(_11||(_9&&_10)||_2==this.$20w)
{_3.bodyKeyPress(isc.EH.lastEvent);return false}
if(_9)_3.hide()}else if(this.addUnknownValues){if(_9&&_10)this.updateValue()}
if(!this.addUnknownValues&&_1==this)this.$82s()},isc.A.shouldCompleteOnTab=function isc_ComboBoxItem_shouldCompleteOnTab(){return this.completeOnTab||(this.addUnknownValues==false)},isc.A.shouldCompleteOnEnter=function isc_ComboBoxItem_shouldCompleteOnEnter(){if(this.addUnknownValues==false)return true;else if(this.$823)return true;else if(this.completeOnEnter!=null)return this.completeOnEnter;else{return((this.form&&!this.form.isSearchForm)||!this.$19m())}},isc.A.handleKeyDown=function isc_ComboBoxItem_handleKeyDown(){if(!this.hasFocus||this.isReadOnly())return this.Super("handleKeyDown",arguments);var _1=isc.EH.lastEvent.keyName,_2=_1==this.$jf,_3=_1==this.$10j,_4=this.pickList,_5=this.$128z();this.$82p=null;var _6=_2&&this.shouldCompleteOnTab()||_3&&this.shouldCompleteOnEnter();if((_2&&this.fetchValueOnTab)||(_3&&this.fetchValueOnEnter))
{var _7=this.$1282()||this.$82q();if(_6&&_5&&!_7&&_4!=null&&_4.data!=null&&!_4.data.isEmpty())
{this.$82r()}else{var _8=this.getEnteredValue(),_9=this.getDisplayFieldName(),_10=this.shouldFetchMissingDisplayValue(_8);if(_9!=null&&_4&&(isc.isA.ResultSet&&isc.isA.ResultSet(_4.data))&&(_4.data.allRowsCached()||(!_7&&_4.data.localData&&_4.data.allMatchingRowsCached())))
{_10=false;var _11=_4.data,_12=_11.localData.find(_9,_8);if(_12!=null)this.$953(_12)}
if(_10){this.$128v(_8);if(this.clearEnteredValuePendingReply){this.setElementValue("")}}else{this.$10y(_8,true)}
if(_4)_4.hide()}}else if(_6){if(this.$82q()){this.$82p=this.getEnteredValue();if(this.clearEnteredValuePendingReply){this.setElementValue("")}}else if(_5){this.$82r()}}
return this.Super("handleKeyDown",arguments)},isc.A.$82q=function isc_ComboBoxItem__loadingData(){return(this.$82m||this.$43j)},isc.A.chooseCurrentPickListValue=function isc_ComboBoxItem_chooseCurrentPickListValue(){var _1=this.pickList;var _2=_1.getSelectedRecord();if(_2!=null)_1.itemClick(_2)},isc.A.$82r=function isc_ComboBoxItem__fireTabCompletion(){this.chooseCurrentPickListValue()},isc.A.refreshDisplayValue=function isc_ComboBoxItem_refreshDisplayValue(){if(this.$82q())return;if(this.$82t)return;return this.Super("refreshDisplayValue",arguments)},isc.A.handleEditorExit=function isc_ComboBoxItem_handleEditorExit(){if(this.$84z())return;this.$823=false;var _1=this.getEnteredValue(),_2=this.getValue();if(this.$82p!=null&&(this.$1563||this.$82p==_1)&&!this.$82q())
{this.$82r();this.$82p=null;_1=this.getEnteredValue()}
if(this.$82p==null&&!this.$1441){if(this.addUnknownValues){var _3=this.getOptionDataSource(),_4=this.getDisplayFieldName();if(_2==_1&&(_3==null||(_4!=null&&_2!=null&&!this.shouldFetchMissingValue(_2))))
{var _5=this.mapValueToDisplay(_2);if(_5!=_2){if(isc.isAn.emptyString(_5)&&this.$176g())
{this.$66t()}else{this.setElementValue(_5)}}}else if(_3!=null&&_4!=null&&_1!=null&&_1!=""&&this.shouldFetchMissingDisplayValue(_1))
{this.$128v(_1)}}else{if(!this.$82q()){if(this.isUnknownValue(_1)){this.setElementValue(this.getDisplayValue())}else{this.$10y(_1,true)}}}}
this.$843=(this.$82p!=null);var _6=this.Super("handleEditorExit",arguments);this.$843=null;return _6},isc.A.$142r=function isc_ComboBoxItem__showValueAfterDraw(_1){if(_1&&this.$82t){this.setElementValue(this.$824)}else return this.Super("$142r",arguments)},isc.A.filterComplete=function isc_ComboBoxItem_filterComplete(){if(this.$19m()){var _1=this.$128m(false);if(_1){if(this.specialValues&&this.separateSpecialValues){this.setSeparateSpecialValues(_1)}else{var _2=this.pickList.getOriginalData();if(isc.isA.ResultSet(_2)){var _3=_2.addSpecialValueRecords(this.getValueFieldName(),this.getDisplayFieldName(),_1);if(_3&&this.pickList)this.pickList.markForRedraw()}}}}
var _4=isc.PickList.getPrototype().filterComplete;_4.apply(this,arguments)},isc.A.updateValueMap=function isc_ComboBoxItem_updateValueMap(_1){this.Super("updateValueMap",arguments);if(this.$192)delete this.$192},isc.A.getClientPickListData=function isc_ComboBoxItem_getClientPickListData(){if(this.$192)return this.$192;var _1=isc.PickList.optionsFromValueMap(this),_2=this.getValueFieldName();var _3=this.$128m(false);if(_3){if(this.separateSpecialValues){this.setSeparateSpecialValues(_3)}else{_1.addListAt(_3,0)}}
this.$192=_1;return _1},isc.A.$82o=function isc_ComboBoxItem__updateValueForFilterComplete(_1,_2,_3){this.selectDefaultItem();if(!this.hasFocus){var _4=this.getEnteredValue();if(this.$82p!=null&&(this.$1563||(this.hasFocus&&this.clearEnteredValuePendingReply&&!_4)||this.$82p==_4))
{this.$82r();this.$82p=null}
if(!this.addUnknownValues){if(this.isUnknownValue(_4)){if(!this.hasFocus){var _5=this.getDisplayValue();if(isc.isAn.emptyString(_5)&&this.$176g())
{this.$66t()}else{this.setElementValue(_5)}
this.$82u()}}else if(!isc.isA.MultiComboBoxItem||!isc.isA.MultiComboBoxItem(this.creator)||!this.hasFocus)
{var r=this.getSelectedRecord();if(r&&r[this.valueField]==this._value&&r[this.displayField]==_4){this.pickList.selection.selectSingle(r)}else{this.$10y(_4,true);_4=this.getEnteredValue();if(this.$176g()&&(_4==null||isc.is.emptyString(_4)))
{this.$66t()}}
this.$82u()}}
this.$844(this.getValue())}
this.$19v()},isc.A.updateDisplayValueMap=function isc_ComboBoxItem_updateDisplayValueMap(_1){this.Super("updateDisplayValueMap",arguments);if(this.$128n&&this.$847){var _2=this.getDisplayFieldName();if(_2){var _3=this.$847,_4=this.getValueFieldName(),_5=this.$128n,_6=false;for(var i=0;i<_5.length;i++){var _8=_5[i],_9=_8[_4],_10=_3.find(_4,_9);if(_10!=null){_8[_2]=_10[_2];_6=true}}
if(_6&&this.separateSpecialValues){if(this.separateValuesList)this.separateValuesList.markForRedraw()}}}},isc.A.$82s=function isc_ComboBoxItem__markPending(){var _1=this.$82t;this.$82t=true;this.$824=this.getEnteredValue();if(!_1)this.updateState()},isc.A.$82u=function isc_ComboBoxItem__markNotPending(){if(!this.$82t)return;this.$82t=null;this.$824=null;this.updateState()},isc.A.getTextBoxStyle=function isc_ComboBoxItem_getTextBoxStyle(){if(this.pendingTextBoxStyle==null||!this.$82t||this.$68y()){if(this.$68y())return isc.TextItem.getInstanceProperty("textBoxStyle");return this.Super("getTextBoxStyle",arguments)}
return this.pendingTextBoxStyle},isc.A.$1748=function isc_ComboBoxItem__remappedDisplayValueUnchanged(_1){if(this.$66x){for(var i in this.$66x){if(i==_1){return false}}}
return this.Super("$1748",arguments)},isc.A.$43a=function isc_ComboBoxItem__nativeCutPaste(_1,_2){this.$182w=true;this.Super("$43a",arguments)},isc.A.$10y=function isc_ComboBoxItem__updateValue(_1,_2){var _3=this.$84z(),_4=(!_2&&!this.$201&&(this.addUnknownValues==false||_3));var _5=false;if(this.addUnknownValues==false&&_4&&this.allowEmptyValue&&(_1==""))
{_4=false;if(!_3)_5=true}
if(!_4&&!this.$182w){this.$82u();var _6=this.mapDisplayToValue(_1);if(this.$201)this.explicitChoice=this.$201;if(this.compareValues(_6,this._value)){if(_5){this.refreshPickList(_1)}
return true}
this.explicitChoice=this.$201;return this.Super("$10y",arguments)}else{if(this.$182w)delete this.$182w;if(this.changeOnKeypress&&this.length!=null&&isc.isA.String(_1)&&_1.length>this.length){_1=_1.substring(0,this.length);this.setElementValue(_1)}
if(this.$84z())return;if(!this.$82t)return;if(this.$824!=this.getElementValue()){this.$824=this.getElementValue()}
if(this.$824==this.$111h)return;this.$111h=this.$824;this.refreshPickList(_1)}},isc.A.$122m=function isc_ComboBoxItem__minimalUpdateValue(_1){this.refreshPickList(_1)},isc.A.handleChanged=function isc_ComboBoxItem_handleChanged(_1,_2){var _3=this.Super("handleChanged",arguments);this.refreshPickList(this.getEnteredValue());return _3},isc.A.refreshPickList=function isc_ComboBoxItem_refreshPickList(_1){var _2=(!_1||_1==isc.emptyString);if(!_2)delete this.$200;var _3=this.pickList,_4=this.$128z();if(_2&&!this.$200){if(_4)_3.hide()}else if(this.showPickListOnKeypress||_4){if(!this.$201&&this.hasFocus){this.$143h(_1)}}},isc.A.$143h=function isc_ComboBoxItem__refreshPickList(_1){if(!this.filterWithValue&&(this.$84k!=_1)){this.filterWithValue=true;delete this.$84k}
this.showPickList(true,true)},isc.A.selectDefaultItem=function isc_ComboBoxItem_selectDefaultItem(){if(this.pickList==null||this.pickList.destroyed)return;var _1=this.pickList.selection;var _2;if(!this.addUnknownValues&&this.$824!=null){_2=this.getPickListRecordForValue(this.$824)}else{_2=this.getSelectedRecord()}
if(_2){this.pickList.clearLastHilite();this.delayCall("selectItemFromValue",[_2[this.getValueFieldName()]]);return}
var _2=this.pickList.getRecord(0);if(_2==null||Array.isLoading(_2)||_2[this.pickList.isSeparatorProperty])return;_1.selectSingle(_2);this.pickList.clearLastHilite();this.pickList.scrollRecordIntoView(0)},isc.A.getSelectedRecord=function isc_ComboBoxItem_getSelectedRecord(){var _1=this.Super("getSelectedRecord",arguments);if(_1==null&&this._value!=null){_1=this.getPickListRecordForValue(this._value);if(_1!=null&&this.optionDataSource){var _2=this.$848([_1]);if(_2){this.$846();if(this.getDisplayFieldName()!=this.getValueFieldName()){this.updateDisplayValueMap()}}}}
return _1},isc.A.getPickListRecordForValue=function isc_ComboBoxItem_getPickListRecordForValue(_1,_2){var _3;if(this.pickList==null||this.pickList.destroyed){if(this.progressiveLoading===true||this.progressiveLoading===false){if(this.pickListProperties==null)this.picklistProperties={};this.picklistProperties.progressiveLoading=this.progressiveLoading}
this.makePickList(false)}
if(_2==null)_2=this.getValueFieldName();if(this.pickList&&this.pickList.data){_3=this.pickList.data.find(_2,_1)}
return _3},isc.A.$128s=function isc_ComboBoxItem__shouldFetchMissingValue(_1,_2){if(this.fetchMissingValues==false)return false;var _3=this.getOptionDataSource();if(_3==null)return false;var _4=this.Super("$128s",arguments);if(_4==false)return false;if(_1!=null&&_3){var _5=(this.pickList&&this.pickList.data&&!this.pickList.data.$882)?this.getPickListRecordForValue(_1,_2):null;if(_5!=null){this.$848([_5]);this.updateDisplayValueMap(true);return false}}
return _4},isc.A.getPickListFilterOperator=function isc_ComboBoxItem_getPickListFilterOperator(){return(this.textMatchStyle=="startsWith"?"iStartsWith":this.textMatchStyle=="exact"?"iEquals":"iContains")},isc.A.getPickerSearchValue=function isc_ComboBoxItem_getPickerSearchValue(){if(this.pickerSearchForm&&this.pickerSearchForm.isVisible()){return this.pickerSearchForm.getValue("s")}
var _1=this.$82p;if(_1==null){if(this.$1441){_1=this.getValue()}else _1=this.getEnteredValue()}
return _1},isc.A.getPickListFilterCriteria=function isc_ComboBoxItem_getPickListFilterCriteria(){var _1=this.getOptionCriteriaCopy(),_2=this.pickListCriteria;if(_2!=null){_2=isc.addProperties({},_2);if(_1==null)_1=_2;else{_1=isc.DataSource.combineCriteria(_1,_2)}}
if(this.alwaysFilterWithValue||this.filterWithValue){var _3=this.filterFields;if(_3==null){_3=[this.getDisplayFieldName()||this.getValueFieldName()]}
var _4=this.$82p||this.getPickerSearchValue();var _5;if(_3.length==1){_5={};_5[_3[0]]=_4}else{_5={_constructor:"AdvancedCriteria",operator:"or",criteria:[]}
for(var i=0;i<_3.length;i++){_5.criteria.add({fieldName:_3[i],value:_4,operator:this.getPickListFilterOperator()})}}
if(_1==null)_1=_5;else _1=isc.DataSource.combineCriteria(_1,_5,"and",this.textMatchStyle)}
if(_1&&this.form){_1=isc.DataSource.resolveDynamicCriteria(_1,this.form.getRuleContext())}
return _1||{}},isc.A.isEntryTooShortToFilter=function isc_ComboBoxItem_isEntryTooShortToFilter(){var _1=this.getEnteredValue();var _2=(_1!=null&&_1.length<this.minimumSearchLength);var _3=((this.filterWithValue||this.alwaysfilterWithValue)&&_2);return _3},isc.A.getEntryTooShortMessage=function isc_ComboBoxItem_getEntryTooShortMessage(){return this.searchStringTooShortMessage},isc.A.$849=function isc_ComboBoxItem__refreshForDisplayValueChange(){if(!this.hasFocus)return true;if(!this.addUnknownValues)return!this.$82t;return!!this.explicitChoice},isc.A.elementBlur=function isc_ComboBoxItem_elementBlur(){this.Super("elementBlur",arguments);if(isc.Browser.isMobile){this.delayCall("hidePickListOnBlur",[true],100)}else{this.hidePickListOnBlur()}},isc.A.hidePickListOnBlur=function isc_ComboBoxItem_hidePickListOnBlur(_1){delete this.$111h;if(_1&&((this.hasFocus&&this.containerWidget.hasFocus)||(this.pickList&&this.pickList.body.hasFocus)))
{return}
if(this.pickList&&this.pickList.$93s)return;var _2=this.pickList,_3=isc.EH,_4=_3.lastEvent;if(this.$84z()||(isc.Browser.isIE&&this.getActiveElement()==this.getDataElement()))
{return}
delete this.$19i;delete this.$43i;if(!_2||!_2.isVisible()||_2.formItem!=this)return;_2.hide()},isc.A.$84z=function isc_ComboBoxItem__mouseDownInPickList(){var _1=this.pickList;if(!_1||!_1.isVisible()||!_1.isDrawn())return false;var _2=isc.EH,_3=isc.EH.lastEvent;if((_3.eventType=="selectionChange"&&_1.contains(isc.EH.mouseDownTarget()))||((_3.eventType==_2.MOUSE_DOWN||_3.eventType==_2.CLICK||_3.eventType==_2.POINTER_DOWN||_3.eventType==_2.POINTER_CANCEL||(_3.eventType==_2.MOUSE_MOVE&&_2.stillWithinMouseDownTarget()))&&(_1.contains(_3.target,true)||(_1.filterEditor&&_1.filterEditor.getEditForm()==_3.target))))
{return true}
return false},isc.A.editorEnter=function isc_ComboBoxItem_editorEnter(_1,_2,_3){this.$66s()},isc.A.editorExit=function isc_ComboBoxItem_editorExit(_1,_2,_3){if(this.$176g()&&(_3==null||isc.isAn.emptyString(_3)))
{this.$66t()}},isc.A.showPicker=function isc_ComboBoxItem_showPicker(){var _1=this.hasPopOutPicker();if(!_1){this.focusInItem()}
this.filterWithValue=false;var _2=this.getEnteredValue(),_3=(!_2||_2==isc.emptyString);this.$84k=_2;this.$200=_3;this.showPickList();if(_1&&this.pickerSearchForm){if(!_3&&this.addUnknownValues&&this.isUnknownValue(_2))
{this.pickerSearchForm.setValues({search:_2})}else{this.pickerSearchForm.clearValues()}
if(this.pickerSaveButton)this.pickerSaveButton.disable();if(_1&&this.pickList){this.delayCall("delayedFocusOnPickListBody",null,0)}}},isc.A.delayedFocusOnPickListBody=function isc_ComboBoxItem_delayedFocusOnPickListBody(){var _1=this.pickList?this.pickList.body:null;if(_1!=null)_1.focus()},isc.A.renderDisabledEventMask=function isc_ComboBoxItem_renderDisabledEventMask(){if(this.hasPopOutPicker())return true;return this.Super("renderDisabledEventMask",arguments)},isc.A.handleClick=function isc_ComboBoxItem_handleClick(){if(!this.isDisabled()&&!this.isReadOnly()&&this.hasPopOutPicker()){this.showPicker()}
return this.Super("handleClick",arguments)},isc.A.pickValue=function isc_ComboBoxItem_pickValue(_1){this.$66s();var _2=this.mapValueToDisplay(_1);this.setElementValue(_2);if(this.hasFocus)this.selectValue();this.$201=true;this.$66x={};this.$66x[_2]=_1;this.updateValue();delete this.$201},isc.A.setValueMap=function isc_ComboBoxItem_setValueMap(){this.Super("setValueMap",arguments);if(this.pickList){if(this.pickList.isVisible())this.pickList.hide();delete this.pickList.formItem
this.setUpPickList(this.pickList.isVisible())}
if(this.addUnknownValues){var _1=this.getDisplayValue();if(isc.isAn.emptyString(_1)&&this.$176g()){this.$66t()}else{this.setElementValue(_1)}}},isc.A.setValue=function isc_ComboBoxItem_setValue(_1,_2,_3,_4,_5){var _6=this._value!=_1;if(!_6){if(this.$82t&&(this.$82p!=null||this.hasFocus))
{this.setElementValue(this.$824);return}}
this.$82u();this.$43o=true;this.invokeSuper(isc.ComboBoxItem,"setValue",_1,_2,_3,_4,_5);delete this.$43o;if(!this.hasFocus&&this.$176g()&&this.getHint()){var _7;if(_1===_7||_1==null||isc.is.emptyString(_1)){this.$66t()}}
if(_3||_1==null){this.explicitChoice=false}else if(_6){this.explicitChoice=true}},isc.A.getDefaultValue=function isc_ComboBoxItem_getDefaultValue(){var _1=this.Super("getDefaultValue",arguments);if(_1==null&&this.defaultToFirstOption){_1=this.getFirstOptionValue()}
return _1},isc.A.makePickList=function isc_ComboBoxItem_makePickList(_1){if(!isc.ComboBoxItem.$1695&&this.pickListProperties!=null&&this.pickListProperties.showFilterEditor)
{this.logWarn("ComboBoxItem.pickListProperties specified with 'showFilterEditor' set to true. The 'showFilterEditor' property is not supported for the pickList of a ComboBoxItem and may result in unexpected user experience.");isc.ComboBoxItem.$1695=true}
this.$128m(false);if(this.progressiveLoading===true||this.progressiveLoading===false){if(this.pickListProperties==null)this.picklistProperties={};this.picklistProperties.progressiveLoading=this.progressiveLoading}
if(!this.filterLocally&&this.specialValues&&!this.separateSpecialValues&&this.$19m())
{if(this.pickListProperties==null)
this.pickListProperties={};if(this.pickListProperties.dataProperties==null)
this.pickListProperties.dataProperties={};this.pickListProperties.dataProperties.fetchMode="basic"}
var _2=isc.PickList.getPrototype().makePickList;return _2.apply(this,arguments)},isc.A.shouldGenerateExactMatchCriteria=function isc_ComboBoxItem_shouldGenerateExactMatchCriteria(){if(this.generateExactMatchCriteria!=null)return this.generateExactMatchCriteria;var _1=this.form.getDataSource();if(_1&&_1.supportsAdvancedCriteria())return true;return false},isc.A.hasAdvancedCriteria=function isc_ComboBoxItem_hasAdvancedCriteria(){if(this.Super("hasAdvancedCriteria",arguments))return true;if(this.addUnknownValues&&this.explicitChoice&&this.shouldGenerateExactMatchCriteria())
return true;return false});isc.evalBoundary;isc.B.push(isc.A.$182a=function isc_ComboBoxItem__usePickListFilterAsCriteria(){return this.addUnknownValues&&!this.explicitChoice&&this.operator==null},isc.A.getCriteriaFieldName=function isc_ComboBoxItem_getCriteriaFieldName(){if(this.criteriaField!=null)return this.criteriaField;if(this.displayField!=null&&this.$182a()){return this.displayField}
return this.getDataPath()||this.getFieldName()},isc.A.getCriteriaValue=function isc_ComboBoxItem_getCriteriaValue(){if(this.displayField!=null&&!this.$1441&&this.$182a())
{var _1=this.getEnteredValue();if(_1!=this.emptyDisplayValue){return _1}}
return this.Super("getCriteriaValue",arguments)},isc.A.getOperator=function isc_ComboBoxItem_getOperator(_1){var _2;if(this.$182a()){_2=this.getPickListFilterOperator()}else{_2=this.Super("getOperator",arguments)}
return _2},isc.A.canEditSimpleCriterion=function isc_ComboBoxItem_canEditSimpleCriterion(_1){if(this.getDataPath()&&_1==this.getDataPath())return true;if(this.criterionField)return _1==this.criterionField;if(this.displayField&&_1==this.displayField)return true;return this.getFieldName()==_1},isc.A.setSimpleCriterion=function isc_ComboBoxItem_setSimpleCriterion(_1,_2){if(this.criterionField==null&&this.displayField!=null&&_2==this.displayField){this.setValue(_1,null,true)}else{this.setValue(_1)}},isc.A.canEditCriterion=function isc_ComboBoxItem_canEditCriterion(_1,_2){if(!this.addUnknownValues){return this.Super("canEditCriterion",arguments)}
if(this.getDataPath()&&_1.fieldName==this.getDataPath())return true;var _3=_1.fieldName,_4=this.criterionField||this.getFieldName(),_5=this.Super("getOperator",[]);if(_3!=null){if(this.displayField==null){if(_3==_4){return _1.operator==_5||_1.operator==this.getPickListFilterOperator()}}else{if(_3==_4){return _1.operator==_5}else if(_3==this.displayField){return _1.operator==this.getPickListFilterOperator()}}}
return false},isc.A.setCriterion=function isc_ComboBoxItem_setCriterion(_1){if(!this.addUnknownValues||this.displayField==null||_1.fieldName!=this.displayField)
{return this.Super("setCriterion",arguments)}
var _2=_1.value;this.setElementValue(_2);this.$43f(_2);var _3=this.mapDisplayToValue(_2);if(!this.compareValues(_3,this._value))this.saveValue(_3)},isc.A.$43f=function isc_ComboBoxItem__checkForDisplayFieldValue(_1,_2){var _3=(this.$17b(_1,true)!=null);if(_3){return}
if(this.$43j){this.$43k=true;return}
if(this.pickList!=null&&this.pickList.formItem==this&&isc.isA.ResultSet(this.pickList.data)&&this.pickList.data.allRowsCached())
{return}
this.invokeSuper(isc.ComboBoxItem,"$43f",_1)},isc.A.$17b=function isc_ComboBoxItem__mapKey(_1,_2,_3,_4,_5,_6){var _7=this.invokeSuper(isc.ComboBoxItem,"$17b",_1,true,_3,_4,_5,_6);if(_7==null&&this.getDisplayFieldName()!=null){var _8=this.$19o(_1,false),_9;if(_8!==_9){_7=_8}else if(this.specialValues){var _10=this.specialValues;if(isc.isA.String(_10))_10=this.getGlobalReference(_10);if(!isc.isAn.Array(_10)){if(isc.PickList.emptyStoredValue&&_1===null){_1=isc.PickList.emptyStoredValue}
if(_10[_1]!==_9)_7=_10[_1]}}}
if(_7==null&&!_2)_7=_1;return _7},isc.A.mapDisplayToValue=function isc_ComboBoxItem_mapDisplayToValue(_1,_2,_3,_4){if(this.$66x){for(var i in this.$66x){if(i==_1){return this.$66x[i]}}
delete this.$66x}
if(this.getDisplayFieldName()!=null){var _6;_6=(_1==this.emptyDisplayValue)?null:this.$19o(_1,true);if(_6!=null)_1=_6}
return this.invokeSuper(isc.ComboBoxItem,"mapDisplayToValue",_1,_2,_3,_4)},isc.A.$85m=function isc_ComboBoxItem__shouldAllowExpressions(){return false},isc.A.$17h=function isc_ComboBoxItem__getAutoCompleteSetting(){return this.$27r});isc.B._maxIndex=isc.C+79;isc.ComboBoxItem.registerStringMethods({dataArrived:"startRow,endRow,data",getPickListFilterCriteria:""});isc.defineClass("BoundDSFieldPicker","ComboBoxItem");isc.A=isc.BoundDSFieldPicker.getPrototype();isc.A.width="*";isc.A.addUnknownValues=false;isc.A=isc.BoundDSFieldPicker.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.init=function isc_BoundDSFieldPicker_init(){if(this.requiresDSField){var _1=this.requiresDSField,_2=this.form.getValues(),_3=_2[_1];if(_3){var _4=isc.DS.get(_3),_5=_4.getFieldNames();this.valueMap=_5}}else{this.logInfo("BoundDSFieldPicker specified without a requiresDSField attribute")}
this.Super("init",arguments)});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("MultiComboBoxItem","CanvasItem");isc.A=isc.MultiComboBoxItem;isc.A.FLOW="flow";isc.A.FLOW_REVERSE="flowReverse";isc.A.HORIZONTAL="horizontal";isc.A.HORIZONTAL_REVERSE="horizontalReverse";isc.A.VERTICAL="vertical";isc.A.VERTICAL_REVERSE="verticalReverse";isc.A.$96a="$96b";isc.A.defaultHint="Enter values";isc.A=isc.MultiComboBoxItem;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$96d=isc.Array.$96d;isc.B.push(isc.A.$96c=function isc_c_MultiComboBoxItem__binarySearch(_1,_2,_3,_4){if(!_3){_3=isc.MultiComboBoxItem.$96d}
var _5;if(_4===_5){_4=true}
return isc.Array.$96c(_2,_1,_3,_4)},isc.A.$96e=function isc_c_MultiComboBoxItem__transferMember(_1,_2,_3,_4,_5){var _6=_1.getMember(_2);if(_1.Class=="FlowLayout"||_3.Class=="FlowLayout"){_1.removeMember(_6,_5)}
_3.addMember(_6,_4,_5)},isc.A.$96f=function isc_c_MultiComboBoxItem__transferMembers(_1,_2,_3,_4,_5,_6){var _7=isc.MultiComboBoxItem.$96e;for(var i=0;i<_1;++i){_7(_2,_3,_4,_5+i,_6)}},isc.A.$96g=function isc_c_MultiComboBoxItem__transferMembersReverse(_1,_2,_3,_4,_5,_6){var _7=isc.MultiComboBoxItem.$96e;for(var i=0;i<_1;++i){_7(_2,_3+(_1-i-1),_4,_5+i,_6)}},isc.A.isOrderReversedForStyle=function isc_c_MultiComboBoxItem_isOrderReversedForStyle(_1){return _1==isc.MultiComboBoxItem.HORIZONTAL||_1==isc.MultiComboBoxItem.FLOW_REVERSE||_1==isc.MultiComboBoxItem.VERTICAL_REVERSE});isc.B._maxIndex=isc.C+5;isc.A=isc.MultiComboBoxItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.shouldSaveValue=true;isc.A.autoDestroy=true;isc.A.addUnknownValues=false;isc.A.alwaysExitOnTab=true;isc.A.autoFetchData=false;isc.A.comboBoxDefaults={name:"cb",_autoAssignedName:true,showTitle:false,width:"*",hint:isc.MultiComboBoxItem.defaultHint,showHintInField:true,completeOnTab:false,completeOnEnter:false,fetchValueOnTab:true,fetchValueOnEnter:true,loadingDisplayValue:null,clearEnteredValuePendingReply:true,shouldSaveValue:false,editorType:"ComboBoxItem",getTitle:function(){var _1=this.creator;return _1.getTitle.apply(_1,arguments)},handleKeyDown:function(_1,_2,_3){var _4=isc.EH.lastEvent.keyName,_5=_4==this.$jf;if(!this.hasFocus||this.isReadOnly()||!_5||this.creator.alwaysExitOnTab)
{return this.Super("handleKeyDown",arguments)}
var _6=this.pickList,_7=this.$128z(),_8=this.getEnteredValue(),_9=this.getDisplayFieldName(),_10=this.shouldFetchMissingDisplayValue(_8),_11=this.$1282()||this.$82q();if(_9!=null&&!_11&&_6&&(isc.isA.ResultSet&&isc.isA.ResultSet(_6.data))&&_6.data.localData&&_6.data.allMatchingRowsCached())
{_10=false;var _12=_6.data,_13=_12.localData.find(_9,_8);if(_13!=null)this.$953(_13)}
if(!this.creator.addUnknownValues){var _14;if(!_10&&(_14=this.mapDisplayToValue(_8))!=null)
{this.$10y(_8,true);if(_6)_6.hide()}}else{if(_10){this.$128v(_8);if(this.clearEnteredValuePendingReply){this.setElementValue("")}}else{this.$10y(_8,true)}
if(_6)_6.hide()}
this.invokeSuper(isc.ComboBoxItem,"handleKeyDown",_1,_2,_3);return false},changed:function(_1,_2){this.creator.$96p(_1,_2)},blur:function(_1,_2){this.creator.$161g(_1,_2,false)},focus:function(_1,_2){this.creator.$161g(_1,_2,true)}};isc.A.comboFormDefaults={_constructor:"DynamicForm",autoParent:"none",numCols:1,cellPadding:0,writeFormTag:false};isc.A.valueLayoutDefaults={tileMargin:0,layoutMargin:0};isc.A.buttonConstructor="IButton";isc.A.buttonDefaults={canHover:true,align:"left",icon:"[SKIN]actions/remove.png",iconAlign:"right",iconOrientation:"right",click:function(){this.creator.$1289(this)},hover:function(){this.creator.$wb();return false},focusChanged:function(_1){this.creator.$161h(this,_1)}};isc.A.pendingButtonStyle="buttonPending";isc.A.deselectedButtonStyle="buttonDeselected";isc.A.layoutStyle=isc.MultiComboBoxItem.FLOW;isc.A.comboBoxWidth=130;isc.A.useInsertionOrder=true;isc.B.push(isc.A.sortOrder=function isc_MultiComboBoxItem_sortOrder(_1,_2){var _3=this.getDisplayFieldName(),a=_1[_3],b=_2[_3];return isc.MultiComboBoxItem.$96d(a,b)});isc.B._maxIndex=isc.C+1;isc.A=isc.MultiComboBoxItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.loadingDisplayValue=null;isc.A.$77l="button";isc.A.$131u="$131v";isc.A.$161u="$161v";isc.B.push(isc.A.init=function isc_MultiComboBoxItem_init(){this.multiple=true;this.autoTrimMultipleValues=false;this.$161a=isc.Set.create();this.fetchMissingValues=true;if(this.value==null&&this.defaultValue!=null){this.value=this.defaultValue}
this.$96h=[];this.$96i=[];this.$96j={};this.$96k=[];return this.Super("init",arguments)},isc.A.setAddUnknownValues=function isc_MultiComboBoxItem_setAddUnknownValues(_1){var _2=this.addUnknownValues;this.addUnknownValues=_1;if(this.comboBox!=null&&_2!=_1){this.comboBox.setAddUnknownValues(_1);this.setValue(null);if(_1)this.invalidateDisplayValueCache()}},isc.A.$89y=function isc_MultiComboBoxItem__getCanvasTabDescendents(_1,_2){var _3=(this.alwaysExitOnTab||!this.$134m());if(!_3){this.Super("$89y",[this.comboForm,_2],arguments)}
if(this.useInsertionOrder){var k=0,_5=this.$96h.length;for(;k<_5;++k){var _6=this.$96s(k,false);_2.add(this.$96u.getMember(_6))}}else{var j=0,_8=this.$96i.length;for(;j<_8;++j){var _6=this.$96s(false,j);_2.add(this.$96u.getMember(_6))}}
if(_3){this.Super("$89y",[this.comboForm,_2],arguments)}},isc.A.$161i=function isc_MultiComboBoxItem__isStoredValueReverseOfButtonValues(){var _1=this.layoutStyle,_2=this.isRTL();return(this.useInsertionOrder&&((_1===isc.MultiComboBoxItem.FLOW&&!_2)||(_1===isc.MultiComboBoxItem.FLOW_REVERSE&&_2)||(_1===isc.MultiComboBoxItem.HORIZONTAL&&!_2)||(_1===isc.MultiComboBoxItem.HORIZONTAL_REVERSE&&_2)||_1===isc.MultiComboBoxItem.VERTICAL_REVERSE))},isc.A.$96l=function isc_MultiComboBoxItem__storeValue(){var _1=!!this.pendingStatus;var _2;if(this.useInsertionOrder){_2=this.$96h.duplicate();if(this.$161i()){_2.reverse()}}else{_2=this.$96i.duplicate()}
if(this.deselectedButtonStyle!=null&&this.$161r()){var _3=this.$96j;for(var _4=_2.length;_4>0;--_4){var _5=_2[_4-1],_6=_3[_5];if(_6.$161w){_2.removeAt(_4-1)}}}
this.storeValue(_2);if(_1&&!!this.pendingStatus)this.$161j()},isc.A.$96m=function isc_MultiComboBoxItem__createButtonForValue(_1,_2){var _3={title:_2,width:1,overflow:"hidden"};if(!this.$96o()){_3.width=this.canvas.getWidth()}else{_3.overflow="visible"}
var _4=this.createAutoChild(this.$77l,_3,isc.IButton);this.$96j[_1]=_4;_4[isc.MultiComboBoxItem.$96a]=_1;return _4},isc.A.$96p=function isc_MultiComboBoxItem__comboBoxItemChanged(_1,_2){var _3=_2.getValue();if(_3==null||isc.isAn.emptyString(_3))return;if(!_2.$19m()){if(this.$96r(_3))this.$96l()}else{var _4=this.comboBox.$847,_5=this.getValueFieldName(),_6=(_4==null?null:_4.find(_5,_3));if(_6==null&&this.addUnknownValues){_6={};_6[_5]=_3;var _7=this.getDisplayFieldName();if(_7)_6[_7]=_3}
if(_6!=null){var _8=this.$953(_6);this.updateDisplayValueMap(false);if(this.$96r(_3))this.$96l()}}
_2.clearValue()},isc.A.$161g=function isc_MultiComboBoxItem__comboBoxItemFocusChanged(_1,_2,_3){var _4=this.form,_5=this.ns.EH.getFocusCanvas();if(_5!=null&&this.canvas.contains(_5,true)){if(_4.getFocusSubItem()!==this){_4.setFocusItem(this);this.elementFocus()}}else{this.elementBlur();if(_4.getFocusSubItem()===this)_4.setFocusItem(null)}},isc.A.$134m=function isc_MultiComboBoxItem__isComboFormFirst(){var _1=this.useInsertionOrder,_2=this.layoutStyle;return(_1&&_2==isc.MultiComboBoxItem.HORIZONTAL)||_2==isc.MultiComboBoxItem.FLOW_REVERSE||_2==isc.MultiComboBoxItem.HORIZONTAL_REVERSE||_2==isc.MultiComboBoxItem.VERTICAL||(_1&&_2==isc.MultiComboBoxItem.VERTICAL_REVERSE)},isc.A.$96s=function isc_MultiComboBoxItem__transformIndex(_1,_2,_3){var _4=this.useInsertionOrder,_5=this.layoutStyle,_6=this.$96h.length,_7;if(_4){if(_5==isc.MultiComboBoxItem.FLOW||_5==isc.MultiComboBoxItem.FLOW_REVERSE){_7=_6-_1-1;if(_3){++_7}}else{_7=_1}}else{_7=_2}
if(this.$134m()){++_7}
return _7},isc.A.$96t=function isc_MultiComboBoxItem__getSortOrder(){var _1=this.getValueMap();if(_1==null&&this.getOptionDataSource()!=null){var _2=this,_3=this.getValueFieldName();return function(_9,_10){var _4=_2.$847,_5=(_4==null?null:_4.find(_3,_9)),_6=(_4==null?null:_4.find(_3,_10));if(_5==null||_6==null){var _7=_2.getOptionDataSource(),_8=(_7==null?null:_7.getCacheData());if(_8!=null){if(_5==null)_5=_8.find(_3,_9);if(_6==null)_6=_8.find(_3,_10)}}
return _2.sortOrder.call(_2,_5,_6)}}else{return isc.MultiComboBoxItem.$96d}},isc.A.$96r=function isc_MultiComboBoxItem__insertButtonForValue(_1){var _2=this.$96t();var j=isc.MultiComboBoxItem.$96c(_1,this.$96i,_2),_4=(j>=0),_5=false;if(!_4){j=-(j+1);var _6=this.getDisplayValue(_1),_7=this.$96m(_1,_6),_8=this.$96s(0,j,true);this.$96h.unshift(_1);this.$96i.addAt(_1,j);this.$96u.addMember(_7,_8)}else{var _8=this.$96s(!this.useInsertionOrder||this.$96h.indexOf(_1),j,false);var _9=this.$96u.getMember(_8);if(!_9.$161w){_9.animateFade(50,function(){_9.animateFade(100,null,100)},100)}else{_5=true;_9.$161w=false;_9.enable();_9.setBaseStyle(this.$161x());if(isc.Canvas.ariaEnabled())_9.setAriaState("hidden",!_9.isVisible())}}
return!_4||_5},isc.A.$1289=function isc_MultiComboBoxItem__buttonClick(_1){if(this.isReadOnly()){return}
var _2=_1.hasFocus,_3=_1[isc.MultiComboBoxItem.$96a],_4=this.$96t(),j=isc.MultiComboBoxItem.$96c(_3,this.$96i,_4),k=this.$96h.indexOf(_3);var _7=this.deselectedButtonStyle;if(_7!=null&&this.$161r()&&this.$161a.has(_3)){_1.disable();_1.setBaseStyle(_7);_1.$161w=true}else{delete this.$96j[_3];var _8=this.$96u;_8.hideMember(_1,{target:this,methodName:this.$131u,args:[_8,_1]});this.$955(_3);this.updateDisplayValueMap(false);this.$96h.splice(k,1);this.$96i.splice(j,1)}
if(isc.Canvas.ariaEnabled()&&!_1.destroyed)_1.setAriaState("hidden",true);if(_2){var _9=this.$96h.length;if(_9>0){var _10;if(this.useInsertionOrder){var _11=Math.max(0,k-1),_10=this.$96j[this.$96h[_11]]}else{var _12=Math.min(j,_9-1),_10=this.$96j[this.$96i[_12]]}
_10.focus()}else{this.comboBox.focusInItem()}}
this.$96l()},isc.A.$161h=function isc_MultiComboBoxItem__buttonFocusChanged(_1,_2){var _3=this.form,_4=(_2?_1:this.ns.EH.getFocusCanvas());if(_4!=null&&this.canvas.contains(_4,true)){if(_3.getFocusSubItem()!==this){_3.setFocusItem(this);this.elementFocus()}}else{this.elementBlur();if(_3.getFocusSubItem()===this)_3.setFocusItem(null)}},isc.A.$131v=function isc_MultiComboBoxItem__finishedHidingButton(_1,_2){_1.removeMember(_2,true);_2.destroy()},isc.A.$161v=function isc_MultiComboBoxItem__finishedHidingButtons(_1,_2){_1.removeMembers(_2,true);_2.callMethod("destroy")},isc.A.$96v=function isc_MultiComboBoxItem__removeAllButtons(){var _1=this.$96u;if(this.layoutStyle===isc.MultiComboBoxItem.FLOW||this.layoutStyle==isc.MultiComboBoxItem.FLOW_REVERSE){var _2;if(this.$134m()){_2=_1.tiles.slice(1)}else{_2=_1.tiles.slice(0,-1)}
for(var _3=_2.length;_3>0;--_3){var _4=_2[_3-1];_1.removeTile(_4);_4.destroy()}}else{var _5;if(this.$134m()){_5=_1.members.slice(1)}else{_5=_1.members.slice(0,-1)}
_1.removeMembers(_5,true);_5.callMethod("destroy")}
if(!this.isDrawn()){this.invalidateDisplayValueCache(false)}
this.$96j={};this.$96h=[];this.$96i=[];this.$96k=[]},isc.A.drawn=function isc_MultiComboBoxItem_drawn(){var _1=this.Super("drawn",arguments),_2;if(this.$96w!==_2){var _3=this.getDisplayValue(this.$96w);this.showValue(_3,this.$96w,this.form,this);delete this.$96w}
return _1},isc.A.redrawn=function isc_MultiComboBoxItem_redrawn(){var _1=this.Super("redrawn",arguments);var _2=this.comboBox;if(_2!=null&&isc.screenReader)_2.addContentRoles();return _1},isc.A.showValue=function isc_MultiComboBoxItem_showValue(_1,_2,_3,_4){if(!this.isDrawn()){this.$96w=_2}else if(!_2){this.$96v()}else if(isc.isAn.Array(_2)){this.$96v();for(var i=0,_6=_2.length;i<_6;++i){var _7=_2[i];if(this.$959(_7)){this.$96r(_7,_1[i])}else{this.$96k.push(_7)}}}},isc.A.$959=function isc_MultiComboBoxItem__isValueInCache(_1){return(!this.optionDataSource||(this.$17b(_1,true)!==null))},isc.A.$849=function isc_MultiComboBoxItem__refreshForDisplayValueChange(){return this.comboBox.$849.apply(this.comboBox,arguments)},isc.A.setValueMap=function isc_MultiComboBoxItem_setValueMap(_1){this.Super("setValueMap",arguments);this.comboBox.setValueMap.apply(this.comboBox,arguments)},isc.A.updateValueMap=function isc_MultiComboBoxItem_updateValueMap(_1){this.Super("updateValueMap",false);if(_1){var _2=this.$96t(),_3=this.$96o(),_4=this.useInsertionOrder,_5=this.$96h.length;var _6=this.canvas.getWidth();var _7=[];for(var i=0;i<_5;++i){var _9=this.$96h[i],_10=this.getDisplayValue(_9),j=isc.MultiComboBoxItem.$96c(_9,_7,_2),_12=this.$96j[_9];_12.setTitle(_10);if(!_3){_12.setWidth(_6)}
_12.setAutoFit(_3);_7.addAt(_9,-(j+1))}
var _13=this.$96i;this.$96i=_7;if(!_4){var _14=this.$96u,_15;for(var i=0;i<_5;++i){var _9=_13[i],j=_7.indexOf(_9);if(i!=j){_14.reorderMember(this.$96s(_15,i,false),this.$96s(_15,j,false))}}}
if(!this.$96k.isEmpty()){var _16=this.$96k.length,_17=0;for(var i=0;i<_16;++i){var j=i-_17,_9=this.$96k[j];if(this.$959(_9)){var _10=this.getDisplayValue(_9);this.$96r(_9,_10);this.$96k.splice(j,1);++_17}}}}},isc.A.setLayoutStyle=function isc_MultiComboBoxItem_setLayoutStyle(_1){var _2=this.layoutStyle;if(!_1||(_2==_1)){return}
var _3=isc.MultiComboBoxItem.FLOW,_4=isc.MultiComboBoxItem.FLOW_REVERSE,_5=isc.MultiComboBoxItem.HORIZONTAL,_6=isc.MultiComboBoxItem.HORIZONTAL_REVERSE,_7=isc.MultiComboBoxItem.VERTICAL,_8=isc.MultiComboBoxItem.VERTICAL_REVERSE,_9=isc.MultiComboBoxItem.$96e,_10=isc.MultiComboBoxItem.$96f,_11=isc.MultiComboBoxItem.$96g,_12=this.useInsertionOrder,_13=this.comboBoxWidth,_14=true,_15=this.$96h.length,_16=_2==_5||_2==_4||_2==_8,_17=isc.MultiComboBoxItem.isOrderReversedForStyle(_1),_18=(_12?_11:_10);if(_1==_3||_1==_4){if(!isc.FlowLayout){isc.Log.logWarn("The ISC_Grids module must be loaded to use layoutStyle:\"flow\".  The MultiComboBoxItem will continue to use the \""+_2+"\" layout style.");return}
var _19=this.$96x(),_20=_19.animateTileChange;_19.animateTileChange=false;_9(this.$96u,(!_12&&_16?_15:0),_19,0,_14);_18(_15,this.$96u,0,_19,0,_14);this.canvas.removeMember(0,_14);this.$96u.destroy();this.$96u=_19;this.canvas.addMember(_19,0,_14)}else if(_1==_5||_1==_6||_1==_7||_1==_8)
{var _21=(_1==_5||_1==_6),_22=(_2==_5||_2==_6),_23=(_21?this.$96y:this.$96z);if(_2==_3||_2==_4||(_21!=_22))
{var _19=_23.call(this);if(_2==_3||_2==_4){this.$96u.animateTileChange=false;_9(this.$96u,_15,_19,0,_14);_18(_15,this.$96u,0,_19,(!_12&&_17?0:1),_14)}else if(_12||(_16==_17)){_10(_15+1,this.$96u,0,_19,0,_14)}else{_9(this.$96u,(_16?_15:0),_19,0,_14);_10(_15,this.$96u,0,_19,(_16?1:0),_14)}
this.canvas.removeMember(this.$96u,_14);this.$96u.destroy();this.$96u=_19;this.canvas.addMember(_19,0,_14);if(_12&&_17){this.$96u.reverseOrder=true;this.$96u.reflow()}}else if(_12){if(_17!=_16){this.$96u.reverseOrder=_17;this.$96u.reflow()}}else{if(!_17){_9(this.$96u,_15,this.$96u,0,_14)}else{_9(this.$96u,0,this.$96u,_15,_14)}}}else{return}
this.layoutStyle=_1;this.comboForm.setWidth(_1==_7||_1==_8?"100%":_13);this.$960(this.$96o(_1));var _24;if(_20!==_24){_19.animateTileChange=_20}},isc.A.destroy=function isc_MultiComboBoxItem_destroy(){if(this.comboForm)this.comboForm.destroy();if(this.$96u)this.$96u.destroy();this.Super("destroy",arguments)},isc.A.handleEditorExit=function isc_MultiComboBoxItem_handleEditorExit(){var _1=this.$843;this.$843=true;var _2=this.Super("handleEditorExit",arguments);this.$843=_1;return _2},isc.A.$960=function isc_MultiComboBoxItem__setAutoFitButtons(_1){var _2=this.$96u;if(!_2)return;var _3=_2.getMembersLength(),_4=this.canvas.getWidth();for(var i=0;i<_3;i++){var _6=_2.getMember(i);if(isc.isA.StatefulCanvas(_6)){if(!_1)_6.setWidth(_4);_6.setAutoFit(_1)}}},isc.A.setAutoFitButtons=function isc_MultiComboBoxItem_setAutoFitButtons(_1){var _2=this.$96o(),_3=this.$96o(null,_1);this.autoFitButtons=_1;if(_2!=_3){this.$960(_3)}},isc.A.$18y=function isc_MultiComboBoxItem__createCanvas(){if((this.layoutStyle==isc.MultiComboBoxItem.FLOW||this.layoutStyle==isc.MultiComboBoxItem.FLOW_REVERSE)&&!isc.FlowLayout){isc.Log.logWarn("The ISC_Grids module must be loaded to use layoutStyle:\"flow\".  The MultiComboBoxItem will default to using the \""+isc.MultiComboBoxItem.VERTICAL_REVERSE+"\" layout style.");this.layoutStyle=isc.MultiComboBoxItem.VERTICAL_REVERSE}
var _1;if(this.layoutStyle==isc.MultiComboBoxItem.FLOW||this.layoutStyle==isc.MultiComboBoxItem.FLOW_REVERSE||this.layoutStyle==isc.MultiComboBoxItem.HORIZONTAL||this.layoutStyle==isc.MultiComboBoxItem.HORIZONTAL_REVERSE)
{_1=this.comboBoxWidth}else{_1="100%"}
var _2=isc.addProperties({ID:this.ID+isc.$ag+"comboBox"},this.comboBoxDefaults,this.comboBoxProperties,{creator:this,optionDataSource:this.optionDataSource,autoFetchData:this.autoFetchData,valueMap:this.valueMap,displayField:this.displayField,valueField:this.valueField,addUnknownValues:this.addUnknownValues,changeOnKeypress:!this.addUnknownValues});var _3=this.addAutoChild("comboForm",{width:_1,items:[_2],visibility:this.renderAsReadOnly()||this.renderAsStatic()?isc.Canvas.HIDDEN:isc.Canvas.INHERIT,readOnlyDisplay:this.getReadOnlyDisplay(),canEdit:this.getCanEdit()});var _4=this.comboBox=_3.getItem(0);var _5=isc.addProperties({},this.canvasDefaults,this.canvasProperties,{autoDraw:false,height:1});var _6=isc.MultiComboBoxItem.isOrderReversedForStyle(this.layoutStyle);if(this.layoutStyle==isc.MultiComboBoxItem.HORIZONTAL||this.layoutStyle==isc.MultiComboBoxItem.HORIZONTAL_REVERSE){this.$96u=this.$96y();this.$96u.reverseOrder=_6}else if(this.layoutStyle==isc.MultiComboBoxItem.VERTICAL||this.layoutStyle==isc.MultiComboBoxItem.VERTICAL_REVERSE)
{var _7=this.width;if(_7!=null&&!_5.width){if(isc.isA.Number(_7))_7-=this.$141();_5.width=_7}
this.$96u=this.$96z();this.$96u.reverseOrder=_6}else if(this.layoutStyle==isc.MultiComboBoxItem.FLOW||this.layoutStyle==isc.MultiComboBoxItem.FLOW_REVERSE){this.$96u=this.$96x();this.$96u.reverseOrder=_6}
this.$96u.addMember(_3);_5.members=[this.$96u];this.canvas=isc.HLayout.create(_5);this.Super("$18y",arguments)},isc.A.$161x=function isc_MultiComboBoxItem__getNormalButtonStyle(){var _1,_2;if((_1=this.buttonProperties)!=null&&(_2=_1.baseStyle)!=null)
{return _2}else if((_1=this.buttonDefaults)!=null&&(_2=_1.baseStyle)!=null)
{return _2}else{var _3=isc.ClassFactory.getClass(this.getAutoChildClass(this.$77l,isc.IButton));return _3.$b4.baseStyle}},isc.A.$161j=function isc_MultiComboBoxItem__updatePendingStyles(){if(!this.$161p())return;var _1=this.pendingButtonStyle;if(_1==null)return;var _2=this.$161x();if(_1===_2)return;var _3=this.$96u;if(!this.pendingStatus){if(this.useInsertionOrder){var _4=this.$96h,_5=_4.length;for(var k=0;k<_5;++k){_3.getMember(this.$96s(k,false,false)).setBaseStyle(_2)}}else{var _7=this.$96i,_8=_7.length;for(var j=0;j<_8;++j){_3.getMember(this.$96s(false,j,false)).setBaseStyle(_2)}}}else{var _10=this.$160w();var _11;if(_10==null)_11=0;else if(!isc.isAn.Array(_10)){_10=[_10];_11=1}else{_11=_10.length}
if(this.useInsertionOrder){var _4=this.$96h,_5=_4.length,_12=this.$161i();var i=0,k;for(;i<_11&&i<_5;++i){k=_12?_5-1-i:i;if(!isc.DynamicForm.compareValues(_10[i],_4[k]))break;var _14=_3.getMember(this.$96s(k,false,false));if(!_14.$161w)_14.setBaseStyle(_2)}
for(;i<_5;++i){k=_12?_5-1-i:i;_3.getMember(this.$96s(k,false,false)).setBaseStyle(_1)}}else{var _7=this.$96i,_8=_7.length,_15=this.$96t();var i=0,j=0;while(i<_11&&j<_8){var _16=_15(_10[i],_7[j]);if(_16<0){++i}else if(_16==0){var _14=_3.getMember(this.$96s(false,j,false));if(!_14.$161w)_14.setBaseStyle(_2);++i;++j}else{_3.getMember(this.$96s(false,j,false)).setBaseStyle(_1);++j}}
for(;j<_8;++j){_3.getMember(this.$96s(false,j,false)).setBaseStyle(_1)}}}},isc.A.$1607=function isc_MultiComboBoxItem__pendingStatusChanged(_1){if(!_1){var _2=this.$161a;_2.clear();var _3=this._value;if(isc.isAn.Array(_3)){var _4=_3.length;for(var i=0;i<_4;++i){_2.add(_3[i])}}else{_2.add(_3)}
if(this.deselectedButtonStyle!=null&&this.$161r()){var _6=[],_7=this.$96u;if(this.layoutStyle===isc.MultiComboBoxItem.FLOW||this.layoutStyle===isc.MultiComboBoxItem.FLOW_REVERSE){var _8=_7.tiles,_9=_8.length;for(var _10=_9-1;_10>0;--_10){var _11=_8[_10-1];if(_11.$161w)_6.add(_11)}}else{var _12;if(this.$134m()){_12=_7.members.slice(1)}else{_12=_7.members.slice(0,-1)}
for(var i=0,_13=_12.length;i<_13;++i){var _11=_12[i];if(_11.$161w)_6.add(_11)}}
var _14=_6.length;if(_14>0){_7.hideMembers(_6,{target:this,methodName:this.$161u,args:[_7,_6]});var _15=this.$96t(),_16=this.$96j;for(var i=0;i<_14;++i){var _11=_6[i],_3=_11[isc.MultiComboBoxItem.$96a],j=isc.MultiComboBoxItem.$96c(_3,this.$96i,_15),k=this.$96h.indexOf(_3);delete _16[_3];this.$955(_3);this.updateDisplayValueMap(false);this.$96h.splice(k,1);this.$96i.splice(j,1)}}}}
this.Super("$1607",arguments)},isc.A.$1608=function isc_MultiComboBoxItem__defaultPendingStatusChangedBehavior(_1){this.Super("$1608",arguments);this.$161j()},isc.A.$152r=function isc_MultiComboBoxItem__canEditChanged(_1){if((this.canEditChanged==null||this.canEditChanged(_1)!=false)&&this.canvas!=null)
{this.comboForm.setCanEdit(_1);this.comboForm.setVisibility(this.renderAsReadOnly()||this.renderAsStatic()?isc.Canvas.HIDDEN:isc.Canvas.INHERIT);this.canvas.setDisabled(this.shouldDisableCanvas())}},isc.A.$152p=function isc_MultiComboBoxItem__readOnlyDisplayChanged(_1){if((this.readOnlyDisplayChanged==null||this.readOnlyDisplayChanged(_1)!=false)&&this.canvas!=null)
{this.comboForm.setReadOnlyDisplay(_1);this.comboForm.setVisibility(this.renderAsReadOnly()||this.renderAsStatic()?isc.Canvas.HIDDEN:isc.Canvas.INHERIT)}},isc.A.$96o=function isc_MultiComboBoxItem__getAutoFitButtons(_1,_2){var _2=_2||this.autoFitButtons,_1=_1||this.layoutStyle;if(_1==isc.MultiComboBoxItem.HORIZONTAL||_1==isc.MultiComboBoxItem.HORIZONTAL_REVERSE)
{return true}else if(this.autoFitButtons!=null){return this.autoFitButtons}else if(_1==isc.MultiComboBoxItem.FLOW||this.layoutStyle===isc.MultiComboBoxItem.FLOW_REVERSE){return true}else{return false}},isc.A.$96y=function isc_MultiComboBoxItem__createHStack(){return isc.HStack.create(this.valueLayoutDefaults,this.valueLayoutProperties,{creator:this,autoDraw:false,canFocus:false,canHover:true,height:1,members:[],animateMembers:true,animateMemberTime:100,hover:function(){this.creator.$wb();return false}})},isc.A.$96z=function isc_MultiComboBoxItem__createVStack(){return isc.VStack.create(this.valueLayoutDefaults,this.valueLayoutProperties,{creator:this,autoDraw:false,canFocus:false,canHover:true,height:1,members:[],animateMembers:true,animateMemberTime:100,hover:function(){this.creator.$wb();return false}})},isc.A.$96x=function isc_MultiComboBoxItem__createFlowLayout(){return isc.FlowLayout.create(this.valueLayoutDefaults,this.valueLayoutProperties,{creator:this,autoDraw:false,canFocus:false,canHover:true,tiles:[],height:1,animateTileChange:false,overflow:"visible",getMember:function(_7){return this.getTile(_7)},getMemberNumber:function(_7){if(isc.isA.Number(_7)){return _7}
var _1=this.getLength();for(var i=0;i<_1;++i){if(_7===this.getTile(i)){return i}}
return-1},getMembers:function(){var _3=[],_4=this.getLength();for(var i=0;i<_4;++i){var _5=this.getTile(i);_3.add(_5)}
return _3},getMembersLength:function(_7){return this.getLength()},addMember:function(_7,_8){this.addTile(_7,_8);this.layoutTiles()},removeMember:function(_7){this.removeTile(_7)},removeMembers:function(_7){var _6=_7.length;for(var i=0;i<_6;++i){this.removeTile(_7[i])}},hideMember:function(_7,_8){_7.hide();this.fireCallback(_8)},hideMembers:function(_7,_8){_7.callMethod("hide");this.fireCallback(_8)},reorderMember:function(_7,_8){if(_7!=_8){var _5=this.getTile(_7);this.removeMember(_5);this.addMember(_5,_8)}},hover:function(){this.creator.$wb();return false}})});isc.B._maxIndex=isc.C+40;isc.ClassFactory.defineClass("FileItem","CanvasItem");isc.A=isc.FileItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.shouldSaveValue=true;isc.A.$105m=true;isc.A.multiple=true;isc.A.editFormConstructor="DynamicForm";isc.A.editFormDefaults={numCols:1,colWidths:["*"],autoDraw:false,cellPadding:0,_redrawWithParent:false,redrawOnResize:false,canSubmit:true,getSaveOperationType:function(){if(this.targetItem&&this.targetItem.form)
return this.targetItem.form.getSaveOperationType();return this.Super("getSaveOperationType",arguments)}};isc.A.uploadItemConstructor=isc.TUploadItem||isc.UploadItem;isc.A.displayFormConstructor="DynamicForm";isc.A.displayFormDefaults={autoDraw:false,_redrawWithParent:false,redrawOnResize:false,canSubmit:true};isc.A.displayItemConstructor="StaticTextItem";isc.A.displayCanvasConstructor="Canvas";isc.A.$12f="blob";isc.B.push(isc.A.setMultiple=function isc_FileItem_setMultiple(_1){this.multiple=_1;if(this.isDrawn())this.redraw()},isc.A.$18y=function isc_FileItem__createCanvas(){if(!isc.isA.Canvas(this.canvas)){this.$861=this.isReadOnly();this.canvas=(this.$861?this.$862():this.$863())}
this.containerWidget.addChild(this.canvas)},isc.A.$862=function isc_FileItem__createReadOnlyCanvas(){var _1={},_2;if(this.type==this.$12f){_1=isc.addProperties({width:"100%",height:10},this.displayFormDefaults,this.displayFormProperties,{action:this.action,targetItem:this,items:[isc.addProperties({},this.displayItemDefaults,this.displayItemProperties,{type:"text",editorType:this.displayItemConstructor,width:this.width,height:"*",name:this.getFieldName(),showTitle:false})]});var _3=isc.isA.Class(this.displayFormConstructor)?this.displayFormConstructor:isc[this.displayFormConstructor];_2=this.displayForm=_3.create(_1)}else{_1=isc.addProperties({width:"100%",height:10,visibility:"hidden"},this.displayCanvasDefaults,this.displayCanvasProperties);var _3=isc.isA.Class(this.displayCanvasConstructor)?this.displayCanvasConstructor:isc[this.displayCanvasConstructor];_2=this.displayCanvas=_3.create(_1)}
return _2},isc.A.$863=function isc_FileItem__createEditableCanvas(){var _1=isc.addProperties({},this.editFormDefaults,this.editFormProperties,{action:this.action,targetItem:this,addOperation:this.form.addOperation,updateOperation:this.form.updateOperation,removeOperation:this.form.removeOperation,fetchOperation:this.form.fetchOperation,items:[isc.addProperties({},this.uploadItemDefaults,this.uploadItemProperties,{name:this.getFieldName(),showTitle:false,targetItem:this,editorType:this.uploadItemConstructor,width:isc.isA.Number(this.width)?this.width:null,height:isc.isA.Number(this.height)?this.height:null,multiple:this.multiple,accept:this.accept,getElementName:function(){return this.getFieldName()},changed:function(_5,_6,_7){this.targetItem.storeValue(_7)},$17u:function(){var _2=this.targetItem;return _2.$17u.apply(_2,arguments)}}),{name:"_transaction",type:"HiddenItem"}]});var _3=isc.isA.Class(this.editFormConstructor)?this.editFormConstructor:isc[this.editFormConstructor];var _4=this.editForm=_3.create(_1);_4.redrawIfDirty();this.uploadItem=_4.items[0];return _4},isc.A.setElementReadOnly=function isc_FileItem_setElementReadOnly(_1){this.redraw()},isc.A.redraw=function isc_FileItem_redraw(){var _1=this.isReadOnly();if(this.$861!=_1){this.$173n()}else if(this.canvas&&!_1){var _2=this.editForm.getItem(0);if(this.multiple!=_2.multiple){_2==null;this.$173n()}}
this.Super("redraw",arguments)},isc.A.$173n=function isc_FileItem__recreateCanvas(){var _1=this.getValue();if(this.canvas){delete this.canvas.canvasItem;this.canvas.destroy(true)}
this.$861=this.isReadOnly();this.setCanvas(this.$861?this.$862():this.$863());this.setValue(_1)},isc.A.setValue=function isc_FileItem_setValue(_1){if(this.isReadOnly()){var _2=this.form,_3=_2.getValues();if(this.type=="blob"){this.canvas.items[0].setValue(_1)}else{this.setCanvasContent(_1)}
return this.Super("setValue",arguments)}else{if(_1==null||isc.isA.emptyString(_1)){this.canvas.items[0].setValue(_1);return this.Super("setValue",arguments)}
return this.canvas.items[0].setValue(_1)}},isc.A.setCanvasContent=function isc_FileItem_setCanvasContent(_1){var _2=this.getFormRecord();if((this.type=="imageFile"||this.type=="viewFile")&&this.showFileInline!=false){this.canvas.setHeight("*");this.canvas.setWidth("*");this.canvas.setContents(this.getImageHTML()||"&nbsp;")}else{if(this.showFileInline==true){this.logWarn("setValue(): Unsupported field-type for showFileInline: "+this.type)}
this.canvas.setHeight(20);this.canvas.setWidth("*");this.canvas.setContents(this.getViewDownloadHTML(_1,_2)||"&nbsp;")}},isc.A.setWidth=function isc_FileItem_setWidth(_1){if(this.canvas&&!this.isReadOnly()){this.canvas.items[0].setWidth(_1)}
this.Super("setWidth",arguments)},isc.A.setHeight=function isc_FileItem_setHeight(_1){if(this.canvas&&!this.isReadOnly()){this.canvas.items[0].setHeight(_1)}
this.Super("setHeight",arguments)},isc.A.getViewDownloadHTML=function isc_FileItem_getViewDownloadHTML(_1,_2){if(_2==null)return null;var _3=this.form,_4=_3.valuesManager,_5=_3.getDataSource(),_6=_5?_5.getField(this.name):null,_7=(_5?_5.getFilenameField(this.name):null)||this.name+"_filename",_8=_2[_7],_9=_5?_5.getPrimaryKeyFieldNames():null,_10=(_9==null);if(_6&&!_6.filenameSuppressed&&(_8==null||isc.isAn.emptyString(_8))){return this.emptyCellValue}
if(_9){var _11=_4?_4.getValues():_3.getValues();for(var i=0;i<_9.length;i++){var _13=_9[i];if(isc.DynamicForm.$70o(_13,this,_11,_3,true)==null){_10=true;break}}}
if(_10){return this.emptyCellValue}
return"<nobr>"+this.$137i()+"&nbsp;"+this.$137j()+(_8?"&nbsp;"+_8:"")+"</nobr>"},isc.A.$137i=function isc_FileItem__getViewIconSrc(){return isc.Canvas.imgHTML({src:this.viewIconSrc,width:16,height:16,extraCSSText:"cursor:"+isc.Canvas.HAND,extraStuff:" onclick='"+this.getID()+".viewFile()'"})},isc.A.$137j=function isc_FileItem__getDownloadIconSrc(){return isc.Canvas.imgHTML({src:this.downloadIconSrc,width:16,height:16,extraCSSText:"cursor:"+isc.Canvas.HAND,extraStuff:" onclick='"+this.getID()+".downloadFile()'"})},isc.A.getFormDataSource=function isc_FileItem_getFormDataSource(){var _1=this.form.getDataSource()||(this.form.valuesManager?this.form.valuesManager.getDataSource():null);return _1},isc.A.getFormRecord=function isc_FileItem_getFormRecord(){var _1=this.form.valuesManager?this.form.valuesManager.getValues():null;if(!_1||isc.isAn.emptyObject(_1))_1=this.form.getValues();return _1},isc.A.getImageHTML=function isc_FileItem_getImageHTML(){var _1=this.getFormRecord();if(!_1||isc.isAn.emptyObject(_1))return;var _2=this.form.getField(this.name),_3=this.name+"$68c",_4=_1?_1[_3]:null,_5=this.getFormDataSource();if(_4==null&&_5){var _6=isc.Canvas.getFieldImageDimensions(_2,_1);_4=_1[_3]=isc.Canvas.imgHTML(_5.getFileURL(_1,_2.name),_6.width,_6.height,null,null,isc.Canvas.$1625)}
return _4},isc.A.viewFile=function isc_FileItem_viewFile(){isc.DS.get(this.getFormDataSource()).viewFile(this.getFormRecord(),this.name)},isc.A.downloadFile=function isc_FileItem_downloadFile(){isc.DS.get(this.getFormDataSource()).downloadFile(this.getFormRecord(),this.name)},isc.A.$85m=function isc_FileItem__shouldAllowExpressions(){return false});isc.B._maxIndex=isc.C+20;if(isc.ListGrid){isc.ClassFactory.defineClass("RelationItem","CanvasItem");isc.A=isc.RelationItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.canvasConstructor="ListGrid";isc.A.canvasDefaults={canEdit:true};isc.A.pickerConstructor="RelationPicker";isc.A.showEditButton=true;isc.A.editButtonDefaults={click:"item.showPicker(item.showPickerModal(), icon)",prompt:"Edit new/selected item"};isc.A.showRemoveButton=true;isc.A.removeButtonDefaults={src:"[SKIN]DynamicForm/Remove_icon.gif",click:"item.removeSelectedData()",prompt:"Remove selected item"};isc.A.canEditWithNoMasterRecord=false;isc.B.push(isc.A.getValuesComponent=function isc_RelationItem_getValuesComponent(){var _1=this.form,_2=this.form?this.form.valuesManager:null;if(_2!=null)return _2;return _1},isc.A.showPickerModal=function isc_RelationItem_showPickerModal(){var _1=this.getValuesComponent();return _1&&!_1.saveOperationIsAdd()});isc.B._maxIndex=isc.C+2;isc.A=isc.RelationItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.init=function isc_RelationItem_init(){this.hasMasterRecord=false;this.Super("init",arguments);if(this.showEditButton)this.editButton=this.addIcon(this.editButtonDefaults);if(this.showRemoveButton)this.removeButton=this.addIcon(this.removeButtonDefaults)},isc.A.getPickerData=function isc_RelationItem_getPickerData(){var _1=this.canvas.getSelectedRecord();if(_1)return _1;var _2=this.getValuesComponent();return this.getDataSource().getForeignKeysByRelation(_2.getValues(),_2.dataSource)},isc.A.showPicker=function isc_RelationItem_showPicker(_1,_2,_3,_4){if(_3==null)_3={};_3.dataSource=this.dataSource;this.Super("showPicker",[_1,_2,_3,_4],arguments);var _5={};var _6=this.getValuesComponent();if(!_6.saveOperationIsAdd()){_5=this.getDataSource().getForeignKeysByRelation(_6.getValues(),_6.dataSource)}
this.picker.setForeignKeyValues(_5)},isc.A.getValue=function isc_RelationItem_getValue(){return},isc.A.removeSelectedData=function isc_RelationItem_removeSelectedData(){this.canvas.removeSelectedData()},isc.A.setValue=function isc_RelationItem_setValue(){this.delayCall("filterRelation")},isc.A.filterRelation=function isc_RelationItem_filterRelation(){var _1=this.getValuesComponent();var _2=_1.getValues();var _3=this.isDisabled();if(_1.saveOperationIsAdd()){this.canvas.setData([]);this.hasMasterRecord=false}else{var _4=this.getDataSource();if(_4){this.canvas.filterData(_4.getForeignKeysByRelation(_2,_1.dataSource));this.hasMasterRecord=true}}
if(_3!=this.isDisabled()){this.updateDisabled()}
if(this.picker){this.picker.clearData()}},isc.A.isDisabled=function isc_RelationItem_isDisabled(){var _1=this.Super("isDisabled",arguments);if(_1)return true;if(this.canEditWithNoMasterRecord)return false;return!!this.hasMasterRecord},isc.A.$85m=function isc_RelationItem__shouldAllowExpressions(){return false});isc.B._maxIndex=isc.C+9;isc.defineClass("RelationPicker","VLayout");isc.A=isc.RelationPicker.getPrototype();isc.A.className="dialogBackground";isc.A=isc.RelationPicker.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.creatorName="picker";isc.B.push(isc.A.initWidget=function isc_RelationPicker_initWidget(){this.Super("initWidget",arguments);this.addAutoChild("editor",{dataSource:this.dataSource},"DynamicForm");this.addAutoChild("toolbar",{membersMargin:2},"HLayout");this.addAutoChild("saveButton",{title:"Save",click:"this.picker.editor.saveData(this.picker.getID()+'.hide()')"},"AutoFitButton",this.toolbar);this.addAutoChild("clearButton",{title:"Clear",click:"this.picker.clearData();"},"AutoFitButton",this.toolbar);this.addAutoChild("cancelButton",{title:"Cancel",click:"this.picker.hide();this.picker.clearData()"},"AutoFitButton",this.toolbar)},isc.A.hide=function isc_RelationPicker_hide(){this.Super("hide",arguments);this.hideClickMask()},isc.A.setData=function isc_RelationPicker_setData(_1){this.editor.setData(_1)},isc.A.getData=function isc_RelationPicker_getData(){return this.editor.getValues()},isc.A.clearData=function isc_RelationPicker_clearData(){this.editor.clearValues();this.setData(this.foreignKeyValues)},isc.A.dataChanged=function isc_RelationPicker_dataChanged(){},isc.A.setForeignKeyValues=function isc_RelationPicker_setForeignKeyValues(_1){this.foreignKeyValues=_1});isc.B._maxIndex=isc.C+7;}
if(isc.ListGrid){isc.ClassFactory.defineClass("MultiFileItem","RelationItem");isc.A=isc.MultiFileItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.pickerConstructor="MultiFilePicker";isc.A.canvasDefaults={showHeader:false,canHover:true,cellHoverHTML:function(_1,_2,_3){if(this.canvasItem.form.saveOperationIsAdd()){var _4=_1[this.getFieldName(_3)];if(_4&&this.displayShortName){_4=_4.replace(/^.*[\\\/]/,isc.emptyString)}
return _4}},getCellValue:function(_1,_2,_3){var _1=this.Super("getCellValue",arguments);if(this.canvasItem.form.saveOperationIsAdd()){if(!this.displayShortName||!_1)return _1;_1=_1.replace(/.*(\\|\/)/g,isc.emptyString)}
return _1}};isc.A.emptyMessage="Click icon to add...";isc.A.editButtonPrompt="Add files";isc.A.removeButtonPrompt="Remove selected files";isc.A.pickerUploadButtonInitialTitle="OK";isc.A.pickerUploadButtonTitle="Save";isc.A.pickerCancelButtonTitle="Cancel";isc.A.pickerAddAnotherFileButtonTitle="<u>Add&nbsp;another</u>";isc.A.pickerUploadProgressLabel="Saving ${fileName} ${formattedFileSize}";isc.A.displayShortName=true;isc.A.iconWidth=16;isc.A.iconHeight=16;isc.A.editButtonDefaults=isc.addProperties({},isc.RelationItem.getInstanceProperty('editButtonDefaults'),{src:"[SKIN]MultiUploadItem/icon_add_files.png",showOver:false});isc.A.removeButtonDefaults=isc.addProperties({},isc.RelationItem.getInstanceProperty('removeButtonDefaults'),{src:"[SKIN]MultiUploadItem/icon_remove_files.png",showOver:false});isc.A.canEditWithNoMasterRecord=true;isc.B.push(isc.A.getDynamicDefaults=function isc_MultiFileItem_getDynamicDefaults(_1){if(_1=="canvas"){var _2={};if(this.emptyMessage!=null)_2.emptyMessage=this.emptyMessage;if(this.displayShortName!=null)_2.displayShortName=this.displayShortName;return _2}
return this.Super("getDynamicDefaults",arguments)},isc.A.showPickerModal=function isc_MultiFileItem_showPickerModal(){return true});isc.B._maxIndex=isc.C+2;isc.A=isc.MultiFileItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.init=function isc_MultiFileItem_init(){this.editButtonDefaults=isc.addDefaults({prompt:this.editButtonPrompt},this.editButtonDefaults);this.removeButtonDefaults=isc.addDefaults({prompt:this.removeButtonPrompt},this.removeButtonDefaults);this.pickerProperties=isc.addProperties({},this.pickerProperties,{uploadWithoutPKButtonName:this.pickerUploadButtonInitialTitle,uploadWithPKButtonName:this.pickerUploadButtonTitle,cancelButtonName:this.pickerCancelButtonTitle,addAnotherFileButtonProperties:{contents:this.pickerAddAnotherFileButtonTitle},progressMeterProperties:{progressLabelProperties:{dynamicContents:false,dynamicContentVars:null,contents:null,getContents:function(){var _1=this.creator,_2=_1.creator.creator,_3=_2.pickerUploadProgressLabel,_4=_3.evalDynamicString(_2,{fileName:_1.fileName,formattedFileSize:_1.getFormattedFileSize()});return"<b><nobr>"+_4+"</nobr></b>"},show:function(){this.setContents(this.getContents());this.Super("show",arguments)}}}});return this.Super("init",arguments)},isc.A.removeSelectedData=function isc_MultiFileItem_removeSelectedData(){var _1=this.getValuesComponent();if(!_1.saveOperationIsAdd())return this.Super("removeSelectedData",arguments);var _2=this.canvas.getSelection();var _3=_2.length;for(var i=0;i<_3;++i){this.picker.removeUploadField(_2[i]._form,true)}},isc.A.formSaved=function isc_MultiFileItem_formSaved(_1,_2,_3){if(this.picker){this.showPicker(true,this.editButton);var _4=this.getValuesComponent();this.picker.setForeignKeyValues(this.getDataSource().getForeignKeysByRelation(_3,_4.dataSource));this.picker.saveData(this.getID()+".saveDataCallback()");return false}else{this.saveDataCallback()}},isc.A.saveDataCallback=function isc_MultiFileItem_saveDataCallback(){if(this.picker)this.picker.hide();this.getValuesComponent().formSavedComplete();if(this.picker&&isc.ResultSet&&!isc.isA.ResultSet(this.canvas.data)){this.canvas.setData([]);this.canvas.fetchData(this.picker.foreignKeyValues)}},isc.A.pickerDataChanged=function isc_MultiFileItem_pickerDataChanged(_1){if(!this.getValuesComponent().saveOperationIsAdd())return;this.canvas.setData(this.picker.getData())},isc.A.destroy=function isc_MultiFileItem_destroy(){if(this.picker)this.picker.destroy();this.Super("destroy",arguments)});isc.B._maxIndex=isc.C+6;isc.defineClass("MultiFilePicker","VStack");isc.A=isc.MultiFilePicker.getPrototype();isc.A.height=1;isc.A.layoutMargin=10;isc.A.showInWindow=false;isc.A.styleName="windowBackground";isc.A.minUploadFields=1;isc.A.minFileSizeForProgressBar=204800;isc.A.progressCheckFrequency=1000;isc.A.progressMeterConstructor="MultiFileProgressMeter";isc.A.uploadLayoutConstructor="VStack";isc.A.uploadWithPKButtonName="Save";isc.A.uploadWithoutPKButtonName="OK";isc.A.cancelButtonName="Cancel";isc.A.showUploadRemoveButton=true;isc.A.uploadWithoutPK=false;isc.A.title="Add files";isc.A.dialogWrapperProperties={_constructor:"Window",showHeader:true,showMinimizeButton:false,showCloseButton:false,autoSize:true,headerProperties:{margin:-2},bodyProperties:{layoutMargin:10,margin:-2}};isc.A=isc.MultiFilePicker.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.addAnotherFileButtonDefaults={canFocus:true,contents:"<u>Add&nbsp;another</u>"};isc.A.creatorName="picker";isc.B.push(isc.A.initWidget=function isc_MultiFilePicker_initWidget(){this.Super("initWidget",arguments);this.addAutoChild("uploadLayout",{height:1});this.addAutoChild("addAnotherFileButton",{width:75,height:20,align:"left",cursor:isc.Canvas.HAND,icon:"[SKIN]MultiUploadItem/icon_add_files.png",click:"this.picker.addUploadField()"},"Label");this.addAutoChild("toolbar",{width:1,height:1,membersMargin:10,layoutMargin:10,layoutAlign:"right"},"HStack");this.addAutoChild("saveButton",{title:this.hasKeys()?this.uploadWithPKButtonName:this.uploadWithoutPKButtonName,width:80,updateTitle:function(){var _1=this.parentElement.picker;var _2=_1.hasKeys()?_1.uploadWithPKButtonName:_1.uploadWithoutPKButtonName;if(_2!=this.title)this.setTitle(_2)},click:function(){var _1=this.parentElement.picker;if(!_1.hasKeys()&&!_1.uploadWithoutPK){_1.hide();_1.dataChanged()}else{_1.saveData()}},observes:[{source:this,message:"setForeignKeyValues",action:"observer.updateTitle()"}]},"IButton",this.toolbar);this.addAutoChild("cancelButton",{title:this.cancelButtonName,width:80,click:function(){this.picker.hide();if(this.picker.creator.form.saveOperationIsAdd())this.picker.revertData()}},"IButton",this.toolbar);this.clearData()},isc.A.hasKeys=function isc_MultiFilePicker_hasKeys(){return(this.foreignKeyValues&&!isc.isAn.emptyObject(this.foreignKeyValues))},isc.A.setForeignKeyValues=function isc_MultiFilePicker_setForeignKeyValues(_1){this.foreignKeyValues=_1},isc.A.revertData=function isc_MultiFilePicker_revertData(){this.clearData(true)},isc.A.clearData=function isc_MultiFilePicker_clearData(_1){var _2=this.getForms(),_3=0;for(var i=_2.length-1;i>=0;i--){var _5=false;if(_1)_5=(_2[i].newlyAdded==true);else _5=true;if(isc.isAn.emptyObject(_2[i].getValues()))_5=true;if(_5)this.removeUploadField(_2[i]);else _3++}
for(var i=_3;i<this.minUploadFields;i++)this.addUploadField()},isc.A.addUploadField=function isc_MultiFilePicker_addUploadField(){var _1;if(this.dataSource==null){isc.logWarn("A datasource must be defined on a MultiFileItem ("+this.id+") or it will both not function and elements will not render properly.")}else{var _2=isc.DataSource.get(this.dataSource),_3=_2.getFields();for(var _4 in _3){if(_3[_4].type=="binary"||_3[_4].type=="imageFile"){_1=_4;break}}
if(_1==null){isc.logWarn("The datasource defined on a MultiFileItem ("+this.id+") must define a binary field")}}
var _5=this.createAutoChild("uploadForm",{dataSource:this.dataSource,cellPadding:0,numCols:2,colWidths:['*','*'],width:250,newlyAdded:true,elementChanged:function(){this.Super("elementChanged",arguments);this.picker.dataChanged()},fields:[{name:_1,multiple:false}]},isc.DynamicForm);var _6=this.createAutoChild("uploadFormLayout",{members:[_5],height:21},isc.HLayout);this.uploadLayout.addMember(_6);if(this.showUploadRemoveButton){var _7=this.createAutoChild("uploadRemoveButton",{form:_5,picker:this,contents:isc.emptyString,cursor:isc.Canvas.HAND,icon:"[SKIN]MultiUploadItem/icon_remove_files.png",click:"this.picker.removeUploadField(this.form, true)",iconSpacing:6,width:22,height:20},isc.Label);_6.addMember(_7,0)}
if(this.maxUploadFields&&this.maxUploadFields<=this.uploadLayout.getMembers().length)
this.addAnotherFileButton.hide()},isc.A.removeUploadField=function isc_MultiFilePicker_removeUploadField(_1,_2){if(_1.$203){isc.rpc.cancelQueue(_1.$203);this.transactionNum=null;if(this.progressMeter)this.progressMeter.hide()}
if(_1.parentElement)_1.parentElement.destroy();if(_2&&this.uploadLayout.getMembers().length<this.minUploadFields){this.addUploadField()}
if(this.maxUploadFields&&this.maxUploadFields>this.uploadLayout.getMembers().length){this.addAnotherFileButton.show()}
this.dataChanged()},isc.A.getForms=function isc_MultiFilePicker_getForms(){return this.uploadLayout.getMembers().callMethod("getMember",this.showUploadRemoveButton?1:0)},isc.A.dataChanged=function isc_MultiFilePicker_dataChanged(){},isc.A.show=function isc_MultiFilePicker_show(){var _1=this.getForms();if(_1)_1.setProperty("newlyAdded",false);this.Super("show",arguments);if(this.showInWindow&&!this.dialogWrapper){this.setLayoutMargin(0);this.addAutoChild("dialogWrapper",{title:this.title});this.dialogWrapper.addItem(this.uploadLayout);this.dialogWrapper.addItem(this.addAnotherFileButton);this.dialogWrapper.addItem(this.toolbar)}},isc.A.hide=function isc_MultiFilePicker_hide(){this.Super("hide",arguments);this.hideClickMask()},isc.A.getData=function isc_MultiFilePicker_getData(){var _1=[];var _2=this.getForms();for(var i=0;i<_2.length;i++){var _4=_2[i];if(!_4)continue;var _5=_4.getValues();if(isc.isAn.emptyObject(_5))continue;_5._form=_4;_1[_1.length]=_5}
return _1},isc.A.saveData=function isc_MultiFilePicker_saveData(_1){if(!_1)_1=this.saveCallback;if(!_1)_1=this.getID()+".hide()";this.saveCallback=_1;var _2=this.getForms();this.saveButton.setTitle(this.uploadWithPKButtonName);var _3;var _4;while(_2.length>0){_3=_2[0];_4=_3.getFields()[0].getValue();if(!_4){this.removeUploadField(_3);_2.remove(_3)}
else break}
if(_2.length==0){if(this.progressMeter){this.progressMeter.hide()}
this.transactionNum=null;delete this.saveCallback;this.fireCallback(_1);this.clearData();return}
if(!_3.validate())return;if(!this.progressMeter){this.progressMeter=this.createAutoChild("progressMeter",{progressCheckFrequency:this.progressCheckFrequency});this.addMember(this.progressMeter,0)}
_4=_4.replace(/.*(\\|\/)/g,isc.emptyString);this.progressMeter.setFileName(_4);this.progressMeter.hideProgressBar();this.progressMeter.show();if(this.hasKeys()){for(var _5 in this.foreignKeyValues)_3.setValue(_5,this.foreignKeyValues[_5])}
var _6=_3.saveData(this.getID()+".saveDataCallback(dsRequest, dsResponse, data)",{params:{formID:_3.getID()},willHandleError:true,form:_3,showPrompt:false,saveDataCallback:_1,timeout:0});this.transactionNum=_6.transactionNum;_3.$203=this.transactionNum;this.progressCheck(_3.getID(),this.transactionNum)},isc.A.saveDataCallback=function isc_MultiFilePicker_saveDataCallback(_1,_2,_3){var _4=_1.form;if(_2.status!=isc.RPCResponse.STATUS_SUCCESS){this.progressMeter.hide();this.transactionNum=null;if(_2.status==isc.RPCResponse.STATUS_VALIDATION_ERROR){_4.setErrors(_2.errors,true)}else{isc.warn(_3)}
return}
_4.$203=null;this.removeUploadField(_4);this.saveData(_1.saveDataCallback);if(this.callingFormItem.fileUploaded){this.callingFormItem.fileUploaded(_1,_2)}},isc.A.progressCheck=function isc_MultiFilePicker_progressCheck(_1,_2){this.lastProgressCheckTime=new Date().getTime();isc.DMI.callBuiltin({methodName:"uploadProgressCheck",callback:this.getID()+".progressCallback(rpcRequest, rpcResponse, data, "+_2+")",arguments:_1,requestParams:{willHandleError:true,showPrompt:false,formID:_1}})},isc.A.progressCallback=function isc_MultiFilePicker_progressCallback(_1,_2,_3,_4){var _5=_1.formID;var _6=window[_5];if(!_6||this.transactionNum!==_4)return;if(_2.status!=isc.RPCResponse.STATUS_SUCCESS)this.progressCheck(_5);if(_3.errors){isc.rpc.cancelQueue(this.transactionNum);_6.setErrors(_3.errors,true);this.saveButton.show();this.transactionNum=null;this.progressMeter.hide();return}
this.progressMeter.setFileSize(_3.totalBytes);if(_3.totalBytes<this.minFileSizeForProgressBar){this.progressMeter.hideProgressBar();return}
this.progressMeter.setBytesReceived(_3.bytesSoFar);this.progressMeter.showProgressBar();this.progressMeter.setPercentDone(100*_3.bytesSoFar/_3.totalBytes);var _7=this.progressCheckFrequency-(new Date().getTime()-this.lastProgressCheckTime);if(_7<0)_7=0;this.delayCall("progressCheck",[_5,_4],_7)});isc.B._maxIndex=isc.C+16;isc.defineClass("MultiFileProgressMeter","VStack");isc.A=isc.MultiFileProgressMeter;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.formatBytes=function isc_c_MultiFileProgressMeter_formatBytes(_1){var _2;if(_1<1024){_1=Math.round(_1/1024);_2="B"}else if(_1<(1024*1024)){_1=Math.round(_1/1024);_2="KB"}else{_1=Math.round(_1/(1024*1024)*100)/100;_2="MB"}
return _1+"&nbsp;"+_2});isc.B._maxIndex=isc.C+1;isc.A=isc.MultiFileProgressMeter.getPrototype();isc.A.height=50;isc.A=isc.MultiFileProgressMeter.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.initWidget=function isc_MultiFileProgressMeter_initWidget(){this.Super("initWidget",arguments);this.progressLabelProperties=isc.addDefaults(this.progressLabelProperties,{dynamicContentsVars:{progressMeter:this},dynamicContents:true,contents:"<b><nobr>Saving ${progressMeter.fileName} ${progressMeter.getFormattedFileSize()}</nobr></b>"});this.addAutoChild("progressLabel",{height:1},"Canvas")},isc.A.setFileName=function isc_MultiFileProgressMeter_setFileName(_1){this.fileName=_1;delete this.fileSize;this.bytesSoFar=0;this.bytesReceived=0;this.progressLabel.markForRedraw();if(this.progressBar)this.setPercentDone(0)},isc.A.setFileSize=function isc_MultiFileProgressMeter_setFileSize(_1){this.fileSize=_1;this.progressLabel.markForRedraw()},isc.A.setBytesReceived=function isc_MultiFileProgressMeter_setBytesReceived(_1){this.bytesSoFar=this.bytesReceived;;this.bytesReceived=_1;this.progressLabel.markForRedraw()},isc.A.getFormattedFileSize=function isc_MultiFileProgressMeter_getFormattedFileSize(){if(!this.fileSize)return isc.emptyString;var _1="<br>";if(this.bytesReceived){_1+=isc.MultiFileProgressMeter.formatBytes(this.bytesReceived)+" of "}
_1+=isc.MultiFileProgressMeter.formatBytes(this.fileSize);if(this.bytesSoFar&&this.progressCheckFrequency){var _2=this.bytesReceived-this.bytesSoFar;_2=isc.MultiFileProgressMeter.formatBytes(_2*1000/this.progressCheckFrequency);_1+=" ("+_2+"/sec)"}
return _1},isc.A.showProgressBar=function isc_MultiFileProgressMeter_showProgressBar(){this.addAutoChild("progressBar",{overflow:"visible"},"Progressbar");this.progressBar.show()},isc.A.hideProgressBar=function isc_MultiFileProgressMeter_hideProgressBar(){if(this.progressBar)this.progressBar.hide()},isc.A.setPercentDone=function isc_MultiFileProgressMeter_setPercentDone(_1){this.progressBar.setPercentDone(_1)});isc.B._maxIndex=isc.C+8;}
isc.addGlobal("MultiUploadItem",isc.MultiFileItem);isc.addGlobal("MultiUploadPicker",isc.MultiFilePicker);if(isc.ListGrid){isc.defineClass("DialogUploadItem","StaticTextItem");isc.A=isc.DialogUploadItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.iconHeight=16;isc.A.iconWidth=16;isc.A.icons=[{src:"[SKIN]MultiUploadItem/icon_add_files.png",name:"upload",prompt:"Upload File",click:"item.showPicker(true)"},{src:"[SKIN]MultiUploadItem/icon_remove_files.png",name:"remove",prompt:"Remove File",click:"item.removeFile()"}];isc.A.pickerConstructor="DialogUploadPicker";isc.A.noFileString="[NONE]";isc.B.push(isc.A.init=function isc_DialogUploadItem_init(){this.Super("init",arguments);if(!this.pickerDefaults)this.pickerDefaults={};isc.addProperties(this.pickerDefaults,{dataSource:this.dataSource})},isc.A.mapValueToDisplay=function isc_DialogUploadItem_mapValueToDisplay(_1){return _1==null?this.noFileString:this.Super("mapValueToDisplay",arguments)},isc.A.showPicker=function isc_DialogUploadItem_showPicker(){this.Super("showPicker",arguments);var _1=this.getValue('primaryKey');this.picker.foreignKeyValues={primaryKey:_1}},isc.A.removeFile=function isc_DialogUploadItem_removeFile(){var _1=this.getValue();if(_1!=this.defaultValue){var _2=isc.DataSource.get(this.dataSource);_2.removeData({primaryKey:_1},this.getID()+".removeFileCallback(dsResponse)")}},isc.A.removeFileCallback=function isc_DialogUploadItem_removeFileCallback(_1){if(_1.status!=isc.DSResponse.STATUS_SUCCESS){isc.warn("Unable to remove file: "+_1.data);return}
this.setValue(this.defaultValue)},isc.A.fileUploaded=function isc_DialogUploadItem_fileUploaded(_1,_2){var _3=_2.data;var _4={};_4[_3.primaryKey]=_3.file_filename;this.setValueMap(_4);this.setValue(_3.primaryKey)},isc.A.destroy=function isc_DialogUploadItem_destroy(){if(this.picker)this.picker.destroy();this.Super("destroy",arguments)},isc.A.$85m=function isc_DialogUploadItem__shouldAllowExpressions(){return false});isc.B._maxIndex=isc.C+8;isc.defineClass("DialogUploadPicker","MultiFilePicker");isc.A=isc.DialogUploadPicker.getPrototype();isc.A.maxUploadFields=1;isc.A.uploadWithoutPKButtonName="Upload";isc.A.uploadWithPKButtonName="Upload";isc.A.showUploadRemoveButton=false;isc.A.uploadWithoutPK=true}
if(isc.ListGrid){isc.ClassFactory.defineClass("SOAPUploadItem","DialogUploadItem");isc.A=isc.SOAPUploadItem.getPrototype();isc.A.dataSource="sessionFiles"}isc.ClassFactory.defineClass("SpinnerItem","TextItem");isc.A=isc.SpinnerItem;isc.A.INCREASE_ICON={};isc.A.DECREASE_ICON={};isc.A=isc.SpinnerItem.getPrototype();isc.A.defaultType="float";isc.A.changeOnKeypress=false;isc.A.canTabToIcons=false;isc.A.height=18;isc.A.unstackedTextBoxStyle="textItem";isc.A.step=1;isc.A.increaseIconDefaults={width:16,height:9,src:"[SKIN]/DynamicForm/Spinner_increase_icon.png",name:"increase",showOver:false,redrawOnShowIcon:true,showFocusedWithItem:false,imgOnly:true,hspace:0};isc.A.decreaseIconDefaults={width:16,height:9,src:"[SKIN]/DynamicForm/Spinner_decrease_icon.png",name:"decrease",showOver:false,redrawOnShowIcon:true,showFocusedWithItem:false,imgOnly:true,hspace:0};isc.A.unstackedIncreaseIconDefaults={src:"[SKIN]/DynamicForm/Spinner_increase_icon.png",width:18,height:18,name:"increase",showOver:false,showFocusedWithItem:false,imgOnly:true,hspace:0};isc.A.unstackedDecreaseIconDefaults={src:"[SKIN]/DynamicForm/Spinner_decrease_icon.png",width:18,height:18,name:"decrease",showOver:false,showFocusedWithItem:false,imgOnly:true,hspace:0};isc.A=isc.SpinnerItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.writeSpinnersIntoControlTable=true;isc.A.$132h="<td tabIndex='-1'"+(isc.Browser.isIE?" style='font-size:0px'":"");isc.A.$132i=" rowspan='2'>";isc.A.$132j="</td>";isc.A.$1480="increase";isc.A.$1481="decrease";isc.B.push(isc.A.init=function isc_SpinnerItem_init(){this.Super("init",arguments);var _1=this.step;if(_1!=null&&!isc.isA.Number(_1)){_1=parseFloat(_1);if(!isc.isA.Number(_1))_1=1;this.step=_1}},isc.A.$1482=function isc_SpinnerItem__stackedMode(){if(this.writeStackedIcons!=null)return this.writeStackedIcons;return!isc.Browser.isTouch},isc.A.$14v=function isc_SpinnerItem__setUpIcons(){if(this.icons==null)this.icons=[];var _1,_2;if(this.$1482()){_1=this.increaseIcon=isc.addProperties({},this.increaseIconDefaults,isc.SpinnerItem.INCREASE_ICON,this.increaseIconProperties),_2=this.decreaseIcon=isc.addProperties({},this.decreaseIconDefaults,isc.SpinnerItem.DECREASE_ICON,this.decreaseIconProperties);_1.inline=false;_2.inline=false;this.icons.addListAt([_1,_2],0)}else{_2=this.unstackedDecreaseIcon=isc.addProperties({},this.unstackedDecreaseIconDefaults,this.unstackedDecreaseIconProperties);_1=this.unstackedIncreaseIcon=isc.addProperties({},this.unstackedIncreaseIconDefaults,this.unstackedIncreaseIconProperties);_1.inline=false;_2.inline=false;this.icons.addListAt([_2,_1],0)}
this.Super("$14v",arguments)},isc.A.$186e=function isc_SpinnerItem__writeSpinnersIntoControlTable(){return this.writeSpinnersIntoControlTable&&this.showIcons&&this.$1482()},isc.A.$1857=function isc_SpinnerItem__writeControlTable(){if(this.Super("$1857"))return true;if(this.$186e())return true;return false},isc.A.$16e=function isc_SpinnerItem__writeIconIntoItem(_1){if(this.$186e()&&((_1==this.increaseIcon)||(_1==this.decreaseIcon)))
{return true}
return this.Super("$16e",arguments)},isc.A.$186d=function isc_SpinnerItem__getPickerIconCellValue(){var _1=this.Super("$186d",arguments);if(this.$186e()){var _2=this.$186f();_2[7]=this.getIconHTML(this.icons[0]);_2[12]=this.getIconHTML(this.icons[1]);var _3=_2.join("");if(_1==null){_1=_3}else{_1="<table cellPadding=0 cellSpacing=0><tr><td>"+_1+"</td><td>"+_3+"</td></table>"}}
return _1},isc.A.getTextBoxWidth=function isc_SpinnerItem_getTextBoxWidth(_1){var _2=this.Super("getTextBoxWidth",arguments);if(this.$186e()){var _3=this.increaseIcon;_2-=(_3.width||this.iconWidth);if(_3.hspace)_2-=_3.hspace;if(_3.baseStyle)_2-=isc.Element.$yp(_3.baseStyle)}
return _2},isc.A.getIconsHTML=function isc_SpinnerItem_getIconsHTML(){if(this.$186e()){return this.Super("getIconsHTML",arguments)}
if(!this.showIcons)return isc.emptyString;var _1=this.$16j(true);if(!this.$1482()||!this.icons[0].visible){return this.Super("getIconsHTML",arguments)}
var _2=this.$186f();var _3=this.icons.length-2;if(_3<this.$132k){_2.splice(9+4*_3,4*(this.$132k-_3));this.$132k=_3}else{var d=_3-this.$132k;if(d>0){var _5=[9,0];_5[2+4*d-1]=null;_2.splice.apply(_2,_5);this.$132k=_3}}
if(this.renderAsStatic()){_2[7]=null;_2[12+4*this.$132k]=null}else{_2[7]=this.getIconHTML(this.icons[0]);_2[12+4*this.$132k]=this.getIconHTML(this.icons[1])}
var i=9;for(var d=2;d<this.icons.length;++d,i+=4){var _7=this.icons[d];if(!_7.visible||this.$16e(_7)){_2[i]=null;_2[i+1]=null;_2[i+2]=null;_2[i+3]=null}else{_2[i]=this.$132h;_2[i+1]=this.$132i;_2[i+2]=this.getIconHTML(_7);_2[i+3]=this.$132j;delete _7.$181a}}
return _2.join(isc.emptyString)},isc.A.$186f=function isc_SpinnerItem__getSpinnerTableTemplate(){var _1=this.$204;if(_1==null){var _2=this.$132h,_3={},_4=this.$16l(_3),_5=this.$16m(_3);_1=this.$204=["<table role='presentation' style='margin-top:",_5,";margin-bottom:",_5,"' border=0 cellpadding=0 cellspacing=0><tbody><tr>",_2,">",null,"</td>","</tr><tr>",_2,">",null,"</td></tr></tbody></table>"];this.$132k=0}
return _1},isc.A.getIconHTML=function isc_SpinnerItem_getIconHTML(_1){if(this.$68y())return null;return this.Super("getIconHTML",arguments)},isc.A.getTextBoxStyle=function isc_SpinnerItem_getTextBoxStyle(){if(this.$1482()){if(this.$68y())return isc.TextItem.getInstanceProperty("textBoxStyle");else return this.Super("getTextBoxStyle",arguments)}
if(this.$68y()&&this.unstackedPrintTextBoxStyle){return this.$15x(this.unstackedPrintTextBoxStyle)}
var _1=(this.getCanEdit()==false&&this.renderAsStatic()?this.getReadOnlyTextBoxStyle():this.unstackedTextBoxStyle),_2=this.$15x(_1);return _2},isc.A.getReadOnlyTextBoxStyle=function isc_SpinnerItem_getReadOnlyTextBoxStyle(){if(this.$1482())return this.Super("getReadOnlyTextBoxStyle",arguments);return this.unstackedReadOnlyTextBoxStyle||(this.form?this.form.readOnlyTextBoxStyle:"staticTextItem")},isc.A.$16m=function isc_SpinnerItem__getIconVMargin(_1){if(_1==this.icons[0]||_1==this.icons[1])return 0;return this.Super("$16m",arguments)},isc.A.getTotalIconsWidth=function isc_SpinnerItem_getTotalIconsWidth(){var _1=this.Super("getTotalIconsWidth",arguments);if(!this.$186e()&&_1>0&&this.$1482()){var _2=Math.max(this.icons[0].width,this.icons[1].width);_1-=_2}
return _1},isc.A.mouseStillDown=function isc_SpinnerItem_mouseStillDown(_1,_2,_3){if(this.isDisabled()||this.isReadOnly())return;this.$205++;if(this.$18j)this.updateValue();var _4=_3.nativeTarget;var _5=this.$116r,_6=null;if(_4==this.$16v(this.icons[0])){_6=this.icons[0]}else if(_4==this.$16v(this.icons[1])){_6=this.icons[1]}
if(_5!=_6){this.$205=1;if(_5!=null){var _7=this.$16v(_5);if(_7){this.$123(_5.name,_7)}}
this.$116r=_6;if(_6!=null){if(!isc.Browser.isTouch&&this.$166()!=null&&this.$166()==this.$15h())
{this.blurItem()}
var _7=this.$16v(_6);if(_7){this.$121(_6.name,_7)}}}
if(_6!=null){if(_6.name===this.$1480){this.increaseValue()}else if(_6.name===this.$1481){this.decreaseValue()}}},isc.A.mouseDown=function isc_SpinnerItem_mouseDown(_1,_2,_3){if(this.isDisabled()||this.isReadOnly())return;this.$205=0;isc.Page.setEvent(isc.EH.MOUSE_UP,this,isc.Page.FIRE_ONCE,"$116s")},isc.A.$116s=function isc_SpinnerItem__clearLastTargetIcon(){var _1=this.$116r;if(_1!=null){var _2=this.$16v(_1);if(_2){this.$123(_1.name,_2)}}
this.$116r=null;if(!isc.Browser.isTouch)this.focusInItem()},isc.A.handleKeyPress=function isc_SpinnerItem_handleKeyPress(_1,_2){var _3=this.Super("handleKeyPress",arguments);if(_3==false){return false}
var _4=_1.keyName,_5=this.isReadOnly();if(!_5&&_4=="Arrow_Up"){this.increaseValue();return false}
if(!_5&&_4=="Arrow_Down"){this.decreaseValue();return false}
return _3},isc.A.getNextValue=function isc_SpinnerItem_getNextValue(_1,_2){return this.$118d(_1,_2)},isc.A.getPreviousValue=function isc_SpinnerItem_getPreviousValue(_1,_2){return this.$118d(_1,_2)},isc.A.$118d=function isc_SpinnerItem__defaultGetNextValue(_1,_2){var _3=this.min,_4=this.max;var _5,_6;if(Math.round(_2)==_2){_5=0}else{var _7=_2+"";_5=_7.length-(_7.indexOf(".")+1)}
if(Math.round(_1)==_1){_6=0}else{var _8=_1+"";_6=_8.length-(_8.indexOf(".")+1)}
_1+=_2;var _9=Math.max(_5,_6);if(_9>0){_1=parseFloat(_1.toFixed(_9))}
if(_2>0&&_4!=null&&_1>_4)_1=_4;else if(_2<0&&_3!=null&&_1<_3)_1=_3;return _1},isc.A.increaseValue=function isc_SpinnerItem_increaseValue(){this.updateValue();var _1=this.getValue();if(_1!=null&&this.max==_1)return;var _2=this.$205;var _3=this.form.mouseStillDownDelay;var _4=this.step*(_2!=null?Math.pow(2,Math.floor(this.$205/(2000/_3))):1);return this.$118e(_1,_4,true)},isc.A.decreaseValue=function isc_SpinnerItem_decreaseValue(){this.updateValue();var _1=this.getValue();if(_1!=null&&this.min==_1)return;var _2=this.$205;var _3=this.form.mouseStillDownDelay;var _4=(0-this.step)*(_2!=null?Math.pow(2,Math.floor(this.$205/(2000/_3))):1);return this.$118e(_1,_4,false)},isc.A.$118e=function isc_SpinnerItem__modifyValue(_1,_2,_3){var _4=this.min,_5=this.max;if(!isc.isA.Number(_1)){_1=0;if((_4!=null&&_1<_4)||(_5!=null&&_1>_5)){_1=(_4!=null?_4:_5)}}
if(_4==null&&_5==null){_1=_3?this.getNextValue(_1,_2):this.getPreviousValue(_1,_2)}else{_1=this.$118d(_1,_2)}
var _6=this.form,_7=this.form?this.form.getValues():null,_8=(this.formatEditorValue!=null)?this.formatEditorValue(_1,_7,_6,this):_1;this.setElementValue(_8);this.updateValue()},isc.A.mapDisplayToValue=function isc_SpinnerItem_mapDisplayToValue(_1){_1=this.Super("mapDisplayToValue",arguments);if(isc.isA.String(_1)){var _2=parseFloat(_1);if(_2==_1)_1=_2}
return _1},isc.A.isInRange=function isc_SpinnerItem_isInRange(_1){if(this.max!=null){if(this.max<_1)return false}else if(this.min==null){if(0<=this.step){if((_1<this.getPreviousValue(_1,-this.step))||(this.getNextValue(_1,this.step)<_1))
{return false}}else{if((_1>this.getPreviousValue(_1,-this.step))||(this.getNextValue(_1,this.step)>_1))
{return false}}}
if(this.min!=null){if(_1<this.min)return false}
return true},isc.A.updateValue=function isc_SpinnerItem_updateValue(){var _1=this.getElementValue();_1=this.mapDisplayToValue(_1);if(_1==this._value)return;if(_1!=null&&(!isc.isA.Number(_1)||!this.isInRange(_1))){var _2=this.mapValueToDisplay(this._value);this.setElementValue(_2);return}
this.Super("updateValue",arguments)},isc.A.setValue=function isc_SpinnerItem_setValue(_1,_2,_3,_4,_5,_6){if(_1!=null&&!isc.isA.Number(_1)){var _7=parseFloat(_1);if(_7==_1)_1=_7;else{this.logWarn("setValue(): passed '"+_1+"'. This is not a valid number - rejecting this value");_1=null}}
if(_1!=null){if(this.max!=null&&_1>this.max){this.logWarn("setValue passed "+_1+" - exceeds specified maximum. Clamping to this.max.");_1=this.max}
if(this.min!=null&&_1<this.min){this.logWarn("setValue passed "+_1+" - less than specified minimum. Clamping to this.min.");_1=this.min}
if(this.max==null&&this.min==null){var _8=this.getNextValue(_1,this.step),_9=this.getPreviousValue(_1,-this.step);if(0<=this.step){if(_1<_9){this.logWarn("setValue passed "+_1+" - less than the previous value "+_9+". Setting to the previous value.");_1=_9}
if(_8<_1){this.logWarn("setValue passed "+_1+" - greater than the next value "+_8+". Setting to the next value.");_1=_8}}else{if(_1>_9){this.logWarn("setValue passed "+_1+" - greater than the previous value "+_9+". Setting to the previous value.");_1=_9}
if(_8>_1){this.logWarn("setValue passed "+_1+" - less than the next value "+_8+". Setting to the next value.");_1=_8}}}}
return this.invokeSuper(isc.SpinnerItem,"setValue",_1,_2,_3,_4,_5,_6)});isc.B._maxIndex=isc.C+29;isc.ClassFactory.defineClass("SliderItem","CanvasItem");isc.A=isc.SliderItem.getPrototype();isc.A.defaultType="float";isc.A.width=150;isc.A.vertical=false;isc.A.minValue=1;isc.A.maxValue=100;isc.A.roundValues=true;isc.A.roundPrecision=1;isc.A.defaultValue=1;isc.A.valueStyle="sliderValue";isc.A.pendingValueStyle="pendingSliderValue";isc.A.shouldSaveValue=true;isc.A.sliderConstructor="Slider";isc.A.sliderDefaults={autoDraw:false,showTitle:false,hover:function(){var _1=this.canvasItem;if(_1!=null){_1.$wb();return false}},valueChanged:function(){var _1=this.canvasItem;if(_1!=null)_1.sliderChange()}};isc.A.autoDestroy=true;isc.A=isc.SliderItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.changeOnDrag=true;isc.B.push(isc.A.init=function isc_SliderItem_init(){this.Super("init",arguments);this.$207=this.getDefaultValue()},isc.A.$18y=function isc_SliderItem__createCanvas(){var _1=this.canvas=this.addAutoChild("slider",{canHover:this.$161p(),vertical:this.vertical,minValue:this.minValue,maxValue:this.maxValue,value:this.defaultValue,numValues:this.numValues,roundValues:this.roundValues,roundPrecision:this.roundPrecision,tabIndex:this.getGlobalTabIndex(),valueStyle:this.valueStyle,width:this.width},this.sliderConstructor,this.container);if(_1!=null){this.observe(_1._track,"$lf",this.sliderPartFocusChanged);this.observe(_1._thumb,"$lf",this.sliderPartFocusChanged);if(_1._thumb.triggerArea!=null){this.observe(_1._thumb.triggerArea,"$lf",this.sliderPartFocusChanged)}}
this.Super("$18y",arguments)},isc.A.sliderPartFocusChanged=function isc_SliderItem_sliderPartFocusChanged(){var _1=this.form,_2=this.ns.EH.getFocusCanvas();if(_2!=null&&this.canvas.contains(_2,true)){if(_1.getFocusSubItem()!==this){_1.setFocusItem(this);this.elementFocus()}}else{this.elementBlur();if(_1.getFocusSubItem()===this)_1.setFocusItem(null)}},isc.A.isEditable=function isc_SliderItem_isEditable(){return this.getCanEdit()},isc.A.$1608=function isc_SliderItem__defaultPendingStatusChangedBehavior(_1){this.Super("$1608",arguments);this.canvas.setValueStyle(_1?this.pendingValueStyle:this.valueStyle)},isc.A.setValue=function isc_SliderItem_setValue(_1){this.$17g=true;var _2;if(_1==null){_2=this.getDefaultValue();if(_2!=null)_1=_2}
this.$207=_1;this.canvas.setValue(_1,(_2!=null))},isc.A.getValue=function isc_SliderItem_getValue(){return this.canvas.getValue()},isc.A.sliderChange=function isc_SliderItem_sliderChange(){var _1=this.canvas.getValue();if(this.$207!=_1){if(this.changeOnDrag||!this.canvas.valueIsChanging()){this.$10y(_1);this.$207=_1}}else{this.saveValue(_1)}},isc.A.setMinValue=function isc_SliderItem_setMinValue(_1){this.canvas.setMinValue(_1);this.minValue=_1},isc.A.setMaxValue=function isc_SliderItem_setMaxValue(_1){this.canvas.setMaxValue(_1);this.maxValue=_1},isc.A.setNumValues=function isc_SliderItem_setNumValues(_1){this.canvas.setNumValues(_1);this.numValues=_1},isc.A.$85m=function isc_SliderItem__shouldAllowExpressions(){return false});isc.B._maxIndex=isc.C+12;isc.ClassFactory.defineClass("ColorItem","TextItem");isc.addGlobal("ColorPickerItem",isc.ColorItem);isc.A=isc.ColorItem.getPrototype();isc.A.changeOnBlur=true;isc.A.changeOnKeypress=false;isc.A.pickerConstructor="ColorPicker";isc.A.pickerDefaults={colorSelected:function(_1,_2){this.callingFormItem.$1551(_1,_2)},pickerCancelled:function(){this.callingFormItem.$183d()}};isc.A.showPickerIcon=true;isc.A.showEmptyPickerIcon=false;isc.A.pickerIconWidth=18;isc.A.pickerIconHeight=18;isc.A.pickerIconHSpace=2;isc.A.pickerIconSrc="[SKIN]/DynamicForm/ColorPicker_icon.png";isc.A.pickerIconPrompt="Click to select a new color";isc.A.defaultPickerMode="simple";isc.A.allowComplexMode=true;isc.A.supportsTransparency=false;isc.A.browserSpellCheck=false;isc.A.defaultType="color";isc.A=isc.ColorItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$1508="empty";isc.B.push(isc.A.updateValue=function isc_ColorItem_updateValue(){var _1=this._value,_2=this.getElementValue();_2=this.mapDisplayToValue(_2);if(_2==this._value)return;if(_2!=null&&!isc.isA.color(_2)){this.setElementValue(_1);return}
this.Super("updateValue",arguments);if(this.showPickerIcon&&this._value!=_1){var _3=this.getPickerIcon();var _4=(this._value==null||isc.isAn.emptyString(this._value));this.setIconBackgroundColor(_3,_4?isc.emptyString:this._value);if(this.showEmptyPickerIcon){this.setIconCustomState(_3,_4?this.$1508:null)}
this.updateState()}},isc.A.getDefaultValue=function isc_ColorItem_getDefaultValue(){var _1=this.Super("getDefaultValue",arguments);if(_1&&!isc.isA.color(_1)){this.logWarn("Default value:"+_1+" is not a valid color identifier. Ignoring this default.");_1=this.defaultValue=null}
return _1},isc.A.showPicker=function isc_ColorItem_showPicker(){var _1=isc.addProperties({},this.pickerDefaults);_1.defaultPickMode=this.defaultPickerMode;_1.allowComplexMode=this.allowComplexMode;_1.supportsTransparency=this.supportsTransparency;this.picker=isc.ColorPicker.getSharedColorPicker(_1);var _2=this.picker;var _3=_2.callingFormItem;if(_3!=this){_2.callingFormItem=this;_2.callingForm=this.form;_2.setSupportsTransparency(this.supportsTransparency)}
_2.setHtmlColor(this._value||"");if(_2.allowComplexMode){if(_2.$56c=='simple'){_2.modeToggleButton.setTitle(_2.moreButtonTitle)}else{_2.modeToggleButton.setTitle(_2.lessButtonTitle)}}
if(!this.isObserving(_2,"visibilityChanged")){this.observe(_2,"visibilityChanged",this.pickerVisibilityChanged)}
this.$183e=this.getValue();return this.Super("showPicker",arguments)},isc.A.$183d=function isc_ColorItem__pickerCancelled(){this.setValue(this.$183e);delete this.$183e},isc.A.$1551=function isc_ColorItem__pickerColorSelected(_1,_2){if(this.pickerColorSelected)this.pickerColorSelected(_1,_2);if(!this.mask){_1=this.mapValueToDisplay(_1)}
this.setElementValue(_1);this.updateValue()},isc.A.pickerColorSelected=function isc_ColorItem_pickerColorSelected(_1,_2){},isc.A.pickerVisibilityChanged=function isc_ColorItem_pickerVisibilityChanged(_1){if(!_1){this.focusInIcon("picker");this.ignore(this.picker,"visibilityChanged")}},isc.A.setValue=function isc_ColorItem_setValue(_1,_2,_3,_4){_1=this.invokeSuper(isc.ColorItem,"setValue",_1,_2,_3,_4);if(this.showPickerIcon){var _5=this.getPickerIcon();var _6=(_1==null||isc.isAn.emptyString(_1));this.setIconBackgroundColor(_5,_6?isc.emptyString:_1);if(this.showEmptyPickerIcon){this.setIconCustomState(_5,_6?this.$1508:null)}
this.updateState()}
return _1});isc.B._maxIndex=isc.C+8;if(isc.ListGrid){isc.ClassFactory.defineClass("ValueMapEditor","VLayout");isc.A=isc.ValueMapEditor.getPrototype();isc.A.mapTypeConstructor=isc.Button;isc.A.mapTypeDefaults={autoDraw:false,width:"100%",click:function(){this.creator.canvasItem.toggleObjectArray()},showIf:function(){return this.creator.canvasItem.showMapTypeButton},getTitle:function(){var _1=this.creator.canvasItem,_2=_1.saveAsObject;if(_2)return _1.saveAsObjectTitle;else return _1.saveAsArrayTitle}};isc.A.selectorConstructor=isc.ListGrid;isc.A.selectorDefaults={height:1,overflow:"visible",bodyOverflow:"visible",inherentHeight:true,showNewRecordRow:true,listEndEditAction:"next",canEdit:true,editEvent:isc.EH.CLICK,cellHeight:22,selectionType:isc.Selection.NONE,selectOnEdit:false,leaveScrollbarGap:false,showSortArrow:isc.ListGrid.NONE,canSort:false,canResizeFields:false,dataChanged:function(){this.Super("dataChanged",arguments);if(this.creator&&this.creator.canvasItem)
this.creator.canvasItem.updateValue()},stopOnErrors:true,validateCellValue:function(_1,_2,_3,_4){var _5=this.getFieldName(_2),_6=this.creator.canvasItem,_7=_6.$208(_5,_1,_3);if(_7)return _7;return this.Super("validateCellValue",arguments)},cellContextClick:function(_1,_2,_3){var _4=this.creator.canvasItem.getSelectorContextMenu(_1);_4.showContextMenu();return false},getHeaderContextMenu:function(){return this.creator.canvasItem.getSelectorContextMenu()}};isc.A=isc.ValueMapEditor.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.initWidget=function isc_ValueMapEditor_initWidget(){if(!this.canvasItem){this.logWarn("ValueMapEditors are not supported as standalone widgets at this time.");return}
this.Super("initWidget",arguments);this.addAutoChild("mapType",{});this.addAutoChild("selector",{newRecordRowMessage:this.canvasItem.newOptionRowMessage,showHeader:this.showHeader,fields:this.canvasItem.$209(),data:this.canvasItem.$21a()})});isc.B._maxIndex=isc.C+1;isc.ClassFactory.defineClass("ValueMapItem","CanvasItem");isc.A=isc.ValueMapItem.getPrototype();isc.A.height=1;isc.A.autoDestroy=true;isc.A.shouldSaveValue=true;isc.A.showMapTypeButton=true;isc.A.showHeader=true;isc.A.newOptionRowMessage="Click to add a new option";isc.A.displayTitle="Display";isc.A.valueTitle="Value";isc.A.undefinedKeyErrorMessage="Each valueMap option must have a defined value";isc.A.duplicateValueErrorMessage="Please enter a unique value for this option";isc.A.saveAsArrayTitle="Stored == Displayed";isc.A.saveAsObjectTitle="Stored != Displayed";isc.A=isc.ValueMapItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.$18y=function isc_ValueMapItem__createCanvas(){if(this.canvas)return;if(this._value==null)this._value=[];this.canvas=isc.ValueMapEditor.create({autoDraw:false,_generated:true,ID:this.getID()+"$21b",canvasItem:this,showMapType:this.showMapTypeButton,showHeader:this.showHeader,height:this.height,overflow:isc.Canvas.VISIBLE});this.Super("$18y",arguments)},isc.A.$21c=function isc_ValueMapItem__getMapTypeButton(){return this.canvas.mapType},isc.A.$21d=function isc_ValueMapItem__getSelectorGrid(){return this.canvas.selector},isc.A.$21a=function isc_ValueMapItem__getSelectorData(_1){var _1=_1||this.getValue();if(!_1)_1=this.saveAsObject?{}:[];var _2=[];if(isc.isAn.Array(_1)){for(var i=0;i<_1.length;i++){_2[i]={value:_1[i]}}}else{var i=0;for(var _4 in _1){_2[i]={value:_4,display:_1[_4]}
i++}}
return _2},isc.A.$209=function isc_ValueMapItem__getSelectorFields(){if(!this.$21e||!this.$21f){this.$21e={name:"display",title:this.displayTitle};this.$21f={name:"value",title:this.valueTitle}}
var _1=[this.$21f];if(this.saveAsObject)_1.add(this.$21e);return _1},isc.A.$208=function isc_ValueMapItem__validateSelectorCellValue(_1,_2,_3){if(_1!="value")return;if(!this.saveAsObject&&this.allowDuplicates)return;var _4=this.$21d(),_5=_2>_4.data.getLength(),_6=this._value,_7;if(this.saveAsObject){if(_3==null||_3==""){return[this.undefinedKeyErrorMessage]}
_7=isc.getKeys(_6)}else{_7=_6||[]}
var _8;if(_5){if(_7.contains(_3))_8=true}else{for(var i=0;i<_7.length;i++){if(_2==i)continue;if(_3==_7[i]){_8=true;break}}}
if(_8)return[this.duplicateValueErrorMessage];return null},isc.A.getSelectorContextMenu=function isc_ValueMapItem_getSelectorContextMenu(_1){if(!this.$21g){var _2=[{title:"Add new option",click:"menu.canvasItem.addOption()"},{title:"Delete option",enableIf:"menu.record != null",click:"menu.canvasItem.removeOption(menu.record)"}];if(this.showMapTypeButton){_2.add({dynamicTitle:"this.canvasItem.$21h()",click:"menu.canvasItem.toggleObjectArray()"})}
this.$21g=this.ns.Menu.create({canvasItem:this,ID:this.getID()+"$21i",data:_2})}
this.$21g.record=_1;return this.$21g},isc.A.addOption=function isc_ValueMapItem_addOption(){this.$21d().startEditingNew()},isc.A.removeOption=function isc_ValueMapItem_removeOption(_1){var _2=this.$21d();_2.data.remove(_1);_2.data.dataChanged()},isc.A.$21h=function isc_ValueMapItem__getToggleObjectArrayTitle(){var _1=this.saveAsObject;return _1?this.saveAsArrayTitle:this.saveAsObjectTitle},isc.A.toggleObjectArray=function isc_ValueMapItem_toggleObjectArray(){this.setSaveAsObject(!this.saveAsObject)},isc.A.setSaveAsObject=function isc_ValueMapItem_setSaveAsObject(_1){if(this.saveAsObject==_1)return;var _2,_3=this.getValue();if(_1){_2={};if(_3!=null){for(var i=0;i<_3.length;i++){_2[_3[i]]=_3[i]}}}else{_2=[];for(var _5 in _3){_2.add(_5)}}
this._value=_2;this.saveAsObject=_1;var _6=this.$21d(),_7=this.$21a();if(!_6)return;_6.setData(_7);_6.setFields(this.$209());if(this.showMapTypeButton)this.$21c().markForRedraw()},isc.A.isEditable=function isc_ValueMapItem_isEditable(){return true},isc.A.updateValue=function isc_ValueMapItem_updateValue(){var _1=this.$21d(),_2=_1.data,_3=this.saveAsObject,_4=_3?{}:[],_5;if(_3){var _6={};if(isc.isAn.Array(this._value)){_5=true}else{isc.addProperties(_6,this._value)}
var _7=isc.getKeys(_6);for(var i=0;i<_2.length;i++){var _9=_2[i],_10=_9.display;_4[_9.value]=_9.display;if(!_7.contains(_10)||(_6[_9.value]!=_10))
_5=true;delete _6[_9.value]}
if(isc.getKeys(_6).length!=0)_5=true}else{if(!isc.isAn.Array(this._value)||(this._value.length!=_2.length)){_5=true}
for(var i=0;i<_2.length;i++){var _9=_2[i],_10=_9.value;_4[i]=_10;if(!_5&&(this._value[i]!=_10))_5=true}}
if(!_5)return;if(this.handleChange(_4,this._value)==false)return;_4=this.$17n;delete this.$17n;this.saveValue(_4)},isc.A.setValue=function isc_ValueMapItem_setValue(_1){this.$17g=true;if(_1!=null&&!isc.isAn.Object(_1)){this.logWarn("setValue() passed an invalid object. Must be a valueMap (either specified as an array or a raw JS object.");return}
var _2=isc.isAn.Array(_1),_3=(!!this.saveAsObject);if(_1!=null&&_2==_3){this.logInfo("setValue() passed a valueMap of type "+(_2?"Array":"Object")+".  Updating this.saveAsObject to match this data type.");this.setSaveAsObject(!_2);_3=this.saveAsObject}
this._value=_1;this.$21d().setData(this.$21a())});isc.B._maxIndex=isc.C+15}
isc.defineClass("ArrayItem",isc.ValueMapItem);isc.A=isc.ArrayItem.getPrototype();isc.A.showMapTypeButton=false;isc.A.showHeader=false;isc.A.saveAsObject=false;isc.A.allowDuplicates=true;isc.A.newOptionRowMessage="Click to add values";isc.defineClass("MappingItem",isc.ValueMapItem);isc.A=isc.MappingItem.getPrototype();isc.A.showMapTypeButton=false;isc.A.saveAsObject=true;if(isc.ListGrid){isc.ClassFactory.defineClass("PickTreeItem","CanvasItem");isc.A=isc.PickTreeItem;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.$21j=function isc_c_PickTreeItem__itemSelected(_1){return this.canvasItem.$21j(_1)},isc.A.$21k=function isc_c_PickTreeItem__getButtonTitle(){var _1=this.getSelectedItem();if(_1==null){var _2=this.canvasItem,_3=this.canvasItem.getValue();if(_3!=null)return _2.mapValueToDisplay(_3)}
return this.Super("getTitle",arguments)},isc.A.$21l=function isc_c_PickTreeItem__treeDataLoaded(){var _1=this.canvasItem;_1.setValue(_1.getValue())});isc.B._maxIndex=isc.C+3;isc.A=isc.PickTreeItem.getPrototype();isc.A.canFocus=true;isc.A.shouldSaveValue=true;isc.A.buttonDefaults={height:19,hover:function(){var _1=this.canvasItem;if(_1!=null){_1.$wb();return false}}};isc.A.buttonConstructor="TreeMenuButton";isc.A.pendingButtonStyle="buttonPending";isc.A.emptyMenuMessage="No items to display";isc.A.emptyDisplayValue=null;isc.A.readOnlyDisplay="disabled";isc.A=isc.PickTreeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$77l="button";isc.A.width=null;isc.B.push(isc.A.init=function isc_PickTreeItem_init(){this.Super("init",arguments);if(this.optionDataSource==null&&this.dataSource==null&&this.valueTree==null){this.logWarn("This form item requires a 'valueTree'.")}},isc.A.getOptionDataSource=function isc_PickTreeItem_getOptionDataSource(){var _1=this.optionDataSource||this.dataSource;if(_1!=null)_1=isc.DataSource.get(_1);return _1},isc.A.getDisplayValue=function isc_PickTreeItem_getDisplayValue(){return this.canvas.getTitle()},isc.A.setValueTree=function isc_PickTreeItem_setValueTree(_1){this.valueTree=_1;if(this.canvas){this.canvas.setData(this.valueTree)}},isc.A.$18y=function isc_PickTreeItem__createCanvas(){var _1={getTitle:isc.PickTreeItem.$21k,canFocus:this.$kk(),canHover:this.$161p(),dataSource:this.getOptionDataSource(),criteria:this.optionCriteria,menu:{$1053:this.optionOperationId},data:this.valueTree,canSelectParentItems:this.canSelectParentItems,itemSelected:isc.PickTreeItem.$21j,emptyMenuMessage:this.emptyMenuMessage,unselectedTitle:this.$1054(),loadDataOnDemand:this.loadDataOnDemand,treeDataLoaded:isc.PickTreeItem.$21l,displayField:this.displayField,dataProperties:(this.dataProperties==null?{}:this.dataProperties)};if(_1.width==null&&this.width!=null){var _2=this.getInnerWidth();var _3=0;if(this.icons&&this.icons.length>0){for(var i=0;i<this.icons.length;i++){_3+=this.getIconWidth(this.icons[i])+this.iconHSpace}}
if(!isc.isA.Number(_2)){_1.width=_2}else{_1.width=Math.max(1,_2-_3)}}
this.canvas=this.addAutoChild(this.$77l,_1,this.buttonConstructor,this.container);this.autoDestroy=true;this.Super("$18y",arguments);if(this._value!=null)this.setValue(this._value)},isc.A.$21j=function isc_PickTreeItem__itemSelected(_1){var _2=this.$21m(_1);this.$93r=_1;var _3=this.$10y(_2);if(_3==false)delete this.$93r;if(this.getValue()!=_2)_3=false;return _3},isc.A.saveValue=function isc_PickTreeItem_saveValue(_1,_2){if(this.$93r!=null){this.$21n=this.$93r;delete this.$93r}else{this.$21n=this.$21s(_1);if(this.canvas){this.canvas.setSelectedItem(this.$21n)}}
return this.Super("saveValue",arguments)},isc.A.showValue=function isc_PickTreeItem_showValue(_1,_2){var _3=this.$21s(_2);if(_3!=null){this.canvas.setSelectedItem(_3)}else{var _4=this.$1605(_2,true);this.canvas.setTitle(_4)}},isc.A.$1605=function isc_PickTreeItem__getDisplayValueForOldValueHover(_1,_2){var _3;if(!_2&&(_3=this.$21s(_1))!=null){return this.canvas.$161k(_3)}else{var _4=this.optionDataSource||this.dataSource;var _5=!_4||(this.$17b(_1,true)!==null),_6=_5?_1:"";return _6}},isc.A.$1608=function isc_PickTreeItem__defaultPendingStatusChangedBehavior(_1){this.Super("$1608",arguments);var _2=this.pendingButtonStyle;if(_2==null)return;var _3;if(this.buttonProperties!=null&&this.buttonProperties.baseStyle!=null){_3=this.buttonProperties.baseStyle}else if(this.buttonDefaults!=null&&this.buttonDefaults.baseStyle!=null){_3=this.buttonDefaults.baseStyle}else{var _4=isc.ClassFactory.getClass(this.getAutoChildClass(this.$77l,isc.IButton));_3=_4.$b4.baseStyle}
if(_2===_3)return;this.button.setBaseStyle(_1?_2:_3)},isc.A.$21m=function isc_PickTreeItem__mapNodeToValue(_1){if(this.$21o())return this.valueTree.getPath(_1);return _1[this.$21p()]},isc.A.$21o=function isc_PickTreeItem__usePathAsId(){return(!this.valueField&&this.valueTree&&(this.valueTree.modelType!="parent"))},isc.A.$21p=function isc_PickTreeItem__getValueFieldName(){var _1=this.valueField;if(!_1){_1=this.valueTree?this.valueTree.idField:this.$21q()}
return _1},isc.A.$21q=function isc_PickTreeItem__getPrimaryKeyFieldName(){if(!this.getOptionDataSource())return null;if(!this.$21r){var _1=isc.DataSource.getDataSource(this.getOptionDataSource()),_2=_1.getPrimaryKeyFieldNames(),_3=isc.isAn.Array(_2)?_2[0]:_2;if(isc.isAn.Array(_2)&&_2.length>1){this.logWarn("Multiple primary key fields not supported by PickTreeItem - using '"+_3+"' as single primary key field")}
this.$21r=_3}
return this.$21r},isc.A.getSelectedNode=function isc_PickTreeItem_getSelectedNode(){return this.$21n},isc.A.getSelectedRecord=function isc_PickTreeItem_getSelectedRecord(){return this.getSelectedNode()},isc.A.updateValueMap=function isc_PickTreeItem_updateValueMap(_1){this.Super("updateValueMap",arguments);if(_1)this.canvas.markForRedraw()},isc.A.$21s=function isc_PickTreeItem__getNode(_1){if(!_1)return null;var _2=(this.getOptionDataSource()&&this.canvas?this.canvas.getTree():this.valueTree);if(this.$21o())return this.valueTree.find(_1);return _2.find(this.$21p(),_1)},isc.A.$85m=function isc_PickTreeItem__shouldAllowExpressions(){return false},isc.A.fetchData=function isc_PickTreeItem_fetchData(){var _1=this.getOptionDataSource();if(_1==null){this.logWarn("fetchData() called on pickTree item with no option data source. Ignoring.");return}
var _2=this.canvas.getTree();if(!_2||!_2.invalidateCache){return}
_2.invalidateCache()},isc.A.$1054=function isc_PickTreeItem__getEmptyDisplayValue(){if(this.emptyDisplayValue!=null){return this.emptyDisplayValue}else{var _1=isc[this.buttonConstructor],_2=_1&&_1.getInstanceProperty("unselectedTitle");return _2||""}},isc.A.setEmptyDisplayValue=function isc_PickTreeItem_setEmptyDisplayValue(_1){this.emptyDisplayValue=_1;if(this.button!=null){this.button.unselectedTitle=this.$1054()}});isc.B._maxIndex=isc.C+22;isc.defineClass("IPickTreeItem","PickTreeItem");isc.A=isc.IPickTreeItem.getPrototype();isc.A.buttonConstructor="ITreeMenuButton"}
isc.ClassFactory.defineClass("PopUpTextAreaItem","StaticTextItem");isc.A=isc.PopUpTextAreaItem.getPrototype();isc.A.canFocus=true;isc.A.wrap=false;isc.A.width=150;isc.A.clipValue=true;isc.A.popUpOnEnter=false;isc.A.popUpOnAnyClick=true;isc.A.textAreaWidth=100;isc.A.textAreaHeight=100;isc.A.iconOnly=false;isc.A.popUpIconSrc="[SKIN]/DynamicForm/PopUpTextAreaEditor_icon.gif";isc.A.popUpIconWidth=20;isc.A.popUpIconHeight=20;isc.A.iconVAlign=isc.Canvas.CENTER;isc.A=isc.PopUpTextAreaItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.$14v=function isc_PopUpTextAreaItem__setUpIcons(){if(this.icons==null)this.icons=[];var _1={name:"popUpIcon",src:this.popUpIconSrc,showOver:false,width:this.popUpIconWidth,height:this.popUpIconHeight,click:this.$43p};this.icons.addAt(_1,0);this.Super("$14v",arguments)},isc.A.$43p=function isc_PopUpTextAreaItem__popUpIconClick(_1,_2,_3){if(_2.popUpOnAnyClick||_2.isDisabled()||_2.isReadOnly())return;_2.showPopUp(true)},isc.A.handleCellClick=function isc_PopUpTextAreaItem_handleCellClick(){if(this.Super("handleCellClick")==false)return false;if(this.popUpOnAnyClick&&!this.isDisabled()&&!this.isReadOnly())this.showPopUp(true)},isc.A.showPopUp=function isc_PopUpTextAreaItem_showPopUp(_1){var _2=this.getValue();if(!this.$21t)this.setupPopUpForm();if(!this.$21t.isDrawn()){this.$21t.draw()}
this.placePopUp();var _3=this.$21t.getItem("textArea");_3.setValue(_2);this.$21t.bringToFront();this.$21t.show();if(_1)this.$21t.delayCall("focusInItem",["textArea"]);this.$21t.showClickMask({target:this,methodName:"hidePopUp"},true,[this.$21t])},isc.A.visibilityChanged=function isc_PopUpTextAreaItem_visibilityChanged(){if(!this.isVisible())this.$21u()},isc.A.$21u=function isc_PopUpTextAreaItem__hiddenObservation(){var _1=this.$21t;if(!_1||!(_1.isVisible()&&_1.isDrawn()))return;_1.clear()},isc.A.moved=function isc_PopUpTextAreaItem_moved(){this.$21v()},isc.A.$21v=function isc_PopUpTextAreaItem__movedObservation(){var _1=this.$21t;if(!_1||!(_1.isVisible()&&_1.isDrawn()))return;var _2=this.getTop(),_3=this.getLeft(),_4=this.getInnerWidth(),_5=this.getInnerHeight(),_6=this.containerWidget,_7=_6.getScrollTop(),_8=_6.getScrollLeft(),_9=_6.getViewportWidth(),_10=_6.getViewportHeight();if(_2<_7||(_2+_5)>(_7+_10)||_3<_8||(_3+_4)>(_8+_9))
{_1.clear()}else{this.placePopUp()}},isc.A.zIndexChanged=function isc_PopUpTextAreaItem_zIndexChanged(){var _1=this.$21t;if(!_1||!(_1.isVisible()&&_1.isDrawn()))return;_1.bringToFront()},isc.A.placePopUp=function isc_PopUpTextAreaItem_placePopUp(){var _1=this.getTextAreaTop(),_2=this.getTextAreaLeft(),_3=this.getTextAreaWidth(),_4=this.getTextAreaHeight();this.$21t.moveTo(_2,_1);this.$21t.resizeTo(_3,_4);var _5=this.$21t.getItem("textArea");_5.setWidth(_3);_5.setHeight(_4)},isc.A.setupPopUpForm=function isc_PopUpTextAreaItem_setupPopUpForm(){if(this.$21t!=null)return;var _1=isc.DynamicForm.create({autoDraw:false,ID:this.getID()+"$21t",_generated:true,separateContentInsertion:false,cellPadding:0,targetItem:this,values:{textArea:this.getValue()},items:[{name:"textArea",showTitle:false,type:"textArea",selectOnFocus:true,targetItem:this,focus:function(_4){this.targetItem.textAreaFocus()},keyDown:function(_4,_5,_6,_7){this.targetItem.$18i();return this.targetItem.textAreaKeyDown(_4,_6,_7)},keyPress:function(_4,_5,_6,_7){return this.targetItem.textAreaKeyPress(_4,_6,_7)},blur:function(){this.targetItem.textAreaBlur()}}],hide:function(_4,_5,_6,_7){var _2=this.invokeSuper(isc.DynamicForm,"hide",_4,_5,_6,_7);this.hideClickMask();return _2},clear:function(_4,_5,_6,_7){var _2=this.invokeSuper(isc.DynamicForm,"clear",_4,_5,_6,_7);this.hideClickMask();return _2}});this.$21t=_1;var _3=this.containerWidget;_1.observe(_3,"destroy","observer.clear();observer.destroy()")},isc.A.hidePopUp=function isc_PopUpTextAreaItem_hidePopUp(){if(this.$21t){this.updateValue();this.$21t.clear()}},isc.A.destroy=function isc_PopUpTextAreaItem_destroy(){if(this.$21t){this.$21t.destroy();delete this.$21t}
return this.Super("destroy",arguments)},isc.A.getTextAreaTop=function isc_PopUpTextAreaItem_getTextAreaTop(){var _1=this.getPageTop();if(isc.Browser.isIE)_1-=1;return _1},isc.A.getTextAreaLeft=function isc_PopUpTextAreaItem_getTextAreaLeft(){return this.getPageLeft()},isc.A.getTextAreaWidth=function isc_PopUpTextAreaItem_getTextAreaWidth(){return Math.max(this.textAreaWidth,this.getInnerWidth())},isc.A.getTextAreaHeight=function isc_PopUpTextAreaItem_getTextAreaHeight(){return this.textAreaHeight},isc.A.mapValueToDisplay=function isc_PopUpTextAreaItem_mapValueToDisplay(){if(this.iconOnly)return"";return this.Super("mapValueToDisplay",arguments)},isc.A.textAreaBlur=function isc_PopUpTextAreaItem_textAreaBlur(){this.hidePopUp()},isc.A.textAreaFocus=function isc_PopUpTextAreaItem_textAreaFocus(){},isc.A.textAreaKeyPress=function isc_PopUpTextAreaItem_textAreaKeyPress(_1,_2,_3){},isc.A.textAreaKeyDown=function isc_PopUpTextAreaItem_textAreaKeyDown(_1,_2,_3){},isc.A.setValue=function isc_PopUpTextAreaItem_setValue(_1){var _2=this.mapValueToDisplay(this.getValue());this.Super("setValue",arguments);var _3=this.mapValueToDisplay(this.getValue());if(_2!=_3){this.setElementValue(_3)
if(this.$21t&&this.$21t.isVisible()){this.$21t.setValue("textArea",_3)}}},isc.A.updateValue=function isc_PopUpTextAreaItem_updateValue(){if(this.$21t&&this.$21t.isVisible()&&!this.$21t.$10u)
{var _1=this.$21t.getItem("textArea");_1.updateValue();var _2=this.$21t.getValue("textArea");this.setElementValue(this.mapValueToDisplay(_2));this.$10y(_2)}else{return this.Super("updateValue",arguments)}},isc.A.setElementValue=function isc_PopUpTextAreaItem_setElementValue(_1){if(this.iconOnly)return;return this.Super("setElementValue",arguments)},isc.A.focusInItem=function isc_PopUpTextAreaItem_focusInItem(){if(this.$21t&&this.$21t.isVisible()&&this.$21t.isDrawn()){this.$21t.focusInItem('textArea')}else if(this.showIcons){this.focusInIcon(this.icons[0])}else{this.showPopUp(true)}},isc.A.$173=function isc_PopUpTextAreaItem__setElementTabIndex(_1){if(!this.isVisible()||!this.containerWidget.isDrawn())return;this.$175()},isc.A.setElementReadOnly=function isc_PopUpTextAreaItem_setElementReadOnly(_1){});isc.B._maxIndex=isc.C+28;isc.defineClass("ExpressionItem","PopUpTextAreaItem");isc.A=isc.ExpressionItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.multiple=true;isc.A.textAreaWidth=400;isc.A.showActionIcon=true;isc.A.actionIconSrc="[SKIN]/actions/add.png";isc.A.actionIconWidth=20;isc.A.actionIconHeight=20;isc.A.actionIconPosition=1;isc.B.push(isc.A.mapValueToDisplay=function isc_ExpressionItem_mapValueToDisplay(_1){if(isc.isAn.Array(_1)){var _2=[];for(var i=0;i<_1.length;++i){var _4=_1[i];if(isc.isA.StringMethod(_4)){_2.add(_4.getDisplayValue())}else if(isc.isAn.Object(_4)){_2.add(this.creator.builder.getActionTitle(_4.target,_4.name))}}
return _2.join(", ")}else if(isc.isA.StringMethod(_1)){return _1.getDisplayValue()}else if(isc.isA.Function(_1)){if(_1.iscAction){var _5=this.creator.builder;if(isc.isAn.Array(_1.iscAction)){return _1.iscAction.map(function(_6){return _5.getActionTitle(_6.target,_6.name)}).join(", ")}
return _5.getActionTitle(_1.iscAction.target,_1.iscAction.name)}
return isc.Func.getBody(_1)}
else return this.Super("mapValueToDisplay",arguments)},isc.A.getValue=function isc_ExpressionItem_getValue(){var _1=this.Super("getValue");if(isc.isA.Function(_1))return isc.Func.getBody(_1);else return _1},isc.A.$14v=function isc_ExpressionItem__setUpIcons(){this.Super("$14v",arguments);if(this.showActionIcon){if(this.icons==null)this.icons=[];var _1=this.actionIconPosition;this.icons.addAt({name:"action",src:this.actionIconSrc,showOver:false,width:this.actionIconWidth,height:this.actionIconHeight,click:function(_2,_3){_3.showActionMenu();return false}},_1);this.$36c(this.icons[_1])}},isc.A.updateAppearance=function isc_ExpressionItem_updateAppearance(_1){this.setElementValue(this.mapValueToDisplay(_1))},isc.A.showActionMenu=function isc_ExpressionItem_showActionMenu(){var _1=[],_2=this.getValue();if(isc.isA.Function(_2)&&_2.iscAction!=null){_1.add(isc.StringMethod.create({value:_2.iscAction}))}else if(isc.isA.StringMethod(_2)){_1.add(_2)}else if(isc.isAn.Array(_2)){for(var i=0;i<_2.length;++i){var _4=_2[i];if(isc.isA.Function(_4)&&_4.iscAction!=null){_1.add(isc.StringMethod.create({value:_4.iscAction}))}else if(isc.isA.StringMethod(_4)){_1.add(_4)}else if(isc.isAn.Object(_4)){_1.add(isc.StringMethod.create({value:_4}))}}}else if(isc.isAn.Object(_2)){_1.add(isc.StringMethod.create({value:_2}))}
var _5=this.actionMenu;if(_5==null){var _6=this;_5=this.actionMenu=this.createAutoChild("actionMenu",{builder:this.creator.builder,sourceComponent:this.form.currentComponent,sourceMethod:this.name,components:this.form.allComponents,bindingComplete:function(_8){_6.$10y(_8)}},"ActionMenu")}
_5.currentStringMethods=_1;_5.show();var _7=this.getIconPageRect(this.icons[1]);_5.placeNear(_7[0]+_7[2],_7[1]+_7[3])});isc.B._maxIndex=isc.C+5;isc.ClassFactory.defineClass("SearchForm","DynamicForm");isc.A=isc.SearchForm.getPrototype();isc.A.canEditFieldAttribute="canFilter";isc.A.isSearchForm=true;isc.A.hiliteRequiredFields=false;isc.A.operationType="fetch";isc.A.$66m=true;isc.A.allowEmptyValues=true;isc.A.storeAtomicValues=true;isc.A=isc.SearchForm.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.$21w="DateItem";isc.A.defaultDateEditorType="DateRangeItem";isc.B.push(isc.A.createItem=function isc_SearchForm_createItem(_1,_2,_3,_4,_5){var _6=this.getDataSource(),_7=_6?_6.getField(_1[this.fieldIdProperty])!=null:false;if(_7){var _8=isc.FormItemFactory.getItemClassName(_1,_2,this),_9=isc.FormItemFactory.getItemClass(_8);if(_9==isc.DateItem&&_1&&(_1.useTextField==null))
_1.useTextField=true;if(_1.allowEmptyValue==null){_1.allowEmptyValue=this.allowEmptyValues}}
return this.invokeSuper(isc.SearchForm,"createItem",_1,_2,_3,_4,_5)},isc.A.submitValues=function isc_SearchForm_submitValues(_1,_2){if(this.search!=null){return this.search(this.getValuesAsCriteria(),this)}},isc.A.validate=function isc_SearchForm_validate(_1,_2,_3){if(this.validateTypeOnly){return this.invokeSuper(isc.SearchForm,"validate",_1,_2,true)}else{return this.invokeSuper(isc.SearchForm,"validate",_1,_2,_3)}},isc.A.getEditorType=function isc_SearchForm_getEditorType(_1){var _2=_1.filterEditorType||_1.editorType;if(_2==isc.DynamicForm.$178h){_2=null}
if(_2!=null)return _2;var _3=_1.type;if(_3&&isc.SimpleType.inheritsFrom(_3,"date")){return this.defaultDateEditorType}
var _4=_3==isc.SearchForm.$12e||_3==isc.SearchForm.$52x||_3==isc.SearchForm.$677;if(_4)return"StaticTextItem";return this.Super("getEditorType",arguments)});isc.B._maxIndex=isc.C+4;isc.A=isc.SearchForm.getPrototype();isc.A.showFilterFieldsOnly=true;isc.A.validateTypeOnly=true;isc.SearchForm.registerStringMethods({search:"criteria,form"});isc.ClassFactory.defineClass("ValuesManager");isc.A=isc.ValuesManager;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.getById=function isc_c_ValuesManager_getById(_1){var _2=window[_1]||null;return _2?(isc.isA.ValuesManager(_2)?_2:null):null});isc.B._maxIndex=isc.C+1;isc.A=isc.ValuesManager.getPrototype();isc.A.unknownErrorMessage=null;isc.A=isc.ValuesManager.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.operator="and";isc.B.push(isc.A.init=function isc_ValuesManager_init(){this.ns.ClassFactory.addGlobalID(this);if(this.unknownErrorMessage==null){this.unknownErrorMessage=isc.Canvas.getPrototype().unknownErrorMessage}
if(this.dataSource)this.bindToDataSource(this.dataSource);if(this.values==null)this.values={};isc.DynamicForm.$91f(this,this.values,{});if(this.members!=null){var _1=this.members;this.members=null;if(!isc.isAn.Array(_1))_1=[_1];for(var i=0;i<_1.length;i++){this.addMember(_1[i])}}
this.rememberValues()},isc.A.destroy=function isc_ValuesManager_destroy(){var _1=this.members;if(_1){for(var i=_1.length-1;i>=0;i--){this.removeMember(_1[i])}}
window[this.getID()]=null;this.Super("destroy",arguments)},isc.A.$49z=function isc_ValuesManager__saveDataReply(_1,_2,_3){var _4=this.getMembers();if(!this.suppressServerDataSync&&_2&&_2.status>=0&&_3!=null){if(isc.isAn.Array(_3))_3=_3[0];if(_1.data)_1.data=isc.shallowClone(_1.data);var _5=false;for(var i=0;i<_4.length;i++){var _7=_4[i].dataPath;if(_7!=null&&_7!="/"){_5=true}else if(isc.isA.DynamicForm(_4[i])){var _8=_4[i].getItems(),_9=_8.getProperty("dataPath");for(var _10=0;_10<_9.length;_10++){if(_9[_10]!=null&&_9[_10]!="/"){_5=true;break}}}
if(_5)break}
if(_5){this.setValues(_3)}else{var _11=(_1.originalData||_1.data),_12=this.getValues();var _13=false,_14=true,_15;for(var _16 in _3){var _17=_11[_16]===_15?this.$10s[_16]:_11[_16];var _18=this.getField(_16);if(this.fieldValuesAreEqual(_18,_12[_16],_17)){if(!this.fieldValuesAreEqual(_18,_17,_3[_16])){_12[_16]=_3[_16];_13=true}}else{_14=false}}
if(_13){this.$10r(_12)}
var _8=this.getItems();for(var i=0;i<_8.length;i++){var _19=_8[i];if(isc.isAn.UploadItem(_19))continue;var _20=_19.dataPath||_19.name;if(_20==null)continue;var _21=isc.DynamicForm.$70o(_20,_19,_11,this,true,"edit");if(_21===_15||this.fieldValuesAreEqual(_19,_21,_19.getValue()))
{if(_13){var _22=isc.DynamicForm.$70o(_20,_19,_3,this,true,"edit");if(!this.fieldValuesAreEqual(_19,_21,_22)){_19.setValue(_22)}}}else{_14=false}}
if(_14){this.rememberValues()}}
if(this.saveOperationType=="add")delete this.saveOperationType;var _23=(this.members?this.members.duplicate():[]);for(var i=0;i<_23.length;i++){var _24=_23[i];if(!isc.isA.DynamicForm(_24))continue;_24.saveOperationType=null}}
this.$491={request:_1,response:_2,serverData:_3};this.$490=0;this.$181w=true;for(var i=0;i<_4.length;i++){if(_4[i]&&_4[i].updatePendingStyles)_4[i].updatePendingStyles()}
delete this.$181w;this.formSavedComplete()},isc.A.$71e=function isc_ValuesManager__updateMultipleMemberValue(_1,_2,_3,_4){_2=(_2!=null)?this.$702(_1,_2):_1;return this.$10y(_2,_3,_4)},isc.A.$10y=function isc_ValuesManager__updateValue(_1,_2,_3){if(this.$835)return;var _4=isc.isA.Number(_1);if(!_4&&isc.isA.DynamicForm(_3)&&_3.getItem(_1)==null){this.$66q(_3,_1);return}
var _5;var _6=_3.getFullDataPath();var _7;if(_3&&_3.getField){_7=_3.getField(_1)}
if(!_4){if(_1!=null&&!isc.isA.String(_1)){_1=_1.dataPath||_1.name}
if(_1){if(_6==null||_1.startsWith(isc.Canvas.$70l)){_6=_1}else{_6=this.$702(_6,_1)}}
if(_7==null){var _8=this.getDataSource();if(_8)_7=_8.getFieldForDataPath(_6)}}else{if(!_6){_6=_1}else if(!_6.endsWith(isc.Canvas.$70l)){_6+=isc.Canvas.$70l+_1}else{_6+=_1}}
isc.DynamicForm.$70n(_6,_7,_2,this.values,_3,true,"vm_updateValue");var _5=_6.contains(isc.Canvas.$70l);if(_5&&this.autoSynchronize!==false){var _9=_6.split(isc.Canvas.$70l);if(parseInt(_9[_9.length-1])==_9[_9.length-1]){this.synchronizeMembers(_3)}else{var _10=this.getFieldsForDataPath(_6||_1);this.$835=true;for(var i=0;i<_10.length;i++){if(_10[i].form==_3)continue;_10[i].saveValue(_2)}
delete this.$835}}},isc.A.synchronizeMembers=function isc_ValuesManager_synchronizeMembers(_1){if(!this.members)return;for(var i=0;i<this.members.length;i++){if(!_1||this.members[i].selectionComponent==_1){this.synchronizeMember(this.members[i])}}},isc.A.synchronizeMembersOnDataPath=function isc_ValuesManager_synchronizeMembersOnDataPath(_1){if(!this.members)return;for(var i=0;i<this.members.length;i++){if(this.members[i].dataPath==_1){this.synchronizeMember(this.members[i])}}},isc.A.synchronizeMember=function isc_ValuesManager_synchronizeMember(_1,_2){if(!_1)return;if(!this.members||!this.members.contains(_1)){this.logWarn("synchronizeMember called with component ID "+_1.ID+".  This component is not a member of this valuesManager");return}
this.$835=true;this.$707(_1,_2);delete this.$835;if(this.memberSynchronized&&isc.isA.Function(this.memberSynchronized)){this.memberSynchronized(_1)}},isc.A.$702=function isc_ValuesManager__combineDataPaths(_1,_2){if(isc.isAn.Object(_2)){_2=_2.dataPath||_2.name}
return isc.DynamicForm.$702(_1,_2)},isc.A.$66q=function isc_ValuesManager__itemlessValueWarning(_1,_2){this.logWarn("Member Form: "+_1+" has explicitly specified value for field[s] '"+_2+"', but has no item associated with this fieldName. Ignoring this value. Values may be set for fields with no associated form item directly on the valuesManager via valuesManager.setValues(), but not on member forms. See ValuesManager documentation for more info.")},isc.A.$10z=function isc_ValuesManager__clearValue(_1,_2){var _3=_2.getFullDataPath();if(_3)_1=this.$702(_3,_1);return isc.DynamicForm.$70m(_1,this.values)},isc.A.bindToDataSource=function isc_ValuesManager_bindToDataSource(_1){if(!isc.isA.DataSource(_1))_1=isc.DataSource.getDataSource(_1);if(_1!=null)this.dataSource=_1},isc.A.setDataSource=function isc_ValuesManager_setDataSource(_1,_2){this.bindToDataSource(_1)},isc.A.getDataSource=function isc_ValuesManager_getDataSource(){if(isc.isA.String(this.dataSource)){if(this.serviceNamespace||this.serviceName){this.dataSource=this.lookupSchema()}else{var _1=isc.DS.get(this.dataSource);if(_1!=null)return _1;_1=this.getWindow()[this.dataSource];if(_1&&isc.isA.DataSource(_1))return(this.dataSource=_1)}}
return this.dataSource},isc.A.lookupSchema=function isc_ValuesManager_lookupSchema(){var _1;if(this.serviceName)_1=isc.WebService.getByName(this.serviceName,this.serviceNamespace);else _1=isc.WebService.get(this.serviceNamespace);if((this.serviceNamespace||this.serviceName)&&_1==null){this.logWarn("Could not find WebService definition: "+(this.serviceName?"serviceName: "+this.serviceName:"")+(this.serviceNamespace?"   serviceNamespace: "+this.serviceNamespace:"")+this.getStackTrace())}
if(!isc.isA.String(this.dataSource)){this.logWarn("this.dataSource was not a String in lookupSchema");return}
if(_1)return _1.getSchema(this.dataSource)},isc.A.getDataSourceField=function isc_ValuesManager_getDataSourceField(_1){var _2=this.getDataSource();if(!_2||!_1)return null;_1=_1.trim("/");var _3=this.getDataSource(),_4=_1.split("/"),_5;for(var i=0;i<_4.length;i++){if(isc.isAn.emptyString(_4[i]))continue;var _7=_4[i];_5=_3.getField(_7);_3=_5?isc.DataSource.getDataSource(_5.type):_3}
return _5},isc.A.getItems=function isc_ValuesManager_getItems(){if(!this.members)return[];var _1=[];for(var i=0;i<this.members.length;i++){var _3=this.members[i];if(!_3.getItems)continue;_1.addList(_3.getItems())}
return _1},isc.A.getFields=function isc_ValuesManager_getFields(){return this.getItems()},isc.A.getItem=function isc_ValuesManager_getItem(_1,_2){return this.$706(_1,true,_2)},isc.A.getField=function isc_ValuesManager_getField(_1){return this.getItem(_1)},isc.A.getFieldsForDataPath=function isc_ValuesManager_getFieldsForDataPath(_1){return this.getItem(_1,true)},isc.A.getMembers=function isc_ValuesManager_getMembers(){return this.members},isc.A.getMember=function isc_ValuesManager_getMember(_1){var _2=window[_1];if(this.members&&this.members.contains(_2))return _2;return null},isc.A.getMemberForField=function isc_ValuesManager_getMemberForField(_1,_2){return this.$706(_1,false,_2)},isc.A.$706=function isc_ValuesManager__findMemberByField(_1,_2,_3){if(!this.members||_1==null||isc.isAn.emptyString(_1))return null;var _4=_1.trim(isc.Canvas.$70l);var _5=_4.split(isc.Canvas.$70l);var _6=_3?[]:null;for(var i=0;i<this.members.length;i++){var _8=this.members[i],_9=_8.getFullDataPath();if(_9==isc.Canvas.$70l||isc.isAn.emptyString(_9)){_9=null}else if(_9!=null){_9=_9.trim(isc.Canvas.$70l)}
if(_5&&_5.length>0&&_9!=null){var _10=null;for(var _11=0;_11<_5.length;_11++){_10=!_10?_5[_11]:(_10+isc.Canvas.$70l+_5[_11]);if(_9.endsWith(isc.Canvas.$70l)){_9=_9.substring(0,_9.length-1)}
if(_9==_10){if(!_2&&(_11==_5.length-1)){if(!_3)return _8;_6.add(_8);break}
if(_8.getField){var _12=_5.slice(_11+1).join(isc.Canvas.$70l);var _13=_8.getField(_12);if(_13){if(_2){if(!isc.isA.FormItem(_13))_13=null;if(_3){if(_13)_6.add(_13)}else{return _13}}else{if(_3)_6.add(_8);else return _8}}}}}}else{if(this.members[i].getItem){var _14=this.members[i].getField(_1);if(!_14){if(_1.startsWith(isc.Canvas.$70l)){_14=this.members[i].getField(_1.substring(1))}}
if(_14){if(_2){if(!isc.isA.FormItem(_14))_14=null;if(_3){if(_14)_6.add(_14)}else{return _14}}else{if(_3)_6.add(_8);else return _8}}}}}
return _3?_6:null},isc.A.getFileItemForm=function isc_ValuesManager_getFileItemForm(){if(!this.members)return;var _1=false,_2;for(var i=0;i<this.members.length;i++){if(this.members[i].getFileItemForm==null)continue;var _4=this.members[i].getFileItemForm();if(_4){if(_1){this.logWarn("ValuesManager defined with more than one member form  containing a FileItem. This is not supported - binary data may only be uploaded from one FileItem when saving ValuesManager data")}else{_2=_4;_1=true}}}
return _2},isc.A.validate=function isc_ValuesManager_validate(_1,_2,_3,_4,_5,_6){if(this.disableValidation)return true;if(this.dataSource&&this.dataSource.useLocalValidators!=null&&this.useLocalValidators==false)return true;var _7=this.hasErrors();this.clearHiddenErrors();var _8=true,_9=this.dataSource?isc.addProperties({},this.getDataSource().getFields()):null,_10={},_11={},_12=false;this.buildDataPathsRecursively(_11,"",this.getDataSource());if(!_5)this.$178d=[];else delete this.$178d;var _13=this.$178d;if(this.members){var _14=isc.rpc?isc.rpc.startQueue():false;for(var i=0;i<this.members.length;i++){if(!isc.isA.DynamicForm(this.members[i]))continue;var _16=this.members[i],_17=_16.disableValidation,_18=this.members[i].getItems();if(!_17){if(_16.handleHiddenValidationErrors!=null){this.logInfo("form level 'handleHiddenValidationErrors' method suppressed in favor of valuesManager level handler","validation");_16.$43q=_16.handleHiddenValidationErrors}
_16.handleHiddenValidationErrors=this.$43r}
for(var j=0;j<_18.length;j++){var _20=_18[j].getFullDataPath()||_18[j].getFieldName();_12=_12||(_20&&_20.contains(isc.Canvas.$70l));if(_9&&this.members[i].getDataSource()==this.getDataSource()){delete _9[_20]}
if(_11&&_20){delete _11[_20.trim(isc.Canvas.$70l)]}}
var _21=_17?true:_16.validate(true,true,_3,_4,_5,true,_13);_8=(_8&&_21);if(!_17){if(_16.$43s)_16.handleHiddenValidationErrors=_16.$43s;else delete _16.handleHiddenValidationErrors}
if(!_21){if(!(_16.isDrawn()&&_16.isVisible())){this.addHiddenErrors(_16.errors,_16)}else{this.addHiddenErrors(_16.getHiddenErrors(),_16)}}}
if(!_14&&isc.rpc)isc.rpc.sendQueue()}
var _22=this.getValues(),_23={},_24=_12?_11:_9;for(var _20 in _24){var _25=_24[_20],_10=_25.validators,_26=isc.DynamicForm.$70o(_20,_25,_22,null,true,"validate");if(_10!=null){for(var i=0;i<_10.length;i++){var _27=_10[i];if(!_27)continue;if(_26==null&&_27.type!='required'&&_27.type!="requiredIf")
{continue}
if(!this.processValidator(_25,_27,_26,null,_22)){if(_23[_20]==null)_23[_20]=[];var _28=_27.errorMessage||this.unknownErrorMessage;_23[_20].add(_28)}}}
if(_23[_20]&&_23[_20].length==1)_23[_20]=_23[_20][0]}
this.addHiddenErrors(_23);var _29=this.hasErrors();if(_7||_29){this.showErrors(true)}
if(isc.getKeys(_23).length>0)_8=false;return _8},isc.A.buildDataPathsRecursively=function isc_ValuesManager_buildDataPathsRecursively(_1,_2,_3){if(!isc.isA.DataSource(_3))return;if(_3.$85e){this.logWarn("detected ds loop at: "+_2+", refusing to recurse further");return}
_3.$85e=true;var _4=_3.getFields();for(var _5 in _4){_1[_2+_5]=_4[_5];if(_3.fieldIsComplexType(_5)){var _6=_3.getSchema(_4[_5].type);this.buildDataPathsRecursively(_1,_2+_5+isc.Canvas.$70l,_6)}}
delete _3.$85e},isc.A.getValidatedValues=function isc_ValuesManager_getValidatedValues(){if(!this.validate())return null;return this.getValues()},isc.A.$43r=function isc_ValuesManager__handleHiddenFormErrors(_1){var _2=this.valuesManager;_2.addHiddenErrors(_1,this);return false},isc.A.clearHiddenErrors=function isc_ValuesManager_clearHiddenErrors(){delete this.hiddenErrors},isc.A.addHiddenErrors=function isc_ValuesManager_addHiddenErrors(_1,_2){if(_1==null||isc.isAn.emptyObject(_1))return;if(!this.hiddenErrors)this.hiddenErrors={};if(_2){if(isc.isA.Canvas(_2))_2=_2.getID()}else _2=this.getID();if(!this.hiddenErrors[_2])this.hiddenErrors[_2]={};for(var _3 in _1){this.hiddenErrors[_2][_3]=this.$43t(this.hiddenErrors[_2][_3],_1[_3])}},isc.A.getHiddenErrors=function isc_ValuesManager_getHiddenErrors(_1){if(!_1){this.synchHiddenErrors()}
if(!this.hiddenErrors)return null;var _2={};for(var _3 in this.hiddenErrors){this.assembleHiddenErrorsRecursively(_2,this.hiddenErrors[_3])}
return _2},isc.A.assembleHiddenErrorsRecursively=function isc_ValuesManager_assembleHiddenErrorsRecursively(_1,_2,_3,_4){if(_3==null)_3="";var _5=_3;if(_4!=null)_5+="["+_4+"]";if(isc.isA.List(_2)){for(var i=0;i<_2.length;i++){if(_2[i]!==null){if(isc.isAn.Object(_2[i])){this.assembleHiddenErrorsRecursively(_1,_2[i],_5,i)}else{if(_1[_5]==null)_1[_5]=[];_1[_5][i]=_2[i]}}}}else if(isc.isAn.Object(_2)){for(var _7 in _2){if(isc.isAn.Object(_2[_7])){if(_5==""){this.assembleHiddenErrorsRecursively(_1,_2[_7],_7)}else{this.assembleHiddenErrorsRecursively(_1,_2[_7],_5+isc.Canvas.$70l+_7)}}else{if(_5==""){_1[_7]=_2[_7]}else{_1[_5+isc.Canvas.$70l+_7]=_2[_7]}}}}else{_1[_5]=_2}
return _1},isc.A.synchHiddenErrors=function isc_ValuesManager_synchHiddenErrors(){var _1=this.hiddenErrors,_2=this.getID();if(_1&&_1[_2]){for(var _3 in _1[_2]){var _4=_1[_2][_3],_5=this.getItem(_3),_6=_5?_5.form:null;if(_5){_6.addFieldErrors(_3,_4);delete _1[_2][_3]}}}
var _7=_1[_2];_1=this.hiddenErrors={};if(_7)_1[_2]=_7;if(this.members){for(var i=0;i<this.members.length;i++){if(!isc.isA.DynamicForm(this.members[i]))continue;var _9=this.members[i],_10=_9.getID(),_11=_9.errors;if(!_11||isc.isAn.emptyObject(_11))continue;if(!_9.isVisible()||!_9.isDrawn()){_11=isc.addProperties({},_11);_1[_10]=_11}else{for(var _3 in _11){var _5=_9.getItem(_3);if(!_5){if(!_1[_2])_1[_2]={};_1[_2][_3]=_11[_3];delete _11[_3]}else if(!_5.visible){if(!_1[_10])_1[_10]={};_1[_10][_3]=_11[_3]}}}}}},isc.A.processValidator=function isc_ValuesManager_processValidator(_1,_2,_3,_4,_5){return isc.Validator.processValidator(_1,_2,_3,_4,_5)},isc.A.$21z=function isc_ValuesManager__handleHiddenValidationErrors(_1){var _2=this.getHiddenErrors(_1);if(_2==null||isc.getKeys(_2).length==0)return;var _3;if(this.handleHiddenValidationErrors){_3=this.handleHiddenValidationErrors(_2)}
if(_3==false)return;var _4="Validation failed with the following errors:";var _5=isc.isAn.Array(_2)?_2:[_2];for(var i=0;i<_5.length;i++){var _7=_5[i];for(var _8 in _7){var _9=_2[_8];if(!isc.isAn.Array(_9))_9=[_9];if(_9.length==0)continue;_4+="\n"+_8+":";for(var i=0;i<_9.length;i++){_4+=(i==0?"- ":"\n - ")+_9[i]}}}
this.logInfo(_4,"validation")},isc.A.setErrors=function isc_ValuesManager_setErrors(_1,_2){this.clearHiddenErrors();if(isc.isA.List(_1))_1=_1[0];var _3=(this.members?this.members.duplicate():[]);for(var i=0;i<_3.length;i++){if(!isc.isA.DynamicForm(_3[i]))continue;var _5=_3[i],_6=!_5.isVisible()||!_5.isDrawn(),_7=_5.getItems(),_8={},_9={},_10=_5.getSelectionChain();for(var j=0;j<_7.getLength();j++){var _12=_7[j],_13=_12.getFullDataPath(),_14=_12.getFieldName(),_15=this.getItemErrors(_1,_13,_10);if(_15!=null){_8[_14]=_15;if(_6||!_12.visible){_9[_14]=_15}
this.deleteItemErrors(_1,_13,_10)}}
_5.setErrors(_8,false);if(!isc.isAn.emptyObject(_9))
this.addHiddenErrors(_9,_5)}
this.addHiddenErrors(_1);if(_2)this.showErrors(true)},isc.A.getItemErrors=function isc_ValuesManager_getItemErrors(_1,_2,_3){var _4=_2.trim(isc.Canvas.$70l),_5=_4.contains(isc.Canvas.$70l);if(isc.isAn.Array(_1))_1=_1[0];if(!_5){var _6=_1[_2]}else{var _7=_4.split(isc.Canvas.$70l),_6=_1,_8=0;for(var i=0;i<_7.length;i++){_6=_6[_7[i]];if(isc.isAn.Array(_6)){if(_3.length>_8){_6=_6[_3[_8++]]}else{_6=_6[0]}}
if(!_6)break}}
if(_6){if(!isc.isAn.Array(_6))_6=[_6];var _10=[];for(var i=0;i<_6.length;i++){if(_6[i].errorMessage){_10.add(_6[i].errorMessage)}else{_10.add(_6[i])}}
return _10.length>1?_10:_10[0]}},isc.A.deleteItemErrors=function isc_ValuesManager_deleteItemErrors(_1,_2,_3){var _4=_2.trim(isc.Canvas.$70l),_5=_4.contains(isc.Canvas.$70l);if(isc.isAn.Array(_1))_1=_1[0];if(!_5){delete _1[_2]}else{var _6=_4.split(isc.Canvas.$70l);var _7=_1,_8=[],_9=0;for(var i=0;i<_6.length;i++){_8.add(_7);_7=_7[_6[i]];if(isc.isAn.Array(_7)){if(_3.length>_9){_7=_7[_3[_9++]]}else{_7=_7[0]}}
if(!_7)break}
if(_7)delete _7;for(var i=_8.length-1;i>=0;i--){if(isc.isAn.emptyObject(_8[i])){delete _8[i]}}}},isc.A.$43t=function isc_ValuesManager__addFieldErrors(_1,_2){if(!_1)return _2;if(!_2)return _1;if(!isc.isAn.Array(_1))_1=[_1];if(isc.isA.String(_2))_1.add(_2);else _1.addList(_2);return _1},isc.A.addFieldErrors=function isc_ValuesManager_addFieldErrors(_1,_2,_3){var _4=true;var _5=this.getMemberForField(_1);if(_5!=null&&isc.isA.DynamicForm(_5)){_5.addFieldErrors(_1,_2,false);var _6=_5.getItem();if(_5.isVisible()&&_5.isDrawn()&&_6&&_6.visible){_4=false}}
if(_4){if(!this.hiddenErrors)this.hiddenErrors={};var _7=_5?_5.getID():this.getID();if(!this.hiddenErrors[_7])this.hiddenErrors[_7]={};this.hiddenErrors[_7][_1]=this.$43t(this.hiddenErrors[_7][_1],_2)}
if(_3)this.showFieldErrors(_1)},isc.A.setFieldErrors=function isc_ValuesManager_setFieldErrors(_1,_2,_3){var _4=true;var _5=this.getMemberForField(_1);if(_5!=null&&isc.isA.DynamicForm(_5)){_5.setFieldErrors(_1,_2,false);var _6=_5.getItem();if(_5.isVisible()&&_5.isDrawn()&&_6&&_6.visible){_4=false}}
if(_4){if(!this.hiddenErrors)this.hiddenErrors={};this.hiddenErrors[_1]=_2}
if(_3)this.showFieldErrors(_1)},isc.A.clearErrors=function isc_ValuesManager_clearErrors(_1){this.setErrors({},_1)},isc.A.clearFieldErrors=function isc_ValuesManager_clearFieldErrors(_1,_2){var _3=this.getMemberForField(_1);if(_3&&isc.isA.DynamicForm(_3))_3.clearFieldErrors(_1,_2);if(this.hiddenErrors)delete this.hiddenErrors[_1]},isc.A.getErrors=function isc_ValuesManager_getErrors(){var _1=isc.addProperties({},this.getHiddenErrors(true));if(this.members){for(var i=0;i<this.members.length;i++){if(!isc.isA.DynamicForm(this.members[i]))continue;isc.addProperties(_1,this.members[i].getErrors())}}
if(!isc.isA.emptyObject(_1))return _1
return null},isc.A.getFieldErrors=function isc_ValuesManager_getFieldErrors(_1){var _2=this.getMemberForField(_1)
if(_2&&isc.isA.DynamicForm(_2))return _2.getFieldErrors(_1);if(this.hiddenErrors&&this.hiddenErrors[this.getID()])
return this.hiddenErrors[this.getID()][_1]},isc.A.hasErrors=function isc_ValuesManager_hasErrors(){if(this.hiddenErrors&&!isc.isA.emptyObject(this.hiddenErrors)){for(var _1 in this.hiddenErrors){if(this.hiddenErrors[_1]&&!isc.isAn.emptyObject(this.hiddenErrors[_1]))
return true}}
if(this.members==null)return false;for(var i=0;i<this.members.length;i++){if(isc.isA.DynamicForm(this.members[i])&&this.members[i].hasErrors())return true}
return false},isc.A.hasFieldErrors=function isc_ValuesManager_hasFieldErrors(_1){var _2=this.getMemberForField(_1);if(_2&&isc.isA.DynamicForm(_2)&&_2.hasFieldErrors(_1))return true;var _3=this.getHiddenErrors(true);if(_3&&_3[_1]!=null)return true;return false},isc.A.showErrors=function isc_ValuesManager_showErrors(_1){if(this.members){for(var i=0;i<this.members.length;i++){if(!isc.isA.DynamicForm(this.members[i]))continue;if(!this.members[i].isDrawn())continue;this.members[i].$116a=true;this.members[i].showErrors()}}
if(this.hiddenErrors!=null){this.$21z(_1)}},isc.A.showFieldErrors=function isc_ValuesManager_showFieldErrors(_1){var _2=this.getMemberForField(_1);if(_2&&isc.isA.DynamicForm(_2)&&_2.isVisible()&&_2.isDrawn()){var _3=_2.getItem(_1);if(_3&&_3.visible){_3.redraw("Validation errors modified");return}}
this.$21z()},isc.A.handleAsyncValidationReply=function(success,errors){},isc.A.$178e=function isc_ValuesManager__handleFormAsyncValidationReply(_1,_2,_3,_4){var _5=this.$178d;if(!_5||_5!==_4)return;if(_5.remove(_1)&&this.handleAsyncValidationReply!=null){this.logInfo("Asynchronous validation done - calling handleAsyncValidationReply()");this.handleAsyncValidationReply(_2,_3)}
delete this.$178d},isc.A.$178f=function isc_ValuesManager__addAsyncValidationMember(_1,_2){var _3=this.$178d;if(_3&&_3==_2)_3.add(_1)},isc.A.isPendingAsyncValidation=function isc_ValuesManager_isPendingAsyncValidation(){var _1=this.$178d;return _1!=null&&_1.length>0},isc.A.getValues=function isc_ValuesManager_getValues(){if(this.members!=null){var _1=isc.EH.getFocusCanvas();if(this.members.contains(_1)&&_1.updateFocusItemValue)_1.updateFocusItemValue()}
return isc.addProperties({},this.values)},isc.A.setValues=function isc_ValuesManager_setValues(_1){if(isc.isAn.Array(_1)){var _2=isc.isA.Object(_1[0]);this.logWarn("values specified as an array."+(_2?" Treating the first item in the array as intended values.":" Ignoring specified values."));if(_2)_1=_1[0];else _1=null}
this.$10r(_1);if(this.members){for(var i=0;i<this.members.length;i++){this.synchronizeMember(this.members[i])}}
this.rememberValues()},isc.A.$10r=function isc_ValuesManager__saveValues(_1){var _2={};isc.DynamicForm.$91f(this,_1,_2);_1=_2;this.values=_1},isc.A.setData=function isc_ValuesManager_setData(_1){return this.setValues(_1)},isc.A.clearValues=function isc_ValuesManager_clearValues(){this.setValues({})},isc.A.getMemberValues=function isc_ValuesManager_getMemberValues(_1){var _2=this.getMember(_1);if(_2!=null)return _2.getValues()},isc.A.setMemberValues=function isc_ValuesManager_setMemberValues(_1,_2){var _3=this.getMember(_1);if(_3!=null)return _3.setValues(_2)},isc.A.getValuesAsCriteria=function isc_ValuesManager_getValuesAsCriteria(_1,_2){var _3;for(var i=0;i<this.members.length;i++){if(i==0){_3=this.members[i].getValuesAsCriteria(_1,_2)}else{_3=isc.DataSource.combineCriteria(_3,this.members[i].getValuesAsCriteria(_1,_2),this.operator,_2)}}
if(_3==null||_3._constructor!="AdvancedCriteria"){if(_3==null)_3={};var _5=isc.addProperties({},this.getValues()),_6,_7=false;for(var _8 in _5){if(_3[_8]!==_6)delete _5[_8];else _7=true}
if(_7){this.logWarn("getValuesAsCriteria() returning simple criteria.Values object for this ValuesManager includes values for fields which are not associated with any member item:"+this.echo(_5)+". These values will be combined with the simple criteria retrieved from member forms, but developers should be aware that values not associated with any item are not supported for AdvancedCriteria.");_5=isc.DataSource.filterCriteriaForFormValues(_5)
if(_3==null)_3=_5;else isc.addProperties(_3,_5)}}
return _3},isc.A.getValuesAsAdvancedCriteria=function isc_ValuesManager_getValuesAsAdvancedCriteria(_1,_2){return this.getValuesAsCriteria(true,_1,_2)},isc.A.rememberValues=function isc_ValuesManager_rememberValues(){var _1=this.getValues();var _2={},_3=[];isc.DynamicForm.$91f(this,_1,_2,_3);this.$10s=_2;this.$10t=_3;return this.$10s},isc.A.getOldValues=function isc_ValuesManager_getOldValues(){var _1={};isc.addProperties(_1,this.$10s);return _1},isc.A.getChangedValues=function isc_ValuesManager_getChangedValues(){return this.valuesHaveChanged(true)},isc.A.resetValues=function isc_ValuesManager_resetValues(){var _1={};isc.DynamicForm.$91f(this,this.$10s,_1);for(var i=0;i<this.$91h;i++){isc.DynamicForm.$70m(this.$91h[i],_1,this)}
this.setValues(_1)},isc.A.valuesHaveChanged=function isc_ValuesManager_valuesHaveChanged(_1){var _2=this.getValues();var _3=this.$10s||{};return isc.DynamicForm.valuesHaveChanged(this,_1,_2,_3)},isc.A.getValue=function isc_ValuesManager_getValue(_1,_2){return isc.DynamicForm.$70o(_1,this.getField(_1),this.values,_2,true,"vm_getValue")},isc.A.setValue=function isc_ValuesManager_setValue(_1,_2){var _3=false,_4,_5;if(this.members){var _6=this.getItem(_1,true);if(_6&&_6.length>0){for(var i=0;i<_6.length;i++){var _8=_6[i];if(_8&&_8.setValue){var _9=_8.type?isc.SimpleType.getType(_8.type):null,_10=_2,_11=(_2===_5);if(!_11&&_9&&_9.getAtomicValue&&_9.updateAtomicValue){_1=_8.getFullDataPath();isc.DynamicForm.$70n(_1,null,_2,this.values,null,true);_10=_9.getAtomicValue(_2)}
if(_11)_8.clearValue();else _8.setValue(_10);_3=true}}}}
if(!_3){if(_2===_5){isc.DynamicForm.$70m(_1,this.values)}else{isc.DynamicForm.$70n(_1,null,_2,this.values,null,true)}}
var _12=this.$706(_1,false,true);if(_12){for(var i=0;i<_12.length;i++){if(_4&&_4.setData){var _13=_1;if(_1.indexOf(isc.Canvas.$70l)!=-1){_13=_1.substring(0,_1.lastIndexOf(isc.Canvas.$70l));_4.setData(isc.DynamicForm.$70o(_13,null,this.values,_4,true))}}}}});isc.evalBoundary;isc.B.push(isc.A.clearValue=function isc_ValuesManager_clearValue(_1){this.setValue(_1)},isc.A.addMember=function isc_ValuesManager_addMember(_1,_2){if(isc.isA.String(_1))_1=window[_1];if(!isc.isA.Canvas(_1)){this.logWarn("addMember() passed invalid object: "+this.echo(_1)+" - this should be a Canvas instance");return}
if(isc.isA.ValuesManager(_1.valuesManager)){_1.valuesManager.removeMember(_1)}else if(_1.valuesManager!=null){_1.valuesManager=null}
if(this.members==null)this.members=[];var _3=_1.getDataSource();if(_3!=null&&!_2&&_3!=this.getDataSource()){this.logWarn("addMember(): mismatched DataSources; new member form "+_1+" has dataSource: '"+_3.ID+"', valuesManager has DataSource "+(this.getDataSource()!=null?"'"+this.getDataSource().ID+"'":"[NONE]"))}
if(this.getDataSource()!=null&&_1.isMultipart&&_1.isMultipart()&&_1.isMultipart())
{this.logWarn("addMember(): new member form "+_1+" is flagged as using multipart encoding. Multipart forms require direct form submission to transfer uploaded files to the server - any uploaded files from this member form will be dropped when saving values from this ValuesManager to the server.")}
if(_1.dataArity=="single"&&_1.autoTrackSelection){if(_1.selectionComponent==null||_1.$837){var _4=_1.getFullDataPath(),_5=_4?this.getDataSourceField(_4):null,_6=isc.DynamicForm.$70o(_4,null,this.values,_1,true),_7=isc.isAn.Array(_6)||(_5&&_5.multiple);if(_7){var _8=this.getMemberForField(_4,true);if(_8&&_8.length>0){for(var i=0;i<_8.length;i++){var _10=_8[i];if(_10.dataArity=="multiple"){_1.setSelectionComponent(_10);_1.$837=true;break}}}}}}else{var _4=_1.getFullDataPath(),_11=this.getMemberForField(_4,true);if(_11&&_11.length>0){for(var i=0;i<_11.length;i++){if(_11[i].dataArity=="single"&&_11[i].autoTrackSelection&&(_11[i].selectionComponent==null||_11[i].$837==true))
{_11[i].setSelectionComponent(_1);_11[i].$837=true}}}}
if(_1.dataArity=="multiple"&&_1.autoTrackSelection){var _4=_1.getFullDataPath(),_12=_4&&_4.contains(isc.Canvas.$70l);if(_12){var _13=_4.split(isc.Canvas.$70l);_4="/";for(var i=_13.length-2;i>=0;i--){for(var j=0;j<=i;j++){_4+=_13[j];if(j!=i)_4+="/"}
var _5=this.getDataSourceField(_4),_6=isc.DynamicForm.$70o(_4,null,this.values,_1,true),_7=isc.isAn.Array(_6)||(_5&&_5.multiple);if(_7)break}}
if(_7){var _8=this.getMemberForField(_4,true);if(_8&&_8.length>0){for(var i=0;i<_8.length;i++){var _10=_8[i];if(_10.dataArity=="multiple"){_1.setSelectionComponent(_10);_1.$837=true;break}}}}
var _4=_1.getFullDataPath();if(_4&&_4!=""){var _15=this.members;for(var i=0;i<_15.length;i++){if(_15[i]==_1)continue;if(_15[i].dataArity=="single")continue;var _16=_15[i].getFullDataPath();if(_16&&_16!=_4&&_16.startsWith(_4))
{if(_15[i].selectionComponent!=null){if(_15[i].$837){var _17=_15[i].selectionComponent.getFullDataPath();if(_4.length>_17.length){_15[i].setSelectionComponent(_1);_15[i].$837=true}}}}}}}
this.members.add(_1);_1.valuesManager=this;if(_1.dataSource==null&&this.dataSource!=null&&_1.getFields){var _18=isc.isA.DynamicForm(_1)?_1.$834:_1.getAllFields();_18=_18||_1.getAllFields();var _4=_1.getFullDataPath();var _19=this.getDataSource();if(_4){var _19=_19.getDataSourceForDataPath(_4,true)}
_1.setDataSource(_19,_18)}
this.synchronizeMember(_1,true);_1.$703=_2;this.rememberValues();if(isc.isA.DynamicForm(_1)){this.observe(_1,"handleAsyncValidationReply","observer.$178e(this,success,errors,context)")}},isc.A.$707=function isc_ValuesManager__setMemberValues(_1,_2){if(_1.getFields==null)return;var _3=_1.getFullDataPath(),_4=this.getField(_3),_5=isc.DynamicForm.$70o(_3,null,this.values,_1,true),_6=isc.isAn.Array(_5)||(_4&&_4.multiple),_7=_1.selectionComponent;if(_6){if(_1.dataArity=="single"){if(_7!=null){var _8=_1.$71d,_9=false;for(var i=0;i<_5.length;i++){if(_5[i]==_8){_9=true;break}}
if(_9){_5=_5[i]}else{_5=null;this.logDebug("Unable to locate selectionComponent's selected record in $707.  Record is: "+isc.Comm.serialize(_8))}}else{if(isc.isAn.Array(_5))_5=_5[0]}}}else{if(_5!=null&&_1.dataArity=="multiple")_5=[_5]}
if(!isc.isA.DynamicForm(_1)){if(!_1.setData)return;var _11=_1.getFullDataPath(),_12=_2?_1.getData():null;if(_5==null){if(_2){isc.DynamicForm.$70n(_11,null,_12,this.values,_1,true)}}else{if(_2&&_12!=null&&!isc.isAn.emptyObject(_12)&&!isc.isAn.emptyArray(_12))
{this.logInfo("ValuesManager member:"+_1.getID()+" has existing values:"+this.echo(_12)+", replacing with values from this valuesManager:"+this.echo(_5))}
_1.setData(_5)}}else{var _13=_1.getItems(),_14=false,_15;for(var i=0;i<_13.getLength();i++){var _16=_13[i];var _17=_16.getTrimmedDataPath()||_16.getFieldName();if(_17==null)continue;var _3=_1.getFullDataPath(),_18=_17.startsWith(isc.Canvas.$70l),_19=_18?_17:this.$702(_3,_17);var _20=isc.DynamicForm.$70o(_19,null,this.values,_1,true);if(!_18){var _21=isc.DynamicForm.$70o(_19,null,_1.values,_1,true);if(_21!==_15){this.logInfo("Member form "+_1+" has specified value for field '"+_19+"' which collides with an already specified value in this ValuesManager. Resetting the value on the member form.")}}
if(_20!==_15){_1.setValue(_17,_20)}else{if(!_2)_1.clearValue(_17)}
if(_16.shouldSaveValue!=false){var _22=_1.getValue(_17);if(_22===_15){isc.DynamicForm.$70m(_19,this.values,_1,true)}else{isc.DynamicForm.$70n(_19,null,_22,this.values,_1,true)}
_14=true}
if(_16.formValuesChanged&&isc.isA.Function(_16.formValuesChanged))
_16.formValuesChanged();if(_14){if(_1.valuesChanged)_1.valuesChanged();if(_1.markForRedraw)_1.markForRedraw()}}
if(_2){this.$709(_1)}}},isc.A.$709=function isc_ValuesManager__findItemlessFormValues(_1,_2,_3,_4,_5){if(_2==null)_2=_1.getValues();if(_4==null)_4=[];for(var _6 in _2){var _7=_3?this.$702(_3,_6):_6;if(!_1.getItem(_7)){var _8=_2[_6];if(!isc.isAn.Object(_8)||isc.isA.Date(_8)||isc.isAn.Array(_8)){_4.add(_7);_1.clearValue(_7)}else{this.$709(_1,_8,_3,_4,true)}}}
if(!_5&&_4.length>0){this.$66q(_1,_4)}},isc.A.addMembers=function isc_ValuesManager_addMembers(_1){if(!isc.isAn.Array(_1))this.addMember(_1);else{for(var i=0;i<_1.length;i++){this.addMember(_1[i])}}},isc.A.removeMember=function isc_ValuesManager_removeMember(_1){if(isc.isA.String(_1)){_1=isc.Class.getArrayItem(_1,this.members);if(_1==null)return}else if(this.members&&!this.members.contains(_1))return;if(isc.isA.DynamicForm(_1)){this.ignore(_1,"handleAsyncValidationReply");var _2=this.$178d;if(_2)_2.removeEvery(_1)}
if(this.members)this.members.remove(_1);_1.valuesManager=null},isc.A.removeMembers=function isc_ValuesManager_removeMembers(_1){if(!isc.isAn.Array(_1))this.removeMember(_1);else{for(var i=0;i<_1.length;i++){this.removeMember(_1[i])}}},isc.A.getPrintHTML=function isc_ValuesManager_getPrintHTML(){var _1=this.getValues(),_2=isc.StringBuffer.create();_2.append("<TABLE border=1><TR><TD align='center' style='font-weight:bold;'>Field</TD>","<TD align='center' style='font-weight:bold;'>Value</TD>");for(var _3 in _1){_2.append("<TR><TD>",_3,"</TD><TD>",_1[_3],"</TD></TR>")}
_2.append("</TABLE>");return _2.release(false)},isc.A.getAllDBCs=function isc_ValuesManager_getAllDBCs(_1){var _2=[];if(_1==null){for(var i=0;i<this.members.length;i++){_2.addAll(this.getAllDBCs(this.members[i]))}
var _4=[];for(var i=0;i<_2.length;i++){if(!_4.contains(_2[i]))_4.add(_2[i])}
return _4}
if(isc.isA.DataBoundComponent(_1))_2.add(_1);var _5=_1.children;if(!_5)return _2;for(var i=0;i<_5.length;i++){var _1=_5[i];if(isc.isA.DataBoundComponent(_1))_2.add(_1);_2.addAll(this.getAllDBCs(_1))}
return _2});isc.B._maxIndex=isc.C+80;isc.ValuesManager.registerStringMethods({handleHiddenValidationErrors:"errors",submitValues:"values,valuesManager",itemChanged:"item,newValue"});if(isc.Window){isc.ClassFactory.defineClass("ColorPicker",isc.Window);isc.A=isc.ColorPicker;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.getSharedColorPicker=function isc_c_ColorPicker_getSharedColorPicker(_1,_2){_1=_1||{};if(!isc.isA.ColorPicker(this.$56b)){this.$56b=isc.ColorPicker.create(_1)}else{if(_1.colorSelected==null)delete this.$56b.colorSelected;if(_1.colorChanged==null)delete this.$56b.colorChanged;this.$56b.setProperties(_1)}
if(!_2){var _3=this.$56b;if(_3.$56c!=_3.defaultPickMode){_3.$56c=_3.defaultPickMode;if(_3.$56c=='simple'){_3.removeComplexElements();if(_3.allowComplexMode){_3.modeToggleButton.setTitle(_3.moreButtonTitle)}}else{if(!_3.$56i){_3.createComplexElements()}
_3.addComplexElements();_3.modeToggleButton.setTitle(_3.lessButtonTitle)}}
_3.setHtmlColor(_3.defaultColor);_3.setOpacity(_3.defaultOpacity)}
return this.$56b});isc.B._maxIndex=isc.C+1;isc.addGlobal("ColorChooser",isc.ColorPicker);isc.A=isc.ColorPicker.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.canFocusInHeaderButtons=true;isc.A.autoSize=true;isc.A.keepInParentRect=true;isc.A.isModal=true;isc.A.autoCenter=true;isc.A.autoDraw=false;isc.A.showMinimizeButton=false;isc.A.showOkButton=true;isc.A.okButtonConstructor="IButton";isc.A.okButtonDefaults={width:80,autoParent:"buttonLayout",click:function(){if(this.creator.colorSelected){this.creator.colorSelected(this.creator.getHtmlColor(),this.creator.getOpacity())}
this.creator.hide()}};isc.A.showCancelButton=true;isc.A.cancelButtonConstructor="IButton";isc.A.cancelButtonDefaults={title:"Cancel",width:80,autoParent:"buttonLayout",click:function(){this.creator.$183f()}};isc.A.showModeToggleButton=true;isc.A.modeToggleButtonConstructor="IButton";isc.A.modeToggleButtonDefaults={width:80,autoParent:"buttonLayout",click:function(){this.creator.$56e()}};isc.A.showButtonLayout=true;isc.A.buttonLayoutConstructor="HLayout";isc.A.buttonLayoutDefaults={width:"*",defaultLayoutAlign:"center"};isc.A.bodyLayoutConstructor="VLayout";isc.A.bodyLayoutDefaults={autoDraw:false,width:"100%",height:"100%"};isc.A.contentLayoutConstructor="VLayout";isc.A.contentLayoutDefaults={autoDraw:false,resized:function(){if(this.creator.buttonLayout)this.creator.buttonLayout.setWidth(this.getVisibleWidth())}};isc.A.innerContentLayoutConstructor="HLayout";isc.A.innerContentLayoutDefaults={autoDraw:false,align:"center",membersMargin:5};isc.A.leftLayoutConstructor="VLayout";isc.A.leftLayoutDefaults={membersMargin:10};isc.A.basicLabelConstructor="Label";isc.A.basicLabelDefaults={autoDraw:false,margin:0,paddingTop:5,paddingBottom:5,width:"100%",height:15,wrap:false};isc.A.formLayoutConstructor="VLayout";isc.A.formLayoutDefaults={autoDraw:false,membersMargin:4};isc.A.rgbFormConstructor="DynamicForm";isc.A.rgbFormDefaults={autoDraw:false,cellPadding:1,width:65,colWidths:[60,"*"]};isc.A.hslFormConstructor="DynamicForm";isc.A.hslFormDefaults={autoDraw:false,cellPadding:1,width:65,colWidths:[60,"*"]};isc.A.htmlFormConstructor="DynamicForm";isc.A.htmlFormDefaults={autoDraw:false,cellPadding:1,width:65};isc.A.crossHairDefaults={_constructor:"Img",autoDraw:false,imageWidth:16,imageHeight:16,width:16,height:16,imageType:"normal",canDrag:true,canDrop:true,dragAppearance:"target",picker:this,dragMove:function(){this.picker.$56s=true;this.picker.$56t(this.parentElement.getOffsetX(),this.parentElement.getOffsetY())}};isc.A.colorBoxDefaults={_constructor:"Canvas",autoDraw:false,width:"100%",height:30};isc.A.opacityBoxDefaults={_constructor:"Canvas",autoDraw:false,width:60,height:30,overflow:"hidden",styleName:"colorChooserCell"};isc.A.luminosityStackDefaults={_constructor:"VStack",autoDraw:false,extraSpace:5,overflow:"hidden",styleName:"colorChooserCell"};isc.A.opacitySliderDefaults={_constructor:"Slider",autoDraw:false,vertical:false,minValue:0,maxValue:100,numValues:100,length:100,height:12,width:100,showTitle:false,showValue:false,labelWidth:10,showRange:false,value:100,dragStart:function(){return isc.EH.STOP_BUBBLING},dragMove:function(){return isc.EH.STOP_BUBBLING},dragStop:function(){return isc.EH.STOP_BUBBLING}};isc.A.defaultColor="#808080";isc.A.colorButtonSize=20;isc.A.colorButtonBaseStyle="colorChooserCell";isc.A.colorArray=["#000000","#993300","#333300","#003300","#003366","#000080","#333399","#333333","#800000","#FF6600","#808000","#008000","#008080","#0000FF","#666699","#808080","#FF0000","#FF9900","#99CC00","#339966","#33CCCC","#3366FF","#800080","#999999","#FF00FF","#FFCC00","#FFFF00","#00FF00","#00FFFF","#00CCFF","#993366","#C0C0C0","#FF99CC","#FFCC99","#FFFF99","#CCFFCC","#CCFFFF","#99CCFF","#CC99FF","#FFFFFF"];isc.A.numBasicColorRows=5;isc.A.numBasicColorColumns=8;isc.A.basicColorLayoutDefaults={_constructor:"VLayout",autoParent:"none"};isc.A.basicColorRowLayoutDefaults={_constructor:"HLayout",layoutBottomMargin:1,membersMargin:1};isc.A.basicColorSwatchDefaults={autoDraw:false,_constructor:"StatefulCanvas",overflow:"hidden",title:"",showFocusOutline:false,showTitle:false,showFocused:true,showRollOver:true,showFocusedAsOver:true,canFocus:true,click:function(){var _1=this.creator;_1.setHtmlColor(this.backgroundColor);_1.$56g(this.backgroundColor)}};isc.A.showLuminositySlider=false;isc.A.luminositySliderConstructor="Slider";isc.A.luminositySliderDefaults={autoDraw:true,minValue:0,maxValue:240,numValues:240,width:10,showTitle:false,showValue:false,showRange:false,dragStart:function(){return isc.EH.STOP_BUBBLING},dragMove:function(){return isc.EH.STOP_BUBBLING},dragStop:function(){return isc.EH.STOP_BUBBLING}};isc.A.swatchWidth=170;isc.A.swatchHeight=170;isc.A.lumStep=4;isc.A.lumWidth=15;isc.A.supportsTransparency=true;isc.A.opacityText="Lorem ipsum dolor sit amet, consectetuer adipiscing elit.";isc.A.swatchImageURL="[SKIN]ColorPicker/spectrum.png";isc.A.crosshairImageURL="[SKIN]ColorPicker/crosshair.png";isc.A.lessButtonTitle="<< Less";isc.A.moreButtonTitle="More >>";isc.A.basicColorLabel="Basic Colors :";isc.A.selectedColorLabel="Selected Color:";isc.A.opacitySliderLabel="Opacity:";isc.A.defaultOpacity=100;isc.A.redFieldTitle="Red";isc.A.redFieldPrompt="The Red component of the selected color";isc.A.greenFieldTitle="Green";isc.A.greenFieldPrompt="The Green component of the selected color";isc.A.blueFieldTitle="Blue";isc.A.blueFieldPrompt="The Blue component of the selected color";isc.A.htmlFieldTitle="HTML";isc.A.htmlFieldPrompt="The selected color&#39;s HTML coding";isc.A.hueFieldTitle="Hue";isc.A.hueFieldPrompt="The Hue (base tone) of the selected color";isc.A.satFieldTitle="Sat";isc.A.satFieldPrompt="The Saturation (color purity) of the selected color";isc.A.lumFieldTitle="Lum";isc.A.lumFieldPrompt="The Luminosity (brightness) of the selected color";isc.A.okButtonTitle="OK";isc.A.cancelButtonTitle="Cancel";isc.A.autoPosition=true;isc.A.autoCenterOnShow=true;isc.A.autoHide=null;isc.A.defaultPickMode="simple";isc.A.allowComplexMode=true;isc.A.$56f=true;isc.B.push(isc.A.closeClick=function isc_ColorPicker_closeClick(){this.hide()},isc.A.$183f=function isc_ColorPicker__cancel(){this.hide();if(this.pickerCancelled)this.pickerCancelled()});isc.B._maxIndex=isc.C+2;isc.A=isc.ColorPicker.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.selectTitle="Select a Color";isc.B.push(isc.A.show=function isc_ColorPicker_show(){if(this.autoPosition){this.autoCenter=false;var _1=isc.EH.getLastEvent();this.placeNear(_1.x,_1.y)}else{if(this.autoCenterOnShow)this.autoCenter=true}
this.Super("show",arguments);if(this.cancelButton){this.cancelButton.focus()}},isc.A.redraw=function isc_ColorPicker_redraw(){this.Super("redraw",arguments);if(this.autoPosition){this.autoCenter=false;this.placeNear(this.left,this.top)}},isc.A.initWidget=function isc_ColorPicker_initWidget(){this.Super("initWidget",arguments);this.title=this.selectTitle;this.$56c=this.defaultPickMode;if(!this.allowComplexMode){this.$56c="simple"}
this.addAutoChild("basicColorLayout");var _1=this.numBasicColorRows,_2=this.numBasicColorColumns;var _3={height:this.colorButtonSize};for(var i=0;i<_1;++i){var _5=this.createAutoChild("basicColorRowLayout",_3);for(var j=0;j<_2;++j){var _7=this.createAutoChild("basicColorSwatch",{baseStyle:this.colorButtonBaseStyle,width:this.colorButtonSize,height:this.colorButtonSize,backgroundColor:this.colorArray[i*_2+j]});_5.addMember(_7)}
this.basicColorLayout.addMember(_5)}
this.leftLayout=this.createAutoChild("leftLayout");this.leftLayout.addMember(this.basicColorLayout);this.innerContentLayout=this.createAutoChild("innerContentLayout");this.innerContentLayout.addMembers([this.leftLayout]);this.contentLayout=this.createAutoChild("contentLayout");this.contentLayout.addMembers([this.innerContentLayout]);this.bodyLayout=this.createAutoChild("bodyLayout");this.bodyLayout.addMember(this.contentLayout);this.$170v=this.showOkButton;if(this.$56c==="simple"){this.showOkButton=false}
if(!this.allowComplexMode){this.showModeToggleButton=false}
this.addAutoChild("buttonLayout");this.addAutoChild("okButton",{title:this.okButtonTitle});this.addAutoChild("cancelButton",{title:this.cancelButtonTitle});this.addAutoChild("modeToggleButton",{title:(this.$56c=="simple"&&this.allowComplexMode?this.moreButtonTitle:this.lessButtonTitle)});if(this.$56c!="simple"){this.createComplexElements();this.addComplexElements()}
this.bodyLayout.addMember(this.buttonLayout);this.addItem(this.bodyLayout);this.setHtmlColor(this.defaultColor);this.$56h();this.setOpacity(this.defaultOpacity)},isc.A.draw=function isc_ColorPicker_draw(){this.Super("draw",arguments);if(this.buttonLayout)this.buttonLayout.setWidth(this.body.getVisibleWidth())},isc.A.createComplexElements=function isc_ColorPicker_createComplexElements(){if(this.$56c!='complex'){return}
this.rgbForm=this.createAutoChild("rgbForm",{picker:this,fields:[{name:"pickerRedVal",title:this.redFieldTitle,type:"text",width:50,defaultValue:this.$56j,prompt:this.redFieldPrompt,picker:this,changed:function(_4,_5,_6){this.picker.setRed(_6)}},{name:"pickerGrnVal",title:this.greenFieldTitle,type:"text",width:50,defaultValue:this.$56k,prompt:this.greenFieldPrompt,picker:this,changed:function(_4,_5,_6){this.picker.setGreen(_6)}},{name:"pickerBluVal",title:this.blueFieldTitle,type:"text",width:50,defaultValue:this.$56l,prompt:this.blueFieldPrompt,picker:this,changed:function(_4,_5,_6){this.picker.setBlue(_6)}}]});this.hslForm=this.createAutoChild("hslForm",{picker:this,fields:[{name:"pickerHueVal",title:this.hueFieldTitle,type:"text",width:49,defaultValue:this.$56o,prompt:this.hueFieldPrompt,picker:this,changed:function(_4,_5,_6){this.picker.setHue(_6)}},{name:"pickerSatVal",title:this.satFieldTitle,type:"text",width:49,defaultValue:this.$56p,prompt:this.satFieldPrompt,picker:this,changed:function(_4,_5,_6){this.picker.setSaturation(_6)}},{name:"pickerLumVal",title:this.lumFieldTitle,type:"text",width:49,defaultValue:this.$56q,prompt:this.lumFieldPrompt,picker:this,changed:function(_4,_5,_6){this.picker.setLuminosity(_6)}}]});this.htmlForm=this.createAutoChild("htmlForm",{picker:this,fields:[{name:"pickerHtmlVal",title:this.htmlFieldTitle,type:"text",width:90,defaultValue:this.$56m,prompt:this.htmlFieldPrompt,picker:this,changed:function(_4,_5,_6){this.picker.setHtmlColor(_6)}}]});this.crossHair=this.createAutoChild("crossHair",{picker:this,src:this.crosshairImageURL});this.colorBox=this.createAutoChild("colorBox",{picker:this,backgroundColor:this.getHtmlColor()});this.opacityBox=this.createAutoChild("opacityBox",{picker:this,contents:this.opacityText,children:[this.colorBox]});this.luminosityStack=this.createAutoChild("luminosityStack",{picker:this,height:this.swatchHeight+2,width:this.lumWidth,click:function(){var _1=this.picker.luminositySlider.$1260(true,[isc.EH.getX(),isc.EH.getY()-2],true);this.picker.luminositySlider.setValue(_1)}});var _2=Math.ceil(this.swatchHeight/this.lumStep)
for(var i=0;i<_2;i++){this.luminosityStack.addMember(isc.Canvas.create({autoDraw:false,width:this.lumWidth,height:this.lumStep,margin:0,padding:0,overflow:"hidden"}))}
this.luminositySlider=this.createAutoChild("luminositySlider",{length:this.swatchHeight,height:this.swatchHeight});if(this.supportsTransparency){this.opacitySlider=this.createAutoChild("opacitySlider",{picker:this});this.$56z=isc.HLayout.create({membersMargin:5,members:[isc.Label.create({autoDraw:false,contents:this.opacitySliderLabel,width:this.swatchWidth-105,height:10}),this.opacitySlider]})}
this.$560=isc.VLayout.create({autoDraw:false,membersMargin:5,members:[isc.HLayout.create({autoDraw:false,height:this.swatchHeight,membersMargin:5,members:[isc.Img.create({autoDraw:false,width:this.swatchWidth+2,height:this.swatchHeight+2,src:this.swatchImageURL,overflow:"hidden",styleName:"colorChooserCell",picker:this,click:function(){this.picker.$56t(this.getOffsetX(),this.getOffsetY())},children:[this.crossHair]})]}),isc.HLayout.create({autoDraw:false,membersMargin:5,defaultLayoutAlign:"center",members:[isc.Label.create({autoDraw:false,contents:this.selectedColorLabel,width:this.swatchWidth-63,height:15}),this.opacityBox]})]});this.$186j=isc.HLayout.create({autoDraw:false,height:"100%",width:1,overflow:"visible",members:[this.luminosityStack,this.luminositySlider]});if(this.luminositySlider)this.observe(this.luminositySlider,"valueChanged","observer.luminositySliderChanged()");if(this.opacitySlider)this.observe(this.opacitySlider,"valueChanged","observer.$562()")},isc.A.initComplexElements=function isc_ColorPicker_initComplexElements(){if(!this.luminositySlider)this.luminositySlider=this.createAutoChild("luminositySlider",{length:this.swatchHeight});this.luminositySlider.setValue(this.$56q);this.$56h();this.$563(this.$56o,this.$56p);if(this.$56m)this.setHtmlColor(this.$56m);this.colorBox.setBackgroundColor(isc.ColorUtils.hslToHtml(this.$56o,this.$56p,this.$56q));if(this.supportsTransparency){this.colorBox.setOpacity(this.$56d);this.opacitySlider.setValue(this.$56d)}},isc.A.addComplexElements=function isc_ColorPicker_addComplexElements(){if(this.$56c!='complex'){return}
this.showOkButton=this.$170v;this.setAutoChild("okButton",{title:this.okButtonTitle});this.buttonLayout.setMembers([this.okButton,this.cancelButton,this.modeToggleButton]);if(!this.basicLabel){this.basicLabel=this.createAutoChild("basicLabel",{contents:this.basicColorLabel})}
if(!this.$186p){this.$186p=isc.HLayout.create({autoDraw:false,membersMargin:4,members:[this.rgbForm,this.hslForm]})}
if(!this.formLayout){this.formLayout=this.createAutoChild("formLayout");this.formLayout.addMembers([this.$186p,this.htmlForm])}
this.contentLayout.addMember(this.basicLabel,0);this.leftLayout.addMember(this.formLayout);if(this.supportsTransparency){this.$560.addMember(this.$56z)}
this.innerContentLayout.addMember(this.$560);this.innerContentLayout.addMember(this.$186j);this.initComplexElements()},isc.A.removeComplexElements=function isc_ColorPicker_removeComplexElements(){if(this.$56c=='complex'){return}
this.showOkButton=false;this.setAutoChild("okButton");if(this.formLayout){this.contentLayout.removeMembers([this.basicLabel]);this.leftLayout.removeMembers([this.formLayout]);this.innerContentLayout.removeMembers([this.$560,this.$186j])}},isc.A.setSupportsTransparency=function isc_ColorPicker_setSupportsTransparency(_1){this.supportsTransparency=_1;if(this.$56c=='complex'){if(this.supportsTransparency){this.$560.addMember(this.$56z)}else{this.$560.removeMember(this.$56z)}}},isc.A.getRed=function isc_ColorPicker_getRed(){return this.$56j},isc.A.getGreen=function isc_ColorPicker_getGreen(){return this.$56k},isc.A.getBlue=function isc_ColorPicker_getBlue(){return this.$56l},isc.A.getHue=function isc_ColorPicker_getHue(){return this.$56o},isc.A.getSaturation=function isc_ColorPicker_getSaturation(){return this.$56p},isc.A.getLuminosity=function isc_ColorPicker_getLuminosity(){return this.$56q},isc.A.getHtmlColor=function isc_ColorPicker_getHtmlColor(){return this.$56m},isc.A.getOpacity=function isc_ColorPicker_getOpacity(){return this.$56d},isc.A.setRed=function isc_ColorPicker_setRed(_1){if(_1<0)this.$56j=0;else if(_1>255)this.$56j=255;else this.$56j=_1/1;if(this.$56c=='complex'){this.rgbForm.setValue("pickerRedVal",this.$56j)}
if(this.$56f===true)
this.$564('rgb')},isc.A.setGreen=function isc_ColorPicker_setGreen(_1){if(_1<0)this.$56k=0;else if(_1>255)this.$56k=255;else this.$56k=_1/1;if(this.$56c=='complex'){this.rgbForm.setValue("pickerGrnVal",this.$56k)}
if(this.$56f===true)
this.$564('rgb')},isc.A.setBlue=function isc_ColorPicker_setBlue(_1){if(_1<0)this.$56l=0;else if(_1>255)this.$56l=255;else this.$56l=_1/1;if(this.$56c=='complex'){this.rgbForm.setValue("pickerBluVal",this.$56l)}
if(this.$56f===true)
this.$564('rgb')},isc.A.setHue=function isc_ColorPicker_setHue(_1){if(_1<0)this.$56o=0;else if(_1>239)this.$56o=239;else this.$56o=_1/1;if(this.$56c=='complex'){this.hslForm.setValue("pickerHueVal",this.$56o)}
if(this.$56f===true)
this.$564('hsl')},isc.A.setSaturation=function isc_ColorPicker_setSaturation(_1){if(_1<0)this.$56p=0;else if(_1>240)this.$56p=240;else this.$56p=_1/1;if(this.$56c=='complex'){this.hslForm.setValue("pickerSatVal",this.$56p)}
if(this.$56f===true){this.$564('hsl')}},isc.A.setLuminosity=function isc_ColorPicker_setLuminosity(_1,_2){if(_1<0)this.$56q=0;else if(_1>240)this.$56q=240;else this.$56q=_1/1;this.$105z=!_2;if(this.$56c=='complex'){this.hslForm.setValue("pickerLumVal",this.$56q)}
if(this.$56f===true)
this.$564('hsl')},isc.A.setHtmlColor=function isc_ColorPicker_setHtmlColor(_1){if(isc.ColorUtils.encodingIsValid(_1)===true){this.$56m=_1.toUpperCase();if(this.$56c=='complex'){this.htmlForm.setValue("pickerHtmlVal",this.$56m)}
if(this.$56f===true)
this.$564('html')}},isc.A.setOpacity=function isc_ColorPicker_setOpacity(_1){if(this.$56c=='complex'&&this.supportsTransparency){if(_1<0)this.$56d=0;else if(_1>100)this.$56d=100;else this.$56d=_1/1;if(this.$56f===true){this.$564('opacity')}}},isc.A.$564=function isc_ColorPicker__changeColor(_1){if(_1=='rgb'){var _2=isc.ColorUtils.rgbToHsl(this.$56j,this.$56k,this.$56l);this.$56f=false;this.setHue(_2.h);this.setSaturation(_2.s);this.setLuminosity(_2.l,true);this.setHtmlColor(isc.ColorUtils.rgbToHtml(this.$56j,this.$56k,this.$56l));this.$56f=true;this.$563(this.$56o,this.$56p)}else if(_1=='hsl'){if(!this.$105z)this.$56q=120;var _3=isc.ColorUtils.hslToRgb(this.$56o,this.$56p,this.$56q);this.$56f=false;this.setRed(_3.r);this.setGreen(_3.g);this.setBlue(_3.b);this.setHtmlColor(isc.ColorUtils.rgbToHtml(this.$56j,this.$56k,this.$56l));this.$56f=true;if(this.$56o!=this.$565||this.$56p!=this.$566){this.$563(this.$56o,this.$56p)}}else if(_1=='html'){var _3=isc.ColorUtils.htmlToRgb(this.$56m);this.$56f=false;this.setRed(_3.r);this.setGreen(_3.g);this.setBlue(_3.b);var _2=isc.ColorUtils.rgbToHsl(this.$56j,this.$56k,this.$56l);this.setHue(_2.h);this.setSaturation(_2.s);this.setLuminosity(_2.l,true);this.$56f=true;this.$563(this.$56o,this.$56p)}
if(this.$56c=='complex'){if(!this.luminositySlider)this.luminositySlider=this.createAutoChild("luminositySlider",{length:this.swatchHeight});this.luminositySlider.setValue(this.$56q);this.hslForm.setValue("pickerLumVal",this.$56q)}
if(this.$56c=='complex'){this.colorBox.setBackgroundColor(isc.ColorUtils.hslToHtml(this.$56o,this.$56p,this.$56q))}
if(this.$56o!=this.$565||this.$56p!=this.$566){this.$56h()}
if(this.$56c=='complex'&&this.supportsTransparency){this.colorBox.setOpacity(this.$56d);if(this.opacitySlider!=null){var _4=this.opacitySlider,_5=_4.getValue(),_6=this.$56d;if(_6===null)_6=100;if(_5!=_6)this.opacitySlider.setValue(this.$56d)}}
this.$565=this.$56o;this.$566=this.$56p;if(this.colorChanged)this.colorChanged()},isc.A.$56g=function isc_ColorPicker__oneClickColorSelected(_1){if(((this.autoHide===undefined||this.autoHide===null)&&this.$56c==="simple")||this.autoHide===true)
{this.hide()}
if(this.colorSelected){this.colorSelected(_1)}},isc.A.$563=function isc_ColorPicker__positionCrossHair(_1,_2){if(_1==null||_2==null)return;if(this.$56c!='complex'){return}
if(this.$56s===true){this.$56s=false;return}
var _3=_1/239.0;var _4=_2/240.0;_3*=this.swatchWidth;_4=this.swatchHeight-(_4*this.swatchHeight);_3=parseInt(_3)-8;_4=parseInt(_4)-8;this.crossHair.setLeft(_3);this.crossHair.setTop(_4)},isc.A.$56t=function isc_ColorPicker__crosshairMoved(_1,_2){_1-=5;_2-=5;_1/=this.swatchWidth;_2=1.0-_2/this.swatchHeight;this.$56f=false;this.setHue(Math.floor(_1*239.0+0.5));this.$56f=true;this.setSaturation(Math.floor(_2*240.0+0.5))},isc.A.$56h=function isc_ColorPicker__setLumVals(){if(this.$56c!='complex'){return}
for(var i=0;i<this.swatchHeight/this.lumStep;i++){this.luminosityStack.members[i].setBackgroundColor(isc.ColorUtils.hslToHtml(this.$56o,this.$56p,240-(i*240/(this.swatchHeight/this.lumStep))))}},isc.A.luminositySliderChanged=function isc_ColorPicker_luminositySliderChanged(){var _1=this.luminositySlider.getValue();if(this.$56q!=_1){this.setLuminosity(_1)}},isc.A.$562=function isc_ColorPicker__opSliderChanged(){this.setOpacity(this.opacitySlider.getValue())},isc.A.setCurrentPickMode=function isc_ColorPicker_setCurrentPickMode(_1){if(this.$56c==_1)return;if(_1=="simple"||!this.allowComplexMode){this.$56c="simple";this.removeComplexElements();if(this.allowComplexMode){this.modeToggleButton.setTitle(this.moreButtonTitle)}}else{this.$56c="complex";if(!this.$560){this.createComplexElements()}
this.addComplexElements();this.modeToggleButton.setTitle(this.lessButtonTitle)}
this.modeToggleButton.setState("");this.reflow();this.markForRedraw()},isc.A.$56e=function isc_ColorPicker__togglePickMode(){this.setCurrentPickMode(this.$56c=="simple"?"complex":"simple")});isc.B._maxIndex=isc.C+34;isc.ColorPicker.registerStringMethods({colorChanged:"",colorSelected:"color,opacity"});isc.defineClass("ColorUtils",isc.Class);isc.A=isc.ColorUtils;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.hexToDec=function isc_c_ColorUtils_hexToDec(_1){return parseInt(_1,16)},isc.A.decToHex=function isc_c_ColorUtils_decToHex(_1){var d=_1/1;var h=d.toString(16);if(h.length==1){h="0"+h}
return h},isc.A.brightness=function isc_c_ColorUtils_brightness(_1,_2,_3){var _4=isc.ColorUtils.rgbToHsl(_1,_2,_3);return(_4.l/240.0)},isc.A.encodingIsValid=function isc_c_ColorUtils_encodingIsValid(_1){return(_1.substring(0,1)=='#'&&isc.isA.color(_1))},isc.A.rgbToHtml=function isc_c_ColorUtils_rgbToHtml(_1,_2,_3){var _4='#'+isc.ColorUtils.decToHex(_1)+isc.ColorUtils.decToHex(_2)+isc.ColorUtils.decToHex(_3);return _4},isc.A.hslToHtml=function isc_c_ColorUtils_hslToHtml(_1,_2,_3){var _4=isc.ColorUtils.hslToRgb(_1,_2,_3);var _5='#'+isc.ColorUtils.decToHex(_4.r)+isc.ColorUtils.decToHex(_4.g)+isc.ColorUtils.decToHex(_4.b);return _5},isc.A.htmlToRgb=function isc_c_ColorUtils_htmlToRgb(_1){var r=_1.substring(1,3);var g=_1.substring(3,5);var b=_1.substring(5,7);return{r:isc.ColorUtils.hexToDec(r),g:isc.ColorUtils.hexToDec(g),b:isc.ColorUtils.hexToDec(b)}},isc.A.htmlToHsl=function isc_c_ColorUtils_htmlToHsl(_1){var r=_1.substring(1,3);var g=_1.substring(3,5);var b=_1.substring(5,7);return isc.ColorUtils.rgbToHsl(isc.ColorUtils.hexToDec(r),isc.ColorUtils.hexToDec(g),isc.ColorUtils.hexToDec(b))},isc.A.rgbToHsl=function isc_c_ColorUtils_rgbToHsl(_1,_2,_3){var _4=_1/255.0;var _5=_2/255.0;var _6=_3/255.0;var _7=Math.min(Math.min(_4,_5),_6);var _8=Math.max(Math.max(_4,_5),_6);var _9=_8-_7;var h=0,s=0,l=0;l=(_8+_7)/2.0;if(_8==_7){s=0;h=0}else{if(l<0.5){s=(_8-_7)/(_8+_7)}else{s=(_8-_7)/(2.0-_8-_7)}
if(_4==_8)
h=(_5-_6)/_9;else if(_5==_8)
h=2+(_6-_4)/_9;else
h=4+(_4-_5)/_9}
h=Math.floor(h*40+0.5);if(h<0)h+=240;s=Math.floor(s*240+0.5);l=Math.floor(l*240+0.5);return{h:h,s:s,l:l}},isc.A.hslToRgb=function isc_c_ColorUtils_hslToRgb(_1,_2,_3){var _4=_1/239.0;var _5=_2/240.0;var _6=_3/240.0;var _7,_8,_9,_10,_11;var r=0,g=0,b=0;if(_5==0){r=_6;g=_6;b=_6}else{if(_6<0.5){_8=_6*(1.0+_5)}else{_8=(_6+_5)-(_6*_5)}
_7=(2.0*_6)-_8;_9=_4+0.3333;_10=_4;_11=_4-0.3333;if(_9<0)_9+=1.0;if(_10<0)_10+=1.0;if(_11<0)_11+=1.0;if(_9>1)_9-=1.0;if(_10>1)_10-=1.0;if(_11>1)_11-=1.0;if(_9*6.0<1)
r=_7+(_8-_7)*6.0*_9;else if(_9*2.0<1)
r=_8;else if(_9*3.0<2)
r=_7+(_8-_7)*(0.6667-_9)*6.0;else
r=_7;if(_10*6.0<1)
g=_7+(_8-_7)*6.0*_10;else if(_10*2.0<1)
g=_8;else if(_10*3.0<2)
g=_7+(_8-_7)*(0.6667-_10)*6.0;else
g=_7;if(_11*6.0<1)
b=_7+(_8-_7)*6.0*_11;else if(_11*2.0<1)
b=_8;else if(_11*3.0<2)
b=_7+(_8-_7)*(0.6667-_11)*6.0;else
b=_7}
r=Math.floor(r*255.0+0.5);g=Math.floor(g*255.0+0.5);b=Math.floor(b*255.0+0.5);return{r:r,g:g,b:b}});isc.B._maxIndex=isc.C+10}
isc.ClassFactory.defineClass("NestedEditorItem","CanvasItem");isc.A=isc.NestedEditorItem.getPrototype();isc.A.shouldSaveValue=true;isc.A.isCriteriaEditor=false;isc.A.editorConstructor="DynamicForm";isc.A.editorDefaults={itemChanged:function(_1,_2){var _3=this.creator.isCriteriaEditor?this.getValuesAsCriteria():this.getValues();if(_3!=null){_3=isc.addProperties({},_3)}
this.creator.storeValue(_3)}};isc.A=isc.NestedEditorItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.init=function isc_NestedEditorItem_init(){this.$67h();this.Super("init",arguments)},isc.A.isEditable=function isc_NestedEditorItem_isEditable(){return true},isc.A.$67h=function isc_NestedEditorItem__createEditor(){var _1;var _2={};if(this.form.dataSource){_1=isc.DataSource.getDataSource(this.form.dataSource);var _3=_1.getField(this.name);if(_3){_2.dataSource=_1.getFieldDataSource(_3)}}
if(this.form&&this.form.showComplexFieldsRecursively){_2.showComplexFields=true;_2.showComplexFieldsRecursively=true}else{_2.showComplexFields=false}
_2.values=this.getValue();this.addAutoChild("editor",_2);this.canvas=this.editor},isc.A.showValue=function isc_NestedEditorItem_showValue(_1,_2){this.editor.setValues(_2)},isc.A.$85m=function isc_NestedEditorItem__shouldAllowExpressions(){return false});isc.B._maxIndex=isc.C+5;isc.ClassFactory.defineClass("NestedListEditorItem","CanvasItem");isc.A=isc.NestedListEditorItem.getPrototype();isc.A.shouldSaveValue=true;isc.A.editorConstructor="ListEditor";isc.A.editorDefaults={inlineEdit:false,height:155,saveRecord:function(){if(!this.form.validate())return false;var _1=this.form.getValues();this.showList();if(this.inlineEdit){this.grid.setEditValues(this.grid.getEditRow(),_1)}else{if(this.form.saveOperationType=="add"){this.grid.addData(_1)}else{isc.addProperties(this.currentRecord,_1);this.grid.markForRedraw()}
if(!this.inlineEdit){this.form.clearValues()}
this.creator.updateValue(this.grid.data)}
return true}};isc.A=isc.NestedListEditorItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.init=function isc_NestedListEditorItem_init(){this.$67h();this.Super("init",arguments)},isc.A.isEditable=function isc_NestedListEditorItem_isEditable(){return true},isc.A.$67h=function isc_NestedListEditorItem__createEditor(){var _1;var _2={};if(this.form.dataSource){_1=isc.DataSource.getDataSource(this.form.dataSource);var _3=_1.getField(this.name);if(_3){_2.dataSource=_1.getFieldDataSource(_3)}}
if(this.form&&this.form.showComplexFieldsRecursively){_2.formProperties={showComplexFields:true,showComplexFieldsRecursively:true};_2.gridProperties={showComplexFields:true,showComplexFieldsRecursively:true,canRemoveRecords:true,saveLocally:true,data:[]}}else{_2.formProperties={showComplexFields:false};_2.gridProperties={showComplexFields:false,canRemoveRecords:true,saveLocally:true}}
this.addAutoChild("editor",_2);this.canvas=this.editor},isc.A.updateValue=function isc_NestedListEditorItem_updateValue(_1){this.editor.setData(_1);this.$10y(_1)},isc.A.setValue=function isc_NestedListEditorItem_setValue(_1){this.editor.setData(_1);this.Super("setValue",arguments)},isc.A.$85m=function isc_NestedListEditorItem__shouldAllowExpressions(){return false});isc.B._maxIndex=isc.C+6;isc.ClassFactory.defineClass("ViewFileItem","FileItem");isc.A=isc.ViewFileItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.shouldSaveValue=false;isc.A.colSpan="*";isc.A.height=20;isc.A.width="*";isc.A.overflow="visible";isc.A.canEdit=false;isc.A.defaultType="viewFile";isc.B.push(isc.A.isEditable=function isc_ViewFileItem_isEditable(){return false},isc.A.formValuesChanged=function isc_ViewFileItem_formValuesChanged(){this.setCanvasContent(null)});isc.B._maxIndex=isc.C+2;isc.defineClass("PanelHeader","ImgSectionHeader");isc.A=isc.PanelHeader.getPrototype();isc.A.width="100%";isc.A.height=22;isc.A.baseStyle="sectionHeader";isc.A=isc.PanelHeader.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.showSelectedIcon=false;isc.A.showRollOverIcon=false;isc.A.showDisabledIcon=false;isc.A.showDownIcon=false;isc.A.showFocusedIcon=false;isc.B.push(isc.A.initWidget=function isc_PanelHeader_initWidget(){this.setPanelTitleFromCanvas()},isc.A.setPanelTitleFromCanvas=function isc_PanelHeader_setPanelTitleFromCanvas(){if(this.canvas){if(this.canvas.title)this.title=this.canvas.title;if(this.canvas.icon)this.icon=this.canvas.icon}});isc.B._maxIndex=isc.C+2;isc.PanelHeader.registerStringMethods({iconClick:""});isc.A=isc.Canvas.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.panelHeaderDefaults={_constructor:"PanelHeader"};isc.A.panelHeaderProperties={};isc.A.panelHeaderPlacement="peer";isc.B.push(isc.A.setupPanelHeader=function isc_Canvas_setupPanelHeader(){if(!this.showPanelHeader)return;this.panelHeader=this.createAutoChild("panelHeader",{canvas:this,snapTo:"T"});if(isc.isA.Layout(this))this.panelHeaderPlacement="member";else this.panelHeaderPlacement="peer";this.panelHeaderPlacement="peer";if(this.panelHeaderPlacement=="member"){this.addMember(this.panelHeader,0)}
else if(this.panelHeaderPlacement=="peer"){this.addPeer(this.panelHeader);this.panelHeader.moveAbove(this);this.$wi(this.panelHeader,isc.Canvas.TOP)}
else if(this.panelHeaderPlacement=="custom"){}});isc.B._maxIndex=isc.C+1;isc.A=isc.Canvas.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.panelActionControls=[];isc.B.push(isc.A.refreshPanelControls=function isc_Canvas_refreshPanelControls(){var _1=this.panelControls||[];if(!this.panelHeader.controls)this.panelHeader.controls=[];else this.panelHeader.controls.setLength(0);for(var i=0;i<_1.length;i++){var _3=_1.get(i),_4=null;if(isc.isAn.Object(_3)){_4=isc.addProperties({},_3)}else if(_3.startsWith("action:")){var _5=_3.substring(7,_3.length),_6=isc.Canvas.getRegisteredAction(_5);if(this.canPerformAction(_6)){if(this.showActionInPanel(_6))
_4=this.getPanelActionControl(_6)}}else{_4=this.createAutoChild(_3)}
if(_4){this.panelHeader.controls.add(_4)}else{}}
var _7=this.panelHeader;_7.addControls()},isc.A.canPerformAction=function isc_Canvas_canPerformAction(_1){var _2=_1.name,_3=_1.enableProperty||"can"+_2.substring(0,1).toUpperCase()+_2.substring(1,_2.length);return this[_3]&&this[_3]==true?true:false},isc.A.showActionInPanel=function isc_Canvas_showActionInPanel(_1){return _1.showInPanel},isc.A.getPanelActionControl=function isc_Canvas_getPanelActionControl(_1){var _2=this.panelActionControls[_1.name],_3=_1.controlConstructor||"ImgButton";_2=isc.ClassFactory.newInstance(_3,{ID:this.getID()+"_"+_1.name,width:18,height:18,src:_1.icon,showRollOver:false,showDown:false,showDisabled:false,showFocused:false,actionTarget:this,actionObject:_1,prompt:_1.tooltip,click:function(){this.actionTarget[this.actionObject.methodName]()}});this.panelActionControls[_1.name]=_2;return this.panelActionControls[_1.name]},isc.A.showPrintPreview=function isc_Canvas_showPrintPreview(_1,_2,_3,_4){isc.Canvas.showPrintPreview(this,_1,_2,_3,_4)});isc.B._maxIndex=isc.C+5;isc.A=isc.Canvas;isc.A.$71k={};isc.A=isc.Canvas;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.registerAction=function isc_c_Canvas_registerAction(_1){if(!this.$71k[_1.name]){this.$71k[_1.name]=_1}},isc.A.getRegisteredActionNames=function isc_c_Canvas_getRegisteredActionNames(){return isc.getKeys(this.$71k)},isc.A.getRegisteredActions=function isc_c_Canvas_getRegisteredActions(){return isc.getValues(this.$71k)},isc.A.getRegisteredActionIndex=function isc_c_Canvas_getRegisteredActionIndex(){var _1=this.getRegisteredActions(),_2=_1.makeIndex("name",false);return _2},isc.A.getRegisteredAction=function isc_c_Canvas_getRegisteredAction(_1){return this.$71k[_1]},isc.A.isActionRegistered=function isc_c_Canvas_isActionRegistered(_1){return!this.$71k[_1]?false:true});isc.B._maxIndex=isc.C+6;isc.defineClass("Action","Class");isc.A=isc.Action.getPrototype();isc.A.name=null;isc.A.title=null;isc.A.icon=null;isc.A.tooltip=null;isc.A.methodName=null;isc.A.controlConstructor="ImgButton";isc.A.enableProperty=null;isc.A.showInPanel=true;isc.Canvas.registerAction(isc.Action.create({name:"edit",title:"Edit",icon:"[SKINIMG]/actions/edit.png",tooltip:"Put the component into Edit mode",methodName:"startEditing",showInPanel:false}));isc.Canvas.registerAction(isc.Action.create({name:"editNew",title:"Edit New",icon:"[SKINIMG]/SectionHeader/opener_closed.png",tooltip:"Add a new Record to the component",methodName:"startEditingNew",showInPanel:false}));isc.Canvas.registerAction(isc.Action.create({name:"sort",title:"Sort",icon:"[SKINIMG]/actions/sort_ascending.png",tooltip:"Sort the records in the component",methodName:"sort",controlConstructor:"SortActionSelector",enableProperty:"canSortFields",showInPanel:false}));isc.Canvas.registerAction(isc.Action.create({name:"export",title:"Export",icon:"[SKINIMG]/actions/redo.png",tooltip:"Export the data in the component",methodName:"exportData",showInPanel:true}));isc.Canvas.registerAction(isc.Action.create({name:"print",title:"Print",icon:"[SKINIMG]/actions/print.png",tooltip:"Print the data in the component",methodName:"showPrintPreview",showInPanel:true}));isc.defineClass("SortActionSelector","DynamicForm");isc.A=isc.SortActionSelector.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.width=100;isc.A.height=20;isc.A.numCols=4;isc.A.fields=[{name:"sortField",showTitle:false,colSpan:2,type:"select",width:80,prompt:"Sort Field",startRow:false,endRow:false,changed:function(_1,_2,_3){var _4=_1.getField("sortDirection").getValue(),_5=_4?"ascending":"descending";if(_1.actionTarget.sort)_1.actionTarget.sort(_3,_5);else _1.actionTarget.data.sortByProperty(_3,_4)}},{name:"sortDirection",showTitle:true,showLabel:false,type:"checkbox",width:20,prompt:"Sort Direction: Checked is Ascending",startRow:false,endRow:false,changed:function(_1,_2,_3){var _4=_3,_5=_4?"ascending":"descending",_6=_1.getField("sortField").getValue();if(_1.actionTarget.sort)_1.actionTarget.sort(_6,_5);else _1.actionTarget.data.sortByProperty(_6,_4)}}];isc.B.push(isc.A.initWidget=function isc_SortActionSelector_initWidget(){this.Super("initWidget",arguments)},isc.A.draw=function isc_SortActionSelector_draw(){this.Super("draw",arguments);var _1=this.actionTarget.getDataSource(),_2=_1?isc.getValues(_1.getFields()):[],_3={};for(var i=0;i<_2.length;i++){var _5=_2.get(i);_3[_5.name]=_5.title}
this.getField("sortField").setValueMap(_3)});isc.B._maxIndex=isc.C+2;isc.defineClass("DataPathItem","TextItem");isc.A=isc.DataPathItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.operationsTreeDefaults={_constructor:"TTreeGrid",autoDraw:false,recordDoubleClick:function(){this.creator.operationSelected()},getIcon:function(_1){var _2=this.creator.form.creator,_3=(_2&&_2.getServiceElementIcon)?_2.getServiceElementIcon(_1):null;if(_3)return _3;return this.Super("getIcon",arguments)}};isc.A.operationsTreeSelectButtonDefaults={_constructor:"TButton",autoDraw:false,title:"Select",click:function(){if(this.creator.operationsTree.anySelected())
this.creator.operationSelected()}};isc.A.defaultIcons=[{src:"[SKINIMG]/actions/edit.png",click:"item.showOperationsTreeData()",width:16,height:16},{src:"[SKINIMG]/actions/remove.png",click:"item.clearFormValues()",width:16,height:16}];isc.A.baseManagedProperties=["dataPath","schemaDataSource","serviceName","serviceNamespace"];isc.B.push(isc.A.getPropertyName=function isc_DataPathItem_getPropertyName(_1){if(this.isInput)
return"input"+_1.substring(0,1).toUpperCase()+_1.substring(1);else return _1},isc.A.initManagedProperties=function isc_DataPathItem_initManagedProperties(){this.managedProperties=[];var _1=this.baseManagedProperties;for(var i=0;i<_1.length;i++){this.managedProperties.add(this.getPropertyName(_1[i]))}},isc.A.keyPress=function isc_DataPathItem_keyPress(_1,_2,_3){if(_3!="Arrow_Left"&&_3!="Arrow_Right"&&_3!="Home"&&_3!="End")return false;this.Super("keyPress",arguments)},isc.A.init=function isc_DataPathItem_init(){this.icons=isc.clone(this.defaultIcons);this.initManagedProperties();this.Super("init",arguments);if(this.operationsTreeData){this.addAutoChildren(["operationsTree","operationsTreeSelectButton"])}},isc.A.showOperationsTreeData=function isc_DataPathItem_showOperationsTreeData(){if(!this.operationsTreeData)return;if(!this.operationsTree)
this.addAutoChildren(["operationsTree","operationsTreeSelectButton"]);var _1;if(isc.isA.Tree(this.operationsTreeData)){_1=this.operationsTreeData}else{_1=isc.Tree.create({modelType:"children",root:{children:this.operationsTreeData},nameProperty:"name",childrenProperty:"children"});_1.openAll()}
this.operationsTree.setData(_1);var _2=this.isInput?"formInputs":"formOutputs";var _3=_2+"/"+this.getValue(),_4=_1.find(_3);if(_4)this.operationsTree.selectRecord(_4);if(!this.schemaDialog){this.schemaDialog=isc.TWindow.create({title:"Select element from message",autoCenter:true,height:"90%",width:"60%",isModal:true,showModalMask:true,items:[isc.VLayout.create({width:"100%",height:"100%",members:[this.operationsTree,this.operationsTreeSelectButton]})]})}else this.schemaDialog.show()},isc.A.operationSelected=function isc_DataPathItem_operationSelected(){var _1=this.operationsTree,_2=_1.data,_3=_1.getSelectedRecord();this.schemaDialog.hide();this.setDataPathProperties(_3)},isc.A.setDataPathProperties=function isc_DataPathItem_setDataPathProperties(_1){var _2=_1.defaults;this.dataPathProps=isc.applyMask(_2,this.managedProperties);if(this.logIsInfoEnabled()){this.logInfo("setDPProps, editNode: "+this.echoAll(_1)+" defaults: "+this.echo(_2)+", managedProps: "+this.managedProperties+", props: "+this.echo(this.dataPathProps))}
this.saveFormValues()},isc.A.saveFormValues=function isc_DataPathItem_saveFormValues(){for(var i=0;i<this.managedProperties.length;i++){var _2=this.managedProperties[i],_3=this.dataPathProps[_2];this.form.setValue(_2,_3)}
if(this.form.saveProperties){this.form.saveProperties(this.dataPathProps,this.form.currentComponent)}},isc.A.clearFormValues=function isc_DataPathItem_clearFormValues(){for(var i=0;i<this.managedProperties.length;i++){this.form.setValue(this.managedProperties[i],null)}
if(this.form.saveProperties){this.form.saveProperties(this.dataPathProps,this.form.currentComponent)}});isc.B._maxIndex=isc.C+9;if(isc.ListGrid){isc.defineClass("RelativeDateItem","CanvasItem");isc.A=isc.RelativeDateItem;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.getAbsoluteDate=function isc_c_RelativeDateItem_getAbsoluteDate(_1,_2,_3,_4){var _5=false;if(isc.SimpleType.inheritsFrom(_3,"date")&&!isc.SimpleType.inheritsFrom(_3,"datetime"))
{_5=true}
var _6=isc.DateUtil.getAbsoluteDate(_1,_2,_4,_5);return _6},isc.A.getPeriodName=function isc_c_RelativeDateItem_getPeriodName(_1){return isc.DateUtil.getTimeUnitName(_1)},isc.A.getPeriodKey=function isc_c_RelativeDateItem_getPeriodKey(_1){return isc.DateUtil.getTimeUnitKey(_1)},isc.A.parseRelativeDateString=function isc_c_RelativeDateItem_parseRelativeDateString(_1){return isc.DateUtil.parseRelativeDateString(_1)},isc.A.isRelativeDate=function isc_c_RelativeDateItem_isRelativeDate(_1){return isc.DateUtil.isRelativeDate(_1)});isc.B._maxIndex=isc.C+5;isc.A=isc.RelativeDateItem.getPrototype();isc.A.height=20;isc.A.cellHeight=20;isc.A.canFocus=true;isc.A.timeUnitOptions=["day","week","month"];isc.A.showPastOptions=true;isc.A.showFutureOptions=true;isc.A.allowAbsoluteDates=true;isc.A.rangeRoundingGranularity={"year":"day","month":"day","week":"day","day":"day","hour":"minute","minute":"second","second":"second"};isc.A.millisecondsAgoTitle="N milliseconds ago";isc.A.secondsAgoTitle="N seconds ago";isc.A.minutesAgoTitle="N minutes ago";isc.A.hoursAgoTitle="N hours ago";isc.A.daysAgoTitle="N days ago";isc.A.weeksAgoTitle="N weeks ago";isc.A.monthsAgoTitle="N months ago";isc.A.quartersAgoTitle="N quarters ago";isc.A.yearsAgoTitle="N years ago";isc.A.millisecondsFromNowTitle="N milliseconds from now";isc.A.secondsFromNowTitle="N seconds from now";isc.A.minutesFromNowTitle="N minutes from now";isc.A.hoursFromNowTitle="N hours from now";isc.A.daysFromNowTitle="N days from now";isc.A.weeksFromNowTitle="N weeks from now";isc.A.monthsFromNowTitle="N months from now";isc.A.quartersFromNowTitle="N quarters from now";isc.A.yearsFromNowTitle="N years from now";isc.A.defaultValue="$today";isc.A.operator="greaterThan";isc.A.presetOptions={"$today":"Today","$yesterday":"Yesterday","$tomorrow":"Tomorrow","$weekAgo":"Current day of last week","$weekFromNow":"Current day of next week","$monthAgo":"Current day of last month","$monthFromNow":"Current day of next month"};isc.A.saveOnEnter=true;isc.A.$146c=130;isc.A.valueFieldDefaults={editorType:"ComboBoxItem",showTitle:false,shouldSaveValue:false,validateOnChange:false,width:"*",getInnerWidth:function(_1){var _2=this.Super("getInnerWidth",arguments);var _3=this.form.canvasItem;if(_3==null||this.$11e()||!_3.$142()||!isc.isA.Number(_2)){return Math.max(0,_2)}
return Math.max(0,_2-_3.$141())},keyPress:function(_1,_2,_3,_4){if(_3=="Enter"){var _5=_2.canvasItem;if(_5&&_5.form)
_5.form.handleKeyPress(isc.EH.lastEvent)}},pickValue:function(){this.form.canvasItem.setBaseDate();this.Super("pickValue",arguments)}};isc.A.defaultQuantity=1;isc.A.minQuantity=0;isc.A.maxQuantity=999999;isc.A.quantityFieldWidth=50;isc.A.quantityFieldDefaults={editorType:"SpinnerItem",min:0,step:1,showTitle:false,shouldSaveValue:false,selectOnFocus:true,$184a:function(_1,_2,_3){_1.updateValue();var _4=_2.canvasItem;if(_4&&_4.form){_4.updateValue();if(_3)_4.form.handleKeyPress(isc.EH.lastEvent)}},blur:function(_1,_2){_2.$184a(_2,_1)},keyPress:function(_1,_2,_3,_4){if(_3=="Enter"){_1.$184a(_1,_2,true)}}};isc.A.showChooserIcon=true;isc.A.pickerIconDefaults={name:"chooserIcon",showOver:false,showFocused:false,showFocusedWithItem:false,neverDisable:true,src:"[SKIN]/DynamicForm/DatePicker_icon.gif"};isc.A.pickerIconWidth=16;isc.A.pickerIconHeight=16;isc.A.iconVAlign="center";isc.A.pickerIconPrompt="Show Date Chooser";isc.A.pickerConstructor="DateChooser";isc.A.showCalculatedDateField=true;isc.A.invalidCalculatedDatePrompt="";isc.A.calculatedDateFieldDefaults={editorType:"BlurbItem",border:"1px solid black;",width:"*",setValue:function(_1){if(_1==null||_1=="")_1=this.defaultValue;return this.Super("setValue",arguments)},formatValue:function(_1){if(!_1||_1=="")return"";return"("+_1+")"},startRow:false,showTitle:false,shouldSaveValue:false};isc.A.centuryThreshold=isc.DateItem.DEFAULT_CENTURY_THRESHOLD;isc.A.shouldSaveValue=true;isc.A.editCriteriaInInnerForm=false;isc.A.editorConstructor="DynamicForm";isc.A.editorDefaults={numCols:4,cellPadding:0,colWidths:["*",50,22,"*"],itemChanged:function(_1,_2){this.creator.updateValue()},itemKeyPress:function(_1,_2,_3){var _1=this.canvasItem;if(_1&&_1.form){return _1.$18d(_1,_1.form,_2,_3)}}};isc.A.useSharedPicker=false;isc.A.pickerDefaults={closeOnEscapeKeypress:true,showCancelButton:true,autoHide:true};isc.A.showChooserFiscalYearPicker=false;isc.A.showChooserWeekPicker=false;isc.A=isc.RelativeDateItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.autoDestroy=true;isc.A.$113r=null;isc.A.showPickerTimeItem=true;isc.A.use24HourTime=true;isc.A.validators=[{type:"isDate"}];isc.B.push(isc.A.init=function isc_RelativeDateItem_init(){if(!this.startDate)this.startDate=isc.DateItem.getPrototype().getStartDate();if(!this.endDate)this.endDate=isc.DateItem.getPrototype().getEndDate();this.$67h();this.Super("init",arguments)},isc.A.isEditable=function isc_RelativeDateItem_isEditable(){return true},isc.A.$67h=function isc_RelativeDateItem__createEditor(){var _1;var _2={$76z:true};this.addAutoChild("editor",_2);this.canvas=this.editor;var _3=this,_4=[],_5=2;if(this.valueFieldWidth==null){var _6=isc.DateTimeItem.getInstanceProperty("width"),_7=isc.ComboBoxItem.getInstanceProperty("pickerIconWidth");_6=Math.max(this.$146c,_6+_7);this.valueFieldWidth=_6}
var _8=(this.valueFieldProperties&&this.valueFieldProperties.editorType)||this.valueFieldDefaults.editorType;if(this.allowAbsoluteDates==false){this.showChooserIcon=false;_8="SelectItem"}
_4[0]=isc.addProperties({},this.valueFieldDefaults,this.valueFieldProperties,{valueMap:this.getValueFieldOptions()},{name:"valueField",editorType:_8});_4[1]=isc.addProperties({},this.quantityFieldDefaults,this.quantityFieldProperties,{defaultValue:this.defaultQuantity,min:this.minQuantity,max:this.maxQuantity,width:this.quantityFieldWidth,minWidth:this.quantityFieldWidth},{name:"quantityField"});if(this.showChooserIcon){_5=3;_4[2]={name:"iconPlaceholder",type:"staticText",width:1,showTitle:false,canFocus:true,$872:function(){return false},focusInItem:function(){this.focusInIcon(this.icons[0])},$11s:function(_11){return false},iconVAlign:"center",icons:[isc.addProperties({prompt:this.pickerIconPrompt,width:this.pickerIconWidth,height:this.pickerIconHeight},this.pickerIconDefaults,this.pickerIconProperties,{click:function(){if(!_3.isReadOnly()){_3.showPicker()}}})]}}
var _9=this.getType(),_10=false;if(isc.SimpleType.inheritsFrom(_9,"date")&&!isc.SimpleType.inheritsFrom(_9,"datetime"))
{_10=this.isLogicalDate=true}
this.setBaseDate();if(this.showCalculatedDateField){_4[_5]=isc.addProperties({},this.calculatedDateFieldDefaults,this.calculatedDateFieldProperties,{cellStyle:this.getHintStyle(),defaultValue:this.invalidCalculatedDatePrompt},{name:"calculatedDateField"})}
this.canvas.setFields(_4);this.valueField=this.canvas.getField("valueField");this.quantityField=this.canvas.getField("quantityField");if(this.showCalculatedDateField)
this.calculatedDateField=this.canvas.getField("calculatedDateField");if(this.showChooserIcon){this.iconPlaceholder=this.canvas.getField("iconPlaceholder");this.pickerIcon=this.iconPlaceholder.icons.find("name","chooserIcon")}
this.setValue(this.value||this.defaultValue)},isc.A.getBaseDate=function isc_RelativeDateItem_getBaseDate(){return this.baseDate},isc.A.setBaseDate=function isc_RelativeDateItem_setBaseDate(_1){this.baseDate=_1||(this.isLogicalDate?isc.DateUtil.createLogicalDate():new Date())},isc.A.updateEditor=function isc_RelativeDateItem_updateEditor(){if(!this.valueField||!this.quantityField)return;var _1,_2,_3=false;if(this.valueField.hasFocus){_1=this.valueField;_2=this.valueField.getSelectionRange()}else if(this.quantityField.hasFocus){_1=this.quantityField;_2=this.quantityField.getSelectionRange()}
var _4=this.valueField.getValue(),_5=this.quantityField.getValue();var _6=(_4&&isc.isA.String(_4)&&this.relativePresets[_4]);if(!_6){_3=true;this.editor.colWidths=[this.valueFieldWidth,22,"*","*"];this.quantityField.hide()}else{_3=true;this.editor.colWidths=[this.valueFieldWidth,this.quantityFieldWidth,22,"*"];this.quantityField.show()}
if(this.calculatedDateField){var _4=this.getAbsoluteDate();var _7=this.calculatedDateField.getValue();var _8=!_4?"":""+this.formatDate(_4)+"";if(_7!=_8){_3=true;this.calculatedDateField.setValue(_8)}}
if(_3&&_1!=null){if(!_6&&_1==this.quantityField){this.valueField.focusInItem()}}},isc.A.getValueFieldOptions=function isc_RelativeDateItem_getValueFieldOptions(_1){if(_1&&this.$113r)return this.$113r;var _2=isc.addProperties({},this.presetOptions);this.relativePresets={};for(var i=0;i<this.timeUnitOptions.length;i++){var _4=this.timeUnitOptions[i];if(this.showPastOptions){_2[_4+"_ago"]=this[_4+"sAgoTitle"];this.relativePresets[_4+"_ago"]=true}
if(this.showFutureOptions){_2[_4+"_fromNow"]=this[_4+"sFromNowTitle"];this.relativePresets[_4+"_fromNow"]=true}}
this.$113r=_2;return _2},isc.A.setValue=function isc_RelativeDateItem_setValue(_1,_2){if(!this.valueField)return this.Super("setValue",arguments);if(_1==null&&!_2){var _3=this.getDefaultValue();if(_3!=null){_1=_3}}
if(isc.isA.Date(_1)&&_1.$84l!=null&&this.compareValues(this.$84m,_1.$84l))
{if(_1.getTime()==_1.$84n){_1=_1.$84l}}
var _4=false;this.setBaseDate();if(_1==null){this.valueField.setValue(null)}else if(isc.isA.Date(_1)||this.valueField.valueMap[_1]||(_1.value&&this.valueField.valueMap[_1.value]))
{var _5=isc.isA.Date(_1);_4=!_5;this.valueField.setValue(_5?this.formatDate(_1):_1.value?_1.value:_1)}else if(this.timeUnitOptions.contains(_1)){_4=true;_1+="_fromNow";this.valueField.setValue(_1)}else if(isc.isA.String(_1)&&isc.isA.Date(this.parseDate(_1,this.getInputFormat()))){_1=this.parseDate(_1,this.getInputFormat());this.valueField.setValue(this.formatDate(_1))}else{var _6,_4=isc.RelativeDateItem.isRelativeDate(_1);if(_4||isc.isA.String(_1)){_6=isc.RelativeDateItem.getAbsoluteDate(_1,this.getBaseDate(),this.getType(),this.rangePosition)}
if(!isc.isA.Date(_6)){_4=false;this.valueField.setValue(null)}else{var _7=_4?_1.value:_1;_7=isc.DateUtil.mapRelativeDateShortcut(_7,this.rangePosition);var _8,_9,_10=isc.RelativeDateItem.parseRelativeDateString(_7),_11=isc.RelativeDateItem.getPeriodName(_10.period),_12=(_10.direction=="+"?"fromNow":"ago");_9=_10?_10.countValue:null;_8=_11?_11.toLowerCase()+"_"+_12:null;if(!_10.qualifier&&_8&&this.valueField.valueMap[_8]){this.valueField.setValue(_8);this.quantityField.setValue(_9);_4=true}else{_4=false;this.valueField.setValue(this.formatDate(_6));_1=_6}}}
if(_4){this.$84m=this.getDataValue();_1=this.$84o(this.$84m)}else{this.$84m=null}
this.Super("setValue",[_1,_2],arguments);this.updateEditor()},isc.A.$84o=function isc_RelativeDateItem__convertToAbsoluteDate(_1){var _2=_1.value?_1.value:_1;var _3=isc.RelativeDateItem.getAbsoluteDate(_2,this.getBaseDate(),this.getType(),this.rangePosition);if(isc.isA.Date(_3)){_3.$84l=_1;_3.$84n=_3.getTime()}
return _3},isc.A.getAbsoluteDate=function isc_RelativeDateItem_getAbsoluteDate(){return this.getDataValue(true)},isc.A.getRelativeDate=function isc_RelativeDateItem_getRelativeDate(){var _1=this.valueField.getValue(),_2=this.quantityField.getValue();if(!_1||!isc.isA.String(_1))return null;var _3=_1.substring(0,1);if(_3=="+"||_3=="-"||(_3=="$"&&this.getValueFieldOptions(true)[_1]))
{return this.getRelativeDateObject(_1)}
var _4=_1.indexOf("_");if(_4>=0){var _5=_1.substring(0,_4),_6=(_1.substring(_4+1)=="ago"),_7=isc.RelativeDateItem.getPeriodKey(_5);if(_7){var _8=(_6?"-":"+")+_2+_7;var _9=this.rangePosition=="end"?"+":"-",_10=this.rangeRoundingGranularity[_5];if(_10!=null&&_10.toLowerCase()!="millisecond"){_10=isc.RelativeDateItem.getPeriodKey(_10).toUpperCase();_8+="["+_9+"0"+_10+"]"}
return this.getRelativeDateObject(_8)}}
return null},isc.A.getRelativeDateObject=function isc_RelativeDateItem_getRelativeDateObject(_1){var _2={_constructor:"RelativeDate",value:_1};if(this.rangePosition)_2.rangePosition=this.rangePosition;return _2},isc.A.getDataValue=function isc_RelativeDateItem_getDataValue(_1){var _2=this.valueField.getValue(),_3;if(_2==null||isc.isAn.emptyString(_2)){_3=null}else{var _4=this.getRelativeDate();if(_4){if(_1){if(!_4.value.startsWith("$")||this.getValueFieldOptions(true)[_4.value]){_3=this.$84o(_4)}}else{_3=_4}}else{_3=this.parseDate(_2,this.getInputFormat())}
if(isc.isA.Date(_3)){var _5=this.getType();if(_5){if(!isc.SimpleType.inheritsFrom(_5,"datetime")&&!isc.SimpleType.inheritsFrom(_5,"time"))
{_3.logicalDate=true}}
if(this.rangePosition){_3.rangePosition=this.rangePosition}}}
return _3},isc.A.updateValue=function isc_RelativeDateItem_updateValue(){if(!this.valueField||!this.quantityField)return;var _1=this._value,_2=this.$84m,_3=this.getDataValue(false);if(!_1&&_3)this.setBaseDate();var _4=(_3==null||isc.isA.Date(_3))?_3:this.$84o(_3);if(_3!=_4){this.$84m=_3}else{this.$84m=null}
if(this.compareValues(_1,_4)&&this.compareValues(_2,this.$84m))return;this.$10y(_4);this.updateEditor()},isc.A.hasAdvancedCriteria=function isc_RelativeDateItem_hasAdvancedCriteria(){return(this.valueField&&this.valueField.getValue()!=null)},isc.A.getCriterion=function isc_RelativeDateItem_getCriterion(_1){var _2=this.getDataValue(_1);if(_2==null)return null;if(isc.isA.Date(_2)&&this.rangePosition=="end"){if(_2.getSeconds()==0)_2.setSeconds(59);if(_2.getMilliseconds()==0)_2.setMilliseconds(999)}
var _3=this.getCriteriaFieldName();return{operator:this.operator,value:_2,fieldName:_3}},isc.A.getCellHeight=function isc_RelativeDateItem_getCellHeight(){var _1=this.Super("getCellHeight",arguments);if(isc.Browser.isIE&&this.useTextField&&isc.isA.Number(_1))_1+=2;return _1},isc.A.getFiscalCalendar=function isc_RelativeDateItem_getFiscalCalendar(){return this.fiscalCalendar||isc.DateUtil.getFiscalCalendar()},isc.A.setFiscalCalendar=function isc_RelativeDateItem_setFiscalCalendar(_1){this.fiscalCalendar=_1},isc.A.showPicker=function isc_RelativeDateItem_showPicker(){if(!this.picker){if(this.useSharedPicker)this.picker=isc.DateChooser.getSharedDateChooser();else{this.picker=isc[this.pickerConstructor].create(isc.addProperties({},this.pickerDefaults,this.pickerProperties,{_generated:true,autoHide:true,showCancelButton:true}));if(!this.picker.isDrawn()){this.picker.moveTo(null,-9999);this.picker.draw()}}}
var _1=this.picker;var _2=_1.callingFormItem;if(_2!=this){if(_2)_2.ignore(_1,"dataChanged");this.observe(_1,"dataChanged","observer.pickerDataChanged(observed)");_1.callingFormItem=this;_1.callingForm=this.canvas;_1.locatorParent=this.canvas}
if(this.inputFormat)_1.inputFormat=this.inputFormat;_1.startYear=this.getStartDate().getFullYear();_1.endYear=this.getEndDate().getFullYear();_1.fiscalCalendar=this.getFiscalCalendar();_1.showFiscalYearChooser=this.showChooserFiscalYearPicker;_1.showWeekChooser=this.showChooserWeekPicker;var _3=this.type,_4=false;if(isc.SimpleType.inheritsFrom(_3,"date")&&!isc.SimpleType.inheritsFrom(_3,"datetime"))
{_4=true}
var _5=_4?false:this.showPickerTimeItem;_1.showTimeItem=_5
_1.use24HourTime=this.use24HourTime;if(this.pickerTimeItemProperties)
_1.timeItemProperties=isc.addProperties({},_1.timeItemProperties,this.pickerTimeItemProperties);var _6=this.getAbsoluteDate();if(_1.setData){if(isc.isA.Date(_6)&&!isNaN(_6.getTime())){_1.setData(_6)}else{var _7=new Date();if(this.rangePosition=="start"){_7=isc.DateUtil.getStartOf(_7,"D")}else if(this.rangePosition=="end"){_7=isc.DateUtil.getEndOf(_7,"D")}
_1.setData(_7);_1.$1275=true}}
if(this.shouldShowPickerTimeItem()&&this.picker.timeLayout.visibility==isc.Canvas.HIDDEN){this.picker.timeLayout.show();_1.reflowNow()}else{_1.reflowNow();if(!this.shouldShowPickerTimeItem()&&this.picker.timeLayout.visibility!=isc.Canvas.HIDDEN){this.picker.timeLayout.hide()}}
if(_1.updateUI)_1.updateUI();return this.Super("showPicker",arguments)},isc.A.shouldShowPickerTimeItem=function isc_RelativeDateItem_shouldShowPickerTimeItem(){if(this.showPickerTimeItem==false)return false;return isc.SimpleType.inheritsFrom(this.type,"datetime")},isc.A.getPickerRect=function isc_RelativeDateItem_getPickerRect(){var _1=this.getPageLeft(),_2=this.getPageTop(),_3=isc.DateItem.getChooserWidth()+3,_4=isc.DateItem.getChooserHeight()+3,_5=this.canvas,_6;_6=_5.getItem("iconPlaceholder");_1+=_6.getLeft();_1+=Math.round((_6.getVisibleWidth()-(this.getPickerIconWidth()/2))-
(_3/2));_2+=Math.round((this.getPickerIconHeight()/2)-(_4/2));return[_1,_2]},isc.A.updateDisabled=function isc_RelativeDateItem_updateDisabled(){this.Super("updateDisabled",arguments);if(this.iconPlaceholder&&this.iconPlaceholder.isVisible()){this.iconPlaceholder.redraw()}},isc.A.pickerDataChanged=function isc_RelativeDateItem_pickerDataChanged(_1){var _2=_1.getData();var _3=this.getType(),_4=isc.SimpleType.inheritsFrom(_3,"date"),_5=isc.SimpleType.inheritsFrom(_3,"datetime");if((!_4||_5)){if(!this.showPickerTimeItem){this.setToZeroTime(_2);if(this.rangePosition=="end"){_2=isc.DateUtil.getEndOf(_2,"D");_2.rangePosition=this.rangePosition}}else{if(this.rangePosition=="end"){_2.rangePosition=this.rangePosition;if(_2.getSeconds()==0)_2.setSeconds(59);if(_2.getMilliseconds()==0)_2.setMilliseconds(999)}}}
this.$20l=true;this.valueField.setValue(this.formatDate(_2));this.$20l=false;this.updateValue();if(!this.hasFocus)this.focusInItem()},isc.A.getStartDate=function isc_RelativeDateItem_getStartDate(){var _1=this.parseDate(this.startDate);if(!isc.isA.Date(_1)){this.logWarn("startDate was not in valid date format - using default start date");_1=isc.DateItem.getPrototype().getStartDate()}
return _1},isc.A.getEndDate=function isc_RelativeDateItem_getEndDate(){var _1=this.parseDate(this.endDate);if(!isc.isA.Date(_1)){this.logWarn("endDate was not in valid date format - using default end date");_1=isc.DateItem.getPrototype().getEndDate()}
return _1},isc.A.parseDate=function isc_RelativeDateItem_parseDate(_1,_2){if(_1==null||isc.isAn.emptyString(_1))return null;if(_2==null)_2=this.getInputFormat();var _3=this.getType(),_4=isc.SimpleType.inheritsFrom(_3,"date"),_5=isc.SimpleType.inheritsFrom(_3,"datetime"),_6=_4&&!_5;var _7=isc.DateUtil.parseInput(_1,_2,this.centuryThreshold,true,!_6);if(isc.isA.Date(_7)&&!_6){var _8=this.getEnteredValue();if(_8!=null&&!isc.isA.Function(_2)){var _9=isc.DateUtil.isDatetimeString(_8,_2);if(!_9){this.setToZeroTime(_7);if(this.rangePosition=="end")_7=isc.DateUtil.getEndOf(_7,"D")}}}
return _7},isc.A.formatDate=function isc_RelativeDateItem_formatDate(_1){if(!isc.isA.Date(_1))return _1;var _2=this.$45i();var _3=this.getType(),_4=false,_5=isc.SimpleType.inheritsFrom(_3,"date");if(!_5||isc.SimpleType.inheritsFrom(_3,"datetime"))_4=true;if(_4){return _1.toShortDatetime(_2,true)}else{return _1.toShortDate(_2,!_5)}},isc.A.getInputFormat=function isc_RelativeDateItem_getInputFormat(){if(this.inputFormat)return this.inputFormat;var _1=this.$45i();if(_1){return isc.DateUtil.mapDisplayFormatToInputFormat(_1)}
return null},isc.A.getEnteredValue=function isc_RelativeDateItem_getEnteredValue(){if(this.valueField)return this.valueField.getValue();return this.getValue()},isc.A.getValue=function isc_RelativeDateItem_getValue(){var _1=this.Super("getValue",arguments);return _1||(this.valueField&&this.valueField.getValue())});isc.B._maxIndex=isc.C+31}
if(isc.ListGrid){isc.defineClass("DateRangeItem","CanvasItem");isc.A=isc.DateRangeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.fieldLayout="vertical";isc.A.shouldSaveValue=true;isc.A.fromTitle="From";isc.A.toTitle="To";isc.A.allowRelativeDates=false;isc.A.validateCriteria=true;isc.A.dateRangeFormConstructor="DynamicForm";isc.A.dateRangeFormDefaults={margin:0,padding:0,itemChanged:function(_1,_2){var _3=this.getValues(),_4={_constructor:"DateRange"};if(_3.fromField!=null)_4.start=_3.fromField;if(_3.toField!=null)_4.end=_3.toField;this.creator.$10y(_4)}};isc.A.relativeItemConstructor="RelativeDateItem";isc.A.absoluteItemConstructor="DateItem";isc.A.absoluteDateTimeItemConstructor="DateTimeItem";isc.B.push(isc.A.setFromDate=function isc_DateRangeItem_setFromDate(_1){this.fromDate=_1;if(this.fromField)this.fromField.setValue(this.fromDate)},isc.A.setToDate=function isc_DateRangeItem_setToDate(_1){this.toDate=_1;if(this.toField)this.toField.setValue(this.toDate)},isc.A.hasAdvancedCriteria=function isc_DateRangeItem_hasAdvancedCriteria(){return this.fromField&&this.toField&&(this.fromField.getValue()!=null||this.toField.getValue()!=null)},isc.A.getCriterion=function isc_DateRangeItem_getCriterion(_1){if(this.validateCriteria){if(!this.validateRange())return null}
_1=_1||!this.allowRelativeDates;var _2=_1?this.fromField.getValue():this.fromField.getRelativeDate()||this.fromField.getValue(),_3=_2!=null,_4=_1?this.toField.getValue():this.toField.getRelativeDate()||this.toField.getValue(),_5=_4!=null,_6=null;if(_3||_5){_6={_constructor:"AdvancedCriteria",operator:"and",criteria:[]};if(_3){if(isc.DateUtil.isRelativeDate(_2)){_2.rangePosition="start"}
if(this.fromField.isLogicalDate){_2.logicalDate=true}
_6.criteria.add({fieldName:this.getCriteriaFieldName(),operator:"greaterOrEqual",value:_2})}
if(_5){if(isc.DateUtil.isRelativeDate(_4)){_4.rangePosition="end"}
if(this.toField.isLogicalDate){_4.logicalDate=true}
_6.criteria.add({fieldName:this.getCriteriaFieldName(),operator:"lessOrEqual",value:_4})}}
return _6},isc.A.validateRange=function isc_DateRangeItem_validateRange(){var _1=true;if(this.fromField&&!this.fromField.validate())_1=false;if(this.toField&&!this.toField.validate())_1=false;return _1},isc.A.canEditCriterion=function isc_DateRangeItem_canEditCriterion(_1){if(_1==null)return false;var _2=this.getCriteriaFieldName();if(_1.operator=="and"){var _3=_1.criteria;if(_3.length==0||_3.length>2){return false}else if(_3.length==1){var _4=_3[0];if(_4.fieldName!=_2)return false;if(_4.operator=="equals"){this.logWarn("DynamicForm editing Advanced criteria. Includes criterion for field "+_2+". A dateRange editor is showing for this field and the existing criteria has operator: "+_4.operator+". DateRange items can only edit criteria greaterThan/greaterOrEqual or lessThan/lessOrEqual. However, for the 'equals' operator, a dateRange will be constructed for you, as greaterOrEqual to [value] and lessOrEqual to [value], ie, one day.");return true}}
for(var i=0;i<_3.length;i++){var _6=_3[i];if(_6.fieldName!=_2)return false;if(_6.operator!="greaterThan"&&_6.operator!="greaterOrEqual"&&_6.operator!="lessThan"&&_6.operator!="lessOrEqual")
{this.logWarn("DynamicForm editing Advanced criteria. Includes criterion for field "+_2+". A dateRange editor is showing for this field but the existing criteria has operator:"+_6.operator+". DateRange items can only edit criteria greaterThan/greaterOrEqual or lessThan/lessOrEqual so leaving this unaltered.");return false}}
return true}else if(_1.fieldName==_2){var _7="DynamicForm editing Advanced criteria. Includes criterion for field "+_2+". A dateRange editor is showing for this field and the existing criteria has operator:"+_1.operator+". DateRange items can only edit criteria greaterThan/greaterOrEqual or lessThan/lessOrEqual";if(_1.operator=="equals"){this.logWarn(_7+". However, for the 'equals' operator, a dateRange will be constructed for you, as greaterOrEqual to [value] and lessOrEqual to [value], ie, one day.");return true}
if(_1.operator!="greaterThan"&&_1.operator!="greaterOrEqual"&&_1.operator!="lessThan"&&_1.operator!="lessOrEqual")
{this.logWarn(_7+" so leaving this unaltered.");return false}
return true}
return false},isc.A.setCriterion=function isc_DateRangeItem_setCriterion(_1){if(!_1)return;if(_1.operator=="equals"){var _2={_constructor:"AdvancedCriteria",operator:"and",criteria:[{fieldName:_1.fieldName,operator:"greaterOrEqual",value:_1.value},{fieldName:_1.fieldName,operator:"lessOrEqual",value:_1.value}]};_1=_2}
var _3,_4;if(_1.operator=="and"){_3=_1.criteria.find("operator","greaterThan");if(!_3)_3=_1.criteria.find("operator","greaterOrEqual");_4=_1.criteria.find("operator","lessThan");if(!_4)_4=_1.criteria.find("operator","lessOrEqual")}else{if(_1.operator=="greaterThan")_3=_1;else if(_1.operator=="greaterOrEqual")_3=_1;else if(_1.operator=="lessThan")_4=_1;else if(_1.operator=="lessOrEqual")_4=_1}
if(_3!=null){this.fromField.setValue(_3.value)}
if(_4!=null){this.toField.setValue(_4.value)}});isc.B._maxIndex=isc.C+7;isc.A=isc.DateRangeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.autoDestroy=true;isc.A.invalidRangeErrorMessage="'To' field value cannot be earlier than 'From' field value.";isc.B.push(isc.A.init=function isc_DateRangeItem_init(){if(this.type==null)this.type="date";this.$67h();this.Super("init",arguments)},isc.A.isEditable=function isc_DateRangeItem_isEditable(){return true},isc.A.$67h=function isc_DateRangeItem__createEditor(){var _1;var _2={$76z:true};if(this.form.dataSource){_1=isc.DataSource.getDataSource(this.form.dataSource);var _3=_1.getField(this.name);if(_3){_2.dataSource=_1.getFieldDataSource(_3)}}
if(this.form&&this.form.showComplexFieldsRecursively){_2.showComplexFields=true;_2.showComplexFieldsRecursively=true}else{_2.showComplexFields=false}
_2.height=22;var _4=this.innerTitleOrientation||this.titleOrientation||this.form.titleOrientation||"left";_2.titleOrientation=_4;if(_4=="left"){if(this.fieldLayout=="vertical"){_2.numCols=2;_2.colWidths=[50,"*"]}else{_2.numCols=4;_2.colWidths=[50,"*",50,"*"]}}else if(_4=="right"){if(this.fieldLayout=="vertical"){_2.numCols=2;_2.colWidths=["*",50]}else{_2.numCols=4;_2.colWidths=["*",50,"*",50]}}else{if(this.fieldLayout=="vertical"){_2.numCols=1;_2.colWidths=["*"]}else{_2.numCols=2;_2.colWidths=["*","*"]}}
this.addAutoChild("dateRangeForm",_2);this.canvas=this.dateRangeForm;var _5=this.getType(),_6=false;if(isc.SimpleType.inheritsFrom(_5,"date")&&!isc.SimpleType.inheritsFrom(_5,"datetime"))
{_6=true}
if(!this.baseDate)this.baseDate=new Date();if(_6)this.baseDate=isc.DateUtil.getLogicalDateOnly(this.baseDate);var _7=this,_8=this.allowRelativeDates?this.relativeItemConstructor:(_6?this.absoluteItemConstructor:this.absoluteDateTimeItemConstructor),_9=[];_9[0]=isc.addProperties({},this.fromFieldDefaults,this.fromFieldProperties,{_constructor:this.fromFieldConstructor||_8,name:"fromField",baseDate:this.baseDate,dateFormatter:(this.dateDisplayFormat||this.dateFormatter),type:this.getType(),inputFormat:(this.dateInputFormat||this.inputFormat),rangePosition:"start",title:this.fromTitle,defaultValue:this.fromDate,useTextField:(!this.allowRelativeDates?true:null)});_9[1]=isc.addProperties({},this.toFieldDefaults,this.toFieldProperties,{_constructor:this.toFieldConstructor||_8,name:"toField",baseDate:this.baseDate,dateFormatter:(this.dateDisplayFormat||this.dateFormatter),type:this.getType(),inputFormat:(this.dateInputFormat||this.inputFormat),rangePosition:"end",title:this.toTitle,defaultValue:this.toDate,useTextField:(!this.allowRelativeDates?true:null)});if(!_9[1].validators)_9[1].validators=[];_9[1].validators.add({type:"custom",errorMessage:this.invalidRangeErrorMessage,condition:function(_11,_12,_13,_14){if(_13!=null&&isc.isA.Date(_13)){var _10=_14.fromField;if(_10!=null&&isc.isA.Date(_10)&&isc.DateUtil.compareDates(_10,_13)<0)
{return false}}
return true}});this.canvas.setFields(_9);this.toField=this.canvas.getField("toField");this.fromField=this.canvas.getField("fromField");if(this.defaultValue){this.setValue(this.defaultValue)}else{if(this.fromDate)this.setFromDate(this.fromDate);if(this.toDate)this.setToDate(this.toDate)}},isc.A.fieldChanged=function isc_DateRangeItem_fieldChanged(){},isc.A.setValue=function isc_DateRangeItem_setValue(_1){var _2=_1?_1.start:null,_3=_1?_1.end:null,_4=isc.RelativeDateItem;if(!this.allowRelativeDates&&_4.isRelativeDate(_2))this.setFromDate(null);else this.setFromDate(_2);if(!this.allowRelativeDates&&_4.isRelativeDate(_3))this.setToDate(null);else this.setToDate(_3);this.Super("setValue",arguments)},isc.A.getValue=function isc_DateRangeItem_getValue(){var _1=this.allowRelativeDates,_2=this.isDrawn(),_3=this.fromField,_4=this.toField,_5=null,_6=null;if(_3){if(_1&&_3.getRelativeDate)_5=_3.getRelativeDate()
if(_5==null)_5=_3.getValue()}else{_5=this.fromDate}
if(_4){if(_1&&_4.getRelativeDate)_6=_4.getRelativeDate();if(_6==null)_6=_4.getValue()}else{_6=this.toDate}
if(_5==null&&_6==null)return null;var _7={_constructor:"DateRange"};if(_5!=null)_7.start=_5;if(_6!=null)_7.end=_6;return _7});isc.B._maxIndex=isc.C+6;if(isc.Window){isc.defineClass("DateRangeDialog","Window");isc.A=isc.DateRangeDialog;isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.askForRange=function isc_c_DateRangeDialog_askForRange(_1,_2,_3,_4){var _5=isc.DateRangeDialog.create({allowRelativeDates:_1!=null?_1:true,rangeItemProperties:_2,callback:_4},_3);_5.show()});isc.B._maxIndex=isc.C+1;isc.A=isc.DateRangeDialog.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.isModal=true;isc.A.showModalMask=true;isc.A.dismissOnEscape=true;isc.A.autoCenter=true;isc.A.autoSize=true;isc.A.autoFocus=true;isc.A.vertical="true";isc.A.showMinimizeButton=false;isc.A.headerIconProperties={src:"[SKIN]/DynamicForm/DatePicker_icon.gif"};isc.A.returnCriterion=false;isc.A.headerTitle="Select Date Range";isc.A.mainLayoutDefaults={_constructor:"VLayout",width:380,height:105,layoutMargin:5};isc.A.rangeFormDefaults={_constructor:"DynamicForm",numCols:1,height:"100%",autoParent:"mainLayout"};isc.A.rangeItemConstructor="DateRangeItem";isc.A.rangeItemDefaults={allowRelativeDates:true,showTitle:false};isc.A.buttonLayoutDefaults={_constructor:"HLayout",width:"100%",height:1,layoutAlign:"right",align:"right",membersMargin:5,autoParent:"mainLayout"};isc.A.clearButtonTitle="Clear";isc.A.clearButtonConstructor="IButton";isc.A.clearButtonDefaults={width:80,canFocus:true,autoParent:"buttonLayout",click:function(){this.creator.clearValues()}};isc.A.okButtonTitle="OK";isc.A.okButtonConstructor="IButton";isc.A.okButtonDefaults={width:80,canFocus:true,autoParent:"buttonLayout",click:function(){this.creator.accept()}};isc.A.cancelButtonTitle="Cancel";isc.A.cancelButtonConstructor="IButton";isc.A.cancelButtonDefaults={width:80,canFocus:true,autoParent:"buttonLayout",click:function(){this.creator.cancel()}};isc.A.destroyOnClose=true;isc.B.push(isc.A.keyPress=function isc_DateRangeDialog_keyPress(){var _1=isc.EH.getKey();if(_1=="Enter"){this.accept()}},isc.A.closeClick=function isc_DateRangeDialog_closeClick(){this.cancel()},isc.A.destroy=function isc_DateRangeDialog_destroy(){if(this.rangeForm){this.rangeForm.markForDestroy()}
this.Super("destroy",arguments)});isc.B._maxIndex=isc.C+3;isc.A=isc.DateRangeDialog.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.initWidget=function isc_DateRangeDialog_initWidget(){this.title=this.headerTitle;this.Super("initWidget",arguments);this.addAutoChild("mainLayout");if(!this.type)this.type="date";var _1=isc.addProperties({_constructor:this.rangeItemConstructor},this.rangeItemDefaults,this.rangeItemProperties,{name:"rangeItem",fromDate:this.fromDate,toDate:this.toDate,type:this.type,dateDisplayFormat:this.dateDisplayFormat});this.addAutoChild("rangeForm",{$76z:true,items:[_1]});var _2=this.rangeItem=this.rangeForm.getField("rangeItem");var _3=_2.innerTitleOrientation||_2.titleOrientation||"left";_2.canvas.titleOrientation=_3;if(_3=="left"||_3=="right"){_2.canvas.numCols=2;_2.canvas.colWidths=[50,"*"]}else{_2.canvas.numCols=1;_2.canvas.colWidths=["*"]}
this.addAutoChild("buttonLayout");this.addAutoChild("clearButton",{canFocus:true,title:this.clearButtonTitle});this.addAutoChild("okButton",{canFocus:true,title:this.okButtonTitle});this.addAutoChild("cancelButton",{canFocus:true,title:this.cancelButtonTitle});this.addItem(this.mainLayout)},isc.A.clearValues=function isc_DateRangeDialog_clearValues(){if(this.rangeItem){this.rangeItem.setValue(null);if(this.autoValidate)this.rangeItem.validateRange()}},isc.A.accept=function isc_DateRangeDialog_accept(){if(this.autoValidate&&!this.rangeItem.validateRange()){return}
this.finished(this.rangeItem.returnCriterion?this.rangeItem.getCriterion():this.rangeItem.getValue())},isc.A.cancel=function isc_DateRangeDialog_cancel(){this.hide();if(this.item){this.rangeItem.setFromDate(this.item.fromDate);this.rangeItem.setToDate(this.item.toDate)}
if(this.destroyOnClose)this.markForDestroy()},isc.A.finished=function isc_DateRangeDialog_finished(_1){if(this.callback)this.fireCallback(this.callback,"value",[_1]);this.hide();if(this.destroyOnClose)this.markForDestroy()});isc.B._maxIndex=isc.C+5;isc.defineClass("MiniDateRangeItem","StaticTextItem");isc.A=isc.MiniDateRangeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.controlStyle="textItem";isc.A.clipValue=true;isc.A.applyHeightToTextBox=true;isc.A.wrap=false;isc.A.valign="middle";isc.A.iconVAlign="middle";isc.A.height=20;isc.A.width=100;isc.A.shouldSaveValue=true;isc.A.rangeDialogConstructor="DateRangeDialog";isc.A.rangeDialogDefaults={autoDraw:false,destroyOnClose:false};isc.A.canFocus=true;isc.A.canTabToIcons=true;isc.A.fromDateOnlyPrefix="Since";isc.A.toDateOnlyPrefix="Before";isc.A.pickerIconPrompt="Show Date Chooser";isc.A.showPickerIcon=true;isc.A.pickerIconSrc="[SKIN]/DynamicForm/DatePicker_icon.gif";isc.A.pickerIconDefaults={width:16,height:16,showOver:false,showFocused:false,showFocusedWithItem:false,hspace:0,click:function(_1,_2,_3){if(!_2.isReadOnly())_2.showRangeDialog()}};isc.A.allowRelativeDates=true;isc.B.push(isc.A.$872=function isc_MiniDateRangeItem__canFocusInTextBox(){return false},isc.A.handleClick=function isc_MiniDateRangeItem_handleClick(){if(!this.isReadOnly())this.showRangeDialog()});isc.B._maxIndex=isc.C+2;isc.A=isc.MiniDateRangeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.autoValidate=true;isc.B.push(isc.A.init=function isc_MiniDateRangeItem_init(){this.Super("init",arguments);var _1=this.getType();var _2=isc.addProperties({},this.rangeDialogProperties?this.rangeDialogProperties.rangeItemProperties:null,{allowRelativeDates:this.allowRelativeDates,criteriaField:this.criteriaField,type:_1});this.addAutoChild("rangeDialog",{type:_1,item:this,autoValidate:this.autoValidate,fromDate:this.fromDate,toDate:this.toDate,rangeItemProperties:_2,dateDisplayFormat:this.dateDisplayFormat,callback:this.getID()+".rangeDialogCallback(value)"});this.rangeItem=this.rangeDialog.rangeItem;this.rangeItem.name=this.name;if(this.defaultValue){this.setValue(this.defaultValue)}
if(this.validators)this.validators.remove(this.validators.find("type","isDate"))},isc.A.validate=function isc_MiniDateRangeItem_validate(){return this.rangeItem.validateRange()},isc.A.setAutoValidate=function isc_MiniDateRangeItem_setAutoValidate(_1){this.autoValidate=_1;if(this.rangeDialog)this.rangeDialog.autoValidate=this.autoValidate},isc.A.showRangeDialog=function isc_MiniDateRangeItem_showRangeDialog(){this.rangeDialog.show();var _1=this.rangeDialog.rangeItem;_1.setFromDate(this.fromDate);_1.setToDate(this.toDate);_1.canvas.validate()},isc.A.rangeDialogCallback=function isc_MiniDateRangeItem_rangeDialogCallback(_1){if(!this.$10y(_1))return;this.displayValue(_1)},isc.A.hasAdvancedCriteria=function isc_MiniDateRangeItem_hasAdvancedCriteria(){return this.rangeItem!=null&&this.rangeItem.hasAdvancedCriteria()},isc.A.getCriterion=function isc_MiniDateRangeItem_getCriterion(){var _1=this.rangeItem?this.rangeItem.getCriterion():null;return _1},isc.A.setCriterion=function isc_MiniDateRangeItem_setCriterion(_1){if(this.rangeItem){this.rangeItem.setCriterion(_1);var _2=this.rangeItem.getValue();this.setValue(_2,null,true)}},isc.A.canEditCriterion=function isc_MiniDateRangeItem_canEditCriterion(_1){return this.rangeItem?this.rangeItem.canEditCriterion(_1):false},isc.A.setValue=function isc_MiniDateRangeItem_setValue(_1,_2,_3){this.updateStoredDates(_1);if(!_3){this.rangeItem.setFromDate(this.fromDate);this.rangeItem.setToDate(this.toDate)}
var _4=[this.getValue()];this.Super("setValue",_4,arguments)},isc.A.updateStoredDates=function isc_MiniDateRangeItem_updateStoredDates(_1){if(_1!=null){if(isc.DataSource.isAdvancedCriteria(_1)){var _2={};for(var i=0;i<_1.criteria.length;i++){var _4=_1.criteria[i];if(_4.operator=="greaterThan"||_4.operator=="greaterOrEqual")
_2.start=_4.value;else if(_4.operator=="lessThan"||_4.operator=="lessOrEqual")
_2.end=_4.value}
_1=_2}
this.fromDate=!_1.start?null:_1.start;this.toDate=!_1.end?null:_1.end}else{this.fromDate=null;this.toDate=null;this.prompt=""}},isc.A.saveValue=function isc_MiniDateRangeItem_saveValue(){this.Super("saveValue",arguments);this.updateStoredDates(this._value)},isc.A.displayValue=function isc_MiniDateRangeItem_displayValue(_1){var _2=this.mapValueToDisplay(_1)||"";this.setElementValue(_2,_1)},isc.A.mapValueToDisplay=function isc_MiniDateRangeItem_mapValueToDisplay(_1){if(_1==null)return"";var _2=_1.start,_3=_1.end,_4=isc.RelativeDateItem,_5=(_4.isRelativeDate(_2)?_4.getAbsoluteDate(_2.value,null,null,"start"):_2),_6=(_4.isRelativeDate(_3)?_4.getAbsoluteDate(_3.value,null,null,"end"):_3);var _7;if(_5||_6){if(this.dateDisplayFormat||this.format){if(_5)_7=this.formatDate(_5);if(_6){if(_7)_7+=" - "+this.formatDate(_6);else _7=this.formatDate(_6)}}else _7=isc.DateUtil.getFormattedDateRangeString(_5,_6);if(!_5)_7=this.toDateOnlyPrefix+" "+_7;else if(!_6)_7=this.fromDateOnlyPrefix+" "+_7}
this.prompt=_7||"";return this.prompt},isc.A.getValue=function isc_MiniDateRangeItem_getValue(){if(!this.rangeItem)return;return this.rangeItem.getValue()},isc.A.formatDate=function isc_MiniDateRangeItem_formatDate(_1){if(!isc.isA.Date(_1))return _1;var _2=this.getType(),_3=isc.SimpleType.inheritsFrom(_2,"date")&&!isc.SimpleType.inheritsFrom(_2,"datetime");return _1.toShortDate(this.$45i(),!_3)},isc.A.getCriteriaValue=function isc_MiniDateRangeItem_getCriteriaValue(){return this.getCriterion()},isc.A.destroy=function isc_MiniDateRangeItem_destroy(){if(this.rangeDialog)this.rangeDialog.markForDestroy();this.Super("destroy",arguments)});isc.B._maxIndex=isc.C+18}}
if(isc.Portal){isc.defineClass("EntityEditorHeader","VLayout");isc.A=isc.EntityEditorHeader.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.height=1;isc.A.padding=10;isc.A.border="2px solid black";isc.A.headerLayoutDefaults={_constructor:"VLayout",width:"100%",height:1,membersMargin:5};isc.A.headerLabelTitle="<B><H2>Editing ${entityType}</H2><br><H3>This UI lets you edit the entire data-structure for this Entity-type</H3></B>";isc.A.headerLabelDefaults={_constructor:"Label",width:"100%",height:30,autoParent:"headerLayout"};isc.A.showDetailLabel=false;isc.A.defaultDetailLabelTitle="<B><H3>This UI lets you edit the entire data-structure for this Entity-type</H3></B>";isc.A.detailLabelTitle="<B><H3>$entityComment</H3></B>";isc.A.detailLabelDefaults={_constructor:"Label",width:"100%",height:20,autoParent:"headerLayout"};isc.A.unknownEntityTitle="[Unknown Entity-type]";isc.B.push(isc.A.initWidget=function isc_EntityEditorHeader_initWidget(){var _1=this.headerLabelTitle;var _2=this.detailLabelTitle;if(this.dataSource)this.getDataSource(this.dataSource);if(!this.entityName)this.entityName=this.getEntityName(this.dataSource);if(!this.entityComment)this.entityComment=this.getEntityComment(this.dataSource);if(this.entityName)
_1=_1.evalDynamicString(this,{entityType:this.entityName});if(this.entityComment)
_2=_2.evalDynamicString(this,{entityType:this.entityComment});this.headerLayout=this.addAutoChild("headerLayout");this.headerLabel=this.addAutoChild("headerLabel",{contents:_1});this.detailLabel=this.addAutoChild("detailLabel",{contents:_2});this.headerLayout.addMembers([this.headerLabel,this.detailLabel]);this.addMember(this.headerLayout)},isc.A.getEntityName=function isc_EntityEditorHeader_getEntityName(_1){var _2=this.unknownEntityTitle;if(_1){if(isc.isA.Function(_1.getEntityName))
_2=_1.getEntityName();else _2=_1.ID}
return _2},isc.A.getEntityComment=function isc_EntityEditorHeader_getEntityComment(_1){var _2=this.defaultDetailLabelTitle;if(_1){if(isc.isA.Function(_1.getEntityComment))
_2=_1.getEntityComment();else _2="Allows hierarchical editing of data in "+_1.ID+" DataSource"}
return _2});isc.B._maxIndex=isc.C+3;isc.defineClass("EntityEditorForm","Portlet");isc.A=isc.EntityEditorForm.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.addButtonDefaults={_constructor:"IButton",title:"Add",autoFit:true,layoutAlign:"right",click:function(){this.creator.addRecord()}};isc.A.formDefaults={_constructor:"DynamicForm",numCols:6,colWidths:["*","*","*","*","*","*"],width:"100%",implicitSave:true,initWidget:function(){this.Super("initWidget",arguments);if(this.record&&this.relation){var _1={};if(!this.relation.direction){_1[this.relation.baseFieldName]=this.record[this.relation.baseFieldName]}else{_1[this.relation.baseFieldName]=this.record[this.relation.relatedFieldName]}
this.fetchData(_1)}},implicitSaveCallback:function(_1){if(!this.record||!this.record[this.relation.baseFieldName]){this.creator.setRecord(_1);this.setValues(_1);this.saveOperationType="update"}}};isc.B.push(isc.A.initWidget=function isc_EntityEditorForm_initWidget(){this.Super("initWidget",arguments);this.addAutoChild("addButton");this.addAutoChild("form",isc.addProperties({},this.formProperties,{dataSource:this.dataSource,title:this.title,record:this.record,relation:this.relation}));if(isc.isA.Portlet(this))this.addItems([this.addButton,this.form]);else this.addMembers([this.addButton,this.form])},isc.A.fetchData=function isc_EntityEditorForm_fetchData(){var _1={};if(!this.relation.direction){if(this.isTopLevel())
_1[this.relation.baseFieldName]=this.record[this.relation.baseFieldName]}else{_1[this.relation.baseFieldName]=this.record[this.relation.relatedFieldName]}
this.form.fetchData(_1)},isc.A.addRecord=function isc_EntityEditorForm_addRecord(){var _1={};if(!this.relation.direction){if(!this.isTopLevel())
_1[this.relation.baseFieldName]=this.record[this.relation.baseFieldName]}else{_1[this.relation.baseFieldName]=this.record[this.relation.relatedFieldName]}
this.record=_1;this.form.editNewRecord(_1)},isc.A.isTopLevel=function isc_EntityEditorForm_isTopLevel(){return this.relation.relatedDS==null},isc.A.setRecord=function isc_EntityEditorForm_setRecord(_1){if(this.isTopLevel()){this.creator.updateTopLevel()}else{this.fetchData()}
this.record=_1;this.form.record=_1;if(this.addButton)this.addButton.setDisabled(this.record==null)},isc.A.getData=function isc_EntityEditorForm_getData(){return null},isc.A.getCriteria=function isc_EntityEditorForm_getCriteria(){return this.form.getValuesAsCriteria()},isc.A.enterSearchMode=function isc_EntityEditorForm_enterSearchMode(_1){this.addButton.setDisabled(true);this.record=this.form.record=null;this.form.implicitSave=false;this.form.setData([]);if(_1)this.form.setValues(_1)},isc.A.exitSearchMode=function isc_EntityEditorForm_exitSearchMode(){});isc.B._maxIndex=isc.C+9;isc.defineClass("EntityEditorGrid","Portlet");isc.A=isc.EntityEditorGrid.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.addButtonDefaults={_constructor:"IButton",title:"Add",autoFit:true,layoutAlign:"right",click:function(){this.creator.addRecord()}};isc.A.gridDefaults={_constructor:"ListGrid",width:"100%",height:"100%",autoFitMaxRecords:4,autoFetchData:false,canEdit:true,autoSaveEdits:true,initWidget:function(){if(this.record&&this.relation){this.initialCriteria={};this.initialCriteria[this.relation.baseFieldName]=this.record[this.relation.relatedFieldName]}
this.Super("initWidget",arguments)}};isc.B.push(isc.A.initWidget=function isc_EntityEditorGrid_initWidget(){this.addAutoChild("addButton");if(!isc.isA.DataSource(this.dataSource))
this.dataSource=isc.DS.get(this.dataSource);this.addAutoChild("grid",isc.addProperties({},this.gridProperties,{dataSource:this.dataSource,title:this.title,record:this.record,relation:this.relation}));if(this.record)this.fetchData();if(this.addButton)this.addButton.setDisabled(this.record==null);if(isc.isA.Portlet(this))this.addItems([this.addButton,this.grid]);else this.addMembers([this.addButton,this.grid]);this.Super("initWidget",arguments)},isc.A.setData=function isc_EntityEditorGrid_setData(_1){},isc.A.fetchData=function isc_EntityEditorGrid_fetchData(){var _1={};if(this.record){_1[this.relation.baseFieldName]=this.record[this.relation.relatedFieldName]}
this.grid.fetchData(_1)},isc.A.addRecord=function isc_EntityEditorGrid_addRecord(){var _1={};_1[this.relation.baseFieldName]=this.record[this.relation.relatedFieldName];this.grid.startEditingNew(_1)},isc.A.setRecord=function isc_EntityEditorGrid_setRecord(_1){this.record=_1;this.fetchData();if(this.addButton)this.addButton.setDisabled(this.record==null)},isc.A.getData=function isc_EntityEditorGrid_getData(){return null},isc.A.getCriteria=function isc_EntityEditorGrid_getCriteria(){return this.grid.getFilterEditorCriteria()},isc.A.enterSearchMode=function isc_EntityEditorGrid_enterSearchMode(_1){this.addButton.setDisabled(true);this.record=this.grid.record=null;this.grid.setData([]);this.grid.setShowFilterEditor(true);if(_1)this.grid.setCriteria(_1)},isc.A.exitSearchMode=function isc_EntityEditorGrid_exitSearchMode(){});isc.B._maxIndex=isc.C+9;isc.defineClass("EntityEditor","VLayout");isc.A=isc.EntityEditor.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.membersMargin=10;isc.A.padding=10;isc.A.dataSource="";isc.A.modeFormDefaults={_constructor:"DynamicForm",height:1,width:"100%",fields:[{name:"edit",title:"options",defaultToFirstOption:true,valueMap:["Edit","Search"],changed:function(_1,_2,_3){_1.creator.setMode(_3)}}]};isc.A.formEntityDefaults={_constructor:"EntityEditorForm",height:1,width:"100%"};isc.A.gridEntityDefaults={_constructor:"EntityEditorGrid",height:1,width:"100%"};isc.A.showTabset=false;isc.A.tabsetDefaults={_constructor:"TabSet",width:"100%",height:"100%"};isc.A.portalDefaults={_constructor:"PortalLayout",width:"100%",height:"100%",showColumnMenus:false,numColumns:1};isc.B.push(isc.A.getDataSourceHierarchy=function isc_EntityEditor_getDataSourceHierarchy(_1,_2){var _3=[];if(!isc.isA.DataSource(_1))
_1=isc.DS.getDataSource(_1);if(!isc.isA.DataSource(_1)){this.logWarn("No datasource provided..");return _3}
if(!_2)_2=[];if(_2.contains(_1.ID)){return null}
var _4=isc.getValues(_1.getFields()),_5=[];for(var i=0;i<_4.length;i++){if(_4[i].foreignKey!=null){_5.add(_4[i])}}
var _7=_1.ID,_8=[],_9=[];isc.DS.registerDataSource(_1);var _10=_1.getChildDataSources();if(_10){for(var i=0;i<_10.length;i++){var _11=_10[i],_12=isc.getValues(_11.getFields());for(var j=0;j<_12.length;j++){var _14=_12[j];if(!_14.foreignKey||isc.DS.getForeignDSName(_14,_11)!=_1.ID)continue;var _15=isc.DS.getForeignFieldName(_14,_11);var _16=_4.find("name",_15);if(_16&&_14.entityEditMode!="picker"){var _17=_7,_18=_16.name,_19=_11.ID,_20=_14.name,_21=_16.relationArity,_22="out";if(!_2.contains(_19)){_3.add({baseDS:_19,baseFieldName:_20,relatedDS:_17,relatedFieldName:_18,relationArity:_16.relationArity})}}}}}
for(var j=0;j<_5.length;j++){var _16=_5[j];if(!_16.foreignKey)continue;var _23=isc.DS.getForeignFieldName(_16,_1),_11=isc.DS.getDataSource(isc.DS.getForeignDSName(_16,_1)),_12=isc.getValues(_11.getFields());var _14=_12.find("name",_23);if(_14&&_16.entityEditMode!="picker"){var _17=_7,_18=_16.name,_19=this.getDSName(_11),_20=_14.name,_21=_16.relationArity,_22="out";if(!_2.contains(_19)){_3.add({baseDS:_19,baseFieldName:_20,relatedDS:_17,relatedFieldName:_18,relationArity:_21,direction:_22})}}}
return _3},isc.A.getDSName=function isc_EntityEditor_getDSName(_1){if(isc.isA.String(_1))return _1;if(isc.isA.DataSource(_1))return _1.ID;return null});isc.B._maxIndex=isc.C+2;isc.A=isc.EntityEditor.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.initWidget=function isc_EntityEditor_initWidget(){this.vertical=true;if(!isc.isA.DataSource(this.dataSource))
this.dataSource=isc.DS.getDataSource(this.dataSource);if(!this.dataSource)this.logWarn("No dataSource provided - no entity to edit");else this.entityTree=this.getEntityTree();this.addAutoChild("modeForm");this.addAutoChild("tabset");this.addAutoChild("portal");this.addMember(this.modeForm);if(this.tabset)this.addMember(this.tabset);if(this.portal)this.addMember(this.portal)},isc.A.getEntityTree=function isc_EntityEditor_getEntityTree(){if(!isc.isA.DataSource(this.dataSource))
return{baseDS:"NoDSProvided",relations:[]};var _1={baseDS:this.dataSource.ID,baseFieldName:this.dataSource.getPrimaryKeyFieldNames()[0],relations:[]};_1.relations=this.getDataSourceHierarchy(this.dataSource);return _1},isc.A.fetchDataByPK=function isc_EntityEditor_fetchDataByPK(_1){if(!this.dataSource)return;var _2=this;this.dataSource.fetchData(_1,function(_3,_4){_2.fetchDataReply(_4)})},isc.A.fetchDataReply=function isc_EntityEditor_fetchDataReply(_1){this.clearEntity();this.record=_1[0];this.showEntity()},isc.A.clearEntity=function isc_EntityEditor_clearEntity(){if(this.entities&&this.entities.length>0){if(this.showTabset){for(var i=this.tabset.tabs.length-1;i>=0;i--){this.entities[i].markForDestroy();this.tabset.removeTab(i)}}else if(this.portal){this.portal.members.removeAll();for(var i=this.entities.length-1;i>=0;i--){this.entities[i].markForDestroy()}}else{for(var i=this.members.length-1;i>=1;i--){this.removeMember(i);this.entities[i-1].markForDestroy()}}}
this.entities=[];this.record=null},isc.A.showEntity=function isc_EntityEditor_showEntity(){var _1=this.entityTree;if(!this.entities)this.entities=[];if(!this.entityTree)return;this.addEditor(_1);this.topLevelComponent=this.entities[0];if(_1&&_1.relations&&_1.relations.length>0){for(var i=0;i<_1.relations.length;i++){var _3=_1.relations[i];if(this.shouldShowEntity(_3.baseDS)){if(_3.relationArity=="one"){this.addEditor(_3)}else{this.addGrid(_3)}}}}},isc.A.updateTopLevel=function isc_EntityEditor_updateTopLevel(){for(var i=1;i<this.entities.length;i++){this.entities[i].setRecord(this.topLevelComponent.record)}},isc.A.getData=function isc_EntityEditor_getData(){return[]},isc.A.getDataSourceSpec=function isc_EntityEditor_getDataSourceSpec(_1,_2){if(this.dataSources){var _3=this.dataSources[_1];if(!_3)_3=this.dataSources[_1+"!"+_2];return _3}
return null},isc.A.getRelatedEditorProperties=function isc_EntityEditor_getRelatedEditorProperties(_1,_2){var _3=this.getDataSourceSpec(_1,_2);if(_3)return _3.editorProperties;return null},isc.A.shouldShowEntity=function isc_EntityEditor_shouldShowEntity(_1){if(this.dataSources){var _2=this.dataSources[_1],_3;if(_2===_3)return true;return(_2!==null)}
return true},isc.A.addEditor=function isc_EntityEditor_addEditor(_1){var _2=this.createAutoChild("formEntity",{height:"100%",width:"100%",dataSource:_1.baseDS,title:this.getEntityTitle(_1),record:this.record,relation:_1,formProperties:this.getRelatedEditorProperties(_1.baseDS,_1.relatedFieldName)});this.addEntityLink(_2);this.logWarn("adding linked single-record entity")},isc.A.addGrid=function isc_EntityEditor_addGrid(_1){var _2=this.createAutoChild("gridEntity",{height:"100%",width:"100%",dataSource:_1.baseDS,title:this.getEntityTitle(_1),record:this.record,relation:_1,gridProperties:this.getRelatedEditorProperties(_1.baseDS,_1.relatedFieldName)});this.addEntityLink(_2);this.logWarn("added linked multiple-record entity")},isc.A.addEntityLink=function isc_EntityEditor_addEntityLink(_1){this.entities.add(_1);if(this.showTabset){this.addEntityTab(_1)}else{var _2=_1.relation,_3=this.getDataSourceSpec(_2.baseDS,_2.relatedFieldName),_4=(_3&&_3.rowNum!=null?_3.rowNum:-1),_5=(_3&&_3.offsetInRow!=null?_3.offsetInRow:-1);if(this.portal){if(_3&&_3.userHeight!=null){_1.updateUserSize(_3.userHeight,_1.$o5)}
if(_4!=-1){this.portal.getColumn(0).addPortletToExistingRow(_1,_4,_5)}else{this.portal.getColumn(0).addPortlet(_1)}}
else this.addMember(_1)}},isc.A.getEntityName=function isc_EntityEditor_getEntityName(_1){var _2=this.getDSName(_1.baseDS),_3=this.getDSName(_1.relatedDS),_4=_1.relatedFieldName||_1.baseFieldName;return _2+"_"+_4},isc.A.getEntityTitle=function isc_EntityEditor_getEntityTitle(_1){var _2=this.getDataSourceSpec(_1.baseDS,_1.baseFieldName),_3=this.getDSName(_1.baseDS),_4=this.getDSName(_1.relatedDS),_5=_1.relatedFieldName||_1.baseFieldName,_6;if(_2&&_2.entityTitle){_6=_2.entityTitle}else if(!_4){_6=isc.DS.getAutoTitle(_3)}else if(_3!=_4){_6=isc.DS.getAutoTitle(_3)}else{_6=isc.DS.getAutoTitle(_5)}
return _6},isc.A.addEntityTab=function isc_EntityEditor_addEntityTab(_1){var _2=this.getEntityName(_1.relation),_3=this.getEntityTitle(_1.relation);if(_1){_1.setWidth("100%");_1.setHeight("100%")}
this.tabset.addTab({name:_2,title:_3,pane:_1,relation:_1.relation})},isc.A.setMode=function isc_EntityEditor_setMode(_1){var i,_3;if(_1=="Search"){if(this.entities&&this.entities.length>0){for(i=0;i<this.entities.length;i++){_3=this.entities[i];if(isc.isA.EntityEditorGrid(_3)){_3.enterSearchMode(this.getEntityCriteria(_3));_3.markForRedraw()}else if(isc.isA.EntityEditorForm(_3)){_3.enterSearchMode(this.getEntityCriteria(_3));_3.markForRedraw()}}}}else{if(!this.entityCriteria)this.entityCriteria={};if(this.entities&&this.entities.length>0){for(i=0;i<this.entities.length;i++){_3=this.entities[i];var _4=_3.getCriteria();if(_4){this.entityCriteria[_3.getID()]={relation:_3.relation,criteria:_4}}}}}},isc.A.getEntityCriteria=function isc_EntityEditor_getEntityCriteria(_1){if(this.entityCriteria){return this.entityCriteria[_1.getID()]}
return null});isc.B._maxIndex=isc.C+19}
if(isc.ListGrid){isc.defineClass("PresetCriteriaItem","SelectItem");isc.PresetCriteriaItem.addClassMethods({})
isc.A=isc.PresetCriteriaItem.getPrototype();isc.A.canFocus=true;isc.A.customOptionTitle="Custom...";isc.A.shouldSaveValue=true;isc.A=isc.PresetCriteriaItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.init=function isc_PresetCriteriaItem_init(){if(!this.options)this.options={};this.valueMap={};for(var _1 in this.options){this.valueMap[_1]=_1}
if(this.showCustomOption){this.options["customOption"]=null;this.valueMap["customOption"]=this.customOptionTitle}
this.Super("init",arguments)},isc.A.changed=function isc_PresetCriteriaItem_changed(_1,_2,_3){if(_3=="customOption"){if(this.getCustomCriteria&&isc.isA.Function(this.getCustomCriteria))
this.getCustomCriteria(this.getID()+".getCustomCriteriaReply(criteria,title)")}},isc.A.getCustomCriteria=function isc_PresetCriteriaItem_getCustomCriteria(_1){},isc.A.getCustomCriteriaReply=function isc_PresetCriteriaItem_getCustomCriteriaReply(_1,_2){this.valueMap["customOption"]=_2;this.options["customOption"]=_1},isc.A.getCriteriaValue=function isc_PresetCriteriaItem_getCriteriaValue(){return this.getCriterion()},isc.A.hasAdvancedCriteria=function isc_PresetCriteriaItem_hasAdvancedCriteria(){return true},isc.A.getCriterion=function isc_PresetCriteriaItem_getCriterion(){var _1=this.getValue(),_2=this.options[_1];return _2},isc.A.updateCriteriaFieldNames=function isc_PresetCriteriaItem_updateCriteriaFieldNames(_1){for(var _2 in _1){var _3=_1[_2];if(isc.DataSource.isAdvancedCriteria(_3)){_3=this.updateCriteriaFieldNames(_3)}else{if(!_3.fieldName){_3.fieldName=this.getCriteriaFieldName()}}}
return _1},isc.A.setValue=function isc_PresetCriteriaItem_setValue(_1){_1=this.matchCriteria(_1);this.Super("setValue",arguments)},isc.A.setValueMap=function isc_PresetCriteriaItem_setValueMap(_1){return null},isc.A.canEditCriterion=function isc_PresetCriteriaItem_canEditCriterion(_1){var _2=isc.DS.isAdvancedCriteria(_1)?isc.DS.getCriteriaFields(_1).getUniqueItems():_1.criteria?_1.criteria.getProperty("fieldName").getUniqueItems():[_1.fieldName];var _3=this.getCriteriaFieldName();return _2.contains(_3)},isc.A.setCriterion=function isc_PresetCriteriaItem_setCriterion(_1){this.setValue(isc.shallowClone(_1))},isc.A.matchCriteria=function isc_PresetCriteriaItem_matchCriteria(_1,_2){var _3=_2||this.options;for(var _4 in _3){var _5=_3[_4];if(this.objectsAreEqual(_5,_1)){return _4}}
return _1},isc.A.objectsAreEqual=function isc_PresetCriteriaItem_objectsAreEqual(_1,_2){if(!_1&&!_2)return true;if(!_1||!_2)return false;for(var _3 in _1){if(_3=="_constructor")continue;var _4=_1[_3],_5=_2[_3];if(isc.isAn.Array(_4)){for(var i=0;i<_4.length;i++){if(isc.isAn.Object(_4[i])){if(!this.objectsAreEqual(_4[i],_5[i]))return false}else{if(_4[i]!=_5[i])return false}}}else if(isc.isA.Date(_4)){if(isc.DateUtil.compareDates(_4,_5)!=0)return false}else if(isc.isAn.Object(_4)){if(!this.objectsAreEqual(_4,_5))return false}else{if(_1[_3]!=_2[_3])return false}}
return true});isc.B._maxIndex=isc.C+14;isc.defineClass("PresetDateRangeItem","PresetCriteriaItem");isc.A=isc.PresetDateRangeItem.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.customOptionTitle="Custom Date Range";isc.B.push(isc.A.getCustomCriteria=function isc_PresetDateRangeItem_getCustomCriteria(_1){this.$03=_1;isc.DateRangeDialog.askForRange(true,{returnCriterion:true},null,this.getID()+".showDateRangeDialogReply(value)")},isc.A.showDateRangeDialogReply=function isc_PresetDateRangeItem_showDateRangeDialogReply(_1){var _2=this.$03;delete this.$03;this.fireCallback(_2,"criteria,title",[_1,this.customOptionTitle])},isc.A.getCriterion=function isc_PresetDateRangeItem_getCriterion(){var _1=this.getValue(),_2=this.options[_1];return _2});isc.B._maxIndex=isc.C+3}
isc._nonDebugModules=(isc._nonDebugModules!=null?isc._nonDebugModules:[]);isc._nonDebugModules.push('Forms');isc.checkForDebugAndNonDebugModules();isc._moduleEnd=isc._Forms_end=(isc.timestamp?isc.timestamp():new Date().getTime());if(isc.Log&&isc.Log.logIsInfoEnabled('loadTime'))isc.Log.logInfo('Forms module init time: '+(isc._moduleEnd-isc._moduleStart)+'ms','loadTime');delete isc.definingFramework;if(isc.Page)isc.Page.handleEvent(null,"moduleLoaded",{moduleName:'Forms',loadTime:(isc._moduleEnd-isc._moduleStart)});}else{if(window.isc&&isc.Log&&isc.Log.logWarn)isc.Log.logWarn("Duplicate load of module 'Forms'.");}
