\n
\n
\n
\n {{#multiple}}{{#reset}}\n {{{.}}}\n {{/reset}}{{/multiple}}\n
\n
\n\n`;\n };\n\n var formSelect = function (columnKeys) {\n return `\n
\n`;\n };\n\n var formSelectOptions = function (columnKeys) {\n return `\n{{#selected}}\n
\n{{/selected}}\n`;\n };\n\n\n var options = function (columnKeys) {\n return `\n{{#waitOptions}}\n
\n
\n \n {{{lang.loading}}}\n \n
\n
\n{{/waitOptions}}\n{{^waitOptions}}\n {{#options}}\n {{^hide}}\n
\n
\n {{${columnKeys.optionText}}}\n
\n
\n {{/hide}}\n {{/options}}\n {{^options}}\n
\n
\n \n {{{lang.noOptions}}}\n \n
\n
\n {{/options}}\n{{/waitOptions}}\n`;\n };\n\n var label = function (columnKeys) {\n return `{{#selected}}
{{/selected}}`;\n };\n\n AUTOCOMPLETE.tmpl = {\n \"autocompleteDisplay\": autocompleteDisplay,\n \"formSelect\": formSelect,\n \"formSelectOptions\": formSelectOptions,\n \"optionGroup\": optionGroup,\n \"options\": options,\n \"label\": label,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(AUTOCOMPLETE.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();"]}
\ No newline at end of file
+{"version":3,"sources":["ax5ui.all.min.js","ax5-core.js","ax5-def.js","ax5-error-msg.js","ax5-polyfill.js","ax5-ui.js","mustache.js","ax5dialog.js","ax5dialog-tmpl.js","ax5mask.js","ax5mask-tmpl.js","ax5toast.js","ax5toast-tmpl.js","ax5modal.js","ax5modal-tmpl.js","ax5calendar.js","ax5calendar-tmpl.js","ax5picker.js","ax5ui-picker-tmpl.js","ax5formatter.js","ax5formatter-formatter.js","ax5menu.js","ax5menu-tmpl.js","ax5select.js","ax5select-tmpl.js","ax5grid.js","ax5grid-body.js","ax5grid-collector.js","ax5grid-data.js","ax5grid-excel.js","ax5grid-formatter.js","ax5grid-header.js","ax5grid-inline-editor.js","ax5grid-page.js","ax5grid-scroller.js","ax5grid-tmpl.js","ax5grid-util.js","ax5media-viewer.js","ax5media-viewer-tmpl.js","ax5uploader.js","ax5uploader-tmpl.js","ax5combobox.js","ax5combobox-tmpl.js","ax5combobox-util.js","ax5layout.js","ax5binder.js","ax5autocomplete.js","ax5autocomplete-tmpl.js"],"names":["_typeof","Symbol","iterator","obj","constructor","prototype","info","U","root","this","win","doc","document","reIsJson","documentElement","reMs","reSnakeCase","reCamelCase","reDot","reInt","reNotNum","reMoneySplit","RegExp","reAmp","reEq","reClassNameSplit","ax5","guid","getGuid","urlUtil","url","urls","href","location","param","search","referrer","pathname","hostname","port","split","replace","hashdata","last","baseUrl","left","getError","className","errorCode","methodName","errorMsg","msg","version","onerror","console","error","toArray","arguments","join","eventKeys","BACKSPACE","TAB","RETURN","ESC","LEFT","UP","RIGHT","DOWN","DELETE","HOME","END","PAGEUP","PAGEDOWN","INSERT","SPACE","weekNames","label","browser","ua","mobile","browserName","match","browserVersion","navigator","userAgent","toLowerCase","name","exec","indexOf","isBrowser","window","wheelEnm","test","supportTouch","maxTouchPoints","msMaxTouchPoints","supportFileApi","FileReader","File","FileList","Blob","each","O","_fn","isNothing","key","i","l","length","isObj","undefined","call","map","fnResult","results","isObject","push","isFunction","sum","defaultValue","tokenValue","isArray","avg","reduce","tokenItem","reduceRight","filter","k","toJson","jsonString","util","jsonObjectBody","value","isString","isNumber","isUndefined","parseJson","str","force","Function","e","getType","typeName","nodeType","_toString","isWindow","isElement","isNodelist","isDate","Date","isNaN","valueOf","isDateFormat","result","date","mm","substr","dd","getMonth","getDate","first","keys","Object","item","setCookie","cn","cv","exdays","opts","expire","setDate","cookie","escape","toUTCString","path","domain","secure","getCookie","cname","ca","c","charAt","substring","unescape","alert","pos","right","lastIndexOf","camelCase","all","letter","toUpperCase","snakeCase","number","cond","pair","isMinus","Number","returnValue","Math","round","abs","floor","ceil","val","txtNumber","arrNumber","nUnit","myByte","Array","slice","merge","second","j","p","v","encode","s","encodeURIComponent","decode","decodeURIComponent","apply","localDate","yy","hh","mi","ss","utcD","localD","UTC","getUTCHours","getTimezoneOffset","setUTCHours","d","aDateTime","aTimes","aTime","aDate","va","ISO_8601","ISO_8601_FULL","parseFloat","_d","mxdd","DyMilli","setTime","getTime","getFullYear","parseInt","daysOfMonth","processor","firstDayOfMonth","lastDayOfMonth","nY","nM","nD","nH","nMM","nS","nDW","fStr","getUTCFullYear","setDigit","getHours","getMinutes","getSeconds","getDay","yre","regY","$1","mre","regM","dre","regD","hre","regH","mire","regMI","sre","regS","dwre","regDW","dday","getDayTime","diffnum","thisYearMemoryDay","memoryDay","today","weeksOfMonth","myDate","year","month","count","y","m","num","padder","radix","toString","times","findParentNode","_target","parentNode","tagName","toLocaleLowerCase","klasss","hasClass","a","getAttribute","cssNumber","re","found","unit","css","returns","valSplited","forEach","trim","vSplited","stopEvent","event","cancelBubble","stopPropagation","preventDefault","deepCopy","r","jQuery","extend","escapeHtml","unescapeHtml","string","_string","ax5string","format","args","concat","_pos","selectRange","textRange","selectAll","el","range","offset","arr","moveStart","collapse","moveEnd","start","end","text","selectNodeContents","setStart","node","setEnd","firstChild","rangeType","selection","get","body","createTextRange","moveToElementText","getSelection","createRange","select","focus","removeAllRanges","addRange","debounce","func","wait","immediately","timeout","removeTimeout","debounced","clearTimeout","setTimeout","bind","cancel","module","exports","def","501","401","402","460","461","re_trim","hwp","hasOwnProperty","hdeb","propertyIsEnumerable","de","del","TypeError","prop","fun","t","len","thisp","o","nop","self","bound","querySelectorAll","querySelector","createStyleSheet","style","selector","maxCount","resultSet","addRule","currentStyle","foo","removeRule","Infinity","String","JSON","parse","sJSON","stringify","f","vContent","splice","documentMode","_splice","_slice","begin","size","cloned","max","upTo","min","con","method","empty","dummy","properties","methods","pop","webkitMatchMedia","mozMatchMedia","oMatchMedia","msMatchMedia","matchMedia","getElementsByTagName","styleMedia","media","createElement","script","type","id","insertBefore","getComputedStyle","matchMedium","styleSheet","cssText","textContent","width","matches","addListener","localMatchMedia","hasMediaQueries","isListening","timeoutID","queries","handleChange","evt","il","mql","listeners","jl","index","listener","addEventListener","removeListener","ui","axUi","config","setConfig","cfg","callInit","init","log","bindWindowResize","callBack","resize","bindWindowResize__","main","addClass","cls","classStore","factory","arg","initInstance","instance","instanceId","initPrototype","superClass","wrapper","global","mustache","object","typeStr","escapeRegExp","hasProperty","propName","testRegExp","regExpTest","isWhitespace","nonSpaceRe","entityMap","parseTemplate","template","tags","stripSpace","hasTag","nonSpace","spaces","tokens","compileTags","tagsToCompile","spaceRe","Error","openingTagRe","closingTagRe","closingCurlyRe","sections","chr","token","openSection","scanner","Scanner","eos","scanUntil","valueLength","scan","tagRe","whiteRe","equalsRe","curlyRe","nestTokens","squashTokens","lastToken","squashedTokens","numTokens","section","nestedTokens","collector","tail","Context","view","parentContext","cache",".","@each","@key","@value","parent","Writer","objectToString","&","<",">","\"","'","/","lookup","names","context","lookupHit","clearCache","render","partials","renderTokens","originalTemplate","symbol","buffer","renderSection","renderInverted","renderPartial","unescapedValue","escapedValue","rawValue","subRender","defaultWriter","to_html","send","DIALOG","UI","ax5dialog","clickEventName","theme","title","lang","ok","animateTime","activeDialog","onStateChanged","that","getContent","dialogId","data","input","btns","_crlf","tmpl","open","callback","box","append","height","position","top","zIndex","dialogType","find","on","btnOnClick","onKeyup","align","state","dialogConfig","innerHeight","innerWidth","target","srcElement","btnTarget","emptyKey","oi","onClick","close","doNotCallback","keyCode","tryCount","confirm","prompt","_option","unbind","remove","dialog_instance","dialog","dialogDisplay","columnKeys","tmplName","MASK","ax5mask","maskContent","status","getBodyTmpl","templateName","setBody","content","options","maskConfig","$mask","_cfg","$target","maskId","outerWidth","outerHeight","_$target","_delay","_this2","_close","removeClass","fadeOut","_this3","pullRequest","mask_instance","mask","defaultMask","TOAST","ax5toast","toastSeq","toastSeqClear","icon","closeIcon","displayTime","containerPosition","toastContainer","queue","toastId","toastBox","containerId","prepend","toastType","btn_target","styles","toast_instance","toast","toastDisplay","MODAL","ax5modal","ENM","mousedown","mousemove","mouseup","getMousePosition","mouseObj","changedTouches","clientX","clientY","margin","minimizePosition","closeToEsc","disableDrag","activeModal","watingModal","$","modalId","header","fullScreen","iframe","iframeLoadingMsg","absolute","attr","action","hide","show","submit","onkeyup","isFullScreen","isButton","mousePosition","moveModal","alignProcessor","top-left","top-right","bottom-left","bottom-right","center-middle","modalZIndex","modalOffset","modalBox","windowBox","getResizerPosition","__dx","__dy","minX","maxX","minY","maxY","scrollLeft","scrollTop","resizer","resizerBg","off","setModalPosition","removeAttr","modalConfig","$iframe","iframeObject","idoc","contentDocument","contentWindow","children","innerHTML","CollectGarbage","minimized","minimize","originalHeight","maximize","setModalConfig","_config","_fullScreen","headerHeight","modal_instance","modal","CALENDAR","ax5calendar","selectableCount","selectionMap","selectableMap","markerMap","printedDay","startOfWeek","mode","dateFormat","displayDate","dimensions","controlHeight","controlButtonWidth","colHeadHeight","itemPadding","yearHeading","monthHeading","yearTmpl","months","dayTmpl","multipleSelect","selectMode","defaultMarkerTheme","defaultPeriodTheme","getFrame","controlCSS","controlButtonCSS","setDisplay","yy1","yy2","control","monthTmpl","html","yearFirst","changeMode","printDay","nowDate","loopDate","_k","dotDate","monthStratDate","_today","tableStartDate","day","add","thisMonth","itemStyles","frameWidth","frameHeight","list","n","thisDate","return","_date","row","col","isStartOfWeek","thisDataLabel","classNames","selectable","onclick","printMonth","tableStartMonth","nMonth","colHeadLabel","_month","isStartOfRow","thisMonthLabel","printYear","tableStartYear","nYear","_year","thisYear","thisYearLabel","removed","dt","dateElement","move","applyMarkerMap","applySelectionMap","applyPeriodMap","periodMap","clearPeriodMap","control-display","setSelection","setSelectable","marker","setMarker","changeDate","isPrint","from","to","isApply","setPeriod","fromLabel","toLabel","period","calendar_instance","calendar","frameTmpl","PICKER","ax5picker","picker","date_leftArrow","date_yearTmpl","date_monthTmpl","date_rightArrow","activePicker","activePickerQueueIndex","openTimer","closeTimer","bindPickerTarget","pickerEvent","queIdx","click","pickerType","@fn","_input","inputLength","contentWidth","contentMargin","secure-num","keyboard","numpad","formatter","ax5formatter","alignPicker","_alignPicker","pickerDirection","$window","$body","positionMargin","dim","pickerDim","winWidth","winHeight","direction","positionCSS","activePickerArrow","onBodyClick","onBtnClick","onBodyKeyup","getQueIdx","boundID","pickerConfig","setContentValue","multipleInputProcessor","_item","_inputIndex","_val","diffDay","prevInputValue","nextInputValue","values","pickerCalendar","ax5uiInstance","inputIndex","disableChangeTrigger","trigger","pickerContent","calendarConfig","idx","dValue","itemId","po","numArray","x","random","specialArray","fn","btnWrapStyle","btnTheme","btnStyle","specialBtnTheme","act","keyArray","shiftValue","getKeyBoard","isShiftKey","keyValue","keyLabel","specialBtnWrapStyle","specialBtnStyle","$this","toggleShift","picker_instance","defaultConfig","pickerTmpl","FORMATTER","setSelectionRange","selectionStart","selectionEnd","formatterEvent","optIdx","$input","keydown","isStop","enterableKeyCodes","which","metaKey","ctrlKey","shiftKey","keyup","elemFocusPosition","beforeValue","newValue","selectionLength","elem","pattern","getPatternValue","blur","_force","removeData","bindFormatterTarget","matched","patternArgument","getEnterableKeyCodes","formatterConfig","formatting","formatter_instance","ctrlKeys","18","8","17","46","40","35","187","27","36","45","37","189","34","33","13","39","16","9","38","91","numKeys","48","49","50","51","52","53","54","55","56","57","96","97","98","99","100","101","102","103","104","105","pattern_money","_opts","188","eType","regExpPattern","maxRound","pattern_number","190","pattern_date","191","matchedPattern","inspectValue","inspect","Y","TODAY","M","D","dLen","h","b","nval","pattern_time","186","pattern_bizno","pattern_phone","regExpPattern3","pattern_credit","pattern_custom","money","time","bizno","phone","credit","custom","MENU","ax5menu","iconWidth","acceleratorWidth","menuBodyPadding","items","itemClickAndClose","menuBar","appEventAttach","active","menuId","clickItem","onLoad","popup","opt","depth","activeMenu","icons","divide","childOpt","_items","_activeMenu","@parent","element","check","setValue","checkbox","checked","radio","$document","wh","ww","w","getOption","pageY","updateTheme","filteringItem","attach","popUpChildMenu","openedIndex","opened","clickParentMenu","getCheckValue","checkItems","collectItem","menu_instance","menu","tmplMenubar","SELECT","ax5select","noSelected","noOptions","loading","multipleLabel","optionValue","optionText","optionSelected","activeSelectOptionGroup","activeSelectQueueIndex","waitOptionsCallback","keyUpTimer","xvar","onChange","alignSelectDisplay","$display","$select","minWidth","min-width","reset","line-height","alignSelectOptionGroup","newTop","clickEl","gindex","multiple","optionFocusIndex","$option","getLabel","labels","selected","optgroup","syncLabel","$displayLabel","focusWord","searchWord","indexedOptions","@findex","optionsSort","sort","focusMove","findex","_focusIndex","_prevFocusIndex","focusOptionEl","optionGroupScrollContainer","optionSelectedIndex","optionItemLength","focusOptionElHeight","optionGroupScrollContainerHeight","optionGroupScrollContainerScrollTop","focusOptionElTop","bindSelectTarget","focusWordCall","$displayInput","selectEvent","clear","keyUp","keyDown","selectChange","syncSelectOptions","tabIndex","formSize","setSelected","elementOptions","newOptions","focusIndex","OIndex","OO","OOIndex","option","selectConfig","onExpand","optionsMap","_O","_OIndex","focusTop","selectedOptionEl","waitOptions","stop","animate","update","getSelected","clearSelected","nn","optionIndex","internal","onClose","enable","disable","select_instance","optionGroupTmpl","selectTmpl","optionsTmpl","GRID","ax5grid","frozenColumnIndex","frozenRowIndex","showLineNumber","showRowSelector","columnMinWidth","lineNumberColumnWidth","rowSelectorColumnWidth","sortable","remoteSort","columnHeight","columnPadding","columnBorderWidth","grouping","rightSum","footSum","page","display","navigationItemCount","scroller","barMinSize","trackPadding","modified","deleted","disableSelection","bodyTrHeight","scrollContentWidth","scrollContentHeight","columns","colGroup","footSumColumns","bodyGrouping","selectedDataIndexs","deletedList","sortInfo","focusedColumn","selectedColumn","isInlineEditing","inlineEditing","headerTable","leftHeaderData","headerData","rightHeaderData","bodyRowTable","leftBodyRowData","bodyRowData","rightBodyRowData","bodyRowMap","bodyGroupingTable","leftBodyGroupingData","bodyGroupingData","rightBodyGroupingData","footSumTable","leftFootSumData","footSumData","needToPaintSum","initGrid","container","hidden","panel","aside-header","left-header","header-scroll","right-header","top-aside-body","top-left-body","top-body","top-body-scroll","top-right-body","aside-body","aside-body-scroll","left-body","left-body-scroll","body-scroll","right-body","right-body-scroll","bottom-aside-body","bottom-left-body","bottom-body","bottom-body-scroll","bottom-right-body","livePanelKeys","vertical","vertical-bar","horizontal","horizontal-bar","corner","navigation","form","clipboard","initColumns","_columns","makeHeaderTable","makeBodyRowTable","makeBodyRowMap","rows","colGroupMap","rl","cl","cols","colIndex","onResetColumns","resetColGroupWidth","initFootSum","initBodyGroup","alignGrid","repaint","computedWidth","CT_WIDTH","totalWidth","autoWidthColgroupIndexs","_width","_footSum","makeFootSumTable","_grouping","by","makeBodyGroupingTable","kl","orderBy","seq","fixed","sortFixed","_isFirst","verticalScrollerWidth","horizontalScrollerHeight","CT_HEIGHT","CT_INNER_WIDTH","CT_INNER_HEIGHT","asidePanelWidth","frozenPanelWidth","endIndex","rightPanelWidth","frozenRowHeight","footSumHeight","pageHeight","totalColGroupWidth","bodyWidth","bodyHeight","panelDisplayProcess","vPosition","hPosition","containerType","isHide","scrollerDisplayProcess","scrollerWidth","scrollerHeight","sortColumns","_sortInfo","initData","clearGroupingData","onDataChanged","grid","isPickerClick","focused","originalEvent","copySelect","KEY_UP","moveFocus","KEY_DOWN","KEY_LEFT","KEY_RIGHT","KEY_HOME","KEY_END","INLINE_EDIT","_e","inlineEdit","activeEditLength","columnKey","_act","_data","copysuccess","_rowIndex","_colIndex","_dindex","$clipBoard","copyTextArray","copyText","_di","_column","dindex","rowIndex","originalColumn","__isGrouping","innerText","execCommand","setData","set","navigationUpdate","scrollTo","getList","_type","setHeight","_height","offsetParent","addRow","_row","_options","removeRow","updateRow","repaintRow","deleteRow","_key","_value","repaintCell","_panelName","_rows","__dindex","__key","__value","addColumn","_cindex","removeColumn","updateColumn","setColumnWidth","columnResizerIndex","getColumnSortInfo","setColumnSort","applySortStatus","_selectObject","selectedClear","clearSelect","updateRowState","updateRowStateAll","exportExcel","_fileName","table","getExcelString","excel","_this4","selectedIndex","grid_instance","columnSelect","focusClear","panelName","column","editKey","colspan","selectedRange","deActive","trl","_panels","columnSelector","cell","_states","si","cellChecked","_state","targetClick","default","editor","getValue","trueValue","falseValue","editorConfig","rowSelector","internalCall","lineNumber","touchmoved","resetFrozenColumn","dividedBodyRowObj","divideTableByFrozenColumnIndex","asideBodyRowData","dataTable","rowspan","_col","columnAttr","leftData","rightData","dividedBodyGroupingObj","asideBodyGroupingData","dividedFootSumObj","getFieldValue","_list","_index","_returnPlainText","tagsToReplace","_editor","inlineEditor","editMode","disabled","getHtml","tag","getGroupingValue","_label","__groupingList","groupBy","__groupingBy","getSumFieldValue","_reset","paintStartRowIndex","dataRowCount","isFirstPaint","bodyAlign","paintRowCount","repaintBody","_elTargetKey","_colGroup","_bodyRow","_groupRow","_scrollConfig","_elTarget","SS","cgi","cgl","di","dl","tri","ci","cellHeight","colAlign","isScrolled","isGroupingRow","rowTable","_focusedColumn","_selectedColumn","attrs","tdCSS_class","styleClass","_cellHeight","lineHeight","multiLine","repaintSum","isFootSum","scrollConfig","asideColGroup","leftHeaderColGroup","headerColGroup","statusUpdate","_newValue","updateCell","updateWith","updateColumnKey","findPanelByColumnIndex","updateWithCell","replaceGroupTr","replaceTr","noRepaint","_position","UD","_dy","moveResult","while_i","nPanelInfo","LR","_dx","isScrollPanel","containerPanelName","$column","newLeft","INDEX","_initValue","useReturnToSave","originalValue","initValue","__editor","$inlineEditorCell","$inlineEditor","_msg","editorValue","CANCEL","__clear","bindedAx5ui","getBody","getSum","listLength","returnList","appendIndex","dataRealRowCount","groupingKeys","compareString","gi","gl","appendRow","ari","appendRowItem","ki","lastIndex","getRealPathForDataItem","_selected","sortInfoArray","getKeyValue","order","_a_val","_b_val","_a","_b","base64","btoa","uri","getExcelTmpl","tableToExcel","fileName","output","tables","worksheet","ti","isChrome","isSafari","isIE","msSaveOrOpenBlob","blob1","blankWindow","write","anchor","appendChild","download","removeChild","export","columnResizerEvent","_columnResizer","$columnResizer","columnResizerPositionLeft","gridTargetOffsetLeft","resizeRange","__da","columnResizerLived","toggleSort","dividedHeaderObj","asideHeaderData","headerAlign","repaintHeader","tableWidth","trCSS_class","_SS","enableFilter","resizerHeight","resizerLeft","AS","sortOrder","multiSort","getHeader","edit_text","_root","_columnKey","_$parent","$el","bindUI","_$el","edit_money","edit_number","edit_date","edit_select","eConfig","edit_checkbox","marginTop","onclickPageMove","_pageNo","currentPage","selectPage","prev","pageNo","next","totalPages","hasPage","pageSize","totalElements","firstIcon","prevIcon","nextIcon","lastIcon","startI","endI","fromRowIndex","toRowIndex","convertScrollPosition","_var","_content_height","_panel_height","_scroller_height","_vertical_scroller_height","verticalScrollBarHeight","_content_width","_panel_width","_scroller_width","_horizontal_scroller_width","horizontalScrollBarWidth","convertScrollBarPosition","_top","scrollPositon","_left","scrollBarMover","track","bar","moveout_timer","trackOffset","barBox","trackBox","getScrollerPosition","barOffset","scrollContentMover","wheel","delta","_body_scroll_position","_top_is_end","_left_is_end","getContentPosition","__x_da","__y_da","E","detail","deltaY","wheelDelta","deltaX","page_navigation","page_status","_table","_frozenColumnIndex","tempTable_l","tempTable_r","colStartIndex","colEndIndex","leftCol","rightCol","pageX","maekRows","parentField","field","selfMakeRow","__columns","_footSumColumns","footSumRow","addC","_bodyGroupingColumns","_containerPanelName","_isScrollPanel","_dataPath","_path","MEDIAVIEWER","ax5mediaViewer","src","poster","viewer","prevHandle","nextHandle","ratio","elementType","thumbnail","getSelectedIndex","selecteIndex","alignMediaList","thumbnailWidth","containerWidth","parentLeft","parentWidth","swipeMedia","getSwipePosition","__time","viewerWidth","nextIndex","viewer-holder","viewer-loading","list-holder","list-prev-handle","list-table","list-next-handle","$img","_img","mediaThumbnailWidth","mediaThumbnailHeight","mediaView","image","img","Image","onload","video","setMediaList","mediaViewer_instance","mediaViewer","frame","UPLOADER","ax5uploader","upload","abort","uploadedBox","uploadedName","uploadedPath","downloadPath","previewPath","accept","manualUpload","progressBox","defaultBtns","uploadedFiles","$inputContainer","$inputFile","$inputFileForm","$fileSelector","$dropZone","$uploadedBox","__uploading","selectedFiles","selectedFilesTotal","__loaded","bound_onStateChanged","bound_onSelectFile","_evt","files","dataTransfer","bound_openProgressBox","bound_alignLayout","bound_bindEvent","cellType","uploadedItemIndex","parents","fileIndex","contains","dropZone","ondragover","ondragout","ondrop","_TF","bound_alignProgressBox","_alignProgressBox","$progressBox","progressBoxDirection","$progressBoxArrow","viewport","$progressUpload","$progressAbort","bound_closeProgressBox","bound_startUpload","html5","uploadFile","shift","bound_uploadComplete","formData","FormData","xhr","XMLHttpRequest","res","response","debug","onuploaderror","bound_uploaded","onprogress","bound_updateProgressBar","loaded","total","load","filesTotal","$progressBar","lengthComputable","bound_repaintUploadedBox","onuploaded","onuploadComplete","bound_attachFileTag","bound_cancelUpload","validateSelectedFiles","setUploadedFiles","_files","removeFile","removeFileAll","selectFile","uploader_instance","uploader","uploadProgress","inputFile","inputFileForm","upoadedBox","byte","COMBOBOX","ax5combobox","removeIcon","activecomboboxOptionGroup","activecomboboxQueueIndex","alignComboboxDisplay","displayTableHeightAdjust","displayTableHeight","$displayTable","alignComboboxOptionGroup","setOptionSelect","hasSelected","printLabel","$displayLabelInput","before","focusLabel","clearLabel","blurLabel","onSearch","syncComboboxOptions","regExp","@gindex","@index","setValueType","addOptions","addedOption","noStateChange","bindComboboxTarget","debouncedFocusWord","comboboxEvent","disableCtrlKeys","comboboxConfig","_boundID","_values","setText","_text","getSelectedOption","combobox","combobox_instance","optionGroup","comboboxDisplay","formSelect","formSelectOptions","nodeTypeProcessor","1","editable","textNode","3","ax5layout","splitter","autoResize","alignLayoutAll","parentQueIdx","alignLayout","getDockPanelOuterSize","__width","__height","getPixel","parentSize","beforeSetCSS","panelIndex","splitPanel","asteriskLength","setCSS","$splitter","bottom","targetDimension","dockPanel","center","minHeight","withoutAsteriskSize","windowResize","prevPosition","offsetEnd","offsetStart","layoutProcessor","dock-panel","split-panel","orientation","childResize","childQueIdxs","layout","onResize","resizeSplitter","splitterOffset","splitterBox","maxWidth","maxHeight","prevPanel","nextPanel","prePanelMinHeight","nextPanelMinHeight","prePanelMinWidth","nextPanelMinWidth","resizerType","setPanelSize","tab-panel","tabControl","activePanelIndex","tabPanel","onOpenTab","activePanel","getTabLabesTmpl","bindLayoutTarget","applyLayout","panelInfo","dock","ELIndex","hasActivePanel","hooksResizeLayout","childQueIdx","UIConfig","resizeLayoutPanel","resizeOption","resetLayoutPanel","tabOpen","layout_instance","ax5binder","model","view_target","change_trigger","click_trigger","update_trigger","get_type","get_mix_path","dataPath","item_path","get_real_path","setModel","_binding","obj_type","this_type","_this","set_els_value","__ADDED__","fragdom","bind_event_tmpl","change","repeat_path","remove_item","__DELETED__","print_tmpl","childAdd","child_path","child_item","childRemove","child_index","childUpdate","childSet","onUpdate","isupdate","dom","repeat_idx","hasItem","new_value","origin_value","value_type","setAllow","jquery","tagname","tk","ix","callChange","vi","option_matched","AXSelect","bindSelectSetValue","sync_model","isInit","isPlainObject","@i","item_index","mix_path","validate","errors","is_validate","is_error","AUTOCOMPLETE","ax5autocomplete","activeautocompleteOptionGroup","activeautocompleteQueueIndex","alignAutocompleteDisplay","alignAutocompleteOptionGroup","nindex","collect_options","removeSelectedIndex","newSelectedArray","pushOk","appendOk","bindAutocompleteTarget","autocompleteEvent","removeIndex","inputValue","autocompleteConfig","autocomplete","autocomplete_instance","autocompleteDisplay"],"mappings":"AAAA,YAEA,IAAIA,SAA4B,kBAAXC,SAAoD,gBAApBA,QAAOC,SAAwB,SAAUC,GAAO,aAAcA,IAAS,SAAUA,GAAO,MAAOA,IAAyB,kBAAXF,SAAyBE,EAAIC,cAAgBH,QAAUE,IAAQF,OAAOI,UAAY,eAAkBF,KCFtQ,WAIA,GAeAG,GAAAC,EAfAC,EAAAC,KAAAC,EAAAD,KACAE,EAAAD,EAAAA,EAAAE,SAAA,KACAC,GADAH,EAAAA,EAAAE,SAAAE,gBAAA,KACA,sEACAC,EAAA,QACAC,EAAA,mBACAC,EAAA,WACAC,EAAA,KACAC,EAAA,eACAC,EAAA,OACAC,EAAA,GAAAC,QAAA,gCACAC,EAAA,KACAC,EAAA,IACAC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B,GACA,MAAA,kTAUA+4C,EAAA,SAAA/4C,GACA,MAAA,g4BAoBAovC,EAAA,SAAApvC,GACA,MAAA,6GAKAqvC,EAAA,SAAArvC,GACA,MAAA,qCAEAA,EAAA6d,YAFA,yBAEA7d,EAAA8d,WAFA,gCAQApd,EAAA,SAAAV,GACA,MAAA,giBAaAA,EAAA6d,YAbA,UAaA7d,EAAA+d,eAbA,mCAaA/d,EAAA+d,eAbA,yKAeA/d,EAAA8d,WAfA,ycAiCAphC,EAAA,SAAAsjB,GACA,MAAA,+QAGA43C,GAAAj6C,MACAo7C,oBAAAA,EACA3J,WAAAA,EACAC,kBAAAA,EACAH,YAAAA,EACAxuC,QAAAA,EACAhkB,MAAAA,EAEAyR,IAAA,SAAA8R,EAAA1C,EAAAyC,GACA,MAAAxmB,KAAA0d,SAAAuE,OAAAm8C,EAAAj6C,KAAAsC,GAAAphB,KAAAtG,KAAAynB,GAAAzC","file":"ax5ui.all.min.js","sourcesContent":["'use strict';\n\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; };\n\n(function () {\n 'use strict';\n\n // root of function\n\n var root = this,\n win = this;\n var doc = win ? win.document : null,\n docElem = win ? win.document.documentElement : null;\n var reIsJson = /^([\"'](\\\\.|[^\"\\\\\\n\\r])*?[\"']|[,:{}\\[\\]0-9.\\-+Eaeflnr-u \\n\\r\\t])+?$/,\n reMs = /^-ms-/,\n reSnakeCase = /[\\-_]([\\da-z])/gi,\n reCamelCase = /([A-Z])/g,\n reDot = /\\./,\n reInt = /[-|+]?[\\D]/gi,\n reNotNum = /\\D/gi,\n reMoneySplit = new RegExp('([0-9])([0-9][0-9][0-9][,.])'),\n reAmp = /&/g,\n reEq = /=/,\n reClassNameSplit = /[ ]+/g,\n\n\n /** @namespace {Object} ax5 */\n ax5 = {},\n info,\n U,\n dom;\n\n /**\n * guid\n * @member {Number} ax5.guid\n */\n ax5.guid = 1;\n /**\n * ax5.guid를 구하고 증가시킵니다.\n * @method ax5.getGuid\n * @returns {Number} guid\n */\n ax5.getGuid = function () {\n return ax5.guid++;\n };\n\n /**\n * 상수모음\n * @namespace ax5.info\n */\n ax5.info = info = function () {\n /**\n * ax5 version\n * @member {String} ax5.info.version\n */\n var version = \"1.3.66\";\n\n /**\n * ax5 library path\n * @member {String} ax5.info.baseUrl\n */\n var baseUrl = \"\";\n\n /**\n * ax5 에러 출력메세지 사용자 재 정의\n * @member {Object} ax5.info.onerror\n * @examples\n * ```\n * ax5.info.onerror = function(){\n * console.log(arguments);\n * }\n * ```\n */\n var onerror = function onerror() {\n console.error(U.toArray(arguments).join(\":\"));\n };\n\n /**\n * event keyCodes\n * @member {Object} ax5.info.eventKeys\n * @example\n * ```\n * {\n * \tBACKSPACE: 8, TAB: 9,\n * \tRETURN: 13, ESC: 27, LEFT: 37, UP: 38, RIGHT: 39, DOWN: 40, DELETE: 46,\n * \tHOME: 36, END: 35, PAGEUP: 33, PAGEDOWN: 34, INSERT: 45, SPACE: 32\n * }\n * ```\n */\n var eventKeys = {\n BACKSPACE: 8, TAB: 9,\n RETURN: 13, ESC: 27, LEFT: 37, UP: 38, RIGHT: 39, DOWN: 40, DELETE: 46,\n HOME: 36, END: 35, PAGEUP: 33, PAGEDOWN: 34, INSERT: 45, SPACE: 32\n };\n\n /**\n * week names\n * @member {Object[]} weekNames\n * @member {string} weekNames[].label\n *\n * @example\n * ```\n * [\n * {label: \"SUN\"},{label: \"MON\"},{label: \"TUE\"},{label: \"WED\"},{label: \"THU\"},{label: \"FRI\"},{label: \"SAT\"}\n * ]\n * console.log( weekNames[0] );\n * console.log( ax5.info.weekNames[(new Date()).getDay()].label )\n * ```\n */\n var weekNames = [{ label: \"SUN\" }, { label: \"MON\" }, { label: \"TUE\" }, { label: \"WED\" }, { label: \"THU\" }, { label: \"FRI\" }, { label: \"SAT\" }];\n\n /**\n * 사용자 브라우저 식별용 오브젝트\n * @member {Object} ax5.info.browser\n * @example\n * ```\n * console.log( ax5.info.browser );\n * //Object {name: \"chrome\", version: \"39.0.2171.71\", mobile: false}\n * ```\n */\n var browser = function (ua, mobile, browserName, match, browser, browserVersion) {\n if (!win || !win.navigator) return {};\n\n ua = navigator.userAgent.toLowerCase(), mobile = ua.search(/mobile/g) != -1, browserName, match, browser, browserVersion;\n\n if (ua.search(/iphone/g) != -1) {\n return { name: \"iphone\", version: 0, mobile: true };\n } else if (ua.search(/ipad/g) != -1) {\n return { name: \"ipad\", version: 0, mobile: true };\n } else if (ua.search(/android/g) != -1) {\n match = /(android)[ \\/]([\\w.]+)/.exec(ua) || [];\n browserVersion = match[2] || \"0\";\n return { name: \"android\", version: browserVersion, mobile: mobile };\n } else {\n browserName = \"\";\n match = /(opr)[ \\/]([\\w.]+)/.exec(ua) || /(chrome)[ \\/]([\\w.]+)/.exec(ua) || /(webkit)[ \\/]([\\w.]+)/.exec(ua) || /(msie) ([\\w.]+)/.exec(ua) || ua.indexOf(\"compatible\") < 0 && /(mozilla)(?:.*? rv:([\\w.]+)|)/.exec(ua) || [];\n browser = match[1] || \"\";\n browserVersion = match[2] || \"0\";\n\n if (browser == \"msie\") browser = \"ie\";\n return {\n name: browser,\n version: browserVersion,\n mobile: mobile\n };\n }\n ua = null, mobile = null, browserName = null, match = null, browser = null, browserVersion = null;\n }();\n\n /**\n * 브라우저 여부\n * @member {Boolean} ax5.info.isBrowser\n */\n var isBrowser = !!(typeof window !== 'undefined' && typeof navigator !== 'undefined' && win.document);\n\n /**\n * 브라우저에 따른 마우스 휠 이벤트이름\n * @member {Object} ax5.info.wheelEnm\n */\n var wheelEnm = win && /Firefox/i.test(navigator.userAgent) ? \"DOMMouseScroll\" : \"mousewheel\";\n\n /**\n * 첫번째 자리수 동사 - (필요한것이 없을때 : 4, 실행오류 : 5)\n * 두번째 자리수 목적어 - 문자열 0, 숫자 1, 배열 2, 오브젝트 3, 함수 4, DOM 5, 파일 6, 기타 7\n * 세번째 자리수 옵션\n * @member {Object} ax5.info.errorMsg\n */\n var errorMsg = {};\n\n /**\n * 현재 페이지의 Url 정보를 리턴합니다.\n * @method ax5.info.urlUtil\n * @returns {Object}\n * @example\n * ```\n * console.log( ax5.util.toJson( ax5.info.urlUtil() ) );\n * {\n *\t\"baseUrl\": \"http://ax5:2018\",\n *\t\"href\": \"http://ax5:2018/samples/index.html?a=1&b=1#abc\",\n *\t\"param\": \"a=1&b=1\",\n *\t\"referrer\": \"\",\n *\t\"pathname\": \"/samples/index.html\",\n *\t\"hostname\": \"ax5\",\n *\t\"port\": \"2018\",\n *\t\"url\": \"http://ax5:2018/samples/index.html\",\n *\t\"hashdata\": \"abc\"\n * }\n * ```\n */\n function urlUtil(url, urls) {\n url = {\n href: win.location.href,\n param: win.location.search,\n referrer: doc.referrer,\n pathname: win.location.pathname,\n hostname: win.location.hostname,\n port: win.location.port\n }, urls = url.href.split(/[\\?#]/);\n url.param = url.param.replace(\"?\", \"\");\n url.url = urls[0];\n if (url.href.search(\"#\") > -1) {\n url.hashdata = U.last(urls);\n }\n urls = null;\n url.baseUrl = U.left(url.href, \"?\").replace(url.pathname, \"\");\n return url;\n }\n\n /**\n * ax5-error-msg.js 에 정의된 ax5 error를 반환합니다.\n * @method ax5.info.getError\n * @returns {Object}\n * @example\n * ```\n * console.log( ax5.info.getError(\"single-uploader\", \"460\", \"upload\") );\n *\n * if(!this.selectedFile){\n * if (cfg.onEvent) {\n * \tvar that = {\n * \t\taction: \"error\",\n * \t\terror: ax5.info.getError(\"single-uploader\", \"460\", \"upload\")\n * \t};\n * \tcfg.onEvent.call(that, that);\n * }\n * return this;\n * }\n * ```\n */\n function getError(className, errorCode, methodName) {\n if (info.errorMsg && info.errorMsg[className]) {\n return {\n className: className,\n errorCode: errorCode,\n methodName: methodName,\n msg: info.errorMsg[className][errorCode]\n };\n } else {\n return { className: className, errorCode: errorCode, methodName: methodName };\n }\n }\n\n /**\n * 브라우져의 터치 기능 유무를 확인합니다.\n * @method ax5.info.supportTouch\n * @returns {boolean}\n * @example\n * ```\n * var chkFlag = ax5.info.supportTouch;\n */\n var supportTouch = win ? 'ontouchstart' in win || navigator.maxTouchPoints > 0 || navigator.msMaxTouchPoints > 0 : false;\n\n var supportFileApi = win ? win.FileReader && win.File && win.FileList && win.Blob : false;\n\n return {\n errorMsg: errorMsg,\n version: version,\n baseUrl: baseUrl,\n onerror: onerror,\n eventKeys: eventKeys,\n weekNames: weekNames,\n browser: browser,\n isBrowser: isBrowser,\n supportTouch: supportTouch,\n supportFileApi: supportFileApi,\n wheelEnm: wheelEnm,\n urlUtil: urlUtil,\n getError: getError\n };\n }();\n\n /**\n * Refer to this by {@link ax5}.\n * @namespace ax5.util\n */\n ax5['util'] = U = function () {\n var _toString = Object.prototype.toString;\n\n /**\n * Object나 Array의 아이템으로 사용자 함수를 호출합니다.\n * @method ax5.util.each\n * @param {Object|Array} O\n * @param {Function} _fn\n * @example\n * ```js\n * var axf = ax5.util;\n * axf.each([0,1,2], function(){\n * \t// with this\n * });\n * axf.each({a:1, b:2}, function(){\n * \t// with this\n * });\n * ```\n */\n function each(O, _fn) {\n if (isNothing(O)) return [];\n var key,\n i = 0,\n l = O.length,\n isObj = l === undefined || typeof O === \"function\";\n if (isObj) {\n for (key in O) {\n if (typeof O[key] != \"undefined\") if (_fn.call(O[key], key, O[key]) === false) break;\n }\n } else {\n for (; i < l;) {\n if (typeof O[i] != \"undefined\") if (_fn.call(O[i], i, O[i++]) === false) break;\n }\n }\n return O;\n }\n\n // In addition to using the http://underscorejs.org : map, reduce, reduceRight, find\n /**\n * 원본 아이템들을 이용하여 사용자 함수의 리턴값으로 이루어진 새로운 배열을 만듭니다.\n * @method ax5.util.map\n * @param {Object|Array} O\n * @param {Function} _fn\n * @returns {Array}\n * @example\n * ```js\n * var myArray = [0,1,2,3,4];\n * var myObject = {a:1, b:\"2\", c:{axj:\"what\", arrs:[0,2,\"3\"]},\n * fn: function(abcdd){\n * return abcdd;\n * }\n * };\n *\n * var _arr = ax5.util.map( myArray, function(index, I){\n * return index+1;\n * });\n * console.log(_arr);\n * // [1, 2, 3, 4, 5]\n *\n * var _arr = ax5.util.map( myObject, function(k, v){\n * return v * 2;\n * });\n * console.log(_arr);\n * // [2, 4, NaN, NaN]\n * ```\n */\n function map(O, _fn) {\n if (isNothing(O)) return [];\n var key,\n i = 0,\n l = O.length,\n results = [],\n fnResult;\n if (isObject(O)) {\n for (key in O) {\n if (typeof O[key] != \"undefined\") {\n fnResult = undefined;\n if ((fnResult = _fn.call(O[key], key, O[key])) === false) break;else results.push(fnResult);\n }\n }\n } else {\n for (; i < l;) {\n if (typeof O[i] != \"undefined\") {\n fnResult = undefined;\n if ((fnResult = _fn.call(O[i], i, O[i++])) === false) break;else results.push(fnResult);\n }\n }\n }\n return results;\n }\n\n /**\n * 원본 아이템들을 이용하여 사용자 함수의 리턴값이 참인 아이템의 위치나 키값을 반환합니다.\n * @method ax5.util.search\n * @param {Object|Array} O\n * @param {Function|String|Number} _fn - 함수 또는 값\n * @returns {Number|String}\n * @example\n * ```js\n * var myArray = [0,1,2,3,4,5,6];\n * var myObject = {a:\"123\",\"b\":\"123\",c:123};\n *\n * ax5.util.search(myArray, function(){\n * return this > 3;\n * });\n * // 4\n * ax5.util.search(myObject, function(k, v){\n * return v === 123;\n * });\n * // \"c\"\n * ax5.util.search([1,2,3,4], 3);\n * // 2\n * ax5.util.search([1,2], 4);\n * // -1\n * ax5.util.search([\"name\",\"value\"], \"value\");\n * // 1\n * ax5.util.search([\"name\",\"value\"], \"values\");\n * // -1\n * ax5.util.search({k1:\"name\",k2:\"value\"}, \"value2\");\n * // -1\n * ax5.util.search({k1:\"name\",k2:\"value\"}, \"value\");\n * // \"k2\"\n * ```\n */\n function search(O, _fn) {\n if (isNothing(O)) return -1;\n var key,\n i = 0,\n l = O.length;\n if (isObject(O)) {\n for (key in O) {\n if (typeof O[key] != \"undefined\" && isFunction(_fn) && _fn.call(O[key], key, O[key])) {\n return key;\n break;\n } else if (O[key] == _fn) {\n return key;\n break;\n }\n }\n } else {\n for (; i < l;) {\n if (typeof O[i] != \"undefined\" && isFunction(_fn) && _fn.call(O[i], i, O[i])) {\n return i;\n break;\n } else if (O[i] == _fn) {\n return i;\n break;\n }\n i++;\n }\n }\n return -1;\n }\n\n /**\n * @method ax5.util.sum\n * @param {Array|Object} O\n * @param {Number} [defaultValue]\n * @param {Function} _fn\n * @returns {Number}\n * @example\n * ```js\n * var arr = [\n * {name: \"122\", value: 9},\n * {name: \"122\", value: 10},\n * {name: \"123\", value: 11}\n * ];\n *\n * var rs = ax5.util.sum(arr, function () {\n * if(this.name == \"122\") {\n * return this.value;\n * }\n * });\n * console.log(rs); // 19\n *\n * console.log(ax5.util.sum(arr, 10, function () {\n * return this.value;\n * }));\n * // 40\n * ```\n */\n function sum(O, defaultValue, _fn) {\n var i, l, tokenValue;\n if (isFunction(defaultValue) && typeof _fn === \"undefined\") {\n _fn = defaultValue;\n defaultValue = 0;\n }\n if (typeof defaultValue === \"undefined\") defaultValue = 0;\n\n if (isArray(O)) {\n i = 0;\n l = O.length;\n for (; i < l; i++) {\n if (typeof O[i] !== \"undefined\") {\n if ((tokenValue = _fn.call(O[i], O[i])) === false) break;else if (typeof tokenValue !== \"undefined\") defaultValue += tokenValue;\n }\n }\n return defaultValue;\n } else if (isObject(O)) {\n for (i in O) {\n if (typeof O[i] != \"undefined\") {\n if ((tokenValue = _fn.call(O[i], O[i])) === false) break;else if (typeof tokenValue !== \"undefined\") defaultValue += tokenValue;\n }\n }\n return defaultValue;\n } else {\n console.error(\"argument error : ax5.util.sum - use Array or Object\");\n return defaultValue;\n }\n }\n\n /**\n * @method ax5.util.avg\n * @param {Array|Object} O\n * @param {Number} [defaultValue]\n * @param {Function} _fn\n * @returns {Number}\n * @example\n * ```js\n * var arr = [\n * {name: \"122\", value: 9},\n * {name: \"122\", value: 10},\n * {name: \"123\", value: 11}\n * ];\n *\n * var rs = ax5.util.avg(arr, function () {\n * return this.value;\n * });\n *\n * console.log(rs); // 10\n * ```\n */\n function avg(O, defaultValue, _fn) {\n var i, l, tokenValue;\n if (isFunction(defaultValue) && typeof _fn === \"undefined\") {\n _fn = defaultValue;\n defaultValue = 0;\n }\n if (typeof defaultValue === \"undefined\") defaultValue = 0;\n\n if (isArray(O)) {\n i = 0;\n l = O.length;\n for (; i < l; i++) {\n if (typeof O[i] !== \"undefined\") {\n if ((tokenValue = _fn.call(O[i], O[i])) === false) break;else if (typeof tokenValue !== \"undefined\") defaultValue += tokenValue;\n }\n }\n return defaultValue / l;\n } else if (isObject(O)) {\n for (i in O) {\n if (typeof O[i] != \"undefined\") {\n if ((tokenValue = _fn.call(O[i], O[i])) === false) break;else if (typeof tokenValue !== \"undefined\") defaultValue += tokenValue;\n }\n }\n return defaultValue / l;\n } else {\n console.error(\"argument error : ax5.util.sum - use Array or Object\");\n return defaultValue;\n }\n }\n\n /**\n * 배열의 왼쪽에서 오른쪽으로 연산을 진행하는데 수행한 결과가 왼쪽 값으로 반영되어 최종 왼쪽 값을 반환합니다.\n * @method ax5.util.reduce\n * @param {Array|Object} O\n * @param {Function} _fn\n * @returns {Alltypes}\n * @example\n * ```js\n * var aarray = [5,4,3,2,1];\n * result = ax5.util.reduce( aarray, function(p, n){\n * return p * n;\n * });\n * console.log(result, aarray);\n * // 120 [5, 4, 3, 2, 1]\n *\n * ax5.util.reduce({a:1, b:2}, function(p, n){\n * return parseInt(p|0) + parseInt(n);\n * });\n * // 3\n * ```\n */\n function reduce(O, _fn) {\n var i, l, tokenItem;\n if (isArray(O)) {\n i = 0, l = O.length, tokenItem = O[i];\n for (; i < l - 1;) {\n if (typeof O[i] != \"undefined\") {\n if ((tokenItem = _fn.call(root, tokenItem, O[++i])) === false) break;\n }\n }\n return tokenItem;\n } else if (isObject(O)) {\n for (i in O) {\n if (typeof O[i] != \"undefined\") {\n if ((tokenItem = _fn.call(root, tokenItem, O[i])) === false) break;\n }\n }\n return tokenItem;\n } else {\n console.error(\"argument error : ax5.util.reduce - use Array or Object\");\n return null;\n }\n }\n\n /**\n * 배열의 오른쪽에서 왼쪽으로 연산을 진행하는데 수행한 결과가 오른쪽 값으로 반영되어 최종 오른쪽 값을 반환합니다.\n * @method ax5.util.reduceRight\n * @param {Array} O\n * @param {Function} _fn\n * @returns {Alltypes}\n * @example\n * ```js\n * var aarray = [5,4,3,2,1];\n * result = ax5.util.reduceRight( aarray, function(p, n){\n * console.log( n );\n * return p * n;\n * });\n * console.log(result, aarray);\n * 120 [5, 4, 3, 2, 1]\n * ```\n */\n function reduceRight(O, _fn) {\n var i = O.length - 1,\n tokenItem = O[i];\n for (; i > 0;) {\n if (typeof O[i] != \"undefined\") {\n if ((tokenItem = _fn.call(root, tokenItem, O[--i])) === false) break;\n }\n }\n return tokenItem;\n }\n\n /**\n * 배열또는 오브젝트의 각 아이템을 인자로 하는 사용자 함수의 결과가 참인 아이템들의 배열을 반환합니다.\n * @method ax5.util.filter\n * @param {Object|Array} O\n * @param {Function} _fn\n * @returns {Array}\n * @example\n * ```js\n * var aarray = [5,4,3,2,1];\n * result = ax5.util.filter( aarray, function(){\n * return this % 2;\n * });\n * console.log(result);\n * // [5, 3, 1]\n *\n * var filObject = {a:1, s:\"string\", oa:{pickup:true, name:\"AXISJ\"}, os:{pickup:true, name:\"AX5\"}};\n * result = ax5.util.filter( filObject, function(){\n * \treturn this.pickup;\n * });\n * console.log( ax5.util.toJson(result) );\n * // [{\"pickup\": , \"name\": \"AXISJ\"}, {\"pickup\": , \"name\": \"AX5\"}]\n * ```\n */\n function filter(O, _fn) {\n if (isNothing(O)) return [];\n var k,\n i = 0,\n l = O.length,\n results = [],\n fnResult;\n if (isObject(O)) {\n for (k in O) {\n if (typeof O[k] != \"undefined\") {\n if (fnResult = _fn.call(O[k], k, O[k])) results.push(O[k]);\n }\n }\n } else {\n for (; i < l;) {\n if (typeof O[i] != \"undefined\") {\n if (fnResult = _fn.call(O[i], i, O[i])) results.push(O[i]);\n i++;\n }\n }\n }\n return results;\n }\n\n /**\n * Object를 JSONString 으로 반환합니다.\n * @method ax5.util.toJson\n * @param {Object|Array} O\n * @returns {String} JSON\n * @example\n * ```js\n * var ax = ax5.util;\n * var myObject = {\n * a:1, b:\"2\", c:{axj:\"what\", arrs:[0,2,\"3\"]},\n * fn: function(abcdd){\n * return abcdd;\n * }\n * };\n * console.log( ax.toJson(myObject) );\n * ```\n */\n function toJson(O) {\n var jsonString = \"\";\n if (ax5.util.isArray(O)) {\n var i = 0,\n l = O.length;\n jsonString += \"[\";\n for (; i < l; i++) {\n if (i > 0) jsonString += \",\";\n jsonString += toJson(O[i]);\n }\n jsonString += \"]\";\n } else if (ax5.util.isObject(O)) {\n jsonString += \"{\";\n var jsonObjectBody = [];\n each(O, function (key, value) {\n jsonObjectBody.push('\"' + key + '\": ' + toJson(value));\n });\n jsonString += jsonObjectBody.join(\", \");\n jsonString += \"}\";\n } else if (ax5.util.isString(O)) {\n jsonString = '\"' + O + '\"';\n } else if (ax5.util.isNumber(O)) {\n jsonString = O;\n } else if (ax5.util.isUndefined(O)) {\n jsonString = \"undefined\";\n } else if (ax5.util.isFunction(O)) {\n jsonString = '\"{Function}\"';\n } else {\n jsonString = O;\n }\n return jsonString;\n }\n\n /**\n * 관용의 JSON Parser\n * @method ax5.util.parseJson\n * @param {String} JSONString\n * @param {Boolean} [force] - 강제 적용 여부 (json 문자열 검사를 무시하고 오브젝트 변환을 시도합니다.)\n * @returns {Object}\n * @example\n * ```\n * console.log(ax5.util.parseJson('{\"a\":1}'));\n * // Object {a: 1}\n * console.log(ax5.util.parseJson(\"{'a':1, 'b':'b'}\"));\n * // Object {a: 1, b: \"b\"}\n * console.log(ax5.util.parseJson(\"{'a':1, 'b':function(){return 1;}}\", true));\n * // Object {a: 1, b: function}\n * console.log(ax5.util.parseJson(\"{a:1}\"));\n * // Object {a: 1}\n * console.log(ax5.util.parseJson(\"[1,2,3]\"));\n * // [1, 2, 3]\n * console.log(ax5.util.parseJson(\"['1','2','3']\"));\n * // [\"1\", \"2\", \"3\"]\n * console.log(ax5.util.parseJson(\"[{'a':'99'},'2','3']\"));\n * // [Object, \"2\", \"3\"]\n * ```\n */\n function parseJson(str, force) {\n if (force || reIsJson.test(str)) {\n try {\n return new Function('', 'return ' + str)();\n } catch (e) {\n return { error: 500, msg: 'syntax error' };\n }\n } else {\n return { error: 500, msg: 'syntax error' };\n }\n }\n\n /**\n * 인자의 타입을 반환합니다.\n * @method ax5.util.getType\n * @param {Object|Array|String|Number|Element|Etc} O\n * @returns {String} window|element|object|array|function|string|number|undefined|nodelist\n * @example\n * ```js\n * var axf = ax5.util;\n * var a = 11;\n * var b = \"11\";\n * console.log( axf.getType(a) );\n * console.log( axf.getType(b) );\n * ```\n */\n function getType(O) {\n var typeName;\n if (O != null && O == O.window) {\n typeName = \"window\";\n } else if (!!(O && O.nodeType == 1)) {\n typeName = \"element\";\n } else if (!!(O && O.nodeType == 11)) {\n typeName = \"fragment\";\n } else if (O === null) {\n typeName = \"null\";\n } else if (typeof O === \"undefined\") {\n typeName = \"undefined\";\n } else if (_toString.call(O) == \"[object Object]\") {\n typeName = \"object\";\n } else if (_toString.call(O) == \"[object Array]\") {\n typeName = \"array\";\n } else if (_toString.call(O) == \"[object String]\") {\n typeName = \"string\";\n } else if (_toString.call(O) == \"[object Number]\") {\n typeName = \"number\";\n } else if (_toString.call(O) == \"[object NodeList]\") {\n typeName = \"nodelist\";\n } else if (typeof O === \"function\") {\n typeName = \"function\";\n }\n return typeName;\n }\n\n /**\n * 오브젝트가 window 인지 판단합니다.\n * @method ax5.util.isWindow\n * @param {Object} O\n * @returns {Boolean}\n */\n function isWindow(O) {\n return O != null && O == O.window;\n }\n\n /**\n * 오브젝트가 HTML 엘리먼트여부인지 판단합니다.\n * @method ax5.util.isElement\n * @param {Object} O\n * @returns {Boolean}\n */\n function isElement(O) {\n return !!(O && (O.nodeType == 1 || O.nodeType == 11));\n }\n\n /**\n * 오브젝트가 Object인지 판단합니다.\n * @method ax5.util.isObject\n * @param {Object} O\n * @returns {Boolean}\n */\n function isObject(O) {\n return _toString.call(O) == \"[object Object]\";\n }\n\n /**\n * 오브젝트가 Array인지 판단합니다.\n * @method ax5.util.isArray\n * @param {Object} O\n * @returns {Boolean}\n */\n function isArray(O) {\n return _toString.call(O) == \"[object Array]\";\n }\n\n /**\n * 오브젝트가 Function인지 판단합니다.\n * @method ax5.util.isFunction\n * @param {Object} O\n * @returns {Boolean}\n */\n function isFunction(O) {\n return typeof O === \"function\";\n }\n\n /**\n * 오브젝트가 String인지 판단합니다.\n * @method ax5.util.isString\n * @param {Object} O\n * @returns {Boolean}\n */\n function isString(O) {\n return _toString.call(O) == \"[object String]\";\n }\n\n /**\n * 오브젝트가 Number인지 판단합니다.\n * @method ax5.util.isNumber\n * @param {Object} O\n * @returns {Boolean}\n */\n function isNumber(O) {\n return _toString.call(O) == \"[object Number]\";\n }\n\n /**\n * 오브젝트가 NodeList인지 판단합니다.\n * @method ax5.util.isNodelist\n * @param {Object} O\n * @returns {Boolean}\n */\n function isNodelist(O) {\n return !!(_toString.call(O) == \"[object NodeList]\" || typeof O !== \"undefined\" && O && O[0] && O[0].nodeType == 1);\n }\n\n /**\n * 오브젝트가 undefined인지 판단합니다.\n * @method ax5.util.isUndefined\n * @param {Object} O\n * @returns {Boolean}\n */\n function isUndefined(O) {\n return typeof O === \"undefined\";\n }\n\n /**\n * 오브젝트가 undefined이거나 null이거나 빈값인지 판단합니다.\n * @method ax5.util.isNothing\n * @param {Object} O\n * @returns {Boolean}\n */\n function isNothing(O) {\n return typeof O === \"undefined\" || O === null || O === \"\";\n }\n\n /**\n * 오브젝트가 날자값인지 판단합니다.\n * @method ax5.util.isDate\n * @param {Date} O\n * @returns {Boolean}\n * @example\n * ```js\n * ax5.util.isDate('2016-09-30');\n * // false\n * ax5.util.isDate( new Date('2016-09-30') );\n * // true\n * ```\n */\n function isDate(O) {\n return O instanceof Date && !isNaN(O.valueOf());\n }\n\n function isDateFormat(O) {\n var result = false;\n if (!O) {} else if (O instanceof Date && !isNaN(O.valueOf())) {\n result = true;\n } else {\n if (O.length > 7) {\n if (date(O) instanceof Date) {\n return true;\n }\n }\n O = O.replace(/\\D/g, '');\n if (O.length > 7) {\n var mm = O.substr(4, 2),\n dd = O.substr(6, 2);\n O = date(O);\n if (O.getMonth() == mm - 1 && O.getDate() == dd) {\n result = true;\n }\n }\n }\n return result;\n }\n\n /**\n * 오브젝트의 첫번째 아이템을 반환합니다.\n * @method ax5.util.first\n * @param {Object|Array} O\n * @returns {Object}\n * @example\n * ```js\n * ax5.util.first({a:1, b:2});\n * // Object {a: 1}\n * ax5.util.first([1,2,3,4]);\n * // 1\n * ```\n */\n function first(O) {\n if (isObject(O)) {\n var keys = Object.keys(O);\n var item = {};\n item[keys[0]] = O[keys[0]];\n return item;\n } else if (isArray(O)) {\n return O[0];\n } else {\n console.error(\"ax5.util.object.first\", \"argument type error\");\n return undefined;\n }\n }\n\n /**\n * 오브젝트의 마지막 아이템을 반환합니다.\n * @method ax5.util.last\n * @param {Object|Array} O\n * @returns {Object}\n * @example\n * ```js\n * ax5.util.last({a:1, b:2});\n * // Object {b: 2}\n * ax5.util.last([1,2,3,4]);\n * // 4\n * ```\n */\n function last(O) {\n if (isObject(O)) {\n var keys = Object.keys(O);\n var item = {};\n item[keys[keys.length - 1]] = O[keys[keys.length - 1]];\n return item;\n } else if (isArray(O)) {\n return O[O.length - 1];\n } else {\n console.error(\"ax5.util.object.last\", \"argument type error\");\n return undefined;\n }\n }\n\n /**\n * 쿠키를 설정합니다.\n * @method ax5.util.setCookie\n * @param {String} cname - 쿠키이름\n * @param {String} cvalue - 쿠키값\n * @param {Number} [exdays] - 쿠키 유지일수\n * @param {Object} [opts] - path, domain 설정 옵션\n * @example\n * ```js\n * ax5.util.setCookie(\"jslib\", \"AX5\");\n * ax5.util.setCookie(\"jslib\", \"AX5\", 3);\n * ax5.util.setCookie(\"jslib\", \"AX5\", 3, {path:\"/\", domain:\".axisj.com\"});\n * ```\n */\n function setCookie(cn, cv, exdays, opts) {\n var expire;\n if (typeof exdays === \"number\") {\n expire = new Date();\n expire.setDate(expire.getDate() + exdays);\n }\n opts = opts || {};\n return doc.cookie = [escape(cn), '=', escape(cv), expire ? \"; expires=\" + expire.toUTCString() : \"\", // use expires attribute, max-age is not supported by IE\n opts.path ? \"; path=\" + opts.path : \"\", opts.domain ? \"; domain=\" + opts.domain : \"\", opts.secure ? \"; secure\" : \"\"].join(\"\");\n }\n\n /**\n * 쿠키를 가져옵니다.\n * @method ax5.util.getCookie\n * @param {String} cname\n * @returns {String} cookie value\n * @example\n * ```js\n * ax5.util.getCookie(\"jslib\");\n * ```\n */\n function getCookie(cname) {\n var name = cname + \"=\";\n var ca = doc.cookie.split(';'),\n i = 0,\n l = ca.length;\n for (; i < l; i++) {\n var c = ca[i];\n while (c.charAt(0) == ' ') {\n c = c.substring(1);\n }if (c.indexOf(name) != -1) return unescape(c.substring(name.length, c.length));\n }\n return \"\";\n }\n\n /**\n * jsonString 으로 alert 합니다.\n * @method ax5.util.alert\n * @param {Object|Array|String|Number} O\n * @returns {Object|Array|String|Number} O\n * @example ```js\n * ax5.util.alert({a:1,b:2});\n * ax5.util.alert(\"정말?\");\n * ```\n */\n function alert(O) {\n win.alert(toJson(O));\n return O;\n }\n\n /**\n * 문자열의 특정 문자열까지 잘라주거나 원하는 포지션까지 잘라줍니다.\n * @method ax5.util.left\n * @param {String} str - 문자열\n * @param {String|Number} pos - 찾을 문자열 또는 포지션\n * @returns {String}\n * @example\n * ```js\n * ax5.util.left(\"abcd.efd\", 3);\n * // abc\n * ax5.util.left(\"abcd.efd\", \".\");\n * // abcd\n * ```\n */\n function left(str, pos) {\n if (typeof str === \"undefined\" || typeof pos === \"undefined\") return \"\";\n if (isString(pos)) {\n return str.indexOf(pos) > -1 ? str.substr(0, str.indexOf(pos)) : \"\";\n } else if (isNumber(pos)) {\n return str.substr(0, pos);\n } else {\n return \"\";\n }\n }\n\n /**\n * 문자열의 특정 문자열까지 잘라주거나 원하는 포지션까지 잘라줍니다.\n * @method ax5.util.right\n * @param {String} str - 문자열\n * @param {String|Number} pos - 찾을 문자열 또는 포지션\n * @returns {String}\n * @example\n * ```js\n * ax5.util.right(\"abcd.efd\", 3);\n * // efd\n * ax5.util.right(\"abcd.efd\", \".\");\n * // efd\n * ```\n */\n function right(str, pos) {\n if (typeof str === \"undefined\" || typeof pos === \"undefined\") return \"\";\n str = '' + str;\n if (isString(pos)) {\n return str.lastIndexOf(pos) > -1 ? str.substr(str.lastIndexOf(pos) + 1) : \"\";\n } else if (isNumber(pos)) {\n return str.substr(str.length - pos);\n } else {\n return \"\";\n }\n }\n\n /**\n * css형 문자열이나 특수문자가 포함된 문자열을 카멜케이스로 바꾸어 반환합니다.\n * @method ax5.util.camelCase\n * @param {String} str\n * @returns {String}\n * @example\n * ```js\n * ax5.util.camelCase(\"inner-width\");\n * ax5.util.camelCase(\"innerWidth\");\n * // innerWidth\n * ```\n */\n function camelCase(str) {\n return str.replace(reMs, \"ms-\").replace(reSnakeCase, function (all, letter) {\n return letter.toUpperCase();\n });\n }\n\n /**\n * css형 문자열이나 카멜케이스문자열을 스네이크 케이스 문자열로 바꾸어 반환합니다.\n * @method ax5.util.snakeCase\n * @param {String} str\n * @returns {String}\n * @example\n * ```js\n * ax5.util.snakeCase(\"innerWidth\");\n * ax5.util.snakeCase(\"inner-Width\");\n * ax5.util.snakeCase(\"innerWidth\");\n * // inner-width\n * ```\n */\n function snakeCase(str) {\n return camelCase(str).replace(reCamelCase, function (all, letter) {\n return \"-\" + letter.toLowerCase();\n });\n }\n\n /**\n * 문자열에서 -. 을 제외한 모든 문자열을 제거하고 숫자로 반환합니다. 옵션에 따라 원하는 형식의 숫자로 변환 할 수 도 있습니다.\n * @method ax5.util.number\n * @param {String|Number} str\n * @param {Object} cond - 옵션\n * @returns {String|Number}\n * @example\n * ```js\n * var cond = {\n * \tround: {Number|Boolean} - 반올림할 자릿수,\n * \tmoney: {Boolean} - 통화,\n * \tabs: {Boolean} - 절대값,\n * \tbyte: {Boolean} - 바이트\n * }\n *\n * console.log(ax5.util.number(123456789.678, {round:1}));\n * console.log(ax5.util.number(123456789.678, {round:1, money:true}));\n * console.log(ax5.util.number(123456789.678, {round:2, byte:true}));\n * console.log(ax5.util.number(-123456789.8888, {abs:true, round:2, money:true}));\n * console.log(ax5.util.number(\"A-1234~~56789.8~888PX\", {abs:true, round:2, money:true}));\n *\n * //123456789.7\n * //123,456,789.7\n * //117.7MB\n * //123,456,789.89\n * //123,456,789.89\n * ```\n */\n function number(str, cond) {\n var result,\n pair = ('' + str).split(reDot),\n isMinus = Number(pair[0]) < 0 || pair[0] == \"-0\",\n returnValue = 0.0;\n pair[0] = pair[0].replace(reInt, \"\");\n if (pair[1]) {\n pair[1] = pair[1].replace(reNotNum, \"\");\n returnValue = Number(pair[0] + \".\" + pair[1]) || 0;\n } else {\n returnValue = Number(pair[0]) || 0;\n }\n result = isMinus ? -returnValue : returnValue;\n\n each(cond, function (k, c) {\n if (k == \"round\") {\n if (isNumber(c)) {\n if (c < 0) {\n result = +(Math.round(result + \"e-\" + Math.abs(c)) + \"e+\" + Math.abs(c));\n } else {\n result = +(Math.round(result + \"e+\" + c) + \"e-\" + c);\n }\n } else {\n result = Math.round(result);\n }\n }\n if (k == \"floor\") {\n result = Math.floor(result);\n }\n if (k == \"ceil\") {\n result = Math.ceil(result);\n } else if (k == \"money\") {\n result = function (val) {\n var txtNumber = '' + val;\n if (isNaN(txtNumber) || txtNumber == \"\") {\n return \"\";\n } else {\n var arrNumber = txtNumber.split('.');\n arrNumber[0] += '.';\n do {\n arrNumber[0] = arrNumber[0].replace(reMoneySplit, '$1,$2');\n } while (reMoneySplit.test(arrNumber[0]));\n if (arrNumber.length > 1) {\n return arrNumber.join('');\n } else {\n return arrNumber[0].split('.')[0];\n }\n }\n }(result);\n } else if (k == \"abs\") {\n result = Math.abs(Number(result));\n } else if (k == \"byte\") {\n result = function (val) {\n val = Number(result);\n var nUnit = \"KB\";\n var myByte = val / 1024;\n if (myByte / 1024 > 1) {\n nUnit = \"MB\";\n myByte = myByte / 1024;\n }\n if (myByte / 1024 > 1) {\n nUnit = \"GB\";\n myByte = myByte / 1024;\n }\n return number(myByte, { round: 1 }) + nUnit;\n }(result);\n }\n });\n\n return result;\n }\n\n /**\n * 배열 비슷한 오브젝트를 배열로 변환해줍니다.\n * @method ax5.util.toArray\n * @param {Object|Elements|Arguments} O\n * @returns {Array}\n * @example\n * ```js\n * ax5.util.toArray(arguments);\n * //\n * ```\n */\n function toArray(O) {\n if (typeof O.length != \"undefined\") return Array.prototype.slice.call(O);\n return [];\n }\n\n /**\n * 첫번째 인자에 두번째 인자 아이템을 합쳐줍니다. concat과 같은 역할을 하지만. 인자가 Array타입이 아니어도 됩니다.\n * @method ax5.util.merge\n * @param {Array|ArrayLike} first\n * @param {Array|ArrayLike} second\n * @returns {Array} first\n * @example\n * ```\n *\n * ```\n */\n function merge(first, second) {\n var l = second.length,\n i = first.length,\n j = 0;\n\n if (typeof l === \"number\") {\n for (; j < l; j++) {\n first[i++] = second[j];\n }\n } else {\n while (second[j] !== undefined) {\n first[i++] = second[j++];\n }\n }\n\n first.length = i;\n\n return first;\n }\n\n /**\n * 오브젝트를 파라미터형식으로 또는 파라미터를 오브젝트 형식으로 변환합니다.\n * @method ax5.util.param\n * @param {Object|Array|String} O\n * @param {String} [cond] - param|object\n * @returns {Object|String}\n * @example\n * ```\n * ax5.util.param({a:1,b:'1232'}, \"param\");\n * ax5.util.param(\"a=1&b=1232\", \"param\");\n * // \"a=1&b=1232\"\n * ax5.util.param(\"a=1&b=1232\");\n * // {a: \"1\", b: \"1232\"}\n * ```\n */\n function param(O, cond) {\n var p;\n if (isString(O) && typeof cond !== \"undefined\" && cond == \"param\") {\n return O;\n } else if (isString(O) && typeof cond !== \"undefined\" && cond == \"object\" || isString(O) && typeof cond === \"undefined\") {\n p = {};\n each(O.split(reAmp), function () {\n var item = this.split(reEq);\n if (!p[item[0]]) p[item[0]] = item[1];else {\n if (isString(p[item[0]])) p[item[0]] = [p[item[0]]];\n p[item[0]].push(item[1]);\n }\n });\n return p;\n } else {\n p = [];\n each(O, function (k, v) {\n p.push(k + \"=\" + escape(v));\n });\n return p.join('&');\n }\n }\n\n function encode(s) {\n return encodeURIComponent(s);\n }\n\n function decode(s) {\n return decodeURIComponent(s);\n }\n\n function error() {\n ax5.info.onerror.apply(this, arguments);\n }\n\n function localDate(yy, mm, dd, hh, mi, ss) {\n var utcD, localD;\n localD = new Date();\n if (typeof hh === \"undefined\") hh = 23;\n if (typeof mi === \"undefined\") mi = 59;\n utcD = new Date(Date.UTC(yy, mm, dd || 1, hh, mi, ss || 0));\n\n if (mm == 0 && dd == 1 && utcD.getUTCHours() + utcD.getTimezoneOffset() / 60 < 0) {\n utcD.setUTCHours(0);\n } else {\n utcD.setUTCHours(utcD.getUTCHours() + utcD.getTimezoneOffset() / 60);\n }\n return utcD;\n }\n\n /**\n * 날짜 형식의 문자열이나 Date객체를 조건에 맞게 처리 한 후 원하는 return 값으로 반환합니다.\n * @method ax5.util.date\n * @param {String|Date} d\n * @param {Object} cond\n * @returns {Date|String}\n * @example\n * ```js\n * ax5.util.date('2013-01-01'); // Tue Jan 01 2013 23:59:00 GMT+0900 (KST)\n * ax5.util.date((new Date()), {add:{d:10}, return:'yyyy/MM/dd'}); // \"2015/07/01\"\n * ax5.util.date('1919-03-01', {add:{d:10}, return:'yyyy/MM/dd hh:mm:ss'}); // \"1919/03/11 23:59:00\"\n * ```\n */\n function date(d, cond) {\n var yy, mm, dd, hh, mi, aDateTime, aTimes, aTime, aDate, utcD, localD, va;\n var ISO_8601 = /^\\d{4}(-\\d\\d(-\\d\\d(T\\d\\d:\\d\\d(:\\d\\d)?(\\.\\d+)?(([+-]\\d\\d:\\d\\d)|Z)?)?)?)?$/i;\n var ISO_8601_FULL = /^\\d{4}-\\d\\d-\\d\\dT\\d\\d:\\d\\d:\\d\\d(\\.\\d+)?(([+-]\\d\\d:\\d\\d)|Z)?$/i;\n\n if (isString(d)) {\n if (d.length == 0) {\n d = new Date();\n } else if (d.length > 15) {\n if (ISO_8601_FULL.test(d) || ISO_8601.test(d)) {\n d = new Date(d);\n } else {\n aDateTime = d.split(/ /g), aTimes, aTime, aDate = aDateTime[0].split(/\\D/g), yy = aDate[0];\n mm = parseFloat(aDate[1]);\n dd = parseFloat(aDate[2]);\n aTime = aDateTime[1] || \"09:00\";\n aTimes = aTime.substring(0, 5).split(\":\");\n hh = parseFloat(aTimes[0]);\n mi = parseFloat(aTimes[1]);\n if (right(aTime, 2) === \"AM\" || right(aTime, 2) === \"PM\") hh += 12;\n d = localDate(yy, mm - 1, dd, hh, mi);\n }\n } else if (d.length == 14) {\n va = d.replace(/\\D/g, \"\");\n d = localDate(va.substr(0, 4), va.substr(4, 2) - 1, number(va.substr(6, 2)), number(va.substr(8, 2)), number(va.substr(10, 2)), number(va.substr(12, 2)));\n } else if (d.length > 7) {\n va = d.replace(/\\D/g, \"\");\n d = localDate(va.substr(0, 4), va.substr(4, 2) - 1, number(va.substr(6, 2)));\n } else if (d.length > 4) {\n va = d.replace(/\\D/g, \"\");\n d = localDate(va.substr(0, 4), va.substr(4, 2) - 1, 1);\n } else if (d.length > 2) {\n va = d.replace(/\\D/g, \"\");\n return localDate(va.substr(0, 4), va.substr(4, 2) - 1, 1);\n } else {\n d = new Date();\n }\n }\n\n if (typeof cond === \"undefined\") {\n return d;\n } else {\n\n if (\"add\" in cond) {\n d = function (_d, opts) {\n var yy,\n mm,\n dd,\n mxdd,\n DyMilli = 1000 * 60 * 60 * 24;\n\n if (typeof opts[\"d\"] !== \"undefined\") {\n _d.setTime(_d.getTime() + opts[\"d\"] * DyMilli);\n } else if (typeof opts[\"m\"] !== \"undefined\") {\n yy = _d.getFullYear();\n mm = _d.getMonth();\n dd = _d.getDate();\n yy = yy + parseInt(opts[\"m\"] / 12);\n mm += opts[\"m\"] % 12;\n mxdd = daysOfMonth(yy, mm);\n if (mxdd < dd) dd = mxdd;\n _d = new Date(yy, mm, dd, 12);\n } else if (typeof opts[\"y\"] !== \"undefined\") {\n _d.setTime(_d.getTime() + opts[\"y\"] * 365 * DyMilli);\n }\n return _d;\n }(new Date(d), cond[\"add\"]);\n }\n\n if (\"set\" in cond) {\n d = function (_d, opts) {\n var yy,\n mm,\n dd,\n processor = {\n \"firstDayOfMonth\": function firstDayOfMonth(date) {\n yy = date.getFullYear();\n mm = date.getMonth();\n dd = 1;\n return new Date(yy, mm, dd, 12);\n },\n \"lastDayOfMonth\": function lastDayOfMonth(date) {\n yy = date.getFullYear();\n mm = date.getMonth();\n dd = daysOfMonth(yy, mm);\n return new Date(yy, mm, dd, 12);\n }\n };\n if (opts in processor) {\n return processor[opts](_d);\n } else {\n return _d;\n }\n }(new Date(d), cond[\"set\"]);\n }\n\n if (\"return\" in cond) {\n return function () {\n var fStr = cond[\"return\"],\n nY,\n nM,\n nD,\n nH,\n nMM,\n nS,\n nDW;\n\n nY = d.getUTCFullYear();\n nM = setDigit(d.getMonth() + 1, 2);\n nD = setDigit(d.getDate(), 2);\n nH = setDigit(d.getHours(), 2);\n nMM = setDigit(d.getMinutes(), 2);\n nS = setDigit(d.getSeconds(), 2);\n nDW = d.getDay();\n\n var yre = /[^y]*(yyyy)[^y]*/gi;\n yre.exec(fStr);\n var regY = RegExp.$1;\n var mre = /[^m]*(MM)[^m]*/g;\n mre.exec(fStr);\n var regM = RegExp.$1;\n var dre = /[^d]*(dd)[^d]*/gi;\n dre.exec(fStr);\n var regD = RegExp.$1;\n var hre = /[^h]*(hh)[^h]*/gi;\n hre.exec(fStr);\n var regH = RegExp.$1;\n var mire = /[^m]*(mm)[^i]*/g;\n mire.exec(fStr);\n var regMI = RegExp.$1;\n var sre = /[^s]*(ss)[^s]*/gi;\n sre.exec(fStr);\n var regS = RegExp.$1;\n var dwre = /[^d]*(dw)[^w]*/gi;\n dwre.exec(fStr);\n var regDW = RegExp.$1;\n\n if (regY === \"yyyy\") {\n fStr = fStr.replace(regY, right(nY, regY.length));\n }\n if (regM === \"MM\") {\n if (regM.length == 1) nM = d.getMonth() + 1;\n fStr = fStr.replace(regM, nM);\n }\n if (regD === \"dd\") {\n if (regD.length == 1) nD = d.getDate();\n fStr = fStr.replace(regD, nD);\n }\n if (regH === \"hh\") {\n fStr = fStr.replace(regH, nH);\n }\n if (regMI === \"mm\") {\n fStr = fStr.replace(regMI, nMM);\n }\n if (regS === \"ss\") {\n fStr = fStr.replace(regS, nS);\n }\n if (regDW == \"dw\") {\n fStr = fStr.replace(regDW, info.weekNames[nDW].label);\n }\n return fStr;\n }();\n } else {\n return d;\n }\n }\n }\n\n /**\n * 인자인 날짜가 오늘부터 몇일전인지 반환합니다. 또는 인자인 날짜가 가까운 미래에 몇일 후인지 반환합니다.\n * @method ax5.util.dday\n * @param {String|Data} d\n * @param {Object} cond\n * @returns {Number}\n * @example\n * ```js\n * ax5.util.dday('2016-01-29');\n * // 1\n * ax5.util.dday('2016-01-29', {today:'2016-01-28'});\n * // 1\n * ax5.util.dday('1977-03-29', {today:'2016-01-28', age:true});\n * // 39\n * ```\n */\n function dday(d, cond) {\n var memoryDay = date(d),\n DyMilli = 1000 * 60 * 60 * 24,\n today = new Date(),\n diffnum,\n thisYearMemoryDay;\n\n function getDayTime(_d) {\n return Math.floor(_d.getTime() / DyMilli) * DyMilli;\n }\n\n if (typeof cond === \"undefined\") {\n diffnum = number((getDayTime(memoryDay) - getDayTime(today)) / DyMilli, { floor: true });\n return diffnum;\n } else {\n diffnum = number((getDayTime(memoryDay) - getDayTime(today)) / DyMilli, { floor: true });\n if (cond[\"today\"]) {\n today = date(cond.today);\n diffnum = number((getDayTime(memoryDay) - getDayTime(today)) / DyMilli, { floor: true });\n }\n if (cond[\"thisYear\"]) {\n thisYearMemoryDay = new Date(today.getFullYear(), memoryDay.getMonth(), memoryDay.getDate());\n diffnum = number((getDayTime(thisYearMemoryDay) - getDayTime(today)) / DyMilli, { floor: true });\n if (diffnum < 0) {\n thisYearMemoryDay = new Date(today.getFullYear() + 1, memoryDay.getMonth(), memoryDay.getDate());\n diffnum = number((getDayTime(thisYearMemoryDay) - getDayTime(today)) / DyMilli, { floor: true });\n }\n }\n if (cond[\"age\"]) {\n thisYearMemoryDay = new Date(today.getFullYear(), memoryDay.getMonth(), memoryDay.getDate());\n diffnum = thisYearMemoryDay.getFullYear() - memoryDay.getFullYear();\n }\n\n return diffnum;\n }\n }\n\n /**\n * 인자인 날짜가 몇년 몇월의 몇번째 주차인지 반환합니다.\n * @method ax5.util.weeksOfMonth\n * @param {String|Data} d\n * @returns {Object}\n * @example\n * ```js\n * ax5.util.weeksOfMonth(\"2015-10-01\"); // {year: 2015, month: 10, count: 1}\n * ax5.util.weeksOfMonth(\"2015-09-19\"); // {year: 2015, month: 9, count: 3}\n * ```\n */\n function weeksOfMonth(d) {\n var myDate = date(d);\n return {\n year: myDate.getFullYear(),\n month: myDate.getMonth() + 1,\n count: parseInt(myDate.getDate() / 7 + 1)\n };\n }\n\n /**\n * 년월에 맞는 날자수를 반환합니다.\n * (new Date()).getMonth() 기준으로 월값을 보냅니다. \"2월\" 인경우 \"1\" 을 넘기게 됩니다.\n * @method ax5.util.daysOfMonth\n * @param {Number} y\n * @param {Number} m\n * @returns {Number}\n * @examples\n * ```js\n * ax5.util.daysOfMonth(2015, 11); // 31\n * ax5.util.daysOfMonth(2015, 1); // 28\n * ```\n */\n function daysOfMonth(y, m) {\n if (m == 3 || m == 5 || m == 8 || m == 10) {\n return 30;\n } else if (m == 1) {\n return y % 4 == 0 && y % 100 != 0 || y % 400 == 0 ? 29 : 28;\n } else {\n return 31;\n }\n }\n\n /**\n * 원하는 횟수 만큼 자릿수 맞춤 문자열을 포함한 문자열을 반환합니다.\n * 문자열 길이보다 작은값을 보내면 무시됩니다.\n * @method ax5.util.setDigit\n * @param {String|Number} num\n * @param {Number} length\n * @param {String} [padder=0]\n * @param {Number} [radix]\n * @returns {String}\n * @example\n * ```\n * ax5.util.setDigit(2016, 6)\n * // \"002016\"\n * ax5.util.setDigit(2016, 2)\n * // \"2016\"\n * ```\n */\n function setDigit(num, length, padder, radix) {\n var s = num.toString(radix || 10);\n return times(padder || '0', length - s.length) + s;\n }\n\n /**\n * 문자열을 지정된 수만큼 반복 합니다.\n * @param {String} s\n * @param {Number} count\n * @returns {string}\n * @example\n * ```\n * ax5.util.times(2016, 2)\n * //\"20162016\"\n * ```\n */\n function times(s, count) {\n return count < 1 ? '' : new Array(count + 1).join(s);\n }\n\n /**\n * 타겟엘리먼트의 부모 엘리멘트 트리에서 원하는 조건의 엘리먼트를 얻습니다.\n * @method ax5.util.findParentNode\n * @param {Element} _target - target element\n * @param {Object|Function} cond - 원하는 element를 찾을 조건\n * @returns {Element}\n * @example\n * ```\n * // cond 속성정의\n * var cond = {\n * \ttagname: {String} - 태그명 (ex. a, div, span..),\n * \tclazz: {String} - 클래스명\n * \t[, 그 외 찾고 싶은 attribute명들]\n * };\n * console.log(\n * console.log(\n * ax5.util.findParentNode(e.target, {tagname:\"a\", clazz:\"ax-menu-handel\", \"data-custom-attr\":\"attr_value\"})\n * );\n * // cond 함수로 처리하기\n * jQuery('#id').bind(\"click.app_expand\", function(e){\n * \tvar target = ax5.util.findParentNode(e.target, function(target){\n * \t\tif($(target).hasClass(\"aside\")){\n * \t\t\treturn true;\n * \t\t}\n * \t\telse{\n * \t\t\treturn true;\n * \t\t}\n * \t});\n * \t//client-aside\n * \tif(target.id !== \"client-aside\"){\n * \t\t// some action\n * \t}\n * });\n * ```\n */\n\n function findParentNode(_target, cond) {\n if (_target) {\n while (function () {\n var result = true;\n if (typeof cond === \"undefined\") {\n _target = _target.parentNode ? _target.parentNode : false;\n } else if (isFunction(cond)) {\n result = cond(_target);\n } else if (isObject(cond)) {\n for (var k in cond) {\n if (k === \"tagname\") {\n if (_target.tagName.toLocaleLowerCase() != cond[k]) {\n result = false;\n break;\n }\n } else if (k === \"clazz\" || k === \"class_name\") {\n if (\"className\" in _target) {\n var klasss = _target.className.split(reClassNameSplit);\n var hasClass = false;\n for (var a = 0; a < klasss.length; a++) {\n if (klasss[a] == cond[k]) {\n hasClass = true;\n break;\n }\n }\n result = hasClass;\n } else {\n result = false;\n break;\n }\n } else {\n // 그외 속성값들.\n if (_target.getAttribute) {\n if (_target.getAttribute(k) != cond[k]) {\n result = false;\n break;\n }\n } else {\n result = false;\n break;\n }\n }\n }\n }\n return !result;\n }()) {\n if (_target.parentNode && _target.parentNode.parentNode) {\n _target = _target.parentNode;\n } else {\n _target = false;\n break;\n }\n }\n }\n return _target;\n }\n\n /**\n * @method ax5.util.cssNumber\n * @param {String|Number} val\n * @returns {String}\n * @example\n * ```\n * console.log(ax5.util.cssNumber(\"100px\"))\n * console.log(ax5.util.cssNumber(\"100%\"))\n * console.log(ax5.util.cssNumber(\"100\"))\n * console.log(ax5.util.cssNumber(100))\n * console.log(ax5.util.cssNumber(\"!!100@#\"))\n * ```\n */\n function cssNumber(val) {\n var re = /\\D?(\\d+)([a-zA-Z%]*)/i,\n found = ('' + val).match(re),\n unit = found[2] || \"px\";\n\n return found[1] + unit;\n }\n\n /**\n * css string 및 object 를 넘기면 object 및 string 으로 변환되어 리턴됩니다.\n * @method ax5.util.css\n * @param {Object|String} val - CSS String or CSS Object\n * @returns {String|Object}\n * @example\n * ```\n * console.log(ax5.util.css({background: \"#ccc\", padding: \"50px\", width: \"100px\"}));\n * //\"background:#ccc;padding:50px;width:100px;\"\n * console.log(ax5.util.css('width:100px;padding: 50px; background: #ccc'));\n * // object {width: \"100px\", padding: \"50px\", background: \"#ccc\"}\n * ```\n */\n function css(val) {\n var returns;\n if (isObject(val)) {\n returns = '';\n for (var k in val) {\n returns += k + ':' + val[k] + ';';\n }\n return returns;\n } else if (isString(val)) {\n returns = {};\n var valSplited = val.split(/[ ]*;[ ]*/g);\n valSplited.forEach(function (v) {\n if ((v = v.trim()) !== \"\") {\n var vSplited = v.split(/[ ]*:[ ]*/g);\n returns[vSplited[0]] = vSplited[1];\n }\n });\n return returns;\n }\n }\n\n /**\n * @method ax5.util.stopEvent\n * @param {Event} e\n * @example\n * ```\n * ax5.util.stopEvent(e);\n * ```\n */\n function stopEvent(e) {\n // 이벤트 중지 구문\n if (!e) var e = window.event;\n\n //e.cancelBubble is supported by IE -\n // this will kill the bubbling process.\n e.cancelBubble = true;\n e.returnValue = false;\n\n //e.stopPropagation works only in Firefox.\n if (e.stopPropagation) e.stopPropagation();\n if (e.preventDefault) e.preventDefault();\n\n return false;\n // 이벤트 중지 구문 끝\n }\n\n /**\n * @method ax5.util.selectRange\n * @param {Element} el\n * @param {Element} offset\n * @example\n * ```\n * ax5.util.selectRange($(\"#select-test-0\")); // selectAll\n * ax5.util.selectRange($(\"#select-test-0\"), \"selectAll\"); //selectAll\n * ax5.util.selectRange($(\"#select-test-0\"), \"start\"); // focus on start\n * ax5.util.selectRange($(\"#select-test-0\"), \"end\"); // focus on end\n * ax5.util.selectRange($(\"#select-test-0\"), [1, 5]); // select 1~5\n * ```\n */\n var selectRange = function () {\n var processor = {\n 'textRange': {\n 'selectAll': function selectAll(el, range, offset) {},\n 'arr': function arr(el, range, offset) {\n range.moveStart(\"character\", offset[0]); // todo ie node select 체크필요\n range.collapse();\n range.moveEnd(\"character\", offset[1]);\n },\n 'start': function start(el, range, offset) {\n range.moveStart(\"character\", 0);\n range.collapse();\n },\n 'end': function end(el, range, offset) {\n range.moveStart(\"character\", range.text.length);\n range.collapse();\n }\n },\n 'range': {\n 'selectAll': function selectAll(el, range, offset) {\n range.selectNodeContents(el);\n },\n 'arr': function arr(el, range, offset) {\n if (isObject(offset[0])) {\n range.setStart(offset[0].node, offset[0].offset);\n range.setEnd(offset[1].node, offset[1].offset);\n } else {\n range.setStart(el.firstChild, offset[0]);\n range.setEnd(el.firstChild, offset[1]);\n }\n },\n 'start': function start(el, range, offset) {\n range.selectNodeContents(el);\n range.collapse(true);\n },\n 'end': function end(el, range, offset) {\n range.selectNodeContents(el);\n range.collapse(false);\n }\n }\n };\n return function (el, offset) {\n var range, rangeType, selection;\n\n if (el instanceof jQuery) {\n el = el.get(0);\n }\n if (!el) return;\n\n // 레인지 타입 선택\n if (doc.body.createTextRange) {\n range = document.body.createTextRange();\n range.moveToElementText(el);\n rangeType = \"textRange\";\n } else if (window.getSelection) {\n selection = window.getSelection();\n range = document.createRange();\n rangeType = \"range\";\n }\n\n // range 적용\n if (typeof offset == \"undefined\") {\n processor[rangeType].selectAll.call(this, el, range, offset);\n } else if (isArray(offset)) {\n processor[rangeType].arr.call(this, el, range, offset);\n } else {\n for (var key in processor[rangeType]) {\n if (offset == key) {\n processor[rangeType][key].call(this, el, range, offset);\n break;\n }\n }\n }\n\n // 포커스 및 셀렉트\n if (doc.body.createTextRange) {\n range.select();\n el.focus();\n } else if (window.getSelection) {\n el.focus();\n selection.removeAllRanges();\n selection.addRange(range);\n }\n };\n }();\n\n /**\n * 지정한 시간을 지연시켜 함수를 실행합니다.\n * @method ax5.util.debounce\n * @param {Function} func\n * @param {Number} wait\n * @param {Boolean} immediately\n * @returns {debounced}\n * @example\n * ```js\n * var debounceFn = ax5.util.debounce(function( val ) { console.log(val); }, 300);\n * $(document.body).click(function(){\n * debounceFn(new Date());\n * });\n * ```\n */\n var debounce = function debounce(func, wait, immediately) {\n var timeout, removeTimeout;\n var debounced = function debounced() {\n var args = toArray(arguments);\n\n if (removeTimeout) clearTimeout(removeTimeout);\n if (timeout) {\n // 두번째 호출\n if (timeout) clearTimeout(timeout);\n timeout = setTimeout(function (args) {\n func.apply(this, args);\n }.bind(this, args), wait);\n } else {\n // 첫 호출\n timeout = setTimeout(function (args) {\n func.apply(this, args);\n }.bind(this, args), immediately ? 0 : wait);\n }\n removeTimeout = setTimeout(function () {\n clearTimeout(timeout);\n timeout = null;\n }, wait);\n };\n debounced.cancel = function () {\n clearTimeout(timeout);\n clearTimeout(removeTimeout);\n timeout = null;\n };\n\n return debounced;\n };\n\n /**\n * @method ax5.util.deepCopy\n * @param {Object} obj\n * @returns {Object}\n * @example\n * ```js\n * var obj = [\n * {name:\"A\", child:[{name:\"a-1\"}]},\n * {name:\"B\", child:[{name:\"b-1\"}], callBack: function(){ console.log('callBack'); }}\n * ];\n * var copiedObj = ax5.util.deepCopy(obj)\n * ```\n */\n function deepCopy(obj) {\n var r, l;\n if ((typeof obj === 'undefined' ? 'undefined' : _typeof(obj)) == 'object') {\n if (U.isArray(obj)) {\n l = obj.length;\n r = new Array(l);\n for (var i = 0; i < l; i++) {\n r[i] = deepCopy(obj[i]);\n }\n return r;\n } else {\n return jQuery.extend({}, obj);\n }\n }\n return obj;\n }\n\n /**\n * HTML 문자열을 escape 처리합니다.\n * \"<\" represents the < sign.\n * \">\" represents the > sign.\n * \"&\" represents the & sign.\n * \"" represents the \" mark.\n * [Character entity references](https://www.w3.org/TR/html401/charset.html#h-5.3)\n * @method ax5.util.escapeHtml\n * @param {String} s\n * @returns {string}\n * @example\n * ```\n * ax5.util.escapeHtml('HTML
string & \"escape\"')\n * //\"HTML <span>string</span> & "escape"\"\n * ```\n */\n function escapeHtml(s) {\n if (_toString.call(s) != \"[object String]\") return s;\n if (!s) return \"\";\n return s.replace(/[\\<\\>\\&\\\"]/gm, function (match) {\n switch (match) {\n case \"<\":\n return \"<\";\n case \">\":\n return \">\";\n case \"&\":\n return \"&\";\n case \"\\\"\":\n return \""\";\n default:\n return match;\n }\n });\n }\n\n /**\n * HTML 문자열을 unescape 처리합니다.\n * escapeHtml를 참고하세요.\n * @method ax5.util.unescapeHtml\n * @param {String} s\n * @returns {string}\n * @example\n * ```\n * ax5.util.unescapeHtml('HTML <span>string</span> & "escape"')\n * //\"HTML
string & \"escape\"\"\n * ```\n */\n function unescapeHtml(s) {\n if (_toString.call(s) != \"[object String]\") return s;\n if (!s) return \"\";\n return s.replace(/(<)|(>)|(&)|(")/gm, function (match) {\n switch (match) {\n case \"<\":\n return \"<\";\n case \">\":\n return \">\";\n case \"&\":\n return \"&\";\n case \""\":\n return \"\\\"\";\n default:\n return match;\n }\n });\n }\n\n /**\n * @method ax5.util.string\n * @param {String} tmpl\n * @param {*} args\n * @return {ax5string}\n * @example\n * ```js\n * ax5.util.string(\"{0} is dead, but {1} is alive! {0} {2}\").format(\"ASP\", \"ASP.NET\");\n * ax5.util.string(\"{0} is dead, but {1} is alive! {0} {2}\").format([\"ASP\", \"ASP.NET\"]);\n * ax5.util.stinrg(\"{0} counts\").format(100);\n * ```\n */\n function string(_string) {\n function ax5string(_string) {\n this.value = _string;\n this.toString = function () {\n return this.value;\n };\n /**\n * @method ax5.util.string.format\n * @returns {*}\n */\n this.format = function () {\n var args = [];\n for (var i = 0, l = arguments.length; i < l; i++) {\n args = args.concat(arguments[i]);\n }\n return this.value.replace(/{(\\d+)}/g, function (match, number) {\n return typeof args[number] != 'undefined' ? args[number] : match;\n });\n };\n /**\n * @method ax5.util.string.escape\n * @returns {*}\n */\n this.escape = function () {\n return escapeHtml(this.value);\n };\n /**\n * @method ax5.util.string.unescape\n * @returns {*}\n */\n this.unescape = function () {\n return unescapeHtml(this.value);\n };\n /**\n * @method ax5.util.string.encode\n * @returns {*}\n */\n this.encode = function () {\n return encode(this.value);\n };\n /**\n * @method ax5.util.string.decode\n * @returns {*}\n */\n this.decode = function () {\n return decode(this.value);\n };\n /**\n * @method ax5.util.string.left\n * @param {String|Number} pos - 찾을 문자열 또는 포지션\n * @returns {*}\n */\n this.left = function (_pos) {\n return left(this.value, _pos);\n };\n /**\n * @method ax5.util.string.right\n * @param {String|Number} pos - 찾을 문자열 또는 포지션\n * @returns {*}\n */\n this.right = function (_pos) {\n return right(this.value, _pos);\n };\n /**\n * @method ax5.util.string.camelCase\n * @returns {*}\n */\n this.camelCase = function () {\n return camelCase(this.value);\n };\n /**\n * @method ax5.util.string.snakeCase\n * @returns {*}\n */\n this.snakeCase = function () {\n return snakeCase(this.value);\n };\n }\n return new ax5string(_string);\n }\n\n return {\n alert: alert,\n each: each,\n map: map,\n search: search,\n reduce: reduce,\n reduceRight: reduceRight,\n filter: filter,\n sum: sum,\n avg: avg,\n toJson: toJson,\n parseJson: parseJson,\n first: first,\n last: last,\n deepCopy: deepCopy,\n\n left: left,\n right: right,\n getType: getType,\n isWindow: isWindow,\n isElement: isElement,\n isObject: isObject,\n isArray: isArray,\n isFunction: isFunction,\n isString: isString,\n isNumber: isNumber,\n isNodelist: isNodelist,\n isUndefined: isUndefined,\n isNothing: isNothing,\n setCookie: setCookie,\n getCookie: getCookie,\n camelCase: camelCase,\n snakeCase: snakeCase,\n number: number,\n toArray: toArray,\n merge: merge,\n param: param,\n error: error,\n date: date,\n dday: dday,\n daysOfMonth: daysOfMonth,\n weeksOfMonth: weeksOfMonth,\n setDigit: setDigit,\n times: times,\n findParentNode: findParentNode,\n cssNumber: cssNumber,\n css: css,\n isDate: isDate,\n isDateFormat: isDateFormat,\n stopEvent: stopEvent,\n selectRange: selectRange,\n debounce: debounce,\n escapeHtml: escapeHtml,\n unescapeHtml: unescapeHtml,\n\n string: string\n };\n }();\n\n if ((typeof module === 'undefined' ? 'undefined' : _typeof(module)) === \"object\" && _typeof(module.exports) === \"object\") {\n module.exports = ax5;\n } else {\n root.ax5 = function () {\n return ax5;\n }(); // ax5.ui에 연결\n }\n}).call(typeof window !== \"undefined\" ? window : undefined);\n\nax5.def = {};\nax5.info.errorMsg[\"ax5dialog\"] = {\n \"501\": \"Duplicate call error\"\n};\n\nax5.info.errorMsg[\"ax5picker\"] = {\n \"401\": \"Can not find target element\",\n \"402\": \"Can not find boundID\",\n \"501\": \"Can not find content key\"\n};\n\nax5.info.errorMsg[\"single-uploader\"] = {\n \"460\": \"There are no files to be uploaded.\",\n \"461\": \"There is no uploaded files.\"\n};\n\nax5.info.errorMsg[\"ax5calendar\"] = {\n \"401\": \"Can not find target element\"\n};\n\nax5.info.errorMsg[\"ax5formatter\"] = {\n \"401\": \"Can not find target element\",\n \"402\": \"Can not find boundID\",\n \"501\": \"Can not find pattern\"\n};\n\nax5.info.errorMsg[\"ax5menu\"] = {\n \"501\": \"Can not find menu item\"\n};\n\nax5.info.errorMsg[\"ax5select\"] = {\n \"401\": \"Can not find target element\",\n \"402\": \"Can not find boundID\",\n \"501\": \"Can not find option\"\n};\n\nax5.info.errorMsg[\"ax5combobox\"] = {\n \"401\": \"Can not find target element\",\n \"402\": \"Can not find boundID\",\n \"501\": \"Can not find option\"\n};\n// 필수 Ployfill 확장 구문\n(function () {\n 'use strict';\n\n var root = this,\n re_trim = /^\\s*|\\s*$/g;\n\n // From https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/keys\n if (!Object.keys) {\n Object.keys = function () {\n var hwp = Object.prototype.hasOwnProperty,\n hdeb = !{ toString: null }.propertyIsEnumerable('toString'),\n de = ['toString', 'toLocaleString', 'valueOf', 'hasOwnProperty', 'isPrototypeOf', 'propertyIsEnumerable', 'constructor'],\n del = de.length;\n\n return function (obj) {\n if ((typeof obj === 'undefined' ? 'undefined' : _typeof(obj)) !== 'object' && (typeof obj !== 'function' || obj === null)) throw new TypeError('type err');\n var r = [],\n prop,\n i;\n for (prop in obj) {\n if (hwp.call(obj, prop)) r.push(prop);\n }if (hdeb) {\n for (i = 0; i < del; i++) {\n if (hwp.call(obj, de[i])) r.push(de[i]);\n }\n }\n return r;\n };\n }();\n }\n\n // ES5 15.4.4.18 Array.prototype.forEach ( callbackfn [ , thisArg ] )\n // From https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/forEach\n if (!Array.prototype.forEach) {\n Array.prototype.forEach = function (fun /*, thisp */) {\n if (this === void 0 || this === null) {\n throw TypeError();\n }\n var t = Object(this);\n var len = t.length >>> 0;\n if (typeof fun !== \"function\") {\n throw TypeError();\n }\n var thisp = arguments[1],\n i;\n for (i = 0; i < len; i++) {\n if (i in t) {\n fun.call(thisp, t[i], i, t);\n }\n }\n };\n }\n\n // ES5 15.3.4.5 Function.prototype.bind ( thisArg [, arg1 [, arg2, ... ]] )\n // https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Function/bind\n if (!Function.prototype.bind) {\n Function.prototype.bind = function (o) {\n if (typeof this !== 'function') {\n throw TypeError(\"function\");\n }\n var slice = [].slice,\n args = slice.call(arguments, 1),\n self = this,\n bound = function bound() {\n return self.apply(this instanceof nop ? this : o, args.concat(slice.call(arguments)));\n };\n\n function nop() {}\n\n nop.prototype = self.prototype;\n bound.prototype = new nop();\n return bound;\n };\n }\n\n /*global document */\n /**\n * define document.querySelector & document.querySelectorAll for IE7\n *\n * A not very fast but small hack. The approach is taken from\n * http://weblogs.asp.net/bleroy/archive/2009/08/31/queryselectorall-on-old-ie-versions-something-that-doesn-t-work.aspx\n *\n */\n (function () {\n if (document.querySelectorAll || document.querySelector) {\n return;\n }\n if (!document.createStyleSheet) return;\n var style = document.createStyleSheet(),\n select = function select(selector, maxCount) {\n var all = document.all,\n l = all.length,\n i,\n resultSet = [];\n\n style.addRule(selector, \"foo:bar\");\n for (i = 0; i < l; i += 1) {\n if (all[i].currentStyle.foo === \"bar\") {\n resultSet.push(all[i]);\n if (resultSet.length > maxCount) {\n break;\n }\n }\n }\n style.removeRule(0);\n return resultSet;\n };\n\n document.querySelectorAll = function (selector) {\n return select(selector, Infinity);\n };\n document.querySelector = function (selector) {\n return select(selector, 1)[0] || null;\n };\n })();\n\n if (!String.prototype.trim) {\n (function () {\n String.prototype.trim = function () {\n return this.replace(re_trim, '');\n };\n })();\n }\n\n if (!window.JSON) {\n window.JSON = {\n parse: function parse(sJSON) {\n return new Function('', 'return ' + sJSON)();\n },\n stringify: function () {\n var r = /[\"]/g,\n _f;\n return _f = function f(vContent) {\n var result, i, j;\n switch (result = typeof vContent === 'undefined' ? 'undefined' : _typeof(vContent)) {\n case 'string':\n return '\"' + vContent.replace(r, '\\\\\"') + '\"';\n case 'number':\n case 'boolean':\n return vContent.toString();\n case 'undefined':\n return 'undefined';\n case 'function':\n return '\"\"';\n case 'object':\n if (!vContent) return 'null';\n result = '';\n if (vContent.splice) {\n for (i = 0, j = vContent.length; i < j; i++) {\n result += ',' + _f(vContent[i]);\n }return '[' + result.substr(1) + ']';\n } else {\n for (i in vContent) {\n if (vContent.hasOwnProperty(i) && vContent[i] !== undefined && typeof vContent[i] != 'function') result += ',\"' + i + '\":' + _f(vContent[i]);\n }return '{' + result.substr(1) + '}';\n }\n }\n };\n }()\n };\n }\n\n // splice ie8 <= polyfill\n (function () {\n if (!document.documentMode || document.documentMode >= 9) return false;\n var _splice = Array.prototype.splice;\n Array.prototype.splice = function () {\n var args = Array.prototype.slice.call(arguments);\n if (typeof args[1] === \"undefined\") args[1] = this.length - args[0];\n return _splice.apply(this, args);\n };\n })();\n\n /**\n * Shim for \"fixing\" IE's lack of support (IE < 9) for applying slice\n * on host objects like NamedNodeMap, NodeList, and HTMLCollection\n * (technically, since host objects have been implementation-dependent,\n * at least before ES6, IE hasn't needed to work this way).\n * Also works on strings, fixes IE < 9 to allow an explicit undefined\n * for the 2nd argument (as in Firefox), and prevents errors when\n * called on other DOM objects.\n */\n (function () {\n 'use strict';\n\n var _slice = Array.prototype.slice;\n\n try {\n // Can't be used with DOM elements in IE < 9\n _slice.call(document.documentElement);\n } catch (e) {\n // Fails in IE < 9\n // This will work for genuine arrays, array-like objects,\n // NamedNodeMap (attributes, entities, notations),\n // NodeList (e.g., getElementsByTagName), HTMLCollection (e.g., childNodes),\n // and will not fail on other DOM objects (as do DOM elements in IE < 9)\n Array.prototype.slice = function (begin, end) {\n // IE < 9 gets unhappy with an undefined end argument\n end = typeof end !== 'undefined' ? end : this.length;\n\n // For native Array objects, we use the native slice function\n if (Object.prototype.toString.call(this) === '[object Array]') {\n return _slice.call(this, begin, end);\n }\n\n // For array like object we handle it ourselves.\n var i,\n cloned = [],\n size,\n len = this.length;\n\n // Handle negative value for \"begin\"\n var start = begin || 0;\n start = start >= 0 ? start : Math.max(0, len + start);\n\n // Handle negative value for \"end\"\n var upTo = typeof end == 'number' ? Math.min(end, len) : len;\n if (end < 0) {\n upTo = len + end;\n }\n\n // Actual expected size of the slice\n size = upTo - start;\n\n if (size > 0) {\n cloned = new Array(size);\n if (this.charAt) {\n for (i = 0; i < size; i++) {\n cloned[i] = this.charAt(start + i);\n }\n } else {\n for (i = 0; i < size; i++) {\n cloned[i] = this[start + i];\n }\n }\n }\n\n return cloned;\n };\n }\n })();\n\n // Console-polyfill. MIT license. https://github.com/paulmillr/console-polyfill\n // Make it safe to do console.log() always.\n (function (con) {\n var prop, method;\n var empty = {};\n var dummy = function dummy() {};\n var properties = 'memory'.split(',');\n var methods = ('assert,clear,count,debug,dir,dirxml,error,exception,group,' + 'groupCollapsed,groupEnd,info,log,markTimeline,profile,profiles,profileEnd,' + 'show,table,time,timeEnd,timeline,timelineEnd,timeStamp,trace,warn').split(',');\n while (prop = properties.pop()) {\n con[prop] = con[prop] || empty;\n }while (method = methods.pop()) {\n con[method] = con[method] || dummy;\n }\n })(window.console || {}); // Using `this` for web workers.\n\n\n // Modernizr style test\n if (!(window.webkitMatchMedia || window.mozMatchMedia || window.oMatchMedia || window.msMatchMedia || window.matchMedia)) {\n var root = document.getElementsByTagName('html')[0];\n root.className += ' no-matchmedia';\n }\n\n /*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas, David Knight. Dual MIT/BSD license */\n window.matchMedia || (window.matchMedia = function () {\n \"use strict\";\n\n // For browsers that support matchMedium api such as IE 9 and webkit\n\n var styleMedia = window.styleMedia || window.media;\n\n // For those that don't support matchMedium\n if (!styleMedia) {\n var style = document.createElement('style'),\n script = document.getElementsByTagName('script')[0],\n info = null;\n\n style.type = 'text/css';\n style.id = 'matchmediajs-test';\n\n script.parentNode.insertBefore(style, script);\n\n // 'style.currentStyle' is used by IE <= 8 and 'window.getComputedStyle' for all other browsers\n info = 'getComputedStyle' in window && window.getComputedStyle(style, null) || style.currentStyle;\n\n styleMedia = {\n matchMedium: function matchMedium(media) {\n var text = '@media ' + media + '{ #matchmediajs-test { width: 1px; } }';\n\n // 'style.styleSheet' is used by IE <= 8 and 'style.textContent' for all other browsers\n if (style.styleSheet) {\n style.styleSheet.cssText = text;\n } else {\n style.textContent = text;\n }\n\n // Test if media query is true or false\n return info.width === '1px';\n }\n };\n }\n\n return function (media) {\n return {\n matches: styleMedia.matchMedium(media || 'all'),\n media: media || 'all'\n };\n };\n }());\n\n /*! matchMedia() polyfill addListener/removeListener extension. Author & copyright (c) 2012: Scott Jehl. Dual MIT/BSD license */\n (function () {\n // Bail out for browsers that have addListener support\n if (window.matchMedia && window.matchMedia('all').addListener) {\n return false;\n }\n\n var localMatchMedia = window.matchMedia,\n hasMediaQueries = localMatchMedia('only all').matches,\n isListening = false,\n timeoutID = 0,\n // setTimeout for debouncing 'handleChange'\n queries = [],\n // Contains each 'mql' and associated 'listeners' if 'addListener' is used\n handleChange = function handleChange(evt) {\n // Debounce\n clearTimeout(timeoutID);\n\n timeoutID = setTimeout(function () {\n for (var i = 0, il = queries.length; i < il; i++) {\n var mql = queries[i].mql,\n listeners = queries[i].listeners || [],\n matches = localMatchMedia(mql.media).matches;\n\n // Update mql.matches value and call listeners\n // Fire listeners only if transitioning to or from matched state\n if (matches !== mql.matches) {\n mql.matches = matches;\n\n for (var j = 0, jl = listeners.length; j < jl; j++) {\n listeners[j].call(window, mql);\n }\n }\n }\n }, 30);\n };\n\n window.matchMedia = function (media) {\n var mql = localMatchMedia(media),\n listeners = [],\n index = 0;\n\n mql.addListener = function (listener) {\n // Changes would not occur to css media type so return now (Affects IE <= 8)\n if (!hasMediaQueries) {\n return;\n }\n\n // Set up 'resize' listener for browsers that support CSS3 media queries (Not for IE <= 8)\n // There should only ever be 1 resize listener running for performance\n if (!isListening) {\n isListening = true;\n window.addEventListener('resize', handleChange, true);\n }\n\n // Push object only if it has not been pushed already\n if (index === 0) {\n index = queries.push({\n mql: mql,\n listeners: listeners\n });\n }\n\n listeners.push(listener);\n };\n\n mql.removeListener = function (listener) {\n for (var i = 0, il = listeners.length; i < il; i++) {\n if (listeners[i] === listener) {\n listeners.splice(i, 1);\n }\n }\n };\n\n return mql;\n };\n })();\n\n // extend innerWidth ..\n var html = document.getElementsByTagName('html')[0];\n var body = document.getElementsByTagName('body')[0];\n\n /*\n if (!window.innerWidth) window.innerWidth = html.clientWidth;\n if (!window.innerHeight) window.innerHeight = html.clientHeight;\n if (!window.scrollX) window.scrollX = window.pageXOffset || html.scrollLeft;\n if (!window.scrollY) window.scrollY = window.pageYOffset || html.scrollTop;\n */\n}).call(window);\n/**\n * Refer to this by {@link ax5}.\n * @namespace ax5.ui\n */\n\n/**\n * @class ax5.ui.root\n * @classdesc ax5 ui class\n * @author tom@axisj.com\n * @example\n * ```\n * var myui = new ax5.ui.root();\n * ```\n */\nax5.ui = function () {\n\n function axUi() {\n this.config = {};\n this.name = \"root\";\n\n /**\n * 클래스의 속성 정의 메소드 속성 확장후에 내부에 init 함수를 호출합니다.\n * @method ax5.ui.root.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Boolean} [callInit=true] - init 함수 호출 여부\n * @returns {ax5.ui.axUi}\n * @example\n * ```\n * var myui = new ax5.ui.root();\n * myui.setConfig({\n * \tid:\"abcd\"\n * });\n * ```\n */\n this.setConfig = function (cfg, callInit) {\n jQuery.extend(true, this.config, cfg);\n if (typeof callInit == \"undefined\" || callInit === true) {\n this.init();\n }\n return this;\n };\n this.init = function () {\n console.log(this.config);\n };\n\n this.bindWindowResize = function (callBack) {\n setTimeout(function () {\n jQuery(window).resize(function () {\n if (this.bindWindowResize__) clearTimeout(this.bindWindowResize__);\n this.bindWindowResize__ = setTimeout(function () {\n callBack.call(this);\n }.bind(this), 10);\n }.bind(this));\n }.bind(this), 100);\n };\n\n this.stopEvent = function (e) {\n if (e.preventDefault) e.preventDefault();\n if (e.stopPropagation) e.stopPropagation();\n e.cancelBubble = true;\n return false;\n };\n\n this.toString = function () {\n return this.name + '@' + this.version;\n };\n\n // instance init\n this.main = function () {}.apply(this, arguments);\n }\n\n /**\n * @method ax5.ui.addClass\n * @param {Object} config\n * @param {String} config.className - name of Class\n * @param {String} [config.version=\"\"] - version of Class\n * @param {Object} [config.classStore=ax5.ui] - 클래스가 저장될 경로\n * @param {Function} [config.superClass=ax5.ui.root]\n * @param {Function} cls - Class Function\n */\n function addClass(config, cls) {\n if (!config || !config.className) throw 'invalid call';\n var classStore = config.classStore ? config.classStore : ax5.ui;\n if (!classStore) throw 'invalid classStore';\n\n // make ui definition variable\n ax5.def[config.className] = {\n version: config.version\n };\n\n var factory = function factory(cls, arg) {\n switch (arg.length) {\n case 0:\n return new cls();\n break;\n case 1:\n return new cls(arg[0]);\n break;\n case 2:\n return new cls(arg[0], arg[1]);\n break;\n case 3:\n return new cls(arg[0], arg[1], arg[2]);\n break;\n }\n };\n var initInstance = function initInstance(name, version, instance) {\n instance.name = name;\n instance.version = version;\n instance.instanceId = ax5.getGuid();\n return instance;\n };\n var initPrototype = function initPrototype(cls) {\n var superClass = config.superClass ? config.superClass : ax5.ui.root;\n if (!ax5.util.isFunction(superClass)) throw 'invalid superClass';\n superClass.call(this); // 부모호출\n cls.prototype = new superClass(); // 상속\n };\n var wrapper = function wrapper() {\n if (!this || !(this instanceof wrapper)) throw 'invalid call';\n var instance = factory(cls, arguments);\n return initInstance(config.className, config.version || \"\", instance);\n };\n initPrototype.call(this, cls);\n classStore[config.className] = wrapper;\n }\n\n return {\n root: axUi,\n addClass: addClass\n };\n}();\n\n/*!\n * mustache.js - Logic-less {{mustache}} templates with JavaScript\n * http://github.com/janl/mustache.js\n * https://github.com/thomasJang/mustache.js -- imporove some variables\n */\n\n(function defineMustache(global, factory) {\n\n factory(global.mustache = {});\n})(window.ax5, function mustacheFactory(mustache) {\n\n var objectToString = Object.prototype.toString;\n var isArray = Array.isArray || function isArrayPolyfill(object) {\n return objectToString.call(object) === '[object Array]';\n };\n\n function isFunction(object) {\n return typeof object === 'function';\n }\n\n /**\n * More correct typeof string handling array\n * which normally returns typeof 'object'\n */\n function typeStr(obj) {\n return isArray(obj) ? 'array' : typeof obj === 'undefined' ? 'undefined' : _typeof(obj);\n }\n\n function escapeRegExp(string) {\n return string.replace(/[\\-\\[\\]{}()*+?.,\\\\\\^$|#\\s]/g, '\\\\$&');\n }\n\n /**\n * Null safe way of checking whether or not an object,\n * including its prototype, has a given property\n */\n function hasProperty(obj, propName) {\n return obj != null && (typeof obj === 'undefined' ? 'undefined' : _typeof(obj)) === 'object' && propName in obj;\n }\n\n // Workaround for https://issues.apache.org/jira/browse/COUCHDB-577\n // See https://github.com/janl/mustache.js/issues/189\n var regExpTest = RegExp.prototype.test;\n\n function testRegExp(re, string) {\n return regExpTest.call(re, string);\n }\n\n var nonSpaceRe = /\\S/;\n\n function isWhitespace(string) {\n return !testRegExp(nonSpaceRe, string);\n }\n\n var entityMap = {\n '&': '&', '<': '<', '>': '>', '\"': '"', \"'\": ''', '/': '/'\n };\n\n function escapeHtml(string) {\n return String(string).replace(/[&<>\"'\\/]/g, function fromEntityMap(s) {\n return entityMap[s];\n });\n }\n\n var whiteRe = /\\s*/;\n var spaceRe = /\\s+/;\n var equalsRe = /\\s*=/;\n var curlyRe = /\\s*\\}/;\n var tagRe = /#|\\^|\\/|>|\\{|&|=|!/;\n\n /**\n * Breaks up the given `template` string into a tree of tokens. If the `tags`\n * argument is given here it must be an array with two string values: the\n * opening and closing tags used in the template (e.g. [ \"<%\", \"%>\" ]). Of\n * course, the default is to use mustaches (i.e. mustache.tags).\n *\n * A token is an array with at least 4 elements. The first element is the\n * mustache symbol that was used inside the tag, e.g. \"#\" or \"&\". If the tag\n * did not contain a symbol (i.e. {{myValue}}) this element is \"name\". For\n * all text that appears outside a symbol this element is \"text\".\n *\n * The second element of a token is its \"value\". For mustache tags this is\n * whatever else was inside the tag besides the opening symbol. For text tokens\n * this is the text itself.\n *\n * The third and fourth elements of the token are the start and end indices,\n * respectively, of the token in the original template.\n *\n * Tokens that are the root node of a subtree contain two more elements: 1) an\n * array of tokens in the subtree and 2) the index in the original template at\n * which the closing tag for that section begins.\n */\n function parseTemplate(template, tags) {\n if (!template) return [];\n\n var sections = []; // Stack to hold section tokens\n var tokens = []; // Buffer to hold the tokens\n var spaces = []; // Indices of whitespace tokens on the current line\n var hasTag = false; // Is there a {{tag}} on the current line?\n var nonSpace = false; // Is there a non-space char on the current line?\n\n // Strips all whitespace tokens array for the current line\n // if there was a {{#tag}} on it and otherwise only space.\n function stripSpace() {\n if (hasTag && !nonSpace) {\n while (spaces.length) {\n delete tokens[spaces.pop()];\n }\n } else {\n spaces = [];\n }\n\n hasTag = false;\n nonSpace = false;\n }\n\n var openingTagRe, closingTagRe, closingCurlyRe;\n\n function compileTags(tagsToCompile) {\n if (typeof tagsToCompile === 'string') tagsToCompile = tagsToCompile.split(spaceRe, 2);\n\n if (!isArray(tagsToCompile) || tagsToCompile.length !== 2) throw new Error('Invalid tags: ' + tagsToCompile);\n\n openingTagRe = new RegExp(escapeRegExp(tagsToCompile[0]) + '\\\\s*');\n closingTagRe = new RegExp('\\\\s*' + escapeRegExp(tagsToCompile[1]));\n closingCurlyRe = new RegExp('\\\\s*' + escapeRegExp('}' + tagsToCompile[1]));\n }\n\n compileTags(tags || mustache.tags);\n\n var scanner = new Scanner(template);\n\n var start, type, value, chr, token, openSection;\n while (!scanner.eos()) {\n start = scanner.pos;\n\n // Match any text between tags.\n value = scanner.scanUntil(openingTagRe);\n\n if (value) {\n for (var i = 0, valueLength = value.length; i < valueLength; ++i) {\n chr = value.charAt(i);\n\n if (isWhitespace(chr)) {\n spaces.push(tokens.length);\n } else {\n nonSpace = true;\n }\n\n tokens.push(['text', chr, start, start + 1]);\n start += 1;\n\n // Check for whitespace on the current line.\n if (chr === '\\n') stripSpace();\n }\n }\n\n // Match the opening tag.\n if (!scanner.scan(openingTagRe)) break;\n\n hasTag = true;\n\n // Get the tag type.\n type = scanner.scan(tagRe) || 'name';\n scanner.scan(whiteRe);\n\n // Get the tag value.\n if (type === '=') {\n value = scanner.scanUntil(equalsRe);\n scanner.scan(equalsRe);\n scanner.scanUntil(closingTagRe);\n } else if (type === '{') {\n value = scanner.scanUntil(closingCurlyRe);\n scanner.scan(curlyRe);\n scanner.scanUntil(closingTagRe);\n type = '&';\n } else {\n value = scanner.scanUntil(closingTagRe);\n }\n\n // Match the closing tag.\n if (!scanner.scan(closingTagRe)) throw new Error('Unclosed tag at ' + scanner.pos);\n\n token = [type, value, start, scanner.pos];\n tokens.push(token);\n\n if (type === '#' || type === '^') {\n sections.push(token);\n } else if (type === '/') {\n // Check section nesting.\n openSection = sections.pop();\n\n if (!openSection) throw new Error('Unopened section \"' + value + '\" at ' + start);\n\n if (openSection[1] !== value) throw new Error('Unclosed section \"' + openSection[1] + '\" at ' + start);\n } else if (type === 'name' || type === '{' || type === '&') {\n nonSpace = true;\n } else if (type === '=') {\n // Set the tags for the next time around.\n compileTags(value);\n }\n }\n\n // Make sure there are no open sections when we're done.\n openSection = sections.pop();\n\n if (openSection) throw new Error('Unclosed section \"' + openSection[1] + '\" at ' + scanner.pos);\n\n return nestTokens(squashTokens(tokens));\n }\n\n /**\n * Combines the values of consecutive text tokens in the given `tokens` array\n * to a single token.\n */\n function squashTokens(tokens) {\n var squashedTokens = [];\n\n var token, lastToken;\n for (var i = 0, numTokens = tokens.length; i < numTokens; ++i) {\n token = tokens[i];\n\n if (token) {\n if (token[0] === 'text' && lastToken && lastToken[0] === 'text') {\n lastToken[1] += token[1];\n lastToken[3] = token[3];\n } else {\n squashedTokens.push(token);\n lastToken = token;\n }\n }\n }\n\n return squashedTokens;\n }\n\n /**\n * Forms the given array of `tokens` into a nested tree structure where\n * tokens that represent a section have two additional items: 1) an array of\n * all tokens that appear in that section and 2) the index in the original\n * template that represents the end of that section.\n */\n function nestTokens(tokens) {\n var nestedTokens = [];\n var collector = nestedTokens;\n var sections = [];\n\n var token, section;\n for (var i = 0, numTokens = tokens.length; i < numTokens; ++i) {\n token = tokens[i];\n\n switch (token[0]) {\n case '#':\n case '^':\n collector.push(token);\n sections.push(token);\n collector = token[4] = [];\n break;\n case '/':\n section = sections.pop();\n section[5] = token[2];\n collector = sections.length > 0 ? sections[sections.length - 1][4] : nestedTokens;\n break;\n default:\n collector.push(token);\n }\n }\n\n return nestedTokens;\n }\n\n /**\n * A simple string scanner that is used by the template parser to find\n * tokens in template strings.\n */\n function Scanner(string) {\n this.string = string;\n this.tail = string;\n this.pos = 0;\n }\n\n /**\n * Returns `true` if the tail is empty (end of string).\n */\n Scanner.prototype.eos = function eos() {\n return this.tail === '';\n };\n\n /**\n * Tries to match the given regular expression at the current position.\n * Returns the matched text if it can match, the empty string otherwise.\n */\n Scanner.prototype.scan = function scan(re) {\n var match = this.tail.match(re);\n\n if (!match || match.index !== 0) return '';\n\n var string = match[0];\n\n this.tail = this.tail.substring(string.length);\n this.pos += string.length;\n\n return string;\n };\n\n /**\n * Skips all text until the given regular expression can be matched. Returns\n * the skipped string, which is the entire tail if no match can be made.\n */\n Scanner.prototype.scanUntil = function scanUntil(re) {\n var index = this.tail.search(re),\n match;\n\n switch (index) {\n case -1:\n match = this.tail;\n this.tail = '';\n break;\n case 0:\n match = '';\n break;\n default:\n match = this.tail.substring(0, index);\n this.tail = this.tail.substring(index);\n }\n\n this.pos += match.length;\n\n return match;\n };\n\n /**\n * Represents a rendering context by wrapping a view object and\n * maintaining a reference to the parent context.\n */\n function Context(view, parentContext) {\n this.view = view;\n this.cache = {\n '.': this.view,\n '@each': function each() {\n var returns = [];\n for (var k in this) {\n returns.push({ '@key': k, '@value': this[k] });\n }\n return returns;\n }\n };\n this.parent = parentContext;\n }\n\n /**\n * Creates a new context using the given view with this context\n * as the parent.\n */\n Context.prototype.push = function push(view) {\n return new Context(view, this);\n };\n\n /**\n * Returns the value of the given name in this context, traversing\n * up the context hierarchy if the value is absent in this context's view.\n */\n Context.prototype.lookup = function lookup(name) {\n var cache = this.cache;\n\n var value;\n if (cache.hasOwnProperty(name)) {\n value = cache[name];\n } else {\n var context = this,\n names,\n index,\n lookupHit = false;\n\n while (context) {\n if (name.indexOf('.') > 0) {\n value = context.view;\n names = name.split('.');\n index = 0;\n\n /**\n * Using the dot notion path in `name`, we descend through the\n * nested objects.\n *\n * To be certain that the lookup has been successful, we have to\n * check if the last object in the path actually has the property\n * we are looking for. We store the result in `lookupHit`.\n *\n * This is specially necessary for when the value has been set to\n * `undefined` and we want to avoid looking up parent contexts.\n **/\n while (value != null && index < names.length) {\n if (index === names.length - 1) lookupHit = hasProperty(value, names[index]);\n\n value = value[names[index++]];\n }\n } else {\n value = context.view[name];\n lookupHit = hasProperty(context.view, name);\n }\n\n if (lookupHit) break;\n\n context = context.parent;\n }\n\n cache[name] = value;\n }\n\n if (isFunction(value)) value = value.call(this.view);\n\n return value;\n };\n\n /**\n * A Writer knows how to take a stream of tokens and render them to a\n * string, given a context. It also maintains a cache of templates to\n * avoid the need to parse the same template twice.\n */\n function Writer() {\n this.cache = {};\n }\n\n /**\n * Clears all cached templates in this writer.\n */\n Writer.prototype.clearCache = function clearCache() {\n this.cache = {};\n };\n\n /**\n * Parses and caches the given `template` and returns the array of tokens\n * that is generated from the parse.\n */\n Writer.prototype.parse = function parse(template, tags) {\n var cache = this.cache;\n var tokens = cache[template];\n\n if (tokens == null) tokens = cache[template] = parseTemplate(template, tags);\n\n return tokens;\n };\n\n /**\n * High-level method that is used to render the given `template` with\n * the given `view`.\n *\n * The optional `partials` argument may be an object that contains the\n * names and templates of partials that are used in the template. It may\n * also be a function that is used to load partial templates on the fly\n * that takes a single argument: the name of the partial.\n */\n Writer.prototype.render = function render(template, view, partials) {\n var tokens = this.parse(template);\n var context = view instanceof Context ? view : new Context(view);\n return this.renderTokens(tokens, context, partials, template);\n };\n\n /**\n * Low-level method that renders the given array of `tokens` using\n * the given `context` and `partials`.\n *\n * Note: The `originalTemplate` is only ever used to extract the portion\n * of the original template that was contained in a higher-order section.\n * If the template doesn't use higher-order sections, this argument may\n * be omitted.\n */\n Writer.prototype.renderTokens = function renderTokens(tokens, context, partials, originalTemplate) {\n var buffer = '';\n var token, symbol, value;\n for (var i = 0, numTokens = tokens.length; i < numTokens; ++i) {\n value = undefined;\n token = tokens[i];\n symbol = token[0];\n\n if (symbol === '#') value = this.renderSection(token, context, partials, originalTemplate);else if (symbol === '^') value = this.renderInverted(token, context, partials, originalTemplate);else if (symbol === '>') value = this.renderPartial(token, context, partials, originalTemplate);else if (symbol === '&') value = this.unescapedValue(token, context);else if (symbol === 'name') value = this.escapedValue(token, context);else if (symbol === 'text') value = this.rawValue(token);\n\n if (value !== undefined) buffer += value;\n }\n\n return buffer;\n };\n\n Writer.prototype.renderSection = function renderSection(token, context, partials, originalTemplate) {\n var self = this;\n var buffer = '';\n\n var value = context.lookup(token[1]);\n\n // This function is used to render an arbitrary template\n // in the current context by higher-order sections.\n function subRender(template) {\n return self.render(template, context, partials);\n }\n\n if (!value) return;\n\n if (isArray(value)) {\n for (var j = 0, valueLength = value.length; j < valueLength; ++j) {\n if (value[j]) {\n if (_typeof(value[j]) === 'object') {\n value[j]['@i'] = j;\n value[j]['@first'] = j === 0;\n }\n\n buffer += this.renderTokens(token[4], context.push(value[j]), partials, originalTemplate);\n }\n }\n } else if ((typeof value === 'undefined' ? 'undefined' : _typeof(value)) === 'object' || typeof value === 'string' || typeof value === 'number') {\n buffer += this.renderTokens(token[4], context.push(value), partials, originalTemplate);\n } else if (isFunction(value)) {\n if (typeof originalTemplate !== 'string') throw new Error('Cannot use higher-order sections without the original template');\n\n // Extract the portion of the original template that the section contains.\n value = value.call(context.view, originalTemplate.slice(token[3], token[5]), subRender);\n\n if (value != null) buffer += value;\n } else {\n buffer += this.renderTokens(token[4], context, partials, originalTemplate);\n }\n return buffer;\n };\n\n Writer.prototype.renderInverted = function renderInverted(token, context, partials, originalTemplate) {\n var value = context.lookup(token[1]);\n\n // Use JavaScript's definition of falsy. Include empty arrays.\n // See https://github.com/janl/mustache.js/issues/186\n if (!value || isArray(value) && value.length === 0) return this.renderTokens(token[4], context, partials, originalTemplate);\n };\n\n Writer.prototype.renderPartial = function renderPartial(token, context, partials) {\n if (!partials) return;\n\n var value = isFunction(partials) ? partials(token[1]) : partials[token[1]];\n if (value != null) return this.renderTokens(this.parse(value), context, partials, value);\n };\n\n Writer.prototype.unescapedValue = function unescapedValue(token, context) {\n var value = context.lookup(token[1]);\n if (value != null) return value;\n };\n\n Writer.prototype.escapedValue = function escapedValue(token, context) {\n var value = context.lookup(token[1]);\n if (value != null) return mustache.escape(value);\n };\n\n Writer.prototype.rawValue = function rawValue(token) {\n return token[1];\n };\n\n mustache.name = 'mustache.js';\n mustache.version = '2.1.3';\n mustache.tags = ['{{', '}}'];\n\n // All high-level mustache.* functions use this writer.\n var defaultWriter = new Writer();\n\n /**\n * Clears all cached templates in the default writer.\n */\n mustache.clearCache = function clearCache() {\n return defaultWriter.clearCache();\n };\n\n /**\n * Parses and caches the given template in the default writer and returns the\n * array of tokens it contains. Doing this ahead of time avoids the need to\n * parse templates on the fly as they are rendered.\n */\n mustache.parse = function parse(template, tags) {\n return defaultWriter.parse(template, tags);\n };\n\n /**\n * Renders the `template` with the given `view` and `partials` using the\n * default writer.\n */\n mustache.render = function render(template, view, partials) {\n if (typeof template !== 'string') {\n throw new TypeError('Invalid template! Template should be a \"string\" ' + 'but \"' + typeStr(template) + '\" was given as the first ' + 'argument for mustache#render(template, view, partials)');\n }\n\n return defaultWriter.render(template, view, partials);\n };\n\n // This is here for backwards compatibility with 0.4.x.,\n /*eslint-disable */ // eslint wants camel cased function name\n mustache.to_html = function to_html(template, view, partials, send) {\n /*eslint-enable*/\n\n var result = mustache.render(template, view, partials);\n\n if (isFunction(send)) {\n send(result);\n } else {\n return result;\n }\n };\n\n // Export the escaping function so that the user may override it.\n // See https://github.com/janl/mustache.js/issues/244\n mustache.escape = escapeHtml;\n\n // Export these mainly for testing, but also for advanced usage.\n mustache.Scanner = Scanner;\n mustache.Context = Context;\n mustache.Writer = Writer;\n});\n// ax5.ui.dialog\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var DIALOG;\n\n UI.addClass({\n className: \"dialog\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5dialog\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var dialog = new ax5.ui.dialog();\n * var mask = new ax5.ui.mask();\n * dialog.setConfig({\n * zIndex: 5000,\n * onStateChanged: function () {\n * if (this.state === \"open\") {\n * mask.open();\n * }\n * else if (this.state === \"close\") {\n * mask.close();\n * }\n * }\n * });\n *\n * dialog.alert({\n * theme: 'default',\n * title: 'Alert default',\n * msg: theme + ' color'\n * }, function () {\n * console.log(this);\n * });\n * ```\n */\n var ax5dialog = function ax5dialog() {\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n id: 'ax5-dialog-' + this.instanceId,\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchend\" : \"click\"),\n theme: 'default',\n width: 300,\n title: '',\n msg: '',\n lang: {\n \"ok\": \"ok\", \"cancel\": \"cancel\"\n },\n animateTime: 150\n };\n this.activeDialog = null;\n cfg = this.config;\n\n var onStateChanged = function onStateChanged(opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n that = null;\n return true;\n },\n\n /**\n * @method ax5dialog.getContent\n * @param {String} dialogId\n * @param {Object} opts\n * @returns dialogDisplay\n */\n getContent = function getContent(dialogId, opts) {\n var data = {\n dialogId: dialogId,\n title: opts.title || cfg.title || \"\",\n msg: (opts.msg || cfg.msg || \"\").replace(/\\n/g, \"
\"),\n input: opts.input,\n btns: opts.btns,\n '_crlf': function _crlf() {\n return this.replace(/\\n/g, \"
\");\n }\n };\n\n try {\n return DIALOG.tmpl.get.call(this, \"dialogDisplay\", data);\n } finally {\n data = null;\n }\n },\n\n /**\n * @method ax5dialog.open\n * @param {Object} opts\n * @param callback\n */\n open = function open(opts, callback) {\n var pos = {},\n box;\n\n opts.id = opts.id || cfg.id;\n\n box = {\n width: opts.width\n };\n jQuery(document.body).append(getContent.call(this, opts.id, opts));\n\n this.activeDialog = jQuery('#' + opts.id);\n this.activeDialog.css({ width: box.width });\n\n // dialog 높이 구하기 - 너비가 정해지면 높이가 변경 될 것.\n opts.height = box.height = this.activeDialog.height();\n\n //- position 정렬\n if (typeof opts.position === \"undefined\" || opts.position === \"center\") {\n pos.top = jQuery(window).height() / 2 - box.height / 2;\n pos.left = jQuery(window).width() / 2 - box.width / 2;\n } else {\n pos.left = opts.position.left || 0;\n pos.top = opts.position.top || 0;\n }\n if (cfg.zIndex) {\n pos[\"z-index\"] = cfg.zIndex;\n }\n this.activeDialog.css(pos);\n\n // bind button event\n if (opts.dialogType === \"prompt\") {\n this.activeDialog.find(\"[data-dialog-prompt]\").get(0).focus();\n } else {\n this.activeDialog.find(\"[data-dialog-btn]\").get(0).focus();\n }\n\n this.activeDialog.find(\"[data-dialog-btn]\").on(cfg.clickEventName, function (e) {\n btnOnClick.call(this, e || window.event, opts, callback);\n }.bind(this));\n\n // bind key event\n jQuery(window).bind(\"keydown.ax5dialog\", function (e) {\n onKeyup.call(this, e || window.event, opts, callback);\n }.bind(this));\n\n jQuery(window).bind(\"resize.ax5dialog\", function (e) {\n align.call(this, e || window.event);\n }.bind(this));\n\n onStateChanged.call(this, opts, {\n self: this,\n state: \"open\"\n });\n\n pos = null;\n box = null;\n },\n align = function align(e) {\n if (!this.activeDialog) return this;\n var opts = self.dialogConfig,\n box = {\n width: opts.width,\n height: opts.height\n };\n //- position 정렬\n if (typeof opts.position === \"undefined\" || opts.position === \"center\") {\n box.top = window.innerHeight / 2 - box.height / 2;\n box.left = window.innerWidth / 2 - box.width / 2;\n } else {\n box.left = opts.position.left || 0;\n box.top = opts.position.top || 0;\n }\n if (box.left < 0) box.left = 0;\n if (box.top < 0) box.top = 0;\n\n this.activeDialog.css(box);\n\n opts = null;\n box = null;\n\n return this;\n },\n btnOnClick = function btnOnClick(e, opts, callback, target, k) {\n var that;\n if (e.srcElement) e.target = e.srcElement;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-dialog-btn\")) {\n return true;\n }\n });\n\n if (target) {\n k = target.getAttribute(\"data-dialog-btn\");\n\n that = {\n self: this,\n key: k, value: opts.btns[k],\n dialogId: opts.id,\n btnTarget: target\n };\n if (opts.dialogType === \"prompt\") {\n var emptyKey = null;\n for (var oi in opts.input) {\n that[oi] = this.activeDialog.find('[data-dialog-prompt=' + oi + ']').val();\n if (that[oi] == \"\" || that[oi] == null) {\n emptyKey = oi;\n break;\n }\n }\n }\n if (opts.btns[k].onClick) {\n opts.btns[k].onClick.call(that, k);\n } else if (opts.dialogType === \"alert\") {\n if (callback) callback.call(that, k);\n this.close({ doNotCallback: true });\n } else if (opts.dialogType === \"confirm\") {\n if (callback) callback.call(that, k);\n this.close({ doNotCallback: true });\n } else if (opts.dialogType === \"prompt\") {\n if (k === 'ok') {\n if (emptyKey) {\n this.activeDialog.find('[data-dialog-prompt=\"' + emptyKey + '\"]').get(0).focus();\n return false;\n }\n }\n if (callback) callback.call(that, k);\n this.close({ doNotCallback: true });\n }\n }\n\n that = null;\n opts = null;\n callback = null;\n target = null;\n k = null;\n },\n onKeyup = function onKeyup(e, opts, callback, target, k) {\n var that,\n emptyKey = null;\n\n if (e.keyCode == ax5.info.eventKeys.ESC) {\n this.close();\n }\n if (opts.dialogType === \"prompt\") {\n if (e.keyCode == ax5.info.eventKeys.RETURN) {\n that = {\n self: this,\n key: k, value: opts.btns[k],\n dialogId: opts.id,\n btnTarget: target\n };\n\n for (var oi in opts.input) {\n that[oi] = this.activeDialog.find('[data-dialog-prompt=' + oi + ']').val();\n if (that[oi] == \"\" || that[oi] == null) {\n emptyKey = oi;\n break;\n }\n }\n if (emptyKey) {\n that = null;\n emptyKey = null;\n return false;\n }\n if (callback) callback.call(that, k);\n this.close({ doNotCallback: true });\n }\n }\n\n that = null;\n emptyKey = null;\n opts = null;\n callback = null;\n target = null;\n k = null;\n };\n\n /**\n * Preferences of dialog UI\n * @method ax5dialog.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Number} [config.zIndex]\n * @returns {ax5dialog}\n * @example\n * ```\n * ```\n */\n //== class body start\n this.init = function () {\n\n this.onStateChanged = cfg.onStateChanged;\n // this.onLoad = cfg.onLoad;\n };\n\n /**\n * open the dialog of alert type\n * @method ax5dialog.alert\n * @param {Object|String} [{theme, title, msg, btns}|msg] - dialog 속성을 json으로 정의하거나 msg만 전달\n * @param {Function} [callback] - 사용자 확인 이벤트시 호출될 callback 함수\n * @returns {ax5dialog}\n * @example\n * ```\n * myDialog.alert({\n * title: 'app title',\n * msg: 'alert'\n * }, function(){});\n * ```\n */\n this.alert = function (opts, callback, tryCount) {\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n };\n }\n\n if (this.activeDialog) {\n // try one more\n if (!tryCount) {\n setTimeout(function () {\n this.alert(opts, callback, 1);\n }.bind(this), Number(cfg.animateTime) + 100);\n } else {\n console.log(ax5.info.getError(\"ax5dialog\", \"501\", \"alert\"));\n }\n return this;\n }\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n\n opts.dialogType = \"alert\";\n opts.theme = opts.theme || cfg.theme || \"\";\n opts.callback = callback;\n\n if (typeof opts.btns === \"undefined\") {\n opts.btns = {\n ok: { label: cfg.lang[\"ok\"], theme: opts.theme }\n };\n }\n open.call(this, opts, callback);\n\n return this;\n };\n\n /**\n * open the dialog of confirm type\n * @method ax5dialog.confirm\n * @param {Object|String} [{theme, title, msg, btns}|msg] - dialog 속성을 json으로 정의하거나 msg만 전달\n * @param {Function} [callback] - 사용자 확인 이벤트시 호출될 callback 함수\n * @returns {ax5dialog}\n * @example\n * ```\n * myDialog.confirm({\n * title: 'app title',\n * msg: 'confirm'\n * }, function(){});\n * ```\n */\n this.confirm = function (opts, callback, tryCount) {\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n };\n }\n\n if (this.activeDialog) {\n // try one more\n if (!tryCount) {\n setTimeout(function () {\n this.confirm(opts, callback, 1);\n }.bind(this), Number(cfg.animateTime) + 100);\n } else {\n console.log(ax5.info.getError(\"ax5dialog\", \"501\", \"confirm\"));\n }\n return this;\n }\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n\n opts.dialogType = \"confirm\";\n opts.theme = opts.theme || cfg.theme || \"\";\n opts.callback = callback;\n\n if (typeof opts.btns === \"undefined\") {\n opts.btns = {\n ok: { label: cfg.lang[\"ok\"], theme: opts.theme },\n cancel: { label: cfg.lang[\"cancel\"] }\n };\n }\n open.call(this, opts, callback);\n\n return this;\n };\n\n /**\n * open the dialog of prompt type\n * @method ax5dialog.prompt\n * @param {Object|String} [{theme, title, msg, btns, input}|msg] - dialog 속성을 json으로 정의하거나 msg만 전달\n * @param {Function} [callback] - 사용자 확인 이벤트시 호출될 callback 함수\n * @returns {ax5dialog}\n * @example\n * ```\n * myDialog.prompt({\n * title: 'app title',\n * msg: 'alert'\n * }, function(){});\n * ```\n */\n this.prompt = function (opts, callback, tryCount) {\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n };\n }\n\n if (this.activeDialog) {\n // try one more\n if (!tryCount) {\n setTimeout(function () {\n this.prompt(opts, callback, 1);\n }.bind(this), Number(cfg.animateTime) + 100);\n } else {\n console.log(ax5.info.getError(\"ax5dialog\", \"501\", \"prompt\"));\n }\n return this;\n }\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n opts.dialogType = \"prompt\";\n opts.theme = opts.theme || cfg.theme || \"\";\n opts.callback = callback;\n\n if (typeof opts.input === \"undefined\") {\n opts.input = {\n value: { label: \"\" }\n };\n }\n if (typeof opts.btns === \"undefined\") {\n opts.btns = {\n ok: { label: cfg.lang[\"ok\"], theme: opts.theme },\n cancel: { label: cfg.lang[\"cancel\"] }\n };\n }\n open.call(this, opts, callback);\n\n return this;\n };\n\n /**\n * close the dialog\n * @method ax5dialog.close\n * @returns {ax5dialog}\n * @example\n * ```\n * myDialog.close();\n * ```\n */\n this.close = function (_option) {\n var opts, that;\n if (this.activeDialog) {\n opts = self.dialogConfig;\n this.activeDialog.addClass(\"destroy\");\n jQuery(window).unbind(\"keydown.ax5dialog\");\n jQuery(window).unbind(\"resize.ax5dialog\");\n\n setTimeout(function () {\n if (this.activeDialog) {\n this.activeDialog.remove();\n this.activeDialog = null;\n }\n\n that = {\n self: this,\n state: \"close\",\n dialogId: opts.id\n };\n\n if (opts.callback && (!_option || !_option.doNotCallback)) {\n opts.callback.call(that);\n }\n\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n opts = null;\n that = null;\n }.bind(this), cfg.animateTime);\n }\n return this;\n };\n\n // 클래스 생성자\n this.main = function () {\n\n UI.dialog_instance = UI.dialog_instance || [];\n UI.dialog_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5dialog;\n }());\n DIALOG = ax5.ui.dialog;\n})();\n\n// ax5.ui.dialog.tmpl\n(function () {\n\n var DIALOG = ax5.ui.dialog;\n\n var dialogDisplay = function dialogDisplay(columnKeys) {\n return ' \\n
\\n \\n
\\n
{{{msg}}}
\\n \\n {{#input}}\\n
\\n {{#@each}}\\n
\\n {{/@each}}\\n
\\n {{/input}}\\n \\n
\\n
\\n
\\n ';\n };\n\n DIALOG.tmpl = {\n \"dialogDisplay\": dialogDisplay,\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(DIALOG.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.mask\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var MASK;\n\n UI.addClass({\n className: \"mask\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5mask\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var customMask = function customMask() {\n * var cTmpl = '' +\n * '
' +\n * '
' +\n * '
' +\n * ' {{{body}}}' +\n * '
' +\n * '
';\n * return cTmpl;\n * };\n * ax5.ui.mask.tmpl.customMask = customMask;\n *\n * var mask = new ax5.ui.mask();\n *\n * mask.open({\n * templateName: 'customMask',\n * content: 'custom MASK on target',\n * target: $(\"#user-content\").get(0),\n * onClick: function(){\n * console.log(this);\n * }\n * });\n * ```\n */\n var ax5mask = function ax5mask() {\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: '',\n target: jQuery(document.body).get(0),\n animateTime: 250\n };\n this.maskContent = '';\n this.status = \"off\";\n\n cfg = this.config;\n\n var onStateChanged = function onStateChanged(opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n opts = null;\n that = null;\n return true;\n },\n getBodyTmpl = function getBodyTmpl(data) {\n if (typeof data.templateName === \"undefined\") data.templateName = \"defaultMask\";\n return MASK.tmpl.get.call(this, data.templateName, data);\n },\n setBody = function setBody(content) {\n this.maskContent = content;\n };\n\n /**\n * Preferences of Mask UI\n * @method ax5mask.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5mask}\n * @example\n * ```\n * setConfig({\n * target : {Element|AX5 nodelist}, // 마스크 처리할 대상\n * content : {String}, // 마스크안에 들어가는 내용물\n * onStateChanged: function(){} // 마스크 상태변경 시 호출되는 함수 this.type으로 예외처리 가능\n * }\n * ```\n */\n this.init = function () {\n // after setConfig();\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n if (this.config.content) setBody.call(this, this.config.content);\n };\n\n /**\n * open mask\n * target 을 주지 않으면 기본적으로 body 에 마스크가 적용되고 원하는 타겟을 지정해서 마스크를 씌울 수 있습니다.\n * 기본 정의된 마스크 외에 사용자가 템플릿을 정의해서 마스크를 사용 가능합니다.\n * @method ax5mask.open\n * @param {Object} config\n * @param {String} config\n * @returns {ax5mask}\n * @example\n * ```js\n * my_mask.open({\n * target: document.body,\n * content: \"
Loading..
\",\n * onStateChanged: function () {\n *\n * }\n * });\n *\n * my_mask.open({\n * target: $(\"#mask-target\").get(0), // dom Element\n * content: \"
Loading..
\",\n * onStateChanged: function () {\n *\n * }\n * });\n *\n *\n * var customMask = function customMask() {\n * var cTmpl = '' +\n * '
' +\n * '
' +\n * '
' +\n * ' {{{body}}}' +\n * '
' +\n * '
';\n * return cTmpl;\n * };\n * ax5.ui.mask.tmpl.customMask = customMask;\n *\n * my_mask.open({\n * target: $(\"#mask-target\").get(0), // dom Element\n * content: \"
Loading..
\",\n * \n * onStateChanged: function () {\n *\n * }\n * });\n * ```\n */\n this.open = function (options) {\n\n if (this.status === \"on\") this.close();\n if (options && options.content) setBody.call(this, options.content);\n if (options && typeof options.templateName === \"undefined\") options.templateName = \"defaultMask\";\n self.maskConfig = {};\n\n jQuery.extend(true, self.maskConfig, this.config, options);\n\n var _cfg = self.maskConfig,\n target = _cfg.target,\n $target = jQuery(target),\n maskId = 'ax-mask-' + ax5.getGuid(),\n $mask,\n css = {},\n that = {},\n templateName = _cfg.templateName,\n\n /*\n bodyTmpl = getBodyTmpl(),\n body = ax5.mustache.render(bodyTmpl, {\n theme: _cfg.theme,\n maskId: maskId,\n body: this.maskContent\n });\n */\n body = getBodyTmpl({\n theme: _cfg.theme,\n maskId: maskId,\n body: this.maskContent,\n templateName: templateName\n });\n\n jQuery(document.body).append(body);\n\n // 마스크의 타겟이 html body 가 아니라면\n if (target && target !== jQuery(document.body).get(0)) {\n css = {\n position: _cfg.position || \"absolute\",\n left: $target.offset().left,\n top: $target.offset().top,\n width: $target.outerWidth(),\n height: $target.outerHeight()\n };\n\n if (typeof self.maskConfig.zIndex !== \"undefined\") {\n css[\"z-index\"] = self.maskConfig.zIndex;\n }\n $target.addClass(\"ax-masking\");\n\n // 마스크의 타겟이 html body가 아닌경우 window resize 이벤트를 추적하여 엘리먼트 마스크의 CSS 속성 변경\n jQuery(window).bind(\"resize.ax5mask-\" + this.instanceId, function (_$target) {\n this.align();\n }.bind(this));\n }\n\n this.$mask = $mask = jQuery(\"#\" + maskId);\n this.$target = $target;\n this.status = \"on\";\n $mask.css(css);\n\n if (_cfg.onClick) {\n $mask.on(\"click\", function (e) {\n that = {\n self: self,\n state: \"open\",\n type: \"click\"\n };\n self.maskConfig.onClick.call(that, that);\n });\n }\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"open\"\n });\n\n options = null;\n _cfg = null;\n target = null;\n $target = null;\n maskId = null;\n $mask = null;\n css = null;\n that = null;\n templateName = null;\n body = null;\n\n return this;\n };\n\n /**\n * close mask\n * @method ax5mask.close\n * @param {Number} [_delay=0]\n * @returns {ax5mask}\n * @example\n * ```\n * my_mask.close();\n * ```\n */\n this.close = function (_delay) {\n var _this2 = this;\n\n if (this.$mask) {\n (function () {\n var _close = function _close() {\n this.status = \"off\";\n this.$mask.remove();\n this.$target.removeClass(\"ax-masking\");\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"close\"\n });\n\n jQuery(window).unbind(\"resize.ax5mask-\" + this.instanceId);\n };\n\n if (_delay) {\n setTimeout(function () {\n _close.call(this);\n }.bind(_this2), _delay);\n } else {\n _close.call(_this2);\n }\n })();\n }\n return this;\n };\n\n /**\n * @method ax5mask.fadeOut\n * @returns {ax5mask}\n */\n this.fadeOut = function () {\n var _this3 = this;\n\n if (this.$mask) {\n (function () {\n var _close = function _close() {\n this.status = \"off\";\n this.$mask.remove();\n this.$target.removeClass(\"ax-masking\");\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"close\"\n });\n\n jQuery(window).unbind(\"resize.ax5mask-\" + this.instanceId);\n };\n\n _this3.$mask.addClass(\"fade-out\");\n setTimeout(function () {\n _close.call(this);\n }.bind(_this3), cfg.animateTime);\n })();\n }\n return this;\n };\n\n /**\n * @method ax5mask.align\n * @returns {ax5mask}\n */\n this.align = function () {\n if (this.maskConfig && this.maskConfig.target && this.maskConfig.target !== jQuery(document.body).get(0)) {\n try {\n var css = {\n position: this.maskConfig.position || \"absolute\",\n left: this.$target.offset().left,\n top: this.$target.offset().top,\n width: this.$target.outerWidth(),\n height: this.$target.outerHeight()\n };\n this.$mask.css(css);\n } catch (e) {}\n }\n return this;\n };\n\n this.pullRequest = function () {\n console.log(\"test pullRequest01\");\n console.log(\"test pullRequest02\");\n };\n\n // 클래스 생성자\n this.main = function () {\n\n UI.mask_instance = UI.mask_instance || [];\n UI.mask_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5mask;\n }());\n MASK = ax5.ui.mask;\n})();\n// ax5.ui.mask.tmpl\n(function () {\n\n var MASK = ax5.ui.mask;\n\n var defaultMask = function defaultMask(columnKeys) {\n return '\\n
\\n
\\n
\\n
\\n {{{body}}}\\n
\\n
\\n
\\n ';\n };\n\n MASK.tmpl = {\n \"defaultMask\": defaultMask,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(MASK.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.toast\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var TOAST;\n\n UI.addClass({\n className: \"toast\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5toast\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```\n * ```js\n * var toast = new ax5.ui.toast();\n * toast.setConfig({\n * icon: '
',\n * containerPosition: \"bottom-right\",\n * closeIcon: '
'\n * });\n *\n * toast.onStateChanged = function(){\n * console.log(this);\n * };\n *\n * toast.push({\n * icon: '
',\n * msg:\"999999\"\n * });\n *\n * toast.push({\n * theme: theme,\n * msg: 'toast message'\n * });\n * ```\n */\n var ax5toast = function ax5toast() {\n var self = this,\n cfg,\n toastSeq = 0,\n toastSeqClear = null;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchstart\" : \"click\"),\n theme: 'default',\n width: 300,\n icon: '',\n closeIcon: '',\n msg: '',\n lang: {\n \"ok\": \"ok\", \"cancel\": \"cancel\"\n },\n displayTime: 3000,\n animateTime: 250,\n containerPosition: \"bottom-left\"\n };\n this.toastContainer = null;\n this.queue = [];\n\n cfg = this.config;\n\n var onStateChanged = function onStateChanged(opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n opts = null;\n that = null;\n return true;\n },\n\n /**\n * @method ax5toast.getContent\n * @param {String} toastId\n * @param {Object} opts\n * @returns toastDisplay\n * @example\n * ```js\n * ax5toast.getContent('ax5-toast-3-1', opts);\n * ```\n */\n getContent = function getContent(toastId, opts) {\n\n var data = {\n toastId: toastId,\n theme: opts.theme,\n icon: opts.icon,\n msg: (opts.msg || \"\").replace(/\\n/g, \"
\"),\n btns: opts.btns,\n closeIcon: opts.closeIcon\n };\n\n try {\n return TOAST.tmpl.get.call(this, \"toastDisplay\", data);\n } finally {\n toastId = null;\n data = null;\n }\n },\n\n /**\n * @method ax5toast.open\n * @param opts\n * @param callBack\n * @returns {ax5toast}\n */\n open = function open(opts, callBack) {\n if (toastSeqClear) clearTimeout(toastSeqClear);\n\n var toastBox,\n box = {\n width: opts.width\n };\n\n opts.id = 'ax5-toast-' + self.containerId + '-' + ++toastSeq;\n if (jQuery('#' + opts.id).get(0)) return this;\n\n if (U.left(cfg.containerPosition, '-') == 'bottom') {\n this.toastContainer.append(getContent(opts.id, opts));\n } else {\n this.toastContainer.prepend(getContent(opts.id, opts));\n }\n\n toastBox = jQuery('#' + opts.id);\n toastBox.css({ width: box.width });\n opts.toastBox = toastBox;\n this.queue.push(opts);\n\n onStateChanged.call(this, opts, {\n self: this,\n state: \"open\",\n toastId: opts.id\n });\n\n if (opts.toastType === \"push\") {\n // 자동 제거 타이머 시작\n setTimeout(function () {\n this.close(opts, callBack);\n }.bind(this), cfg.displayTime);\n\n toastBox.find(\"[data-ax-toast-btn]\").on(cfg.clickEventName, function (e) {\n btnOnClick.call(this, e || window.event, opts, toastBox, callBack);\n }.bind(this));\n } else if (opts.toastType === \"confirm\") {\n toastBox.find(\"[data-ax-toast-btn]\").on(cfg.clickEventName, function (e) {\n btnOnClick.call(this, e || window.event, opts, toastBox, callBack);\n }.bind(this));\n }\n\n box = null;\n },\n btnOnClick = function btnOnClick(e, opts, toastBox, callBack, target, k) {\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-ax-toast-btn\")) {\n return true;\n }\n });\n\n if (target) {\n k = target.getAttribute(\"data-ax-toast-btn\");\n\n var that = {\n key: k, value: opts.btns ? opts.btns[k] : k,\n toastId: opts.id,\n btn_target: target\n };\n\n if (opts.btns && opts.btns[k].onClick) {\n opts.btns[k].onClick.call(that, k);\n } else if (opts.toastType === \"push\") {\n if (callBack) callBack.call(that, k);\n this.close(opts, callBack);\n } else if (opts.toastType === \"confirm\") {\n if (callBack) callBack.call(that, k);\n this.close(opts, callBack);\n }\n }\n\n e = null;\n opts = null;\n toastBox = null;\n callBack = null;\n target = null;\n k = null;\n };\n\n /**\n * Preferences of toast UI\n * @method ax5toast.set_config\n * @param {Object} config - 클래스 속성값\n * @returns {ax5toast}\n * @example\n * ```\n * ```\n */\n //== class body start\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n // after set_config();\n self.containerId = ax5.getGuid();\n var styles = [];\n if (cfg.zIndex) {\n styles.push(\"z-index:\" + cfg.zIndex);\n }\n jQuery(document.body).append('
');\n this.toastContainer = jQuery('[data-toast-container=\"' + self.containerId + '\"]');\n };\n\n /**\n * @method ax5toast.push\n * @param opts\n * @param callBack\n * @returns {ax5toast}\n */\n this.push = function (opts, callBack) {\n if (!self.containerId) {\n this.init();\n }\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n };\n }\n opts.toastType = \"push\";\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n\n open.call(this, opts, callBack);\n\n opts = null;\n callBack = null;\n return this;\n };\n\n /**\n * @method ax5toast.confirm\n * @param opts\n * @param callBack\n * @returns {ax5toast}\n */\n this.confirm = function (opts, callBack) {\n if (!self.containerId) {\n this.init();\n }\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n };\n }\n opts.toastType = \"confirm\";\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n\n if (typeof opts.btns === \"undefined\") {\n opts.btns = {\n ok: { label: cfg.lang[\"ok\"], theme: opts.theme }\n };\n }\n open.call(this, opts, callBack);\n\n opts = null;\n callBack = null;\n return this;\n };\n\n /**\n * close the toast\n * @method ax5toast.close\n * @returns {ax5toast}\n * @example\n * ```\n * my_toast.close();\n * ```\n */\n this.close = function (opts, callBack) {\n if (typeof opts === \"undefined\") {\n opts = U.last(this.queue);\n }\n\n var toastBox = opts.toastBox;\n toastBox.addClass(opts.toastType == \"push\" ? \"removed\" : \"destroy\");\n this.queue = U.filter(this.queue, function () {\n return opts.id != this.id;\n });\n setTimeout(function () {\n var that = {\n toastId: opts.id\n };\n\n toastBox.remove();\n if (callBack) callBack.call(that);\n\n that = {\n self: this,\n state: \"close\",\n toastId: opts.id\n };\n onStateChanged.call(this, opts, that);\n\n // 3초후에도 아무 일이 없다면 완전히 제거\n if (this.queue.length === 0) {\n if (toastSeqClear) clearTimeout(toastSeqClear);\n toastSeqClear = setTimeout(function () {\n /// console.log(\"try clear seq\");\n if (this.queue.length === 0) toastSeq = 0;\n }.bind(this), 3000);\n }\n\n that = null;\n opts = null;\n callBack = null;\n toastBox = null;\n }.bind(this), cfg.animateTime);\n\n return this;\n };\n\n // 클래스 생성자\n this.main = function () {\n\n UI.toast_instance = UI.toast_instance || [];\n UI.toast_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5toast;\n }());\n TOAST = ax5.ui.toast;\n})();\n// ax5.ui.toast.tmpl\n(function () {\n\n var TOAST = ax5.ui.toast;\n\n var toastDisplay = function toastDisplay(columnKeys) {\n return '\\n
\\n {{#icon}}\\n
{{{.}}}
\\n {{/icon}}\\n
{{{msg}}}
\\n {{#btns}}\\n
\\n {{/btns}}\\n {{^btns}}\\n
{{{closeIcon}}}\\n {{/btns}}\\n
\\n
';\n };\n\n TOAST.tmpl = {\n \"toastDisplay\": toastDisplay,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(TOAST.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.modal\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var MODAL;\n\n UI.addClass({\n className: \"modal\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5modal\n * @alias ax5.ui.modal\n * @author tom@axisj.com\n * @example\n * ```js\n * var modal = new ax5.ui.modal({\n * iframeLoadingMsg: '
',\n * header: {\n * title: \"MODAL TITLE\",\n * btns: {\n * minimize: {\n * label: '
', onClick: function () {\n * modal.minimize();\n * }\n * },\n * maximize: {\n * label: '
', onClick: function () {\n * modal.maximize();\n * }\n * },\n * close: {\n * label: '
', onClick: function () {\n * modal.close();\n * }\n * }\n * }\n * }\n * });\n *\n * modal.open({\n * width: 800,\n * height: 600,\n * fullScreen: function(){\n * return ($(window).width() < 600);\n * },\n * iframe: {\n * method: \"get\",\n * url: \"http://chequer-app:2017/html/login.html\",\n * param: \"callback=modalCallback\"\n * }\n * });\n * ```\n */\n var ax5modal = function ax5modal() {\n var self = this,\n cfg = void 0,\n ENM = {\n \"mousedown\": ax5.info.supportTouch ? \"touchstart\" : \"mousedown\",\n \"mousemove\": ax5.info.supportTouch ? \"touchmove\" : \"mousemove\",\n \"mouseup\": ax5.info.supportTouch ? \"touchend\" : \"mouseup\"\n },\n getMousePosition = function getMousePosition(e) {\n var mouseObj = e;\n if ('changedTouches' in e) {\n mouseObj = e.changedTouches[0];\n }\n return {\n clientX: mouseObj.clientX,\n clientY: mouseObj.clientY\n };\n };\n\n this.instanceId = ax5.getGuid();\n this.config = {\n id: 'ax5-modal-' + this.instanceId,\n position: {\n left: \"center\",\n top: \"middle\",\n margin: 10\n },\n minimizePosition: \"bottom-right\",\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchstart\" : \"click\"),\n theme: 'default',\n width: 300,\n height: 400,\n closeToEsc: true,\n disableDrag: false,\n animateTime: 250\n };\n this.activeModal = null;\n this.watingModal = false;\n this.$ = {}; // UI inside of the jQuery object store\n\n cfg = this.config; // extended config copy cfg\n\n var onStateChanged = function onStateChanged(opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n return true;\n },\n getContent = function getContent(modalId, opts) {\n var data = {\n modalId: modalId,\n theme: opts.theme,\n header: opts.header,\n fullScreen: opts.fullScreen ? \"fullscreen\" : \"\",\n styles: \"\",\n iframe: opts.iframe,\n iframeLoadingMsg: opts.iframeLoadingMsg\n };\n\n if (opts.zIndex) {\n data.styles += \"z-index:\" + opts.zIndex + \";\";\n }\n if (opts.absolute) {\n data.styles += \"position:absolute;\";\n }\n\n if (data.iframe && typeof data.iframe.param === \"string\") {\n data.iframe.param = ax5.util.param(data.iframe.param);\n }\n\n return MODAL.tmpl.get.call(this, \"content\", data, {});\n },\n open = function open(opts, callback) {\n var that = void 0;\n jQuery(document.body).append(getContent.call(this, opts.id, opts));\n\n this.activeModal = jQuery('#' + opts.id);\n\n // 파트수집\n this.$ = {\n \"root\": this.activeModal,\n \"header\": this.activeModal.find('[data-modal-els=\"header\"]'),\n \"body\": this.activeModal.find('[data-modal-els=\"body\"]')\n };\n\n if (opts.iframe) {\n this.$[\"iframe-wrap\"] = this.activeModal.find('[data-modal-els=\"iframe-wrap\"]');\n this.$[\"iframe\"] = this.activeModal.find('[data-modal-els=\"iframe\"]');\n this.$[\"iframe-form\"] = this.activeModal.find('[data-modal-els=\"iframe-form\"]');\n this.$[\"iframe-loading\"] = this.activeModal.find('[data-modal-els=\"iframe-loading\"]');\n }\n\n //- position 정렬\n this.align();\n\n that = {\n self: this,\n id: opts.id,\n theme: opts.theme,\n width: opts.width,\n height: opts.height,\n state: \"open\",\n $: this.$\n };\n\n if (opts.iframe) {\n this.$[\"iframe-wrap\"].css({ height: opts.height });\n this.$[\"iframe\"].css({ height: opts.height });\n\n // iframe content load\n this.$[\"iframe-form\"].attr({ \"method\": opts.iframe.method });\n this.$[\"iframe-form\"].attr({ \"target\": opts.id + \"-frame\" });\n this.$[\"iframe-form\"].attr({ \"action\": opts.iframe.url });\n this.$[\"iframe\"].on(\"load\", function () {\n that.state = \"load\";\n if (opts.iframeLoadingMsg) {\n this.$[\"iframe-loading\"].hide();\n }\n onStateChanged.call(this, opts, that);\n }.bind(this));\n if (!opts.iframeLoadingMsg) {\n this.$[\"iframe\"].show();\n }\n this.$[\"iframe-form\"].submit();\n }\n\n if (callback) callback.call(that);\n\n if (!this.watingModal) {\n onStateChanged.call(this, opts, that);\n }\n\n // bind key event\n if (opts.closeToEsc) {\n jQuery(window).bind(\"keydown.ax-modal\", function (e) {\n onkeyup.call(this, e || window.event);\n }.bind(this));\n }\n jQuery(window).bind(\"resize.ax-modal\", function (e) {\n this.align(null, e || window.event);\n }.bind(this));\n\n this.activeModal.find(\"[data-modal-header-btn]\").on(cfg.clickEventName, function (e) {\n btnOnClick.call(this, e || window.event, opts);\n }.bind(this));\n\n this.$.header.bind(ENM[\"mousedown\"], function (e) {\n if (opts.isFullScreen) return false;\n\n /// 이벤트 필터링 추가 : 버튼엘리먼트로 부터 발생된 이벤트이면 moveModal 시작하지 않도록 필터링\n var isButton = U.findParentNode(e.target, function (_target) {\n if (_target.getAttribute(\"data-modal-header-btn\")) {\n return true;\n }\n });\n\n if (!isButton && opts.disableDrag != true) {\n self.mousePosition = getMousePosition(e);\n moveModal.on.call(self);\n }\n }).bind(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n },\n btnOnClick = function btnOnClick(e, opts, callback, target, k) {\n var that = void 0;\n if (e.srcElement) e.target = e.srcElement;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-modal-header-btn\")) {\n return true;\n }\n });\n\n if (target) {\n k = target.getAttribute(\"data-modal-header-btn\");\n\n that = {\n self: this,\n key: k, value: opts.header.btns[k],\n dialogId: opts.id,\n btnTarget: target\n };\n\n if (opts.header.btns[k].onClick) {\n opts.header.btns[k].onClick.call(that, k);\n }\n }\n\n that = null;\n opts = null;\n callback = null;\n target = null;\n k = null;\n },\n onkeyup = function onkeyup(e) {\n if (e.keyCode == ax5.info.eventKeys.ESC) {\n this.close();\n }\n },\n alignProcessor = {\n \"top-left\": function topLeft() {\n this.align({ left: \"left\", top: \"top\" });\n },\n \"top-right\": function topRight() {\n this.align({ left: \"right\", top: \"top\" });\n },\n \"bottom-left\": function bottomLeft() {\n this.align({ left: \"left\", top: \"bottom\" });\n },\n \"bottom-right\": function bottomRight() {\n this.align({ left: \"right\", top: \"bottom\" });\n },\n \"center-middle\": function centerMiddle() {\n this.align({ left: \"center\", top: \"middle\" });\n }\n },\n moveModal = {\n \"on\": function on() {\n var modalZIndex = this.activeModal.css(\"z-index\"),\n modalOffset = this.activeModal.position(),\n modalBox = {\n width: this.activeModal.outerWidth(), height: this.activeModal.outerHeight()\n },\n windowBox = {\n width: jQuery(window).width(),\n height: jQuery(window).height()\n },\n getResizerPosition = function getResizerPosition(e) {\n self.__dx = e.clientX - self.mousePosition.clientX;\n self.__dy = e.clientY - self.mousePosition.clientY;\n\n var minX = 0;\n var maxX = windowBox.width - modalBox.width;\n var minY = 0;\n var maxY = windowBox.height - modalBox.height;\n\n if (minX > modalOffset.left + self.__dx) {\n self.__dx = -modalOffset.left;\n } else if (maxX < modalOffset.left + self.__dx) {\n self.__dx = maxX - modalOffset.left;\n }\n\n if (minY > modalOffset.top + self.__dy) {\n self.__dy = -modalOffset.top;\n } else if (maxY < modalOffset.top + self.__dy) {\n self.__dy = maxY - modalOffset.top;\n }\n\n return {\n left: modalOffset.left + self.__dx + $(document).scrollLeft(),\n top: modalOffset.top + self.__dy + $(document).scrollTop()\n };\n };\n\n self.__dx = 0; // 변화량 X\n self.__dy = 0; // 변화량 Y\n\n if (!self.resizer) {\n // self.resizerBg : body 가 window보다 작을 때 문제 해결을 위한 DIV\n self.resizerBg = jQuery('
');\n self.resizer = jQuery('
');\n self.resizerBg.css({ zIndex: modalZIndex });\n self.resizer.css({\n left: modalOffset.left,\n top: modalOffset.top,\n width: modalBox.width,\n height: modalBox.height,\n zIndex: modalZIndex + 1\n });\n jQuery(document.body).append(self.resizerBg).append(self.resizer);\n self.activeModal.addClass(\"draged\");\n }\n\n jQuery(document.body).bind(ENM[\"mousemove\"] + \".ax5modal-\" + cfg.id, function (e) {\n self.resizer.css(getResizerPosition(e));\n }).bind(ENM[\"mouseup\"] + \".ax5layout-\" + this.instanceId, function (e) {\n moveModal.off.call(self);\n }).bind(\"mouseleave.ax5layout-\" + this.instanceId, function (e) {\n moveModal.off.call(self);\n });\n\n jQuery(document.body).attr('unselectable', 'on').css('user-select', 'none').on('selectstart', false);\n },\n \"off\": function off() {\n var setModalPosition = function setModalPosition() {\n var box = this.activeModal.offset();\n box.left += this.__dx - $(document).scrollLeft();\n box.top += this.__dy - $(document).scrollTop();\n this.activeModal.css(box);\n };\n\n if (this.resizer) {\n this.activeModal.removeClass(\"draged\");\n this.resizer.remove();\n this.resizer = null;\n this.resizerBg.remove();\n this.resizerBg = null;\n setModalPosition.call(this);\n //this.align();\n }\n\n jQuery(document.body).unbind(ENM[\"mousemove\"] + \".ax5modal-\" + cfg.id).unbind(ENM[\"mouseup\"] + \".ax5modal-\" + cfg.id).unbind(\"mouseleave.ax5modal-\" + cfg.id);\n\n jQuery(document.body).removeAttr('unselectable').css('user-select', 'auto').off('selectstart');\n }\n };\n\n /// private end\n\n /**\n * Preferences of modal UI\n * @method ax5modal.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Number} [config.zIndex]\n * @param {Boolean} [config.absolute=false]\n * @returns {ax5modal}\n * @example\n * ```\n * ```\n */\n //== class body start\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n };\n\n /**\n * open the modal\n * @method ax5modal.open\n * @returns {ax5modal}\n * @example\n * ```\n * my_modal.open();\n * ```\n */\n this.open = function (opts, callback, tryCount) {\n if (typeof tryCount === \"undefined\") tryCount = 0;\n if (!this.activeModal) {\n opts = self.modalConfig = jQuery.extend(true, {}, cfg, opts);\n open.call(this, opts, callback);\n this.watingModal = false;\n } else if (tryCount < 3) {\n // 3번까지 재 시도\n this.watingModal = true;\n setTimeout(function () {\n this.open(opts, callback, tryCount + 1);\n }.bind(this), cfg.animateTime);\n }\n return this;\n };\n\n /**\n * close the modal\n * @method ax5modal.close\n * @returns {ax5modal}\n * @example\n * ```\n * my_modal.close();\n * ```\n */\n this.close = function (opts) {\n if (this.activeModal) {\n opts = self.modalConfig;\n this.activeModal.addClass(\"destroy\");\n jQuery(window).unbind(\"keydown.ax-modal\");\n jQuery(window).unbind(\"resize.ax-modal\");\n\n setTimeout(function () {\n if (this.activeModal) {\n\n // 프레임 제거\n if (opts.iframe) {\n var $iframe = this.$[\"iframe\"]; // iframe jQuery Object\n if ($iframe) {\n var iframeObject = $iframe.get(0),\n idoc = iframeObject.contentDocument ? iframeObject.contentDocument : iframeObject.contentWindow.document;\n\n try {\n $(idoc.body).children().each(function () {\n $(this).remove();\n });\n } catch (e) {}\n idoc.innerHTML = \"\";\n $iframe.attr('src', 'about:blank').remove();\n\n // force garbarge collection for IE only\n window.CollectGarbage && window.CollectGarbage();\n }\n }\n\n this.activeModal.remove();\n this.activeModal = null;\n }\n // 모달 오픈 대기중이면 닫기 상태 전달 안함.\n if (!this.watingModal) {\n onStateChanged.call(this, opts, {\n self: this,\n state: \"close\"\n });\n }\n }.bind(this), cfg.animateTime);\n }\n\n this.minimized = false; // hoksi\n\n return this;\n };\n\n /**\n * @method ax5modal.minimize\n * @returns {ax5modal}\n */\n this.minimize = function () {\n\n return function (minimizePosition) {\n\n if (this.minimized !== true) {\n\n var opts = self.modalConfig;\n if (typeof minimizePosition === \"undefined\") minimizePosition = cfg.minimizePosition;\n\n this.minimized = true;\n this.$.body.hide();\n self.modalConfig.originalHeight = opts.height;\n self.modalConfig.height = 0;\n alignProcessor[minimizePosition].call(this);\n\n onStateChanged.call(this, opts, {\n self: this,\n state: \"minimize\"\n });\n }\n\n return this;\n };\n }();\n\n /**\n * @method ax5modal.maximize\n * @returns {ax5modal}\n */\n this.maximize = function () {\n var opts = self.modalConfig;\n if (this.minimized) {\n this.minimized = false;\n this.$.body.show();\n self.modalConfig.height = self.modalConfig.originalHeight;\n self.modalConfig.originalHeight = undefined;\n\n this.align({ left: \"center\", top: \"middle\" });\n onStateChanged.call(this, opts, {\n self: this,\n state: \"restore\"\n });\n }\n return this;\n };\n\n /**\n * setCSS\n * @method ax5modal.css\n * @param {Object} css -\n * @returns {ax5modal}\n */\n this.css = function (css) {\n if (this.activeModal && !self.fullScreen) {\n this.activeModal.css(css);\n if (css.width) {\n self.modalConfig.width = this.activeModal.width();\n }\n if (css.height) {\n self.modalConfig.height = this.activeModal.height();\n if (this.$[\"iframe\"]) {\n this.$[\"iframe-wrap\"].css({ height: self.modalConfig.height });\n this.$[\"iframe\"].css({ height: self.modalConfig.height });\n }\n }\n }\n return this;\n };\n\n /**\n * @method ax5modal.setModalConfig\n * @param _config\n * @returns {ax5.ui.ax5modal}\n */\n this.setModalConfig = function (_config) {\n self.modalConfig = jQuery.extend({}, self.modalConfig, _config);\n this.align();\n return this;\n };\n\n /**\n * @method ax5modal.align\n * @param position\n * @param e\n * @returns {ax5modal}\n */\n this.align = function () {\n\n return function (position, e) {\n if (!this.activeModal) return this;\n\n var opts = self.modalConfig,\n box = {\n width: opts.width,\n height: opts.height\n };\n\n var fullScreen = opts.isFullScreen = function (_fullScreen) {\n if (typeof _fullScreen === \"undefined\") {\n return false;\n } else if (U.isFunction(_fullScreen)) {\n return _fullScreen();\n }\n }(opts.fullScreen);\n\n if (fullScreen) {\n if (opts.header) this.$.header.show();\n box.width = jQuery(window).width();\n box.height = opts.height;\n box.left = 0;\n box.top = 0;\n } else {\n if (opts.header) this.$.header.show();\n if (position) {\n jQuery.extend(true, opts.position, position);\n }\n\n if (opts.header) {\n opts.headerHeight = this.$.header.outerHeight();\n box.height += opts.headerHeight;\n } else {\n opts.headerHeight = 0;\n }\n\n //- position 정렬\n if (opts.position.left == \"left\") {\n box.left = opts.position.margin || 0;\n } else if (opts.position.left == \"right\") {\n // window.innerWidth;\n box.left = jQuery(window).width() - box.width - (opts.position.margin || 0);\n } else if (opts.position.left == \"center\") {\n box.left = jQuery(window).width() / 2 - box.width / 2;\n } else {\n box.left = opts.position.left || 0;\n }\n\n if (opts.position.top == \"top\") {\n box.top = opts.position.margin || 0;\n } else if (opts.position.top == \"bottom\") {\n box.top = jQuery(window).height() - box.height - (opts.position.margin || 0);\n } else if (opts.position.top == \"middle\") {\n box.top = jQuery(window).height() / 2 - box.height / 2;\n } else {\n box.top = opts.position.top || 0;\n }\n if (box.left < 0) box.left = 0;\n if (box.top < 0) box.top = 0;\n }\n\n this.activeModal.css(box);\n\n if (opts.iframe) {\n this.$[\"iframe-wrap\"].css({ height: box.height - opts.headerHeight });\n this.$[\"iframe\"].css({ height: box.height - opts.headerHeight });\n }\n return this;\n };\n }();\n\n // 클래스 생성자\n this.main = function () {\n\n UI.modal_instance = UI.modal_instance || [];\n UI.modal_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5modal;\n }());\n\n MODAL = ax5.ui.modal;\n})();\n\n// ax5.ui.modal.tmpl\n(function () {\n var MODAL = ax5.ui.modal;\n\n var content = function content() {\n return ' \\n
\\n {{#header}}\\n \\n {{/header}}\\n
\\n {{#iframe}}\\n \\n
\\n
\\n {{/iframe}}\\n
\\n
\\n
\\n ';\n };\n\n MODAL.tmpl = {\n \"content\": content,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(MODAL.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.calendar\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var CALENDAR;\n\n UI.addClass({\n className: \"calendar\",\n version: \"1.3.66\"\n }, function () {\n\n /**\n * @class ax5calendar\n * @classdesc\n * @author tom@axisj.com\n * @logs\n * 2014-06-21 tom : 시작\n * @example\n * ```js\n * ax5.info.months = [\"1월\",\"2월\",\"3월\",\"4월\",\"5월\",\"6월\",\"7월\",\"8월\",\"9월\",\"10월\",\"11월\"];\n * ax5.info.weekNames = [\n * {label: \"일\"},\n * {label: \"월\"},\n * {label: \"화\"},\n * {label: \"수\"},\n * {label: \"목\"},\n * {label: \"금\"},\n * {label: \"토\"}\n * ];\n *\n * var myCalendar = new ax5.ui.calendar({\n * control: {\n * left: '≪',\n * yearTmpl: '%s',\n * monthTmpl: '%s',\n * right: '≫',\n * yearFirst: true\n * },\n *\n * dimensions: {\n * itemPadding: 1,\n * height: 200\n * },\n *\n * target: document.getElementById(\"calendar-target\"),\n * displayDate: (new Date()),\n * mode: \"day\",\n * selectMode: \"day\",\n *\n * marker: (function () {\n * var marker = {};\n * marker[_c_date(today, {'return': 'yyyy-MM-dd', 'add': {d: -1}})] = true;\n * marker[_c_date(today, {'return': 'yyyy-MM-dd', 'add': {d: 0}})] = true;\n * marker[_c_date(today, {'return': 'yyyy-MM-dd', 'add': {d: 1}})] = true;\n *\n * return marker;\n * })(),\n * onClick: function () {\n * console.log(myCalendar.getSelection());\n * },\n * onStateChanged: function () {\n * console.log(this);\n * }\n * , multipleSelect: 2\n * });\n * ```\n */\n var ax5calendar = function ax5calendar() {\n var self = this,\n cfg,\n selectableCount = 1;\n\n this.instanceId = ax5.getGuid();\n this.target = null;\n this.selection = [];\n this.selectionMap = {};\n this.selectableMap = {};\n this.markerMap = {};\n this.printedDay = {\n start: \"\", end: \"\"\n };\n this.config = {\n clickEventName: \"click\",\n theme: 'default',\n startOfWeek: 0,\n mode: 'day', // day|month|year,\n dateFormat: 'yyyy-MM-dd',\n displayDate: new Date(),\n animateTime: 100,\n dimensions: {\n controlHeight: '40',\n controlButtonWidth: '40',\n colHeadHeight: '30',\n itemPadding: 2\n },\n lang: {\n yearHeading: \"Choose the year\",\n monthHeading: \"Choose the month\",\n yearTmpl: \"%s\",\n months: ax5.info.months || ['JAN', 'FEB', 'MAR', 'APR', 'MAY', 'JUN', 'JUL', 'AUG', 'SEP', 'OCT', 'NOV', 'DEC'],\n dayTmpl: \"%s\"\n },\n multipleSelect: false,\n selectMode: 'day',\n defaultMarkerTheme: 'holiday',\n defaultPeriodTheme: 'period'\n };\n\n cfg = this.config;\n\n var onStateChanged = function onStateChanged(opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n that = null;\n },\n getFrame = function getFrame() {\n var data = jQuery.extend(true, {}, cfg, {\n controlCSS: {},\n controlButtonCSS: {}\n });\n\n data.controlButtonCSS[\"height\"] = data.controlCSS[\"height\"] = U.cssNumber(cfg.dimensions.controlHeight);\n data.controlButtonCSS[\"line-height\"] = data.controlCSS[\"line-height\"] = U.cssNumber(cfg.dimensions.controlHeight);\n data.controlButtonCSS[\"width\"] = U.cssNumber(cfg.dimensions.controlHeight);\n\n data.controlCSS = U.css(data.controlCSS);\n data.controlButtonCSS = U.css(data.controlButtonCSS);\n\n try {\n return CALENDAR.tmpl.get.call(this, \"frameTmpl\", data);\n } finally {\n data = null;\n }\n },\n setDisplay = function setDisplay() {\n var myDate = U.date(cfg.displayDate),\n yy = \"\",\n mm = \"\",\n yy1,\n yy2;\n\n if (cfg.control) {\n if (cfg.mode == \"day\" || cfg.mode == \"d\") {\n yy = cfg.control.yearTmpl ? cfg.control.yearTmpl.replace('%s', myDate.getFullYear()) : myDate.getFullYear();\n mm = cfg.control.monthTmpl ? cfg.control.monthTmpl.replace('%s', cfg.lang.months[myDate.getMonth()]) : cfg.lang.months[myDate.getMonth()];\n\n this.$[\"control-display\"].html(function () {\n if (cfg.control.yearFirst) {\n return '
' + yy + '' + '
' + mm + '';\n } else {\n return '
' + mm + '' + '
' + yy + '';\n }\n }());\n } else if (cfg.mode == \"month\" || cfg.mode == \"m\") {\n yy = cfg.control.yearTmpl ? cfg.control.yearTmpl.replace('%s', myDate.getFullYear()) : myDate.getFullYear();\n this.$[\"control-display\"].html('
' + yy + '');\n } else if (cfg.mode == \"year\" || cfg.mode == \"y\") {\n yy1 = cfg.control.yearTmpl ? cfg.control.yearTmpl.replace('%s', myDate.getFullYear() - 10) : myDate.getFullYear() - 10;\n yy2 = cfg.control.yearTmpl ? cfg.control.yearTmpl.replace('%s', Number(myDate.getFullYear()) + 9) : Number(myDate.getFullYear()) + 9;\n this.$[\"control-display\"].html(yy1 + ' ~ ' + yy2);\n }\n\n this.$[\"control-display\"].find('[data-calendar-display]').on(cfg.clickEventName, function (e) {\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-calendar-display\")) {\n return true;\n }\n }),\n mode;\n if (target) {\n mode = target.getAttribute(\"data-calendar-display\");\n this.changeMode(mode);\n }\n target = null;\n mode = null;\n }.bind(this));\n }\n\n myDate = null;\n yy = null;\n mm = null;\n yy1 = null;\n yy2 = null;\n return this;\n },\n printDay = function printDay(nowDate) {\n var dotDate = U.date(nowDate),\n monthStratDate = new Date(dotDate.getFullYear(), dotDate.getMonth(), 1, 12),\n _today = cfg.displayDate,\n tableStartDate = function () {\n var day = monthStratDate.getDay();\n if (day == 0) day = 7;\n day -= cfg.startOfWeek;\n\n try {\n return U.date(monthStratDate, { add: { d: -day } });\n } finally {\n day = null;\n }\n }(),\n loopDate,\n thisMonth = dotDate.getMonth(),\n itemStyles = {},\n i,\n k,\n _k,\n frameWidth = this.$[\"body\"].width(),\n frameHeight = Math.floor(frameWidth * (6 / 7)),\n // 1week = 7days, 1month = 6weeks\n data,\n tmpl;\n\n if (cfg.dimensions.height) {\n frameHeight = U.number(cfg.dimensions.height) - U.number(cfg.dimensions.colHeadHeight);\n }\n\n itemStyles['height'] = Math.floor(frameHeight / 6) - U.number(cfg.dimensions.itemPadding) * 2 + 'px';\n itemStyles['line-height'] = itemStyles['height'];\n itemStyles['padding'] = U.cssNumber(cfg.dimensions.itemPadding);\n\n data = {\n weekNames: [].concat(ax5.info.weekNames),\n list: []\n };\n\n if (cfg.startOfWeek) {\n data.weekNames = data.weekNames.concat(data.weekNames.slice(0, cfg.startOfWeek)).splice(cfg.startOfWeek);\n }\n\n data.weekNames.forEach(function (n) {\n n.colHeadHeight = U.cssNumber(cfg.dimensions.colHeadHeight);\n });\n\n loopDate = tableStartDate;\n i = 0;\n while (i < 6) {\n k = 0;\n while (k < 7) {\n _k = (7 + (k - cfg.startOfWeek)) % 7;\n var thisDate = '' + U.date(loopDate, { \"return\": cfg.dateFormat }),\n _date = {\n 'row': i,\n 'col': k,\n isStartOfWeek: k == 0,\n thisDate: '' + thisDate,\n thisDataLabel: cfg.lang.dayTmpl.replace('%s', loopDate.getDate()),\n itemStyles: U.css(itemStyles),\n addClass: function () {\n\n var classNames = \"\";\n\n if (cfg.selectable) {\n if (self.selectableMap[thisDate]) {\n classNames += loopDate.getMonth() == thisMonth ? \" live\" : \"\";\n } else {\n classNames += \" disable\";\n }\n } else {\n if (loopDate.getMonth() == thisMonth) {\n if (thisDate == U.date(_today, { \"return\": \"yyyyMMdd\" })) {\n classNames += \" focus\";\n } else {\n classNames += \" live\";\n }\n\n if (loopDate.getDay() == 0) {\n classNames += \" sunday\";\n }\n if (loopDate.getDay() == 6) {\n classNames += \" saturday\";\n }\n }\n }\n\n return classNames;\n }() + ' ' + function () {\n return self.markerMap[thisDate] ? self.markerMap[thisDate].theme || cfg.defaultMarkerTheme : '';\n }() + ' ' + function () {\n return self.selectionMap[thisDate] ? \"selected-day\" : '';\n }()\n };\n data.list.push(_date);\n\n k++;\n loopDate = U.date(loopDate, { add: { d: 1 } });\n\n thisDate = null;\n _date = null;\n }\n i++;\n }\n tmpl = CALENDAR.tmpl.get.call(this, \"dayTmpl\", data);\n this.$[\"body\"].html(tmpl);\n this.$[\"body\"].find('[data-calendar-item-date]').on(cfg.clickEventName, function (e) {\n e = e || window.event;\n onclick.call(self, e, 'date');\n U.stopEvent(e);\n });\n\n this.printedDay = {\n start: tableStartDate, end: loopDate\n };\n\n onStateChanged.call(this, null, {\n self: this,\n action: \"printDay\",\n printedDay: this.printedDay\n });\n setDisplay.call(this);\n\n dotDate = null;\n monthStratDate = null;\n _today = null;\n tableStartDate = null;\n loopDate = null;\n thisMonth = null;\n itemStyles = null;\n i = null;\n k = null;\n frameWidth = null;\n frameHeight = null;\n data = null;\n tmpl = null;\n },\n printMonth = function printMonth(nowDate) {\n var dotDate = U.date(nowDate),\n nMonth = dotDate.getMonth(),\n itemStyles = {},\n i,\n k,\n m,\n tableStartMonth,\n frameWidth = this.$[\"body\"].width(),\n frameHeight = Math.floor(frameWidth * (6 / 7)),\n data,\n tmpl;\n\n if (cfg.dimensions.height) {\n frameHeight = U.number(cfg.dimensions.height) - U.number(cfg.dimensions.colHeadHeight);\n }\n\n itemStyles['height'] = Math.floor(frameHeight / 4) - U.number(cfg.dimensions.itemPadding) * 2 + 'px';\n itemStyles['line-height'] = itemStyles['height'];\n itemStyles['padding'] = U.cssNumber(cfg.dimensions.itemPadding);\n\n data = {\n colHeadHeight: U.cssNumber(cfg.dimensions.colHeadHeight),\n colHeadLabel: cfg.lang.monthHeading,\n list: []\n };\n\n tableStartMonth = 0;\n m = 0;\n i = 0;\n while (i < 4) {\n k = 0;\n while (k < 3) {\n var _month = {\n row: i,\n col: k,\n isStartOfRow: k == 0,\n thisMonth: dotDate.getFullYear() + '-' + U.setDigit(m + 1, 2) + '-' + U.setDigit(dotDate.getDate(), 2),\n thisMonthLabel: cfg.lang.months[m],\n itemStyles: U.css(itemStyles),\n addClass: function () {\n if (cfg.selectable) {\n return self.selectableMap[m] ? 'live' : 'disable';\n } else {\n return 'live';\n }\n }() + ' ' + function () {\n return m == nMonth ? \"focus\" : \"\";\n }() + ' ' + function () {\n return self.markerMap[m] ? self.markerMap[m].theme || cfg.defaultMarkerTheme : '';\n }()\n };\n data.list.push(_month);\n m++;\n k++;\n _month = null;\n }\n i++;\n }\n tmpl = CALENDAR.tmpl.get.call(this, \"monthTmpl\", data);\n this.$[\"body\"].html(tmpl);\n this.$[\"body\"].find('[data-calendar-item-month]').on(cfg.clickEventName, function (e) {\n e = e || window.event;\n onclick.call(self, e, 'month');\n U.stopEvent(e);\n });\n\n this.printedDay = {\n start: dotDate.getFullYear() + '-' + U.setDigit(tableStartMonth + 1, 2),\n end: dotDate.getFullYear() + '-' + U.setDigit(m, 2)\n };\n\n onStateChanged.call(this, null, {\n self: this,\n action: \"printMonth\",\n printedDay: this.printedDay\n });\n setDisplay.call(this);\n\n dotDate = null;\n nMonth = null;\n itemStyles = null;\n i = null;\n k = null;\n m = null;\n tableStartMonth = null;\n frameWidth = null;\n frameHeight = null;\n data = null;\n tmpl = null;\n },\n printYear = function printYear(nowDate) {\n var dotDate = U.date(nowDate),\n nYear = dotDate.getFullYear(),\n itemStyles = {},\n i,\n k,\n y,\n tableStartYear,\n frameWidth = this.$[\"body\"].width(),\n frameHeight = Math.floor(frameWidth * (6 / 7)),\n data,\n tmpl;\n\n if (cfg.dimensions.height) {\n frameHeight = U.number(cfg.dimensions.height) - U.number(cfg.dimensions.colHeadHeight);\n }\n\n itemStyles['height'] = Math.floor(frameHeight / 5) - U.number(cfg.dimensions.itemPadding) * 2 + 'px';\n itemStyles['line-height'] = itemStyles['height'];\n itemStyles['padding'] = U.cssNumber(cfg.dimensions.itemPadding);\n\n data = {\n colHeadHeight: U.cssNumber(cfg.dimensions.colHeadHeight),\n colHeadLabel: cfg.lang.yearHeading,\n list: []\n };\n\n tableStartYear = nYear - 10;\n y = nYear - 10;\n i = 0;\n while (i < 5) {\n k = 0;\n while (k < 4) {\n var _year = {\n row: i,\n col: k,\n isStartOfRow: k == 0,\n thisYear: y + '-' + U.setDigit(dotDate.getMonth() + 1, 2) + '-' + U.setDigit(dotDate.getDate(), 2),\n thisYearLabel: cfg.lang.yearTmpl.replace('%s', y),\n itemStyles: U.css(itemStyles),\n addClass: function () {\n if (cfg.selectable) {\n return self.selectableMap[y] ? 'live' : 'disable';\n } else {\n return 'live';\n }\n }() + ' ' + function () {\n return y == nYear ? \"focus\" : \"\";\n }() + ' ' + function () {\n return self.selectableMap[y] ? self.selectableMap[y].theme || cfg.defaultMarkerTheme : '';\n }()\n };\n data.list.push(_year);\n y++;\n k++;\n _year = null;\n }\n i++;\n }\n tmpl = CALENDAR.tmpl.get.call(this, \"yearTmpl\", data);\n this.$[\"body\"].html(tmpl);\n this.$[\"body\"].find('[data-calendar-item-year]').on(cfg.clickEventName, function (e) {\n e = e || window.event;\n onclick.call(this, e, 'year');\n U.stopEvent(e);\n });\n\n this.printedDay = {\n start: tableStartYear, end: y - 1\n };\n\n onStateChanged.call(this, null, {\n self: this,\n action: \"printYear\",\n printedDay: this.printedDay\n });\n setDisplay.call(this);\n\n dotDate = null;\n nYear = null;\n itemStyles = null;\n i = null;\n k = null;\n y = null;\n tableStartYear = null;\n frameWidth = null;\n frameHeight = null;\n data = null;\n tmpl = null;\n },\n onclick = function onclick(e, mode, target, value) {\n var removed, dt, selectable;\n\n mode = mode || \"date\";\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-calendar-item-\" + mode)) {\n return true;\n }\n });\n if (target) {\n value = target.getAttribute(\"data-calendar-item-\" + mode);\n\n dt = U.date(value, { \"return\": cfg.dateFormat });\n selectable = true;\n selectableCount = cfg.multipleSelect ? U.isNumber(cfg.multipleSelect) ? cfg.multipleSelect : 2 : 1;\n\n if (cfg.selectable) {\n if (!self.selectableMap[dt]) selectable = false;\n }\n\n if (mode == \"date\") {\n if (selectable) {\n\n if (self.selection.length >= selectableCount) {\n removed = self.selection.splice(0, self.selection.length - (selectableCount - 1));\n removed.forEach(function (d) {\n self.$[\"body\"].find('[data-calendar-item-date=\"' + U.date(d, { \"return\": cfg.dateFormat }) + '\"]').removeClass(\"selected-day\");\n });\n }\n\n jQuery(target).addClass(\"selected-day\");\n self.selection.push(value);\n\n if (self.onClick) {\n self.onClick.call({\n self: this, date: value, target: this.target, dateElement: target\n });\n }\n }\n } else if (mode == \"month\") {\n if (cfg.selectMode == \"month\") {\n if (selectable) {\n if (self.selection.length >= selectableCount) {\n removed = self.selection.splice(0, self.selection.length - (selectableCount - 1));\n removed.forEach(function (d) {\n self.$[\"body\"].find('[data-calendar-item-month=\"' + U.date(d, { \"return\": 'yyyy-MM-dd' }) + '\"]').removeClass(\"selected-month\");\n });\n }\n\n jQuery(target).addClass(\"selected-month\");\n self.selection.push(value);\n\n if (self.onClick) {\n self.onClick.call({\n self: this, date: value, target: this.target, dateElement: target\n });\n }\n }\n } else {\n self.changeMode(\"day\", value);\n }\n } else if (mode == \"year\") {\n if (cfg.selectMode == \"year\") {\n if (selectable) {\n if (self.selection.length >= selectableCount) {\n removed = self.selection.splice(0, self.selection.length - (selectableCount - 1));\n removed.forEach(function (d) {\n self.$[\"body\"].find('[data-calendar-item-year=\"' + U.date(d, { \"return\": 'yyyy-MM-dd' }) + '\"]').removeClass(\"selected-year\");\n });\n }\n\n jQuery(target).addClass(\"selected-year\");\n self.selection.push(value);\n\n if (self.onClick) {\n self.onClick.call({\n self: this, date: value, target: this.target, dateElement: target\n });\n }\n }\n } else {\n self.changeMode(\"month\", value);\n }\n }\n }\n\n mode = null;\n target = null;\n value = null;\n removed = null;\n dt = null;\n selectable = null;\n },\n move = function move(e, target, value) {\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-calendar-move\")) {\n return true;\n }\n });\n if (target) {\n value = target.getAttribute(\"data-calendar-move\");\n if (cfg.mode == \"day\" || cfg.mode == \"d\") {\n if (value == \"left\") {\n cfg.displayDate = U.date(cfg.displayDate, { add: { m: -1 } });\n } else {\n cfg.displayDate = U.date(cfg.displayDate, { add: { m: 1 } });\n }\n printDay.call(this, cfg.displayDate);\n } else if (cfg.mode == \"month\" || cfg.mode == \"m\") {\n if (value == \"left\") {\n cfg.displayDate = U.date(cfg.displayDate, { add: { y: -1 } });\n } else {\n cfg.displayDate = U.date(cfg.displayDate, { add: { y: 1 } });\n }\n printMonth.call(this, cfg.displayDate);\n } else if (cfg.mode == \"year\" || cfg.mode == \"y\") {\n if (value == \"left\") {\n cfg.displayDate = U.date(cfg.displayDate, { add: { y: -10 } });\n } else {\n cfg.displayDate = U.date(cfg.displayDate, { add: { y: 10 } });\n }\n printYear.call(this, cfg.displayDate);\n }\n }\n\n target = null;\n value = null;\n },\n applyMarkerMap = function applyMarkerMap() {\n setTimeout(function () {\n if (cfg.mode === \"day\" || cfg.mode === \"d\") {\n for (var k in this.markerMap) {\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').addClass(this.markerMap[k].theme || cfg.defaultMarkerTheme);\n }\n }\n }.bind(this));\n },\n applySelectionMap = function applySelectionMap() {\n setTimeout(function () {\n for (var k in this.selectionMap) {\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').addClass(\"selected-day\");\n }\n }.bind(this));\n },\n applyPeriodMap = function applyPeriodMap() {\n setTimeout(function () {\n if (cfg.mode === \"day\" || cfg.mode === \"d\") {\n for (var k in this.periodMap) {\n if (this.periodMap[k].label) {\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').find(\".addon-footer\").html(this.periodMap[k].label);\n }\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').addClass(this.periodMap[k].theme);\n }\n }\n }.bind(this));\n },\n clearPeriodMap = function clearPeriodMap() {\n if (cfg.mode === \"day\" || cfg.mode === \"d\") {\n for (var k in this.periodMap) {\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').find(\".addon-footer\").empty();\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').removeClass(this.periodMap[k].theme);\n }\n }\n };\n\n /**\n * Preferences of calendar UI\n * @method ax5calendar.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Element|nodelist} config.target\n * @param {String} [config.mode=day|month|year]\n * @param {Function} [config.onClick}\n * @returns {ax5calendar}\n * @example\n * ```js\n * var myCalendar = new ax5.ui.calendar();\n * myCalendar.setConfig({\n * target: $(\"#target\"),\n * mode: \"day\"\n * });\n * ```\n */\n //== class body start\n this.init = function () {\n // after setConfig();\n\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n\n if (!cfg.target) {\n console.log(ax5.info.getError(\"ax5calendar\", \"401\", \"setConfig\"));\n }\n this.target = jQuery(cfg.target);\n\n cfg.displayDate = U.date(cfg.displayDate);\n this.target.html(getFrame.call(this));\n\n // 파트수집\n this.$ = {\n \"root\": this.target.find('[data-calendar-els=\"root\"]'),\n \"control\": this.target.find('[data-calendar-els=\"control\"]'),\n \"control-display\": this.target.find('[data-calendar-els=\"control-display\"]'),\n \"body\": this.target.find('[data-calendar-els=\"body\"]')\n };\n\n if (cfg.control) {\n this.$[\"root\"].on(cfg.clickEventName, '[data-calendar-move]', function (e) {\n move.call(this, e || window.event);\n }.bind(this));\n }\n\n // collect selectableMap\n if (cfg.selection) {\n this.setSelection(cfg.selection, false);\n }\n // collect selectableMap\n if (cfg.selectable) {\n this.setSelectable(cfg.selectable, false);\n }\n // collect markerMap\n if (cfg.marker) {\n this.setMarker(cfg.marker, false);\n }\n\n setTimeout(function () {\n if (cfg.mode === \"day\" || cfg.mode === \"d\") {\n printDay.call(this, cfg.displayDate);\n } else if (cfg.mode === \"month\" || cfg.mode === \"m\") {\n printMonth.call(this, cfg.displayDate);\n } else if (cfg.mode === \"year\" || cfg.mode === \"y\") {\n printYear.call(this, cfg.displayDate);\n }\n }.bind(this));\n };\n\n /**\n * @method ax5calendar.changeMode\n * @param {String} mode\n * @param {String} changeDate\n * @returns {ax5calendar}\n */\n this.changeMode = function (mode, changeDate) {\n if (typeof changeDate != \"undefined\") cfg.displayDate = changeDate;\n if (mode) cfg.mode = mode;\n\n this.$[\"body\"].removeClass(\"fadein\").addClass(\"fadeout\");\n setTimeout(function () {\n if (cfg.mode == \"day\" || cfg.mode == \"d\") {\n printDay.call(this, cfg.displayDate);\n } else if (cfg.mode == \"month\" || cfg.mode == \"m\") {\n printMonth.call(this, cfg.displayDate);\n } else if (cfg.mode == \"year\" || cfg.mode == \"y\") {\n printYear.call(this, cfg.displayDate);\n }\n this.$[\"body\"].removeClass(\"fadeout\").addClass(\"fadein\");\n }.bind(this), cfg.animateTime);\n\n return this;\n };\n\n /**\n * @method ax5calendar.setSelection\n * @param {Array} selection\n * @returns {ax5calendar}\n * @example\n * ```\n *\n * ```\n */\n this.setSelection = function () {\n self.selectionMap = {};\n var processor = {\n 'arr': function arr(v, map, count) {\n map = {};\n if (!U.isArray(v)) return map;\n self.selection = v = v.splice(0, count);\n v.forEach(function (n) {\n if (U.isDate(n)) n = U.date(n, { 'return': cfg.dateFormat });\n map[n] = true;\n });\n return map;\n }\n };\n\n return function (selection, isPrint) {\n var result = {};\n selectableCount = cfg.multipleSelect ? U.isNumber(cfg.multipleSelect) ? cfg.multipleSelect : 2 : 1;\n\n if (cfg.selection = selection) {\n if (U.isArray(selection)) {\n result = processor.arr(selection, {}, selectableCount);\n } else {\n return this;\n }\n }\n\n this.selectionMap = jQuery.extend({}, result);\n // 변경내용 적용하여 출력\n\n if (isPrint !== false) applySelectionMap.call(this);\n\n result = null;\n\n return this;\n };\n }();\n\n /**\n * @method ax5calendar.getSelection\n */\n this.getSelection = function () {\n return this.selection;\n };\n\n /**\n * @method ax5calendar.setSelectable\n */\n this.setSelectable = function () {\n self.selectableMap = {};\n var processor = {\n 'arr': function arr(v, map) {\n map = {};\n if (!U.isArray(v)) return map;\n v.forEach(function (n) {\n if (U.isDate(n)) n = U.date(n, { 'return': cfg.dateFormat });\n map[n] = true;\n });\n return map;\n },\n 'obj': function obj(v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (v.range) return map;\n for (var k in v) {\n map[k] = v[k];\n }\n return map;\n },\n 'range': function range(v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (!v.range) return map;\n\n v.range.forEach(function (n) {\n if (U.isDateFormat(n.from) && U.isDateFormat(n.to)) {\n for (var d = U.date(n.from); d <= U.date(n.to); d.setDate(d.getDate() + 1)) {\n map[U.date(d, { \"return\": cfg.dateFormat })] = true;\n }\n } else {\n for (var i = n.from; i <= n.to; i++) {\n map[i] = true;\n }\n }\n });\n\n return map;\n }\n };\n\n return function (selectable, isPrint) {\n\n var key,\n result = {};\n\n if (cfg.selectable = selectable) {\n if (U.isArray(selectable)) {\n result = processor.arr(selectable);\n } else {\n for (key in processor) {\n if (selectable[key]) {\n result = processor[key](selectable);\n break;\n }\n }\n if (Object.keys(result).length === 0) {\n result = processor.obj(selectable);\n }\n }\n }\n\n this.selectableMap = result;\n // 변경내용 적용하여 출력\n if (isPrint !== false) this.changeMode();\n\n return this;\n };\n }();\n\n /**\n * @method ax5calendar.setMarker\n */\n this.setMarker = function () {\n self.markerMap = {};\n var processor = {\n 'obj': function obj(v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (v.range) return map;\n for (var k in v) {\n map[k] = v[k];\n }\n\n v = null;\n return map;\n },\n 'range': function range(v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (!v.range) return map;\n\n v.range.forEach(function (n) {\n if (U.isDateFormat(n.from) && U.isDateFormat(n.to)) {\n for (var d = U.date(n.from); d <= U.date(n.to); d.setDate(d.getDate() + 1)) {\n map[U.date(d, { \"return\": cfg.dateFormat })] = { theme: n.theme, label: n.label };\n }\n } else {\n for (var i = n.from; i <= n.to; i++) {\n map[i] = { theme: n.theme, label: n.label };\n }\n }\n });\n\n v = null;\n return map;\n }\n };\n\n return function (marker, isApply) {\n\n var key,\n result = {};\n\n if (cfg.marker = marker) {\n for (key in processor) {\n if (marker[key]) {\n result = processor[key](marker);\n break;\n }\n }\n if (Object.keys(result).length === 0) {\n result = processor.obj(marker);\n }\n }\n\n this.markerMap = result;\n // 변경내용 적용하여 출력\n if (isApply !== false) applyMarkerMap.call(this);\n return this;\n };\n }();\n\n /**\n * @method ax5calendar.setPeriod\n */\n this.setPeriod = function () {\n self.periodMap = {};\n\n var processor = {\n 'range': function range(v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (!v.range) return map;\n\n v.range.forEach(function (n) {\n if (U.isDateFormat(n.from) && U.isDateFormat(n.to)) {\n for (var d = new Date(U.date(n.from)); d <= U.date(n.to); d.setDate(d.getDate() + 1)) {\n if (d.getTime() == U.date(n.from).getTime()) {\n map[U.date(d, { \"return\": cfg.dateFormat })] = { theme: n.theme || cfg.defaultPeriodTheme, label: n.fromLabel };\n } else if (d.getTime() == U.date(n.to).getTime()) {\n map[U.date(d, { \"return\": cfg.dateFormat })] = { theme: n.theme || cfg.defaultPeriodTheme, label: n.toLabel };\n } else {\n map[U.date(d, { \"return\": cfg.dateFormat })] = { theme: n.theme || cfg.defaultPeriodTheme };\n }\n }\n }\n });\n\n v = null;\n return map;\n }\n };\n\n return function (period, isApply) {\n\n var key,\n result = {};\n\n // 변경내용 적용하여 출력\n if (isApply !== false) {\n clearPeriodMap.call(this);\n }\n\n if (cfg.period = period) {\n result = processor.range(period);\n }\n\n this.periodMap = result;\n\n //console.log(this.periodMap);\n\n // 변경내용 적용하여 출력\n if (isApply !== false) {\n applyPeriodMap.call(this);\n }\n return this;\n };\n }();\n\n // 클래스 생성자\n this.main = function () {\n\n UI.calendar_instance = UI.calendar_instance || [];\n UI.calendar_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5calendar;\n }());\n CALENDAR = ax5.ui.calendar;\n})();\n// ax5.ui.calendar.tmpl\n(function () {\n\n var CALENDAR = ax5.ui.calendar;\n\n var frameTmpl = function frameTmpl(columnKeys) {\n return '\\n
\\n {{#control}}\\n
\\n {{/control}}\\n
\\n
\\n ';\n };\n var dayTmpl = function dayTmpl(columnKeys) {\n return '\\n
\\n \\n \\n {{#weekNames}}\\n \\n {{label}}\\n | \\n {{/weekNames}}\\n
\\n \\n \\n \\n {{#list}} \\n {{#isStartOfWeek}}\\n {{^@first}}\\n
\\n \\n {{/@first}}\\n {{/isStartOfWeek}}\\n \\n \\n \\n {{thisDataLabel}}\\n \\n \\n | \\n {{/list}}\\n
\\n \\n
\\n ';\n };\n var monthTmpl = function monthTmpl(columnKeys) {\n return '\\n
\\n \\n \\n \\n {{colHeadLabel}}\\n | \\n
\\n \\n \\n \\n {{#list}} \\n {{#isStartOfRow}}\\n {{^@first}}\\n
\\n \\n {{/@first}}\\n {{/isStartOfRow}}\\n \\n \\n \\n {{thisMonthLabel}}\\n \\n \\n | \\n {{/list}}\\n
\\n \\n
\\n ';\n };\n var yearTmpl = function yearTmpl(columnKeys) {\n return '\\n
\\n \\n \\n \\n {{colHeadLabel}}\\n | \\n
\\n \\n \\n \\n {{#list}} \\n {{#isStartOfRow}}\\n {{^@first}}\\n
\\n \\n {{/@first}}\\n {{/isStartOfRow}}\\n \\n \\n \\n {{thisYearLabel}}\\n \\n \\n | \\n {{/list}}\\n
\\n \\n
\\n ';\n };\n\n CALENDAR.tmpl = {\n \"frameTmpl\": frameTmpl,\n \"dayTmpl\": dayTmpl,\n \"monthTmpl\": monthTmpl,\n \"yearTmpl\": yearTmpl,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(CALENDAR.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.picker\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var PICKER;\n\n UI.addClass({\n className: \"picker\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5picker\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * ax5.def.picker.date_leftArrow = '
';\n * ax5.def.picker.date_yearTmpl = '%s';\n * ax5.def.picker.date_monthTmpl = '%s';\n * def.picker.date_rightArrow = '
';\n *\n * var picker = new ax5.ui.picker({\n * onStateChanged: function () {\n * console.log(this);\n * }\n * });\n *\n * picker.bind({\n * target: $('[data-picker-date]'),\n * direction: \"auto\",\n * content: {\n * type: 'date',\n * formatter: {\n * pattern: 'date'\n * }\n * }\n * });\n * ```\n */\n var ax5picker = function ax5picker() {\n var self = this,\n cfg = void 0;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchend\" : \"click\"),\n theme: 'default',\n title: '',\n lang: {\n \"ok\": \"ok\",\n \"cancel\": \"cancel\"\n },\n animateTime: 100,\n calendar: {\n multipleSelect: false,\n control: {\n left: ax5.def.picker.date_leftArrow || '←',\n yearTmpl: ax5.def.picker.date_yearTmpl || '%s',\n monthTmpl: ax5.def.picker.date_monthTmpl || '%s',\n right: ax5.def.picker.date_rightArrow || '→',\n yearFirst: true\n }\n }\n };\n this.queue = [];\n this.activePicker = null;\n this.activePickerQueueIndex = -1;\n this.openTimer = null;\n this.closeTimer = null;\n\n cfg = this.config;\n\n var onStateChanged = function onStateChanged(item, that) {\n if (item && item.onStateChanged) {\n item.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n return true;\n },\n bindPickerTarget = function () {\n\n var pickerEvent = {\n 'focus': function focus(queIdx, e) {\n this.open(queIdx);\n },\n 'click': function click(queIdx, e) {\n this.open(queIdx);\n }\n };\n\n var pickerType = {\n '@fn': function fn(queIdx, _input) {\n var item = this.queue[queIdx],\n inputLength = _input.length,\n config = {\n inputLength: inputLength || 1\n };\n\n if (inputLength > 1) {\n config.btns = {\n ok: { label: cfg.lang[\"ok\"], theme: cfg.theme }\n };\n }\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n config = null;\n inputLength = null;\n },\n 'date': function date(queIdx, _input) {\n // 1. 이벤트 바인딩\n // 2. ui 준비\n\n var item = this.queue[queIdx],\n contentWidth = item.content ? item.content.width || 270 : 270,\n contentMargin = item.content ? item.content.margin || 5 : 5,\n inputLength = _input.length,\n config = {\n contentWidth: contentWidth * inputLength + (inputLength - 1) * contentMargin,\n content: { width: contentWidth, margin: contentMargin },\n inputLength: inputLength || 1\n };\n\n if (inputLength > 1 && !item.btns) {\n config.btns = {\n ok: { label: cfg.lang[\"ok\"], theme: cfg.theme }\n };\n }\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n contentWidth = null;\n contentMargin = null;\n config = null;\n inputLength = null;\n },\n 'secure-num': function secureNum(queIdx, _input) {\n var item = this.queue[queIdx],\n inputLength = _input.length,\n config = {\n inputLength: inputLength || 1\n };\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n config = null;\n inputLength = null;\n },\n 'keyboard': function keyboard(queIdx, _input) {\n var item = this.queue[queIdx],\n inputLength = _input.length,\n config = {\n inputLength: inputLength || 1\n };\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n config = null;\n inputLength = null;\n },\n 'numpad': function numpad(queIdx, _input) {\n var item = this.queue[queIdx],\n inputLength = _input.length,\n config = {\n inputLength: inputLength || 1\n };\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n config = null;\n inputLength = null;\n }\n };\n\n return function (queIdx) {\n var item = this.queue[queIdx],\n input;\n\n if (!item.content) {\n console.log(ax5.info.getError(\"ax5picker\", \"501\", \"bind\"));\n return this;\n }\n\n input = item.$target.get(0).tagName.toUpperCase() == \"INPUT\" ? item.$target : item.$target.find('input[type]');\n\n // 함수타입\n if (U.isFunction(item.content)) {\n pickerType[\"@fn\"].call(this, queIdx, input);\n } else {\n for (var key in pickerType) {\n if (item.content.type == key) {\n pickerType[key].call(this, queIdx, input);\n break;\n }\n }\n }\n\n input.unbind('focus.ax5picker').unbind('click.ax5picker').bind('focus.ax5picker', pickerEvent.focus.bind(this, queIdx)).bind('click.ax5picker', pickerEvent.click.bind(this, queIdx));\n\n item.$target.find('.input-group-addon').unbind('click.ax5picker').bind('click.ax5picker', pickerEvent.click.bind(this, queIdx));\n\n if (item.content.formatter && ax5.ui.formatter) {\n input.ax5formatter(item.content.formatter);\n }\n\n input = null;\n item = null;\n queIdx = null;\n return this;\n };\n }(),\n alignPicker = function alignPicker(append) {\n if (!this.activePicker) return this;\n\n var _alignPicker = function _alignPicker(item) {\n var $window = jQuery(window),\n $body = jQuery(document.body);\n var pos = {},\n positionMargin = 12,\n dim = {},\n pickerDim = {},\n pickerDirection;\n\n pos = item.$target.offset();\n dim = {\n width: item.$target.outerWidth(),\n height: item.$target.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), $body.width()),\n winHeight: Math.max($window.height(), $body.height()),\n width: this.activePicker.outerWidth(),\n height: this.activePicker.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n\n if (!item.direction || item.direction === \"\" || item.direction === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = item.direction;\n }\n\n if (append) {\n this.activePicker.addClass(\"direction-\" + pickerDirection);\n }\n\n var positionCSS = function () {\n var css = { left: 0, top: 0 };\n switch (pickerDirection) {\n case \"top\":\n css.left = pos.left + dim.width / 2 - pickerDim.width / 2;\n css.top = pos.top + dim.height + positionMargin;\n break;\n case \"bottom\":\n css.left = pos.left + dim.width / 2 - pickerDim.width / 2;\n css.top = pos.top - pickerDim.height - positionMargin;\n break;\n case \"left\":\n css.left = pos.left + dim.width + positionMargin;\n css.top = pos.top - pickerDim.height / 2 + dim.height / 2;\n break;\n case \"right\":\n css.left = pos.left - pickerDim.width - positionMargin;\n css.top = pos.top - pickerDim.height / 2 + dim.height / 2;\n break;\n }\n return css;\n }();\n\n (function () {\n if (pickerDirection == \"top\" || pickerDirection == \"bottom\") {\n if (positionCSS.left < 0) {\n positionCSS.left = positionMargin;\n this.activePickerArrow.css({ left: pos.left + dim.width / 2 - positionCSS.left });\n } else if (positionCSS.left + pickerDim.width > pickerDim.winWidth) {\n positionCSS.left = pickerDim.winWidth - pickerDim.width - positionMargin;\n this.activePickerArrow.css({ left: pos.left + dim.width / 2 - positionCSS.left });\n }\n }\n }).call(this);\n\n this.activePicker.css(positionCSS);\n };\n\n var item = this.queue[this.activePickerQueueIndex];\n\n this.activePicker.css({ top: -999 });\n\n if (append) jQuery(document.body).append(this.activePicker);\n setTimeout(function () {\n _alignPicker.call(this, item);\n }.bind(this));\n },\n onBodyClick = function onBodyClick(e, target) {\n if (!this.activePicker) return this;\n\n var item = this.queue[this.activePickerQueueIndex];\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-picker-els\")) {\n return true;\n } else if (item.$target.get(0) == target) {\n return true;\n }\n });\n if (!target) {\n //console.log(\"i'm not picker\");\n this.close();\n return this;\n }\n //console.log(\"i'm picker\");\n return this;\n },\n onBtnClick = function onBtnClick(e, target) {\n // console.log('btn click');\n if (e.srcElement) e.target = e.srcElement;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-picker-btn\")) {\n return true;\n }\n });\n\n if (target) {\n var item = this.queue[this.activePickerQueueIndex],\n k = target.getAttribute(\"data-picker-btn\");\n\n if (item.btns && item.btns[k].onClick) {\n var that = {\n key: k,\n value: item.btns[k],\n self: this,\n item: item\n };\n item.btns[k].onClick.call(that, k);\n } else {\n this.close();\n }\n }\n },\n onBodyKeyup = function onBodyKeyup(e) {\n if (e.keyCode == ax5.info.eventKeys.ESC) {\n this.close();\n }\n },\n getQueIdx = function getQueIdx(boundID) {\n if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-axpicker-id\");\n }\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5picker\", \"402\", \"getQueIdx\"));\n return;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n };\n /// private end\n\n /**\n * Preferences of picker UI\n * @method ax5picker.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5picker}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n };\n\n /**\n * bind picker UI\n * @method ax5picker.bind\n * @param {Object} item\n * @param {Element} item.target\n * @param {String} item.direction - top|left|right|bottom|auto\n * @param {Number} item.contentWidth\n * @param {Boolean} item.disableChangeTrigger\n * @param {Function} item.onStateChanged\n * @param {Object} item.btns\n * @param {Object} item.content\n * @param {Number} item.content.width\n * @param {Number} item.content.margin\n * @param {String} item.content.type\n * @param {Object} item.content.config - binded UI config\n * @param {Object} item.content.formatter\n * @param {String} item.content.formatter.pattern\n * @returns {ax5picker}\n * @example\n * ```js\n * var picker = new ax5.ui.picker();\n * $(document.body).ready(function () {\n * picker.bind({\n * target: $('[data-ax5picker=\"basic\"]'),\n * direction: \"top\",\n * content: {\n * width: 270,\n * margin: 10,\n * type: 'date',\n * config: {\n * control: {\n * left: '
',\n * yearTmpl: '%s',\n * monthTmpl: '%s',\n * right: '
'\n * },\n * lang: {\n * yearTmpl: \"%s년\",\n * months: ['01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12'],\n * dayTmpl: \"%s\"\n * }\n * },\n * formatter: {\n * pattern: 'date'\n * }\n * },\n * onStateChanged: function () {\n *\n * }\n * });\n * });\n * ```\n */\n this.bind = function (item) {\n var pickerConfig = {},\n queIdx = void 0;\n\n item = jQuery.extend(true, pickerConfig, cfg, item);\n\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5picker\", \"401\", \"bind\"));\n return this;\n }\n item.$target = jQuery(item.target);\n\n if (!item.$target.get(0)) {\n console.log(ax5.info.getError(\"ax5picker\", \"401\", \"bind\"));\n return this;\n }\n\n if (!item.id) item.id = item.$target.data(\"data-axpicker-id\");\n\n if (!item.id) {\n item.id = 'ax5-picker-' + ax5.getGuid();\n item.$target.data(\"data-axpicker-id\", item.id);\n }\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindPickerTarget.call(this, this.queue.length - 1);\n } else {\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindPickerTarget.call(this, queIdx);\n }\n\n pickerConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * @method ax5picker.setContentValue\n * @param {String} boundID\n * @param {Number} inputIndex\n * @param {String} val\n * @returns {ax5picker} this\n */\n this.setContentValue = function () {\n\n var multipleInputProcessor = {\n \"date\": function date(_item, _inputIndex, _val) {\n var values = [],\n diffDay,\n prevInputValue,\n nextInputValue;\n\n if (_item.$target.get(0).tagName.toUpperCase() !== \"INPUT\") {\n _item.$target.find('input[type]').each(function () {\n values.push(this.value);\n });\n }\n\n if (_inputIndex == 0) {\n if (values.length > 1 && values[1] !== \"\") {\n // 값 검증\n diffDay = ax5.util.dday(values[1], { today: values[0] });\n if (diffDay < 0) {\n // 다음날짜 달력을 변경합니다.\n nextInputValue = _val;\n } else {}\n } else {\n nextInputValue = _val;\n }\n\n if (nextInputValue) {\n _item.pickerCalendar[1].ax5uiInstance.setSelection([nextInputValue], false).changeMode(\"d\", nextInputValue);\n this.setContentValue(_item.id, 1, nextInputValue);\n }\n\n return _val;\n } else if (_inputIndex == 1) {\n if (values.length > 1) {\n // 값 검증\n diffDay = ax5.util.dday(values[1], { today: values[0] });\n if (diffDay < 0) {\n // 다음날짜 달력을 변경합니다.\n prevInputValue = values[1];\n }\n }\n\n if (prevInputValue) {\n _item.pickerCalendar[0].ax5uiInstance.setSelection([prevInputValue], false).changeMode(\"d\", prevInputValue);\n this.setContentValue(_item.id, 0, prevInputValue);\n }\n\n return _val;\n }\n }\n };\n\n return function (boundID, inputIndex, val) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n var _input;\n\n if (item) {\n\n _input = item.$target.get(0).tagName.toUpperCase() == \"INPUT\" ? item.$target : jQuery(item.$target.find('input[type]').get(inputIndex));\n _input.val(val);\n\n if (!item.disableChangeTrigger) {\n _input.trigger(\"change\");\n }\n\n // picker의 입력이 2개이상인 경우\n //console.log(item.inputLength);\n if (item.inputLength > 1) {\n // 경우에 따라 첫번 선택에 따라 해야할 일들 처리\n if (multipleInputProcessor[item.content.type]) {\n val = multipleInputProcessor[item.content.type].call(this, item, inputIndex, val);\n }\n }\n\n var that = {\n self: self,\n state: \"changeValue\",\n item: item,\n inputIndex: inputIndex,\n value: val,\n values: [val]\n };\n if (item.$target.get(0).tagName.toUpperCase() !== \"INPUT\") {\n that.values = [];\n item.$target.find('input[type]').each(function () {\n that.values.push(this.value);\n });\n }\n\n onStateChanged.call(this, item, that);\n\n if (item.inputLength == 1) {\n this.close();\n }\n }\n\n item = null;\n boundID = null;\n inputIndex = null;\n val = null;\n return this;\n };\n }();\n\n /**\n * @method ax5picker.open\n * @param {String} boundObjectId\n * @returns {ax5picker} this\n */\n this.open = function () {\n\n var pickerContent = {\n '@fn': function fn(queIdx, callback) {\n var item = this.queue[queIdx];\n item.content.call(item, function (html) {\n callback(html);\n });\n return true;\n },\n 'date': function date(queIdx) {\n var item = this.queue[queIdx];\n var html = [];\n for (var i = 0; i < item.inputLength; i++) {\n html.push('
');\n if (i < item.inputLength - 1) html.push('
');\n }\n html.push('
');\n item.pickerContent.html(html.join(''));\n\n var calendarConfig = jQuery.extend({}, cfg.calendar, { displayDate: new Date() });\n var input = item.$target.get(0).tagName.toUpperCase() == \"INPUT\" ? item.$target : item.$target.find('input[type]');\n\n // calendar bind\n item.pickerCalendar = [];\n item.pickerContent.find('[data-calendar-target]').each(function () {\n\n // calendarConfig extend ~\n var idx = this.getAttribute(\"data-calendar-target\"),\n dValue = input.get(idx).value,\n d = ax5.util.date(dValue);\n\n calendarConfig.displayDate = d;\n if (dValue) calendarConfig.selection = [d];\n calendarConfig = jQuery.extend(true, calendarConfig, item.content.config || {});\n calendarConfig.target = this;\n calendarConfig.onClick = function () {\n self.setContentValue(item.id, idx, this.date);\n };\n\n item.pickerCalendar.push({\n itemId: item.id,\n inputIndex: idx,\n ax5uiInstance: new ax5.ui.calendar(calendarConfig)\n });\n });\n },\n 'secure-num': function secureNum(queIdx) {\n var item = this.queue[queIdx];\n var html = [];\n for (var i = 0; i < item.inputLength; i++) {\n html.push('
');\n if (i < item.inputLength - 1) html.push('
');\n }\n html.push('
');\n item.pickerContent.html(html.join(''));\n\n // secure-num bind\n item.pickerContent.find('[data-secure-num-target]').each(function () {\n var idx = this.getAttribute(\"data-secure-num-target\"),\n po = [];\n\n var numArray = function (a) {\n var j, x, i;\n for (i = a.length; i; i -= 1) {\n j = Math.floor(Math.random() * i);\n x = a[i - 1];\n a[i - 1] = a[j];\n a[j] = x;\n }\n return a;\n }([0, 1, 2, 3, 4, 5, 6, 7, 8, 9]);\n\n var specialArray = [{ label: \"←\", fn: \"back\" }, { label: \"C\", fn: \"clear\" }];\n\n numArray.forEach(function (n) {\n po.push('
');\n po.push('');\n po.push('
');\n });\n specialArray.forEach(function (n) {\n po.push('
');\n po.push('');\n po.push('
');\n });\n\n po.push('
');\n\n $(this).html(po.join('')).on(\"click\", '[data-secure-num-value]', function () {\n var act = this.getAttribute(\"data-secure-num-value\");\n var _input = item.$target.get(0).tagName.toUpperCase() == \"INPUT\" ? item.$target : jQuery(item.$target.find('input[type]').get(idx));\n var val = _input.val();\n\n if (act == \"back\") {\n _input.val(val.substring(0, val.length - 1));\n } else if (act == \"clear\") {\n _input.val('');\n } else {\n _input.val(val + act);\n }\n\n onStateChanged.call(this, item, {\n self: self,\n state: \"changeValue\",\n item: item,\n value: _input.val()\n });\n });\n });\n },\n 'keyboard': function keyboard(queIdx) {\n var item = this.queue[queIdx];\n var html = [];\n for (var i = 0; i < item.inputLength; i++) {\n html.push('
');\n if (i < item.inputLength - 1) html.push('
');\n }\n html.push('
');\n item.pickerContent.html(html.join(''));\n\n var keyArray = [[{ value: \"`\", shiftValue: \"~\" }, { value: \"1\", shiftValue: \"!\" }, { value: \"2\", shiftValue: \"@\" }, { value: \"3\", shiftValue: \"#\" }, { value: \"4\", shiftValue: \"$\" }, { value: \"5\", shiftValue: \"%\" }, { value: \"6\", shiftValue: \"^\" }, { value: \"7\", shiftValue: \"&\" }, { value: \"8\", shiftValue: \"*\" }, { value: \"9\", shiftValue: \"(\" }, { value: \"0\", shiftValue: \")\" }, { value: \"-\", shiftValue: \"_\" }, { value: \"=\", shiftValue: \"+\" }, { label: \"←\", fn: \"back\" }], [{ value: \"q\", shiftValue: \"Q\" }, { value: \"w\", shiftValue: \"W\" }, { value: \"e\", shiftValue: \"E\" }, { value: \"r\", shiftValue: \"R\" }, { value: \"t\", shiftValue: \"T\" }, { value: \"y\", shiftValue: \"Y\" }, { value: \"u\", shiftValue: \"U\" }, { value: \"i\", shiftValue: \"I\" }, { value: \"o\", shiftValue: \"O\" }, { value: \"p\", shiftValue: \"P\" }, { value: \"[\", shiftValue: \"{\" }, { value: \"]\", shiftValue: \"}\" }, { value: \"\\\\\", shiftValue: \"|\" }], [{ label: \"Clear\", fn: \"clear\" }, { value: \"a\", shiftValue: \"A\" }, { value: \"s\", shiftValue: \"S\" }, { value: \"d\", shiftValue: \"D\" }, { value: \"f\", shiftValue: \"F\" }, { value: \"g\", shiftValue: \"G\" }, { value: \"h\", shiftValue: \"H\" }, { value: \"j\", shiftValue: \"J\" }, { value: \"k\", shiftValue: \"K\" }, { value: \"l\", shiftValue: \"L\" }, { value: \";\", shiftValue: \":\" }, { value: \"'\", shiftValue: \"\\\"\" }], [{ label: \"Shift\", fn: \"shift\" }, { value: \"z\", shiftValue: \"Z\" }, { value: \"x\", shiftValue: \"X\" }, { value: \"c\", shiftValue: \"C\" }, { value: \"v\", shiftValue: \"V\" }, { value: \"b\", shiftValue: \"B\" }, { value: \"n\", shiftValue: \"N\" }, { value: \"m\", shiftValue: \"M\" }, { value: \",\", shiftValue: \"<\" }, { value: \".\", shiftValue: \">\" }, { value: \"/\", shiftValue: \"?\" }, { label: \"Close\", fn: \"close\" }]];\n var specialArray = [{ label: \"←\", fn: \"back\" }, { label: \"C\", fn: \"clear\" }];\n\n var getKeyBoard = function getKeyBoard(isShiftKey) {\n var po = [];\n keyArray.forEach(function (row) {\n po.push('
');\n row.forEach(function (n) {\n\n var keyValue, keyLabel, btnWrapStyle, btnTheme, btnStyle;\n if (n.fn) {\n keyValue = n.fn;\n keyLabel = n.label;\n btnWrapStyle = item.content.config.specialBtnWrapStyle;\n btnTheme = item.content.config.specialBtnTheme;\n btnStyle = item.content.config.specialBtnStyle;\n } else {\n keyLabel = keyValue = isShiftKey ? n.shiftValue : n.value;\n btnWrapStyle = item.content.config.btnWrapStyle;\n btnTheme = item.content.config.btnTheme;\n btnStyle = item.content.config.btnStyle;\n }\n\n po.push('
');\n po.push('');\n po.push('
');\n });\n po.push('
');\n });\n return po.join('');\n };\n\n // secure-num bind\n item.pickerContent.find('[data-keyboard-target]').each(function () {\n var idx = this.getAttribute(\"data-keyboard-target\");\n var $this = $(this);\n var isShiftKey = false;\n var toggleShift = function toggleShift() {\n isShiftKey = !isShiftKey;\n $this.html(getKeyBoard(isShiftKey));\n };\n $this.html(getKeyBoard(isShiftKey)).on(\"mousedown\", '[data-keyboard-value]', function () {\n var act = this.getAttribute(\"data-keyboard-value\");\n var _input = item.$target.get(0).tagName.toUpperCase() == \"INPUT\" ? item.$target : jQuery(item.$target.find('input[type]').get(idx));\n var val = _input.val();\n\n switch (act) {\n case \"back\":\n _input.val(val.substring(0, val.length - 1));\n break;\n case \"clear\":\n _input.val('');\n break;\n case \"shift\":\n toggleShift();\n return false;\n break;\n case \"close\":\n self.close();\n return false;\n break;\n default:\n _input.val(val + act);\n }\n\n onStateChanged.call(this, item, {\n self: self,\n state: \"changeValue\",\n item: item,\n value: _input.val()\n });\n });\n });\n },\n 'numpad': function numpad(queIdx) {\n var item = this.queue[queIdx];\n var html = [];\n for (var i = 0; i < item.inputLength; i++) {\n html.push('
');\n if (i < item.inputLength - 1) html.push('
');\n }\n html.push('
');\n item.pickerContent.html(html.join(''));\n\n // secure-num bind\n item.pickerContent.find('[data-numpad-target]').each(function () {\n var idx = this.getAttribute(\"data-numpad-target\"),\n po = [];\n\n var keyArray = item.content.config.keyArray || [{ value: \"7\" }, { value: \"8\" }, { value: \"9\" }, { label: \"BS\", fn: \"back\" }, { value: \"4\" }, { value: \"5\" }, { value: \"6\" }, { label: \"CLS\", fn: \"clear\" }, { value: \"1\" }, { value: \"2\" }, { value: \"3\" }, { value: \"\" }, { value: \".\" }, { value: \"0\" }, { value: \"\" }, { label: \"OK\", fn: \"enter\" }];\n\n keyArray.forEach(function (n) {\n var keyValue, keyLabel, btnWrapStyle, btnTheme, btnStyle;\n\n if (n.fn) {\n keyValue = n.fn;\n keyLabel = n.label;\n btnTheme = item.content.config.specialBtnTheme;\n btnWrapStyle = item.content.config.specialBtnWrapStyle;\n btnStyle = item.content.config.specialBtnStyle;\n } else {\n keyLabel = keyValue = n.value;\n btnTheme = keyValue ? item.content.config.btnTheme : \"\";\n btnWrapStyle = item.content.config.btnWrapStyle;\n btnStyle = item.content.config.btnStyle;\n }\n\n po.push('
');\n po.push('');\n po.push('
');\n });\n\n po.push('
');\n\n $(this).html(po.join('')).on(\"mousedown\", '[data-numpad-value]', function () {\n var act = this.getAttribute(\"data-numpad-value\");\n var _input = item.$target.get(0).tagName.toUpperCase() == \"INPUT\" ? item.$target : jQuery(item.$target.find('input[type]').get(idx));\n var val = _input.val();\n var state = \"\";\n\n switch (act) {\n case \"back\":\n state = \"changeValue\";\n _input.val(val.substring(0, val.length - 1));\n break;\n case \"clear\":\n state = \"changeValue\";\n _input.val('');\n break;\n case \"enter\":\n self.close(item, \"enter\");\n return false;\n break;\n case \"close\":\n self.close();\n return false;\n break;\n default:\n state = \"changeValue\";\n _input.val(val + act);\n }\n\n onStateChanged.call(this, item, {\n self: self,\n state: state,\n item: item,\n value: _input.val()\n });\n });\n });\n }\n };\n\n return function (boundID, tryCount) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n\n /**\n 다른 피커가 있는 경우와 다른 피커를 닫고 다시 오픈 명령이 내려진 경우에 대한 예외 처리 구문\n */\n if (this.openTimer) clearTimeout(this.openTimer);\n if (this.activePicker) {\n if (this.activePickerQueueIndex == queIdx) {\n return this;\n }\n\n if (tryCount > 2) return this;\n this.close();\n this.openTimer = setTimeout(function () {\n this.open(queIdx, (tryCount || 0) + 1);\n }.bind(this), cfg.animateTime);\n return this;\n }\n\n this.activePicker = jQuery(PICKER.tmpl.get.call(this, \"pickerTmpl\", item));\n this.activePickerArrow = this.activePicker.find(\".ax-picker-arrow\");\n this.activePickerQueueIndex = queIdx;\n item.pickerContent = this.activePicker.find('[data-picker-els=\"content\"]');\n\n if (U.isFunction(item.content)) {\n // 함수타입\n item.pickerContent.html(\"Loading..\");\n pickerContent[\"@fn\"].call(this, queIdx, function (html) {\n item.pickerContent.html(html);\n });\n } else {\n if (item.content.type in pickerContent) {\n pickerContent[item.content.type].call(this, queIdx);\n }\n }\n\n // bind event picker btns\n this.activePicker.find(\"[data-picker-btn]\").on(cfg.clickEventName, function (e) {\n onBtnClick.call(this, e || window.event, queIdx);\n }.bind(this));\n\n alignPicker.call(this, \"append\");\n\n jQuery(window).bind(\"resize.ax5picker\", function () {\n alignPicker.call(this);\n }.bind(this));\n\n // bind key event\n jQuery(window).bind(\"keyup.ax5picker\", function (e) {\n e = e || window.event;\n onBodyKeyup.call(this, e);\n U.stopEvent(e);\n }.bind(this));\n\n jQuery(window).bind(\"click.ax5picker\", function (e) {\n e = e || window.event;\n onBodyClick.call(this, e);\n U.stopEvent(e);\n }.bind(this));\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"open\",\n item: item\n });\n\n return this;\n };\n }();\n\n /**\n * @method ax5picker.close\n * @returns {ax5picker} this\n */\n this.close = function (item, state) {\n if (this.closeTimer) clearTimeout(this.closeTimer);\n if (!this.activePicker) return this;\n\n item = this.queue[this.activePickerQueueIndex];\n\n this.activePicker.addClass(\"destroy\");\n jQuery(window).unbind(\"resize.ax5picker\");\n jQuery(window).unbind(\"click.ax5picker\");\n jQuery(window).unbind(\"keyup.ax5picker\");\n\n this.closeTimer = setTimeout(function () {\n if (this.activePicker) this.activePicker.remove();\n this.activePicker = null;\n this.activePickerQueueIndex = -1;\n\n onStateChanged.call(this, item, {\n self: this,\n state: state || \"close\"\n });\n }.bind(this), cfg.animateTime);\n\n return this;\n };\n\n // 클래스 생성자\n this.main = function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5picker;\n }());\n\n PICKER = ax5.ui.picker;\n})();\n\n/**\n * ax5.ui.picker_instance\n * @type {ax5picker}\n * @example\n * ```js\n * // picker 기본 속성을 변경해야 한다면\n * ax5.ui.picker_instance.setConfig({\n * });\n *\n * ```\n */\nax5.ui.picker_instance = new ax5.ui.picker();\n\njQuery.fn.ax5picker = function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"open\":\n return ax5.ui.picker_instance.open(this);\n break;\n case \"close\":\n return ax5.ui.picker_instance.close(this);\n break;\n case \"setValue\":\n return ax5.ui.picker_instance.setContentValue(this, arguments[1], arguments[2]);\n break;\n default:\n return this;\n }\n } else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend(true, config, defaultConfig);\n ax5.ui.picker_instance.bind(config);\n });\n }\n return this;\n };\n}();\n// ax5.ui.picker.tmpl\n(function () {\n var PICKER = ax5.ui.picker;\n var U = ax5.util;\n\n var pickerTmpl = function pickerTmpl() {\n return '\\n
\\n {{#title}}\\n
{{title}}
\\n {{/title}}\\n
\\n
\\n {{#btns}}\\n
\\n {{#btns}}\\n {{#@each}}\\n \\n {{/@each}}\\n {{/btns}}\\n
\\n {{/btns}}\\n
\\n
\\n
\\n';\n };\n\n PICKER.tmpl = {\n \"pickerTmpl\": pickerTmpl,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(PICKER.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.formatter\n(function () {\n var UI = ax5.ui;\n var U = ax5.util;\n var FORMATTER;\n\n UI.addClass({\n className: \"formatter\",\n version: \"1.3.66\"\n }, function () {\n var TODAY = new Date();\n var setSelectionRange = function setSelectionRange(input, pos) {\n if (typeof pos == \"undefined\") {\n pos = input.value.length;\n }\n if (input.setSelectionRange) {\n input.focus();\n input.setSelectionRange(pos, pos);\n } else if (input.createTextRange) {\n var range = input.createTextRange();\n range.collapse(true);\n range.moveEnd('character', pos);\n range.moveStart('character', pos);\n range.select();\n } else if (input.selectionStart) {\n input.focus();\n input.selectionStart = pos;\n input.selectionEnd = pos;\n }\n };\n\n /**\n * @class ax5formatter\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * $('#idInputTime').attr('data-ax5formatter', 'time').ax5formatter();\n * $('#idInputMoney').attr('data-ax5formatter', 'money').ax5formatter();\n * $('#idInputPhone').attr('data-ax5formatter', 'phone').ax5formatter();\n * $('#idInputDate').attr('data-ax5formatter', 'date').ax5formatter();\n *\n * $('#ax5formatter-custom').ax5formatter({\n * pattern: \"custom\",\n * getEnterableKeyCodes: function(){\n * return {\n * '65':'a',\n * '66':'b',\n * '67':'c',\n * '68':'d',\n * '69':'e',\n * '70':'f'\n * };\n * },\n * getPatternValue: function(obj){\n * return obj.value.replace(/./g, \"*\");\n * }\n * });\n * ```\n */\n var ax5formatter = function ax5formatter() {\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n animateTime: 250\n };\n\n this.queue = [];\n this.openTimer = null;\n this.closeTimer = null;\n\n cfg = this.config;\n\n var formatterEvent = {\n 'focus': function focus(opts, optIdx, e) {\n if (!opts.$input.data(\"__originValue__\")) opts.$input.data(\"__originValue__\", opts.$input.val());\n },\n /* 키 다운 이벤트에서 입력할 수 없는 키 입력을 방어 */\n 'keydown': function keydown(opts, optIdx, e) {\n var isStop = false;\n if (!opts.enterableKeyCodes) {} else if (e.which && opts.enterableKeyCodes[e.which]) {} else if (!e.metaKey && !e.ctrlKey && !e.shiftKey) {\n //console.log(e.which, opts.enterableKeyCodes);\n isStop = true;\n }\n if (isStop) ax5.util.stopEvent(e);\n },\n /* 키 업 이벤트에서 패턴을 적용 */\n 'keyup': function keyup(opts, optIdx, e) {\n var elem = opts.$input.get(0),\n elemFocusPosition,\n beforeValue,\n newValue,\n selection,\n selectionLength;\n\n if ('selectionStart' in elem) {\n // Standard-compliant browsers\n elemFocusPosition = elem.selectionStart;\n } else if (document.selection) {\n // IE\n //elem.focus();\n selection = document.selection.createRange();\n selectionLength = document.selection.createRange().text.length;\n selection.moveStart('character', -elem.value.length);\n elemFocusPosition = selection.text.length - selectionLength;\n }\n\n beforeValue = elem.value;\n if (opts.pattern in FORMATTER.formatter) {\n newValue = FORMATTER.formatter[opts.pattern].getPatternValue.call(this, opts, optIdx, e, elem.value);\n } else {\n newValue = beforeValue;\n }\n\n if (newValue != beforeValue) {\n opts.$input.val(newValue).trigger(\"change\");\n setSelectionRange(elem, elemFocusPosition + newValue.length - beforeValue.length);\n }\n },\n 'blur': function blur(opts, optIdx, e, _force) {\n var elem = opts.$input.get(0),\n beforeValue,\n newValue;\n\n opts.$input.removeData(\"__originValue__\");\n\n beforeValue = elem.value;\n if (opts.pattern in FORMATTER.formatter) {\n newValue = FORMATTER.formatter[opts.pattern].getPatternValue.call(this, opts, optIdx, e, elem.value, 'blur');\n } else {\n newValue = beforeValue;\n }\n\n if (_force) {\n opts.$input.val(newValue);\n } else {\n if (newValue != beforeValue) {\n opts.$input.val(newValue).trigger(\"change\");\n }\n }\n }\n },\n bindFormatterTarget = function bindFormatterTarget(opts, optIdx) {\n\n if (!opts.pattern) {\n if (opts.$target.get(0).tagName == \"INPUT\") {\n opts.pattern = opts.$target.attr('data-ax5formatter');\n } else {\n opts.pattern = opts.$target.find('input[type=\"text\"]').attr('data-ax5formatter');\n }\n if (!opts.pattern) {\n console.log(ax5.info.getError(\"ax5formatter\", \"501\", \"bind\"));\n console.log(opts.target);\n return this;\n }\n }\n\n var re = /[^\\(^\\))]+/gi,\n matched = opts.pattern.match(re);\n\n opts.pattern = matched[0];\n opts.patternArgument = matched[1] || \"\";\n\n // 함수타입\n if (opts.pattern in FORMATTER.formatter) {\n opts.enterableKeyCodes = FORMATTER.formatter[opts.pattern].getEnterableKeyCodes.call(this, opts, optIdx);\n }\n\n opts.$input.unbind('focus.ax5formatter').bind('focus.ax5formatter', formatterEvent.focus.bind(this, this.queue[optIdx], optIdx));\n\n opts.$input.unbind('keydown.ax5formatter').bind('keydown.ax5formatter', formatterEvent.keydown.bind(this, this.queue[optIdx], optIdx));\n\n opts.$input.unbind('keyup.ax5formatter').bind('keyup.ax5formatter', formatterEvent.keyup.bind(this, this.queue[optIdx], optIdx));\n\n opts.$input.unbind('blur.ax5formatter').bind('blur.ax5formatter', formatterEvent.blur.bind(this, this.queue[optIdx], optIdx));\n\n formatterEvent.blur.call(this, this.queue[optIdx], optIdx);\n\n return this;\n },\n getQueIdx = function getQueIdx(boundID) {\n if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-formatter\");\n }\n /*\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5formatter\", \"402\", \"getQueIdx\"));\n return;\n }\n */\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n };\n\n /**\n * Preferences of formatter UI\n * @method ax5formatter.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5.ui.formatter}\n * @example\n * ```\n * ```\n */\n this.init = function () {};\n\n this.bind = function (opts) {\n var formatterConfig = {},\n optIdx;\n\n jQuery.extend(true, formatterConfig, cfg);\n if (opts) jQuery.extend(true, formatterConfig, opts);\n opts = formatterConfig;\n\n if (!opts.target) {\n console.log(ax5.info.getError(\"ax5formatter\", \"401\", \"bind\"));\n return this;\n }\n opts.$target = jQuery(opts.target);\n\n if (opts.$target.get(0).tagName == \"INPUT\") {\n opts.$input = opts.$target;\n } else {\n opts.$input = opts.$target.find('input[type=\"text\"]');\n if (opts.$input.length > 1) {\n opts.$input.each(function () {\n opts.target = this;\n self.bind(opts);\n });\n return this;\n }\n }\n\n opts.$input = opts.$target.get(0).tagName == \"INPUT\" ? opts.$target : opts.$target.find('input[type=\"text\"]');\n if (!opts.id) opts.id = opts.$input.data(\"ax5-formatter\");\n\n if (!opts.id) {\n opts.id = 'ax5-formatter-' + ax5.getGuid();\n opts.$input.data(\"ax5-formatter\", opts.id);\n }\n optIdx = U.search(this.queue, function () {\n return this.id == opts.id;\n });\n\n if (optIdx === -1) {\n this.queue.push(opts);\n bindFormatterTarget.call(this, this.queue[this.queue.length - 1], this.queue.length - 1);\n } else {\n this.queue[optIdx] = opts;\n bindFormatterTarget.call(this, this.queue[optIdx], optIdx);\n }\n\n return this;\n };\n\n /**\n * formatter value 를 다시 적용합니다.\n * @method ax5formatter.formatting\n * @returns {ax5formatter}\n * @example\n * ```js\n * $('[data-ax5formatter=\"time\"]').ax5formatter(\"formatting\"); // 하나만\n * $('[data-ax5formatter]').ax5formatter(\"formatting\"); // 모두\n * ```\n */\n this.formatting = function (boundID) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n var i = this.queue.length;\n while (i--) {\n formatterEvent.blur.call(this, this.queue[i], i, null, true);\n }\n } else {\n formatterEvent.blur.call(this, this.queue[queIdx], queIdx, null, true);\n }\n return this;\n };\n\n this.unbind = function () {\n // 구현해야함.\n };\n\n // 클래스 생성자\n this.main = function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5formatter;\n }());\n\n FORMATTER = ax5.ui.formatter;\n})();\n\nax5.ui.formatter_instance = new ax5.ui.formatter();\n\njQuery.fn.ax5formatter = function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"formatting\":\n return ax5.ui.formatter_instance.formatting(this);\n break;\n\n case \"unbind\":\n return ax5.ui.formatter_instance.unbind(this);\n break;\n\n default:\n return this;\n }\n } else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.formatter_instance.bind(config);\n });\n }\n return this;\n };\n}();\n\n// ax5.ui.formatter.formatter\n(function () {\n\n var FORMATTER = ax5.ui.formatter;\n var U = ax5.util;\n var ctrlKeys = {\n \"18\": \"KEY_ALT\",\n \"8\": \"KEY_BACKSPACE\",\n \"17\": \"KEY_CONTROL\",\n \"46\": \"KEY_DELETE\",\n \"40\": \"KEY_DOWN\",\n \"35\": \"KEY_END\",\n \"187\": \"KEY_EQUAL\",\n \"27\": \"KEY_ESC\",\n \"36\": \"KEY_HOME\",\n \"45\": \"KEY_INSERT\",\n \"37\": \"KEY_LEFT\",\n \"189\": \"KEY_MINUS\",\n \"34\": \"KEY_PAGEDOWN\",\n \"33\": \"KEY_PAGEUP\",\n // \"190\": \"KEY_PERIOD\",\n \"13\": \"KEY_RETURN\",\n \"39\": \"KEY_RIGHT\",\n \"16\": \"KEY_SHIFT\",\n // \"32\": \"KEY_SPACE\",\n \"9\": \"KEY_TAB\",\n \"38\": \"KEY_UP\",\n \"91\": \"KEY_WINDOW\"\n //\"107\" : \"NUMPAD_ADD\",\n //\"194\" : \"NUMPAD_COMMA\",\n //\"110\" : \"NUMPAD_DECIMAL\",\n //\"111\" : \"NUMPAD_DIVIDE\",\n //\"12\" : \"NUMPAD_EQUAL\",\n //\"106\" : \"NUMPAD_MULTIPLY\",\n //\"109\" : \"NUMPAD_SUBTRACT\"\n };\n var numKeys = {\n '48': 1, '49': 1, '50': 1, '51': 1, '52': 1, '53': 1, '54': 1, '55': 1, '56': 1, '57': 1,\n '96': 1, '97': 1, '98': 1, '99': 1, '100': 1, '101': 1, '102': 1, '103': 1, '104': 1, '105': 1\n };\n var pattern_money = {\n getEnterableKeyCodes: function getEnterableKeyCodes(_opts) {\n var enterableKeyCodes = {\n '188': ','\n };\n if (_opts.patternArgument == \"int\") {\n // 소수점 입력 안됨\n } else {\n enterableKeyCodes['190'] = \".\"; // 소수점 입력 허용\n }\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function getPatternValue(_opts, optIdx, e, val, eType) {\n val = val.replace(/[^0-9^\\.^\\-]/g, \"\");\n var regExpPattern = new RegExp('([0-9])([0-9][0-9][0-9][,.])'),\n arrNumber = val.split('.'),\n returnValue;\n\n arrNumber[0] += '.';\n\n do {\n arrNumber[0] = arrNumber[0].replace(regExpPattern, '$1,$2');\n } while (regExpPattern.test(arrNumber[0]));\n\n if (arrNumber.length > 1) {\n if (U.isNumber(_opts.maxRound)) {\n returnValue = arrNumber[0] + U.left(arrNumber[1], _opts.maxRound);\n } else {\n returnValue = arrNumber.join('');\n }\n } else {\n returnValue = arrNumber[0].split('.')[0];\n }\n\n return returnValue;\n }\n };\n\n var pattern_number = {\n getEnterableKeyCodes: function getEnterableKeyCodes(_opts) {\n var enterableKeyCodes = {\n '190': '.'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function getPatternValue(_opts, optIdx, e, val, eType) {\n val = val.replace(/[^0-9^\\.^\\-]/g, \"\");\n var arrNumber = val.split('.'),\n returnValue;\n\n if (arrNumber.length > 1) {\n if (U.isNumber(_opts.maxRound)) {\n returnValue = arrNumber[0] + U.left(arrNumber[1], _opts.maxRound);\n } else {\n returnValue = arrNumber.join('');\n }\n } else {\n returnValue = arrNumber[0].split('.')[0];\n }\n\n return returnValue;\n }\n };\n\n var pattern_date = {\n getEnterableKeyCodes: function getEnterableKeyCodes(_opts) {\n var enterableKeyCodes = {\n '189': '-', '191': '/'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function getPatternValue(_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\");\n if (val == \"\") return val;\n var regExpPattern = /^([0-9]{4})\\-?([0-9]{1,2})?\\-?([0-9]{1,2})?.*$/;\n\n if (_opts.patternArgument == \"time\") {\n regExpPattern = /^([0-9]{4})\\-?([0-9]{1,2})?\\-?([0-9]{1,2})? ?([0-9]{1,2})?:?([0-9]{1,2})?:?([0-9]{1,2})?.*$/;\n }\n\n var matchedPattern = val.match(regExpPattern),\n returnValue = \"\",\n inspectValue = function inspectValue(val, format, inspect, data) {\n var _val = {\n 'Y': function Y(v) {\n if (typeof v == \"undefined\") v = TODAY.getFullYear();\n if (v == '' || v == '0000') v = TODAY.getFullYear();\n return v.length < 4 ? U.setDigit(v, 4) : v;\n },\n 'M': function M(v) {\n if (typeof v == \"undefined\") v = TODAY.getMonth() + 1;\n return v > 12 ? 12 : v == 0 ? '01' : U.setDigit(v, 2);\n },\n 'D': function D(v) {\n if (typeof v == \"undefined\") v = TODAY.getDate() + 1;\n var dLen = U.daysOfMonth(data[1], data[2] - 1);\n return v > dLen ? dLen : v == 0 ? '01' : U.setDigit(v, 2);\n },\n 'h': function h(v) {\n if (!v) v = 0;\n return v > 23 ? 23 : U.setDigit(v, 2);\n },\n 'm': function m(v) {\n if (!v) v = 0;\n return v > 59 ? 59 : U.setDigit(v, 2);\n },\n 's': function s(v) {\n if (!v) v = 0;\n return v > 59 ? 59 : U.setDigit(v, 2);\n }\n };\n return inspect ? _val[format](val) : val;\n };\n\n returnValue = val.replace(regExpPattern, function (a, b) {\n var nval = [inspectValue(arguments[1], \"Y\", eType)];\n if (arguments[2] || eType) nval.push('-' + inspectValue(arguments[2], \"M\", eType));\n if (arguments[3] || eType) nval.push('-' + inspectValue(arguments[3], \"D\", eType, arguments));\n if (_opts.patternArgument == \"time\") {\n if (arguments[4] || eType) nval.push(' ' + inspectValue(arguments[4], \"h\", eType));\n if (arguments[5] || eType) nval.push(':' + inspectValue(arguments[5], \"m\", eType));\n if (arguments[6] || eType) nval.push(':' + inspectValue(arguments[6], \"s\", eType));\n }\n return nval.join('');\n });\n\n if (eType == 'blur' && !matchedPattern) {\n returnValue = function () {\n var nval = [inspectValue(returnValue, \"Y\", eType)];\n nval.push('-' + inspectValue(0, \"M\", eType));\n nval.push('-' + inspectValue(0, \"D\", eType, arguments));\n if (_opts.patternArgument == \"time\") {\n nval.push(' ' + inspectValue(0, \"h\", eType));\n nval.push(':' + inspectValue(0, \"m\", eType));\n nval.push(':' + inspectValue(0, \"s\", eType));\n }\n return nval.join('');\n }();\n } else if (!matchedPattern) returnValue = returnValue.length > 4 ? U.left(returnValue, 4) : returnValue;\n\n return returnValue;\n }\n };\n\n var pattern_time = {\n getEnterableKeyCodes: function getEnterableKeyCodes(_opts) {\n var enterableKeyCodes = {\n '186': ':'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function getPatternValue(_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\");\n var regExpPattern = /^([0-9]{1,2})?:?([0-9]{1,2})?:?([0-9]{1,2})?.*$/;\n\n var matchedPattern = val.match(regExpPattern),\n returnValue = val.replace(regExpPattern, function (a, b) {\n var nval = [arguments[1]];\n if (arguments[2]) nval.push(':' + arguments[2]);\n if (arguments[3]) nval.push(':' + arguments[3]);\n return nval.join('');\n });\n\n if (!matchedPattern) returnValue = returnValue.length > 2 ? U.left(returnValue, 2) : returnValue;\n\n return returnValue;\n }\n };\n\n var pattern_bizno = {\n getEnterableKeyCodes: function getEnterableKeyCodes(_opts) {\n var enterableKeyCodes = {\n '189': '-'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function getPatternValue(_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\");\n var regExpPattern = /^([0-9]{3})\\-?([0-9]{1,2})?\\-?([0-9]{1,5})?.*$/,\n returnValue = val.replace(regExpPattern, function (a, b) {\n var nval = [arguments[1]];\n if (arguments[2]) nval.push(arguments[2]);\n if (arguments[3]) nval.push(arguments[3]);\n return nval.join(\"-\");\n });\n\n return returnValue;\n }\n };\n\n var pattern_phone = {\n getEnterableKeyCodes: function getEnterableKeyCodes(_opts) {\n var enterableKeyCodes = {\n '189': '-', '188': ','\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function getPatternValue(_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\");\n var regExpPattern3 = /^([0-9]{3})\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?/;\n if (val.substr(0, 2) == \"02\") {\n regExpPattern3 = /^([0-9]{2})\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?/;\n }\n\n var returnValue = val.replace(regExpPattern3, function (a, b) {\n var nval = [arguments[1]];\n if (arguments[2]) nval.push(arguments[2]);\n if (arguments[3]) nval.push(arguments[3]);\n if (arguments[4]) nval.push(arguments[4]);\n if (arguments[5]) nval.push(arguments[5]);\n return nval.join(\"-\");\n });\n return returnValue;\n }\n };\n\n var pattern_credit = {\n getEnterableKeyCodes: function getEnterableKeyCodes(_opts) {\n var enterableKeyCodes = {\n '189': '-'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function getPatternValue(_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\").substring(0, 16);\n\n var regExpPattern3 = /^([0-9]{4})\\-?([0-9]{4})?\\-?([0-9]{4})?\\-?([0-9]{4})?/,\n returnValue = val.replace(regExpPattern3, function (a, b) {\n var nval = [arguments[1]];\n if (arguments[2]) nval.push(arguments[2]);\n if (arguments[3]) nval.push(arguments[3]);\n if (arguments[4]) nval.push(arguments[4]);\n return nval.join(\"-\");\n });\n return returnValue;\n }\n };\n\n var pattern_custom = {\n getEnterableKeyCodes: function getEnterableKeyCodes(_opts) {\n if (_opts.getEnterableKeyCodes) {\n return _opts.getEnterableKeyCodes.call(_opts, { $input: _opts.$input });\n } else {\n return null;\n }\n },\n getPatternValue: function getPatternValue(_opts, optIdx, e, val, eType) {\n if (_opts.getPatternValue) {\n return _opts.getPatternValue.call(_opts, { event: e, $input: _opts.$input, value: val });\n }\n }\n };\n\n FORMATTER.formatter = {\n ctrlKeys: ctrlKeys,\n numKeys: numKeys,\n money: pattern_money,\n number: pattern_number,\n date: pattern_date,\n time: pattern_time,\n bizno: pattern_bizno,\n phone: pattern_phone,\n credit: pattern_credit,\n custom: pattern_custom\n };\n})();\n// ax5.ui.menu\n(function () {\n var UI = ax5.ui;\n var U = ax5.util;\n var MENU;\n\n UI.addClass({\n className: \"menu\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5.ui.menu\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var menu = new ax5.ui.menu({\n * theme: 'primary',\n * iconWidth: 20,\n * acceleratorWidth: 100,\n * itemClickAndClose: false,\n * icons: {\n * 'arrow': '
'\n * },\n * columnKeys: {\n * label: 'name',\n * items: 'chidren'\n * },\n * items: [\n * {\n * icon: '
',\n * name: \"Menu Parent 0\",\n * chidren: [\n * {\n * check: {\n * type: 'checkbox',\n * name: 'A',\n * value: '0',\n * checked: false\n * },\n * name: \"Menu Z\",\n * data: {},\n * role: \"\",\n * accelerator: \"CmdOrCtrl+Z\"\n * },\n * {\n * check: {\n * type: 'checkbox',\n * name: 'A',\n * value: '1',\n * checked: true\n * },\n * name: \"Menu A\",\n * data: {},\n * role: \"\"\n * }\n * ],\n * filterType: \"A\"\n * },\n * {\n * divide: true,\n * filterType: \"A\"\n * },\n * {\n * icon: '
',\n * name: \"Menu Parent 1\",\n * chidren: [\n * {\n * name: \"Menu Z\",\n * data: {},\n * role: \"\",\n * chidren: [\n * {\n * name: \"Menu Z\",\n * data: {},\n * role: \"\"\n * },\n * {\n * name: \"Menu A\",\n * data: {},\n * role: \"\"\n * }\n * ]\n * },\n * {\n * name: \"Menu A\",\n * data: {},\n * role: \"\"\n * }\n * ],\n * filterType: \"A\"\n * },\n * {\n * check: {\n * type: 'radio',\n * name: 'radioName',\n * value: '1',\n * checked: false\n * },\n * icon: '
',\n * name: \"Menu Parent 2\"\n * },\n * {\n * check: {\n * type: 'radio',\n * name: 'radioName',\n * value: '2',\n * checked: false\n * },\n * name: \"Menu Parent 3\"\n * },\n * {\n * check: {\n * type: 'radio',\n * name: 'radioName',\n * value: '3',\n * checked: false\n * },\n * name: \"Menu Parent 4\"\n * },\n * {divide: true},\n * {\n * html: function () {\n * return '
' +\n * ' ' +\n * '' +\n * '
';\n * }\n * }\n * ]\n * });\n * ```\n */\n var ax5menu = function ax5menu() {\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: \"default\",\n iconWidth: 22,\n acceleratorWidth: 100,\n menuBodyPadding: 5,\n //direction: \"top\", // top|bottom\n offset: { left: 0, top: 0 },\n position: \"fixed\",\n animateTime: 250,\n items: [],\n itemClickAndClose: true,\n columnKeys: {\n label: 'label',\n items: 'items'\n }\n };\n\n this.openTimer = null;\n this.closeTimer = null;\n this.queue = [];\n this.menuBar = {};\n this.state = undefined;\n\n cfg = this.config;\n\n var appEventAttach = function appEventAttach(active) {\n if (active) {\n jQuery(document).unbind(\"click.ax5menu-\" + this.menuId).bind(\"click.ax5menu-\" + this.menuId, clickItem.bind(this));\n jQuery(window).unbind(\"keydown.ax5menu-\" + this.menuId).bind(\"keydown.ax5menu-\" + this.menuId, function (e) {\n if (e.which == ax5.info.eventKeys.ESC) {\n self.close();\n }\n });\n jQuery(window).unbind(\"resize.ax5menu-\" + this.menuId).bind(\"resize.ax5menu-\" + this.menuId, function (e) {\n self.close();\n });\n } else {\n jQuery(document).unbind(\"click.ax5menu-\" + this.menuId);\n jQuery(window).unbind(\"keydown.ax5menu-\" + this.menuId);\n jQuery(window).unbind(\"resize.ax5menu-\" + this.menuId);\n }\n },\n onStateChanged = function onStateChanged(opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n self.state = that.state;\n opts = null;\n that = null;\n return true;\n },\n onLoad = function onLoad(that) {\n if (this.onLoad) {\n this.onLoad.call(that, that);\n }\n\n that = null;\n return true;\n },\n popup = function popup(opt, items, depth, path) {\n var data = opt,\n activeMenu,\n removed;\n\n data.theme = opt.theme || cfg.theme;\n data.cfg = {\n icons: jQuery.extend({}, cfg.icons),\n iconWidth: opt.iconWidth || cfg.iconWidth,\n acceleratorWidth: opt.acceleratorWidth || cfg.acceleratorWidth\n };\n\n items.forEach(function (n) {\n if (n.html || n.divide) {\n n['@isMenu'] = false;\n if (n.html) {\n n['@html'] = n.html.call({\n item: n,\n config: cfg,\n opt: opt\n });\n }\n } else {\n n['@isMenu'] = true;\n }\n });\n\n data[cfg.columnKeys.items] = items;\n data['@depth'] = depth;\n data['@path'] = path || \"root\";\n data['@hasChild'] = function () {\n return this[cfg.columnKeys.items] && this[cfg.columnKeys.items].length > 0;\n };\n activeMenu = jQuery(MENU.tmpl.get.call(this, \"tmpl\", data, cfg.columnKeys));\n jQuery(document.body).append(activeMenu);\n\n // remove queue\n\n removed = this.queue.splice(depth);\n removed.forEach(function (n) {\n n.$target.remove();\n });\n\n this.queue.push({\n '$target': activeMenu,\n 'data': jQuery.extend({}, data)\n });\n\n activeMenu.find('[data-menu-item-index]').bind(\"mouseover\", function () {\n var depth = this.getAttribute(\"data-menu-item-depth\"),\n index = this.getAttribute(\"data-menu-item-index\"),\n path = this.getAttribute(\"data-menu-item-path\"),\n $this,\n offset,\n scrollTop,\n childOpt,\n _items,\n _activeMenu;\n\n if (depth != null && typeof depth != \"undefined\") {\n _items = self.queue[depth].data[cfg.columnKeys.items][index][cfg.columnKeys.items];\n _activeMenu = self.queue[depth].$target;\n _activeMenu.find('[data-menu-item-index]').removeClass(\"hover\");\n jQuery(this).addClass(\"hover\");\n\n if (_activeMenu.attr(\"data-selected-menu-item-index\") != index) {\n _activeMenu.attr(\"data-selected-menu-item-index\", index);\n\n if (_items && _items.length > 0) {\n\n $this = jQuery(this);\n offset = $this.offset();\n scrollTop = cfg.position == \"fixed\" ? jQuery(document).scrollTop() : 0;\n childOpt = {\n '@parent': {\n left: offset.left,\n top: offset.top,\n width: $this.outerWidth(),\n height: $this.outerHeight()\n },\n left: offset.left + $this.outerWidth() - cfg.menuBodyPadding,\n top: offset.top - cfg.menuBodyPadding - 1 - scrollTop\n };\n\n childOpt = jQuery.extend(true, opt, childOpt);\n popup.call(self, childOpt, _items, Number(depth) + 1, path);\n } else {\n self.queue.splice(Number(depth) + 1).forEach(function (n) {\n n.$target.remove();\n });\n }\n }\n }\n\n depth = null;\n index = null;\n path = null;\n $this = null;\n offset = null;\n scrollTop = null;\n childOpt = null;\n _items = null;\n _activeMenu = null;\n });\n\n // mouse out\n activeMenu.find('[data-menu-item-index]').bind(\"mouseout\", function () {\n var depth = this.getAttribute(\"data-menu-item-depth\"),\n index = this.getAttribute(\"data-menu-item-index\"),\n path = this.getAttribute(\"data-menu-item-path\"),\n _items;\n\n _items = self.queue[depth].data[cfg.columnKeys.items][index][cfg.columnKeys.items];\n if (_items && _items.length > 0) {} else {\n jQuery(this).removeClass(\"hover\");\n }\n });\n\n // is Root\n if (depth == 0) {\n if (data.direction) activeMenu.addClass(\"direction-\" + data.direction);\n onStateChanged.call(this, null, {\n self: this,\n items: items,\n parent: function (path) {\n if (!path) return false;\n var item = null;\n try {\n item = Function(\"\", \"return this.config.items[\" + path.substring(5).replace(/\\./g, '].items[') + \"];\").call(self);\n } catch (e) {}\n return item;\n }(data['@path']),\n state: \"popup\"\n });\n }\n\n align.call(this, activeMenu, data);\n onLoad.call(this, {\n self: this,\n items: items,\n element: activeMenu.get(0)\n });\n\n data = null;\n activeMenu = null;\n removed = null;\n opt = null;\n items = null;\n depth = null;\n path = null;\n\n return this;\n },\n clickItem = function clickItem(e, target, item) {\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-menu-item-index\")) {\n return true;\n }\n });\n if (target) {\n item = function (path) {\n if (!path) return false;\n var item;\n try {\n item = Function(\"\", \"return this.config.items[\" + path.substring(5).replace(/\\./g, '].' + cfg.columnKeys.items + '[') + \"];\").call(self);\n } catch (e) {\n console.log(ax5.info.getError(\"ax5menu\", \"501\", \"menuItemClick\"));\n }\n\n try {\n return item;\n } finally {\n item = null;\n }\n }(target.getAttribute(\"data-menu-item-path\"));\n\n if (!item) return this;\n\n if (item.check) {\n (function (items) {\n var setValue = {\n 'checkbox': function checkbox(value) {\n this.checked = !value;\n },\n 'radio': function radio(value) {\n var name = this.name;\n items.forEach(function (n) {\n if (n.check && n.check.type === 'radio' && n.check.name == name) {\n n.check.checked = false;\n }\n });\n this.checked = !value;\n }\n };\n if (setValue[this.type]) setValue[this.type].call(this, this.checked);\n setValue = null;\n }).call(item.check, cfg.items);\n\n if (!cfg.itemClickAndClose) {\n self.queue.forEach(function (n) {\n n.$target.find('[data-menu-item-index]').each(function () {\n var item = n.data[cfg.columnKeys.items][this.getAttribute(\"data-menu-item-index\")];\n if (item.check) {\n jQuery(this).find(\".item-checkbox-wrap\").attr(\"data-item-checked\", item.check.checked);\n }\n });\n });\n }\n }\n\n if (self.onClick) {\n self.onClick.call(item, item);\n }\n if ((!item[cfg.columnKeys.items] || item[cfg.columnKeys.items].length == 0) && cfg.itemClickAndClose) self.close();\n } else {\n self.close();\n }\n\n target = null;\n item = null;\n return this;\n },\n align = function align(activeMenu, data) {\n //console.log(data['@parent']);\n var $window = jQuery(window),\n $document = jQuery(document),\n wh = cfg.position == \"fixed\" ? $window.height() : $document.height(),\n ww = $window.width(),\n h = activeMenu.outerHeight(),\n w = activeMenu.outerWidth(),\n l = data.left,\n t = data.top,\n position = cfg.position || \"fixed\";\n\n if (l + w > ww) {\n if (data['@parent']) {\n l = data['@parent'].left - w + cfg.menuBodyPadding;\n } else {\n l = ww - w;\n }\n }\n\n if (t + h > wh) {\n t = wh - h;\n }\n\n activeMenu.css({ left: l, top: t, position: position });\n\n activeMenu = null;\n data = null;\n $window = null;\n $document = null;\n wh = null;\n ww = null;\n h = null;\n w = null;\n l = null;\n t = null;\n position = null;\n return this;\n };\n\n /// private end\n\n this.init = function () {\n self.menuId = ax5.getGuid();\n\n /**\n * config에 선언된 이벤트 함수들을 this로 이동시켜 주어 나중에 인스턴스.on... 으로 처리 가능 하도록 변경\n */\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n this.onLoad = cfg.onLoad;\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"init\"\n });\n };\n\n /**\n * @method ax5.ui.menu.popup\n * @param {Event|Object} e - Event or Object\n * @param {Object} [opt]\n * @param {String} [opt.theme]\n * @param {Function} [opt.filter]\n * @returns {ax5.ui.menu} this\n */\n this.popup = function () {\n\n var getOption = {\n 'event': function event(e, opt) {\n //var xOffset = Math.max(document.documentElement.scrollLeft, document.body.scrollLeft);\n //var yOffset = Math.max(document.documentElement.scrollTop, document.body.scrollTop);\n //console.log(e.pageY);\n\n e = {\n left: e.clientX,\n top: cfg.position == \"fixed\" ? e.clientY : e.pageY,\n width: cfg.width,\n theme: cfg.theme\n };\n\n if (cfg.offset) {\n if (cfg.offset.left) e.left += cfg.offset.left;\n if (cfg.offset.top) e.top += cfg.offset.top;\n }\n opt = jQuery.extend(true, e, opt);\n\n try {\n return opt;\n } finally {\n e = null;\n //opt = null;\n }\n },\n 'object': function object(e, opt) {\n e = {\n left: e.left,\n top: e.top,\n width: e.width || cfg.width,\n theme: e.theme || cfg.theme\n };\n\n if (cfg.offset) {\n if (cfg.offset.left) e.left += cfg.offset.left;\n if (cfg.offset.top) e.top += cfg.offset.top;\n }\n\n opt = jQuery.extend(true, e, opt);\n\n try {\n return opt;\n } finally {\n e = null;\n //opt = null;\n }\n }\n };\n var updateTheme = function updateTheme(theme) {\n if (theme) cfg.theme = theme;\n };\n\n return function (e, opt) {\n\n if (!e) return this;\n opt = getOption[typeof e.clientX == \"undefined\" ? \"object\" : \"event\"].call(this, e, opt);\n updateTheme(opt.theme);\n\n var items = [].concat(cfg.items);\n if (opt.filter) {\n var filteringItem = function filteringItem(_items) {\n var arr = [];\n _items.forEach(function (n) {\n if (n.items && n.items.length > 0) {\n n.items = filteringItem(n.items);\n }\n if (opt.filter.call(n)) {\n arr.push(n);\n }\n });\n return arr;\n };\n items = filteringItem(items);\n }\n\n if (items.length) {\n popup.call(this, opt, items, 0); // 0 is seq of queue\n appEventAttach.call(this, true); // 이벤트 연결\n }\n\n e = null;\n //opt = null;\n return this;\n };\n }();\n\n /**\n * @method ax5.ui.menu.attach\n * @param {Element|jQueryObject} el\n * @returns {ax5.ui.menu} this\n */\n this.attach = function () {\n\n var getOption = {\n 'object': function object(e, opt) {\n e = {\n left: e.left,\n top: e.top,\n width: e.width || cfg.width,\n theme: e.theme || cfg.theme,\n direction: e.direction || cfg.direction\n };\n opt = jQuery.extend(true, opt, e);\n\n try {\n return opt;\n } finally {\n e = null;\n opt = null;\n }\n }\n };\n\n var popUpChildMenu = function popUpChildMenu(target, opt, eType) {\n var $target = jQuery(target),\n offset = $target.offset(),\n height = $target.outerHeight(),\n index = Number(target.getAttribute(\"data-menu-item-index\")),\n scrollTop = cfg.position == \"fixed\" ? jQuery(document).scrollTop() : 0;\n\n if (cfg.items && cfg.items[index][cfg.columnKeys.items] && cfg.items[index][cfg.columnKeys.items].length) {\n\n if (self.menuBar.openedIndex == index) {\n if (eType == \"click\") self.close();\n return false;\n }\n\n self.menuBar.target.find('[data-menu-item-index]').removeClass(\"hover\");\n self.menuBar.opened = true;\n self.menuBar.openedIndex = index;\n\n $target.attr(\"data-menu-item-opened\", \"true\");\n $target.addClass(\"hover\");\n\n if (cfg.offset) {\n if (cfg.offset.left) offset.left += cfg.offset.left;\n if (cfg.offset.top) offset.top += cfg.offset.top;\n }\n\n opt = getOption[\"object\"].call(this, { left: offset.left, top: offset.top + height - scrollTop }, opt);\n\n popup.call(self, opt, cfg.items[index][cfg.columnKeys.items], 0, 'root.' + target.getAttribute(\"data-menu-item-index\")); // 0 is seq of queue\n appEventAttach.call(self, true); // 이벤트 연결\n }\n\n target = null;\n opt = null;\n $target = null;\n offset = null;\n height = null;\n index = null;\n scrollTop = null;\n };\n var clickParentMenu = function clickParentMenu(target, opt, eType) {\n var $target = jQuery(target),\n offset = $target.offset(),\n height = $target.outerHeight(),\n index = Number(target.getAttribute(\"data-menu-item-index\")),\n scrollTop = cfg.position == \"fixed\" ? jQuery(document).scrollTop() : 0;\n if (cfg.items && (!cfg.items[index][cfg.columnKeys.items] || cfg.items[index][cfg.columnKeys.items].length == 0)) {\n if (self.onClick) {\n self.onClick.call(cfg.items[index], cfg.items[index]);\n }\n }\n };\n\n return function (el, opt) {\n var data = {},\n items = cfg.items,\n activeMenu;\n\n if (typeof opt === \"undefined\") opt = {};\n\n data.theme = opt.theme || cfg.theme;\n data.cfg = {\n icons: jQuery.extend({}, cfg.icons),\n iconWidth: opt.iconWidth || cfg.iconWidth,\n acceleratorWidth: opt.acceleratorWidth || cfg.acceleratorWidth\n };\n\n items.forEach(function (n) {\n if (n.html || n.divide) {\n n['@isMenu'] = false;\n if (n.html) {\n n['@html'] = n.html.call({\n item: n,\n config: cfg,\n opt: opt\n });\n }\n } else {\n n['@isMenu'] = true;\n }\n });\n\n data[cfg.columnKeys.items] = items;\n\n activeMenu = jQuery(MENU.tmpl.get.call(this, \"tmplMenubar\", data, cfg.columnKeys));\n self.menuBar = {\n target: jQuery(el),\n opened: false\n };\n self.menuBar.target.html(activeMenu);\n\n // click, mouseover\n self.menuBar.target.bind(\"click\", function (e) {\n if (!e) return this;\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-menu-item-index\")) {\n return true;\n }\n });\n if (target) {\n clickParentMenu(target, opt, \"click\");\n popUpChildMenu(target, opt, \"click\");\n }\n\n target = null;\n });\n self.menuBar.target.bind(\"mouseover\", function (e) {\n if (!self.menuBar.opened) return false;\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-menu-item-index\")) {\n return true;\n }\n });\n if (target) popUpChildMenu(target, opt, \"mouseover\");\n\n target = null;\n });\n\n el = null;\n opt = null;\n data = null;\n items = null;\n activeMenu = null;\n\n return this;\n };\n }();\n\n /**\n * @method ax5.ui.menu.close\n * @returns {ax5.ui.menu} this\n */\n this.close = function () {\n\n if (self.menuBar && self.menuBar.target) {\n self.menuBar.target.find('[data-menu-item-index]').removeClass(\"hover\");\n self.menuBar.opened = false;\n self.menuBar.openedIndex = null;\n }\n\n appEventAttach.call(this, false); // 이벤트 제거\n\n this.queue.forEach(function (n) {\n n.$target.remove();\n });\n this.queue = [];\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"close\"\n });\n\n return this;\n };\n\n /**\n * @method ax5.ui.menu.getCheckValue\n * @returns {Object} statusCheckItem\n */\n this.getCheckValue = function () {\n var checkItems = {},\n _collectItem = function collectItem(items) {\n var i = items.length;\n while (i--) {\n if (items[i].check && items[i].check.checked) {\n if (!checkItems[items[i].check.name]) checkItems[items[i].check.name] = items[i].check.value;else {\n if (U.isString(checkItems[items[i].check.name])) checkItems[items[i].check.name] = [checkItems[items[i].check.name]];\n checkItems[items[i].check.name].push(items[i].check.value);\n }\n }\n if (items[i].items && items[i].items.length > 0) _collectItem(items[i].items);\n }\n };\n\n _collectItem(cfg.items);\n\n try {\n return checkItems;\n } finally {\n checkItems = null;\n _collectItem = null;\n }\n };\n\n // 클래스 생성자\n this.main = function () {\n\n UI.menu_instance = UI.menu_instance || [];\n UI.menu_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5menu;\n }());\n\n MENU = ax5.ui.menu;\n})();\n\n// todo : menu 드랍다운 아이콘 설정 기능 추가\n// ax5.ui.menu.tmpl\n(function () {\n var MENU = ax5.ui.menu;\n\n var tmpl = function tmpl(columnKeys) {\n return '\\n \\n ';\n };\n var tmplMenubar = function tmplMenubar(columnKeys) {\n return '\\n \\n ';\n };\n\n MENU.tmpl = {\n \"tmpl\": tmpl,\n \"tmplMenubar\": tmplMenubar,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(MENU.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.select\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var SELECT;\n\n UI.addClass({\n className: \"select\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5select\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var options = [];\n * for (var i = 0; i < 20; i++) {\n * options.push({value: i, text: \"optionText\" + i});\n * }\n * var mySelect = new ax5.ui.select({\n * theme: \"danger\"\n * });\n * mySelect.bind({\n * theme: \"primary\",\n * target: $('[data-ax5select=\"select1\"]'),\n * options: options,\n * onChange: function () {\n * console.log(this);\n * },\n * onClose: function () {\n * console.log(this);\n * },\n * onStateChanged: function () {\n * console.log(this);\n * }\n * });\n * ```\n */\n var ax5select = function ax5select() {\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 100,\n lang: {\n noSelected: '',\n noOptions: 'no options',\n loading: 'now loading..',\n multipleLabel: '\"{{label}}\"외 {{length}}건'\n },\n columnKeys: {\n optionValue: 'value',\n optionText: 'text',\n optionSelected: 'selected'\n }\n };\n this.queue = [];\n this.activeSelectOptionGroup = null;\n this.activeSelectQueueIndex = -1;\n this.openTimer = null;\n this.closeTimer = null;\n this.waitOptionsCallback = null;\n this.keyUpTimer = null;\n this.xvar = {};\n\n cfg = this.config;\n\n var $window = jQuery(window);\n var ctrlKeys = {\n \"18\": \"KEY_ALT\",\n \"8\": \"KEY_BACKSPACE\",\n \"17\": \"KEY_CONTROL\",\n \"46\": \"KEY_DELETE\",\n \"40\": \"KEY_DOWN\",\n \"35\": \"KEY_END\",\n \"187\": \"KEY_EQUAL\",\n \"27\": \"KEY_ESC\",\n \"36\": \"KEY_HOME\",\n \"45\": \"KEY_INSERT\",\n \"37\": \"KEY_LEFT\",\n \"189\": \"KEY_MINUS\",\n \"34\": \"KEY_PAGEDOWN\",\n \"33\": \"KEY_PAGEUP\",\n // \"190\": \"KEY_PERIOD\",\n \"13\": \"KEY_RETURN\",\n \"39\": \"KEY_RIGHT\",\n \"16\": \"KEY_SHIFT\",\n // \"32\": \"KEY_SPACE\",\n \"9\": \"KEY_TAB\",\n \"38\": \"KEY_UP\",\n \"91\": \"KEY_WINDOW\"\n //\"107\" : \"NUMPAD_ADD\",\n //\"194\" : \"NUMPAD_COMMA\",\n //\"110\" : \"NUMPAD_DECIMAL\",\n //\"111\" : \"NUMPAD_DIVIDE\",\n //\"12\" : \"NUMPAD_EQUAL\",\n //\"106\" : \"NUMPAD_MULTIPLY\",\n //\"109\" : \"NUMPAD_SUBTRACT\"\n },\n onStateChanged = function onStateChanged(item, that) {\n if (item && item.onStateChanged) {\n item.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n if (that.state == \"changeValue\") {\n if (item && item.onChange) {\n item.onChange.call(that, that);\n } else if (this.onChange) {\n this.onChange.call(that, that);\n }\n }\n\n item = null;\n that = null;\n return true;\n },\n alignSelectDisplay = function alignSelectDisplay() {\n var i = this.queue.length,\n w;\n while (i--) {\n if (this.queue[i].$display) {\n w = Math.max(this.queue[i].$select.outerWidth(), U.number(this.queue[i].minWidth));\n this.queue[i].$display.css({\n \"min-width\": w\n });\n if (this.queue[i].reset) {\n this.queue[i].$display.find(\".addon-icon-reset\").css({\n \"line-height\": this.queue[i].$display.height() + \"px\"\n });\n }\n }\n }\n\n i = null;\n w = null;\n return this;\n },\n alignSelectOptionGroup = function alignSelectOptionGroup(append) {\n if (!this.activeSelectOptionGroup) return this;\n\n var item = this.queue[this.activeSelectQueueIndex],\n pos = {},\n positionMargin = 0,\n dim = {},\n pickerDim = {},\n pickerDirection;\n\n if (append) jQuery(document.body).append(this.activeSelectOptionGroup);\n\n pos = item.$target.offset();\n dim = {\n width: item.$target.outerWidth(),\n height: item.$target.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), jQuery(document.body).width()),\n winHeight: Math.max($window.height(), jQuery(document.body).height()),\n width: this.activeSelectOptionGroup.outerWidth(),\n height: this.activeSelectOptionGroup.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n if (!item.direction || item.direction === \"\" || item.direction === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = item.direction;\n }\n // todo : 표현할 공간이 없다면..\n if (append) {\n this.activeSelectOptionGroup.addClass(\"direction-\" + pickerDirection);\n }\n this.activeSelectOptionGroup.css(function () {\n if (pickerDirection == \"top\") {\n if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n\n var newTop = pos.top + dim.height / 2 - pickerDim.height / 2;\n if (newTop + pickerDim.height + positionMargin > pickerDim.winHeight) {\n newTop = 0;\n }\n if (newTop < 0) {\n newTop = 0;\n }\n\n return {\n left: pos.left,\n top: newTop,\n width: dim.width\n };\n }\n return {\n left: pos.left,\n top: pos.top + dim.height + 1,\n width: dim.width\n };\n } else if (pickerDirection == \"bottom\") {\n return {\n left: pos.left,\n top: pos.top - pickerDim.height - 1,\n width: dim.width\n };\n }\n }.call(this));\n },\n onBodyClick = function onBodyClick(e, target) {\n if (!this.activeSelectOptionGroup) return this;\n\n var item = this.queue[this.activeSelectQueueIndex],\n clickEl = \"display\";\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-option-value\")) {\n clickEl = \"optionItem\";\n return true;\n } else if (item.$target.get(0) == target) {\n clickEl = \"display\";\n return true;\n }\n });\n\n if (!target) {\n this.close();\n return this;\n } else if (clickEl === \"optionItem\") {\n this.val(item.id, {\n index: {\n gindex: target.getAttribute(\"data-option-group-index\"),\n index: target.getAttribute(\"data-option-index\")\n }\n }, undefined, \"internal\");\n item.$select.trigger(\"change\");\n item.$display.focus();\n if (!item.multiple) this.close();\n } else {\n //open and display click\n //console.log(this.instanceId);\n }\n\n return this;\n },\n onBodyKeyup = function onBodyKeyup(e) {\n if (e.keyCode == ax5.info.eventKeys.ESC) {\n this.close();\n } else if (e.which == ax5.info.eventKeys.RETURN) {\n if (this.queue[this.activeSelectQueueIndex].optionFocusIndex > -1) {\n // 아이템에 포커스가 활성화 된 후, 마우스 이벤트 이면 무시\n var $option = this.activeSelectOptionGroup.find('[data-option-focus-index=\"' + this.queue[this.activeSelectQueueIndex].optionFocusIndex + '\"]');\n this.val(this.queue[this.activeSelectQueueIndex].id, {\n index: {\n gindex: $option.attr(\"data-option-group-index\"),\n index: $option.attr(\"data-option-index\")\n }\n }, undefined, \"internal\");\n this.queue[this.activeSelectQueueIndex].$select.trigger(\"change\");\n if (!this.queue[this.activeSelectQueueIndex].multiple) this.close();\n } else {\n this.close();\n }\n }\n },\n getLabel = function getLabel(queIdx) {\n var item = this.queue[queIdx];\n var labels = [];\n\n if (U.isArray(item.selected) && item.selected.length > 0) {\n item.selected.forEach(function (n) {\n if (n.selected) labels.push(n[item.columnKeys.optionText]);\n });\n } else {\n if (!item.multiple && item.options && item.options[0]) {\n if (item.options[0].optgroup) {\n labels[0] = item.options[0].options[0][item.columnKeys.optionText];\n } else {\n labels[0] = item.options[0][item.columnKeys.optionText];\n }\n } else {\n labels[0] = item.lang.noSelected;\n }\n }\n\n return function () {\n if (item.multiple && labels.length > 1) {\n var data = {\n label: labels[0],\n length: labels.length - 1\n };\n return ax5.mustache.render(item.lang.multipleLabel, data);\n } else {\n return labels[0];\n }\n }();\n },\n syncLabel = function syncLabel(queIdx) {\n this.queue[queIdx].$displayLabel.html(getLabel.call(this, queIdx));\n },\n focusWord = function focusWord(queIdx, searchWord) {\n var options = [],\n i = -1,\n l = this.queue[queIdx].indexedOptions.length - 1,\n n;\n if (searchWord) {\n while (l - i++) {\n n = this.queue[queIdx].indexedOptions[i];\n if (('' + n.value).toLowerCase() == searchWord.toLowerCase()) {\n options = [{ '@findex': n['@findex'], optionsSort: 0 }];\n break;\n } else {\n var sort = ('' + n.value).toLowerCase().search(searchWord.toLowerCase());\n if (sort > -1) {\n options.push({ '@findex': n['@findex'], optionsSort: sort });\n if (options.length > 2) break;\n }\n sort = null;\n }\n }\n options.sort(function (a, b) {\n return a.optionsSort - b.optionsSort;\n });\n }\n if (options && options.length > 0) {\n focusMove.call(this, queIdx, undefined, options[0]['@findex']);\n }\n\n try {\n return options;\n } finally {\n options = null;\n i = null;\n l = null;\n n = null;\n }\n },\n focusMove = function focusMove(queIdx, direction, findex) {\n var _focusIndex, _prevFocusIndex, focusOptionEl, optionGroupScrollContainer;\n if (this.activeSelectOptionGroup && this.queue[queIdx].options && this.queue[queIdx].options.length > 0) {\n\n if (typeof findex !== \"undefined\") {\n _focusIndex = findex;\n } else {\n _prevFocusIndex = this.queue[queIdx].optionFocusIndex == -1 ? this.queue[queIdx].optionSelectedIndex || -1 : this.queue[queIdx].optionFocusIndex;\n if (_prevFocusIndex == -1) {\n _focusIndex = direction > 0 ? 0 : this.queue[queIdx].optionItemLength - 1;\n } else {\n _focusIndex = _prevFocusIndex + direction;\n if (_focusIndex < 0) _focusIndex = 0;else if (_focusIndex > this.queue[queIdx].optionItemLength - 1) _focusIndex = this.queue[queIdx].optionItemLength - 1;\n }\n }\n\n this.queue[queIdx].optionFocusIndex = _focusIndex;\n\n this.activeSelectOptionGroup.find('[data-option-focus-index]').removeClass(\"hover\");\n\n focusOptionEl = this.activeSelectOptionGroup.find('[data-option-focus-index=\"' + _focusIndex + '\"]').addClass(\"hover\");\n\n optionGroupScrollContainer = this.activeSelectOptionGroup.find('[data-els=\"content\"]');\n\n var focusOptionElHeight = focusOptionEl.outerHeight(),\n optionGroupScrollContainerHeight = optionGroupScrollContainer.innerHeight(),\n optionGroupScrollContainerScrollTop = optionGroupScrollContainer.scrollTop(),\n focusOptionElTop = focusOptionEl.position().top + optionGroupScrollContainer.scrollTop();\n\n if (optionGroupScrollContainerHeight + optionGroupScrollContainerScrollTop < focusOptionElTop + focusOptionElHeight) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop + focusOptionElHeight - optionGroupScrollContainerHeight);\n } else if (optionGroupScrollContainerScrollTop > focusOptionElTop) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop);\n }\n // optionGroup scroll check\n }\n },\n bindSelectTarget = function () {\n var focusWordCall = U.debounce(function (searchWord, queIdx) {\n focusWord.call(self, queIdx, searchWord);\n self.queue[queIdx].$displayInput.val('');\n }, 300);\n\n var selectEvent = {\n 'click': function click(queIdx, e) {\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-selected-clear\")) {\n //clickEl = \"clear\";\n return true;\n }\n });\n\n if (target) {\n this.val(queIdx, { clear: true });\n } else {\n if (self.activeSelectQueueIndex == queIdx) {\n if (this.queue[queIdx].optionFocusIndex == -1) {\n // 아이템에 포커스가 활성화 된 후, 마우스 이벤트 이면 무시\n self.close();\n }\n } else {\n self.open(queIdx);\n U.stopEvent(e);\n }\n }\n },\n 'keyUp': function keyUp(queIdx, e) {\n if (e.which == ax5.info.eventKeys.SPACE) {\n selectEvent.click.call(this, queIdx, e);\n } else if (!ctrlKeys[e.which]) {\n // 사용자 입력이 뜸해지면 찾고 검색 값 제거...\n focusWordCall(this.queue[queIdx].$displayInput.val(), queIdx);\n }\n },\n 'keyDown': function keyDown(queIdx, e) {\n if (e.which == ax5.info.eventKeys.DOWN) {\n focusMove.call(this, queIdx, 1);\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.UP) {\n focusMove.call(this, queIdx, -1);\n U.stopEvent(e);\n }\n },\n 'blur': function blur(queIdx, e) {},\n 'selectChange': function selectChange(queIdx, e) {\n this.val(queIdx, this.queue[queIdx].$select.val(), true);\n }\n };\n return function (queIdx) {\n var item = this.queue[queIdx];\n var data = {};\n item.selected = [];\n\n if (!item.$display) {\n /// 템플릿에 전달할 오브젝트 선언\n data.instanceId = this.instanceId;\n data.id = item.id;\n data.name = item.name;\n data.theme = item.theme;\n data.tabIndex = item.tabIndex;\n data.multiple = item.multiple;\n data.reset = item.reset;\n\n data.label = getLabel.call(this, queIdx);\n data.formSize = function () {\n return item.size ? \"input-\" + item.size : \"\";\n }();\n\n item.$display = SELECT.tmpl.get.call(this, \"tmpl\", data);\n item.$displayLabel = item.$display.find('[data-ax5select-display=\"label\"]');\n\n if (item.$target.find(\"select\").get(0)) {\n item.$select = item.$target.find(\"select\");\n // select 속성만 변경\n item.$select.attr(\"tabindex\", \"-1\").attr(\"class\", \"form-control \" + data.formSize);\n if (data.name) {\n item.$select.attr(\"name\", \"name\");\n }\n if (data.multiple) {\n item.$select.attr(\"multiple\", \"multiple\");\n }\n } else {\n item.$select = SELECT.tmpl.get.call(this, \"selectTmpl\", data);\n item.$target.append(item.$select);\n // select append\n }\n\n item.$target.append(item.$display);\n item.$displayInput = item.$display.find('[data-ax5select-display=\"input\"]'); // 사용자 입력값을 받기위한 숨음 입력필드\n item.options = syncSelectOptions.call(this, queIdx, item.options);\n\n alignSelectDisplay.call(this);\n\n item.$displayInput.unbind(\"blur.ax5select\").bind(\"blur.ax5select\", selectEvent.blur.bind(this, queIdx)).unbind('keyup.ax5select').bind('keyup.ax5select', selectEvent.keyUp.bind(this, queIdx)).unbind(\"keydown.ax5select\").bind(\"keydown.ax5select\", selectEvent.keyDown.bind(this, queIdx));\n } else {\n item.$displayLabel.html(getLabel.call(this, queIdx));\n item.options = syncSelectOptions.call(this, queIdx, item.options);\n\n alignSelectDisplay.call(this);\n }\n\n item.$display.unbind('click.ax5select').bind('click.ax5select', selectEvent.click.bind(this, queIdx)).unbind('keyup.ax5select').bind('keyup.ax5select', selectEvent.keyUp.bind(this, queIdx));\n\n // select 태그에 대한 change 이벤트 감시\n item.$select.unbind('change.ax5select').bind('change.ax5select', selectEvent.selectChange.bind(this, queIdx));\n\n data = null;\n item = null;\n queIdx = null;\n return this;\n };\n }(),\n syncSelectOptions = function () {\n var setSelected = function setSelected(queIdx, O) {\n if (!O) {\n this.queue[queIdx].selected = [];\n } else {\n if (this.queue[queIdx].multiple) this.queue[queIdx].selected.push(jQuery.extend({}, O));else this.queue[queIdx].selected[0] = jQuery.extend({}, O);\n }\n };\n\n return function (queIdx, options) {\n var item = this.queue[queIdx];\n var po,\n elementOptions,\n newOptions,\n focusIndex = 0;\n setSelected.call(this, queIdx, false); // item.selected 초기화\n\n if (options) {\n item.options = options;\n item.indexedOptions = [];\n\n // select options 태그 생성\n po = [];\n item.options.forEach(function (O, OIndex) {\n if (O.optgroup) {\n // todo\n O['@gindex'] = OIndex;\n O.options.forEach(function (OO, OOIndex) {\n OO['@index'] = OOIndex;\n OO['@findex'] = focusIndex;\n po.push('
');\n if (OO[item.columnKeys.optionSelected]) {\n setSelected.call(self, queIdx, OO);\n }\n\n item.indexedOptions.push({\n '@findex': focusIndex, value: OO[item.columnKeys.optionValue], text: OO[item.columnKeys.optionText]\n });\n focusIndex++;\n });\n } else {\n O['@index'] = OIndex;\n O['@findex'] = focusIndex;\n po.push('
');\n if (O[item.columnKeys.optionSelected]) {\n setSelected.call(self, queIdx, O);\n }\n\n item.indexedOptions.push({\n '@findex': focusIndex, value: O[item.columnKeys.optionValue], text: O[item.columnKeys.optionText]\n });\n focusIndex++;\n }\n });\n\n item.optionItemLength = focusIndex;\n item.$select.html(po.join(''));\n } else {\n /// select > options 태그로 스크립트 options를 만들어주는 역할\n elementOptions = U.toArray(item.$select.get(0).options);\n // select option 스크립트 생성\n newOptions = [];\n elementOptions.forEach(function (O, OIndex) {\n var option = {};\n //if (O.value != \"\") {\n option[item.columnKeys.optionValue] = O.value;\n option[item.columnKeys.optionText] = O.text;\n option[item.columnKeys.optionSelected] = O.selected;\n option['@index'] = OIndex;\n option['@findex'] = OIndex;\n if (O.selected) setSelected.call(self, queIdx, option);\n newOptions.push(option);\n //}\n option = null;\n });\n item.options = newOptions;\n item.indexedOptions = newOptions;\n }\n\n if (!item.multiple && item.selected.length == 0 && item.options && item.options[0]) {\n if (item.options[0].optgroup) {\n item.options[0].options[0][item.columnKeys.optionSelected] = true;\n item.selected.push(jQuery.extend({}, item.options[0].options[0]));\n } else {\n item.options[0][item.columnKeys.optionSelected] = true;\n item.selected.push(jQuery.extend({}, item.options[0]));\n }\n }\n\n po = null;\n elementOptions = null;\n newOptions = null;\n return item.options;\n };\n }(),\n getQueIdx = function getQueIdx(boundID) {\n if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-ax5select-id\");\n }\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5select\", \"402\", \"getQueIdx\"));\n return;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n };\n /// private end\n\n /**\n * Preferences of select UI\n * @method ax5select.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5select}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onChange = cfg.onChange;\n\n jQuery(window).bind(\"resize.ax5select-display-\" + this.instanceId, function () {\n alignSelectDisplay.call(this);\n }.bind(this));\n };\n\n /**\n * bind select\n * @method ax5select.bind\n * @param {Object} item\n * @param {String} [item.id]\n * @param {String} [item.theme]\n * @param {Boolean} [item.multiple]\n * @param {Element} item.target\n * @param {Object[]} item.options\n * @returns {ax5select}\n */\n this.bind = function (item) {\n var selectConfig = {},\n queIdx;\n\n item = jQuery.extend(true, selectConfig, cfg, item);\n\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5select\", \"401\", \"bind\"));\n return this;\n }\n\n item.$target = jQuery(item.target);\n\n if (!item.id) item.id = item.$target.data(\"data-ax5select-id\");\n if (!item.id) {\n item.id = 'ax5select-' + ax5.getGuid();\n item.$target.data(\"data-ax5select-id\", item.id);\n }\n item.name = item.$target.attr(\"data-ax5select\");\n\n if (item.options) {\n item.options = JSON.parse(JSON.stringify(item.options));\n }\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n item = jQuery.extend(true, item, data);\n }\n })(U.parseJson(item.$target.attr(\"data-ax5select-config\"), true));\n\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindSelectTarget.call(this, this.queue.length - 1);\n } else {\n this.queue[queIdx].selected = [];\n this.queue[queIdx].options = item.options;\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindSelectTarget.call(this, queIdx);\n }\n\n selectConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * open the optionBox of select\n * @method ax5select.open\n * @param {(String|Number|Element)} boundID\n * @param {Number} [tryCount]\n * @returns {ax5select}\n */\n this.open = function () {\n\n var onExpand = function onExpand(item) {\n item.onExpand.call({\n self: this,\n item: item\n }, function (O) {\n if (this.waitOptionsCallback) {\n var data = {};\n var item = this.queue[this.activeSelectQueueIndex];\n\n /// 현재 selected 검증후 처리\n (function (item, O) {\n var optionsMap = {};\n O.options.forEach(function (_O, _OIndex) {\n _O[\"@index\"] = _OIndex;\n optionsMap[_O[item.columnKeys.optionValue]] = _O;\n });\n if (U.isArray(item.selected)) {\n item.selected.forEach(function (_O) {\n if (optionsMap[_O[item.columnKeys.optionValue]]) {\n O.options[optionsMap[_O[item.columnKeys.optionValue]][\"@index\"]][item.columnKeys.optionSelected] = true;\n }\n });\n }\n })(item, O);\n\n item.$displayLabel.html(getLabel.call(this, this.activeSelectQueueIndex));\n item.options = syncSelectOptions.call(this, this.activeSelectQueueIndex, O.options);\n\n alignSelectDisplay.call(this);\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5select-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n this.activeSelectOptionGroup.find('[data-els=\"content\"]').html(SELECT.tmpl.get.call(this, \"optionsTmpl\", data, item.columnKeys));\n }\n }.bind(this));\n };\n\n return function (boundID, tryCount) {\n this.waitOptionsCallback = null;\n\n /**\n * open select from the outside\n */\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n var data = {},\n focusTop,\n selectedOptionEl;\n\n if (item.$display.attr(\"disabled\")) return this;\n\n if (this.openTimer) clearTimeout(this.openTimer);\n if (this.activeSelectOptionGroup) {\n if (this.activeSelectQueueIndex == queIdx) {\n return this;\n }\n\n if (tryCount > 2) return this;\n this.close();\n this.openTimer = setTimeout(function () {\n this.open(queIdx, (tryCount || 0) + 1);\n }.bind(this), cfg.animateTime);\n\n return this;\n }\n\n item.optionFocusIndex = -1; // optionGroup이 열리면 포커스 인덱스 초기화 -1로\n if (item.selected && item.selected.length > 0) {\n item.optionSelectedIndex = item.selected[0][\"@findex\"];\n }\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5select-option-group-\" + item.size;\n data.multiple = item.multiple;\n\n data.lang = item.lang;\n item.$display.attr(\"data-select-option-group-opened\", \"true\");\n //console.log(data.lang);\n\n if (item.onExpand) {\n // onExpand 인 경우 UI 대기모드 추가\n data.waitOptions = true;\n }\n\n data.options = item.options;\n this.activeSelectOptionGroup = SELECT.tmpl.get.call(this, \"optionGroupTmpl\", data);\n this.activeSelectOptionGroup.find('[data-els=\"content\"]').html(SELECT.tmpl.get.call(this, \"optionsTmpl\", data, item.columnKeys));\n this.activeSelectQueueIndex = queIdx;\n\n alignSelectOptionGroup.call(this, \"append\"); // alignSelectOptionGroup 에서 body append\n jQuery(window).bind(\"resize.ax5select-\" + this.instanceId, function () {\n alignSelectOptionGroup.call(this);\n }.bind(this));\n\n if (item.selected && item.selected.length > 0) {\n selectedOptionEl = this.activeSelectOptionGroup.find('[data-option-index=\"' + item.selected[0][\"@index\"] + '\"]');\n\n if (selectedOptionEl.get(0)) {\n focusTop = selectedOptionEl.position().top - this.activeSelectOptionGroup.height() / 3;\n this.activeSelectOptionGroup.find('[data-els=\"content\"]').stop().animate({ scrollTop: focusTop }, item.animateTime, 'swing', function () {});\n }\n }\n\n /// 사용자 입력으로 옵션을 검색하기 위한 시나리오\n // 옵션그룹이 활성화 되면 사용자 입력을 받기위한 input 값 초기화 및 포커스 다른 select가 닫히면서 display focus 이벤트와 충돌하는 문제가 있으므로\n // 1밀리세컨 지연후 포커스 처리. input에 포커스가 되므로 input value로 options를 검색 할 수 있게 됩니다.\n item.$displayInput.val('');\n\n setTimeout(function () {\n item.$displayInput.trigger(\"focus\");\n\n jQuery(window).bind(\"keyup.ax5select-\" + this.instanceId, function (e) {\n e = e || window.event;\n onBodyKeyup.call(this, e);\n U.stopEvent(e);\n }.bind(this));\n\n jQuery(window).bind(\"click.ax5select-\" + this.instanceId, function (e) {\n e = e || window.event;\n onBodyClick.call(this, e);\n U.stopEvent(e);\n }.bind(this));\n }.bind(this), 300);\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"open\",\n item: item\n });\n\n // waitOption timer\n if (item.onExpand) {\n this.waitOptionsCallback = true;\n onExpand.call(this, item);\n }\n\n data = null;\n focusTop = null;\n selectedOptionEl = null;\n return this;\n };\n }();\n\n /**\n * @method ax5select.update\n * @param {(Object|String)} item\n * @returns {ax5select}\n */\n this.update = function (_item) {\n this.bind(_item);\n return this;\n };\n\n /**\n * @method ax5select.val\n * @param {(String|Number|Element)} boundID\n * @param {(String|Object|Array)} [value]\n * @param {Boolean} [selected]\n * @returns {ax5select}\n */\n this.val = function () {\n\n // todo : val 함수 리팩토링 필요\n var getSelected = function getSelected(_item, o, selected) {\n if (typeof selected === \"undefined\") {\n return _item.multiple ? !o : true;\n } else {\n return selected;\n }\n };\n var clearSelected = function clearSelected(queIdx) {\n this.queue[queIdx].options.forEach(function (n) {\n if (n.optgroup) {\n n.options.forEach(function (nn) {\n nn.selected = false;\n });\n } else {\n n.selected = false;\n }\n });\n };\n\n var processor = {\n 'index': function index(queIdx, value, selected) {\n // 클래스 내부에서 호출된 형태, 그런 이유로 옵션그룹에 대한 상태를 변경 하고 있다.\n var item = this.queue[queIdx];\n\n /*\n if (U.isArray(value.index)) {\n value.index.forEach(function (n) {\n item.options[n][item.columnKeys.optionSelected] = getSelected(item, item.options[n][item.columnKeys.optionSelected], selected);\n self.activeSelectOptionGroup\n .find('[data-option-index=\"' + n + '\"]')\n .attr(\"data-option-selected\", item.options[n][item.columnKeys.optionSelected].toString());\n });\n }\n else {\n }\n */\n if (U.isString(value.index.gindex)) {\n item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected] = getSelected(item, item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected], selected);\n self.activeSelectOptionGroup.find('[data-option-group-index=\"' + value.index.gindex + '\"][data-option-index=\"' + value.index.index + '\"]').attr(\"data-option-selected\", item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected].toString());\n } else {\n item.options[value.index.index][item.columnKeys.optionSelected] = getSelected(item, item.options[value.index.index][item.columnKeys.optionSelected], selected);\n self.activeSelectOptionGroup.find('[data-option-index=\"' + value.index.index + '\"]').attr(\"data-option-selected\", item.options[value.index.index][item.columnKeys.optionSelected].toString());\n }\n\n syncSelectOptions.call(this, queIdx, item.options);\n syncLabel.call(this, queIdx);\n alignSelectOptionGroup.call(this);\n },\n 'arr': function arr(queIdx, values, selected) {\n values.forEach(function (value) {\n if (U.isString(value) || U.isNumber(value)) {\n processor.value.call(self, queIdx, value, selected);\n } else {\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(self, queIdx, value, selected);\n break;\n }\n }\n }\n });\n },\n 'value': function value(queIdx, _value2, selected) {\n var item = this.queue[queIdx];\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionValue] == _value2;\n });\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n } else {\n console.log(ax5.info.getError(\"ax5select\", \"501\", \"val\"));\n return;\n }\n\n syncSelectOptions.call(this, queIdx, item.options);\n syncLabel.call(this, queIdx);\n },\n 'text': function text(queIdx, value, selected) {\n var item = this.queue[queIdx];\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionText] == value;\n });\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n } else {\n console.log(ax5.info.getError(\"ax5select\", \"501\", \"val\"));\n return;\n }\n\n syncSelectOptions.call(this, queIdx, item.options);\n syncLabel.call(this, queIdx);\n },\n 'clear': function clear(queIdx) {\n clearSelected.call(this, queIdx);\n syncSelectOptions.call(this, queIdx, this.queue[queIdx].options);\n syncLabel.call(this, queIdx);\n\n if (this.activeSelectOptionGroup) {\n this.activeSelectOptionGroup.find('[data-option-index]').attr(\"data-option-selected\", \"false\");\n }\n }\n };\n\n return function (boundID, value, selected, internal) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5select\", \"402\", \"val\"));\n return;\n }\n\n // setValue 이면 현재 선택값 초기화\n if (typeof value !== \"undefined\" && !this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n\n if (typeof value == \"undefined\") {\n return this.queue[queIdx].selected;\n } else if (U.isArray(value)) {\n processor.arr.call(this, queIdx, value, selected);\n } else if (U.isString(value) || U.isNumber(value)) {\n processor.value.call(this, queIdx, value, selected);\n } else {\n if (value === null) {\n processor.clear.call(this, queIdx);\n } else {\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(this, queIdx, value, selected);\n break;\n }\n }\n }\n }\n\n if (typeof value !== \"undefined\") {\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n item: this.queue[queIdx],\n state: internal ? \"changeValue\" : \"setValue\",\n value: this.queue[queIdx].selected,\n internal: internal\n });\n }\n\n boundID = null;\n return this;\n };\n }();\n\n /**\n * @method ax5select.close\n * @returns {ax5select}\n */\n this.close = function (item) {\n if (this.closeTimer) clearTimeout(this.closeTimer);\n if (!this.activeSelectOptionGroup) return this;\n\n item = this.queue[this.activeSelectQueueIndex];\n item.optionFocusIndex = -1;\n\n item.$displayInput.val('').trigger(\"blur\");\n item.$display.removeAttr(\"data-select-option-group-opened\").trigger(\"focus\");\n\n this.activeSelectOptionGroup.addClass(\"destroy\");\n\n jQuery(window).unbind(\"resize.ax5select-\" + this.instanceId).unbind(\"click.ax5select-\" + this.instanceId).unbind(\"keyup.ax5select-\" + this.instanceId);\n\n this.closeTimer = setTimeout(function () {\n if (this.activeSelectOptionGroup) this.activeSelectOptionGroup.remove();\n this.activeSelectOptionGroup = null;\n this.activeSelectQueueIndex = -1;\n\n var that = {\n self: this,\n item: item,\n value: item.selected,\n state: \"close\"\n };\n\n onStateChanged.call(this, item, that);\n\n // waitOption timer\n if (item.onClose) {\n item.onClose.call(that);\n }\n }.bind(this), cfg.animateTime);\n this.waitOptionsCallback = null;\n return this;\n };\n\n this.enable = function (boundID) {\n var queIdx = getQueIdx.call(this, boundID);\n this.queue[queIdx].$display.removeAttr(\"disabled\");\n this.queue[queIdx].$select.removeAttr(\"disabled\");\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"enable\"\n });\n\n return this;\n };\n\n this.disable = function (boundID) {\n var queIdx = getQueIdx.call(this, boundID);\n this.queue[queIdx].$display.attr(\"disabled\", \"disabled\");\n this.queue[queIdx].$select.attr(\"disabled\", \"disabled\");\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"disable\"\n });\n\n return this;\n };\n\n // 클래스 생성자\n this.main = function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n } else {\n this.init();\n }\n }.apply(this, arguments);\n };\n return ax5select;\n }());\n SELECT = ax5.ui.select;\n})();\n\nax5.ui.select_instance = new ax5.ui.select();\njQuery.fn.ax5select = function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"open\":\n return ax5.ui.select_instance.open(this);\n break;\n case \"close\":\n return ax5.ui.select_instance.close(this);\n break;\n case \"setValue\":\n return ax5.ui.select_instance.val(this, arguments[1], arguments[2]);\n break;\n case \"getValue\":\n return ax5.ui.select_instance.val(this);\n break;\n case \"enable\":\n return ax5.ui.select_instance.enable(this);\n break;\n case \"disable\":\n return ax5.ui.select_instance.disable(this);\n break;\n default:\n return this;\n }\n } else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.select_instance.bind(config);\n });\n }\n return this;\n };\n}();\n\n// muliple 속성이 없는 select의 기본 선택 해제 방법.. 결정 필요..\n// onExpand 가 있으면..?\n// ax5.ui.select.tmpl\n(function () {\n\n var SELECT = ax5.ui.select;\n\n var optionGroupTmpl = function optionGroupTmpl(columnKeys) {\n return '\\n
\\n';\n };\n var tmpl = function tmpl(columnKeys) {\n return '\\n
\\n \\n
{{label}}
\\n
\\n {{#multiple}}{{#reset}}\\n {{{.}}}\\n {{/reset}}{{/multiple}}\\n {{#icons}}\\n {{clesed}}\\n {{opened}}\\n {{/icons}}\\n {{^icons}}\\n \\n \\n {{/icons}}\\n
\\n
\\n \\n\\n';\n };\n var selectTmpl = function selectTmpl(columnKeys) {\n return '\\n
\\n';\n };\n var optionsTmpl = function optionsTmpl(columnKeys) {\n return '\\n{{#waitOptions}}\\n
\\n
\\n \\n {{{lang.loading}}}\\n \\n
\\n
\\n{{/waitOptions}}\\n{{^waitOptions}}\\n {{#options}}\\n {{#optgroup}}\\n
\\n
\\n \\n {{{.}}}\\n \\n
\\n {{#options}}\\n
\\n
\\n {{#multiple}}\\n \\n \\n \\n {{/multiple}}\\n {{' + columnKeys.optionText + '}}\\n
\\n
\\n {{/options}}\\n
\\n {{/optgroup}}\\n {{^optgroup}}\\n
\\n
\\n {{#multiple}}\\n \\n \\n \\n {{/multiple}}\\n {{' + columnKeys.optionText + '}}\\n
\\n
\\n {{/optgroup}}\\n {{/options}}\\n {{^options}}\\n
\\n
\\n \\n {{{lang.noOptions}}}\\n \\n
\\n
\\n {{/options}}\\n{{/waitOptions}}\\n';\n };\n\n SELECT.tmpl = {\n \"optionGroupTmpl\": optionGroupTmpl,\n \"tmpl\": tmpl,\n \"selectTmpl\": selectTmpl,\n \"optionsTmpl\": optionsTmpl,\n\n get: function get(tmplName, data, columnKeys) {\n return jQuery(ax5.mustache.render(SELECT.tmpl[tmplName].call(this, columnKeys), data));\n }\n };\n})();\n/*\n * Copyright (c) 2016. tom@axisj.com\n * - github.com/thomasjang\n * - www.axisj.com\n */\n\n// ax5.ui.grid\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var GRID;\n\n UI.addClass({\n className: \"grid\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5grid\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```\n * var myGrid = new ax5.ui.grid();\n * ```\n */\n var ax5grid = function ax5grid() {\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 250,\n\n // 틀고정 속성\n frozenColumnIndex: 0,\n frozenRowIndex: 0,\n showLineNumber: false,\n showRowSelector: false,\n multipleSelect: true,\n\n height: 0,\n columnMinWidth: 100,\n lineNumberColumnWidth: 30,\n rowSelectorColumnWidth: 26,\n sortable: undefined,\n remoteSort: false,\n\n header: {\n align: false,\n columnHeight: 26,\n columnPadding: 3,\n columnBorderWidth: 1\n },\n body: {\n align: false,\n columnHeight: 26,\n columnPadding: 3,\n columnBorderWidth: 1,\n grouping: false\n },\n rightSum: false,\n footSum: false,\n page: {\n height: 25,\n display: true,\n navigationItemCount: 5\n },\n scroller: {\n size: 15,\n barMinSize: 15,\n trackPadding: 4\n },\n columnKeys: {\n selected: '__selected__',\n modified: '__modified__',\n deleted: '__deleted__',\n disableSelection: '__disable_selection__'\n }\n };\n this.xvar = {\n bodyTrHeight: 0, // 한줄의 높이\n scrollContentWidth: 0, // 스크롤 될 내용물의 너비 (스크롤 될 내용물 : panel['body-scroll'] 안에 컬럼이 있는)\n scrollContentHeight: 0 // 스크롤 된 내용물의 높이\n };\n\n // 그리드 데이터셋\n this.columns = []; // config.columns에서 복제된 오브젝트\n this.colGroup = []; // columns를 table태그로 출력하기 좋게 변환한 오브젝트\n this.footSumColumns = [];\n this.bodyGrouping = {};\n\n this.list = []; // 그리드의 데이터\n this.page = {}; // 그리드의 페이지 정보\n this.selectedDataIndexs = [];\n this.deletedList = [];\n this.sortInfo = {}; // 그리드의 헤더 정렬 정보\n this.focusedColumn = {}; // 그리드 바디의 포커스된 셀 정보\n this.selectedColumn = {}; // 그리드 바디의 선택된 셀 정보\n this.isInlineEditing = false;\n this.inlineEditing = {};\n\n // header\n this.headerTable = {};\n this.leftHeaderData = {};\n this.headerData = {};\n this.rightHeaderData = {};\n\n // body\n this.bodyRowTable = {};\n this.leftBodyRowData = {};\n this.bodyRowData = {};\n this.rightBodyRowData = {};\n this.bodyRowMap = {};\n\n this.bodyGroupingTable = {};\n this.leftBodyGroupingData = {};\n this.bodyGroupingData = {};\n this.rightBodyGroupingData = {};\n\n // footSum\n this.footSumTable = {}; // footSum의 출력레이아웃\n this.leftFootSumData = {}; // frozenColumnIndex 를 기준으로 나누어진 출력 레이아웃 왼쪽\n this.footSumData = {}; // frozenColumnIndex 를 기준으로 나누어진 출력 레이아웃 오른쪽\n this.needToPaintSum = true; // 데이터 셋이 변경되어 summary 변경 필요여부\n\n cfg = this.config;\n\n var onStateChanged = function onStateChanged(_opts, _that) {\n if (_opts && _opts.onStateChanged) {\n _opts.onStateChanged.call(_that, _that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(_that, _that);\n }\n return true;\n },\n initGrid = function initGrid() {\n // 그리드 템플릿에 전달하고자 하는 데이터를 정리합시다.\n\n var data = {\n instanceId: this.id\n };\n\n this.$target.html(GRID.tmpl.get(\"main\", data));\n\n // 그리드 패널 프레임의 각 엘리먼트를 캐쉬합시다.\n this.$ = {\n \"container\": {\n \"hidden\": this.$target.find('[data-ax5grid-container=\"hidden\"]'),\n \"root\": this.$target.find('[data-ax5grid-container=\"root\"]'),\n \"header\": this.$target.find('[data-ax5grid-container=\"header\"]'),\n \"body\": this.$target.find('[data-ax5grid-container=\"body\"]'),\n \"page\": this.$target.find('[data-ax5grid-container=\"page\"]'),\n \"scroller\": this.$target.find('[data-ax5grid-container=\"scroller\"]')\n },\n \"panel\": {\n \"aside-header\": this.$target.find('[data-ax5grid-panel=\"aside-header\"]'),\n \"left-header\": this.$target.find('[data-ax5grid-panel=\"left-header\"]'),\n \"header\": this.$target.find('[data-ax5grid-panel=\"header\"]'),\n \"header-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"header\"]'),\n \"right-header\": this.$target.find('[data-ax5grid-panel=\"right-header\"]'),\n \"top-aside-body\": this.$target.find('[data-ax5grid-panel=\"top-aside-body\"]'),\n \"top-left-body\": this.$target.find('[data-ax5grid-panel=\"top-left-body\"]'),\n \"top-body\": this.$target.find('[data-ax5grid-panel=\"top-body\"]'),\n \"top-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"top-body\"]'),\n \"top-right-body\": this.$target.find('[data-ax5grid-panel=\"top-right-body\"]'),\n \"aside-body\": this.$target.find('[data-ax5grid-panel=\"aside-body\"]'),\n \"aside-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"aside-body\"]'),\n \"left-body\": this.$target.find('[data-ax5grid-panel=\"left-body\"]'),\n \"left-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"left-body\"]'),\n \"body\": this.$target.find('[data-ax5grid-panel=\"body\"]'),\n \"body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"body\"]'),\n \"right-body\": this.$target.find('[data-ax5grid-panel=\"right-body\"]'),\n \"right-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"right-body\"]'),\n \"bottom-aside-body\": this.$target.find('[data-ax5grid-panel=\"bottom-aside-body\"]'),\n \"bottom-left-body\": this.$target.find('[data-ax5grid-panel=\"bottom-left-body\"]'),\n \"bottom-body\": this.$target.find('[data-ax5grid-panel=\"bottom-body\"]'),\n \"bottom-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"bottom-body\"]'),\n \"bottom-right-body\": this.$target.find('[data-ax5grid-panel=\"bottom-right-body\"]')\n },\n \"livePanelKeys\": [], // 현재 사용중인 패널들 (grid-body repaint에서 수집하여 처리)\n \"scroller\": {\n \"vertical\": this.$target.find('[data-ax5grid-scroller=\"vertical\"]'),\n \"vertical-bar\": this.$target.find('[data-ax5grid-scroller=\"vertical-bar\"]'),\n \"horizontal\": this.$target.find('[data-ax5grid-scroller=\"horizontal\"]'),\n \"horizontal-bar\": this.$target.find('[data-ax5grid-scroller=\"horizontal-bar\"]'),\n \"corner\": this.$target.find('[data-ax5grid-scroller=\"corner\"]')\n },\n \"page\": {\n \"navigation\": this.$target.find('[data-ax5grid-page=\"navigation\"]'),\n \"status\": this.$target.find('[data-ax5grid-page=\"status\"]')\n },\n \"form\": {\n \"clipboard\": this.$target.find('[data-ax5grid-form=\"clipboard\"]')\n },\n \"resizer\": {\n \"vertical\": this.$target.find('[data-ax5grid-resizer=\"vertical\"]'),\n \"horizontal\": this.$target.find('[data-ax5grid-resizer=\"horizontal\"]')\n }\n };\n\n this.$[\"container\"][\"root\"].css({ height: this.config.height });\n\n return this;\n },\n initColumns = function initColumns(_columns) {\n this.columns = U.deepCopy(_columns);\n this.headerTable = GRID.util.makeHeaderTable.call(this, this.columns);\n this.xvar.frozenColumnIndex = cfg.frozenColumnIndex > this.columns.length ? this.columns.length : cfg.frozenColumnIndex;\n\n this.bodyRowTable = GRID.util.makeBodyRowTable.call(this, this.columns);\n this.bodyRowMap = GRID.util.makeBodyRowMap.call(this, this.bodyRowTable);\n // 바디에 표현될 한줄의 높이를 계산합니다.\n this.xvar.bodyTrHeight = this.bodyRowTable.rows.length * this.config.body.columnHeight;\n\n var colGroupMap = {};\n for (var r = 0, rl = this.headerTable.rows.length; r < rl; r++) {\n var row = this.headerTable.rows[r];\n for (var c = 0, cl = row.cols.length; c < cl; c++) {\n colGroupMap[row.cols[c].colIndex] = jQuery.extend({}, row.cols[c]);\n }\n }\n\n this.colGroup = [];\n for (var k in colGroupMap) {\n this.colGroup.push(colGroupMap[k]);\n }\n\n return this;\n },\n onResetColumns = function onResetColumns() {\n initColumns.call(this, this.config.columns);\n resetColGroupWidth.call(this);\n if (this.config.footSum) {\n initFootSum.call(this, this.config.footSum);\n this.needToPaintSum = true;\n }\n if (this.config.body.grouping) initBodyGroup.call(this, this.config.body.grouping);\n alignGrid.call(this, true);\n GRID.header.repaint.call(this, true);\n GRID.body.repaint.call(this, true);\n GRID.scroller.resize.call(this);\n },\n resetColGroupWidth = function resetColGroupWidth() {\n /// !! 그리드 target의 크기가 변경되면 이 함수를 호출하려 this.colGroup의 _width 값을 재 계산 하여야 함. [tom]\n var CT_WIDTH = this.$[\"container\"][\"root\"].width() - function () {\n var width = 0;\n if (cfg.showLineNumber) width += cfg.lineNumberColumnWidth;\n if (cfg.showRowSelector) width += cfg.rowSelectorColumnWidth;\n return width;\n }();\n var totalWidth = 0;\n var computedWidth;\n var autoWidthColgroupIndexs = [];\n var colGroup = this.colGroup;\n var i, l;\n\n for (i = 0, l = colGroup.length; i < l; i++) {\n if (U.isNumber(colGroup[i].width)) {\n totalWidth += colGroup[i]._width = colGroup[i].width;\n } else if (colGroup[i].width === \"*\") {\n autoWidthColgroupIndexs.push(i);\n } else if (U.right(colGroup[i].width, 1) === \"%\") {\n totalWidth += colGroup[i]._width = CT_WIDTH * U.left(colGroup[i].width, \"%\") / 100;\n }\n }\n if (autoWidthColgroupIndexs.length > 0) {\n computedWidth = (CT_WIDTH - totalWidth) / autoWidthColgroupIndexs.length;\n for (i = 0, l = autoWidthColgroupIndexs.length; i < l; i++) {\n colGroup[autoWidthColgroupIndexs[i]]._width = computedWidth;\n }\n }\n },\n initFootSum = function initFootSum(_footSum) {\n if (U.isArray(_footSum)) {\n this.footSumTable = GRID.util.makeFootSumTable.call(this, this.footSumColumns = _footSum);\n } else {\n this.footSumColumns = [];\n this.footSumTable = {};\n }\n },\n initBodyGroup = function initBodyGroup(_grouping) {\n var grouping = jQuery.extend({}, _grouping);\n if (\"by\" in grouping && \"columns\" in grouping) {\n\n this.bodyGrouping = {\n by: grouping.by,\n columns: grouping.columns\n };\n this.bodyGroupingTable = GRID.util.makeBodyGroupingTable.call(this, this.bodyGrouping.columns);\n this.sortInfo = function () {\n var sortInfo = {};\n for (var k = 0, kl = this.bodyGrouping.by.length; k < kl; k++) {\n sortInfo[this.bodyGrouping.by[k]] = {\n orderBy: \"asc\",\n seq: k,\n fixed: true\n };\n for (var c = 0, cl = this.colGroup.length; c < cl; c++) {\n if (this.colGroup[c].key === this.bodyGrouping.by[k]) {\n this.colGroup[c].sort = \"asc\";\n this.colGroup[c].sortFixed = true;\n }\n }\n }\n return sortInfo;\n }.call(this);\n } else {\n cfg.body.grouping = false;\n }\n },\n alignGrid = function alignGrid(_isFirst) {\n // isFirst : 그리드 정렬 메소드가 처음 호출 되었는지 판단 하는 아규먼트\n var CT_WIDTH = this.$[\"container\"][\"root\"].width();\n var CT_HEIGHT = this.$[\"container\"][\"root\"].height();\n var CT_INNER_WIDTH = CT_WIDTH;\n var CT_INNER_HEIGHT = CT_HEIGHT;\n\n var asidePanelWidth = cfg.asidePanelWidth = function () {\n var width = 0;\n\n if (cfg.showLineNumber) width += cfg.lineNumberColumnWidth;\n if (cfg.showRowSelector) width += cfg.rowSelectorColumnWidth;\n return width;\n }();\n\n var frozenPanelWidth = cfg.frozenPanelWidth = function (colGroup, endIndex) {\n var width = 0;\n for (var i = 0, l = endIndex; i < l; i++) {\n width += colGroup[i]._width;\n }\n return width;\n }(this.colGroup, cfg.frozenColumnIndex);\n\n var rightPanelWidth = 0; // todo : 우측 함계컬럼 넘비 계산\n\n var frozenRowHeight = function (bodyTrHeight) {\n return cfg.frozenRowIndex * bodyTrHeight;\n }(this.xvar.bodyTrHeight);\n\n var footSumHeight = function (bodyTrHeight) {\n return this.footSumColumns.length * bodyTrHeight;\n }.call(this, this.xvar.bodyTrHeight);\n\n var headerHeight = this.headerTable.rows.length * cfg.header.columnHeight;\n var pageHeight = cfg.page.display ? cfg.page.height : 0;\n\n // 데이터의 길이가 body보다 높을때. 수직 스크롤러 활성화\n var verticalScrollerWidth, horizontalScrollerHeight;\n\n (function () {\n verticalScrollerWidth = CT_HEIGHT - headerHeight - pageHeight - footSumHeight < this.list.length * this.xvar.bodyTrHeight ? this.config.scroller.size : 0;\n // 남은 너비가 colGroup의 너비보다 넓을때. 수평 스크롤 활성화.\n horizontalScrollerHeight = function () {\n var totalColGroupWidth = 0;\n // aside 빼고 너비\n // 수직 스크롤이 있으면 또 빼고 비교\n var bodyWidth = CT_WIDTH - asidePanelWidth - verticalScrollerWidth;\n for (var i = 0, l = this.colGroup.length; i < l; i++) {\n totalColGroupWidth += this.colGroup[i]._width;\n }\n return totalColGroupWidth > bodyWidth ? this.config.scroller.size : 0;\n }.call(this);\n\n if (horizontalScrollerHeight > 0) {\n verticalScrollerWidth = CT_HEIGHT - headerHeight - pageHeight - footSumHeight - horizontalScrollerHeight < this.list.length * this.xvar.bodyTrHeight ? this.config.scroller.size : 0;\n }\n }).call(this);\n\n // 수평 너비 결정\n CT_INNER_WIDTH = CT_WIDTH - verticalScrollerWidth;\n // 수직 스크롤러의 높이 결정.\n CT_INNER_HEIGHT = CT_HEIGHT - pageHeight - horizontalScrollerHeight;\n\n var bodyHeight = CT_INNER_HEIGHT - headerHeight;\n\n var panelDisplayProcess = function panelDisplayProcess(panel, vPosition, hPosition, containerType) {\n var css = {};\n var isHide = false;\n\n switch (hPosition) {\n case \"aside\":\n if (asidePanelWidth === 0) {\n isHide = true;\n } else {\n css[\"left\"] = 0;\n css[\"width\"] = asidePanelWidth;\n }\n break;\n case \"left\":\n if (cfg.frozenColumnIndex === 0) {\n isHide = true;\n } else {\n css[\"left\"] = asidePanelWidth;\n css[\"width\"] = frozenPanelWidth;\n }\n break;\n case \"right\":\n if (!cfg.rightSum) {\n isHide = true;\n } else {}\n break;\n default:\n if (containerType !== \"page\") {\n if (cfg.frozenColumnIndex === 0) {\n css[\"left\"] = asidePanelWidth;\n } else {\n css[\"left\"] = frozenPanelWidth + asidePanelWidth;\n }\n css[\"width\"] = CT_INNER_WIDTH - asidePanelWidth - frozenPanelWidth - rightPanelWidth;\n }\n break;\n }\n\n if (isHide) {\n panel.hide();\n // 프로세스 중지\n return this;\n }\n\n if (containerType === \"body\") {\n switch (vPosition) {\n case \"top\":\n if (cfg.frozenRowIndex == 0) {\n isHide = true;\n } else {\n css[\"top\"] = 0;\n css[\"height\"] = frozenRowHeight;\n }\n break;\n case \"bottom\":\n if (!cfg.footSum) {\n isHide = true;\n } else {\n css[\"top\"] = bodyHeight - footSumHeight;\n css[\"height\"] = footSumHeight; // footSum height\n }\n break;\n default:\n\n css[\"top\"] = frozenRowHeight;\n css[\"height\"] = bodyHeight - frozenRowHeight - footSumHeight;\n\n break;\n }\n } else if (containerType === \"header\") {\n css[\"height\"] = headerHeight;\n } else if (containerType === \"page\") {\n if (pageHeight == 0) {\n isHide = true;\n } else {\n css[\"height\"] = pageHeight;\n }\n }\n\n if (isHide) {\n panel.hide();\n // 프로세스 중지\n return this;\n }\n\n panel.css(css);\n return this;\n };\n var scrollerDisplayProcess = function scrollerDisplayProcess(panel, scrollerWidth, scrollerHeight, containerType) {\n var css = {};\n var isHide = false;\n\n switch (containerType) {\n case \"vertical\":\n if (scrollerWidth > 0) {\n css[\"width\"] = scrollerWidth;\n css[\"height\"] = CT_INNER_HEIGHT;\n css[\"bottom\"] = scrollerHeight + pageHeight;\n } else {\n isHide = true;\n }\n break;\n case \"horizontal\":\n if (scrollerHeight > 0) {\n css[\"width\"] = CT_INNER_WIDTH;\n css[\"height\"] = scrollerHeight;\n css[\"right\"] = scrollerWidth;\n css[\"bottom\"] = pageHeight;\n } else {\n isHide = true;\n }\n break;\n case \"corner\":\n if (scrollerWidth > 0 && scrollerHeight > 0) {\n css[\"width\"] = scrollerWidth;\n css[\"height\"] = scrollerHeight;\n css[\"bottom\"] = pageHeight;\n } else {\n isHide = true;\n }\n break;\n }\n\n if (isHide) {\n panel.hide();\n // 프로세스 중지\n return this;\n }\n\n panel.show().css(css);\n };\n\n this.$[\"container\"][\"header\"].css({ height: headerHeight });\n this.$[\"container\"][\"body\"].css({ height: bodyHeight });\n\n // 각 패널들의 크기 표시여부를 결정합니다\n panelDisplayProcess.call(this, this.$[\"panel\"][\"aside-header\"], \"\", \"aside\", \"header\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"left-header\"], \"\", \"left\", \"header\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"header\"], \"\", \"\", \"header\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"right-header\"], \"\", \"right\", \"header\");\n\n panelDisplayProcess.call(this, this.$[\"panel\"][\"top-aside-body\"], \"top\", \"aside\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"top-left-body\"], \"top\", \"left\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"top-body\"], \"top\", \"\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"top-right-body\"], \"top\", \"right\", \"body\");\n\n panelDisplayProcess.call(this, this.$[\"panel\"][\"aside-body\"], \"\", \"aside\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"left-body\"], \"\", \"left\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"body\"], \"\", \"\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"right-body\"], \"\", \"right\", \"body\");\n\n panelDisplayProcess.call(this, this.$[\"panel\"][\"bottom-aside-body\"], \"bottom\", \"aside\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"bottom-left-body\"], \"bottom\", \"left\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"bottom-body\"], \"bottom\", \"\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"bottom-right-body\"], \"bottom\", \"right\", \"body\");\n\n scrollerDisplayProcess.call(this, this.$[\"scroller\"][\"vertical\"], verticalScrollerWidth, horizontalScrollerHeight, \"vertical\");\n scrollerDisplayProcess.call(this, this.$[\"scroller\"][\"horizontal\"], verticalScrollerWidth, horizontalScrollerHeight, \"horizontal\");\n scrollerDisplayProcess.call(this, this.$[\"scroller\"][\"corner\"], verticalScrollerWidth, horizontalScrollerHeight, \"corner\");\n\n panelDisplayProcess.call(this, this.$[\"container\"][\"page\"], \"\", \"\", \"page\");\n },\n sortColumns = function sortColumns(_sortInfo) {\n GRID.header.repaint.call(this);\n\n if (U.isFunction(this.config.remoteSort)) {\n var that = { sortInfo: [] };\n for (var k in _sortInfo) {\n that.sortInfo.push({\n key: k,\n orderBy: _sortInfo[k].orderBy,\n seq: _sortInfo[k].seq\n });\n }\n that.sortInfo.sort(function (a, b) {\n return a.seq > b.seq;\n });\n this.config.remoteSort.call(that, that);\n } else {\n if (this.config.body.grouping) {\n this.list = GRID.data.initData.call(this, GRID.data.sort.call(this, _sortInfo, GRID.data.clearGroupingData.call(this, this.list)));\n } else {\n this.list = GRID.data.sort.call(this, _sortInfo, GRID.data.clearGroupingData.call(this, this.list));\n }\n GRID.body.repaint.call(this, true);\n GRID.scroller.resize.call(this);\n }\n };\n\n /// private end\n\n /**\n * Preferences of grid UI\n * @method ax5grid.setConfig\n * @param {Object} _config - 클래스 속성값\n * @param {Element} _config.target\n * @param {Number} [_config.frozenColumnIndex=0]\n * @param {Number} [_config.frozenRowIndex=0]\n * @param {Boolean} [_config.showLineNumber=false]\n * @param {Boolean} [_config.showRowSelector=false]\n * @param {Boolean} [_config.multipleSelect=true]\n * @param {Number} [_config.columnMinWidth=100]\n * @param {Number} [_config.lineNumberColumnWidth=30]\n * @param {Number} [_config.rowSelectorColumnWidth=25]\n * @param {Boolean} [_config.sortable=false]\n * @param {Boolean} [_config.multiSort=false]\n * @param {Function} [_config.remoteSort=false]\n * @param {Object} [_config.header]\n * @param {String} [_config.header.align]\n * @param {Number} [_config.header.columnHeight=25]\n * @param {Number} [_config.header.columnPadding=3]\n * @param {Number} [_config.header.columnBorderWidth=1]\n * @param {Object} [_config.body]\n * @param {String} [_config.body.align]\n * @param {Number} [_config.body.columnHeight=25]\n * @param {Number} [_config.body.columnPadding=3]\n * @param {Number} [_config.body.columnBorderWidth=1]\n * @param {Object} [_config.body.grouping]\n * @param {Array} [_config.body.grouping.by] - list grouping keys\n * @param {Array} [_config.body.grouping.columns] - list grouping columns\n * @param {Object} [_config.page]\n * @param {Number} [_config.page.height=25]\n * @param {Boolean} [_config.page.display=true]\n * @param {Number} [_config.page.navigationItemCount=5]\n * @param {Object} [_config.scroller]\n * @param {Number} [_config.scroller.size=15]\n * @param {Number} [_config.scroller.barMinSize=15]\n * @param {Number} [_config.scroller.trackPadding=4]\n * @param {Object} [_config.columnKeys]\n * @param {String} [_config.columnKeys.selected=\"_SELECTED\"]\n * @param {Object[]} _config.columns\n * @param {String} _config.columns[].key\n * @param {String} _config.columns[].label\n * @param {Number} _config.columns[].width\n * @param {(String|Function)} _config.columns[].styleClass\n * @param {Boolean} _config.columns[].enableFilter\n * @param {Boolean} _config.columns[].sortable\n * @param {String} _config.columns[].align\n * @param {(String|Function)} _config.columns[].formatter\n * @param {Object} _config.columns[].editor\n * @param {String} _config.columns[].editor.type - text,number,money,date\n * @param {Object} _config.columns[].editor.config\n * @param {Array} _config.columns[].editor.updateWith\n * @parem {Function} _config.columns[].editor.disabled - disable editor\n * @returns {ax5grid}\n * @example\n * ```js\n * var firstGrid = new ax5.ui.grid();\n *\n * ax5.ui.grid.formatter[\"myType\"] = function () {\n * return \"myType\" + (this.value || \"\");\n * };\n * ax5.ui.grid.formatter[\"capital\"] = function(){\n * return (''+this.value).toUpperCase();\n * };\n *\n * ax5.ui.grid.collector[\"myType\"] = function () {\n * return \"myType\" + (this.value || \"\");\n * };\n *\n * var sampleData = [\n * {a: \"A\", b: \"A01\", price: 1000, amount: 12, cost: 12000, saleDt: \"2016-08-29\", customer: \"장기영\", saleType: \"A\"},\n * {companyJson: {\"대표자명\":\"abcd\"}, a: \"A\", b: \"B01\", price: 1100, amount: 11, cost: 12100, saleDt: \"2016-08-28\", customer: \"장서우\", saleType: \"B\"},\n * {companyJson: {\"대표자명\":\"abcd\"}, a: \"A\", b: \"C01\", price: 1200, amount: 10, cost: 12000, saleDt: \"2016-08-27\", customer: \"이영희\", saleType: \"A\"},\n * {companyJson: {\"대표자명\":\"위세라\"}, a: \"A\", b: \"A01\", price: 1300, amount: 8, cost: 10400, saleDt: \"2016-08-25\", customer: \"황인서\", saleType: \"C\"},\n * {companyJson: {\"대표자명\":\"abcd\"}, a: \"A\", b: \"B01\", price: 1400, amount: 5, cost: 7000, saleDt: \"2016-08-29\", customer: \"황세진\", saleType: \"D\"},\n * {companyJson: {\"대표자명\":\"abcd\"}, a: \"A\", b: \"A01\", price: 1500, amount: 2, cost: 3000, saleDt: \"2016-08-26\", customer: \"이서연\", saleType: \"A\"}\n * ];\n *\n * var gridView = {\n * initView: function () {\n * firstGrid.setConfig({\n * target: $('[data-ax5grid=\"first-grid\"]'),\n * columns: [\n * {\n * key: \"companyJson['대표자명']\",\n * label: \"필드A\",\n * width: 80,\n * styleClass: function () {\n * return \"ABC\";\n * },\n * enableFilter: true,\n * align: \"center\",\n * editor: {type:\"text\"}\n * },\n * {key: \"b\", label: \"필드B\", align: \"center\"},\n * {\n * key: undefined, label: \"필드C\", columns: [\n * {key: \"price\", label: \"단가\", formatter: \"money\", align: \"right\"},\n * {key: \"amount\", label: \"수량\", formatter: \"money\", align: \"right\"},\n * {key: \"cost\", label: \"금액\", align: \"right\", formatter: \"money\"}\n * ]\n * },\n * {key: \"saleDt\", label: \"판매일자\", align: \"center\"},\n * {key: \"customer\", label: \"고객명\"},\n * {key: \"saleType\", label: \"판매타입\"}\n * ]\n * });\n * return this;\n * },\n * setData: function (_pageNo) {\n *\n * firstGrid.setData(sampleData);\n *\n * return this;\n * }\n * };\n * ```\n */\n this.init = function (_config) {\n cfg = jQuery.extend(true, {}, cfg, _config);\n if (!cfg.target) {\n console.log(ax5.info.getError(\"ax5grid\", \"401\", \"init\"));\n return this;\n }\n\n // 그리드의 이벤트 정의 구간\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n this.onLoad = cfg.onLoad;\n this.onDataChanged = cfg.body.onDataChanged;\n // todo event에 대한 추가 정의 필요\n\n this.$target = jQuery(cfg.target);\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n cfg = jQuery.extend(true, cfg, data);\n }\n }).call(this, U.parseJson(this.$target.attr(\"data-ax5grid-config\"), true));\n\n var grid = this.config = cfg;\n\n if (!this.config.height) {\n this.config.height = this.$target.height();\n }\n\n if (!this.id) this.id = this.$target.data(\"data-ax5grid-id\");\n if (!this.id) {\n //this.id = 'ax5grid-' + ax5.getGuid();\n this.id = 'ax5grid-' + this.instanceId;\n this.$target.data(\"data-ax5grid-id\", grid.id);\n }\n\n ///========\n // 그리드를 그리기 위한 가장 기초적인 작업 뼈대와 틀을 준비합니다. 이 메소드는 초기화 시 한번만 호출 되게 됩니다.\n initGrid.call(this);\n\n // columns데이터를 분석하여 미리 처리해야하는 데이터를 정리합니다.\n initColumns.call(this, grid.columns);\n resetColGroupWidth.call(this);\n\n // footSum 데이터를 분석하여 미리 처리해야 하는 데이터를 정리\n if (grid.footSum) initFootSum.call(this, grid.footSum);\n\n // bodyGrouping 데이터를 분석하여 미리 처리해야 하는 데이터를 정리\n if (grid.body.grouping) initBodyGroup.call(this, grid.body.grouping);\n\n // 그리드의 각 요소의 크기를 맞춤니다.\n alignGrid.call(this, true);\n\n // columns의 데이터로 header데이터를 만들고\n GRID.header.init.call(this);\n // header를 출력합니다.\n GRID.header.repaint.call(this);\n\n // columns의 데이터로 body데이터를 만들고\n GRID.body.init.call(this);\n // body를 출력합니다.\n GRID.body.repaint.call(this);\n\n // scroller\n GRID.scroller.init.call(this);\n GRID.scroller.resize.call(this);\n\n jQuery(window).bind(\"resize.ax5grid-\" + this.id, function () {\n alignGrid.call(this);\n GRID.scroller.resize.call(this);\n }.bind(this));\n\n jQuery(document.body).on(\"click.ax5grid-\" + this.id, function (e) {\n var isPickerClick = false;\n var target = U.findParentNode(e.target, function (_target) {\n if (isPickerClick = _target.getAttribute(\"data-ax5grid-inline-edit-picker\")) {\n return true;\n }\n return _target.getAttribute(\"data-ax5grid-container\") === \"root\";\n });\n\n if (target && target.getAttribute(\"data-ax5grid-instance\") === this.id) {\n self.focused = true;\n } else {\n self.focused = false;\n GRID.body.blur.call(this);\n }\n }.bind(this));\n\n var ctrlKeys = {\n \"33\": \"KEY_PAGEUP\",\n \"34\": \"KEY_PAGEDOWN\",\n \"35\": \"KEY_END\",\n \"36\": \"KEY_HOME\",\n \"37\": \"KEY_LEFT\",\n \"38\": \"KEY_UP\",\n \"39\": \"KEY_RIGHT\",\n \"40\": \"KEY_DOWN\"\n };\n jQuery(window).on(\"keydown.ax5grid-\" + this.instanceId, function (e) {\n if (self.focused) {\n if (self.isInlineEditing) {\n\n if (e.which == ax5.info.eventKeys.ESC) {\n self.keyDown(\"ESC\", e.originalEvent);\n } else if (e.which == ax5.info.eventKeys.RETURN) {\n self.keyDown(\"RETURN\", e.originalEvent);\n } else if (e.which == ax5.info.eventKeys.TAB) {\n self.keyDown(\"TAB\", e.originalEvent);\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.UP) {\n self.keyDown(\"RETURN\", { shiftKey: true });\n } else if (e.which == ax5.info.eventKeys.DOWN) {\n self.keyDown(\"RETURN\", {});\n }\n } else {\n\n if (e.metaKey || e.ctrlKey) {\n if (e.which == 67) {\n // c\n self.copySelect();\n }\n } else {\n if (ctrlKeys[e.which]) {\n self.keyDown(ctrlKeys[e.which], e.originalEvent);\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.ESC) {\n if (self.focused) {\n GRID.body.blur.call(self);\n }\n } else if (e.which == ax5.info.eventKeys.RETURN) {\n self.keyDown(\"RETURN\", e.originalEvent);\n } else if (e.which == ax5.info.eventKeys.TAB) {\n //self.keyDown(\"RETURN\", e.originalEvent);\n U.stopEvent(e);\n } else if (e.which != ax5.info.eventKeys.SPACE && Object.keys(self.focusedColumn).length) {\n self.keyDown(\"INLINE_EDIT\", e.originalEvent);\n }\n }\n }\n }\n });\n\n // 그리드 레이아웃이 모든 준비를 마친시점에 onLoad존재 여부를 확인하고 호출하여 줍니다.\n setTimeout(function () {\n if (this.onLoad) {\n this.onLoad.call({\n self: this\n });\n }\n }.bind(this));\n return this;\n };\n\n /**\n * align grid size\n * @method ax5grid.align\n * @returns {ax5grid}\n */\n this.align = function () {\n alignGrid.call(this);\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.keyDown\n * @param {String} _keyName\n * @param {Event|Object} _data\n * @return {ax5grid}\n */\n this.keyDown = function () {\n var processor = {\n \"KEY_UP\": function KEY_UP() {\n GRID.body.moveFocus.call(this, \"UP\");\n },\n \"KEY_DOWN\": function KEY_DOWN() {\n GRID.body.moveFocus.call(this, \"DOWN\");\n },\n \"KEY_LEFT\": function KEY_LEFT() {\n GRID.body.moveFocus.call(this, \"LEFT\");\n },\n \"KEY_RIGHT\": function KEY_RIGHT() {\n GRID.body.moveFocus.call(this, \"RIGHT\");\n },\n \"KEY_HOME\": function KEY_HOME() {\n GRID.body.moveFocus.call(this, \"HOME\");\n },\n \"KEY_END\": function KEY_END() {\n GRID.body.moveFocus.call(this, \"END\");\n },\n \"INLINE_EDIT\": function INLINE_EDIT(_e) {\n GRID.body.inlineEdit.active.call(this, this.focusedColumn, _e);\n if (!/[0-9a-zA-Z]/.test(_e.key)) {\n U.stopEvent(_e);\n }\n },\n \"ESC\": function ESC(_e) {\n GRID.body.inlineEdit.keydown.call(this, \"ESC\");\n },\n \"RETURN\": function RETURN(_e) {\n var activeEditLength = 0;\n for (var columnKey in this.inlineEditing) {\n activeEditLength++;\n\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\", columnKey);\n // next focus\n if (activeEditLength == 1) {\n if (GRID.body.moveFocus.call(this, _e.shiftKey ? \"UP\" : \"DOWN\")) {\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\");\n }\n }\n }\n if (activeEditLength == 0) {\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\");\n }\n },\n \"TAB\": function TAB(_e) {\n\n var activeEditLength = 0;\n for (var columnKey in this.inlineEditing) {\n activeEditLength++;\n\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\", columnKey, { moveFocus: true });\n // next focus\n if (activeEditLength == 1) {\n if (GRID.body.moveFocus.call(this, _e.shiftKey ? \"LEFT\" : \"RIGHT\")) {\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\", undefined, { moveFocus: true });\n }\n }\n }\n }\n };\n return function (_act, _data) {\n if (_act in processor) processor[_act].call(this, _data);\n return this;\n };\n }();\n\n /**\n * @method ax5grid.copySelect\n * @returns {Boolean} copysuccess\n */\n this.copySelect = function () {\n var copysuccess;\n var $clipBoard = this.$[\"form\"][\"clipboard\"];\n var copyTextArray = [];\n var copyText = \"\";\n\n var _rowIndex, _colIndex, _dindex;\n var _di = 0;\n for (var c in this.selectedColumn) {\n var _column = this.selectedColumn[c];\n\n if (_column) {\n if (typeof _dindex === \"undefined\") {\n _dindex = _column.dindex;\n _rowIndex = _column.rowIndex;\n _colIndex = _column.rowIndex;\n }\n\n if (_dindex != _column.dindex || _rowIndex != _column.rowIndex) {\n _di++;\n }\n\n if (!copyTextArray[_di]) {\n copyTextArray[_di] = [];\n }\n var originalColumn = this.bodyRowMap[_column.rowIndex + \"_\" + _column.colIndex];\n if (originalColumn) {\n if (this.list[_column.dindex].__isGrouping) {\n copyTextArray[_di].push(this.list[_column.dindex][_column.colIndex]);\n } else {\n copyTextArray[_di].push(this.list[_column.dindex][originalColumn.key]);\n }\n } else {\n copyTextArray[_di].push(\"\");\n }\n\n _dindex = _column.dindex;\n _rowIndex = _column.rowIndex;\n }\n }\n\n copyTextArray.forEach(function (r) {\n copyText += r.join('\\t') + \"\\n\";\n });\n\n $clipBoard.get(0).innerText = copyText;\n $clipBoard.select();\n\n try {\n copysuccess = document.execCommand(\"copy\");\n } catch (e) {\n copysuccess = false;\n }\n return copysuccess;\n };\n\n /**\n * @method ax5grid.setData\n * @param {Array} _data\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.setData({\n * list: [],\n * page: {\n * currentPage: 0,\n * pageSize: 50,\n * totalElements: 500,\n * totalPages: 100\n * }\n * });\n *\n * // onlyList\n * ax5Grid.setData([]);\n * ```\n */\n this.setData = function (_data) {\n GRID.data.set.call(this, _data);\n alignGrid.call(this);\n GRID.body.repaint.call(this);\n GRID.scroller.resize.call(this);\n GRID.page.navigationUpdate.call(this);\n GRID.body.scrollTo.call(this, { top: 0 });\n return this;\n };\n\n /**\n * @method ax5grid.getList\n * @param {String} _type\n * @returns {Array}\n * @example\n * ```js\n * ax5Grid.getList();\n * ax5Grid.getList(\"modified\");\n * ax5Grid.getList(\"deleted\");\n * ```\n */\n this.getList = function (_type) {\n return GRID.data.getList.call(this, _type);\n };\n\n /**\n * @method ax5grid.setHeight\n * @param {Number} _height\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.setHeight(height);\n * ```\n */\n this.setHeight = function (_height) {\n //console.log(this.$target);\n if (_height == \"100%\") {\n _height = this.$target.offsetParent().innerHeight();\n }\n this.$target.css({ height: _height });\n this.$[\"container\"][\"root\"].css({ height: _height });\n alignGrid.call(this);\n GRID.body.repaint.call(this, \"reset\");\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.addRow\n * @param {Object} _row\n * @param {Number|String} [_dindex=last]\n * @param {Object} [_options] - options of addRow\n * @param {Boolean} [_options.sort] - sortData\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.addRow($.extend({}, {...}), \"first\");\n * ```\n */\n this.addRow = function (_row, _dindex, _options) {\n GRID.data.add.call(this, _row, _dindex, _options);\n alignGrid.call(this);\n GRID.body.repaint.call(this, \"reset\");\n GRID.body.moveFocus.call(this, this.config.body.grouping ? \"START\" : \"END\");\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.removeRow\n * @param {Number|String} [_dindex=last]\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.removeRow();\n * ax5Grid.removeRow(\"first\");\n * ax5Grid.removeRow(\"last\");\n * ax5Grid.removeRow(1);\n * ```\n */\n this.removeRow = function (_dindex) {\n GRID.data.remove.call(this, _dindex);\n alignGrid.call(this);\n GRID.body.repaint.call(this, \"reset\");\n GRID.body.moveFocus.call(this, this.config.body.grouping ? \"START\" : \"END\");\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.updateRow\n * @param {Object} _row\n * @param {Number} _dindex\n * @returns {ax5grid}\n */\n this.updateRow = function (_row, _dindex) {\n GRID.data.update.call(this, _row, _dindex);\n GRID.body.repaintRow.call(this, _dindex);\n return this;\n };\n\n /**\n * @method ax5grid.deleteRow\n * @param {Number|String} _dindex\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.deleteRow(\"first\");\n * ax5Grid.deleteRow(\"last\");\n * ax5Grid.deleteRow(1);\n * ax5Grid.deleteRow(\"selected\");\n * ```\n */\n this.deleteRow = function (_dindex) {\n GRID.data.deleteRow.call(this, _dindex);\n alignGrid.call(this);\n GRID.body.repaint.call(this, \"reset\");\n // 삭제시엔 포커스 ?\n // GRID.body.moveFocus.call(this, (this.config.body.grouping) ? \"START\" : \"END\");\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.setValue\n * @param _dindex\n * @param _key\n * @param _value\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.setValue(0, \"price\", 100);\n * ```\n */\n this.setValue = function (_dindex, _key, _value) {\n // getPanelname;\n if (GRID.data.setValue.call(this, _dindex, _key, _value)) {\n var repaintCell = function repaintCell(_panelName, _rows, __dindex, __key, __value) {\n for (var r = 0, rl = _rows.length; r < rl; r++) {\n for (var c = 0, cl = _rows[r].cols.length; c < cl; c++) {\n if (_rows[r].cols[c].key == __key) {\n if (this.xvar.frozenRowIndex > __dindex) {\n GRID.body.repaintCell.call(this, \"top-\" + _panelName, __dindex, r, c, __value);\n } else {\n GRID.body.repaintCell.call(this, _panelName + \"-scroll\", __dindex, r, c, __value);\n }\n }\n }\n }\n };\n\n repaintCell.call(this, \"left-body\", this.leftBodyRowData.rows, _dindex, _key, _value);\n repaintCell.call(this, \"body\", this.bodyRowData.rows, _dindex, _key, _value);\n }\n\n return this;\n };\n\n /**\n * @method ax5grid.addColumn\n * @param {Object} _column\n * @param {Number|String} [_cindex=last]\n * @returns {ax5grid}\n */\n this.addColumn = function () {\n var processor = {\n \"first\": function first(_column) {\n this.config.columns = [].concat(_column).concat(this.config.columns);\n },\n \"last\": function last(_column) {\n this.config.columns = this.config.columns.concat([].concat(_column));\n }\n };\n\n return function (_column, _cindex) {\n if (typeof _column === \"undefined\") throw '_column must not be null';\n if (typeof _cindex === \"undefined\") _cindex = \"last\";\n if (_cindex in processor) {\n processor[_cindex].call(this, _column);\n } else {\n if (!U.isNumber(_cindex)) {\n throw 'invalid argument _cindex';\n }\n this.config.columns.splice(_cindex, [].concat(_column));\n }\n onResetColumns.call(this); // 컬럼이 변경되었을 때.\n return this;\n };\n }();\n\n /**\n * @method ax5grid.removeCloumn\n * @param {Number|String} [_cindex=last]\n * @returns {ax5grid}\n */\n this.removeColumn = function () {\n var processor = {\n \"first\": function first(_cindex) {\n this.config.columns.splice(_cindex, 1);\n },\n \"last\": function last() {\n this.config.columns.splice(this.config.columns.length - 1, 1);\n }\n };\n return function (_cindex) {\n if (typeof _cindex === \"undefined\") _cindex = \"last\";\n if (_cindex in processor) {\n processor[_cindex].call(this, _cindex);\n } else {\n if (!U.isNumber(_cindex)) {\n throw 'invalid argument _cindex';\n }\n //\n this.config.columns.splice(_cindex, 1);\n }\n onResetColumns.call(this); // 컬럼이 변경되었을 때.\n return this;\n };\n }();\n\n /**\n * @method ax5grid.updateColumn\n * @param {Object} _column\n * @param {Number} _cindex\n * @returns {ax5grid}\n */\n this.updateColumn = function (_column, _cindex) {\n if (!U.isNumber(_cindex)) {\n throw 'invalid argument _cindex';\n }\n //\n this.config.columns.splice(_cindex, 1, _column);\n onResetColumns.call(this); // 컬럼이 변경되었을 때.\n return this;\n };\n\n /**\n * @method ax5grid.setColumnWidth\n * @param {Number} _width\n * @param {Number} _cindex\n * @returns {ax5grid}\n */\n this.setColumnWidth = function (_width, _cindex) {\n this.colGroup[this.xvar.columnResizerIndex]._width = _width;\n this.needToPaintSum = true;\n\n // 컬럼너비 변경사항 적용.\n GRID.header.repaint.call(this);\n GRID.body.repaint.call(this, true);\n GRID.scroller.resize.call(this);\n\n alignGrid.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.getColumnSortInfo\n * @returns {Object} sortInfo\n */\n this.getColumnSortInfo = function () {\n var that = { sortInfo: [] };\n for (var k in this.sortInfo) {\n that.sortInfo.push({\n key: k,\n orderBy: this.sortInfo[k].orderBy,\n seq: this.sortInfo[k].seq\n });\n }\n that.sortInfo.sort(function (a, b) {\n return a.seq > b.seq;\n });\n return that.sortInfo;\n };\n\n /**\n * @method ax5grid.setColumnSort\n * @param {Object} _sortInfo\n * @param {Object} _sortInfo.key\n * @param {Number} _sortInfo.key.seq - seq of sortOrder\n * @param {String} _sortInfo.key.orderBy - \"desc\"|\"asc\"\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5grid.setColumnSort({a:{seq:0, orderBy:\"desc\"}, b:{seq:1, orderBy:\"asc\"}});\n * ```\n */\n this.setColumnSort = function (_sortInfo) {\n if (typeof _sortInfo !== \"undefined\") {\n this.sortInfo = _sortInfo;\n GRID.header.applySortStatus.call(this, _sortInfo);\n }\n\n sortColumns.call(this, _sortInfo || this.sortInfo);\n return this;\n };\n\n /**\n * @method ax5grid.select\n * @param {Number|Object} _selectObject\n * @param {Number} _selectObject.index - index of row\n * @param {Number} _selectObject.rowIndex - rowIndex of columns\n * @param {Number} _selectObject.conIndex - colIndex of columns\n * @param {Object} _options\n * @param {Boolean} _options.selectedClear\n * @param {Boolean} _options.selected\n * @returns {ax5grid}\n * @example\n * ```js\n * firstGrid.select(0);\n * firstGrid.select(0, {selected: true});\n * firstGrid.select(0, {selected: false});\n * firstGrid.select(0, {selectedClear: true});\n * ```\n */\n this.select = function (_selectObject, _options) {\n if (U.isNumber(_selectObject)) {\n var _dindex2 = _selectObject;\n\n if (!this.config.multipleSelect) {\n this.clearSelect();\n } else {\n if (_options && _options.selectedClear) {\n this.clearSelect();\n }\n }\n\n GRID.data.select.call(this, _dindex2, _options && _options.selected);\n GRID.body.updateRowState.call(this, [\"selected\"], _dindex2);\n }\n return this;\n };\n\n /**\n * @method ax5grid.clearSelect\n * @returns {ax5grid}\n * @example\n * ```js\n * firstGrid.clearSelect();\n * ```\n */\n this.clearSelect = function () {\n GRID.body.updateRowState.call(this, [\"selectedClear\"]);\n GRID.data.clearSelect.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.selectAll\n * @param {Object} _options\n * @param {Boolean} _options.selected\n * @param {Function} _options.filter\n * @returns {ax5grid}\n * @example\n * ```js\n * firstGrid.selectAll();\n * firstGrid.selectAll({selected: true});\n * firstGrid.selectAll({selected: false});\n * firstGrid.selectAll({filter: function(){\n * return this[\"b\"] == \"A01\";\n * });\n * firstGrid.selectAll({selected: true, filter: function(){\n * return this[\"b\"] == \"A01\";\n * });\n * ```\n */\n this.selectAll = function (_options) {\n GRID.data.selectAll.call(this, _options && _options.selected, _options);\n GRID.body.updateRowStateAll.call(this, [\"selected\"]);\n return this;\n };\n\n /**\n * @method ax5grid.exportExcel\n * @param {String} _fileName\n * @returns {ax5grid|String}\n * @example\n * ```js\n * firstGrid.exportExcel(\"grid-to-excel.xls\");\n * console.log(firstGrid.exportExcel());\n * ```\n */\n this.exportExcel = function (_fileName) {\n var table = [];\n table.push('
');\n table.push(GRID.header.getExcelString.call(this));\n table.push(GRID.body.getExcelString.call(this));\n table.push('
');\n\n if (typeof _fileName === \"undefined\") {\n return table.join('');\n } else {\n GRID.excel.export.call(this, [table.join('')], _fileName);\n }\n\n return this;\n };\n\n /**\n * @method ax5grid.focus\n * @param {String|Number} _pos - UP, DOWN, LEFT, RIGHT, HOME, END\n * @returns {ax5grid}\n * @example\n * ```js\n * firstGrid.focus(\"UP\");\n * firstGrid.focus(\"DOWN\");\n * firstGrid.focus(\"HOME\");\n * firstGrid.focus(\"END\");\n * ```\n */\n this.focus = function (_pos) {\n var _this4 = this;\n\n if (GRID.body.moveFocus.call(this, _pos)) {\n var focusedColumn = void 0;\n for (var c in this.focusedColumn) {\n focusedColumn = jQuery.extend({}, this.focusedColumn[c], true);\n break;\n }\n if (focusedColumn) {\n this.select(focusedColumn.dindex, { selectedClear: true });\n }\n } else {\n if (typeof this.selectedDataIndexs[0] === \"undefined\") {\n this.select(0);\n } else {\n (function () {\n var selectedIndex = _this4.selectedDataIndexs[0];\n var processor = {\n \"UP\": function UP() {\n if (selectedIndex > 0) {\n this.select(selectedIndex - 1, { selectedClear: true });\n GRID.body.moveFocus.call(this, selectedIndex - 1);\n }\n },\n \"DOWN\": function DOWN() {\n if (selectedIndex < this.list.length - 1) {\n this.select(selectedIndex + 1, { selectedClear: true });\n GRID.body.moveFocus.call(this, selectedIndex + 1);\n }\n },\n \"HOME\": function HOME() {\n this.select(0, { selectedClear: true });\n GRID.body.moveFocus.call(this, 0);\n },\n \"END\": function END() {\n this.select(this.list.length - 1, { selectedClear: true });\n GRID.body.moveFocus.call(this, this.list.length - 1);\n }\n };\n\n if (_pos in processor) {\n processor[_pos].call(_this4);\n }\n })();\n }\n }\n return this;\n };\n\n // 클래스 생성자\n this.main = function () {\n UI.grid_instance = UI.grid_instance || [];\n UI.grid_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5grid;\n }());\n\n GRID = ax5.ui.grid;\n})();\n\n// todo : excel export\n// todo : merge cells\n// todo : filter\n// todo : body menu\n// todo : column reorder\n// todo : editor 필수값 속성 지정\n\n\n// ax5.ui.grid.body\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var columnSelect = {\n focusClear: function focusClear() {\n var self = this;\n for (var c in self.focusedColumn) {\n var _column = self.focusedColumn[c];\n if (_column) {\n self.$.panel[_column.panelName].find('[data-ax5grid-tr-data-index=\"' + _column.dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + _column.rowIndex + '\"][data-ax5grid-column-colindex=\"' + _column.colIndex + '\"]').removeAttr('data-ax5grid-column-focused');\n }\n }\n self.focusedColumn = {};\n },\n clear: function clear() {\n var self = this;\n for (var c in self.selectedColumn) {\n var _column = self.selectedColumn[c];\n if (_column) {\n self.$.panel[_column.panelName].find('[data-ax5grid-tr-data-index=\"' + _column.dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + _column.rowIndex + '\"][data-ax5grid-column-colindex=\"' + _column.colIndex + '\"]').removeAttr('data-ax5grid-column-selected');\n }\n }\n self.selectedColumn = {};\n },\n init: function init(column) {\n var self = this;\n if (this.isInlineEditing) {\n for (var editKey in this.inlineEditing) {\n if (editKey == column.dindex + \"_\" + column.colIndex + \"_\" + column.rowIndex) {\n return this;\n }\n }\n }\n\n // focus\n columnSelect.focusClear.call(self);\n self.focusedColumn[column.dindex + \"_\" + column.colIndex + \"_\" + column.rowIndex] = {\n panelName: column.panelName,\n dindex: column.dindex,\n rowIndex: column.rowIndex,\n colIndex: column.colIndex,\n colspan: column.colspan\n };\n\n // select\n columnSelect.clear.call(self);\n self.xvar.selectedRange = {\n start: [column.dindex, column.rowIndex, column.colIndex, column.colspan - 1],\n end: null\n };\n self.selectedColumn[column.dindex + \"_\" + column.colIndex + \"_\" + column.rowIndex] = function (data) {\n if (data) {\n return false;\n } else {\n return {\n panelName: column.panelName,\n dindex: column.dindex,\n rowIndex: column.rowIndex,\n colIndex: column.colIndex,\n colspan: column.colspan\n };\n }\n }(self.selectedColumn[column.dindex + \"_\" + column.colIndex + \"_\" + column.rowIndex]);\n\n this.$.panel[column.panelName].find('[data-ax5grid-tr-data-index=\"' + column.dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + column.rowIndex + '\"][data-ax5grid-column-colindex=\"' + column.colIndex + '\"]').attr('data-ax5grid-column-focused', \"true\").attr('data-ax5grid-column-selected', \"true\");\n\n if (this.isInlineEditing) {\n GRID.body.inlineEdit.deActive.call(this, \"RETURN\");\n }\n },\n update: function update(column) {\n var self = this;\n var dindex, colIndex, rowIndex, trl;\n\n self.xvar.selectedRange[\"end\"] = [column.dindex, column.rowIndex, column.colIndex, column.colspan - 1];\n columnSelect.clear.call(self);\n\n var range = {\n r: {\n s: Math.min(self.xvar.selectedRange[\"start\"][0], self.xvar.selectedRange[\"end\"][0]),\n e: Math.max(self.xvar.selectedRange[\"start\"][0], self.xvar.selectedRange[\"end\"][0])\n },\n c: {\n s: Math.min(self.xvar.selectedRange[\"start\"][2], self.xvar.selectedRange[\"end\"][2]),\n e: Math.max(self.xvar.selectedRange[\"start\"][2] + self.xvar.selectedRange[\"start\"][3], self.xvar.selectedRange[\"end\"][2] + self.xvar.selectedRange[\"end\"][3])\n }\n };\n\n dindex = range.r.s;\n for (; dindex <= range.r.e; dindex++) {\n\n trl = this.bodyRowTable.rows.length;\n rowIndex = 0;\n for (; rowIndex < trl; rowIndex++) {\n colIndex = range.c.s;\n for (; colIndex <= range.c.e; colIndex++) {\n var _panels = [],\n panelName = \"\";\n\n if (self.xvar.frozenRowIndex > dindex) _panels.push(\"top\");\n if (self.xvar.frozenColumnIndex > colIndex) _panels.push(\"left\");\n _panels.push(\"body\");\n if (_panels[0] !== \"top\") _panels.push(\"scroll\");\n panelName = _panels.join(\"-\");\n\n self.selectedColumn[dindex + \"_\" + colIndex + \"_\" + rowIndex] = {\n panelName: panelName,\n dindex: dindex,\n rowIndex: rowIndex,\n colIndex: colIndex,\n colspan: column.colspan\n };\n\n _panels = null;\n panelName = null;\n }\n }\n }\n dindex = null;\n colIndex = null;\n rowIndex = null;\n\n for (var c in self.selectedColumn) {\n var _column = self.selectedColumn[c];\n if (_column) {\n self.$.panel[_column.panelName].find('[data-ax5grid-tr-data-index=\"' + _column.dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + _column.rowIndex + '\"][data-ax5grid-column-colindex=\"' + _column.colIndex + '\"]').attr('data-ax5grid-column-selected', 'true');\n }\n }\n }\n };\n\n var columnSelector = {\n \"on\": function on(cell) {\n var self = this;\n\n if (this.inlineEditing[cell.dindex + \"_\" + cell.colIndex + \"_\" + cell.rowIndex]) {\n return;\n }\n\n columnSelect.init.call(self, cell);\n\n this.$[\"container\"][\"body\"].on(\"mousemove.ax5grid-\" + this.instanceId, '[data-ax5grid-column-attr=\"default\"]', function (e) {\n if (this.getAttribute(\"data-ax5grid-column-rowIndex\")) {\n columnSelect.update.call(self, {\n panelName: this.getAttribute(\"data-ax5grid-panel-name\"),\n dindex: Number(this.getAttribute(\"data-ax5grid-data-index\")),\n rowIndex: Number(this.getAttribute(\"data-ax5grid-column-rowIndex\")),\n colIndex: Number(this.getAttribute(\"data-ax5grid-column-colIndex\")),\n colspan: Number(this.getAttribute(\"colspan\"))\n });\n U.stopEvent(e);\n }\n }).on(\"mouseup.ax5grid-\" + this.instanceId, function () {\n columnSelector.off.call(self);\n }).on(\"mouseleave.ax5grid-\" + this.instanceId, function () {\n columnSelector.off.call(self);\n });\n\n jQuery(document.body).attr('unselectable', 'on').css('user-select', 'none').on('selectstart', false);\n },\n \"off\": function off() {\n\n this.$[\"container\"][\"body\"].off(\"mousemove.ax5grid-\" + this.instanceId).off(\"mouseup.ax5grid-\" + this.instanceId).off(\"mouseleave.ax5grid-\" + this.instanceId);\n\n jQuery(document.body).removeAttr('unselectable').css('user-select', 'auto').off('selectstart');\n }\n };\n\n var updateRowState = function updateRowState(_states, _dindex, _data) {\n var self = this;\n var cfg = this.config;\n\n var processor = {\n \"selected\": function selected(_dindex) {\n var i = this.$.livePanelKeys.length;\n while (i--) {\n this.$.panel[this.$.livePanelKeys[i]].find('[data-ax5grid-tr-data-index=\"' + _dindex + '\"]').attr(\"data-ax5grid-selected\", this.list[_dindex][cfg.columnKeys.selected]);\n }\n },\n \"selectedClear\": function selectedClear() {\n var si = this.selectedDataIndexs.length;\n while (si--) {\n var dindex = this.selectedDataIndexs[si];\n var i = this.$.livePanelKeys.length;\n while (i--) {\n this.$.panel[this.$.livePanelKeys[i]].find('[data-ax5grid-tr-data-index=\"' + dindex + '\"]').attr(\"data-ax5grid-selected\", false);\n this.list[dindex][cfg.columnKeys.selected] = false;\n }\n }\n },\n \"cellChecked\": function cellChecked(_dindex, _data) {\n var key = _data.key;\n var rowIndex = _data.rowIndex;\n var colIndex = _data.colIndex;\n\n var panelName = function () {\n var _panels = [];\n if (this.xvar.frozenRowIndex > _dindex) _panels.push(\"top\");\n if (this.xvar.frozenColumnIndex > colIndex) _panels.push(\"left\");\n _panels.push(\"body\");\n if (_panels[0] !== \"top\") _panels.push(\"scroll\");\n return _panels.join(\"-\");\n }.call(this);\n\n this.$.panel[panelName].find('[data-ax5grid-tr-data-index=\"' + _dindex + '\"]').find('[data-ax5grid-column-rowIndex=\"' + rowIndex + '\"][data-ax5grid-column-colIndex=\"' + colIndex + '\"]').find('[data-ax5grid-editor=\"checkbox\"]').attr(\"data-ax5grid-checked\", '' + _data.checked);\n }\n };\n _states.forEach(function (_state) {\n if (!processor[_state]) throw 'invaild state name';\n processor[_state].call(self, _dindex, _data);\n });\n };\n\n var updateRowStateAll = function updateRowStateAll(_states, _data) {\n var self = this;\n var cfg = this.config;\n\n var processor = {\n \"selected\": function selected(_dindex) {\n GRID.body.repaint.call(this, true);\n }\n };\n _states.forEach(function (_state) {\n if (!processor[_state]) throw 'invaild state name';\n processor[_state].call(self, _data);\n });\n };\n\n var init = function init() {\n var self = this;\n\n this.$[\"container\"][\"body\"].on(\"click\", '[data-ax5grid-column-attr]', function (e) {\n var panelName, attr, row, col, dindex, rowIndex, colIndex, disableSelection;\n var targetClick = {\n \"default\": function _default(_column) {\n var column = self.bodyRowMap[_column.rowIndex + \"_\" + _column.colIndex];\n var that = {\n self: self,\n page: self.page,\n list: self.list,\n item: self.list[_column.dindex],\n dindex: _column.dindex,\n rowIndex: _column.rowIndex,\n colIndex: _column.colIndex,\n column: column,\n value: self.list[_column.dindex][column.key]\n };\n\n if (column.editor && column.editor.type == \"checkbox\") {\n // todo : GRID.inlineEditor에서 처리 할수 있도록 구문 변경 필요.\n var value = GRID.data.getValue.call(self, _column.dindex, column.key);\n\n var checked, newValue;\n if (column.editor.config && column.editor.config.trueValue) {\n if (checked = !(value == column.editor.config.trueValue)) {\n newValue = column.editor.config.trueValue;\n } else {\n newValue = column.editor.config.falseValue;\n }\n } else {\n newValue = checked = value == false || value == \"false\" || value < \"1\" ? \"true\" : \"false\";\n }\n\n GRID.data.setValue.call(self, _column.dindex, column.key, newValue);\n\n updateRowState.call(self, [\"cellChecked\"], _column.dindex, {\n key: column.key, rowIndex: _column.rowIndex, colIndex: _column.colIndex,\n editorConfig: column.editor.config, checked: checked\n });\n } else {\n if (self.config.body.onClick) {\n self.config.body.onClick.call(that);\n }\n }\n },\n \"rowSelector\": function rowSelector(_column) {\n if (self.list[_column.dindex][self.config.columnKeys.disableSelection]) {\n return false;\n }\n\n if (!self.config.multipleSelect && self.selectedDataIndexs[0] !== _column.dindex) {\n GRID.body.updateRowState.call(self, [\"selectedClear\"]);\n GRID.data.clearSelect.call(self);\n }\n\n GRID.data.select.call(self, _column.dindex, undefined, {\n internalCall: true\n });\n updateRowState.call(self, [\"selected\"], _column.dindex);\n },\n \"lineNumber\": function lineNumber(_column) {}\n };\n\n panelName = this.getAttribute(\"data-ax5grid-panel-name\");\n attr = this.getAttribute(\"data-ax5grid-column-attr\");\n row = Number(this.getAttribute(\"data-ax5grid-column-row\"));\n col = Number(this.getAttribute(\"data-ax5grid-column-col\"));\n rowIndex = Number(this.getAttribute(\"data-ax5grid-column-rowIndex\"));\n colIndex = Number(this.getAttribute(\"data-ax5grid-column-colIndex\"));\n dindex = Number(this.getAttribute(\"data-ax5grid-data-index\"));\n\n if (attr in targetClick) {\n targetClick[attr]({\n panelName: panelName,\n attr: attr,\n row: row,\n col: col,\n dindex: dindex,\n rowIndex: rowIndex,\n colIndex: colIndex\n });\n }\n });\n this.$[\"container\"][\"body\"].on(\"dblclick\", '[data-ax5grid-column-attr]', function (e) {\n var panelName, attr, row, col, dindex, rowIndex, colIndex;\n var targetClick = {\n \"default\": function _default(_column) {\n\n if (this.isInlineEditing) {\n for (var columnKey in this.inlineEditing) {\n if (columnKey == _column.dindex + \"_\" + _column.colIndex + \"_\" + _column.rowIndex) {\n return this;\n }\n }\n }\n\n var column = self.bodyRowMap[_column.rowIndex + \"_\" + _column.colIndex];\n var value = \"\";\n if (column) {\n if (!self.list[dindex].__isGrouping) {\n value = GRID.data.getValue.call(self, dindex, column.key);\n }\n }\n GRID.body.inlineEdit.active.call(self, self.focusedColumn, e, value);\n },\n \"rowSelector\": function rowSelector(_column) {},\n \"lineNumber\": function lineNumber(_column) {}\n };\n\n panelName = this.getAttribute(\"data-ax5grid-panel-name\");\n attr = this.getAttribute(\"data-ax5grid-column-attr\");\n row = Number(this.getAttribute(\"data-ax5grid-column-row\"));\n col = Number(this.getAttribute(\"data-ax5grid-column-col\"));\n rowIndex = Number(this.getAttribute(\"data-ax5grid-column-rowIndex\"));\n colIndex = Number(this.getAttribute(\"data-ax5grid-column-colIndex\"));\n dindex = Number(this.getAttribute(\"data-ax5grid-data-index\"));\n\n if (attr in targetClick) {\n targetClick[attr]({\n panelName: panelName,\n attr: attr,\n row: row,\n col: col,\n dindex: dindex,\n rowIndex: rowIndex,\n colIndex: colIndex\n });\n }\n });\n this.$[\"container\"][\"body\"].on(\"mouseover\", \"tr\", function () {\n return;\n var dindex = this.getAttribute(\"data-ax5grid-tr-data-index\");\n var i = self.$.livePanelKeys.length;\n while (i--) {\n if (typeof self.xvar.dataHoveredIndex !== \"undefined\") self.$.panel[self.$.livePanelKeys[i]].find('[data-ax5grid-tr-data-index=\"' + self.xvar.dataHoveredIndex + '\"]').removeClass(\"hover\");\n self.$.panel[self.$.livePanelKeys[i]].find('[data-ax5grid-tr-data-index=\"' + dindex + '\"]').addClass(\"hover\");\n }\n self.xvar.dataHoveredIndex = dindex;\n });\n this.$[\"container\"][\"body\"].on(\"mousedown\", '[data-ax5grid-column-attr=\"default\"]', function (e) {\n if (self.xvar.touchmoved) return false;\n if (this.getAttribute(\"data-ax5grid-column-rowIndex\")) {\n columnSelector.on.call(self, {\n panelName: this.getAttribute(\"data-ax5grid-panel-name\"),\n dindex: Number(this.getAttribute(\"data-ax5grid-data-index\")),\n rowIndex: Number(this.getAttribute(\"data-ax5grid-column-rowIndex\")),\n colIndex: Number(this.getAttribute(\"data-ax5grid-column-colIndex\")),\n colspan: Number(this.getAttribute(\"colspan\"))\n });\n }\n }).on(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n resetFrozenColumn.call(this);\n };\n\n var resetFrozenColumn = function resetFrozenColumn() {\n var cfg = this.config;\n var dividedBodyRowObj = GRID.util.divideTableByFrozenColumnIndex(this.bodyRowTable, this.xvar.frozenColumnIndex);\n this.asideBodyRowData = function (dataTable) {\n var data = { rows: [] };\n for (var i = 0, l = dataTable.rows.length; i < l; i++) {\n data.rows[i] = { cols: [] };\n if (i === 0) {\n var col = {\n label: \"\",\n colspan: 1,\n rowspan: dataTable.rows.length,\n colIndex: null\n },\n _col = {};\n\n if (cfg.showLineNumber) {\n _col = jQuery.extend({}, col, {\n width: cfg.lineNumberColumnWidth,\n _width: cfg.lineNumberColumnWidth,\n columnAttr: \"lineNumber\",\n label: \" \", key: \"__d-index__\"\n });\n data.rows[i].cols.push(_col);\n }\n if (cfg.showRowSelector) {\n _col = jQuery.extend({}, col, {\n width: cfg.rowSelectorColumnWidth,\n _width: cfg.rowSelectorColumnWidth,\n columnAttr: \"rowSelector\",\n label: \"\", key: \"__d-checkbox__\"\n });\n data.rows[i].cols.push(_col);\n }\n }\n }\n\n return data;\n }.call(this, this.bodyRowTable);\n this.leftBodyRowData = dividedBodyRowObj.leftData;\n this.bodyRowData = dividedBodyRowObj.rightData;\n\n if (cfg.body.grouping) {\n var dividedBodyGroupingObj = GRID.util.divideTableByFrozenColumnIndex(this.bodyGroupingTable, this.xvar.frozenColumnIndex);\n this.asideBodyGroupingData = function (dataTable) {\n var data = { rows: [] };\n for (var i = 0, l = dataTable.rows.length; i < l; i++) {\n data.rows[i] = { cols: [] };\n if (i === 0) {\n var col = {\n label: \"\",\n colspan: 1,\n rowspan: dataTable.rows.length,\n colIndex: null\n },\n _col = {};\n\n if (cfg.showLineNumber) {\n _col = jQuery.extend({}, col, {\n width: cfg.lineNumberColumnWidth,\n _width: cfg.lineNumberColumnWidth,\n columnAttr: \"lineNumber\",\n label: \" \", key: \"__d-index__\"\n });\n data.rows[i].cols.push(_col);\n }\n if (cfg.showRowSelector) {\n _col = jQuery.extend({}, col, {\n width: cfg.rowSelectorColumnWidth,\n _width: cfg.rowSelectorColumnWidth,\n columnAttr: \"rowSelector\",\n label: \"\", key: \"__d-checkbox__\"\n });\n data.rows[i].cols.push(_col);\n }\n }\n }\n\n return data;\n }.call(this, this.bodyGroupingTable);\n this.leftBodyGroupingData = dividedBodyGroupingObj.leftData;\n this.bodyGroupingData = dividedBodyGroupingObj.rightData;\n }\n\n this.leftFootSumData = {};\n this.footSumData = {};\n if (this.config.footSum) {\n var dividedFootSumObj = GRID.util.divideTableByFrozenColumnIndex(this.footSumTable, this.xvar.frozenColumnIndex);\n this.leftFootSumData = dividedFootSumObj.leftData;\n this.footSumData = dividedFootSumObj.rightData;\n }\n };\n\n var getFieldValue = function getFieldValue(_list, _item, _index, _col, _value, _returnPlainText) {\n var _key = _col.key,\n tagsToReplace = {\n '<': '<',\n '>': '>'\n };\n\n if (_key === \"__d-index__\") {\n return typeof _item[\"__index\"] !== \"undefined\" ? _item[\"__index\"] + 1 : \"\";\n } else if (_key === \"__d-checkbox__\") {\n return '
';\n } else {\n if (_col.editor && function (_editor) {\n if (_editor.type in GRID.inlineEditor) {\n return GRID.inlineEditor[_editor.type].editMode == \"inline\";\n }\n return false;\n }(_col.editor)) {\n\n _value = _value || GRID.data.getValue.call(this, _index, _key);\n\n if (U.isFunction(_col.editor.disabled)) {\n if (_col.editor.disabled.call({\n list: _list,\n dindex: _index,\n item: _list[_index],\n key: _key,\n value: _value\n })) {\n return _value;\n }\n }\n\n // print editor\n return _returnPlainText ? _value : GRID.inlineEditor[_col.editor.type].getHtml(this, _col.editor, _value);\n }\n if (_col.formatter) {\n var that = {\n key: _key,\n value: _value || GRID.data.getValue.call(this, _index, _key),\n dindex: _index,\n item: _item,\n list: _list\n };\n if (U.isFunction(_col.formatter)) {\n return _col.formatter.call(that);\n } else {\n return GRID.formatter[_col.formatter].call(that);\n }\n } else {\n var returnValue = \"\";\n\n if (typeof _value !== \"undefined\") {\n returnValue = _value;\n } else {\n _value = GRID.data.getValue.call(this, _index, _key);\n if (_value !== null && typeof _value !== \"undefined\") returnValue = _value;\n }\n\n return typeof returnValue === \"number\" ? returnValue : returnValue.replace(/[<>]/g, function (tag) {\n return tagsToReplace[tag] || tag;\n });\n }\n }\n };\n\n var getGroupingValue = function getGroupingValue(_item, _index, _col) {\n var value,\n that,\n _key = _col.key,\n _label = _col.label;\n\n if (typeof _key === \"undefined\") {\n that = {\n key: _key,\n list: _item.__groupingList,\n groupBy: _item.__groupingBy\n };\n if (U.isFunction(_label)) {\n value = _label.call(that);\n } else {\n value = _label;\n }\n _item[_col.colIndex] = value;\n return value;\n } else if (_key === \"__d-index__\") {\n return '';\n } else if (_key === \"__d-checkbox__\") {\n return '';\n } else {\n if (_col.collector) {\n that = {\n key: _key,\n list: _item.__groupingList\n };\n if (U.isFunction(_col.collector)) {\n value = _col.collector.call(that);\n } else {\n value = GRID.collector[_col.collector].call(that);\n }\n _item[_col.colIndex] = value;\n\n if (_col.formatter) {\n that.value = value;\n if (U.isFunction(_col.formatter)) {\n return _col.formatter.call(that);\n } else {\n return GRID.formatter[_col.formatter].call(that);\n }\n } else {\n return value;\n }\n } else {\n return \" \";\n }\n }\n };\n\n var getSumFieldValue = function getSumFieldValue(_list, _col) {\n var _key = _col.key,\n _label = _col.label;\n //, _collector, _formatter\n if (typeof _key === \"undefined\") {\n return _label;\n } else if (_key === \"__d-index__\" || _key === \"__d-checkbox__\") {\n return ' ';\n } else {\n if (_col.collector) {\n var that = {\n key: _key,\n list: _list\n };\n var value;\n if (U.isFunction(_col.collector)) {\n value = _col.collector.call(that);\n } else {\n value = GRID.collector[_col.collector].call(that);\n }\n\n if (_col.formatter) {\n that.value = value;\n if (U.isFunction(_col.formatter)) {\n return _col.formatter.call(that);\n } else {\n return GRID.formatter[_col.formatter].call(that);\n }\n } else {\n return value;\n }\n } else {\n return \" \";\n }\n }\n };\n\n var repaint = function repaint(_reset) {\n var cfg = this.config,\n list = this.list;\n\n /// repaint reset 타입이면 고정컬럼을 재조정\n if (_reset) {\n resetFrozenColumn.call(this);\n // 틀고정 이 변경되면 출력 시작 인덱스 값을 초기화\n this.xvar.paintStartRowIndex = undefined;\n }\n\n /// 출력시작 인덱스\n var paintStartRowIndex = Math.floor(Math.abs(this.$.panel[\"body-scroll\"].position().top) / this.xvar.bodyTrHeight) + this.xvar.frozenRowIndex;\n if (this.xvar.dataRowCount === list.length && this.xvar.paintStartRowIndex === paintStartRowIndex) return this; // 스크롤 포지션 변경 여부에 따라 프로세스 진행여부 결정\n\n var isFirstPaint = typeof this.xvar.paintStartRowIndex === \"undefined\",\n asideBodyRowData = this.asideBodyRowData,\n leftBodyRowData = this.leftBodyRowData,\n bodyRowData = this.bodyRowData,\n leftFootSumData = this.leftFootSumData,\n footSumData = this.footSumData,\n asideBodyGroupingData = this.asideBodyGroupingData,\n leftBodyGroupingData = this.leftBodyGroupingData,\n bodyGroupingData = this.bodyGroupingData,\n bodyAlign = cfg.body.align,\n paintRowCount = Math.ceil(this.$.panel[\"body\"].height() / this.xvar.bodyTrHeight) + 1;\n\n if (document.addEventListener && ax5.info.supportTouch) {\n paintRowCount = paintRowCount * 2;\n }\n\n /// 스크롤 컨텐츠의 높이 : 그리드 스크롤의 실제 크기와는 관계 없이 데이터 갯수에 따라 스크롤 컨텐츠 높이값 구해서 저장해두기.\n this.xvar.scrollContentHeight = this.xvar.bodyTrHeight * (this.list.length - this.xvar.frozenRowIndex);\n /// 사용된 패널들의 키 모음\n this.$.livePanelKeys = [];\n\n // 그리드 바디 영역 페인트 함수\n var repaintBody = function repaintBody(_elTargetKey, _colGroup, _bodyRow, _groupRow, _list, _scrollConfig) {\n var _elTarget = this.$.panel[_elTargetKey];\n\n if (!isFirstPaint && !_scrollConfig) {\n this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고)\n return false;\n }\n\n var SS = [],\n cgi = void 0,\n cgl = void 0,\n di = void 0,\n dl = void 0,\n tri = void 0,\n trl = void 0,\n ci = void 0,\n cl = void 0,\n col = void 0,\n cellHeight = void 0,\n colAlign = void 0,\n isScrolled = function () {\n // 스크롤값이 변경되거나 처음 호출되었습니까?\n if (typeof _scrollConfig === \"undefined\" || typeof _scrollConfig['paintStartRowIndex'] === \"undefined\") {\n _scrollConfig = {\n paintStartRowIndex: 0,\n paintRowCount: _list.length\n };\n return false;\n } else {\n return true;\n }\n }();\n\n if (isScrolled) {\n SS.push('
');\n }\n SS.push('
');\n SS.push('');\n for (cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n }\n SS.push('');\n SS.push('');\n\n for (di = _scrollConfig.paintStartRowIndex, dl = function () {\n var len = void 0;\n len = _list.length;\n if (_scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex < len) {\n len = _scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex;\n }\n return len;\n }(); di < dl; di++) {\n\n var isGroupingRow = false,\n rowTable = void 0;\n if (_groupRow && \"__isGrouping\" in _list[di]) {\n rowTable = _groupRow;\n isGroupingRow = true;\n } else {\n rowTable = _bodyRow;\n }\n\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n\n SS.push('');\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push(function (_cellHeight) {\n var lineHeight = cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth;\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n }(cellHeight), isGroupingRow ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n }\n SS.push('
');\n\n if (isScrolled && _list.length) {\n SS.push('
');\n }\n\n _elTarget.empty().get(0).innerHTML = SS.join('');\n\n this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고)\n return true;\n };\n var repaintSum = function repaintSum(_elTargetKey, _colGroup, _bodyRow, _list, _scrollConfig) {\n var _elTarget = this.$.panel[_elTargetKey];\n\n if (!isFirstPaint && !_scrollConfig) {\n this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고)\n return false;\n }\n\n var SS = [],\n cgi = void 0,\n cgl = void 0,\n tri = void 0,\n trl = void 0,\n ci = void 0,\n cl = void 0,\n col = void 0,\n cellHeight = void 0,\n colAlign = void 0;\n\n SS.push('
');\n SS.push('');\n for (cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n }\n SS.push('');\n SS.push('');\n\n for (tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('');\n for (ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n col = _bodyRow.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push(function (_cellHeight) {\n var lineHeight = cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth;\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n }(cellHeight), getSumFieldValue.call(this, _list, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n\n SS.push('
');\n\n _elTarget.empty().get(0).innerHTML = SS.join('');\n this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고)\n return true;\n };\n var scrollConfig = {\n paintStartRowIndex: paintStartRowIndex,\n paintRowCount: paintRowCount,\n bodyTrHeight: this.xvar.bodyTrHeight\n };\n\n // aside\n if (cfg.asidePanelWidth > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n repaintBody.call(this, \"top-aside-body\", this.asideColGroup, asideBodyRowData, asideBodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n }\n\n repaintBody.call(this, \"aside-body-scroll\", this.asideColGroup, asideBodyRowData, asideBodyGroupingData, list, scrollConfig);\n\n if (cfg.footSum) {\n // 바닥 요약 (footSum에 대한 aside 사용안함)\n //repaintSum.call(this, \"bottom-aside-body\", this.asideColGroup, asideBodyRowData, null, list);\n }\n }\n\n // left\n if (this.xvar.frozenColumnIndex > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n repaintBody.call(this, \"top-left-body\", this.leftHeaderColGroup, leftBodyRowData, leftBodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n }\n\n repaintBody.call(this, \"left-body-scroll\", this.leftHeaderColGroup, leftBodyRowData, leftBodyGroupingData, list, scrollConfig);\n\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-left-body\", this.leftHeaderColGroup, leftFootSumData, list);\n }\n }\n\n // body\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n repaintBody.call(this, \"top-body-scroll\", this.headerColGroup, bodyRowData, bodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n }\n\n repaintBody.call(this, \"body-scroll\", this.headerColGroup, bodyRowData, bodyGroupingData, list, scrollConfig);\n\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-body-scroll\", this.headerColGroup, footSumData, list, scrollConfig);\n }\n\n //todo : repaintBody 에서 footSum 데이터 예외처리\n // right\n if (cfg.rightSum) {\n // todo : right 표현 정리\n }\n\n this.xvar.paintStartRowIndex = paintStartRowIndex;\n this.xvar.paintRowCount = paintRowCount;\n this.xvar.dataRowCount = list.length;\n this.needToPaintSum = false;\n GRID.page.statusUpdate.call(this);\n };\n\n var repaintCell = function repaintCell(_panelName, _dindex, _rowIndex, _colIndex, _newValue) {\n var self = this;\n var cfg = this.config;\n var list = this.list;\n\n var updateCell = this.$[\"panel\"][_panelName].find('[data-ax5grid-tr-data-index=\"' + _dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + _rowIndex + '\"][data-ax5grid-column-colindex=\"' + _colIndex + '\"]').find('[data-ax5grid-cellholder]');\n var colGroup = this.colGroup;\n var col = colGroup[_colIndex];\n\n updateCell.html(getFieldValue.call(this, list, list[_dindex], _dindex, col));\n\n if (col.editor && col.editor.updateWith) {\n col.editor.updateWith.forEach(function (updateColumnKey) {\n colGroup.forEach(function (col) {\n if (col.key == updateColumnKey) {\n var rowIndex = col.rowIndex;\n var colIndex = col.colIndex;\n var panelName = GRID.util.findPanelByColumnIndex.call(self, _dindex, colIndex, rowIndex).panelName;\n var updateWithCell = self.$[\"panel\"][panelName].find('[data-ax5grid-tr-data-index=\"' + _dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + rowIndex + '\"][data-ax5grid-column-colindex=\"' + colIndex + '\"]').find('[data-ax5grid-cellholder]');\n updateWithCell.html(getFieldValue.call(self, list, list[_dindex], _dindex, col));\n }\n });\n });\n }\n\n /// ~~~~~~\n\n var paintStartRowIndex = Math.floor(Math.abs(this.$.panel[\"body-scroll\"].position().top) / this.xvar.bodyTrHeight) + this.xvar.frozenRowIndex;\n var leftFootSumData = this.leftFootSumData;\n var footSumData = this.footSumData;\n var asideBodyGroupingData = this.asideBodyGroupingData;\n var leftBodyGroupingData = this.leftBodyGroupingData;\n var bodyGroupingData = this.bodyGroupingData;\n var bodyAlign = cfg.body.align;\n var paintRowCount = Math.ceil(this.$.panel[\"body\"].height() / this.xvar.bodyTrHeight) + 1;\n var scrollConfig = {\n paintStartRowIndex: paintStartRowIndex,\n paintRowCount: paintRowCount,\n bodyTrHeight: this.xvar.bodyTrHeight\n };\n\n var repaintSum = function repaintSum(_elTargetKey, _colGroup, _bodyRow, _list, _scrollConfig) {\n var _elTarget = this.$.panel[_elTargetKey];\n\n var SS = [];\n var cgi, cgl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n\n SS.push('
');\n SS.push('');\n for (cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n }\n SS.push('');\n SS.push('');\n\n for (tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('');\n for (ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n col = _bodyRow.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push(function (_cellHeight) {\n var lineHeight = cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth;\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n }(cellHeight), getSumFieldValue.call(this, _list, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n\n SS.push('
');\n\n _elTarget.empty().get(0).innerHTML = SS.join('');\n return true;\n };\n var replaceGroupTr = function replaceGroupTr(_elTargetKey, _colGroup, _groupRow, _list, _scrollConfig) {\n var _elTarget = this.$.panel[_elTargetKey];\n var SS = [];\n var cgi, cgl;\n var di, dl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n for (di = _scrollConfig.paintStartRowIndex, dl = function () {\n var len;\n len = _list.length;\n if (_scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex < len) {\n len = _scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex;\n }\n return len;\n }(); di < dl; di++) {\n if (_groupRow && \"__isGrouping\" in _list[di]) {\n var rowTable = _groupRow;\n SS = [];\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('
');\n\n SS.push(function (_cellHeight) {\n var lineHeight = cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth;\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n }(cellHeight), getGroupingValue.call(this, _list[di], di, col), '');\n\n SS.push(' | ');\n }\n SS.push('
| ');\n }\n _elTarget.find('tr[data-ax5grid-tr-data-index=\"' + di + '\"]').empty().get(0).innerHTML = SS.join('');\n }\n }\n };\n\n // body.grouping tr 다시 그리기..\n if (cfg.body.grouping) {\n // left\n if (this.xvar.frozenColumnIndex > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceGroupTr.call(this, \"top-left-body\", this.leftHeaderColGroup, leftBodyGroupingData, list.slice(0, this.xvar.frozenRowIndex), {\n paintStartRowIndex: 0,\n paintRowCount: this.xvar.frozenRowIndex,\n bodyTrHeight: this.xvar.bodyTrHeight\n });\n }\n replaceGroupTr.call(this, \"left-body-scroll\", this.leftHeaderColGroup, leftBodyGroupingData, list, scrollConfig);\n }\n\n // body\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceGroupTr.call(this, \"top-body-scroll\", this.headerColGroup, bodyGroupingData, list.slice(0, this.xvar.frozenRowIndex), {\n paintStartRowIndex: 0,\n paintRowCount: this.xvar.frozenRowIndex,\n bodyTrHeight: this.xvar.bodyTrHeight\n });\n }\n\n replaceGroupTr.call(this, \"body-scroll\", this.headerColGroup, bodyGroupingData, list, scrollConfig);\n }\n\n if (this.xvar.frozenColumnIndex > 0) {\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-left-body\", this.leftHeaderColGroup, leftFootSumData, list);\n }\n }\n\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-body-scroll\", this.headerColGroup, footSumData, list, scrollConfig);\n }\n };\n\n var repaintRow = function repaintRow(_dindex) {\n var self = this,\n cfg = this.config,\n list = this.list;\n /// ~~~~~~\n\n var paintStartRowIndex = Math.floor(Math.abs(this.$.panel[\"body-scroll\"].position().top) / this.xvar.bodyTrHeight) + this.xvar.frozenRowIndex;\n var asideBodyRowData = this.asideBodyRowData;\n var leftBodyRowData = this.leftBodyRowData;\n var bodyRowData = this.bodyRowData;\n var leftFootSumData = this.leftFootSumData;\n var footSumData = this.footSumData;\n var asideBodyGroupingData = this.asideBodyGroupingData;\n var leftBodyGroupingData = this.leftBodyGroupingData;\n var bodyGroupingData = this.bodyGroupingData;\n var bodyAlign = cfg.body.align;\n var paintRowCount = Math.ceil(this.$.panel[\"body\"].height() / this.xvar.bodyTrHeight) + 1;\n var scrollConfig = {\n paintStartRowIndex: paintStartRowIndex,\n paintRowCount: paintRowCount,\n bodyTrHeight: this.xvar.bodyTrHeight\n };\n\n var repaintSum = function repaintSum(_elTargetKey, _colGroup, _bodyRow, _list) {\n var _elTarget = this.$.panel[_elTargetKey];\n\n var SS = [];\n var cgi, cgl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n\n SS.push('
');\n SS.push('');\n for (cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n }\n SS.push('');\n SS.push('');\n\n for (tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('');\n for (ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n col = _bodyRow.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push(function (_cellHeight) {\n var lineHeight = cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth;\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n }(cellHeight), getSumFieldValue.call(this, _list, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n\n SS.push('
');\n\n _elTarget.empty().get(0).innerHTML = SS.join('');\n return true;\n };\n var replaceGroupTr = function replaceGroupTr(_elTargetKey, _colGroup, _groupRow, _list, _scrollConfig) {\n var _elTarget = this.$.panel[_elTargetKey];\n var SS = [];\n var cgi, cgl;\n var di, dl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n for (di = _scrollConfig.paintStartRowIndex, dl = function () {\n var len;\n len = _list.length;\n if (_scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex < len) {\n len = _scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex;\n }\n return len;\n }(); di < dl; di++) {\n if (_groupRow && \"__isGrouping\" in _list[di]) {\n var rowTable = _groupRow;\n SS = [];\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('
');\n\n SS.push(function (_cellHeight) {\n var lineHeight = cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth;\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n }(cellHeight), getGroupingValue.call(this, _list[di], di, col), '');\n\n SS.push(' | ');\n }\n SS.push('
| ');\n }\n _elTarget.find('tr[data-ax5grid-tr-data-index=\"' + di + '\"]').empty().get(0).innerHTML = SS.join('');\n }\n }\n };\n var replaceTr = function replaceTr(_elTargetKey, _colGroup, _bodyRow, _list, di) {\n var _elTarget = this.$.panel[_elTargetKey];\n var SS = [];\n var cgi, cgl;\n var di, dl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n var rowTable = _bodyRow;\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('
');\n\n SS.push(function (_cellHeight) {\n var lineHeight = cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth;\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n }(cellHeight), getFieldValue.call(this, _list, _list[di], di, col), '');\n SS.push(' | ');\n }\n SS.push('
| ');\n }\n\n //_elTarget.find('tr[data-ax5grid-tr-data-index=\"' + di + '\"]').html(SS.join(''));\n _elTarget.find('tr[data-ax5grid-tr-data-index=\"' + di + '\"]').empty().get(0).innerHTML = SS.join('');\n };\n\n // left\n if (this.xvar.frozenColumnIndex > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceTr.call(this, \"top-left-body\", this.leftHeaderColGroup, leftBodyRowData, list, _dindex);\n }\n replaceTr.call(this, \"left-body-scroll\", this.leftHeaderColGroup, leftBodyRowData, list, _dindex);\n }\n\n // body\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceTr.call(this, \"top-body-scroll\", this.headerColGroup, bodyRowData, list, _dindex);\n }\n\n replaceTr.call(this, \"body-scroll\", this.headerColGroup, bodyRowData, list, _dindex);\n\n // body.grouping tr 다시 그리기..\n if (cfg.body.grouping) {\n // left\n if (this.xvar.frozenColumnIndex > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceGroupTr.call(this, \"top-left-body\", this.leftHeaderColGroup, leftBodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n }\n replaceGroupTr.call(this, \"left-body-scroll\", this.leftHeaderColGroup, leftBodyGroupingData, list, scrollConfig);\n }\n\n // body\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceGroupTr.call(this, \"top-body-scroll\", this.headerColGroup, bodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n }\n\n replaceGroupTr.call(this, \"body-scroll\", this.headerColGroup, bodyGroupingData, list, scrollConfig);\n }\n\n if (this.xvar.frozenColumnIndex > 0) {\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-left-body\", this.leftHeaderColGroup, leftFootSumData, list);\n }\n }\n\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-body-scroll\", this.headerColGroup, footSumData, list, scrollConfig);\n }\n };\n\n var scrollTo = function scrollTo(css, noRepaint) {\n var cfg = this.config;\n\n if (this.isInlineEditing) {\n for (var key in this.inlineEditing) {\n //if(this.inlineEditing[key].editor.type === \"select\") {}\n // 인라인 에디팅 인데 스크롤 이벤트가 발생하면 디액티브 처리\n GRID.body.inlineEdit.deActive.call(this, \"ESC\", key);\n }\n }\n\n if (cfg.asidePanelWidth > 0 && \"top\" in css) {\n this.$.panel[\"aside-body-scroll\"].css({ top: css.top });\n }\n if (this.xvar.frozenColumnIndex > 0 && \"top\" in css) {\n this.$.panel[\"left-body-scroll\"].css({ top: css.top });\n }\n if (this.xvar.frozenRowIndex > 0 && \"left\" in css) {\n this.$.panel[\"top-body-scroll\"].css({ left: css.left });\n }\n\n this.$.panel[\"body-scroll\"].css(css);\n\n if (cfg.footSum && \"left\" in css) {\n this.$.panel[\"bottom-body-scroll\"].css({ left: css.left });\n }\n\n if (!noRepaint && \"top\" in css) {\n repaint.call(this);\n } else {}\n };\n\n var blur = function blur() {\n columnSelect.focusClear.call(this);\n columnSelect.clear.call(this);\n if (this.isInlineEditing) {\n inlineEdit.deActive.call(this);\n }\n };\n\n var moveFocus = function moveFocus(_position) {\n var focus = {\n \"UD\": function UD(_dy) {\n var moveResult = true,\n focusedColumn = void 0,\n originalColumn = void 0,\n while_i = void 0;\n\n for (var c in this.focusedColumn) {\n focusedColumn = jQuery.extend({}, this.focusedColumn[c], true);\n break;\n }\n\n if (!focusedColumn) return false;\n\n originalColumn = this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex];\n columnSelect.focusClear.call(this);\n columnSelect.clear.call(this);\n\n if (_dy > 0) {\n if (focusedColumn.rowIndex + (originalColumn.rowspan - 1) + _dy > this.bodyRowTable.rows.length - 1) {\n focusedColumn.dindex = focusedColumn.dindex + _dy;\n focusedColumn.rowIndex = 0;\n if (focusedColumn.dindex > this.list.length - 1) {\n focusedColumn.dindex = this.list.length - 1;\n moveResult = false;\n }\n } else {\n focusedColumn.rowIndex = focusedColumn.rowIndex + _dy;\n }\n } else {\n if (focusedColumn.rowIndex + _dy < 0) {\n focusedColumn.dindex = focusedColumn.dindex + _dy;\n focusedColumn.rowIndex = this.bodyRowTable.rows.length - 1;\n if (focusedColumn.dindex < 0) {\n focusedColumn.dindex = 0;\n moveResult = false;\n }\n } else {\n focusedColumn.rowIndex = focusedColumn.rowIndex + _dy;\n }\n }\n\n while_i = 0;\n while (typeof this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex] === \"undefined\") {\n if (focusedColumn.rowIndex == 0 || while_i % 2 == (_dy > 0 ? 0 : 1)) {\n focusedColumn.colIndex--;\n } else {\n focusedColumn.rowIndex--;\n }\n\n if (focusedColumn.rowIndex <= 0 && focusedColumn.colIndex <= 0) {\n // find fail\n moveResult = false;\n break;\n }\n while_i++;\n }\n\n var nPanelInfo = GRID.util.findPanelByColumnIndex.call(this, focusedColumn.dindex, focusedColumn.colIndex);\n focusedColumn.panelName = nPanelInfo.panelName;\n\n // 포커스 컬럼의 위치에 따라 스크롤 처리.\n (function () {\n if (focusedColumn.dindex + 1 > this.xvar.frozenRowIndex) {\n if (focusedColumn.dindex <= this.xvar.paintStartRowIndex) {\n scrollTo.call(this, { top: -(focusedColumn.dindex - this.xvar.frozenRowIndex) * this.xvar.bodyTrHeight });\n GRID.scroller.resize.call(this);\n } else if (focusedColumn.dindex + 1 > this.xvar.paintStartRowIndex + (this.xvar.paintRowCount - 2)) {\n scrollTo.call(this, { top: -(focusedColumn.dindex - this.xvar.frozenRowIndex - this.xvar.paintRowCount + 3) * this.xvar.bodyTrHeight });\n GRID.scroller.resize.call(this);\n }\n }\n }).call(this);\n\n this.focusedColumn[focusedColumn.dindex + \"_\" + focusedColumn.colIndex + \"_\" + focusedColumn.rowIndex] = focusedColumn;\n this.$.panel[focusedColumn.panelName].find('[data-ax5grid-tr-data-index=\"' + focusedColumn.dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + focusedColumn.rowIndex + '\"][data-ax5grid-column-colindex=\"' + focusedColumn.colIndex + '\"]').attr('data-ax5grid-column-focused', \"true\");\n\n return moveResult;\n },\n \"LR\": function LR(_dx) {\n var moveResult = true;\n var focusedColumn;\n var originalColumn;\n var while_i = 0;\n var isScrollPanel = false;\n var containerPanelName = \"\";\n\n for (var c in this.focusedColumn) {\n focusedColumn = jQuery.extend({}, this.focusedColumn[c], true);\n break;\n }\n if (!focusedColumn) return false;\n\n originalColumn = this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex];\n\n columnSelect.focusClear.call(this);\n columnSelect.clear.call(this);\n\n if (_dx < 0) {\n focusedColumn.colIndex = focusedColumn.colIndex + _dx;\n if (focusedColumn.colIndex < 0) {\n focusedColumn.colIndex = 0;\n moveResult = false;\n }\n } else {\n focusedColumn.colIndex = focusedColumn.colIndex + (originalColumn.colspan - 1) + _dx;\n if (focusedColumn.colIndex > this.colGroup.length - 1) {\n focusedColumn.colIndex = this.colGroup.length - 1;\n moveResult = false;\n }\n }\n\n if (typeof this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex] === \"undefined\") {\n focusedColumn.rowIndex = 0;\n }\n while_i = 0;\n while (typeof this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex] === \"undefined\") {\n focusedColumn.colIndex--;\n if (focusedColumn.rowIndex <= 0 && focusedColumn.colIndex <= 0) {\n // find fail\n moveResult = false;\n break;\n }\n while_i++;\n }\n\n var nPanelInfo = GRID.util.findPanelByColumnIndex.call(this, focusedColumn.dindex, focusedColumn.colIndex);\n\n focusedColumn.panelName = nPanelInfo.panelName;\n containerPanelName = nPanelInfo.containerPanelName;\n isScrollPanel = nPanelInfo.isScrollPanel;\n\n this.focusedColumn[focusedColumn.dindex + \"_\" + focusedColumn.colIndex + \"_\" + focusedColumn.rowIndex] = focusedColumn;\n\n var $column = this.$.panel[focusedColumn.panelName].find('[data-ax5grid-tr-data-index=\"' + focusedColumn.dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + focusedColumn.rowIndex + '\"][data-ax5grid-column-colindex=\"' + focusedColumn.colIndex + '\"]').attr('data-ax5grid-column-focused', \"true\");\n\n if ($column && isScrollPanel) {\n // 스크롤 패널 이라면~\n var newLeft = function () {\n if ($column.position().left + $column.outerWidth() > Math.abs(this.$.panel[focusedColumn.panelName].position().left) + this.$.panel[containerPanelName].width()) {\n return $column.position().left + $column.outerWidth() - this.$.panel[containerPanelName].width();\n } else if (Math.abs(this.$.panel[focusedColumn.panelName].position().left) > $column.position().left) {\n return $column.position().left;\n } else {\n return;\n }\n }.call(this);\n\n //console.log(newLeft);\n\n if (typeof newLeft !== \"undefined\") {\n GRID.header.scrollTo.call(this, { left: -newLeft });\n scrollTo.call(this, { left: -newLeft });\n GRID.scroller.resize.call(this);\n }\n }\n\n return moveResult;\n },\n \"INDEX\": function INDEX(_dindex) {\n var moveResult = true;\n var focusedColumn;\n var originalColumn;\n var while_i;\n\n for (var c in this.focusedColumn) {\n focusedColumn = jQuery.extend({}, this.focusedColumn[c], true);\n break;\n }\n if (!focusedColumn) {\n focusedColumn = {\n rowIndex: 0,\n colIndex: 0\n };\n }\n originalColumn = this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex];\n\n columnSelect.focusClear.call(this);\n columnSelect.clear.call(this);\n\n if (_dindex == \"end\") {\n _dindex = this.list.length - 1;\n }\n\n focusedColumn.dindex = _dindex;\n focusedColumn.rowIndex = 0;\n\n while_i = 0;\n while (typeof this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex] === \"undefined\") {\n if (focusedColumn.rowIndex == 0 || while_i % 2 == (_dy > 0 ? 0 : 1)) {\n focusedColumn.colIndex--;\n } else {\n focusedColumn.rowIndex--;\n }\n\n if (focusedColumn.rowIndex <= 0 && focusedColumn.colIndex <= 0) {\n // find fail\n break;\n }\n while_i++;\n }\n\n var nPanelInfo = GRID.util.findPanelByColumnIndex.call(this, focusedColumn.dindex, focusedColumn.colIndex);\n focusedColumn.panelName = nPanelInfo.panelName;\n\n // 포커스 컬럼의 위치에 따라 스크롤 처리.\n (function () {\n if (focusedColumn.dindex + 1 > this.xvar.frozenRowIndex) {\n if (focusedColumn.dindex < this.xvar.paintStartRowIndex) {\n scrollTo.call(this, { top: -(focusedColumn.dindex - this.xvar.frozenRowIndex) * this.xvar.bodyTrHeight });\n GRID.scroller.resize.call(this);\n } else if (focusedColumn.dindex + 1 > this.xvar.paintStartRowIndex + (this.xvar.paintRowCount - 2)) {\n scrollTo.call(this, { top: -(focusedColumn.dindex - this.xvar.frozenRowIndex - this.xvar.paintRowCount + 3) * this.xvar.bodyTrHeight });\n GRID.scroller.resize.call(this);\n }\n }\n }).call(this);\n\n this.focusedColumn[focusedColumn.dindex + \"_\" + focusedColumn.colIndex + \"_\" + focusedColumn.rowIndex] = focusedColumn;\n this.$.panel[focusedColumn.panelName].find('[data-ax5grid-tr-data-index=\"' + focusedColumn.dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + focusedColumn.rowIndex + '\"][data-ax5grid-column-colindex=\"' + focusedColumn.colIndex + '\"]').attr('data-ax5grid-column-focused', \"true\");\n\n return moveResult;\n }\n };\n\n var processor = {\n \"UP\": function UP() {\n return focus[\"UD\"].call(this, -1);\n },\n \"DOWN\": function DOWN() {\n return focus[\"UD\"].call(this, 1);\n },\n \"LEFT\": function LEFT() {\n return focus[\"LR\"].call(this, -1);\n },\n \"RIGHT\": function RIGHT() {\n return focus[\"LR\"].call(this, 1);\n },\n \"HOME\": function HOME() {\n return focus[\"INDEX\"].call(this, 0);\n },\n \"END\": function END() {\n return focus[\"INDEX\"].call(this, \"end\");\n },\n \"position\": function position(_position) {\n return focus[\"INDEX\"].call(this, _position);\n }\n };\n\n if (_position in processor) {\n return processor[_position].call(this);\n } else {\n return processor[\"position\"].call(this, _position);\n }\n };\n\n var inlineEdit = {\n active: function active(_focusedColumn, _e, _initValue) {\n var self = this,\n dindex,\n colIndex,\n rowIndex,\n panelName,\n colspan,\n col,\n editor;\n\n // this.inlineEditing = {};\n for (var key in _focusedColumn) {\n panelName = _focusedColumn[key].panelName;\n dindex = _focusedColumn[key].dindex;\n colIndex = _focusedColumn[key].colIndex;\n rowIndex = _focusedColumn[key].rowIndex;\n colspan = _focusedColumn[key].colspan;\n\n // 인라인 에디팅을 멈춰야 하는 경우 조건\n col = this.colGroup[colIndex];\n if (!(editor = col.editor)) return this;\n\n // editor disabled 체크\n if (U.isFunction(editor.disabled)) {\n if (editor.disabled.call({\n list: this.list,\n dindex: dindex,\n item: this.list[dindex],\n key: col.key,\n value: _initValue\n })) {\n return this;\n }\n }\n\n // 조건에 맞지 않는 에디팅 타입이면 반응 없음.\n if (!function (_editor, _type) {\n if (_editor.type in GRID.inlineEditor) {\n return GRID.inlineEditor[_editor.type].editMode == \"popup\";\n }\n }(editor)) {\n // 체크 박스 타입이면 값 변경 시도\n if (editor.type == \"checkbox\") {\n var checked, newValue;\n if (editor.config && editor.config.trueValue) {\n if (checked = !(_initValue == editor.config.trueValue)) {\n newValue = editor.config.trueValue;\n } else {\n newValue = editor.config.falseValue;\n }\n } else {\n newValue = checked = _initValue == false || _initValue == \"false\" || _initValue < \"1\" ? \"true\" : \"false\";\n }\n\n GRID.data.setValue.call(self, dindex, col.key, newValue);\n updateRowState.call(self, [\"cellChecked\"], dindex, {\n key: col.key, rowIndex: rowIndex, colIndex: colIndex,\n editorConfig: col.editor.config, checked: checked\n });\n }\n return this;\n }\n\n if (this.list[dindex].__isGrouping) {\n return false;\n }\n if (key in this.inlineEditing) {\n return false;\n }\n this.inlineEditing[key] = {\n editor: editor,\n panelName: panelName,\n columnKey: key,\n column: _focusedColumn[key],\n useReturnToSave: GRID.inlineEditor[editor.type].useReturnToSave\n };\n this.isInlineEditing = true;\n }\n if (this.isInlineEditing) {\n\n var originalValue = GRID.data.getValue.call(self, dindex, col.key);\n var initValue = function (__value, __editor) {\n if (U.isNothing(__value)) {\n __value = U.isNothing(originalValue) ? \"\" : originalValue;\n }\n\n if (__editor.type == \"money\") {\n return U.number(__value, { \"money\": true });\n } else {\n return __value;\n }\n }.call(this, _initValue, editor);\n\n this.inlineEditing[key].$inlineEditorCell = this.$[\"panel\"][panelName].find('[data-ax5grid-tr-data-index=\"' + dindex + '\"]').find('[data-ax5grid-column-rowindex=\"' + rowIndex + '\"][data-ax5grid-column-colindex=\"' + colIndex + '\"]').find('[data-ax5grid-cellholder]');\n\n this.inlineEditing[key].$inlineEditor = GRID.inlineEditor[editor.type].init(this, key, editor, this.inlineEditing[key].$inlineEditorCell, initValue);\n\n return true;\n }\n },\n deActive: function deActive(_msg, _key, _value) {\n // console.log(this.inlineEditing.column.dindex, this.inlineEditing.$inlineEditor.val());\n if (!this.inlineEditing[_key]) return this;\n\n var panelName = this.inlineEditing[_key].panelName;\n var dindex = this.inlineEditing[_key].column.dindex;\n var rowIndex = this.inlineEditing[_key].column.rowIndex;\n var colIndex = this.inlineEditing[_key].column.colIndex;\n\n var column = this.bodyRowMap[this.inlineEditing[_key].column.rowIndex + \"_\" + this.inlineEditing[_key].column.colIndex];\n var editorValue = function ($inlineEditor) {\n if (typeof _value === \"undefined\") {\n if ($inlineEditor.get(0).tagName == \"SELECT\" || $inlineEditor.get(0).tagName == \"INPUT\" || $inlineEditor.get(0).tagName == \"TEXTAREA\") {\n return $inlineEditor.val();\n } else {\n _msg = \"CANCEL\";\n return false;\n }\n } else {\n return _value;\n }\n }(this.inlineEditing[_key].$inlineEditor);\n\n var newValue = function (__value, __editor) {\n if (__editor.type == \"money\") {\n return U.number(__value);\n } else {\n return __value;\n }\n }.call(this, editorValue, column.editor);\n\n var action = {\n \"CANCEL\": function CANCEL(_dindex, _column, _newValue) {\n action[\"__clear\"].call(this);\n },\n \"RETURN\": function RETURN(_dindex, _column, _newValue) {\n if (GRID.data.setValue.call(this, _dindex, _column.key, _newValue)) {\n action[\"__clear\"].call(this);\n GRID.body.repaintCell.call(this, panelName, dindex, rowIndex, colIndex, _newValue);\n } else {\n action[\"__clear\"].call(this);\n }\n },\n \"__clear\": function __clear() {\n this.isInlineEditing = false;\n var bindedAx5ui = this.inlineEditing[_key].$inlineEditor.data(\"binded-ax5ui\");\n if (bindedAx5ui == \"ax5picker\") {\n this.inlineEditing[_key].$inlineEditor.ax5picker(\"close\");\n } else if (bindedAx5ui == \"ax5select\") {\n this.inlineEditing[_key].$inlineEditor.ax5select(\"close\");\n }\n\n this.inlineEditing[_key].$inlineEditor.remove();\n this.inlineEditing[_key].$inlineEditor = null;\n this.inlineEditing[_key].$inlineEditorCell = null;\n this.inlineEditing[_key] = undefined;\n delete this.inlineEditing[_key]; // delete 지원안하는 브라우저 테스트..\n }\n };\n\n if (_msg in action) {\n action[_msg || \"RETURN\"].call(this, dindex, column, newValue);\n } else {\n action[\"__clear\"].call(this);\n }\n },\n keydown: function keydown(key, columnKey, _options) {\n var processor = {\n \"ESC\": function ESC() {\n for (var columnKey in this.inlineEditing) {\n inlineEdit.deActive.call(this, \"CANCEL\", columnKey);\n }\n },\n \"RETURN\": function RETURN() {\n if (this.isInlineEditing) {\n if (this.inlineEditing[columnKey] && this.inlineEditing[columnKey].useReturnToSave) {\n // todo : 네이밍 검증 할 필요있음.\n inlineEdit.deActive.call(this, \"RETURN\", columnKey);\n }\n } else {\n\n for (var k in this.focusedColumn) {\n var _column = this.focusedColumn[k];\n var column = this.bodyRowMap[_column.rowIndex + \"_\" + _column.colIndex];\n var dindex = _column.dindex;\n var value = \"\";\n if (column) {\n if (!this.list[dindex].__isGrouping) {\n value = GRID.data.getValue.call(this, dindex, column.key);\n }\n }\n\n var col = this.colGroup[_column.colIndex];\n\n if (GRID.inlineEditor[col.editor.type].editMode === \"inline\") {\n if (_options && _options.moveFocus) {} else {\n if (column.editor && column.editor.type == \"checkbox\") {\n\n value = GRID.data.getValue.call(this, dindex, column.key);\n\n var checked, newValue;\n if (column.editor.config && column.editor.config.trueValue) {\n if (checked = !(value == column.editor.config.trueValue)) {\n newValue = column.editor.config.trueValue;\n } else {\n newValue = column.editor.config.falseValue;\n }\n } else {\n newValue = checked = value == false || value == \"false\" || value < \"1\" ? \"true\" : \"false\";\n }\n\n GRID.data.setValue.call(this, _column.dindex, column.key, newValue);\n updateRowState.call(this, [\"cellChecked\"], dindex, {\n key: column.key, rowIndex: _column.rowIndex, colIndex: _column.colIndex,\n editorConfig: column.editor.config, checked: checked\n });\n }\n }\n } else {\n GRID.body.inlineEdit.active.call(this, this.focusedColumn, null, value);\n }\n }\n }\n }\n };\n\n if (key in processor) {\n processor[key].call(this, key, columnKey, _options);\n }\n }\n };\n\n var getExcelString = function getExcelString() {\n var cfg = this.config,\n list = this.list,\n bodyRowData = this.bodyRowTable,\n footSumData = this.footSumTable,\n bodyGroupingData = this.bodyGroupingTable;\n\n // body-scroll 의 포지션에 의존적이므로..\n var getBody = function getBody(_colGroup, _bodyRow, _groupRow, _list) {\n var SS = [],\n di = void 0,\n dl = void 0,\n tri = void 0,\n trl = void 0,\n ci = void 0,\n cl = void 0,\n col = void 0;\n\n //SS.push('
');\n for (di = 0, dl = _list.length; di < dl; di++) {\n var isGroupingRow = false,\n rowTable = void 0;\n\n if (_groupRow && \"__isGrouping\" in _list[di]) {\n rowTable = _groupRow;\n isGroupingRow = true;\n } else {\n rowTable = _bodyRow;\n }\n\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n SS.push('\\n');\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n\n SS.push('', isGroupingRow ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col, undefined, \"text\"), ' | ');\n }\n SS.push('\\n
');\n }\n }\n //SS.push('
');\n return SS.join('');\n };\n var getSum = function getSum(_colGroup, _bodyRow, _list) {\n var SS = [],\n tri = void 0,\n trl = void 0,\n ci = void 0,\n cl = void 0,\n col = void 0;\n\n //SS.push('
');\n for (tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('\\n');\n for (ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n col = _bodyRow.rows[tri].cols[ci];\n SS.push('', getSumFieldValue.call(this, _list, col), ' | ');\n }\n SS.push('\\n
');\n }\n //SS.push('
');\n\n return SS.join('');\n };\n\n var po = [];\n po.push(getBody.call(this, this.headerColGroup, bodyRowData, bodyGroupingData, list));\n if (cfg.footSum) {\n // 바닥 요약\n po.push(getSum.call(this, this.headerColGroup, footSumData, list));\n }\n\n // right\n if (cfg.rightSum) {\n // todo : right 표현 정리\n }\n\n return po.join('');\n };\n\n GRID.body = {\n init: init,\n repaint: repaint,\n repaintCell: repaintCell,\n repaintRow: repaintRow,\n updateRowState: updateRowState,\n updateRowStateAll: updateRowStateAll,\n scrollTo: scrollTo,\n blur: blur,\n moveFocus: moveFocus,\n inlineEdit: inlineEdit,\n getExcelString: getExcelString\n };\n})();\n\n// ax5.ui.grid.collector\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n var sum = function sum() {\n var value = 0;\n var i = this.list.length;\n while (i--) {\n if (!(\"__groupingList\" in this.list[i])) {\n value += U.number(this.list[i][this.key]);\n }\n }\n return value;\n };\n var avg = function avg() {\n var value = 0;\n var i = this.list.length,\n listLength = 0;\n while (i--) {\n if (!(\"__groupingList\" in this.list[i])) {\n value += U.number(this.list[i][this.key]);\n listLength++;\n }\n }\n return U.number(value / (listLength || 1), { \"round\": 2 });\n };\n\n GRID.collector = {\n sum: sum,\n avg: avg\n };\n})();\n// ax5.ui.grid.layout\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var init = function init() {};\n\n var clearGroupingData = function clearGroupingData(_list) {\n var i = 0,\n l = _list.length;\n var returnList = [];\n for (; i < l; i++) {\n if (_list[i] && !_list[i][\"__isGrouping\"]) {\n if (_list[i][this.config.columnKeys.selected]) {\n this.selectedDataIndexs.push(i);\n }\n returnList.push(jQuery.extend({}, _list[i]));\n }\n }\n return returnList;\n };\n\n var initData = function initData(_list) {\n this.selectedDataIndexs = [];\n var i = 0,\n l = _list.length,\n returnList = [],\n appendIndex = 0,\n dataRealRowCount = 0;\n\n if (this.config.body.grouping) {\n var groupingKeys = U.map(this.bodyGrouping.by, function () {\n return {\n key: this,\n compareString: \"\",\n grouping: false,\n list: []\n };\n });\n var gi = 0,\n gl = groupingKeys.length,\n compareString = void 0,\n appendRow = [],\n ari = void 0;\n for (; i < l + 1; i++) {\n gi = 0;\n if (_list[i] && _list[i][this.config.columnKeys.deleted]) {\n this.deletedList.push(_list[i]);\n } else {\n compareString = \"\";\n appendRow = [];\n for (; gi < gl; gi++) {\n if (_list[i]) {\n compareString += \"$|$\" + _list[i][groupingKeys[gi].key];\n }\n if (appendIndex > 0 && compareString != groupingKeys[gi].compareString) {\n var appendRowItem = { keys: [], labels: [], list: groupingKeys[gi].list };\n for (var ki = 0; ki < gi + 1; ki++) {\n appendRowItem.keys.push(groupingKeys[ki].key);\n appendRowItem.labels.push(_list[i - 1][groupingKeys[ki].key]);\n }\n appendRow.push(appendRowItem);\n groupingKeys[gi].list = [];\n }\n groupingKeys[gi].list.push(_list[i]);\n groupingKeys[gi].compareString = compareString;\n }\n\n ari = appendRow.length;\n while (ari--) {\n returnList.push({ __isGrouping: true, __groupingList: appendRow[ari].list, __groupingBy: { keys: appendRow[ari].keys, labels: appendRow[ari].labels } });\n }\n\n if (_list[i]) {\n if (_list[i][this.config.columnKeys.selected]) {\n this.selectedDataIndexs.push(i);\n }\n dataRealRowCount = _list[i][\"__index\"] = i;\n returnList.push(_list[i]);\n appendIndex++;\n }\n }\n }\n } else {\n for (; i < l; i++) {\n if (_list[i] && _list[i][this.config.columnKeys.deleted]) {\n this.deletedList.push(_list[i]);\n } else if (_list[i]) {\n if (_list[i][this.config.columnKeys.selected]) {\n this.selectedDataIndexs.push(i);\n }\n // __index변수를 추가하여 lineNumber 에 출력합니다. (body getFieldValue 에서 출력함)\n _list[i][\"__index\"] = i;\n dataRealRowCount++;\n returnList.push(_list[i]);\n }\n }\n }\n\n // 원본 데이터의 갯수\n // grouping은 제외하고 수집됨.\n this.xvar.dataRealRowCount = dataRealRowCount;\n return returnList;\n };\n\n var set = function set(data) {\n var self = this;\n\n if (U.isArray(data)) {\n this.page = null;\n this.list = initData.call(this, !this.config.remoteSort && Object.keys(this.sortInfo).length ? sort.call(this, this.sortInfo, data) : data);\n this.deletedList = [];\n } else if (\"page\" in data) {\n this.page = jQuery.extend({}, data.page);\n this.list = initData.call(this, !this.config.remoteSort && Object.keys(this.sortInfo).length ? sort.call(this, this.sortInfo, data.list) : data.list);\n this.deletedList = [];\n }\n\n this.needToPaintSum = true;\n this.xvar.frozenRowIndex = this.config.frozenRowIndex > this.list.length ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n\n if (this.config.body.grouping) {}\n return this;\n };\n\n var get = function get(_type) {\n return {\n list: this.list,\n page: this.page\n };\n };\n\n var getList = function getList(_type) {\n var returnList = [];\n var i = 0,\n l = this.list.length;\n switch (_type) {\n case \"modified\":\n for (; i < l; i++) {\n if (this.list[i] && !this.list[i][\"__isGrouping\"] && this.list[i][this.config.columnKeys.modified]) {\n returnList.push(jQuery.extend({}, this.list[i]));\n }\n }\n break;\n case \"selected\":\n for (; i < l; i++) {\n if (this.list[i] && !this.list[i][\"__isGrouping\"] && this.list[i][this.config.columnKeys.selected]) {\n returnList.push(jQuery.extend({}, this.list[i]));\n }\n }\n break;\n case \"deleted\":\n //_list = GRID.data.clearGroupingData(this.list);\n returnList = [].concat(this.deletedList);\n break;\n default:\n returnList = GRID.data.clearGroupingData.call(this, this.list);\n }\n return returnList;\n };\n\n var add = function add(_row, _dindex, _options) {\n var list = this.config.body.grouping ? clearGroupingData.call(this, this.list) : this.list;\n var processor = {\n \"first\": function first() {\n list = [].concat(_row).concat(list);\n },\n \"last\": function last() {\n list = list.concat([].concat(_row));\n }\n };\n\n if (typeof _dindex === \"undefined\") _dindex = \"last\";\n if (_dindex in processor) {\n _row[this.config.columnKeys.modified] = true;\n processor[_dindex].call(this, _row);\n } else {\n if (!U.isNumber(_dindex)) {\n throw 'invalid argument _dindex';\n }\n //\n list = list.splice(_dindex, [].concat(_row));\n }\n\n if (this.config.body.grouping) {\n list = initData.call(this, sort.call(this, this.sortInfo, list));\n } else if (_options && _options.sort && Object.keys(this.sortInfo).length) {\n list = sort.call(this, this.sortInfo, list);\n }\n\n this.list = list;\n\n this.needToPaintSum = true;\n this.xvar.frozenRowIndex = this.config.frozenRowIndex > this.list.length ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n return this;\n };\n\n /**\n * list에서 완전 제거 하는 경우 사용.\n * ax5grid.data.remove\n */\n var remove = function remove(_dindex) {\n var list = this.config.body.grouping ? clearGroupingData.call(this, this.list) : this.list;\n var processor = {\n \"first\": function first() {\n list.splice(_dindex, 1);\n },\n \"last\": function last() {\n var lastIndex = list.length - 1;\n list.splice(lastIndex, 1);\n }\n };\n\n if (typeof _dindex === \"undefined\") _dindex = \"last\";\n if (_dindex in processor) {\n processor[_dindex].call(this, _dindex);\n } else {\n if (!U.isNumber(_dindex)) {\n throw 'invalid argument _dindex';\n }\n //\n list.splice(_dindex, 1);\n }\n\n if (this.config.body.grouping) {\n list = initData.call(this, sort.call(this, this.sortInfo, list));\n } else if (Object.keys(this.sortInfo).length) {\n list = initData.call(this, sort.call(this, this.sortInfo, list));\n } else {\n list = initData.call(this, list);\n }\n\n this.list = list;\n\n this.needToPaintSum = true;\n this.xvar.frozenRowIndex = this.config.frozenRowIndex > this.list.length ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n return this;\n };\n\n /**\n * list에서 deleted 처리 repaint\n * ax5grid.data.deleteRow\n */\n var deleteRow = function deleteRow(_dindex) {\n var list = this.config.body.grouping ? clearGroupingData.call(this, this.list) : this.list;\n var processor = {\n \"first\": function first() {\n list[0][this.config.columnKeys.deleted] = true;\n },\n \"last\": function last() {\n list[list.length - 1][this.config.columnKeys.deleted] = true;\n },\n \"selected\": function selected() {\n var i = list.length;\n while (i--) {\n if (list[i][this.config.columnKeys.selected]) {\n list[i][this.config.columnKeys.deleted] = true;\n }\n }\n }\n };\n\n if (typeof _dindex === \"undefined\") _dindex = \"last\";\n if (_dindex in processor) {\n processor[_dindex].call(this, _dindex);\n } else {\n if (!U.isNumber(_dindex)) {\n throw 'invalid argument _dindex';\n }\n list[_dindex][this.config.columnKeys.deleted] = true;\n }\n\n if (this.config.body.grouping) {\n list = initData.call(this, sort.call(this, this.sortInfo, list));\n } else if (Object.keys(this.sortInfo).length) {\n list = initData.call(this, sort.call(this, this.sortInfo, list));\n } else {\n list = initData.call(this, list);\n }\n\n this.list = list;\n\n this.needToPaintSum = true;\n this.xvar.frozenRowIndex = this.config.frozenRowIndex > this.list.length ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n return this;\n };\n\n var update = function update(_row, _dindex) {\n if (!U.isNumber(_dindex)) {\n throw 'invalid argument _dindex';\n }\n //\n this.needToPaintSum = true;\n this.list.splice(_dindex, 1, _row);\n\n if (this.config.body.grouping) {\n this.list = initData.call(this, clearGroupingData.call(this, this.list));\n }\n };\n\n var setValue = function setValue(_dindex, _key, _value) {\n var originalValue = getValue.call(this, _dindex, _key);\n this.needToPaintSum = true;\n\n if (originalValue !== _value) {\n if (/[\\.\\[\\]]/.test(_key)) {\n try {\n this.list[_dindex][this.config.columnKeys.modified] = true;\n Function(\"val\", \"this\" + GRID.util.getRealPathForDataItem(_key) + \" = val;\").call(this.list[_dindex], _value);\n } catch (e) {}\n } else {\n this.list[_dindex][this.config.columnKeys.modified] = true;\n this.list[_dindex][_key] = _value;\n }\n\n if (this.onDataChanged) {\n this.onDataChanged.call({\n self: this,\n list: this.list,\n dindex: _dindex,\n item: this.list[_dindex],\n key: _key,\n value: _value\n });\n }\n }\n\n return true;\n };\n\n var getValue = function getValue(_dindex, _key, _value) {\n if (/[\\.\\[\\]]/.test(_key)) {\n try {\n _value = Function(\"\", \"return this\" + GRID.util.getRealPathForDataItem(_key) + \";\").call(this.list[_dindex]);\n } catch (e) {}\n } else {\n _value = this.list[_dindex][_key];\n }\n return _value;\n };\n\n var clearSelect = function clearSelect() {\n this.selectedDataIndexs = [];\n };\n\n var select = function select(_dindex, _selected, _options) {\n var cfg = this.config;\n\n if (this.list[_dindex].__isGrouping) return false;\n if (this.list[_dindex][cfg.columnKeys.disableSelection]) return false;\n\n if (typeof _selected === \"undefined\") {\n if (this.list[_dindex][cfg.columnKeys.selected] = !this.list[_dindex][cfg.columnKeys.selected]) {\n this.selectedDataIndexs.push(_dindex);\n }\n } else {\n if (this.list[_dindex][cfg.columnKeys.selected] = _selected) {\n this.selectedDataIndexs.push(_dindex);\n }\n }\n\n if (this.onDataChanged && _options && _options.internalCall) {\n this.onDataChanged.call({\n self: this,\n list: this.list,\n dindex: _dindex,\n item: this.list[_dindex],\n key: cfg.columnKeys.selected,\n value: this.list[_dindex][cfg.columnKeys.selected]\n });\n }\n\n return this.list[_dindex][cfg.columnKeys.selected];\n };\n\n var selectAll = function selectAll(_selected, _options) {\n var cfg = this.config,\n dindex = this.list.length;\n\n if (typeof _selected === \"undefined\") {\n while (dindex--) {\n if (this.list[dindex].__isGrouping) continue;\n if (_options && _options.filter) {\n if (_options.filter.call(this.list[dindex]) !== true) {\n continue;\n }\n }\n if (this.list[dindex][cfg.columnKeys.disableSelection]) continue;\n\n if (this.list[dindex][cfg.columnKeys.selected] = !this.list[dindex][cfg.columnKeys.selected]) {\n this.selectedDataIndexs.push(dindex);\n }\n }\n } else {\n while (dindex--) {\n if (this.list[dindex].__isGrouping) continue;\n if (_options && _options.filter) {\n if (_options.filter.call(this.list[dindex]) !== true) {\n continue;\n }\n }\n if (this.list[dindex][cfg.columnKeys.disableSelection]) continue;\n\n if (this.list[dindex][cfg.columnKeys.selected] = _selected) {\n this.selectedDataIndexs.push(dindex);\n }\n }\n }\n\n if (this.onDataChanged && _options && _options.internalCall) {\n this.onDataChanged.call({\n self: this,\n list: this.list\n });\n }\n\n return this.list;\n };\n\n var sort = function sort(_sortInfo, _list) {\n var self = this,\n list = _list || this.list,\n sortInfoArray = [];\n var getKeyValue = function getKeyValue(_item, _key, _value) {\n if (/[\\.\\[\\]]/.test(_key)) {\n try {\n _value = Function(\"\", \"return this\" + GRID.util.getRealPathForDataItem(_key) + \";\").call(_item);\n } catch (e) {}\n } else {\n _value = _item[_key];\n }\n return _value;\n };\n\n for (var k in _sortInfo) {\n sortInfoArray[_sortInfo[k].seq] = { key: k, order: _sortInfo[k].orderBy };\n }\n sortInfoArray = U.filter(sortInfoArray, function () {\n return typeof this !== \"undefined\";\n });\n\n var i = 0,\n l = sortInfoArray.length,\n _a_val = void 0,\n _b_val = void 0;\n\n list.sort(function (_a, _b) {\n for (i = 0; i < l; i++) {\n _a_val = getKeyValue(_a, sortInfoArray[i].key);\n _b_val = getKeyValue(_b, sortInfoArray[i].key);\n\n if ((typeof _a_val === 'undefined' ? 'undefined' : _typeof(_a_val)) !== (typeof _b_val === 'undefined' ? 'undefined' : _typeof(_b_val))) {\n _a_val = '' + _a_val;\n _b_val = '' + _b_val;\n }\n if (_a_val < _b_val) {\n return sortInfoArray[i].order === \"asc\" ? -1 : 1;\n } else if (_a_val > _b_val) {\n return sortInfoArray[i].order === \"asc\" ? 1 : -1;\n }\n }\n });\n\n if (_list) {\n return list;\n } else {\n this.xvar.frozenRowIndex = this.config.frozenRowIndex > this.list.length ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n return this;\n }\n };\n\n GRID.data = {\n init: init,\n set: set,\n get: get,\n getList: getList,\n setValue: setValue,\n getValue: getValue,\n clearSelect: clearSelect,\n select: select,\n selectAll: selectAll,\n add: add,\n remove: remove,\n deleteRow: deleteRow,\n update: update,\n sort: sort,\n initData: initData,\n clearGroupingData: clearGroupingData\n };\n})();\n/*\n * Copyright (c) 2016. tom@axisj.com\n * - github.com/thomasjang\n * - www.axisj.com\n */\n\n// ax5.ui.grid.excel\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var base64 = function base64(s) {\n return window.btoa(unescape(encodeURIComponent(s)));\n };\n var uri = \"data:application/vnd.ms-excel;base64,\";\n\n var getExcelTmpl = function getExcelTmpl() {\n return '\\uFEFF\\n{{#tables}}{{{body}}}{{/tables}}\\n';\n };\n\n var tableToExcel = function tableToExcel(table, fileName) {\n var link, a, output;\n var tables = [].concat(table);\n\n output = ax5.mustache.render(getExcelTmpl(), {\n worksheet: function () {\n var arr = [];\n tables.forEach(function (t, ti) {\n arr.push({ name: \"Sheet\" + (ti + 1) });\n });\n return arr;\n }(),\n tables: function () {\n var arr = [];\n tables.forEach(function (t, ti) {\n arr.push({ body: t });\n });\n return arr;\n }()\n });\n\n var isChrome = navigator.userAgent.indexOf(\"Chrome\") > -1;\n var isSafari = !isChrome && navigator.userAgent.indexOf(\"Safari\") > -1;\n\n var isIE = /*@cc_on!@*/false || !!document.documentMode; // this works with IE10 and IE11 both :)\n if (navigator.msSaveOrOpenBlob) {\n var blob1 = new Blob([output], { type: \"text/html\" });\n window.navigator.msSaveOrOpenBlob(blob1, fileName);\n } else if (isSafari) {\n // 사파리는 지원이 안되므로 그냥 테이블을 클립보드에 복사처리\n //tables\n var blankWindow = window.open('about:blank', this.id + '-excel-export', 'width=600,height=400');\n blankWindow.document.write(output);\n blankWindow = null;\n } else {\n if (isIE && typeof Blob === \"undefined\") {\n\n //otherwise use the iframe and save\n //requires a blank iframe on page called txtArea1\n var $iframe = jQuery('
');\n jQuery(document.body).append($iframe);\n var iframe = window[this.id + '-excel-export'];\n iframe.document.open(\"text/html\", \"replace\");\n iframe.document.write(output);\n iframe.document.close();\n iframe.focus();\n iframe.document.execCommand(\"SaveAs\", true, fileName);\n $iframe.remove();\n } else {\n // Attempt to use an alternative method\n var anchor = document.body.appendChild(document.createElement(\"a\"));\n\n // If the [download] attribute is supported, try to use it\n if (\"download\" in anchor) {\n anchor.download = fileName;\n //anchor.href = URL.createObjectURL( blob );\n anchor.href = uri + base64(output);\n anchor.click();\n document.body.removeChild(anchor);\n }\n }\n }\n\n return true;\n };\n\n GRID.excel = {\n export: tableToExcel\n };\n})();\n// ax5.ui.grid.formatter\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n var money = function money() {\n return U.number(this.value, { \"money\": true });\n };\n\n GRID.formatter = {\n money: money\n };\n})();\n// ax5.ui.grid.header\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var columnResizerEvent = {\n \"on\": function on(_columnResizer, _colIndex) {\n var self = this;\n var $columnResizer = $(_columnResizer);\n var columnResizerPositionLeft = $columnResizer.offset().left;\n var gridTargetOffsetLeft = self.$[\"container\"][\"root\"].offset().left;\n self.xvar.columnResizerIndex = _colIndex;\n var resizeRange = {\n min: -self.colGroup[_colIndex]._width + 2,\n max: self.colGroup[_colIndex + 1] ? self.colGroup[_colIndex + 1]._width : self.$[\"container\"][\"root\"].width() - 2\n };\n //console.log(resizeRange);\n\n jQuery(document.body).bind(GRID.util.ENM[\"mousemove\"] + \".ax5grid-\" + this.instanceId, function (e) {\n var mouseObj = GRID.util.getMousePosition(e);\n self.xvar.__da = mouseObj.clientX - self.xvar.mousePosition.clientX;\n\n if (resizeRange.min > self.xvar.__da) {\n self.xvar.__da = resizeRange.min;\n } else if (resizeRange.max < self.xvar.__da) {\n self.xvar.__da = resizeRange.max;\n }\n\n if (!self.xvar.columnResizerLived) {\n self.$[\"resizer\"][\"horizontal\"].addClass(\"live\");\n }\n self.xvar.columnResizerLived = true;\n self.$[\"resizer\"][\"horizontal\"].css({\n left: columnResizerPositionLeft + self.xvar.__da - gridTargetOffsetLeft\n });\n }).bind(GRID.util.ENM[\"mouseup\"] + \".ax5grid-\" + this.instanceId, function (e) {\n columnResizerEvent.off.call(self);\n U.stopEvent(e);\n }).bind(\"mouseleave.ax5grid-\" + this.instanceId, function (e) {\n columnResizerEvent.off.call(self);\n U.stopEvent(e);\n });\n\n jQuery(document.body).attr('unselectable', 'on').css('user-select', 'none').on('selectstart', false);\n },\n \"off\": function off() {\n this.$[\"resizer\"][\"horizontal\"].removeClass(\"live\");\n this.xvar.columnResizerLived = false;\n\n if (typeof this.xvar.__da === \"undefined\") {} else {\n this.setColumnWidth(this.colGroup[this.xvar.columnResizerIndex]._width + this.xvar.__da, this.xvar.columnResizerIndex);\n }\n\n jQuery(document.body).unbind(GRID.util.ENM[\"mousemove\"] + \".ax5grid-\" + this.instanceId).unbind(GRID.util.ENM[\"mouseup\"] + \".ax5grid-\" + this.instanceId).unbind(\"mouseleave.ax5grid-\" + this.instanceId);\n\n jQuery(document.body).removeAttr('unselectable').css('user-select', 'auto').off('selectstart');\n }\n };\n\n var init = function init() {\n // 헤더 초기화\n var self = this;\n\n this.$[\"container\"][\"header\"].on(\"click\", '[data-ax5grid-column-attr]', function (e) {\n var key = this.getAttribute(\"data-ax5grid-column-key\"),\n colIndex = this.getAttribute(\"data-ax5grid-column-colindex\"),\n rowIndex = this.getAttribute(\"data-ax5grid-column-rowindex\"),\n col = self.colGroup[colIndex];\n\n if (key === \"__checkbox_header__\") {\n var selected = this.getAttribute(\"data-ax5grid-selected\");\n selected = U.isNothing(selected) ? true : selected === \"true\" ? false : true;\n\n $(this).attr(\"data-ax5grid-selected\", selected);\n self.selectAll({ selected: selected });\n } else {\n if (key && col) {\n if ((col.sortable === true || self.config.sortable === true) && col.sortable !== false) {\n if (!col.sortFixed) toggleSort.call(self, col.key);\n }\n }\n }\n\n GRID.body.blur.call(self);\n });\n this.$[\"container\"][\"header\"].on(\"mousedown\", '[data-ax5grid-column-resizer]', function (e) {\n var colIndex = this.getAttribute(\"data-ax5grid-column-resizer\");\n self.xvar.mousePosition = GRID.util.getMousePosition(e);\n columnResizerEvent.on.call(self, this, Number(colIndex));\n U.stopEvent(e);\n }).on(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n resetFrozenColumn.call(this);\n };\n\n var resetFrozenColumn = function resetFrozenColumn() {\n var cfg = this.config,\n dividedHeaderObj = GRID.util.divideTableByFrozenColumnIndex(this.headerTable, this.config.frozenColumnIndex);\n this.asideHeaderData = function (dataTable) {\n var colGroup = [];\n var data = { rows: [] };\n for (var i = 0, l = dataTable.rows.length; i < l; i++) {\n data.rows[i] = { cols: [] };\n if (i === 0) {\n var col = {\n label: \"\",\n colspan: 1,\n rowspan: dataTable.rows.length,\n colIndex: null\n },\n _col = {};\n\n if (cfg.showLineNumber) {\n _col = jQuery.extend({}, col, {\n width: cfg.lineNumberColumnWidth,\n _width: cfg.lineNumberColumnWidth,\n columnAttr: \"lineNumber\",\n key: \"__index_header__\", label: \" \"\n });\n colGroup.push(_col);\n data.rows[i].cols.push(_col);\n }\n if (cfg.showRowSelector) {\n _col = jQuery.extend({}, col, {\n width: cfg.rowSelectorColumnWidth,\n _width: cfg.rowSelectorColumnWidth,\n columnAttr: \"rowSelector\",\n key: \"__checkbox_header__\", label: \"\"\n });\n colGroup.push(_col);\n data.rows[i].cols.push(_col);\n }\n }\n }\n\n this.asideColGroup = colGroup;\n return data;\n }.call(this, this.headerTable);\n this.leftHeaderData = dividedHeaderObj.leftData;\n this.headerData = dividedHeaderObj.rightData;\n };\n\n var getFieldValue = function getFieldValue(_col) {\n var cfg = this.config,\n colGroup = this.colGroup,\n _key = _col.key,\n tagsToReplace = {\n '<': '<',\n '>': '>'\n };\n\n if (_key === \"__checkbox_header__\") {\n return '
';\n } else {\n return _col.label || \" \";\n }\n };\n\n var repaint = function repaint(_reset) {\n var cfg = this.config,\n colGroup = this.colGroup;\n\n if (_reset) {\n resetFrozenColumn.call(this);\n this.xvar.paintStartRowIndex = undefined;\n }\n var asideHeaderData = this.asideHeaderData,\n leftHeaderData = this.leftHeaderData,\n headerData = this.headerData,\n headerAlign = cfg.header.align;\n\n // this.asideColGroup : asideHeaderData에서 처리 함.\n this.leftHeaderColGroup = colGroup.slice(0, this.config.frozenColumnIndex);\n this.headerColGroup = colGroup.slice(this.config.frozenColumnIndex);\n\n var repaintHeader = function repaintHeader(_elTarget, _colGroup, _bodyRow) {\n var tableWidth = 0,\n SS = [];\n SS.push('
');\n SS.push('');\n for (var cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n tableWidth += _colGroup[cgi]._width;\n }\n SS.push('');\n SS.push('');\n\n for (var tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n var trCSS_class = \"\";\n SS.push('');\n for (var ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n var col = _bodyRow.rows[tri].cols[ci];\n var cellHeight = cfg.header.columnHeight * col.rowspan - cfg.header.columnBorderWidth;\n var colAlign = headerAlign || col.align;\n SS.push('');\n\n SS.push(function () {\n var lineHeight = cfg.header.columnHeight - cfg.header.columnPadding * 2 - cfg.header.columnBorderWidth;\n return '';\n }(), function () {\n var _SS = \"\";\n\n if (!U.isNothing(col.key) && !U.isNothing(col.colIndex) && (cfg.sortable === true || col.sortable === true) && col.sortable !== false) {\n _SS += '';\n }\n return _SS;\n }(), getFieldValue.call(this, col), '');\n\n if (!U.isNothing(col.colIndex)) {\n if (cfg.enableFilter) {\n SS.push('');\n }\n }\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n SS.push('
');\n _elTarget.html(SS.join(''));\n\n /// append column-resizer\n (function () {\n var resizerHeight = cfg.header.columnHeight * _bodyRow.rows.length - cfg.header.columnBorderWidth,\n resizerLeft = 0,\n AS = [];\n\n for (var cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n var col = _colGroup[cgi];\n if (!U.isNothing(col.colIndex)) {\n //_colGroup[cgi]._width\n resizerLeft += col._width;\n AS.push('
');\n }\n }\n _elTarget.append(AS);\n }).call(this);\n\n return tableWidth;\n };\n\n if (cfg.asidePanelWidth > 0) {\n repaintHeader.call(this, this.$.panel[\"aside-header\"], this.asideColGroup, asideHeaderData);\n }\n if (cfg.frozenColumnIndex > 0) {\n repaintHeader.call(this, this.$.panel[\"left-header\"], this.leftHeaderColGroup, leftHeaderData);\n }\n this.xvar.scrollContentWidth = repaintHeader.call(this, this.$.panel[\"header-scroll\"], this.headerColGroup, headerData);\n\n if (cfg.rightSum) {}\n };\n\n var scrollTo = function scrollTo(css) {\n this.$.panel[\"header-scroll\"].css(css);\n return this;\n };\n\n var toggleSort = function toggleSort(_key) {\n var sortOrder = \"\",\n sortInfo = {},\n seq = 0;\n\n for (var k in this.sortInfo) {\n if (this.sortInfo[k].fixed) {\n sortInfo[k] = this.sortInfo[k];\n seq++;\n }\n }\n\n for (var i = 0, l = this.colGroup.length; i < l; i++) {\n if (this.colGroup[i].key == _key) {\n if (sortOrder == \"\") {\n if (typeof this.colGroup[i].sort === \"undefined\") {\n sortOrder = \"desc\";\n } else if (this.colGroup[i].sort === \"desc\") {\n sortOrder = \"asc\";\n } else {\n sortOrder = undefined;\n }\n }\n this.colGroup[i].sort = sortOrder;\n } else if (!this.config.multiSort) {\n this.colGroup[i].sort = undefined;\n }\n\n if (typeof this.colGroup[i].sort !== \"undefined\") {\n if (!sortInfo[this.colGroup[i].key]) {\n sortInfo[this.colGroup[i].key] = {\n seq: seq++,\n orderBy: this.colGroup[i].sort\n };\n }\n }\n }\n\n this.setColumnSort(sortInfo);\n return this;\n };\n\n var applySortStatus = function applySortStatus(_sortInfo) {\n for (var i = 0, l = this.colGroup.length; i < l; i++) {\n for (var _key in _sortInfo) {\n if (this.colGroup[i].key == _key) {\n this.colGroup[i].sort = _sortInfo[_key].orderBy;\n }\n }\n }\n return this;\n };\n\n var select = function select(_options) {\n GRID.data.select.call(this, dindex, _options && _options.selected);\n GRID.body.updateRowState.call(this, [\"selected\"], dindex);\n };\n\n var getExcelString = function getExcelString() {\n var cfg = this.config,\n colGroup = this.colGroup,\n headerData = this.headerTable,\n getHeader = function getHeader(_colGroup, _bodyRow) {\n var SS = [];\n //SS.push('
');\n for (var tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('');\n for (var ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n var col = _bodyRow.rows[tri].cols[ci];\n SS.push('', getFieldValue.call(this, col), ' | ');\n }\n SS.push('
');\n }\n //SS.push('
');\n\n return SS.join('');\n };\n\n return getHeader.call(this, colGroup, headerData);\n };\n\n GRID.header = {\n init: init,\n repaint: repaint,\n scrollTo: scrollTo,\n toggleSort: toggleSort,\n applySortStatus: applySortStatus,\n getExcelString: getExcelString\n };\n})();\n// ax5.ui.grid.inlineEditor\n(function () {\n\n var GRID = ax5.ui.grid;\n\n var edit_text = {\n useReturnToSave: true,\n editMode: \"popup\",\n getHtml: function getHtml(_root, _columnKey, _editor, _value) {\n return '
';\n },\n init: function init(_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n $el.on(\"blur\", function () {\n GRID.body.inlineEdit.deActive.call(_root, \"RETURN\", _columnKey);\n });\n return $el;\n },\n bindUI: function bindUI(_root, _columnKey, _$el, _editor, _$parent, _value) {\n _$el.focus().select();\n }\n };\n\n var edit_money = {\n useReturnToSave: true,\n editMode: \"popup\",\n getHtml: function getHtml(_root, _columnKey, _editor, _value) {\n return '
';\n },\n init: function init(_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n $el.on(\"blur\", function () {\n GRID.body.inlineEdit.deActive.call(_root, \"RETURN\", _columnKey);\n });\n return $el;\n },\n bindUI: function bindUI(_root, _columnKey, _$el, _editor, _$parent, _value) {\n _$el.data(\"binded-ax5ui\", \"ax5formater\");\n _$el.ax5formatter({\n pattern: \"money\"\n });\n _$el.focus().select();\n }\n };\n\n var edit_number = {\n useReturnToSave: true,\n editMode: \"popup\",\n getHtml: function getHtml(_root, _columnKey, _editor, _value) {\n return '
';\n },\n init: function init(_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n $el.on(\"blur\", function () {\n GRID.body.inlineEdit.deActive.call(_root, \"RETURN\", _columnKey);\n });\n return $el;\n },\n bindUI: function bindUI(_root, _columnKey, _$el, _editor, _$parent, _value) {\n _$el.data(\"binded-ax5ui\", \"ax5formater\");\n _$el.ax5formatter({\n pattern: \"number\"\n });\n _$el.focus().select();\n }\n };\n\n var edit_date = {\n useReturnToSave: true,\n editMode: \"popup\",\n getHtml: function getHtml(_root, _columnKey, _editor, _value) {\n return '
';\n },\n init: function init(_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n return $el;\n },\n bindUI: function bindUI(_root, _columnKey, _$el, _editor, _$parent, _value) {\n var self = _root;\n _$el.data(\"binded-ax5ui\", \"ax5picker\");\n _$el.ax5picker({\n direction: \"auto\",\n content: {\n type: 'date',\n formatter: {\n pattern: 'date'\n }\n },\n onStateChanged: function onStateChanged() {\n if (this.state == \"open\") {\n this.self.activePicker.attr(\"data-ax5grid-inline-edit-picker\", \"date\");\n } else if (this.state == \"close\") {\n GRID.body.inlineEdit.deActive.call(self, \"RETURN\", _columnKey);\n }\n }\n });\n _$el.focus().select();\n }\n };\n\n var edit_select = {\n useReturnToSave: false,\n editMode: \"popup\",\n getHtml: function getHtml(_root, _columnKey, _editor, _value) {\n var po = [];\n po.push('
');\n po.push('
');\n\n return po.join('');\n },\n init: function init(_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n return $el;\n },\n bindUI: function bindUI(_root, _columnKey, _$el, _editor, _$parent, _value) {\n var eConfig = {\n columnKeys: {\n optionValue: \"value\",\n optionText: \"text\",\n optionSelected: \"selected\"\n }\n };\n jQuery.extend(true, eConfig, _editor.config);\n\n eConfig.options.forEach(function (n) {\n if (n[eConfig.columnKeys.optionValue] == _value) n[eConfig.columnKeys.optionSelected] = true;\n });\n\n var self = _root;\n _$el.data(\"binded-ax5ui\", \"ax5select\");\n _$el.ax5select({\n direction: \"auto\",\n columnKeys: eConfig.columnKeys,\n options: eConfig.options,\n onStateChanged: function onStateChanged() {\n if (this.state == \"open\") {\n this.self.activeSelectOptionGroup.attr(\"data-ax5grid-inline-edit-picker\", \"select\");\n } else if (this.state == \"changeValue\") {\n GRID.body.inlineEdit.deActive.call(self, \"RETURN\", _columnKey, this.value[0][eConfig.columnKeys.optionValue]);\n } else if (this.state == \"close\") {\n GRID.body.inlineEdit.deActive.call(self, \"ESC\", _columnKey);\n }\n }\n });\n _$el.ax5select(\"open\");\n _$el.ax5select(\"setValue\", _value);\n _$el.find(\"a\").focus();\n }\n };\n\n var edit_checkbox = {\n editMode: \"inline\",\n getHtml: function getHtml(_root, _editor, _value) {\n\n var lineHeight = _root.config.body.columnHeight - _root.config.body.columnPadding * 2 - _root.config.body.columnBorderWidth;\n var checked;\n if (_editor.config && _editor.config.trueValue) {\n checked = _value == _editor.config.trueValue ? \"true\" : \"false\";\n } else {\n checked = _value == false || _value == \"false\" || _value < \"1\" ? \"false\" : \"true\";\n }\n\n var eConfig = {\n marginTop: 2,\n height: lineHeight - 4\n };\n jQuery.extend(true, eConfig, _editor.config);\n eConfig.marginTop = (lineHeight - eConfig.height) / 2;\n\n return '
';\n }\n };\n\n GRID.inlineEditor = {\n \"text\": edit_text,\n \"money\": edit_money,\n \"number\": edit_number,\n \"date\": edit_date,\n \"select\": edit_select,\n \"checkbox\": edit_checkbox\n };\n})();\n// ax5.ui.grid.page\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var onclickPageMove = function onclickPageMove(_act) {\n var callback = function callback(_pageNo) {\n if (this.page.currentPage != _pageNo) {\n this.page.selectPage = _pageNo;\n if (this.config.page.onChange) {\n this.config.page.onChange.call({\n self: this,\n page: this.page,\n data: this.data\n });\n }\n }\n };\n var processor = {\n \"first\": function first() {\n callback.call(this, 0);\n },\n \"prev\": function prev() {\n var pageNo = this.page.currentPage - 1;\n if (pageNo < 0) pageNo = 0;\n callback.call(this, pageNo);\n },\n \"next\": function next() {\n var pageNo = this.page.currentPage + 1;\n if (pageNo > this.page.totalPages - 1) pageNo = this.page.totalPages - 1;\n callback.call(this, pageNo);\n },\n \"last\": function last() {\n callback.call(this, this.page.totalPages - 1);\n }\n };\n\n if (_act in processor) {\n processor[_act].call(this);\n } else {\n callback.call(this, _act - 1);\n }\n };\n\n var navigationUpdate = function navigationUpdate() {\n var self = this;\n if (this.page) {\n var page = {\n hasPage: false,\n currentPage: this.page.currentPage,\n pageSize: this.page.pageSize,\n totalElements: this.page.totalElements,\n totalPages: this.page.totalPages,\n firstIcon: this.config.page.firstIcon,\n prevIcon: this.config.page.prevIcon || \"«\",\n nextIcon: this.config.page.nextIcon || \"»\",\n lastIcon: this.config.page.lastIcon\n };\n var navigationItemCount = this.config.page.navigationItemCount;\n\n page[\"@paging\"] = function () {\n var returns = [];\n\n var startI = page.currentPage - Math.floor(navigationItemCount / 2);\n if (startI < 0) startI = 0;\n var endI = page.currentPage + navigationItemCount;\n if (endI > page.totalPages) endI = page.totalPages;\n\n if (endI - startI > navigationItemCount) {\n endI = startI + navigationItemCount;\n }\n\n if (endI - startI < navigationItemCount) {\n startI = endI - navigationItemCount;\n }\n if (startI < 0) startI = 0;\n\n for (var p = startI, l = endI; p < l; p++) {\n returns.push({ 'pageNo': p + 1, 'selected': page.currentPage == p });\n }\n return returns;\n }();\n\n if (page[\"@paging\"].length > 0) {\n page.hasPage = true;\n }\n\n this.$[\"page\"][\"navigation\"].html(GRID.tmpl.get(\"page_navigation\", page));\n this.$[\"page\"][\"navigation\"].find(\"[data-ax5grid-page-move]\").on(\"click\", function () {\n var act = this.getAttribute(\"data-ax5grid-page-move\");\n onclickPageMove.call(self, act);\n });\n } else {\n this.$[\"page\"][\"navigation\"].empty();\n }\n };\n\n var statusUpdate = function statusUpdate() {\n var fromRowIndex = this.xvar.paintStartRowIndex;\n var toRowIndex = this.xvar.paintStartRowIndex + this.xvar.paintRowCount - 1;\n //var totalElements = (this.page && this.page.totalElements) ? this.page.totalElements : this.xvar.dataRowCount;\n var totalElements = this.xvar.dataRowCount;\n if (toRowIndex > totalElements) {\n toRowIndex = totalElements;\n }\n\n this.$[\"page\"][\"status\"].html(GRID.tmpl.get(\"page_status\", {\n fromRowIndex: U.number(fromRowIndex + 1, { \"money\": true }),\n toRowIndex: U.number(toRowIndex, { \"money\": true }),\n totalElements: U.number(totalElements, { \"money\": true }),\n dataRowCount: totalElements !== this.xvar.dataRealRowCount ? U.number(this.xvar.dataRealRowCount, { \"money\": true }) : false\n }));\n };\n\n GRID.page = {\n navigationUpdate: navigationUpdate,\n statusUpdate: statusUpdate\n };\n})();\n// ax5.ui.grid.scroller\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var convertScrollPosition = {\n \"vertical\": function vertical(css, _var) {\n var _content_height = _var._content_height - _var._panel_height;\n var _scroller_height = _var._vertical_scroller_height - _var.verticalScrollBarHeight;\n var top = _content_height * css.top / _scroller_height;\n if (top < 0) top = 0;else if (_content_height < top) {\n top = _content_height;\n }\n return {\n top: -top\n };\n },\n \"horizontal\": function horizontal(css, _var) {\n var _content_width = _var._content_width - _var._panel_width;\n var _scroller_width = _var._horizontal_scroller_width - _var.horizontalScrollBarWidth;\n var left = _content_width * css.left / _scroller_width;\n if (left < 0) left = 0;else if (_content_width < left) {\n left = _content_width;\n }\n return {\n left: -left\n };\n }\n };\n var convertScrollBarPosition = {\n \"vertical\": function vertical(_top, _var) {\n\n var type = \"vertical\";\n var _content_height = _var._content_height - _var._panel_height;\n var _scroller_height = _var._vertical_scroller_height - _var.verticalScrollBarHeight;\n var top = _scroller_height * _top / _content_height;\n\n if (-top > _scroller_height) {\n top = -_scroller_height;\n\n var scrollPositon = convertScrollPosition[type].call(this, { top: -top }, {\n _content_width: _var._content_width,\n _content_height: _var._content_height,\n _panel_width: _var._panel_width,\n _panel_height: _var._panel_height,\n _horizontal_scroller_width: _var._horizontal_scroller_width,\n _vertical_scroller_height: _var._vertical_scroller_height,\n verticalScrollBarHeight: _var.verticalScrollBarHeight,\n horizontalScrollBarWidth: _var.horizontalScrollBarWidth\n });\n\n GRID.body.scrollTo.call(this, scrollPositon);\n }\n\n return -top;\n },\n \"horizontal\": function horizontal(_left, _var) {\n var type = \"horizontal\";\n var _content_width = _var._content_width - _var._panel_width;\n var _scroller_width = _var._horizontal_scroller_width - _var.horizontalScrollBarWidth;\n var left = _scroller_width * _left / _content_width;\n\n if (-left > _scroller_width) {\n left = -_scroller_width;\n var scrollPositon = convertScrollPosition[type].call(this, { left: -left }, {\n _content_width: _var._content_width,\n _content_height: _var._content_height,\n _panel_width: _var._panel_width,\n _panel_height: _var._panel_height,\n _horizontal_scroller_width: _var._horizontal_scroller_width,\n _vertical_scroller_height: _var._vertical_scroller_height,\n verticalScrollBarHeight: _var.verticalScrollBarHeight,\n horizontalScrollBarWidth: _var.horizontalScrollBarWidth\n });\n\n GRID.header.scrollTo.call(this, scrollPositon);\n GRID.body.scrollTo.call(this, scrollPositon);\n }\n\n return -left;\n }\n };\n var scrollBarMover = {\n \"click\": function click(track, bar, type, e) {\n\n // 마우스 무브 완료 타임과 클릭타임 차이가 20 보다 작으면 클릭이벤트 막기.\n if (new Date().getTime() - GRID.scroller.moveout_timer < 20) {\n return false;\n }\n\n var self = this,\n trackOffset = track.offset(),\n barBox = {\n width: bar.outerWidth(), height: bar.outerHeight()\n },\n trackBox = {\n width: track.innerWidth(), height: track.innerHeight()\n },\n _vertical_scroller_height = self.$[\"scroller\"][\"vertical\"].innerHeight(),\n _panel_height = self.$[\"panel\"][\"body\"].height(),\n _horizontal_scroller_width = self.$[\"scroller\"][\"horizontal\"].innerWidth(),\n _panel_width = self.$[\"panel\"][\"body\"].width(),\n _content_height = self.xvar.scrollContentHeight,\n _content_width = self.xvar.scrollContentWidth,\n verticalScrollBarHeight = self.$[\"scroller\"][\"vertical-bar\"].outerHeight(),\n horizontalScrollBarWidth = self.$[\"scroller\"][\"horizontal-bar\"].outerWidth(),\n getScrollerPosition = {\n \"vertical\": function vertical(e) {\n var mouseObj = GRID.util.getMousePosition(e);\n // track을 벗어 나지 안도록 범위 체크\n var newTop = mouseObj.clientY - trackOffset.top;\n if (newTop < 0) {\n newTop = 0;\n } else if (newTop + barBox.height > trackBox.height) {\n newTop = trackBox.height - barBox.height;\n }\n return { top: newTop };\n },\n \"horizontal\": function horizontal(e) {\n var mouseObj = GRID.util.getMousePosition(e);\n // track을 벗어 나지 안도록 범위 체크\n var newLeft = mouseObj.clientX - trackOffset.left;\n if (newLeft < 0) {\n newLeft = 0;\n } else if (newLeft + barBox.width > trackBox.width) {\n newLeft = trackBox.width - barBox.width;\n }\n return { left: newLeft };\n }\n };\n\n var css = getScrollerPosition[type](e);\n bar.css(css);\n\n var scrollPositon = convertScrollPosition[type].call(self, css, {\n _content_width: _content_width,\n _content_height: _content_height,\n _panel_width: _panel_width,\n _panel_height: _panel_height,\n _horizontal_scroller_width: _horizontal_scroller_width,\n _vertical_scroller_height: _vertical_scroller_height,\n verticalScrollBarHeight: verticalScrollBarHeight,\n horizontalScrollBarWidth: horizontalScrollBarWidth\n });\n if (type === \"horizontal\") GRID.header.scrollTo.call(self, scrollPositon);\n GRID.body.scrollTo.call(self, scrollPositon);\n },\n \"on\": function on(track, bar, type, e) {\n var self = this,\n barOffset = bar.position(),\n barBox = {\n width: bar.outerWidth(), height: bar.outerHeight()\n },\n trackBox = {\n width: track.innerWidth(), height: track.innerHeight()\n },\n _vertical_scroller_height = self.$[\"scroller\"][\"vertical\"].innerHeight(),\n _panel_height = self.$[\"panel\"][\"body\"].height(),\n _horizontal_scroller_width = self.$[\"scroller\"][\"horizontal\"].innerWidth(),\n _panel_width = self.$[\"panel\"][\"body\"].width(),\n _content_height = self.xvar.scrollContentHeight,\n _content_width = self.xvar.scrollContentWidth,\n verticalScrollBarHeight = self.$[\"scroller\"][\"vertical-bar\"].outerHeight(),\n horizontalScrollBarWidth = self.$[\"scroller\"][\"horizontal-bar\"].outerWidth(),\n getScrollerPosition = {\n \"vertical\": function vertical(e) {\n var mouseObj = GRID.util.getMousePosition(e);\n self.xvar.__da = mouseObj.clientY - self.xvar.mousePosition.clientY;\n // track을 벗어 나지 안도록 범위 체크\n var newTop = barOffset.top + self.xvar.__da;\n if (newTop < 0) {\n newTop = 0;\n } else if (newTop + barBox.height > trackBox.height) {\n newTop = trackBox.height - barBox.height;\n }\n return { top: newTop };\n },\n \"horizontal\": function horizontal(e) {\n var mouseObj = GRID.util.getMousePosition(e);\n self.xvar.__da = mouseObj.clientX - self.xvar.mousePosition.clientX;\n // track을 벗어 나지 안도록 범위 체크\n var newLeft = barOffset.left + self.xvar.__da;\n if (newLeft < 0) {\n newLeft = 0;\n } else if (newLeft + barBox.width > trackBox.width) {\n newLeft = trackBox.width - barBox.width;\n }\n return { left: newLeft };\n }\n };\n\n self.xvar.__da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n\n jQuery(document.body).bind(GRID.util.ENM[\"mousemove\"] + \".ax5grid-\" + this.instanceId, function (e) {\n var css = getScrollerPosition[type](e);\n bar.css(css);\n\n var scrollPositon = convertScrollPosition[type].call(self, css, {\n _content_width: _content_width,\n _content_height: _content_height,\n _panel_width: _panel_width,\n _panel_height: _panel_height,\n _horizontal_scroller_width: _horizontal_scroller_width,\n _vertical_scroller_height: _vertical_scroller_height,\n verticalScrollBarHeight: verticalScrollBarHeight,\n horizontalScrollBarWidth: horizontalScrollBarWidth\n });\n\n if (type === \"horizontal\") GRID.header.scrollTo.call(self, scrollPositon);\n GRID.body.scrollTo.call(self, scrollPositon);\n }).bind(GRID.util.ENM[\"mouseup\"] + \".ax5grid-\" + this.instanceId, function (e) {\n scrollBarMover.off.call(self);\n }).bind(\"mouseleave.ax5grid-\" + this.instanceId, function (e) {\n scrollBarMover.off.call(self);\n });\n\n jQuery(document.body).attr('unselectable', 'on').css('user-select', 'none').on('selectstart', false);\n },\n \"off\": function off() {\n\n GRID.scroller.moveout_timer = new Date().getTime();\n\n jQuery(document.body).unbind(GRID.util.ENM[\"mousemove\"] + \".ax5grid-\" + this.instanceId).unbind(GRID.util.ENM[\"mouseup\"] + \".ax5grid-\" + this.instanceId).unbind(\"mouseleave.ax5grid-\" + this.instanceId);\n\n jQuery(document.body).removeAttr('unselectable').css('user-select', 'auto').off('selectstart');\n }\n };\n var scrollContentMover = {\n \"wheel\": function wheel(delta) {\n var self = this,\n _body_scroll_position = self.$[\"panel\"][\"body-scroll\"].position(),\n _panel_height = self.$[\"panel\"][\"body\"].height(),\n _panel_width = self.$[\"panel\"][\"body\"].width(),\n _content_height = self.xvar.scrollContentHeight,\n _content_width = self.xvar.scrollContentWidth;\n\n if (isNaN(_content_height) || isNaN(_content_width)) {\n return false;\n }\n\n var newLeft = void 0,\n newTop = void 0,\n _top_is_end = false,\n _left_is_end = false;\n\n newLeft = _body_scroll_position.left - delta.x;\n newTop = _body_scroll_position.top - delta.y;\n\n // newTop이 범위를 넘었는지 체크\n if (newTop >= 0) {\n newTop = 0;\n _top_is_end = true;\n } else if (newTop <= _panel_height - _content_height) {\n newTop = _panel_height - _content_height;\n if (newTop >= 0) newTop = 0;\n _top_is_end = true;\n } else {\n if (delta.y == 0) _top_is_end = true;\n }\n\n // newLeft이 범위를 넘었는지 체크\n if (newLeft >= 0) {\n newLeft = 0;\n _left_is_end = true;\n } else if (newLeft <= _panel_width - _content_width) {\n newLeft = _panel_width - _content_width;\n if (newLeft >= 0) newLeft = 0;\n _left_is_end = true;\n } else {\n if (delta.x == 0) _left_is_end = true;\n }\n\n //self.$[\"panel\"][\"body-scroll\"].css({left: newLeft, top: newTop});\n GRID.header.scrollTo.call(this, { left: newLeft });\n GRID.body.scrollTo.call(this, { left: newLeft, top: newTop });\n resize.call(this);\n\n return !_top_is_end || !_left_is_end;\n },\n \"on\": function on() {\n var self = this,\n _body_scroll_position = self.$[\"panel\"][\"body-scroll\"].position(),\n _panel_height = self.$[\"panel\"][\"body\"].height(),\n _panel_width = self.$[\"panel\"][\"body\"].width(),\n _content_height = self.xvar.scrollContentHeight,\n _content_width = self.xvar.scrollContentWidth,\n getContentPosition = function getContentPosition(e) {\n var mouseObj = GRID.util.getMousePosition(e),\n newLeft = void 0,\n newTop = void 0;\n\n self.xvar.__x_da = mouseObj.clientX - self.xvar.mousePosition.clientX;\n self.xvar.__y_da = mouseObj.clientY - self.xvar.mousePosition.clientY;\n\n newLeft = _body_scroll_position.left + self.xvar.__x_da;\n newTop = _body_scroll_position.top + self.xvar.__y_da;\n\n // newTop이 범위를 넘었는지 체크\n if (newTop >= 0) {\n newTop = 0;\n } else if (newTop <= _panel_height - _content_height) {\n newTop = _panel_height - _content_height;\n if (newTop >= 0) newTop = 0;\n }\n\n // newLeft이 범위를 넘었는지 체크\n if (newLeft >= 0) {\n newLeft = 0;\n } else if (newLeft <= _panel_width - _content_width) {\n newLeft = _panel_width - _content_width;\n if (newLeft >= 0) newLeft = 0;\n }\n\n return {\n left: newLeft, top: newTop\n };\n };\n\n this.xvar.__x_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n this.xvar.__y_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n this.xvar.touchmoved = false;\n\n jQuery(document.body).on(\"touchmove\" + \".ax5grid-\" + this.instanceId, function (e) {\n\n var css = getContentPosition(e);\n GRID.header.scrollTo.call(self, { left: css.left });\n GRID.body.scrollTo.call(self, css, \"noRepaint\");\n resize.call(self);\n U.stopEvent(e);\n self.xvar.touchmoved = true;\n }).on(\"touchend\" + \".ax5grid-\" + this.instanceId, function (e) {\n if (self.xvar.touchmoved) {\n var css = getContentPosition(e);\n GRID.header.scrollTo.call(self, { left: css.left });\n GRID.body.scrollTo.call(self, css);\n resize.call(self);\n U.stopEvent(e);\n scrollContentMover.off.call(self);\n }\n });\n\n jQuery(document.body).attr('unselectable', 'on').css('user-select', 'none').on('selectstart', false);\n },\n \"off\": function off() {\n\n jQuery(document.body).off(\"touchmove\" + \".ax5grid-\" + this.instanceId).off(\"touchend\" + \".ax5grid-\" + this.instanceId);\n\n jQuery(document.body).removeAttr('unselectable').css('user-select', 'auto').off('selectstart');\n }\n };\n\n var init = function init() {\n var self = this,\n margin = this.config.scroller.trackPadding;\n\n this.$[\"scroller\"][\"vertical-bar\"].css({ width: this.config.scroller.size - (margin + 1), left: margin / 2 });\n this.$[\"scroller\"][\"horizontal-bar\"].css({ height: this.config.scroller.size - (margin + 1), top: margin / 2 });\n\n this.$[\"scroller\"][\"vertical-bar\"].on(GRID.util.ENM[\"mousedown\"], function (e) {\n this.xvar.mousePosition = GRID.util.getMousePosition(e);\n scrollBarMover.on.call(this, this.$[\"scroller\"][\"vertical\"], this.$[\"scroller\"][\"vertical-bar\"], \"vertical\", e);\n }.bind(this)).on(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n this.$[\"scroller\"][\"vertical\"].on(\"click\", function (e) {\n if (e.target.getAttribute(\"data-ax5grid-scroller\") == \"vertical\") {\n scrollBarMover.click.call(this, this.$[\"scroller\"][\"vertical\"], this.$[\"scroller\"][\"vertical-bar\"], \"vertical\", e);\n }\n }.bind(this));\n\n this.$[\"scroller\"][\"horizontal-bar\"].on(GRID.util.ENM[\"mousedown\"], function (e) {\n this.xvar.mousePosition = GRID.util.getMousePosition(e);\n scrollBarMover.on.call(this, this.$[\"scroller\"][\"horizontal\"], this.$[\"scroller\"][\"horizontal-bar\"], \"horizontal\", e);\n }.bind(this)).on(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n this.$[\"scroller\"][\"horizontal\"].on(\"click\", function (e) {\n if (e.target.getAttribute(\"data-ax5grid-scroller\") == \"horizontal\") {\n scrollBarMover.click.call(this, this.$[\"scroller\"][\"horizontal\"], this.$[\"scroller\"][\"horizontal-bar\"], \"horizontal\", e);\n }\n }.bind(this));\n\n this.$[\"container\"][\"body\"].on('mousewheel DOMMouseScroll', function (e) {\n var E = e.originalEvent,\n delta = { x: 0, y: 0 };\n\n if (E.detail) {\n delta.y = E.detail * 10;\n } else {\n if (typeof E.deltaY === \"undefined\") {\n delta.y = -E.wheelDelta;\n delta.x = 0;\n } else {\n delta.y = E.deltaY;\n delta.x = E.deltaX;\n }\n }\n\n if (scrollContentMover.wheel.call(this, delta)) {\n U.stopEvent(e);\n }\n }.bind(this));\n\n if (document.addEventListener && ax5.info.supportTouch) {\n this.$[\"container\"][\"body\"].on(\"touchstart\", '[data-ax5grid-panel]', function (e) {\n self.xvar.mousePosition = GRID.util.getMousePosition(e);\n scrollContentMover.on.call(self);\n });\n }\n };\n\n var resize = function resize() {\n var _vertical_scroller_height = this.$[\"scroller\"][\"vertical\"].height(),\n _horizontal_scroller_width = this.$[\"scroller\"][\"horizontal\"].width(),\n _panel_height = this.$[\"panel\"][\"body\"].height(),\n _panel_width = this.$[\"panel\"][\"body\"].width(),\n _content_height = this.xvar.scrollContentHeight,\n _content_width = this.xvar.scrollContentWidth,\n verticalScrollBarHeight = _panel_height * _vertical_scroller_height / _content_height,\n horizontalScrollBarWidth = _panel_width * _horizontal_scroller_width / _content_width;\n\n if (verticalScrollBarHeight < this.config.scroller.barMinSize) verticalScrollBarHeight = this.config.scroller.barMinSize;\n if (horizontalScrollBarWidth < this.config.scroller.barMinSize) horizontalScrollBarWidth = this.config.scroller.barMinSize;\n\n this.$[\"scroller\"][\"vertical-bar\"].css({\n top: convertScrollBarPosition.vertical.call(this, this.$.panel[\"body-scroll\"].position().top, {\n _content_width: _content_width,\n _content_height: _content_height,\n _panel_width: _panel_width,\n _panel_height: _panel_height,\n _horizontal_scroller_width: _horizontal_scroller_width,\n _vertical_scroller_height: _vertical_scroller_height,\n verticalScrollBarHeight: verticalScrollBarHeight,\n horizontalScrollBarWidth: horizontalScrollBarWidth\n }),\n height: verticalScrollBarHeight\n });\n\n //console.log(horizontalScrollBarWidth);\n\n this.$[\"scroller\"][\"horizontal-bar\"].css({\n left: convertScrollBarPosition.horizontal.call(this, this.$.panel[\"body-scroll\"].position().left, {\n _content_width: _content_width,\n _content_height: _content_height,\n _panel_width: _panel_width,\n _panel_height: _panel_height,\n _horizontal_scroller_width: _horizontal_scroller_width,\n _vertical_scroller_height: _vertical_scroller_height,\n verticalScrollBarHeight: verticalScrollBarHeight,\n horizontalScrollBarWidth: horizontalScrollBarWidth\n }),\n width: horizontalScrollBarWidth\n });\n\n _vertical_scroller_height = null;\n _horizontal_scroller_width = null;\n _panel_height = null;\n _panel_width = null;\n _content_height = null;\n _content_width = null;\n verticalScrollBarHeight = null;\n horizontalScrollBarWidth = null;\n };\n\n GRID.scroller = {\n // 타이머\n moveout_timer: new Date().getTime(),\n init: init,\n resize: resize\n };\n})();\n// ax5.ui.grid.tmpl\n(function () {\n\n var GRID = ax5.ui.grid;\n var main = function main() {\n return '
\\n
\\n \\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
\\n
';\n };\n\n var page_navigation = function page_navigation() {\n return '
\\n {{#hasPage}}\\n
\\n {{#firstIcon}}{{/firstIcon}}\\n \\n
\\n
\\n {{#@paging}}\\n \\n {{/@paging}}\\n
\\n
\\n \\n {{#lastIcon}}{{/lastIcon}}\\n
\\n {{/hasPage}}\\n
';\n };\n\n var page_status = function page_status() {\n return '
{{fromRowIndex}} - {{toRowIndex}} of {{totalElements}}{{#dataRowCount}} ({{dataRowCount}}){{/dataRowCount}}';\n };\n\n GRID.tmpl = {\n \"main\": main,\n \"page_navigation\": page_navigation,\n \"page_status\": page_status,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(GRID.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.grid.util\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n /**\n * @method ax5grid.util.divideTableByFrozenColumnIndex\n * @param _table\n * @param _frozenColumnIndex\n * @returns {{leftHeaderData: {rows: Array}, headerData: {rows: Array}}}\n */\n\n var divideTableByFrozenColumnIndex = function divideTableByFrozenColumnIndex(_table, _frozenColumnIndex) {\n var tempTable_l = { rows: [] };\n var tempTable_r = { rows: [] };\n for (var r = 0, rl = _table.rows.length; r < rl; r++) {\n var row = _table.rows[r];\n\n tempTable_l.rows[r] = { cols: [] };\n tempTable_r.rows[r] = { cols: [] };\n\n for (var c = 0, cl = row.cols.length; c < cl; c++) {\n var col = jQuery.extend({}, row.cols[c]);\n var colStartIndex = col.colIndex,\n colEndIndex = col.colIndex + col.colspan;\n\n if (colStartIndex < _frozenColumnIndex) {\n if (colEndIndex <= _frozenColumnIndex) {\n // 좌측편에 변형없이 추가\n tempTable_l.rows[r].cols.push(col);\n } else {\n var leftCol = jQuery.extend({}, col);\n var rightCol = jQuery.extend({}, leftCol);\n leftCol.colspan = _frozenColumnIndex - leftCol.colIndex;\n rightCol.colIndex = _frozenColumnIndex;\n rightCol.colspan = col.colspan - leftCol.colspan;\n\n tempTable_l.rows[r].cols.push(leftCol);\n tempTable_r.rows[r].cols.push(rightCol);\n }\n } else {\n // 오른편\n tempTable_r.rows[r].cols.push(col);\n }\n }\n }\n\n return {\n leftData: tempTable_l,\n rightData: tempTable_r\n };\n };\n\n var getMousePosition = function getMousePosition(e) {\n var mouseObj,\n originalEvent = e.originalEvent ? e.originalEvent : e;\n mouseObj = 'changedTouches' in originalEvent ? originalEvent.changedTouches[0] : originalEvent;\n // clientX, Y 쓰면 스크롤에서 문제 발생\n return {\n clientX: mouseObj.pageX,\n clientY: mouseObj.pageY\n };\n };\n\n var ENM = {\n \"mousedown\": ax5.info.supportTouch ? \"touchstart\" : \"mousedown\",\n \"mousemove\": ax5.info.supportTouch ? \"touchmove\" : \"mousemove\",\n \"mouseup\": ax5.info.supportTouch ? \"touchend\" : \"mouseup\"\n };\n\n var makeHeaderTable = function makeHeaderTable(_columns) {\n var columns = U.deepCopy(_columns);\n var cfg = this.config;\n var table = {\n rows: []\n };\n var colIndex = 0;\n var maekRows = function maekRows(_columns, depth, parentField) {\n var row = { cols: [] };\n var i = 0,\n l = _columns.length;\n\n for (; i < l; i++) {\n var field = _columns[i];\n var colspan = 1;\n\n if (!field.hidden) {\n field.colspan = 1;\n field.rowspan = 1;\n\n field.rowIndex = depth;\n field.colIndex = function () {\n if (!parentField) {\n return colIndex++;\n } else {\n colIndex = parentField.colIndex + i + 1;\n return parentField.colIndex + i;\n }\n }();\n\n row.cols.push(field);\n\n if ('columns' in field) {\n colspan = maekRows(field.columns, depth + 1, field);\n } else {\n field.width = 'width' in field ? field.width : cfg.columnMinWidth;\n }\n field.colspan = colspan;\n } else {}\n }\n\n if (row.cols.length > 0) {\n if (!table.rows[depth]) {\n table.rows[depth] = { cols: [] };\n }\n table.rows[depth].cols = table.rows[depth].cols.concat(row.cols);\n return row.cols.length - 1 + colspan;\n } else {\n return colspan;\n }\n };\n maekRows(columns, 0);\n\n // set rowspan\n for (var r = 0, rl = table.rows.length; r < rl; r++) {\n for (var c = 0, cl = table.rows[r].cols.length; c < cl; c++) {\n if (!('columns' in table.rows[r].cols[c])) {\n table.rows[r].cols[c].rowspan = rl - r;\n }\n }\n }\n\n return table;\n };\n\n var makeBodyRowTable = function makeBodyRowTable(_columns) {\n var columns = U.deepCopy(_columns);\n var table = {\n rows: []\n };\n var colIndex = 0;\n var maekRows = function maekRows(_columns, depth, parentField) {\n var row = { cols: [] };\n var i = 0,\n l = _columns.length;\n\n var selfMakeRow = function selfMakeRow(__columns) {\n var i = 0,\n l = __columns.length;\n for (; i < l; i++) {\n var field = __columns[i];\n var colspan = 1;\n\n if (!field.hidden) {\n\n if ('key' in field) {\n field.colspan = 1;\n field.rowspan = 1;\n\n field.rowIndex = depth;\n field.colIndex = function () {\n if (!parentField) {\n return colIndex++;\n } else {\n colIndex = parentField.colIndex + i + 1;\n return parentField.colIndex + i;\n }\n }();\n\n row.cols.push(field);\n if ('columns' in field) {\n colspan = maekRows(field.columns, depth + 1, field);\n }\n field.colspan = colspan;\n } else {\n if ('columns' in field) {\n selfMakeRow(field.columns, depth);\n }\n }\n } else {}\n }\n };\n\n for (; i < l; i++) {\n var field = _columns[i];\n var colspan = 1;\n\n if (!field.hidden) {\n\n if ('key' in field) {\n field.colspan = 1;\n field.rowspan = 1;\n\n field.rowIndex = depth;\n field.colIndex = function () {\n if (!parentField) {\n return colIndex++;\n } else {\n colIndex = parentField.colIndex + i + 1;\n return parentField.colIndex + i;\n }\n }();\n\n row.cols.push(field);\n if ('columns' in field) {\n colspan = maekRows(field.columns, depth + 1, field);\n }\n field.colspan = colspan;\n } else {\n if ('columns' in field) {\n selfMakeRow(field.columns, depth);\n }\n }\n } else {}\n }\n\n if (row.cols.length > 0) {\n if (!table.rows[depth]) {\n table.rows[depth] = { cols: [] };\n }\n table.rows[depth].cols = table.rows[depth].cols.concat(row.cols);\n return row.cols.length - 1 + colspan;\n } else {\n return colspan;\n }\n };\n maekRows(columns, 0);\n\n (function (table) {\n // set rowspan\n for (var r = 0, rl = table.rows.length; r < rl; r++) {\n var row = table.rows[r];\n for (var c = 0, cl = row.cols.length; c < cl; c++) {\n var col = row.cols[c];\n if (!('columns' in col)) {\n col.rowspan = rl - r;\n }\n }\n }\n })(table);\n\n return table;\n };\n\n var makeBodyRowMap = function makeBodyRowMap(_table) {\n var map = {};\n _table.rows.forEach(function (row) {\n row.cols.forEach(function (col) {\n map[col.rowIndex + \"_\" + col.colIndex] = jQuery.extend({}, col);\n });\n });\n return map;\n };\n\n var makeFootSumTable = function makeFootSumTable(_footSumColumns) {\n var table = {\n rows: []\n };\n\n for (var r = 0, rl = _footSumColumns.length; r < rl; r++) {\n var footSumRow = _footSumColumns[r];\n table.rows[r] = { cols: [] };\n var addC = 0;\n for (var c = 0, cl = footSumRow.length; c < cl; c++) {\n if (addC > this.columns.length) break;\n var colspan = footSumRow[c].colspan || 1;\n if (footSumRow[c].label || footSumRow[c].key) {\n table.rows[r].cols.push({\n colspan: colspan,\n rowspan: 1,\n colIndex: addC,\n columnAttr: \"sum\",\n align: footSumRow[c].align,\n label: footSumRow[c].label,\n key: footSumRow[c].key,\n collector: footSumRow[c].collector,\n formatter: footSumRow[c].formatter\n });\n } else {\n table.rows[r].cols.push({\n colIndex: addC,\n colspan: colspan,\n rowspan: 1,\n label: \" \"\n });\n }\n addC += colspan;\n }\n\n if (addC < this.columns.length + 1) {\n for (var c = addC; c < this.colGroup.length; c++) {\n table.rows[r].cols.push({\n colIndex: c + 1,\n colspan: 1,\n rowspan: 1,\n label: \" \"\n });\n }\n }\n }\n return table;\n };\n\n var makeBodyGroupingTable = function makeBodyGroupingTable(_bodyGroupingColumns) {\n var table = {\n rows: []\n };\n\n var r = 0;\n table.rows[r] = { cols: [] };\n var addC = 0;\n for (var c = 0, cl = _bodyGroupingColumns.length; c < cl; c++) {\n if (addC > this.columns.length) break;\n var colspan = _bodyGroupingColumns[c].colspan || 1;\n if (_bodyGroupingColumns[c].label || _bodyGroupingColumns[c].key) {\n table.rows[r].cols.push({\n colspan: colspan,\n rowspan: 1,\n rowIndex: 0,\n colIndex: addC,\n columnAttr: \"default\",\n align: _bodyGroupingColumns[c].align,\n label: _bodyGroupingColumns[c].label,\n key: _bodyGroupingColumns[c].key,\n collector: _bodyGroupingColumns[c].collector,\n formatter: _bodyGroupingColumns[c].formatter\n });\n } else {\n table.rows[r].cols.push({\n rowIndex: 0,\n colIndex: addC,\n colspan: colspan,\n rowspan: 1,\n label: \" \"\n });\n }\n addC += colspan;\n }\n\n if (addC < this.colGroup.length) {\n for (var c = addC; c < this.colGroup.length; c++) {\n table.rows[r].cols.push({\n rowIndex: 0,\n colIndex: c + 1,\n colspan: 1,\n rowspan: 1,\n label: \" \"\n });\n }\n }\n\n return table;\n };\n\n var findPanelByColumnIndex = function findPanelByColumnIndex(_dindex, _colIndex, _rowIndex) {\n var _containerPanelName;\n var _isScrollPanel = false;\n var _panels = [];\n\n if (this.xvar.frozenRowIndex > _dindex) _panels.push(\"top\");\n if (this.xvar.frozenColumnIndex > _colIndex) _panels.push(\"left\");\n _panels.push(\"body\");\n\n if (this.xvar.frozenColumnIndex <= _colIndex || this.xvar.frozenRowIndex <= _dindex) {\n _containerPanelName = _panels.join(\"-\");\n _panels.push(\"scroll\");\n _isScrollPanel = true;\n }\n\n return {\n panelName: _panels.join(\"-\"),\n containerPanelName: _containerPanelName,\n isScrollPanel: _isScrollPanel\n };\n };\n\n var getRealPathForDataItem = function getRealPathForDataItem(_dataPath) {\n var path = [];\n var _path = [].concat(_dataPath.split(/[\\.\\[\\]]/g));\n _path.forEach(function (n) {\n if (n !== \"\") path.push(\"[\\\"\" + n.replace(/['\\\"]/g, \"\") + \"\\\"]\");\n });\n _path = null;\n return path.join(\"\");\n };\n\n GRID.util = {\n divideTableByFrozenColumnIndex: divideTableByFrozenColumnIndex,\n getMousePosition: getMousePosition,\n ENM: ENM,\n makeHeaderTable: makeHeaderTable,\n makeBodyRowTable: makeBodyRowTable,\n makeBodyRowMap: makeBodyRowMap,\n makeFootSumTable: makeFootSumTable,\n makeBodyGroupingTable: makeBodyGroupingTable,\n findPanelByColumnIndex: findPanelByColumnIndex,\n getRealPathForDataItem: getRealPathForDataItem\n };\n})();\n// ax5.ui.mediaViewer\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var MEDIAVIEWER;\n\n UI.addClass({\n className: \"mediaViewer\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5mediaViewer\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var myViewer = new ax5.ui.mediaViewer({\n * theme: \"danger\",\n * target: $(\"#media-viewer-target-0\"),\n * loading: {\n * icon: '
',\n * text: '
Now Loading
'\n * },\n * media: {\n * width: '11%', height: '11%',\n * prevHandle: '
',\n * nextHandle: '
',\n * poster: '
',\n * list: [\n * {\n * video: {\n * html: '
',\n * poster: ''\n * }\n * },\n * {\n * video: {\n * html: '
',\n * poster: ''\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'https://www.twilio.com/blog/wp-content/uploads/2013/11/Screen-Shot-2013-11-06-at-12.05.36-PM.png',\n * poster: 'https://www.twilio.com/blog/wp-content/uploads/2013/11/Screen-Shot-2013-11-06-at-12.05.36-PM.png'\n * }\n * }\n * ]\n * },\n * onClick: function () {\n * console.log(this);\n * }\n * });\n * ```\n */\n var ax5mediaViewer = function ax5mediaViewer() {\n var self = this,\n cfg,\n ENM = {\n \"mousedown\": ax5.info.supportTouch ? \"touchstart\" : \"mousedown\",\n \"mousemove\": ax5.info.supportTouch ? \"touchmove\" : \"mousemove\",\n \"mouseup\": ax5.info.supportTouch ? \"touchend\" : \"mouseup\"\n },\n getMousePosition = function getMousePosition(e) {\n var mouseObj = 'changedTouches' in e.originalEvent ? e.originalEvent.changedTouches[0] : e;\n\n return {\n clientX: mouseObj.clientX,\n clientY: mouseObj.clientY,\n time: new Date().getTime()\n };\n };\n\n this.instanceId = ax5.getGuid();\n this.config = {\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchend\" : \"click\"),\n theme: 'default',\n animateTime: 250,\n\n columnKeys: {\n src: 'src',\n poster: 'poster',\n html: 'html'\n },\n loading: {\n icon: '',\n text: 'Now Loading'\n },\n viewer: {\n prevHandle: false,\n nextHandle: false,\n ratio: 16 / 9\n },\n media: {\n prevHandle: '<',\n nextHandle: '>',\n width: 36, height: 36,\n list: []\n }\n };\n this.queue = [];\n this.openTimer = null;\n this.closeTimer = null;\n this.selectedIndex = 0;\n this.mousePosition = {};\n\n cfg = this.config;\n\n var onStateChanged = function onStateChanged(opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n return true;\n },\n getFrame = function getFrame() {\n var data = jQuery.extend(true, { id: this.id }, cfg);\n\n try {\n return MEDIAVIEWER.tmpl.get.call(this, \"frame\", data, cfg.columnKeys);\n } finally {\n data = null;\n }\n },\n onClick = function onClick(e, target) {\n var result,\n elementType = \"\",\n processor = {\n 'thumbnail': function thumbnail(target) {\n this.select(target.getAttribute(\"data-media-thumbnail\"));\n },\n 'prev': function prev(target) {\n if (this.selectedIndex > 0) {\n this.select(this.selectedIndex - 1);\n } else {\n this.select(cfg.media.list.length - 1);\n }\n },\n 'next': function next(target) {\n if (this.selectedIndex < cfg.media.list.length - 1) {\n this.select(this.selectedIndex + 1);\n } else {\n this.select(0);\n }\n },\n 'viewer': function viewer(target) {\n if (self.onClick) {\n self.onClick.call({\n media: cfg.media.list[this.selectedIndex]\n });\n }\n }\n };\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-media-thumbnail\")) {\n elementType = \"thumbnail\";\n return true;\n } else if (target.getAttribute(\"data-media-viewer-els\") == \"media-list-prev-handle\") {\n elementType = \"prev\";\n return true;\n } else if (target.getAttribute(\"data-media-viewer-els\") == \"media-list-next-handle\") {\n elementType = \"next\";\n return true;\n } else if (target.getAttribute(\"data-media-viewer-els\") == \"viewer\") {\n elementType = \"viewer\";\n return true;\n } else if (self.target.get(0) == target) {\n return true;\n }\n });\n\n if (target) {\n for (var key in processor) {\n if (key == elementType) {\n result = processor[key].call(this, target);\n break;\n }\n }\n return this;\n }\n return this;\n },\n getSelectedIndex = function getSelectedIndex() {\n if (cfg.media && cfg.media.list && cfg.media.list.length > 0) {\n var i = cfg.media.list.length,\n selecteIndex = 0;\n while (i--) {\n if (cfg.media.list[i].selected) {\n selecteIndex = i;\n break;\n }\n }\n\n if (selecteIndex == 0) {\n cfg.media.list[0].selected = true;\n }\n try {\n return selecteIndex;\n } finally {\n i = null;\n selecteIndex = null;\n }\n } else {\n return;\n }\n },\n alignMediaList = function alignMediaList() {\n var thumbnail = this.$[\"list\"].find('[data-media-thumbnail=' + this.selectedIndex + ']'),\n pos = thumbnail.position(),\n thumbnailWidth = thumbnail.outerWidth(),\n containerWidth = this.$[\"list\"].outerWidth(),\n parentLeft = this.$[\"list-table\"].position().left,\n parentWidth = this.$[\"list-table\"].outerWidth(),\n newLeft = 0;\n\n if (pos.left + thumbnailWidth + parentLeft > containerWidth) {\n newLeft = containerWidth - (pos.left + thumbnailWidth);\n if (parentLeft != newLeft) this.$[\"list-table\"].css({ left: parentLeft = newLeft });\n } else if (pos.left + parentLeft < 0) {\n newLeft = pos.left;\n if (newLeft > 0) newLeft = 0;\n if (parentLeft != newLeft) this.$[\"list-table\"].css({ left: parentLeft = newLeft });\n }\n\n if (parentLeft != newLeft) {\n if (parentLeft + parentWidth < containerWidth) {\n newLeft = containerWidth - parentWidth;\n if (newLeft > 0) newLeft = 0;\n this.$[\"list-table\"].css({ left: newLeft });\n }\n }\n\n thumbnail = null;\n pos = null;\n thumbnailWidth = null;\n containerWidth = null;\n parentLeft = null;\n newLeft = null;\n },\n swipeMedia = {\n \"on\": function on(mousePosition) {\n // console.log(mousePosition);\n var getSwipePosition = function getSwipePosition(e) {\n var mouseObj = e;\n if ('changedTouches' in e.originalEvent) {\n mouseObj = e.originalEvent.changedTouches[0];\n }\n\n mousePosition.__dx = mouseObj.clientX - mousePosition.clientX;\n mousePosition.__dy = mouseObj.clientY - mousePosition.clientY;\n mousePosition.__time = new Date().getTime();\n\n if (Math.abs(mousePosition.__dx) > Math.abs(mousePosition.__dy)) {\n return { left: mousePosition.__dx };\n } else {\n return { top: mousePosition.__dy };\n }\n };\n var viewerWidth = this.$[\"viewer\"].width();\n\n jQuery(document.body).bind(ENM[\"mousemove\"] + \".ax5media-viewer-\" + this.instanceId, function (e) {\n var position = getSwipePosition(e);\n\n if ('left' in position) {\n self.$[\"viewer-holder\"].css(position);\n if (Math.abs(self.mousePosition.__dx) > viewerWidth / 3) {\n //console.log(self.mousePosition);\n // trigger nextMedia\n\n var nextIndex = 0;\n\n if (self.mousePosition.__dx > 0) {\n if (self.selectedIndex > 0) {\n nextIndex = self.selectedIndex - 1;\n } else {\n nextIndex = cfg.media.list.length - 1;\n }\n } else {\n if (self.selectedIndex < cfg.media.list.length - 1) {\n nextIndex = self.selectedIndex + 1;\n }\n }\n\n self.select(nextIndex);\n swipeMedia.off.call(self);\n }\n\n U.stopEvent(e);\n }\n }).bind(ENM[\"mouseup\"] + \".ax5media-viewer-\" + this.instanceId, function (e) {\n swipeMedia.off.call(self);\n }).bind(\"mouseleave.ax5media-viewer-\" + this.instanceId, function (e) {\n swipeMedia.off.call(self);\n });\n\n jQuery(document.body).attr('unselectable', 'on').css('user-select', 'none').on('selectstart', false);\n },\n \"off\": function off() {\n self.$[\"viewer-holder\"].css({ left: 0 });\n jQuery(document.body).unbind(ENM[\"mousemove\"] + \".ax5media-viewer-\" + this.instanceId).unbind(ENM[\"mouseup\"] + \".ax5media-viewer-\" + this.instanceId).unbind(\"mouseleave.ax5media-viewer-\" + this.instanceId);\n\n jQuery(document.body).removeAttr('unselectable').css('user-select', 'auto').off('selectstart');\n }\n };\n /// private end\n\n /**\n * Preferences of mediaViewer UI\n * @method ax5mediaViewer.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5mediaViewer}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n this.id = 'ax5-media-viewer-' + ax5.getGuid();\n if (cfg.target && cfg.media && cfg.media.list && cfg.media.list.length > 0) {\n this.attach(cfg.target);\n }\n };\n\n /**\n * @method ax5mediaViewer.attach\n * @param target\n * @param options\n * @returns {ax5mediaViewer}\n */\n this.attach = function (target, options) {\n if (!target) {\n console.log(ax5.info.getError(\"ax5mediaViewer\", \"401\", \"setConfig\"));\n }\n if (typeof options != \"undefined\") {\n this.setConfig(options, false);\n }\n this.target = jQuery(target);\n this.target.html(getFrame.call(this));\n\n // 파트수집\n this.$ = {\n \"root\": this.target.find('[data-ax5-ui-media-viewer]'),\n \"viewer-holder\": this.target.find('[data-media-viewer-els=\"viewer-holder\"]'),\n \"viewer\": this.target.find('[data-media-viewer-els=\"viewer\"]'),\n \"viewer-loading\": this.target.find('[data-media-viewer-els=\"viewer-loading\"]'),\n \"list-holder\": this.target.find('[data-media-viewer-els=\"media-list-holder\"]'),\n \"list-prev-handle\": this.target.find('[data-media-viewer-els=\"media-list-prev-handle\"]'),\n \"list\": this.target.find('[data-media-viewer-els=\"media-list\"]'),\n \"list-table\": this.target.find('[data-media-viewer-els=\"media-list-table\"]'),\n \"list-next-handle\": this.target.find('[data-media-viewer-els=\"media-list-next-handle\"]')\n };\n\n this.align();\n\n jQuery(window).unbind(\"resize.ax5media-viewer-\" + this.id).bind(\"resize.ax5media-viewer-\" + this.id, function () {\n this.align();\n alignMediaList.call(this);\n }.bind(this));\n\n this.target.unbind(\"click\").bind(\"click\", function (e) {\n e = e || window.event;\n onClick.call(this, e);\n U.stopEvent(e);\n }.bind(this));\n\n this.$.viewer.unbind(ENM[\"mousedown\"]).bind(ENM[\"mousedown\"], function (e) {\n this.mousePosition = getMousePosition(e);\n swipeMedia.on.call(this, this.mousePosition);\n }.bind(this)).unbind(\"dragstart\").bind(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n this.select(getSelectedIndex.call(this));\n return this;\n };\n\n /**\n * @method ax5mediaViewer.align\n * @returns {ax5mediaViewer}\n */\n this.align = function () {\n // viewer width, height\n this.$[\"viewer-holder\"].css({ height: this.$[\"viewer\"].width() / cfg.viewer.ratio });\n this.$[\"viewer\"].css({ height: this.$[\"viewer\"].width() / cfg.viewer.ratio });\n\n if (this.$[\"viewer\"].data(\"media-type\") == \"image\") {\n var $img = this.$[\"viewer\"].find(\"img\");\n $img.css({\n width: this.$[\"viewer\"].height() * this.$[\"viewer\"].data(\"img-ratio\"), height: this.$[\"viewer\"].height()\n });\n setTimeout(function (_img) {\n _img.css({ left: (this.$[\"viewer\"].width() - _img.width()) / 2 });\n }.bind(this, $img), 1);\n } else if (this.$[\"viewer\"].data(\"media-type\") == \"video\") {\n this.$[\"viewer\"].find(\"iframe\").css({ width: this.$[\"viewer\"].height() * this.$[\"viewer\"].data(\"img-ratio\"), height: this.$[\"viewer\"].height() });\n }\n this.$[\"viewer-loading\"].css({ height: this.$[\"viewer\"].height() });\n\n var mediaThumbnailWidth = U.right(cfg.media.width, 1) == '%' ? U.number(cfg.media.width) / 100 * this.$[\"viewer\"].width() : U.number(cfg.media.width),\n mediaThumbnailHeight = U.right(cfg.media.height, 1) == '%' ? U.number(cfg.media.height) / 100 * this.$[\"viewer\"].width() : U.number(cfg.media.height);\n\n mediaThumbnailWidth = Math.floor(mediaThumbnailWidth);\n mediaThumbnailHeight = Math.floor(mediaThumbnailHeight);\n\n this.$[\"list-prev-handle\"].css({ width: mediaThumbnailWidth * 1.5 });\n this.$[\"list-next-handle\"].css({ width: mediaThumbnailWidth * 1.5 });\n this.$[\"list\"].css({ height: mediaThumbnailHeight });\n this.$[\"list-table\"].find('[data-media-thumbnail]').css({ width: mediaThumbnailWidth, height: mediaThumbnailHeight });\n this.$[\"list-table\"].find('[data-media-thumbnail-video]').css({ width: mediaThumbnailWidth, height: mediaThumbnailHeight });\n\n return this;\n };\n\n /**\n * @method ax5mediaViewer.select\n * @param index\n * @returns {ax5mediaViewer}\n */\n this.select = function () {\n var mediaView = {\n image: function image(obj, callback) {\n self.$[\"viewer-loading\"].show();\n var dim = [this.$[\"viewer\"].width(), this.$[\"viewer\"].height()];\n var img = new Image();\n img.src = obj.image[cfg.columnKeys.src];\n img.onload = function () {\n self.$[\"viewer-loading\"].fadeOut();\n var h = dim[1];\n var w = h * img.width / img.height;\n callback(img, Math.floor(w), h);\n };\n return img;\n },\n video: function video(obj, callback) {\n self.$[\"viewer-loading\"].show();\n var dim = [this.$[\"viewer\"].width(), this.$[\"viewer\"].height()];\n var html = jQuery(obj.video[cfg.columnKeys.html]);\n callback(html, dim[0], dim[1]);\n self.$[\"viewer-loading\"].fadeOut();\n }\n };\n var onLoad = {\n image: function image(img, w, h) {\n img.width = w;\n img.height = h;\n\n var $img = $(img);\n this.$[\"viewer\"].html($img);\n $img.css({ left: (this.$[\"viewer\"].width() - w) / 2 });\n\n this.$[\"viewer\"].data(\"media-type\", \"image\");\n this.$[\"viewer\"].data(\"img-ratio\", w / h);\n },\n video: function video(html, w, h) {\n html.css({ width: w, height: h });\n this.$[\"viewer\"].html(html);\n this.$[\"viewer\"].data(\"media-type\", \"video\");\n this.$[\"viewer\"].data(\"img-ratio\", w / h);\n }\n };\n var select = function select(index) {\n this.$[\"list\"].find('[data-media-thumbnail]').removeClass(\"selected\");\n this.$[\"list\"].find('[data-media-thumbnail=' + index + ']').addClass(\"selected\");\n alignMediaList.call(this);\n };\n\n return function (index) {\n if (typeof index === \"undefined\") return this;\n this.selectedIndex = Number(index);\n var media = cfg.media.list[index];\n select.call(this, index);\n\n for (var key in mediaView) {\n if (media[key]) {\n mediaView[key].call(this, media, onLoad[key].bind(this));\n break;\n }\n }\n return this;\n };\n }();\n\n /**\n * @method ax5mediaViewer.setMediaList\n * @param list\n * @returns {ax5mediaViewer}\n */\n this.setMediaList = function (list) {\n cfg.media.list = [].concat(list);\n this.attach(cfg.target);\n return this;\n };\n\n // 클래스 생성자\n this.main = function () {\n\n UI.mediaViewer_instance = UI.mediaViewer_instance || [];\n UI.mediaViewer_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n } else {\n this.init();\n }\n }.apply(this, arguments);\n };\n return ax5mediaViewer;\n }());\n\n MEDIAVIEWER = ax5.ui.mediaViewer;\n})();\n// ax5.ui.mediaViewer.tmpl\n(function () {\n var MEDIAVIEWER = ax5.ui.mediaViewer;\n\n var frame = function frame(columnKeys) {\n return '\\n
\\n
\\n
\\n {{#media}}\\n
\\n
{{{prevHandle}}}
\\n
\\n
\\n {{#list}}\\n
\\n {{#image}}\\n
\\n
\\n
\\n {{/image}}\\n {{#video}}\\n
\\n {{/video}}\\n
\\n {{/list}}\\n
\\n
\\n
{{{nextHandle}}}
\\n
\\n {{/media}}\\n
\\n ';\n };\n\n MEDIAVIEWER.tmpl = {\n \"frame\": frame,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(MEDIAVIEWER.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.uploader\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var UPLOADER = void 0;\n\n UI.addClass({\n className: \"uploader\",\n version: \"1.3.66\"\n }, function () {\n\n var ax5uploader = function ax5uploader() {\n /**\n * @class ax5uploader\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n *\n * ```\n */\n var self = this,\n cfg = void 0;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchend\" : \"click\"),\n theme: 'default', // theme of uploader\n lang: { // 업로더 버튼 랭귀지 설정\n \"upload\": \"Upload\",\n \"abort\": \"Abort\"\n },\n uploadedBox: {\n columnKeys: {\n name: \"name\",\n type: \"type\",\n size: \"size\",\n uploadedName: \"uploadedName\",\n uploadedPath: \"uploadedPath\",\n downloadPath: \"downloadPath\",\n previewPath: \"previewPath\",\n thumbnail: \"thumbnail\"\n }\n },\n animateTime: 100,\n accept: \"*/*\", // 업로드 선택 파일 타입 설정\n multiple: false, // 다중 파일 업로드\n manualUpload: false, // 업로딩 시작 수동처리 여부\n progressBox: true // 업로드 프로그래스 박스 사용여부 false 이면 업로드 진행바를 표시 하지 않습니다. 개발자가 onprogress 함수를 이용하여 직접 구현 해야 합니다.\n };\n this.defaultBtns = {\n \"upload\": { label: this.config.lang[\"upload\"], theme: \"btn-primary\" },\n \"abort\": { label: this.config.lang[\"abort\"], theme: this.config.theme }\n };\n\n /// 업로드된 파일 큐\n this.uploadedFiles = [];\n /// 업로더 타겟\n this.$target = null;\n /// 업로드된 파일 정보들의 input 태그를 담아두는 컨테이너\n this.$inputContainer = null;\n /// input file 태그\n this.$inputFile = null;\n this.$inputFileForm = null;\n /// 파일 선택버튼\n this.$fileSelector = null;\n /// 파일 드랍존\n this.$dropZone = null;\n /// 파일 목록 표시박스\n this.$uploadedBox = null;\n\n this.__uploading = false;\n this.selectedFiles = [];\n this.selectedFilesTotal = 0;\n this.__loaded = 0;\n\n cfg = this.config;\n\n /**\n * UI 상태변경 이벤트 처리자\n * UI의 상태변경 : open, close, upload 등의 변경사항이 발생되면 onStateChanged 함수를 후출하여 이벤트를 처리\n */\n var bound_onStateChanged = function (that) {\n\n var state = {\n \"open\": function open() {},\n \"close\": function close() {},\n \"upload\": function upload() {}\n };\n\n if (cfg.onStateChanged) {\n cfg.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n that = null;\n return true;\n }.bind(this);\n\n var bound_onSelectFile = function (_evt) {\n var files = void 0;\n\n if (!ax5.info.supportFileApi) {\n // file API 지원 안되는 브라우저.\n // input file에 multiple 지원 안됨 그러므로 단일 파일 처리만 하면 됨.\n files = { path: _evt.target.value };\n } else if ('dataTransfer' in _evt) {\n files = _evt.dataTransfer.files;\n } else if ('target' in _evt) {\n files = _evt.target.files;\n } else if (_evt) {\n files = _evt;\n }\n\n if (!files) return false;\n\n /// selectedFiles에 현재 파일 정보 담아두기\n if (length in files) {\n this.selectedFiles = U.toArray(files);\n } else {\n this.selectedFiles = [files];\n }\n\n if (cfg.progressBox) {\n bound_openProgressBox();\n }\n if (!cfg.manualUpload) {\n this.send();\n }\n\n if (!ax5.info.supportFileApi) {\n bound_alignLayout(false);\n }\n }.bind(this);\n\n var bound_bindEvent = function () {\n this.$fileSelector.off(\"click.ax5uploader\").on(\"click.ax5uploader\", function () {\n this.$inputFile.trigger(\"click\");\n }.bind(this));\n\n if (!ax5.info.supportFileApi) {\n this.$fileSelector.off(\"mouseover.ax5uploader\").on(\"mouseover.ax5uploader\", function () {\n bound_alignLayout(true);\n }.bind(this));\n\n this.$inputFile.off(\"mouseover.ax5uploader\").on(\"mouseover.ax5uploader\", function () {\n this.$fileSelector.addClass(\"active\");\n }.bind(this));\n\n this.$inputFile.off(\"mouseout.ax5uploader\").on(\"mouseout.ax5uploader\", function () {\n this.$fileSelector.removeClass(\"active\");\n\n bound_alignLayout(false);\n }.bind(this));\n }\n\n (function () {\n if (!this.$uploadedBox || !this.$uploadedBox.get(0)) return false;\n\n this.$uploadedBox.on(\"click\", \"[data-uploaded-item-cell]\", function () {\n var $this = jQuery(this),\n cellType = $this.attr(\"data-uploaded-item-cell\"),\n uploadedItemIndex = Number($this.parents('[data-ax5uploader-uploaded-item]').attr('data-ax5uploader-uploaded-item')),\n that = {};\n\n if (cfg.uploadedBox && cfg.uploadedBox.onclick) {\n that = {\n self: self,\n cellType: cellType,\n uploadedFiles: self.uploadedFiles,\n fileIndex: uploadedItemIndex\n };\n cfg.uploadedBox.onclick.call(that, that);\n }\n\n $this = null;\n cellType = null;\n uploadedItemIndex = null;\n that = null;\n });\n }).call(this);\n\n (function () {\n // dropZone 설정 방식 변경\n if (!ax5.info.supportFileApi) return false;\n if (!this.$dropZone || !this.$dropZone.get(0)) return false;\n\n var timer = void 0;\n\n this.$dropZone.parent().on(\"click\", \"[data-ax5uploader-dropzone]\", function (e) {\n if (this == e.target || $.contains(this, e.target)) {\n if (U.isFunction(cfg.dropZone.onclick)) {\n cfg.dropZone.onclick.call({\n self: self\n });\n } else {\n self.$inputFile.trigger(\"click\");\n }\n }\n });\n\n this.$dropZone.get(0).addEventListener('dragover', function (e) {\n U.stopEvent(e);\n\n if (U.isFunction(cfg.dropZone.ondragover)) {\n cfg.dropZone.ondragover.call({\n self: self\n });\n } else {\n self.$dropZone.addClass(\"dragover\");\n }\n }, false);\n\n this.$dropZone.get(0).addEventListener('dragleave', function (e) {\n U.stopEvent(e);\n\n if (U.isFunction(cfg.dropZone.ondragover)) {\n cfg.dropZone.ondragout.call({\n self: self\n });\n } else {\n self.$dropZone.removeClass(\"dragover\");\n }\n }, false);\n\n this.$dropZone.get(0).addEventListener('drop', function (e) {\n U.stopEvent(e);\n\n if (U.isFunction(cfg.dropZone.ondrop)) {\n cfg.dropZone.ondrop.call({\n self: self\n });\n } else {\n self.$dropZone.removeClass(\"dragover\");\n }\n\n bound_onSelectFile(e || window.event);\n }, false);\n }).call(this);\n }.bind(this);\n\n var bound_alignLayout = function (_TF) {\n // 상황이 좋지 않은경우 (만약 버튼 클릭으로 input file click이 되지 않는 다면 z-index값을 높여서 버튼위를 덮는다.)\n if (_TF) {\n if (!ax5.info.supportFileApi) {\n // ie9에서 inputFile을 직접 클릭하지 않으면 submit 오류발생함. submit access denied\n // 그래서 버튼위에 inputFile을 올려두어야 함. (position값을 이용하면 편하지만..)\n // 그런데 form을 안에두면 또 다른 이중폼 문제 발생소지 ㅜㅜ 불가피하게 버튼의 offset 값을 이용.\n var box = this.$fileSelector.offset();\n box.width = this.$fileSelector.outerWidth();\n box.height = this.$fileSelector.outerHeight();\n this.$inputFile.css(box);\n }\n } else {\n this.$inputFile.css({\n left: -1000, top: -1000\n });\n }\n }.bind(this);\n\n var bound_alignProgressBox = function (append) {\n var _alignProgressBox = function _alignProgressBox() {\n var $window = jQuery(window),\n $body = jQuery(document.body);\n var pos = {},\n positionMargin = 6,\n dim = {},\n pickerDim = {},\n pickerDirection = void 0;\n\n // cfg.viewport.selector\n\n pos = this.$progressBox.parent().get(0) == this.$target.get(0) ? this.$fileSelector.position() : this.$fileSelector.offset();\n dim = {\n width: this.$fileSelector.outerWidth(),\n height: this.$fileSelector.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), $body.width()),\n winHeight: Math.max($window.height(), $body.height()),\n width: this.$progressBox.outerWidth(),\n height: this.$progressBox.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n if (!cfg.progressBoxDirection || cfg.progressBoxDirection === \"\" || cfg.progressBoxDirection === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = cfg.progressBoxDirection;\n }\n\n if (append) {\n this.$progressBox.addClass(\"direction-\" + pickerDirection);\n }\n\n var positionCSS = function () {\n var css = { left: 0, top: 0 };\n switch (pickerDirection) {\n case \"top\":\n css.left = pos.left + dim.width / 2 - pickerDim.width / 2;\n css.top = pos.top + dim.height + positionMargin;\n break;\n case \"bottom\":\n css.left = pos.left + dim.width / 2 - pickerDim.width / 2;\n css.top = pos.top - pickerDim.height - positionMargin;\n break;\n case \"left\":\n css.left = pos.left + dim.width + positionMargin;\n css.top = pos.top - pickerDim.height / 2 + dim.height / 2;\n break;\n case \"right\":\n css.left = pos.left - pickerDim.width - positionMargin;\n css.top = pos.top - pickerDim.height / 2 + dim.height / 2;\n break;\n }\n return css;\n }();\n\n (function () {\n if (pickerDirection == \"top\" || pickerDirection == \"bottom\") {\n if (positionCSS.left < 0) {\n positionCSS.left = positionMargin;\n this.$progressBoxArrow.css({ left: pos.left + dim.width / 2 - positionCSS.left });\n } else if (positionCSS.left + pickerDim.width > pickerDim.winWidth) {\n positionCSS.left = pickerDim.winWidth - pickerDim.width - positionMargin;\n this.$progressBoxArrow.css({ left: pos.left + dim.width / 2 - positionCSS.left });\n }\n }\n }).call(this);\n\n this.$progressBox.css(positionCSS);\n };\n\n this.$progressBox.css({ top: -999 });\n if (append) {\n // progressBox를 append 할 타겟 엘리먼트 펀단 후 결정.\n (function () {\n if (cfg.viewport) {\n return jQuery(cfg.viewport.selector);\n } else {\n return this.$target;\n }\n }).call(this).append(this.$progressBox);\n\n // progressBox 버튼에 이벤트 연결.\n this.$progressBox.off(\"click.ax5uploader\").on(\"click.ax5uploader\", \"button\", function (_evt) {\n var act = _evt.target.getAttribute(\"data-pregressbox-btn\");\n var processor = {\n \"upload\": function upload() {\n this.send();\n },\n \"abort\": function abort() {\n this.abort();\n }\n };\n if (processor[act]) processor[act].call(this);\n }.bind(this));\n }\n\n setTimeout(function () {\n _alignProgressBox.call(this);\n }.bind(this));\n }.bind(this);\n\n var bound_openProgressBox = function () {\n this.$progressBox.removeClass(\"destroy\");\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.removeAttr(\"disabled\");\n\n // apend & align progress box\n bound_alignProgressBox(\"append\");\n\n // state change\n bound_onStateChanged({\n self: this,\n state: \"open\"\n });\n }.bind(this);\n\n var bound_closeProgressBox = function () {\n this.$progressBox.addClass(\"destroy\");\n setTimeout(function () {\n this.$progressBox.remove();\n }.bind(this), cfg.animateTime);\n }.bind(this);\n\n var bound_startUpload = function () {\n\n var processor = {\n \"html5\": function html5() {\n\n var uploadFile = this.selectedFiles.shift();\n if (!uploadFile) {\n // 업로드 종료\n bound_uploadComplete();\n return this;\n }\n\n var formData = new FormData();\n //서버로 전송해야 할 추가 파라미터 정보 설정\n\n this.$target.find(\"input\").each(function () {\n formData.append(this.name, this.value);\n });\n // 파일 아이템 추가\n formData.append(cfg.form.fileName, uploadFile);\n\n this.xhr = new XMLHttpRequest();\n this.xhr.open(\"post\", cfg.form.action, true);\n\n this.xhr.onload = function (e) {\n var res = e.target.response;\n try {\n if (typeof res == \"string\") res = U.parseJson(res);\n } catch (e) {\n return false;\n }\n if (cfg.debug) console.log(res);\n\n if (res.error) {\n if (cfg.debug) console.log(res.error);\n if (U.isFunction(cfg.onuploaderror)) {\n cfg.onuploaderror.call({\n self: this,\n error: res.error\n }, res);\n }\n self.send();\n return false;\n }\n\n bound_uploaded(res);\n self.send();\n };\n\n this.xhr.upload.onprogress = function (e) {\n // console.log(e.loaded, e.total);\n bound_updateProgressBar(e);\n if (U.isFunction(cfg.onprogress)) {\n cfg.onprogress.call({\n loaded: e.loaded,\n total: e.total\n }, e);\n }\n };\n this.xhr.send(formData); // multipart/form-data\n },\n \"form\": function form() {\n\n /// i'm busy\n this.__uploading = true;\n\n // 폼과 iframe을 만들어 페이지 아래에 삽입 후 업로드\n var $iframe = jQuery('
');\n jQuery(document.body).append($iframe);\n\n // onload 이벤트 핸들러\n // action에서 파일을 받아 처리한 결과값을 텍스트로 출력한다고 가정하고 iframe의 내부 데이터를 결과값으로 callback 호출\n $iframe.load(function () {\n var doc = this.contentWindow ? this.contentWindow.document : this.contentDocument ? this.contentDocument : this.document,\n root = doc.documentElement ? doc.documentElement : doc.body,\n result = root.textContent ? root.textContent : root.innerText,\n res = void 0;\n\n try {\n res = JSON.parse(result);\n } catch (e) {\n res = {\n error: \"Syntax error\",\n body: result\n };\n }\n\n if (cfg.debug) console.log(res);\n if (res.error) {\n console.log(res);\n } else {\n bound_uploaded(res);\n $iframe.remove();\n\n setTimeout(function () {\n bound_uploadComplete();\n }, 300);\n }\n });\n\n this.$inputFileForm.attr(\"target\", 'ax5uploader-' + this.instanceId + '-iframe').attr(\"action\", cfg.form.action).submit();\n\n this.selectedFilesTotal = 1;\n bound_updateProgressBar({\n loaded: 1,\n total: 1\n });\n }\n };\n\n if (this.__uploading === false) {\n // 전체 파일 사이즈 구하기\n var filesTotal = 0;\n this.selectedFiles.forEach(function (n) {\n filesTotal += n.size;\n });\n this.selectedFilesTotal = filesTotal;\n this.__loaded = 0;\n\n this.__uploading = true; // 업로드 시작 상태 처리\n this.$progressUpload.attr(\"disabled\", \"disabled\");\n this.$progressAbort.removeAttr(\"disabled\");\n }\n\n processor[ax5.info.supportFileApi ? \"html5\" : \"form\"].call(this);\n }.bind(this);\n\n var bound_updateProgressBar = function (e) {\n this.__loaded += e.loaded;\n this.$progressBar.css({ width: U.number(this.__loaded / this.selectedFilesTotal * 100, { round: 2 }) + '%' });\n if (e.lengthComputable) {\n if (e.loaded >= e.total) {}\n }\n }.bind(this);\n\n var bound_uploaded = function (res) {\n if (cfg.debug) console.log(res);\n this.uploadedFiles.push(res);\n bound_repaintUploadedBox(); // 업로드된 파일 출력\n\n if (U.isFunction(cfg.onuploaded)) {\n cfg.onuploaded.call({\n self: this\n }, res);\n }\n }.bind(this);\n\n var bound_uploadComplete = function () {\n this.__uploading = false; // 업로드 완료 상태처리\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.attr(\"disabled\", \"disabled\");\n\n if (cfg.progressBox) {\n bound_closeProgressBox();\n }\n if (U.isFunction(cfg.onuploadComplete)) {\n cfg.onuploadComplete.call({\n self: this\n });\n }\n // update uploadedFiles display\n\n /// reset inputFile\n bound_attachFileTag();\n }.bind(this);\n\n var bound_cancelUpload = function () {\n\n var processor = {\n \"html5\": function html5() {\n if (this.xhr) {\n this.xhr.abort();\n }\n },\n \"form\": function form() {}\n };\n\n this.__uploading = false; // 업로드 완료 상태처리\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.attr(\"disabled\", \"disabled\");\n\n processor[ax5.info.supportFileApi ? \"html5\" : \"form\"].call(this);\n\n if (cfg.progressBox) {\n bound_closeProgressBox();\n }\n\n //this.$inputFile.val(\"\");\n /// reset inputFile\n bound_attachFileTag();\n\n if (cfg.debug) console.log(\"cancelUpload\");\n // update uploadedFiles display\n }.bind(this);\n\n var bound_repaintUploadedBox = function () {\n // uploadedBox 가 없다면 아무일도 하지 않음.\n // onuploaded 함수 이벤트를 이용하여 개발자가 직접 업로드디 박스를 구현 한다고 이해 하자.\n if (this.$uploadedBox === null) return this;\n\n this.$uploadedBox.html(UPLOADER.tmpl.get(\"upoadedBox\", {\n uploadedFiles: this.uploadedFiles,\n icon: cfg.uploadedBox.icon,\n lang: cfg.uploadedBox.lang,\n supportFileApi: !!ax5.info.supportFileApi\n }, cfg.uploadedBox.columnKeys));\n }.bind(this);\n\n var bound_attachFileTag = function () {\n if (this.$inputFile && this.$inputFile.get(0)) {\n this.$inputFile.remove();\n }\n if (this.$inputFileForm && this.$inputFileForm.get(0)) {\n this.$inputFileForm.remove();\n }\n\n this.$inputFile = jQuery(UPLOADER.tmpl.get.call(this, \"inputFile\", {\n instanceId: this.instanceId,\n multiple: cfg.multiple,\n accept: cfg.accept,\n name: cfg.form.fileName\n }));\n\n if (ax5.info.supportFileApi) {\n jQuery(document.body).append(this.$inputFile);\n } else {\n this.$fileSelector.attr(\"tabindex\", -1);\n this.$inputFileForm = jQuery(UPLOADER.tmpl.get.call(this, \"inputFileForm\", {\n instanceId: this.instanceId\n }));\n\n this.$inputFileForm.append(this.$inputFile);\n jQuery(document.body).append(this.$inputFileForm);\n }\n\n this.$inputFile.off(\"change.ax5uploader\").on(\"change.ax5uploader\", function (_evt) {\n bound_onSelectFile(_evt);\n }.bind(this));\n }.bind(this);\n\n /**\n * Preferences of uploader UI\n * @method ax5uploader.setConfig\n * @param {Object} _config - 클래스 속성값\n * @param {Element} _config.target\n * @param {Object} _config.form\n * @param {String} _config.form.action - upload URL\n * @param {String} _config.form.fileName - The name key of the upload file\n * @param {Boolean} [_config.multiple=false] - Whether multiple files. In a browser where fileApi is not supported (eg IE9), it only works with false.\n * @param {String} [_config.accept=\"\"] - accept mimeType (http://www.w3schools.com/TAgs/att_input_accept.asp)\n * @param {Boolean} [_config.manualUpload=false] - Whether to automatically upload when a file is selected.\n * @param {Boolean} [_config.progressBox=true] - Whether to use progressBox\n * @param {String} [_config.progressBoxDirection=auto] - ProgressBox display direction\n * @param {Object} [_config.dropZone]\n * @param {Element} [_config.dropZone.target]\n * @param {Function} [_config.dropZone.onclick]\n * @param {Function} [_config.dropZone.ondragover]\n * @param {Function} [_config.dropZone.ondragout]\n * @param {Function} [_config.dropZone.ondrop]\n * @param {Object} [_config.uploadedBox]\n * @param {Element} [_config.uploadedBox.target]\n * @param {Element} [_config.uploadedBox.icon]\n * @param {Object} [_config.uploadedBox.columnKeys]\n * @param {String} [_config.uploadedBox.columnKeys.name]\n * @param {String} [_config.uploadedBox.columnKeys.type]\n * @param {String} [_config.uploadedBox.columnKeys.size]\n * @param {String} [_config.uploadedBox.columnKeys.uploadedName]\n * @param {String} [_config.uploadedBox.columnKeys.downloadPath]\n * @param {Object} [_config.uploadedBox.lang]\n * @param {String} [_config.uploadedBox.lang.supportedHTML5_emptyListMsg]\n * @param {String} [_config.uploadedBox.lang.emptyListMsg]\n * @param {Function} [_config.uploadedBox.onchange]\n * @param {Function} [_config.uploadedBox.onclick]\n * @param {Function} [_config.validateSelectedFiles]\n * @param {Function} [_config.onprogress] - return loaded, total\n * @param {Function} [_config.onuploaded] - return self\n * @param {Function} [_config.onuploaderror] - return self, error\n * @param {Function} [_config.onuploadComplete] - return self\n * @returns {ax5uploader}\n * @example\n * ```js\n *\n * ```\n */\n this.init = function (_config) {\n cfg = jQuery.extend(true, {}, cfg, _config);\n if (!cfg.target) {\n console.log(ax5.info.getError(\"ax5uploader\", \"401\", \"init\"));\n return this;\n }\n\n this.$target = jQuery(cfg.target);\n\n // 파일 드랍존은 옵션 사항.\n if (cfg.dropZone && cfg.dropZone.target && ax5.info.supportFileApi) {\n this.$dropZone = jQuery(cfg.dropZone.target);\n this.$dropZone.attr(\"data-ax5uploader-dropzone\", this.instanceId);\n }\n\n // uploadedBox 옵션 사항\n if (cfg.uploadedBox && cfg.uploadedBox.target) {\n this.$uploadedBox = jQuery(cfg.uploadedBox.target);\n }\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n cfg = jQuery.extend(true, cfg, data);\n }\n }).call(this, U.parseJson(this.$target.attr(\"data-ax5uploader-config\"), true));\n\n // detect element\n /// fileSelector 수집\n this.$fileSelector = this.$target.find('[data-ax5uploader-button=\"selector\"]');\n\n if (this.$fileSelector.length === 0) {\n console.log(ax5.info.getError(\"ax5uploader\", \"402\", \"can not find file selector\"));\n return this;\n }\n\n // input file 추가\n bound_attachFileTag();\n\n // btns 확인\n cfg.btns = jQuery.extend({}, this.defaultBtns, cfg.btns);\n\n this.$progressBox = jQuery(UPLOADER.tmpl.get.call(this, \"progressBox\", {\n instanceId: this.instanceId,\n btns: cfg.btns\n }));\n this.$progressBar = this.$progressBox.find('[role=\"progressbar\"]');\n this.$progressBoxArrow = this.$progressBox.find(\".ax-progressbox-arrow\");\n this.$progressUpload = this.$progressBox.find('[data-pregressbox-btn=\"upload\"]');\n this.$progressAbort = this.$progressBox.find('[data-pregressbox-btn=\"abort\"]');\n\n // file API가 지원되지 않는 브라우저는 중지 기능 제공 못함.\n if (!ax5.info.supportFileApi) {\n this.$progressAbort.hide();\n }\n // 파일버튼 등에 이벤트 연결.\n bound_bindEvent();\n\n bound_repaintUploadedBox();\n return this;\n };\n\n /**\n * @method ax5uploader.send\n * @returns {ax5uploader}\n *\n */\n this.send = function () {\n return function () {\n // 업로드 시작\n if (U.isFunction(cfg.validateSelectedFiles)) {\n var that = {\n self: this,\n uploadedFiles: this.uploadedFiles,\n selectedFiles: this.selectedFiles\n };\n if (!cfg.validateSelectedFiles.call(that, that)) {\n bound_cancelUpload();\n return false;\n // 전송처리 안함.\n }\n }\n\n bound_startUpload();\n return this;\n };\n }();\n\n /**\n * @method ax5uploader.abort\n * @returns {ax5uploader}\n */\n this.abort = function () {\n return function () {\n if (!ax5.info.supportFileApi) {\n alert(\"This browser not supported abort method\");\n return this;\n }\n bound_cancelUpload();\n return this;\n };\n }();\n\n /**\n * @method ax5uploader.setUploadedFiles\n * @param {Array} _files - JSON formatting can all be overridden in columnKeys.\n * @returns {ax5uploader}\n * @example\n * ```js\n * var upload1 = new ax5.ui.uploader();\n * upload1.setConfig({\n * ...\n * });\n *\n *\n * $.ajax({\n * url: \"api/fileListLoad.php\",\n * success: function (res) {\n * // res JSON format\n * // [{\n * // \"name\": \"barcode-scan-ani.gif\",\n * // \"saveName\": \"barcode-scan-ani.gif\",\n * // \"type\": \"file\",\n * // \"fileSize\": \"3891664\",\n * // \"uploadedPath\": \"/ax5ui-uploader/test/api/files\",\n * // \"thumbUrl\": \"\"\n * // }]\n * upload1.setUploadedFiles(res);\n * }\n * });\n * ```\n */\n this.setUploadedFiles = function (_files) {\n if (U.isArray(_files)) {\n this.uploadedFiles = _files;\n }\n if (U.isString(_files)) {\n try {\n this.uploadedFiles = JSON.parse(_files);\n } catch (e) {}\n }\n\n bound_repaintUploadedBox();\n return this;\n };\n\n /**\n * Removes the object corresponding to the index passed to the argument from uploadedFiles.\n * @method ax5uploader.removeFile\n * @param {Number} _index\n * @returns {ax5uploader}\n * @example\n * ```js\n * // The actual file is not deleted\n * upload1.removeFile(fileIndex);\n * ```\n */\n this.removeFile = function (_index) {\n if (!isNaN(Number(_index))) {\n this.uploadedFiles.splice(_index, 1);\n }\n bound_repaintUploadedBox();\n return this;\n };\n\n /**\n * Empty uploadedFiles\n * @method ax5uploader.removeFileAll\n * @returns {ax5uploader}\n * @example\n * ```js\n *\n * ```\n */\n this.removeFileAll = function () {\n this.uploadedFiles = [];\n bound_repaintUploadedBox();\n return this;\n };\n\n /**\n * @method ax5uploader.selectFile\n * @returns {Boolean}\n */\n this.selectFile = function () {\n if (ax5.info.supportFileApi) {\n this.$inputFile.trigger(\"click\");\n return true;\n }\n return false;\n };\n\n // 클래스 생성자\n this.main = function () {\n UI.uploader_instance = UI.uploader_instance || [];\n UI.uploader_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n } else {\n //this.init();\n }\n }.apply(this, arguments);\n };\n return ax5uploader;\n }());\n\n UPLOADER = ax5.ui.uploader;\n})();\n\n// todo :\n// html5용 업로드 - 구현완료\n// abort, 여러개의 파일이 올라가는 중간에 abort 하면 업로드된 파일은 두고. 안올라간 파일만 중지 -- ok\n// set uploded files\n// uploaded files display, needs columnKeys\n// delete file\n\n// dropFile support\n// ax5.ui.uploader.tmpl\n(function () {\n\n var UPLOADER = ax5.ui.uploader;\n\n var uploadProgress = function uploadProgress(columnKeys) {\n return '\\n ';\n };\n\n var inputFile = function inputFile(columnKeys) {\n return '
';\n };\n\n var inputFileForm = function inputFileForm(columnKeys) {\n return '
';\n };\n\n var progressBox = function progressBox(columnKeys) {\n return '\\n
\\n
\\n
\\n
\\n
\\n 0% Complete\\n
\\n
\\n
\\n {{#btns}}\\n
\\n {{#btns}}\\n {{#@each}}\\n \\n {{/@each}}\\n {{/btns}}\\n
\\n {{/btns}}\\n
\\n
\\n
\\n';\n };\n\n var upoadedBox = function upoadedBox(columnKeys) {\n return '\\n{{#uploadedFiles}}
\\n
\\n
{{{icon.download}}}
\\n
{{' + columnKeys.name + '}}
\\n
({{#@fn_get_byte}}{{' + columnKeys.size + '}}{{/@fn_get_byte}})
\\n
{{{icon.delete}}}
\\n
\\n
{{/uploadedFiles}}\\n{{^uploadedFiles}}\\n{{#supportFileApi}}{{{lang.supportedHTML5_emptyListMsg}}}{{/supportFileApi}}\\n{{^supportFileApi}}{{{lang.emptyListMsg}}}{{/supportFileApi}}\\n{{/uploadedFiles}}\\n';\n };\n\n UPLOADER.tmpl = {\n \"uploadProgress\": uploadProgress,\n \"inputFile\": inputFile,\n \"inputFileForm\": inputFileForm,\n \"progressBox\": progressBox,\n \"upoadedBox\": upoadedBox,\n\n get: function get(tmplName, data, columnKeys) {\n data[\"@fn_get_byte\"] = function () {\n return function (text, render) {\n return ax5.util.number(render(text), { round: 2, byte: true });\n };\n };\n return ax5.mustache.render(UPLOADER.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n// ax5.ui.combobox\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var COMBOBOX;\n\n UI.addClass({\n className: \"combobox\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5combobox\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var options = [];\n * options.push({value: \"1\", text: \"string\"});\n * options.push({value: \"2\", text: \"number\"});\n * options.push({value: \"3\", text: \"substr\"});\n * options.push({value: \"4\", text: \"substring\"});\n * options.push({value: \"search\", text: \"search\"});\n * options.push({value: \"parseInt\", text: \"parseInt\"});\n * options.push({value: \"toFixed\", text: \"toFixed\"});\n * options.push({value: \"min\", text: \"min\"});\n * options.push({value: \"max\", text: \"max\"});\n *\n * var myCombo = new ax5.ui.combobox({\n * theme: \"danger\",\n * removeIcon: '
'\n * });\n * ```\n */\n var ax5combobox = function ax5combobox() {\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 250,\n removeIcon: 'X',\n lang: {\n noSelected: '',\n noOptions: 'no options',\n loading: 'now loading..'\n },\n columnKeys: {\n optionValue: 'value',\n optionText: 'text',\n optionSelected: 'selected'\n }\n };\n\n this.queue = [];\n this.activecomboboxOptionGroup = null;\n this.activecomboboxQueueIndex = -1;\n this.openTimer = null;\n this.closeTimer = null;\n this.waitOptionsCallback = null;\n this.keyUpTimer = null;\n\n cfg = this.config;\n\n var $window = jQuery(window);\n var ctrlKeys = {\n \"18\": \"KEY_ALT\",\n \"8\": \"KEY_BACKSPACE\",\n \"17\": \"KEY_CONTROL\",\n \"46\": \"KEY_DELETE\",\n \"40\": \"KEY_DOWN\",\n \"35\": \"KEY_END\",\n \"187\": \"KEY_EQUAL\",\n \"27\": \"KEY_ESC\",\n \"36\": \"KEY_HOME\",\n \"45\": \"KEY_INSERT\",\n \"37\": \"KEY_LEFT\",\n \"189\": \"KEY_MINUS\",\n \"34\": \"KEY_PAGEDOWN\",\n \"33\": \"KEY_PAGEUP\",\n // \"190\": \"KEY_PERIOD\",\n \"13\": \"KEY_RETURN\",\n \"39\": \"KEY_RIGHT\",\n \"16\": \"KEY_SHIFT\",\n // \"32\": \"KEY_SPACE\",\n \"9\": \"KEY_TAB\",\n \"38\": \"KEY_UP\",\n \"91\": \"KEY_WINDOW\"\n //\"107\" : \"NUMPAD_ADD\",\n //\"194\" : \"NUMPAD_COMMA\",\n //\"110\" : \"NUMPAD_DECIMAL\",\n //\"111\" : \"NUMPAD_DIVIDE\",\n //\"12\" : \"NUMPAD_EQUAL\",\n //\"106\" : \"NUMPAD_MULTIPLY\",\n //\"109\" : \"NUMPAD_SUBTRACT\"\n },\n onStateChanged = function onStateChanged(item, that) {\n if (item && item.onStateChanged) {\n item.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n if (that.state == \"changeValue\") {\n if (item && item.onChange) {\n item.onChange.call(that, that);\n } else if (this.onChange) {\n this.onChange.call(that, that);\n }\n }\n\n item = null;\n that = null;\n return true;\n },\n alignComboboxDisplay = function alignComboboxDisplay() {\n var i = this.queue.length,\n w;\n\n while (i--) {\n var item = this.queue[i];\n if (item.$display) {\n w = Math.max(item.$select.outerWidth(), U.number(item.minWidth));\n item.$display.css({\n \"min-width\": w\n });\n if (item.reset) {\n item.$display.find(\".addon-icon-reset\").css({\n \"line-height\": this.queue[i].$display.height() + \"px\"\n });\n }\n\n // 높이조절 처리\n if (item.multiple) {\n var displayTableHeightAdjust = function () {\n return U.number(item.$display.css(\"border-top-width\")) + U.number(item.$display.css(\"border-bottom-width\"));\n }.call(this);\n item.$target.height('');\n item.$display.height('');\n\n var displayTableHeight = item.$displayTable.outerHeight();\n if (Math.abs(displayTableHeight - item.$target.height()) > displayTableHeightAdjust) {\n item.$target.css({ height: displayTableHeight + displayTableHeightAdjust + 4 });\n item.$display.css({ height: displayTableHeight + displayTableHeightAdjust + 4 });\n }\n }\n }\n }\n\n i = null;\n w = null;\n return this;\n },\n alignComboboxOptionGroup = function alignComboboxOptionGroup(append) {\n if (!this.activecomboboxOptionGroup) return this;\n\n var item = this.queue[this.activecomboboxQueueIndex],\n pos = {},\n positionMargin = 0,\n dim = {},\n pickerDim = {},\n pickerDirection;\n\n if (append) jQuery(document.body).append(this.activecomboboxOptionGroup);\n\n pos = item.$target.offset();\n dim = {\n width: item.$target.outerWidth(),\n height: item.$target.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), jQuery(document.body).width()),\n winHeight: Math.max($window.height(), jQuery(document.body).height()),\n width: this.activecomboboxOptionGroup.outerWidth(),\n height: this.activecomboboxOptionGroup.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n if (!item.direction || item.direction === \"\" || item.direction === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = item.direction;\n }\n\n if (append) {\n this.activecomboboxOptionGroup.addClass(\"direction-\" + pickerDirection);\n }\n this.activecomboboxOptionGroup.css(function () {\n if (pickerDirection == \"top\") {\n if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n\n var newTop = pos.top + dim.height / 2 - pickerDim.height / 2;\n if (newTop + pickerDim.height + positionMargin > pickerDim.winHeight) {\n newTop = 0;\n }\n if (newTop < 0) {\n newTop = 0;\n }\n\n return {\n left: pos.left,\n top: newTop,\n width: dim.width\n };\n }\n return {\n left: pos.left,\n top: pos.top + dim.height + 1,\n width: dim.width\n };\n } else if (pickerDirection == \"bottom\") {\n return {\n left: pos.left,\n top: pos.top - pickerDim.height - 1,\n width: dim.width\n };\n }\n }.call(this));\n },\n onBodyClick = function onBodyClick(e, target) {\n if (!this.activecomboboxOptionGroup) return this;\n\n var item = this.queue[this.activecomboboxQueueIndex],\n clickEl = \"display\";\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-option-value\")) {\n clickEl = \"optionItem\";\n return true;\n } else if (item.$target.get(0) == target) {\n clickEl = \"display\";\n return true;\n }\n });\n\n if (!target) {\n this.close();\n return this;\n } else if (clickEl === \"optionItem\") {\n\n setOptionSelect.call(this, item.id, {\n index: {\n gindex: target.getAttribute(\"data-option-group-index\"),\n index: target.getAttribute(\"data-option-index\")\n }\n }, undefined, true);\n\n alignComboboxDisplay.call(this);\n alignComboboxOptionGroup.call(this);\n\n if (!item.multiple) {\n this.close();\n }\n } else {}\n\n return this;\n },\n getLabel = function getLabel(queIdx) {\n var item = this.queue[queIdx];\n\n // 템플릿에 전달 해야할 데이터 선언\n var data = {};\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5combobox-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n data.selected = item.selected;\n data.hasSelected = data.selected && data.selected.length > 0;\n data.removeIcon = item.removeIcon;\n\n return COMBOBOX.tmpl.get.call(this, \"label\", data, item.columnKeys);\n },\n printLabel = function printLabel(queIdx) {\n var item = this.queue[queIdx];\n\n item.$displayLabel.find('[data-ax5combobox-selected-label]').remove();\n item.$displayLabelInput.before(getLabel.call(this, queIdx));\n },\n focusLabel = function focusLabel(queIdx) {\n if (this.queue[queIdx].disabled) return this;\n\n this.queue[queIdx].$displayLabel.trigger(\"focus\");\n this.queue[queIdx].$displayLabelInput.focus();\n },\n clearLabel = function clearLabel(queIdx) {\n this.queue[queIdx].$displayLabelInput.val('');\n },\n blurLabel = function blurLabel(queIdx) {\n this.queue[queIdx].$displayLabel.trigger(\"blur\");\n this.queue[queIdx].$displayLabelInput.trigger(\"blur\");\n },\n onSearch = function onSearch(queIdx, searchWord) {\n this.queue[queIdx].waitOptions = true;\n\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(COMBOBOX.tmpl.get.call(this, \"option\", this.queue[queIdx], this.queue[queIdx].columnKeys)));\n\n this.queue[queIdx].onSearch.call({\n self: this,\n item: this.queue[queIdx],\n searchWord: searchWord\n }, function (O) {\n\n var data = {};\n var item = this.queue[this.activecomboboxQueueIndex];\n if (!item) return false;\n\n /// 현재 selected 검증후 처리\n (function (item, O) {\n var optionsMap = {};\n O.options.forEach(function (_O, _OIndex) {\n _O[\"@index\"] = _OIndex;\n optionsMap[_O[item.columnKeys.optionValue]] = _O;\n });\n if (U.isArray(item.selected)) {\n item.selected.forEach(function (_O) {\n if (optionsMap[_O[item.columnKeys.optionValue]]) {\n O.options[optionsMap[_O[item.columnKeys.optionValue]][\"@index\"]][item.columnKeys.optionSelected] = true;\n }\n });\n }\n })(item, O);\n\n item.options = syncComboboxOptions.call(this, this.activecomboboxQueueIndex, O.options);\n\n alignComboboxDisplay.call(this);\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5combobox-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(COMBOBOX.tmpl.get.call(this, \"options\", data, item.columnKeys)));\n }.bind(this));\n },\n focusWord = function focusWord(queIdx, searchWord) {\n //console.log(searchWord);\n\n if (this.activecomboboxQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n var options = [],\n i = -1,\n l = this.queue[queIdx].indexedOptions.length - 1,\n n;\n\n if (searchWord != \"\") {\n var regExp = /[\\{\\}\\[\\]\\/?.,;:|\\)*~`!^\\-_+<>@\\#$%&\\\\\\=\\(\\'\\\"]/gi;\n searchWord = searchWord.replace(regExp, \"\");\n if (this.queue[queIdx].onSearch) {\n onSearch.call(this, queIdx, searchWord);\n\n try {\n return options;\n } finally {\n options = null;\n i = null;\n l = null;\n n = null;\n }\n // if there is a \"onSearch\", to end this process\n }\n\n while (l - i++) {\n n = this.queue[queIdx].indexedOptions[i];\n\n if (('' + n.text).toLowerCase() == searchWord.toLowerCase()) {\n options = [{ '@findex': n['@findex'], optionsSort: 0 }];\n break;\n } else {\n var sort = ('' + n.text).toLowerCase().search(searchWord.toLowerCase());\n if (sort > -1) {\n options.push({ '@findex': n['@findex'], optionsSort: sort });\n if (options.length > 2) break;\n }\n sort = null;\n }\n }\n options.sort(function (a, b) {\n return a.optionsSort - b.optionsSort;\n });\n }\n\n if (options && options.length > 0) {\n focusMove.call(this, queIdx, undefined, options[0]['@findex']);\n } else {\n focusClear.call(this, queIdx);\n }\n\n try {\n return options;\n } finally {\n options = null;\n i = null;\n l = null;\n n = null;\n }\n },\n focusClear = function focusClear(queIdx) {\n if (this.activecomboboxOptionGroup) {\n this.activecomboboxOptionGroup.find('[data-option-focus-index]').removeClass(\"hover\").removeAttr(\"data-option-selected\");\n }\n\n this.queue[queIdx].optionFocusIndex = -1;\n },\n focusMove = function focusMove(queIdx, direction, findex) {\n var _focusIndex, _prevFocusIndex, focusOptionEl, optionGroupScrollContainer;\n var item = this.queue[queIdx];\n\n if (this.activecomboboxOptionGroup && item.options && item.options.length > 0) {\n\n if (typeof findex !== \"undefined\") {\n _focusIndex = findex;\n } else {\n _prevFocusIndex = item.optionFocusIndex == -1 ? item.optionSelectedIndex || -1 : item.optionFocusIndex;\n if (_prevFocusIndex == -1) {\n _focusIndex = 0;\n //_focusIndex = (direction > 0) ? 0 : item.optionItemLength - 1; // 맨 끝으로 보낼것인가 말 것인가.\n } else {\n _focusIndex = _prevFocusIndex + direction;\n if (_focusIndex < 0) _focusIndex = 0;else if (_focusIndex > item.optionItemLength - 1) _focusIndex = item.optionItemLength - 1;\n }\n }\n\n item.optionFocusIndex = _focusIndex;\n\n // 포커스 인덱스가 hide아이템을 만나면 hide 아이템이 안나올 때까지 루프를 순회 합니다.\n // todo : editable 로 추가된 options가 제거 되지 않으므로. 인덱스 검색을 좀 더 보강 해야함.\n if (item.options[_focusIndex] && item.options[_focusIndex].hide) {\n // 옵션이 없는 값이 선택된 경우\n if (typeof direction === \"undefined\") {\n return this;\n } else {\n var isStrop = false;\n while (item.options[_focusIndex].hide) {\n _focusIndex = _focusIndex + direction;\n if (_focusIndex < 0) {\n _focusIndex = 0;\n break;\n } else if (_focusIndex > item.optionItemLength - 1) {\n _focusIndex = item.optionItemLength - 1;\n break;\n }\n }\n }\n }\n\n if (typeof _focusIndex !== \"undefined\") {\n this.activecomboboxOptionGroup.find('[data-option-focus-index]').removeClass(\"hover\");\n\n focusOptionEl = this.activecomboboxOptionGroup.find('[data-option-focus-index=\"' + _focusIndex + '\"]').addClass(\"hover\");\n\n optionGroupScrollContainer = this.activecomboboxOptionGroup.find('[data-els=\"content\"]');\n\n if (focusOptionEl.get(0)) {\n var focusOptionElHeight = focusOptionEl.outerHeight(),\n optionGroupScrollContainerHeight = optionGroupScrollContainer.innerHeight(),\n optionGroupScrollContainerScrollTop = optionGroupScrollContainer.scrollTop(),\n focusOptionElTop = focusOptionEl.position().top + optionGroupScrollContainer.scrollTop();\n\n if (optionGroupScrollContainerHeight + optionGroupScrollContainerScrollTop < focusOptionElTop + focusOptionElHeight) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop + focusOptionElHeight - optionGroupScrollContainerHeight);\n } else if (optionGroupScrollContainerScrollTop > focusOptionElTop) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop);\n }\n // optionGroup scroll check\n\n if (typeof direction !== \"undefined\") {\n item.$displayLabelInput.val(item.options[_focusIndex].text);\n }\n }\n }\n }\n },\n syncComboboxOptions = function () {\n var setSelected = function setSelected(queIdx, O) {\n if (!O) {\n this.queue[queIdx].selected = [];\n } else {\n this.queue[queIdx].selected.push(jQuery.extend({}, O));\n /*\n 콤보박스는 selected가 없을 때 options의 첫번째 아이템이 selected가 되지 않는다.\n if (this.queue[queIdx].multiple) this.queue[queIdx].selected.push(jQuery.extend({}, O));\n else this.queue[queIdx].selected[0] = jQuery.extend({}, O);\n */\n }\n };\n\n return function (queIdx, options) {\n var item = this.queue[queIdx];\n var po,\n elementOptions,\n newOptions,\n focusIndex = 0;\n setSelected.call(this, queIdx, false); // item.selected 초기화\n\n if (options) {\n item.options = options;\n item.indexedOptions = [];\n\n // combobox options 태그 생성\n po = [];\n po.push('
');\n\n item.options.forEach(function (O, OIndex) {\n /// @gindex : index of optionGroup\n /// @index : index of options (if you use optionGroup then the index is not unique)\n if (O.optgroup) {\n O['@gindex'] = OIndex;\n O.options.forEach(function (OO, OOIndex) {\n OO['@index'] = OOIndex;\n OO['@findex'] = focusIndex;\n po.push('
');\n if (OO[item.columnKeys.optionSelected]) {\n setSelected.call(self, queIdx, OO);\n }\n\n item.indexedOptions.push({\n '@gindex': OIndex,\n '@index': OOIndex,\n '@findex': focusIndex,\n value: OO[item.columnKeys.optionValue],\n text: OO[item.columnKeys.optionText]\n });\n focusIndex++;\n });\n } else {\n O['@index'] = OIndex;\n O['@findex'] = focusIndex;\n po.push('
');\n if (O[item.columnKeys.optionSelected]) {\n setSelected.call(self, queIdx, O);\n }\n\n item.indexedOptions.push({\n '@index': OIndex,\n '@findex': focusIndex,\n value: O[item.columnKeys.optionValue],\n text: O[item.columnKeys.optionText]\n });\n focusIndex++;\n }\n });\n item.optionItemLength = focusIndex;\n item.$select.html(po.join(''));\n } else {\n /// select > options 태그로 스크립트 options를 만들어주는 역할\n if (item.$select.get(0).options && item.$select.get(0).options.length) item.$select.get(0).options[0].selected = false;\n elementOptions = U.toArray(item.$select.get(0).options);\n\n // select option 스크립트 생성\n newOptions = [];\n elementOptions.forEach(function (O, OIndex) {\n var option = {};\n option[item.columnKeys.optionValue] = O.value;\n option[item.columnKeys.optionText] = O.text;\n option[item.columnKeys.optionSelected] = O.selected;\n option['@index'] = OIndex;\n option['@findex'] = focusIndex;\n if (O.selected) setSelected.call(self, queIdx, option);\n newOptions.push(option);\n focusIndex++;\n\n option = null;\n });\n item.options = newOptions;\n item.indexedOptions = newOptions;\n\n item.$select.prepend('
');\n item.$select.get(0).options[0].selected = true;\n }\n\n po = null;\n elementOptions = null;\n newOptions = null;\n return item.options;\n };\n }(),\n getQueIdx = function getQueIdx(boundID) {\n if (boundID instanceof jQuery) {\n boundID = boundID.data(\"data-ax5combobox-id\");\n } else if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-ax5combobox-id\");\n }\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"getQueIdx\"));\n return;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n },\n getSelected = function getSelected(_item, o, selected) {\n if (typeof selected === \"undefined\") {\n return _item.multiple ? !o : true;\n } else {\n return selected;\n }\n },\n clearSelected = function clearSelected(queIdx) {\n this.queue[queIdx].options.forEach(function (n) {\n if (n.optgroup) {\n n.options.forEach(function (nn) {\n nn.selected = false;\n });\n } else {\n n.selected = false;\n }\n });\n },\n setOptionSelect = function () {\n var processor = {\n 'index': function index(queIdx, value, selected, setValueType) {\n // 클래스 내부에서 호출된 형태, 그런 이유로 옵션그룹에 대한 상태를 변경 하고 있다.\n var item = this.queue[queIdx];\n\n if (U.isString(value.index.gindex)) {\n if (typeof item.options[value.index.gindex] !== \"undefined\") {\n\n item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected] = getSelected(item, item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected], selected);\n\n if (self.activecomboboxOptionGroup) {\n self.activecomboboxOptionGroup.find('[data-option-group-index=\"' + value.index.gindex + '\"][data-option-index=\"' + value.index.index + '\"]').attr(\"data-option-Selected\", item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected].toString());\n }\n }\n } else {\n if (typeof item.options[value.index.index] !== \"undefined\") {\n\n item.options[value.index.index][item.columnKeys.optionSelected] = getSelected(item, item.options[value.index.index][item.columnKeys.optionSelected], selected);\n\n if (self.activecomboboxOptionGroup) {\n self.activecomboboxOptionGroup.find('[data-option-index=\"' + value.index.index + '\"]').attr(\"data-option-Selected\", item.options[value.index.index][item.columnKeys.optionSelected].toString());\n }\n }\n }\n\n if (typeof setValueType === \"undefined\" || setValueType !== \"justSetValue\") {\n syncComboboxOptions.call(this, queIdx, item.options);\n alignComboboxOptionGroup.call(this);\n }\n },\n 'arr': function arr(queIdx, values, selected, setValueType) {\n values.forEach(function (value) {\n if (U.isString(value) || U.isNumber(value)) {\n processor.text.call(self, queIdx, value, selected, \"justSetValue\");\n } else {\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(self, queIdx, value, selected, \"justSetValue\");\n break;\n }\n }\n }\n });\n\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n alignComboboxOptionGroup.call(this);\n },\n 'value': function value(queIdx, _value3, selected, setValueType) {\n var item = this.queue[queIdx];\n var addOptions;\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionValue] == _value3[item.columnKeys.optionValue];\n });\n\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n } else {\n // 새로운 값 추가\n optionIndex = item.options.length;\n addOptions = {\n \"@index\": optionIndex,\n hide: true,\n addedOption: true\n };\n addOptions[item.columnKeys.optionValue] = _value3;\n addOptions[item.columnKeys.optionText] = _value3;\n item.options.push(addOptions);\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n }\n if (typeof setValueType === \"undefined\" || setValueType !== \"justSetValue\") {\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n alignComboboxOptionGroup.call(this);\n }\n },\n 'text': function text(queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx];\n var addOptions;\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionText] == value;\n });\n\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n } else {\n // 새로운 값 추가\n optionIndex = item.options.length;\n addOptions = {\n \"@index\": optionIndex,\n hide: true,\n addedOption: true\n };\n addOptions[item.columnKeys.optionValue] = value;\n addOptions[item.columnKeys.optionText] = value;\n item.options.push(addOptions);\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n }\n if (typeof setValueType === \"undefined\" || setValueType !== \"justSetValue\") {\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n alignComboboxOptionGroup.call(this);\n }\n },\n 'clear': function clear(queIdx) {\n clearSelected.call(this, queIdx);\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n //focusLabel.call(this, queIdx);\n focusClear.call(this, queIdx);\n\n if (this.activecomboboxOptionGroup) {\n this.activecomboboxOptionGroup.find('[data-option-index]').attr(\"data-option-Selected\", \"false\");\n }\n this.queue[queIdx].optionSelectedIndex = -1;\n }\n };\n return function (boundID, value, selected, _option) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n\n if (typeof value == \"undefined\") {\n throw \"error not found value\";\n } else if (U.isArray(value)) {\n processor.clear.call(this, queIdx);\n processor.arr.call(this, queIdx, this.queue[queIdx].multiple || value.length == 0 ? value : [value[value.length - 1]], selected);\n } else if (U.isString(value) || U.isNumber(value)) {\n if (typeof value !== \"undefined\" && value !== null && !this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n processor.text.call(this, queIdx, value, selected, \"justSetValue\");\n } else {\n if (value === null) {\n processor.clear.call(this, queIdx);\n } else {\n if (!this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(this, queIdx, value, selected, \"justSetValue\");\n break;\n }\n }\n }\n }\n\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n printLabel.call(this, queIdx);\n focusLabel.call(this, queIdx);\n\n if (typeof value !== \"undefined\") {\n if (_option && !_option.noStateChange) {\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n item: this.queue[queIdx],\n state: \"changeValue\",\n value: this.queue[queIdx].selected\n });\n }\n }\n\n boundID = null;\n return this;\n };\n }();\n\n /// private end\n\n /**\n * Preferences of combobox UI\n * @method ax5combobox.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5combobox}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onChange = cfg.onChange;\n jQuery(window).bind(\"resize.ax5combobox-display-\" + this.instanceId, function () {\n alignComboboxDisplay.call(this);\n }.bind(this));\n };\n\n /**\n * bind combobox\n * @method ax5combobox.bind\n * @param {Object} item\n * @param {String} [item.id]\n * @param {String} [item.theme]\n * @param {Boolean} [item.multiple]\n * @param {Element} item.target\n * @param {Object[]} item.options\n * @returns {ax5combobox}\n */\n this.bind = function (item) {\n var bindComboboxTarget = function () {\n var debouncedFocusWord = U.debounce(function (queIdx) {\n if (this.activecomboboxQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n focusWord.call(self, queIdx, this.queue[queIdx].$displayLabelInput.val());\n }, 150);\n\n var blurLabel = function blurLabel(queIdx) {\n clearLabel.call(this, queIdx);\n };\n\n var comboboxEvent = {\n 'click': function click(queIdx, e) {\n var clickEl;\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-ax5combobox-remove\")) {\n clickEl = \"optionItemRemove\";\n return true;\n } else if (target.getAttribute(\"data-selected-clear\")) {\n clickEl = \"clear\";\n return true;\n }\n });\n\n if (target) {\n if (clickEl === \"optionItemRemove\") {\n var selectedIndex = target.getAttribute(\"data-ax5combobox-remove-index\");\n var option = this.queue[queIdx].selected[selectedIndex];\n setOptionSelect.call(this, queIdx, {\n index: {\n gindex: option['@gindex'],\n index: option['@index']\n }\n }, false, true);\n alignComboboxDisplay.call(this);\n alignComboboxOptionGroup.call(this);\n focusLabel.call(this, queIdx);\n U.stopEvent(e);\n return this;\n } else if (clickEl === \"clear\") {\n setOptionSelect.call(this, queIdx, { clear: true });\n alignComboboxDisplay.call(this);\n alignComboboxOptionGroup.call(this);\n focusLabel.call(this, queIdx);\n }\n } else {\n if (self.activecomboboxQueueIndex == queIdx) {\n if (this.queue[queIdx].optionFocusIndex == -1) {\n // 아이템에 포커스가 활성화 된 후, 마우스 이벤트 이면 무시\n self.close();\n }\n } else {\n self.open(queIdx);\n focusLabel.call(this, queIdx);\n }\n }\n },\n 'keyUp': function keyUp(queIdx, e) {\n /// 약속된 키 이벤트가 발생하면 stopEvent를 통해 keyUp 이벤트가 발생되지 않도록 막아주는 센스\n if (e.which == ax5.info.eventKeys.ESC && self.activecomboboxQueueIndex === -1) {\n // ESC키를 누르고 옵션그룹이 열려있지 않은 경우\n U.stopEvent(e);\n return this;\n }\n if (self.activecomboboxQueueIndex != queIdx) {\n // 닫힌 상태 인경우\n self.open(queIdx);\n U.stopEvent(e);\n }\n\n var disableCtrlKeys = {\n \"40\": \"KEY_DOWN\",\n \"38\": \"KEY_UP\"\n };\n if (!disableCtrlKeys[e.which]) {\n\n // backspace 감지 하여 input 값이 없으면 스탑이벤트 처리 할 것\n if (e.which == ax5.info.eventKeys.BACKSPACE && this.queue[queIdx].$displayLabelInput.val() == \"\") {\n // 마지막 아이템을 제거.\n if (this.queue[queIdx].selected.length > 0) {\n var option = this.queue[queIdx].selected[this.queue[queIdx].selected.length - 1];\n setOptionSelect.call(this, queIdx, {\n index: {\n gindex: option['@gindex'],\n index: option['@index']\n }\n }, false, true);\n }\n alignComboboxDisplay.call(this);\n alignComboboxOptionGroup.call(this);\n U.stopEvent(e);\n } else {\n debouncedFocusWord.call(this, queIdx);\n }\n }\n },\n 'keyDown': function keyDown(queIdx, e) {\n if (e.which == ax5.info.eventKeys.ESC) {\n clearLabel.call(this, queIdx);\n this.close();\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.RETURN) {\n\n setOptionSelect.call(this, item.id, {\n index: {\n gindex: item.indexedOptions[item.optionFocusIndex][\"@gindex\"],\n index: item.indexedOptions[item.optionFocusIndex][\"@index\"]\n }\n }, undefined, true);\n clearLabel.call(this, queIdx);\n alignComboboxDisplay.call(this);\n\n this.close();\n //alignComboboxOptionGroup.call(this);\n\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.DOWN) {\n focusMove.call(this, queIdx, 1);\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.UP) {\n focusMove.call(this, queIdx, -1);\n U.stopEvent(e);\n }\n },\n 'focus': function focus(queIdx, e) {\n //console.log(e);\n },\n 'blur': function blur(queIdx, e) {\n blurLabel.call(this, queIdx);\n U.stopEvent(e);\n },\n 'selectChange': function selectChange(queIdx, e) {\n setOptionSelect.call(this, queIdx, { value: this.queue[queIdx].$select.val() }, true);\n }\n };\n\n return function (queIdx) {\n var item = this.queue[queIdx];\n var data = {};\n // 현재 선택된 값을 담아두는 저장소, syncComboboxOptions를 통해 options와 selected값을 동기화 처리 한다.\n item.selected = [];\n\n if (!item.$display) {\n /// 템플릿에 전달할 오브젝트 선언\n data.instanceId = this.instanceId;\n data.id = item.id;\n data.name = item.name;\n data.theme = item.theme;\n data.tabIndex = item.tabIndex;\n data.multiple = item.multiple;\n data.reset = item.reset;\n\n data.label = getLabel.call(this, queIdx);\n data.formSize = function () {\n return item.size ? \"input-\" + item.size : \"\";\n }();\n\n //item.$display = jQuery(ax5.mustache.render(COMBOBOX.tmpl[\"comboboxDisplay\"].call(this, queIdx), data));\n item.$display = jQuery(COMBOBOX.tmpl.get.call(this, \"comboboxDisplay\", data, item.columnKeys));\n item.$displayTable = item.$display.find('[data-els=\"display-table\"]');\n item.$displayLabel = item.$display.find('[data-ax5combobox-display=\"label\"]');\n item.$displayLabelInput = item.$display.find('[data-ax5combobox-display=\"input\"]');\n\n if (item.$target.find(\"select\").get(0)) {\n item.$select = item.$target.find(\"select\");\n item.$select.attr(\"tabindex\", \"-1\").attr(\"class\", \"form-control \" + data.formSize);\n if (data.name) {\n item.$select.attr(\"name\", \"name\");\n }\n if (data.multiple) {\n item.$select.attr(\"multiple\", \"multiple\");\n }\n } else {\n //item.$select = jQuery(ax5.mustache.render(COMBOBOX.tmpl[\"formSelect\"].call(this, queIdx), data));\n item.$select = jQuery(COMBOBOX.tmpl.get.call(this, \"formSelect\", data, item.columnKeys));\n item.$target.append(item.$select);\n }\n\n item.$target.append(item.$display);\n // 라벨에 사용자 입력 필드가 있으므로 displayInput은 필요 없음.\n // select.options로 item.options를 만들어내거나 item.options로 select.options를 만들어냄\n item.options = syncComboboxOptions.call(this, queIdx, item.options);\n } else {\n item.$displayLabel.html(getLabel.call(this, queIdx));\n item.options = syncComboboxOptions.call(this, queIdx, item.options);\n }\n\n alignComboboxDisplay.call(this);\n\n item.$display.unbind('click.ax5combobox').bind('click.ax5combobox', comboboxEvent.click.bind(this, queIdx));\n\n // combobox 태그에 대한 이벤트 감시\n\n\n item.$displayLabelInput.unbind(\"focus.ax5combobox\").bind(\"focus.ax5combobox\", comboboxEvent.focus.bind(this, queIdx)).unbind(\"blur.ax5combobox\").bind(\"blur.ax5combobox\", comboboxEvent.blur.bind(this, queIdx)).unbind('keyup.ax5combobox').bind('keyup.ax5combobox', comboboxEvent.keyUp.bind(this, queIdx)).unbind(\"keydown.ax5combobox\").bind(\"keydown.ax5combobox\", comboboxEvent.keyDown.bind(this, queIdx));\n\n // select 태그에 대한 change 이벤트 감시\n\n item.$select.unbind('change.ax5combobox').bind('change.ax5combobox', comboboxEvent.selectChange.bind(this, queIdx));\n\n data = null;\n item = null;\n queIdx = null;\n return this;\n };\n }();\n\n var comboboxConfig = {},\n queIdx;\n\n item = jQuery.extend(true, comboboxConfig, cfg, item);\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5combobox\", \"401\", \"bind\"));\n return this;\n }\n\n item.$target = jQuery(item.target);\n\n if (!item.id) item.id = item.$target.data(\"data-ax5combobox-id\");\n if (!item.id) {\n item.id = 'ax5combobox-' + ax5.getGuid();\n item.$target.data(\"data-ax5combobox-id\", item.id);\n }\n item.name = item.$target.attr(\"data-ax5combobox\");\n if (item.options) {\n item.options = JSON.parse(JSON.stringify(item.options));\n }\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n item = jQuery.extend(true, item, data);\n }\n })(U.parseJson(item.$target.attr(\"data-ax5combobox-config\"), true));\n\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindComboboxTarget.call(this, this.queue.length - 1);\n } else {\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindComboboxTarget.call(this, queIdx);\n }\n\n comboboxConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * open the optionBox of combobox\n * @method ax5combobox.open\n * @param {(String|Number|Element)} boundID\n * @param {Number} [tryCount]\n * @returns {ax5combobox}\n */\n this.open = function () {\n var onExpand = function onExpand(item) {\n item.onExpand.call({\n self: this,\n item: item\n }, function (O) {\n if (this.waitOptionsCallback) {\n var data = {};\n var item = this.queue[this.activecomboboxQueueIndex];\n\n /// 현재 selected 검증후 처리\n (function (item, O) {\n var optionsMap = {};\n O.options.forEach(function (_O, _OIndex) {\n _O[\"@index\"] = _OIndex;\n optionsMap[_O[item.columnKeys.optionValue]] = _O;\n });\n if (U.isArray(item.selected)) {\n item.selected.forEach(function (_O) {\n if (optionsMap[_O[item.columnKeys.optionValue]]) {\n O.options[optionsMap[_O[item.columnKeys.optionValue]][\"@index\"]][item.columnKeys.optionSelected] = true;\n }\n });\n }\n })(item, O);\n\n item.options = syncComboboxOptions.call(this, this.activecomboboxQueueIndex, O.options);\n printLabel.call(this, this.activecomboboxQueueIndex);\n alignComboboxDisplay.call(this);\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5combobox-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n /*\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(\n ax5.mustache.render(COMBOBOX.tmpl[\"options\"].call(this, item.columnKeys), data)\n ));\n */\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(COMBOBOX.tmpl.get.call(this, \"options\", data, item.columnKeys)));\n }\n }.bind(this));\n };\n return function (boundID, tryCount) {\n this.waitOptionsCallback = null;\n\n /**\n * open combobox from the outside\n */\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n var data = {},\n focusTop,\n selectedOptionEl;\n\n if (item.$display.attr(\"disabled\")) return this;\n\n if (this.openTimer) clearTimeout(this.openTimer);\n if (this.activecomboboxOptionGroup) {\n if (this.activecomboboxQueueIndex == queIdx) {\n return this;\n }\n\n if (tryCount > 2) return this;\n this.close();\n this.openTimer = setTimeout(function () {\n this.open(queIdx, (tryCount || 0) + 1);\n }.bind(this), cfg.animateTime);\n\n return this;\n }\n\n item.optionFocusIndex = -1; // optionGroup이 열리면 포커스 인덱스 초기화 -1로\n if (item.selected && item.selected.length > 0) {\n item.optionSelectedIndex = item.selected[0][\"@findex\"];\n }\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5combobox-option-group-\" + item.size;\n data.multiple = item.multiple;\n\n data.lang = item.lang;\n item.$display.attr(\"data-combobox-option-group-opened\", \"true\");\n\n if (item.onExpand) {\n // onExpand 인 경우 UI 대기모드 추가\n data.waitOptions = true;\n }\n data.options = U.filter(item.options, function () {\n return !this.hide;\n });\n\n //this.activecomboboxOptionGroup = jQuery(ax5.mustache.render(COMBOBOX.tmpl[\"optionGroup\"].call(this, item.columnKeys), data));\n this.activecomboboxOptionGroup = jQuery(COMBOBOX.tmpl.get.call(this, \"optionGroup\", data, item.columnKeys));\n //this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(ax5.mustache.render(COMBOBOX.tmpl[\"options\"].call(this, item.columnKeys), data)));\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(COMBOBOX.tmpl.get.call(this, \"options\", data, item.columnKeys)));\n this.activecomboboxQueueIndex = queIdx;\n\n alignComboboxOptionGroup.call(this, \"append\"); // alignComboboxOptionGroup 에서 body append\n jQuery(window).bind(\"resize.ax5combobox-\" + this.instanceId, function () {\n alignComboboxOptionGroup.call(this);\n }.bind(this));\n\n if (item.selected && item.selected.length > 0) {\n selectedOptionEl = this.activecomboboxOptionGroup.find('[data-option-index=\"' + item.selected[0][\"@index\"] + '\"]');\n if (selectedOptionEl.get(0)) {\n focusTop = selectedOptionEl.position().top - this.activecomboboxOptionGroup.height() / 3;\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').stop().animate({ scrollTop: focusTop }, item.animateTime, 'swing', function () {});\n }\n }\n\n jQuery(window).bind(\"click.ax5combobox-\" + this.instanceId, function (e) {\n e = e || window.event;\n onBodyClick.call(this, e);\n U.stopEvent(e);\n }.bind(this));\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"open\",\n item: item\n });\n\n // waitOption timer\n if (item.onExpand) {\n this.waitOptionsCallback = true;\n onExpand.call(this, item);\n }\n\n data = null;\n focusTop = null;\n selectedOptionEl = null;\n return this;\n };\n }();\n\n /**\n * @method ax5combobox.update\n * @param {(Object|String)} item\n * @returns {ax5combobox}\n */\n this.update = function (_item) {\n this.bind(_item);\n return this;\n };\n\n /**\n * @method ax5combobox.setValue\n * @param {(jQueryObject|Element|Number)} _boundID\n * @param {(String|Array)} _value\n * @param {Boolean} [_selected]\n * @return {ax5combobox}\n * @example\n * ```js\n * myCombo.setValue($('[data-ax5combobox=\"combo1\"]'), \"1\");\n * myCombo.setValue($('[data-ax5combobox=\"combo1\"]'), [\"1\", \"2\"]);\n * ```\n */\n this.setValue = function (_boundID, _value, _selected) {\n var queIdx = U.isNumber(_boundID) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n\n clearSelected.call(this, queIdx);\n\n if (U.isArray(_value)) {\n var _values = U.map(_value, function () {\n return { value: this };\n });\n setOptionSelect.call(this, queIdx, _values, _selected || true, { noStateChange: true });\n } else if (U.isString(_value) || U.isNumber(_value)) {\n setOptionSelect.call(this, queIdx, { value: _value }, _selected || true, { noStateChange: true });\n } else {\n printLabel.call(this, queIdx);\n }\n\n blurLabel.call(this, queIdx);\n alignComboboxDisplay.call(this);\n\n return this;\n };\n\n /**\n * @method ax5combobox.setText\n * @param {(jQueryObject|Element|Number)} _boundID\n * @param {(String|Array)} _text\n * @param {Boolean} [_selected]\n * @returns {ax5combobox}\n * @example\n * ```js\n * myCombo.setText($('[data-ax5combobox=\"combo1\"]'), \"string\");\n * myCombo.setText($('[data-ax5combobox=\"combo1\"]'), [\"substring\", \"search\"]);\n * ```\n */\n this.setText = function (_boundID, _text, _selected) {\n var queIdx = U.isNumber(_boundID) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n clearSelected.call(this, queIdx);\n setOptionSelect.call(this, queIdx, _text, true, { noStateChange: true });\n blurLabel.call(this, queIdx);\n alignComboboxDisplay.call(this);\n\n return this;\n };\n\n /**\n * @method ax5combobox.getSelectedOption\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {Array}\n */\n this.getSelectedOption = function (_boundID) {\n var queIdx = U.isNumber(_boundID) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n return U.deepCopy(this.queue[queIdx].selected);\n };\n\n /**\n * @method ax5combobox.close\n * @returns {ax5combobox}\n */\n this.close = function (item) {\n if (this.closeTimer) clearTimeout(this.closeTimer);\n if (!this.activecomboboxOptionGroup) return this;\n\n item = this.queue[this.activecomboboxQueueIndex];\n item.optionFocusIndex = -1;\n item.$display.removeAttr(\"data-combobox-option-group-opened\").trigger(\"focus\");\n item.$displayLabel.attr(\"contentEditable\", \"false\");\n\n this.activecomboboxOptionGroup.addClass(\"destroy\");\n\n jQuery(window).unbind(\"resize.ax5combobox-\" + this.instanceId).unbind(\"click.ax5combobox-\" + this.instanceId).unbind(\"keyup.ax5combobox-\" + this.instanceId);\n\n this.closeTimer = setTimeout(function () {\n if (this.activecomboboxOptionGroup) this.activecomboboxOptionGroup.remove();\n this.activecomboboxOptionGroup = null;\n this.activecomboboxQueueIndex = -1;\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"close\"\n });\n }.bind(this), cfg.animateTime);\n this.waitOptionsCallback = null;\n return this;\n };\n\n /**\n * @method ax5combobox.blur\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5combobox}\n */\n this.blur = function (_boundID) {\n var queIdx = U.isNumber(_boundID) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n\n blurLabel.call(this, queIdx);\n return this;\n };\n\n /**\n * @method ax5combobox.enable\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5combobox}\n */\n this.enable = function (_boundID) {\n var queIdx = getQueIdx.call(this, _boundID);\n\n if (typeof queIdx !== \"undefined\") {\n this.queue[queIdx].disabled = false;\n if (this.queue[queIdx].$display[0]) {\n this.queue[queIdx].$display.removeAttr(\"disabled\");\n this.queue[queIdx].$displayLabelInput.removeAttr(\"disabled\");\n }\n if (this.queue[queIdx].$select[0]) {\n this.queue[queIdx].$select.removeAttr(\"disabled\");\n }\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"enable\"\n });\n }\n\n return this;\n };\n\n /**\n * @method ax5combobox.disable\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5combobox}\n */\n this.disable = function (_boundID) {\n var queIdx = getQueIdx.call(this, _boundID);\n\n if (typeof queIdx !== \"undefined\") {\n this.queue[queIdx].disabled = true;\n if (this.queue[queIdx].$display[0]) {\n this.queue[queIdx].$display.attr(\"disabled\", \"disabled\");\n this.queue[queIdx].$displayLabelInput.attr(\"disabled\", \"disabled\");\n }\n if (this.queue[queIdx].$select[0]) {\n this.queue[queIdx].$select.attr(\"disabled\", \"disabled\");\n }\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"disable\"\n });\n }\n return this;\n };\n\n /**\n * @method ax5combobox.align\n */\n this.align = function () {\n alignComboboxDisplay.call(this);\n return this;\n };\n\n // 클래스 생성자\n this.main = function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n } else {\n this.init();\n }\n }.apply(this, arguments);\n };\n return ax5combobox;\n }());\n\n COMBOBOX = ax5.ui.combobox;\n})();\n\n/**\n * ax5combobox jquery extends\n * @namespace jQueryExtends\n */\n\n/**\n * @method jQueryExtends.ax5combobox\n * @param {String} methodName\n * @param [arguments]\n * @param [arguments]\n * @example\n * ```html\n *
\n * \n * ```\n */\n\nax5.ui.combobox_instance = new ax5.ui.combobox();\njQuery.fn.ax5combobox = function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"open\":\n return ax5.ui.combobox_instance.open(this);\n break;\n case \"close\":\n return ax5.ui.combobox_instance.close(this);\n break;\n case \"setValue\":\n return ax5.ui.combobox_instance.setValue(this, arguments[1], arguments[2], arguments[3], arguments[4] || \"justSetValue\");\n break;\n case \"setText\":\n return ax5.ui.combobox_instance.setText(this, arguments[1], arguments[2], arguments[3], arguments[4] || \"justSetValue\");\n break;\n case \"getSelectedOption\":\n return ax5.ui.combobox_instance.getSelectedOption(this);\n break;\n case \"enable\":\n return ax5.ui.combobox_instance.enable(this);\n break;\n case \"disable\":\n return ax5.ui.combobox_instance.disable(this);\n break;\n case \"blur\":\n return ax5.ui.combobox_instance.blur(this);\n default:\n return this;\n }\n } else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.combobox_instance.bind(config);\n });\n }\n return this;\n };\n}();\n\n// ax5.ui.combobox.tmpl\n(function () {\n\n var COMBOBOX = ax5.ui.combobox;\n var U = ax5.util;\n\n var optionGroup = function optionGroup(columnKeys) {\n return '\\n
\\n ';\n };\n\n var comboboxDisplay = function comboboxDisplay(columnKeys) {\n return '\\n
\\n ';\n };\n\n var formSelect = function formSelect(columnKeys) {\n return '\\n
\\n ';\n };\n\n var formSelectOptions = function formSelectOptions(columnKeys) {\n return '\\n{{#selected}}\\n
\\n{{/selected}}\\n';\n };\n\n var options = function options(columnKeys) {\n return '\\n {{#waitOptions}}\\n
\\n
\\n \\n {{{lang.loading}}}\\n \\n
\\n
\\n {{/waitOptions}}\\n {{^waitOptions}}\\n {{#options}}\\n {{#optgroup}}\\n
\\n
\\n \\n {{{.}}}\\n \\n
\\n {{#options}}\\n {{^hide}}\\n
\\n
\\n {{#multiple}}\\n \\n \\n \\n {{/multiple}}\\n {{' + columnKeys.optionText + '}}\\n
\\n
\\n {{/hide}}\\n {{/options}}\\n
\\n {{/optgroup}}\\n {{^optgroup}}\\n {{^hide}}\\n
\\n
\\n {{#multiple}}\\n \\n \\n \\n {{/multiple}}\\n {{' + columnKeys.optionText + '}}\\n
\\n
\\n {{/hide}}\\n {{/optgroup}}\\n {{/options}}\\n {{^options}}\\n
\\n
\\n \\n {{{lang.noOptions}}}\\n \\n
\\n
\\n {{/options}}\\n {{/waitOptions}}\\n ';\n };\n\n var label = function label(columnKeys) {\n return '{{#selected}}
{{/selected}}';\n };\n\n COMBOBOX.tmpl = {\n \"comboboxDisplay\": comboboxDisplay,\n \"formSelect\": formSelect,\n \"formSelectOptions\": formSelectOptions,\n \"optionGroup\": optionGroup,\n \"options\": options,\n \"label\": label,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(COMBOBOX.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();\n/*\n * Copyright (c) 2016. tom@axisj.com\n * - github.com/thomasjang\n * - www.axisj.com\n */\n\n// ax5.ui.combobox.util\n(function () {\n\n var COMBOBOX = ax5.ui.combobox;\n var U = ax5.util;\n\n var nodeTypeProcessor = {\n '1': function _(queIdx, node, editable) {\n var cfg = this.config;\n var textNode = node;\n\n if ($(node).find(\"span\").get(0)) {\n textNode = $(node).find(\"span\").get(0);\n }\n\n var text = (textNode.textContent || textNode.innerText).replace(/^[\\s\\r\\n\\t]*|[\\s\\r\\n\\t]*$/g, '');\n var item = this.queue[queIdx];\n\n var selectedIndex, option;\n if (item.selected && item.selected.length > 0 && node.getAttribute(\"data-ax5combobox-selected-text\") == text) {\n selectedIndex = node.getAttribute(\"data-ax5combobox-selected-label\");\n option = item.selected[selectedIndex];\n return {\n index: {\n gindex: option[\"@gindex\"],\n index: option[\"@index\"],\n value: option[cfg.columnKeys.optionValue]\n }\n };\n } else if (!node.getAttribute(\"data-ax5combobox-selected-text\")) {\n if (text != \"\") {\n if (editable) {\n return text;\n } else {\n var $option;\n if (item.optionFocusIndex > -1) $option = this.activecomboboxOptionGroup.find('[data-option-focus-index=\"' + item.optionFocusIndex + '\"]');\n if (item.optionFocusIndex > -1 && $option.get(0) && $option.attr(\"data-option-value\")) {\n return {\n index: {\n gindex: $option.attr(\"data-option-group-index\"),\n index: $option.attr(\"data-option-index\")\n }\n };\n } else {\n return item.editable ? text : undefined;\n }\n }\n } else {\n return undefined;\n }\n } else {\n return text;\n }\n },\n '3': function _(queIdx, node, editable) {\n var cfg = this.config;\n var text = (node.textContent || node.innerText).replace(/^[\\s\\r\\n\\t]*|[\\s\\r\\n\\t]*$/g, '');\n var item = this.queue[queIdx];\n\n if (text != \"\") {\n if (editable) {\n return text;\n } else {\n var $option;\n if (item.optionFocusIndex > -1) $option = this.activecomboboxOptionGroup.find('[data-option-focus-index=\"' + item.optionFocusIndex + '\"]');\n if (item.optionFocusIndex > -1 && $option.get(0) && $option.attr(\"data-option-value\")) {\n return {\n index: {\n gindex: $option.attr(\"data-option-group-index\"),\n index: $option.attr(\"data-option-index\")\n }\n };\n } else {\n return item.editable ? text : undefined;\n }\n }\n } else {\n return undefined;\n }\n }\n };\n\n COMBOBOX.util = {\n nodeTypeProcessor: nodeTypeProcessor\n };\n})();\n// ax5.ui.layout\n(function () {\n var UI = ax5.ui;\n var U = ax5.util;\n\n UI.addClass({\n className: \"layout\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5layout\n * @alias ax5.ui.layout\n * @author tom@axisj.com\n * @example\n * ```js\n * jQuery('[data-ax5layout=\"ax1\"]').ax5layout({\n * onResize: function () {\n * }\n * });\n *\n * jQuery('[data-ax5layout=\"ax1\"]').ax5layout(\"resize\", {\n * top: {height: 100},\n * bottom: 100,\n * left: 100,\n * right: 100\n * });\n * ```\n */\n var ax5layout = function ax5layout() {\n var self = this,\n cfg,\n ENM = {\n \"mousedown\": ax5.info.supportTouch ? \"touchstart\" : \"mousedown\",\n \"mousemove\": ax5.info.supportTouch ? \"touchmove\" : \"mousemove\",\n \"mouseup\": ax5.info.supportTouch ? \"touchend\" : \"mouseup\"\n },\n getMousePosition = function getMousePosition(e) {\n var mouseObj = 'changedTouches' in e.originalEvent ? e.originalEvent.changedTouches[0] : e;\n return {\n clientX: mouseObj.clientX,\n clientY: mouseObj.clientY\n };\n };\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 250,\n splitter: {\n size: 4\n },\n autoResize: true\n };\n this.queue = [];\n\n this.openTimer = null;\n this.closeTimer = null;\n this.resizer = null;\n\n cfg = this.config;\n\n var onStateChanged = function onStateChanged(opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n return true;\n },\n alignLayoutAll = function alignLayoutAll() {\n var i = this.queue.length;\n while (i--) {\n if (typeof this.queue[i].parentQueIdx === \"undefined\" && this.queue[i].autoResize) {\n alignLayout.call(this, i, null, \"windowResize\");\n }\n }\n },\n getDockPanelOuterSize = {\n \"width\": function width(item, panel) {\n return panel ? panel.__width + (panel.split ? item.splitter.size : 0) : 0;\n },\n \"height\": function height(item, panel) {\n return panel ? panel.__height + (panel.split ? item.splitter.size : 0) : 0;\n }\n },\n getPixel = function getPixel(size, parentSize) {\n if (size == \"*\") {\n return;\n } else if (U.right(size, 1) == \"%\") {\n return parentSize * U.number(size) / 100;\n } else {\n return Number(size);\n }\n },\n alignLayout = function () {\n\n var beforeSetCSS = {\n \"split\": {\n \"horizontal\": function horizontal(item, panel, panelIndex) {\n if (panel.splitter) {\n panel.__height = item.splitter.size;\n } else {\n if (panelIndex == item.splitPanel.length - 1) {\n if (item.splitPanel.asteriskLength == 0) {\n panel.height = \"*\";\n panel.__height = undefined;\n item.splitPanel.asteriskLength++;\n } else {\n if (panel.height == \"*\") {\n item.splitPanel.asteriskLength++;\n } else {\n //panel.__height = getPixel(panel.height, item.targetDimension.height);\n }\n }\n } else {\n if (panel.height == \"*\") {\n item.splitPanel.asteriskLength++;\n } else {\n //panel.__height = getPixel(panel.height, item.targetDimension.height);\n }\n }\n }\n },\n \"vertical\": function vertical(item, panel, panelIndex) {\n if (panel.splitter) {\n panel.__width = item.splitter.size;\n } else {\n if (panelIndex == item.splitPanel.length - 1) {\n if (item.splitPanel.asteriskLength == 0) {\n panel.width = \"*\";\n panel.__width = undefined;\n item.splitPanel.asteriskLength++;\n } else {\n if (panel.width == \"*\") {\n item.splitPanel.asteriskLength++;\n }\n }\n } else {\n if (panel.width == \"*\") {\n item.splitPanel.asteriskLength++;\n } else {\n //panel.__width = getPixel(panel.width, item.targetDimension.width);\n }\n }\n }\n }\n }\n };\n var setCSS = {\n \"top\": function top(item, panel) {\n panel.$target.css({ height: panel.__height || 0 });\n if (panel.split) {\n panel.$splitter.css({ height: item.splitter.size, top: panel.__height || 0 });\n }\n },\n \"bottom\": function bottom(item, panel) {\n panel.$target.css({ height: panel.__height || 0 });\n if (panel.split) {\n panel.$splitter.css({ height: item.splitter.size, bottom: panel.__height || 0 });\n }\n },\n \"left\": function left(item, panel) {\n var css = {\n width: panel.__width || 0,\n height: item.targetDimension.height\n };\n\n if (item.dockPanel.top) {\n css.height -= item.dockPanel.top.__height;\n css.top = item.dockPanel.top.__height;\n if (item.dockPanel.top.split) {\n css.height -= item.splitter.size;\n css.top += item.splitter.size;\n }\n }\n if (item.dockPanel.bottom) {\n css.height -= item.dockPanel.bottom.__height;\n if (item.dockPanel.bottom.split) {\n css.height -= item.splitter.size;\n }\n }\n\n panel.$target.css(css);\n\n if (panel.split) {\n panel.$splitter.css({ width: item.splitter.size, height: css.height, top: css.top, left: css.width });\n }\n },\n \"right\": function right(item, panel) {\n var css = {\n width: panel.__width || 0,\n height: item.targetDimension.height\n };\n\n if (item.dockPanel.top) {\n css.height -= item.dockPanel.top.__height;\n css.top = item.dockPanel.top.__height;\n if (item.dockPanel.top.split) {\n css.height -= item.splitter.size;\n css.top += item.splitter.size;\n }\n }\n if (item.dockPanel.bottom) {\n css.height -= item.dockPanel.bottom.__height;\n if (item.dockPanel.bottom.split) {\n css.height -= item.splitter.size;\n }\n }\n\n panel.$target.css(css);\n\n if (panel.split) {\n panel.$splitter.css({ width: item.splitter.size, height: css.height, top: css.top, right: css.width });\n }\n },\n \"center\": function center(item, panel) {\n var css = {\n width: item.targetDimension.width,\n height: item.targetDimension.height\n };\n\n if (item.dockPanel.top) {\n css.height -= item.dockPanel.top.__height || 0;\n css.top = item.dockPanel.top.__height || 0;\n if (item.dockPanel.top.split) {\n css.height -= item.splitter.size;\n css.top += item.splitter.size;\n }\n }\n if (item.dockPanel.bottom) {\n css.height -= item.dockPanel.bottom.__height || 0;\n if (item.dockPanel.bottom.split) {\n css.height -= item.splitter.size;\n }\n }\n if (item.dockPanel.left) {\n css.width -= item.dockPanel.left.__width || 0;\n css.left = item.dockPanel.left.__width || 0;\n if (item.dockPanel.left.split) {\n css.width -= item.splitter.size;\n css.left += item.splitter.size;\n }\n }\n if (item.dockPanel.right) {\n css.width -= item.dockPanel.right.__width || 0;\n if (item.dockPanel.right.split) {\n css.width -= item.splitter.size;\n }\n }\n\n var minWidth = panel.minWidth || 0;\n var minHeight = panel.minHeight || 0;\n\n // 레이아웃의 최소 너비 높이를 주어 레이아웃 덕패널이 겹치는 일이 없게 합니다\n if (css.width < minWidth) {\n css.width = minWidth;\n item.$target.css({ minWidth: minWidth + getDockPanelOuterSize[\"width\"](item.dockPanel.left, item.splitter.size) + getDockPanelOuterSize[\"width\"](item.dockPanel.right, item.splitter.size) });\n }\n if (css.height < minHeight) {\n css.height = minHeight;\n item.$target.css({ minHeight: minHeight + getDockPanelOuterSize[\"height\"](item.dockPanel.top, item.splitter.size) + getDockPanelOuterSize[\"height\"](item.dockPanel.bottom, item.splitter.size) });\n }\n\n panel.$target.css(css);\n },\n \"split\": {\n \"horizontal\": function horizontal(item, panel, panelIndex, withoutAsteriskSize, windowResize) {\n var css = {\n display: \"block\"\n };\n var prevPosition = panelIndex ? Number(item.splitPanel[panelIndex - 1].offsetEnd) : 0;\n if (panel.splitter) {\n css.height = item.splitter.size;\n } else {\n if (panel.height == \"*\" && (typeof panel.__height === \"undefined\" || windowResize)) {\n // 남은 전체 공간을 사용\n css.height = panel.__height = (item.targetDimension.height - withoutAsteriskSize) / item.splitPanel.asteriskLength;\n } else {\n css.height = panel.__height || 0;\n }\n }\n css.top = prevPosition;\n panel.offsetStart = prevPosition;\n panel.offsetEnd = Number(prevPosition) + Number(css.height);\n panel.$target.css(css);\n },\n \"vertical\": function vertical(item, panel, panelIndex, withoutAsteriskSize, windowResize) {\n var css = {\n display: \"block\"\n };\n var prevPosition = panelIndex ? Number(item.splitPanel[panelIndex - 1].offsetEnd) : 0;\n\n if (panel.splitter) {\n css.width = item.splitter.size;\n } else {\n if (panel.width == \"*\" && (typeof panel.__width === \"undefined\" || windowResize)) {\n // 남은 전체 공간을 사용\n css.width = panel.__width = (item.targetDimension.width - withoutAsteriskSize) / item.splitPanel.asteriskLength;\n } else {\n css.width = panel.__width || 0;\n }\n }\n css.left = prevPosition;\n panel.offsetStart = prevPosition;\n panel.offsetEnd = Number(prevPosition) + Number(css.width);\n\n panel.$target.css(css);\n }\n }\n };\n var layoutProcessor = {\n \"dock-panel\": function dockPanel(item) {\n for (var panel in item.dockPanel) {\n if (item.dockPanel[panel].$target && item.dockPanel[panel].$target.get(0)) {\n if (panel in setCSS) {\n setCSS[panel].call(this, item, item.dockPanel[panel]);\n }\n }\n }\n },\n \"split-panel\": function splitPanel(item, windowResize) {\n //console.log(item.splitPanel);\n var withoutAsteriskSize;\n item.splitPanel.asteriskLength = 0;\n item.splitPanel.forEach(function (panel, panelIndex) {\n beforeSetCSS[\"split\"][item.orientation].call(this, item, panel, panelIndex);\n });\n\n if (item.orientation == \"horizontal\") {\n withoutAsteriskSize = U.sum(item.splitPanel, function (n) {\n if (n.height != \"*\") return U.number(n.__height);\n });\n } else {\n withoutAsteriskSize = U.sum(item.splitPanel, function (n) {\n if (n.width != \"*\") return U.number(n.__width);\n });\n }\n\n item.splitPanel.forEach(function (panel, panelIndex) {\n setCSS[\"split\"][item.orientation].call(this, item, panel, panelIndex, withoutAsteriskSize, windowResize);\n });\n }\n };\n var childResize = function childResize(item) {\n var i = item.childQueIdxs.length;\n while (i--) {\n alignLayout.call(this, item.childQueIdxs[i]);\n }\n };\n\n return function (queIdx, callback, windowResize) {\n var item = this.queue[queIdx];\n\n // 레이아웃 타겟의 CSS속성을 미리 저장해 둡니다. 왜? 패널별로 크기 계산 할 때 쓰려고\n item.targetDimension = {\n height: item.$target.innerHeight(),\n width: item.$target.innerWidth()\n };\n\n if (item.layout in layoutProcessor) {\n layoutProcessor[item.layout].call(this, item, windowResize);\n }\n\n if (item.childQueIdxs) childResize.call(this, item, windowResize);\n if (item.onResize) {\n setTimeout(function () {\n this.onResize.call(this, this);\n }.bind(item), 1);\n }\n if (callback) {\n callback.call(item, item);\n }\n };\n }(),\n resizeSplitter = {\n \"on\": function on(queIdx, panel, $splitter) {\n var item = this.queue[queIdx];\n var splitterOffset = $splitter.position();\n var splitterBox = {\n width: $splitter.width(), height: $splitter.height()\n };\n var getResizerPosition = {\n \"left\": function left(e) {\n var mouseObj = 'changedTouches' in e.originalEvent ? e.originalEvent.changedTouches[0] : e;\n\n panel.__da = mouseObj.clientX - panel.mousePosition.clientX;\n var minWidth = panel.minWidth || 0;\n var maxWidth = panel.maxWidth || item.targetDimension.width - getDockPanelOuterSize[\"width\"](item, item.dockPanel.left) - getDockPanelOuterSize[\"width\"](item, item.dockPanel.right);\n\n if (panel.__width + panel.__da < minWidth) {\n panel.__da = -panel.__width + minWidth;\n } else if (maxWidth < panel.__width + panel.__da) {\n panel.__da = maxWidth - panel.__width;\n }\n return { left: panel.$splitter.position().left + panel.__da };\n },\n \"right\": function right(e) {\n var mouseObj = 'changedTouches' in e.originalEvent ? e.originalEvent.changedTouches[0] : e;\n\n panel.__da = mouseObj.clientX - panel.mousePosition.clientX;\n var minWidth = panel.minWidth || 0;\n var maxWidth = panel.maxWidth || item.targetDimension.width - getDockPanelOuterSize[\"width\"](item, item.dockPanel.left) - getDockPanelOuterSize[\"width\"](item, item.dockPanel.right);\n\n if (panel.__width - panel.__da < minWidth) {\n panel.__da = panel.__width - minWidth;\n } else if (maxWidth < panel.__width - panel.__da) {\n panel.__da = -maxWidth + panel.__width;\n }\n return { left: panel.$splitter.position().left + panel.__da };\n },\n \"top\": function top(e) {\n var mouseObj = 'changedTouches' in e.originalEvent ? e.originalEvent.changedTouches[0] : e;\n\n panel.__da = mouseObj.clientY - panel.mousePosition.clientY;\n var minHeight = panel.minHeight || 0;\n var maxHeight = panel.maxHeight || item.targetDimension.height - getDockPanelOuterSize[\"height\"](item, item.dockPanel.top) - getDockPanelOuterSize[\"height\"](item, item.dockPanel.bottom);\n\n if (panel.__height + panel.__da < minHeight) {\n panel.__da = -panel.__height + minHeight;\n } else if (maxHeight < panel.__height + panel.__da) {\n panel.__da = maxHeight - panel.__height;\n }\n return { top: panel.$splitter.position().top + panel.__da };\n },\n \"bottom\": function bottom(e) {\n var mouseObj = 'changedTouches' in e.originalEvent ? e.originalEvent.changedTouches[0] : e;\n\n panel.__da = mouseObj.clientY - panel.mousePosition.clientY;\n var minHeight = panel.minHeight || 0;\n var maxHeight = panel.maxHeight || item.targetDimension.height - getDockPanelOuterSize[\"height\"](item, item.dockPanel.top) - getDockPanelOuterSize[\"height\"](item, item.dockPanel.bottom);\n\n if (panel.__height - panel.__da < minHeight) {\n panel.__da = panel.__height - minHeight;\n } else if (maxHeight < panel.__height - panel.__da) {\n panel.__da = -maxHeight + panel.__height;\n }\n return { top: panel.$splitter.position().top + panel.__da };\n },\n \"split\": function split(e) {\n var mouseObj = 'changedTouches' in e.originalEvent ? e.originalEvent.changedTouches[0] : e;\n\n if (item.orientation == \"horizontal\") {\n panel.__da = mouseObj.clientY - panel.mousePosition.clientY;\n\n var prevPanel = item.splitPanel[panel.panelIndex - 1];\n var nextPanel = item.splitPanel[panel.panelIndex + 1];\n\n var prePanelMinHeight = prevPanel.minHeight || 0;\n var nextPanelMinHeight = nextPanel.minHeight || 0;\n\n if (panel.offsetStart + panel.__da < prevPanel.offsetStart + prePanelMinHeight) {\n panel.__da = prevPanel.offsetStart - panel.offsetStart + prePanelMinHeight;\n } else if (panel.offsetStart + panel.__da > nextPanel.offsetEnd - nextPanelMinHeight) {\n panel.__da = nextPanel.offsetEnd - panel.offsetEnd - nextPanelMinHeight;\n }\n\n return { top: panel.$target.position().top + panel.__da };\n } else {\n /// todo : min & max 범위 정하기\n panel.__da = mouseObj.clientX - panel.mousePosition.clientX;\n\n var prevPanel = item.splitPanel[panel.panelIndex - 1];\n var nextPanel = item.splitPanel[panel.panelIndex + 1];\n var prePanelMinWidth = prevPanel.minWidth || 0;\n var nextPanelMinWidth = nextPanel.minWidth || 0;\n\n if (panel.offsetStart + panel.__da < prevPanel.offsetStart + prePanelMinWidth) {\n panel.__da = prevPanel.offsetStart - panel.offsetStart + prePanelMinWidth;\n } else if (panel.offsetStart + panel.__da > nextPanel.offsetEnd - nextPanelMinWidth) {\n panel.__da = nextPanel.offsetEnd - panel.offsetEnd - nextPanelMinWidth;\n }\n return { left: Number(panel.$target.position().left) + Number(panel.__da) };\n }\n }\n };\n panel.__da = 0; // 패널의 변화량\n\n jQuery(document.body).bind(ENM[\"mousemove\"] + \".ax5layout-\" + this.instanceId, function (e) {\n if (!self.resizer) {\n\n self.resizer = jQuery('
');\n self.resizer.css({\n left: splitterOffset.left,\n top: splitterOffset.top,\n width: splitterBox.width,\n height: splitterBox.height\n });\n item.$target.append(self.resizer);\n }\n self.resizer.css(getResizerPosition[panel.resizerType](e));\n }).bind(ENM[\"mouseup\"] + \".ax5layout-\" + this.instanceId, function (e) {\n resizeSplitter.off.call(self, queIdx, panel, $splitter);\n }).bind(\"mouseleave.ax5layout-\" + this.instanceId, function (e) {\n resizeSplitter.off.call(self, queIdx, panel, $splitter);\n });\n\n jQuery(document.body).attr('unselectable', 'on').css('user-select', 'none').on('selectstart', false);\n },\n \"off\": function off(queIdx, panel, $splitter) {\n var item = this.queue[queIdx];\n var setPanelSize = {\n \"dock-panel\": {\n \"left\": function left(queIdx, panel) {\n panel.__width += panel.__da;\n },\n \"right\": function right() {\n panel.__width -= panel.__da;\n },\n \"top\": function top() {\n panel.__height += panel.__da;\n },\n \"bottom\": function bottom() {\n panel.__height -= panel.__da;\n }\n },\n \"split-panel\": {\n \"split\": function split() {\n if (item.orientation == \"horizontal\") {\n // 앞과 뒤의 높이 조절\n item.splitPanel[panel.panelIndex - 1].__height += panel.__da;\n item.splitPanel[panel.panelIndex + 1].__height -= panel.__da;\n } else {\n // 앞과 뒤의 높이 조절\n\n item.splitPanel[panel.panelIndex - 1].__width += panel.__da;\n item.splitPanel[panel.panelIndex + 1].__width -= panel.__da;\n }\n }\n },\n \"tab-panel\": {}\n };\n\n if (self.resizer) {\n self.resizer.remove();\n self.resizer = null;\n setPanelSize[this.queue[queIdx].layout][panel.resizerType].call(this, queIdx, panel);\n alignLayout.call(this, queIdx);\n }\n\n jQuery(document.body).unbind(ENM[\"mousemove\"] + \".ax5layout-\" + this.instanceId).unbind(ENM[\"mouseup\"] + \".ax5layout-\" + this.instanceId).unbind(\"mouseleave.ax5layout-\" + this.instanceId);\n\n jQuery(document.body).removeAttr('unselectable').css('user-select', 'auto').off('selectstart');\n }\n },\n tabControl = {\n \"open\": function open(queIdx, layout, panelIndex) {\n if (layout.activePanelIndex != panelIndex) {\n layout.tabPanel[panelIndex].active = true;\n layout.tabPanel[layout.activePanelIndex].active = false;\n layout.$target.find('[data-tab-panel-label=\"' + panelIndex + '\"]').attr(\"data-tab-active\", \"true\");\n layout.$target.find('[data-tab-panel-label=\"' + layout.activePanelIndex + '\"]').removeAttr(\"data-tab-active\");\n layout.tabPanel[panelIndex].$target.attr(\"data-tab-active\", \"true\");\n layout.tabPanel[layout.activePanelIndex].$target.removeAttr(\"data-tab-active\");\n layout.activePanelIndex = panelIndex;\n\n if (layout.onOpenTab) {\n var that = {\n '$target': layout.$target,\n name: layout.name,\n id: layout.id,\n layout: layout.layout,\n activePanelIndex: layout.activePanelIndex,\n activePanel: layout.tabPanel[layout.activePanelIndex],\n tabPanel: layout.tabPanel\n };\n layout.onOpenTab.call(that);\n }\n }\n }\n },\n getTabLabesTmpl = function getTabLabesTmpl() {\n return '\\n
\\n
\\n
\\n
\\n {{#tabPanel}}\\n
\\n {{/tabPanel}}\\n
\\n
\\n
\\n';\n },\n bindLayoutTarget = function () {\n\n var applyLayout = {\n \"dock-panel\": function dockPanel(queIdx) {\n var item = this.queue[queIdx];\n item.dockPanel = {};\n item.$target.find('>[data-dock-panel]').each(function () {\n\n var panelInfo = {};\n (function (data) {\n if (U.isObject(data) && !data.error) {\n panelInfo = jQuery.extend(true, panelInfo, data);\n }\n })(U.parseJson(this.getAttribute(\"data-dock-panel\"), true));\n\n if ('dock' in panelInfo) {\n panelInfo.$target = jQuery(this);\n panelInfo.$target.addClass(\"dock-panel-\" + panelInfo.dock);\n\n if (panelInfo.split = panelInfo.split && panelInfo.split.toString() == \"true\") {\n panelInfo.$splitter = jQuery('
');\n panelInfo.$splitter.bind(ENM[\"mousedown\"], function (e) {\n panelInfo.mousePosition = getMousePosition(e);\n resizeSplitter.on.call(self, queIdx, panelInfo, panelInfo.$splitter);\n }).bind(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n item.$target.append(panelInfo.$splitter);\n }\n\n if (panelInfo.dock == \"top\" || panelInfo.dock == \"bottom\") {\n panelInfo.__height = getPixel(panelInfo.height, item.targetDimension.height);\n } else {\n panelInfo.__width = getPixel(panelInfo.width, item.targetDimension.width);\n }\n panelInfo.resizerType = panelInfo.dock;\n item.dockPanel[panelInfo.dock] = panelInfo;\n }\n });\n },\n \"split-panel\": function splitPanel(queIdx) {\n var item = this.queue[queIdx];\n item.splitPanel = [];\n item.$target.find('>[data-split-panel], >[data-splitter]').each(function (ELIndex) {\n\n var panelInfo = {};\n (function (data) {\n if (U.isObject(data) && !data.error) {\n panelInfo = jQuery.extend(true, panelInfo, data);\n }\n })(U.parseJson(this.getAttribute(\"data-split-panel\") || this.getAttribute(\"data-splitter\"), true));\n\n panelInfo.$target = jQuery(this);\n panelInfo.$target.addClass(\"split-panel-\" + item.orientation);\n panelInfo.panelIndex = ELIndex;\n\n if (this.getAttribute(\"data-splitter\")) {\n\n panelInfo.splitter = true;\n panelInfo.$target.bind(ENM[\"mousedown\"], function (e) {\n if (panelInfo.panelIndex > 0 && panelInfo.panelIndex < item.splitPanel.length - 1) {\n panelInfo.mousePosition = getMousePosition(e);\n resizeSplitter.on.call(self, queIdx, panelInfo, panelInfo.$target);\n }\n }).bind(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n panelInfo.resizerType = \"split\";\n } else {\n\n if (item.orientation == \"horizontal\") {\n panelInfo.__height = getPixel(panelInfo.height, item.targetDimension.height);\n } else {\n item.orientation = \"vertical\";\n panelInfo.__width = getPixel(panelInfo.width, item.targetDimension.width);\n }\n }\n\n item.splitPanel.push(panelInfo);\n });\n },\n \"tab-panel\": function tabPanel(queIdx) {\n var item = this.queue[queIdx];\n\n var hasActivePanel = false;\n var activePanelIndex = -1;\n item.tabPanel = [];\n item.$target.find('>[data-tab-panel]').each(function (ELIndex) {\n var panelInfo = {};\n (function (data) {\n if (U.isObject(data) && !data.error) {\n panelInfo = jQuery.extend(true, panelInfo, data);\n }\n })(U.parseJson(this.getAttribute(\"data-tab-panel\"), true));\n\n if (hasActivePanel) {\n panelInfo.active = false;\n }\n\n panelInfo.$target = jQuery(this);\n\n if (panelInfo.active && panelInfo.active != \"false\") {\n hasActivePanel = true;\n item.activePanelIndex = ELIndex;\n panelInfo.$target.attr(\"data-tab-active\", \"true\");\n }\n\n panelInfo.panelIndex = ELIndex;\n item.tabPanel.push(panelInfo);\n });\n\n if (!hasActivePanel) {\n item.tabPanel[0].active = true;\n item.tabPanel[0].$target.attr(\"data-tab-active\", \"true\");\n item.activePanelIndex = 0;\n }\n\n // make tabLabel\n item.$target.append(jQuery(ax5.mustache.render(getTabLabesTmpl.call(this, queIdx), item)));\n item.$target.on(\"click\", '[data-tab-panel-label]', function (e) {\n var index = this.getAttribute(\"data-tab-panel-label\");\n tabControl.open.call(self, queIdx, item, index);\n });\n }\n };\n\n return function (queIdx) {\n var item = this.queue[queIdx];\n var data = {};\n\n // 레이아웃 타겟의 CSS속성을 미리 저장해 둡니다. 왜? 패널별로 크기 계산 할 때 쓰려고\n item.targetDimension = {\n height: item.$target.innerHeight(),\n width: item.$target.innerWidth()\n };\n\n // 부모 컨테이너가 ax5layout인지 판단 필요.\n if (item.$target.parents(\"[data-ax5layout]\").get(0)) {\n hooksResizeLayout.call(this, item.$target.parents(\"[data-ax5layout]\").get(0), queIdx);\n }\n\n if (item.layout in applyLayout) {\n applyLayout[item.layout].call(this, queIdx);\n }\n alignLayout.call(this, queIdx);\n };\n }(),\n getQueIdx = function getQueIdx(boundID) {\n if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-ax5layout-id\");\n }\n if (!U.isString(boundID)) {\n //console.log(ax5.info.getError(\"ax5layout\", \"402\", \"getQueIdx\"));\n return -1;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n },\n hooksResizeLayout = function hooksResizeLayout(boundID, childQueIdx) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n if (!this.queue[queIdx].childQueIdxs) this.queue[queIdx].childQueIdxs = [];\n this.queue[queIdx].childQueIdxs.push(childQueIdx);\n this.queue[childQueIdx].parentQueIdx = queIdx;\n };\n /// private end\n /**\n * Preferences of layout UI\n * @method ax5layout.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Number} [config.animateTime=250]\n * @param {Object} [config.splitter]\n * @param {Number} [config.splitter.size=4]\n * @param {Boolean} [config.autoResize=true]\n * @returns {ax5layout}\n * @example\n * ```js\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n jQuery(window).bind(\"resize.ax5layout-\" + this.instanceId, function () {\n alignLayoutAll.call(this);\n }.bind(this));\n };\n\n /**\n * @method ax5layout.bind\n * @param {Object} item\n * @param {String} [item.layout]\n * @param {String} [item.theme]\n * @param {Element} item.target\n * @param {Object[]} item.options\n * @param {Object} [item.splitter]\n * @param {Number} [item.splitter.size=4]\n * @param {Boolean} [item.autoResize=true]\n * @returns {ax5layout}\n */\n this.bind = function (item) {\n var UIConfig = {},\n queIdx;\n\n item = jQuery.extend(true, UIConfig, cfg, item);\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5layout\", \"401\", \"bind\"));\n return this;\n }\n\n item.$target = jQuery(item.target);\n\n if (!item.id) item.id = item.$target.data(\"data-ax5layout-id\");\n if (!item.id) {\n item.id = 'ax5layout-' + ax5.getGuid();\n item.$target.data(\"data-ax5layout-id\", item.id);\n }\n item.name = item.$target.attr(\"data-ax5layout\");\n if (item.options) {\n item.options = JSON.parse(JSON.stringify(item.options));\n }\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n item = jQuery.extend(true, item, data);\n }\n })(U.parseJson(item.$target.attr(\"data-config\"), true));\n\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindLayoutTarget.call(this, this.queue.length - 1);\n } else {\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindLayoutTarget.call(this, queIdx);\n }\n\n UIConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * @method ax5layout.align\n * @param boundID\n * @param {Function} [callback]\n * @param {String} [windowResize]\n * @returns {ax5layout}\n */\n this.align = function (boundID, windowResize) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n\n if (queIdx === -1) {\n var i = this.queue.length;\n while (i--) {\n alignLayout.call(this, i, null, windowResize);\n }\n } else {\n alignLayout.call(this, queIdx, null, windowResize);\n }\n return this;\n };\n\n /**\n * @method ax5layout.onResize\n * @param boundID\n * @param fn\n * @returns {ax5layout}\n */\n this.onResize = function (boundID, fn) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5layout\", \"402\", \"onResize\"));\n return;\n }\n this.queue[queIdx].onResize = fn;\n return this;\n };\n\n /**\n * @method ax5layout.resize\n * @param boundID\n * @param {Object} resizeOption\n * @param {Function} [callback]\n * @returns {ax5layout}\n */\n this.resize = function () {\n\n var resizeLayoutPanel = {\n \"dock-panel\": function dockPanel(item, resizeOption) {\n [\"top\", \"bottom\", \"left\", \"right\"].forEach(function (dock) {\n if (resizeOption[dock] && item.dockPanel[dock]) {\n if (dock == \"top\" || dock == \"bottom\") {\n item.dockPanel[dock].__height = U.isObject(resizeOption[dock]) ? resizeOption[dock].height : resizeOption[dock];\n } else if (dock == \"left\" || dock == \"right\") {\n item.dockPanel[dock].__width = U.isObject(resizeOption[dock]) ? resizeOption[dock].width : resizeOption[dock];\n }\n }\n });\n },\n \"split-panel\": function splitPanel() {},\n \"tab-panel\": function tabPanel() {}\n };\n\n return function (boundID, resizeOption, callback) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n var i = this.queue.length;\n while (i--) {\n resizeLayoutPanel[this.queue[i].layout].call(this, this.queue[i], resizeOption);\n alignLayout.call(this, i, callback);\n }\n } else {\n if (this.queue[queIdx]) {\n resizeLayoutPanel[this.queue[queIdx].layout].call(this, this.queue[queIdx], resizeOption);\n alignLayout.call(this, queIdx, callback);\n }\n }\n\n return this;\n };\n }();\n\n this.reset = function () {\n\n var resetLayoutPanel = {\n \"dock-panel\": function dockPanel(item) {\n [\"top\", \"bottom\", \"left\", \"right\"].forEach(function (dock) {\n if (item.dockPanel[dock]) {\n if (dock == \"top\" || dock == \"bottom\") {\n item.dockPanel[dock].__height = item.dockPanel[dock].height;\n } else if (dock == \"left\" || dock == \"right\") {\n item.dockPanel[dock].__width = item.dockPanel[dock].width;\n }\n }\n });\n },\n \"split-panel\": function splitPanel(item) {\n item.splitPanel.forEach(function (panel) {\n if (item.orientation == \"vertical\") {\n panel.__width = getPixel(panel.width, item.targetDimension.width);\n } else if (item.orientation == \"horizontal\") {\n panel.__height = getPixel(panel.height, item.targetDimension.height);\n }\n });\n },\n \"tab-panel\": function tabPanel() {}\n };\n\n return function (boundID, callback) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {} else {\n resetLayoutPanel[this.queue[queIdx].layout].call(this, this.queue[queIdx]);\n alignLayout.call(this, queIdx, callback);\n }\n\n return this;\n };\n }();\n\n this.hide = function () {};\n\n /**\n * @method ax5layout.tabOpen\n * @param boundID\n * @param tabIndex\n * @returns {ax5.ui.ax5layout}\n */\n this.tabOpen = function () {\n return function (boundID, tabIndex) {\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5layout\", \"402\", \"tabOpen\"));\n return;\n }\n\n tabControl.open.call(this, queIdx, this.queue[queIdx], tabIndex);\n return this;\n };\n }();\n\n /// 클래스 생성자\n this.main = function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n } else {\n this.init();\n }\n }.apply(this, arguments);\n };\n return ax5layout;\n }());\n})();\n\nax5.ui.layout_instance = new ax5.ui.layout();\n\n/**\n * ax5layout jquery extends\n * @namespace jQueryExtends\n */\n\n/**\n * @method jQueryExtends.ax5layout\n * @param {String} methodName\n * @example\n * ```js\n * jQuery('[data-ax5layout=\"ax1\"]').ax5layout();\n * ```\n */\n\njQuery.fn.ax5layout = function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"align\":\n return ax5.ui.layout_instance.align(this, arguments[1]);\n break;\n case \"resize\":\n return ax5.ui.layout_instance.resize(this, arguments[1], arguments[2]);\n break;\n case \"reset\":\n return ax5.ui.layout_instance.reset(this, arguments[1]);\n break;\n case \"hide\":\n return ax5.ui.layout_instance.hide(this, arguments[1]);\n break;\n case \"onResize\":\n return ax5.ui.layout_instance.onResize(this, arguments[1]);\n break;\n case \"tabOpen\":\n return ax5.ui.layout_instance.tabOpen(this, arguments[1]);\n break;\n default:\n return this;\n }\n } else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.layout_instance.bind(config);\n });\n }\n return this;\n };\n}();\n// ax5.ui.binder\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n\n UI.addClass({\n className: \"binder\",\n version: \"1.3.66\"\n }, function () {\n\n /**\n * @class ax5binder\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var obj = {\n * name: \"Thomas Jang\",\n * alias: \"tom\",\n * tel: \"010-8881-9137\",\n * email: \"tom@axisj.com\",\n * sex: \"M\",\n * hobby: [\"sport\"],\n * useYn: \"N\",\n * description: \"http://www.axisj.com\",\n * list: [\n * {\n * name: \"thomas\",\n * tel: \"010-8881-9000\",\n * email: \"tom@axisj.com\",\n * sex: \"M\",\n * description: \"\",\n * child: [{name:\"값1\"},{name:\"값2\"}],\n * qty: 10,\n * cost: 100\n * },\n * {\n * name: \"thomas\",\n * tel: \"010-8881-9000\",\n * email: \"tom@axisj.com\",\n * sex: \"M\",\n * description: \"\",\n * child: [{name:\"값1\"},{name:\"값2\"}],\n * qty: 20,\n * cost: 100\n * }\n * ]\n * };\n *\n * var myBinder = new ax5.ui.binder();\n * myBinder.setModel(obj, $('#form-target'));\n * ```\n */\n var ax5binder = function ax5binder() {\n\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {};\n cfg = this.config;\n\n this.model = {};\n this.tmpl = {};\n this.view_target = null;\n this.change_trigger = {};\n this.click_trigger = {};\n this.update_trigger = {};\n this.onerror = null;\n\n var _toString = Object.prototype.toString,\n get_type = function get_type(O) {\n var typeName;\n if (O != null && O == O.window) {\n typeName = \"window\";\n } else if (!!(O && O.nodeType == 1)) {\n typeName = \"element\";\n } else if (!!(O && O.nodeType == 11)) {\n typeName = \"fragment\";\n } else if (typeof O === \"undefined\") {\n typeName = \"undefined\";\n } else if (_toString.call(O) == \"[object Object]\") {\n typeName = \"object\";\n } else if (_toString.call(O) == \"[object Array]\") {\n typeName = \"array\";\n } else if (_toString.call(O) == \"[object String]\") {\n typeName = \"string\";\n } else if (_toString.call(O) == \"[object Number]\") {\n typeName = \"number\";\n } else if (_toString.call(O) == \"[object NodeList]\") {\n typeName = \"nodelist\";\n } else if (typeof O === \"function\") {\n typeName = \"function\";\n }\n return typeName;\n },\n get_mix_path = function get_mix_path(dataPath, index, item_path) {\n return dataPath + \"[\" + index + \"]\" + (item_path == \".\" ? \"\" : \".\" + item_path);\n },\n get_real_path = function get_real_path(_dataPath) {\n var path = [];\n var _path = [].concat(_dataPath.split(/[\\.\\[\\]]/g));\n _path.forEach(function (n) {\n if (n !== \"\") path.push(\"[\\\"\" + n.replace(/['\\\"]/g, \"\") + \"\\\"]\");\n });\n _path = null;\n return path.join(\"\");\n /*\n var path = [];\n var _path = [].concat(dataPath.split(/[\\.\\[\\]]/g));\n _path.forEach(function (n) {\n if (n !== \"\") path.push(n);\n });\n _path = null;\n return \"'\" + path.join(\"']['\") + \"'\";\n */\n };\n\n /**\n * 바인딩할 자바스크립트 오브젝트로 제이쿼리로 검색된 HTML dom 엘리먼트 에 바인딩합니다. 바인딩된 모델을 반환합니다.\n * @method ax5binder.setModel\n * @param {Object} model\n * @param {jQueryObject} [view_target]\n * @returns {ax5binder}\n * @example\n * ```js\n * var myModel = new ax5.ui.binder();\n * myModel.setModel({}, $(\"#...\"));\n * ```\n */\n this.setModel = function (model, view_target) {\n this.model = model;\n if (!this.view_target && view_target) {\n this.view_target = view_target;\n this._binding();\n } else {\n this._binding(\"update\");\n }\n return this;\n };\n\n /**\n * data_path에 값을 변경한다. value의 타입은 (String, Number, Array, Object)를 지원.\n * @method ax5binder.set\n * @param {String} dataPath\n * @param {Object} value\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.set(\"name\", \"Seowoo\");\n * myModel.set(\"obj.path\", {a:1});\n * ```\n */\n this.set = function (dataPath, value) {\n var _this = this,\n obj_type,\n i,\n this_type;\n\n Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\").call(this.model, value);\n obj_type = get_type(value);\n\n if (obj_type == \"object\") {\n for (var k in value) {\n this.set(dataPath + \".\" + k, value[k]);\n }\n } else if (obj_type == \"array\") {\n this.view_target.find('[data-ax-path=\"' + dataPath + '\"]').each(function () {\n this_type = (this.type || \"\").toLowerCase();\n if (this_type == \"checkbox\" || this_type == \"radio\") _this.set_els_value(this, this.tagName.toLowerCase(), this_type, value, dataPath, \"change\");\n });\n i = value.length;\n while (i--) {\n this.set(dataPath + \"[\" + i + \"]\", value[i]);\n }\n } else {\n // apply data value to els\n this.view_target.find('[data-ax-path=\"' + dataPath + '\"]').each(function () {\n _this.set_els_value(this, this.tagName.toLowerCase(), (this.type || \"\").toLowerCase(), value, dataPath, \"change\");\n });\n }\n return this;\n };\n\n /**\n * data_path에 값을 반환한다. data_path 가 없으면 전체 Object를 반환한다.\n * @method ax5binder.get\n * @param dataPath\n * @returns {*}\n */\n this.get = function (dataPath) {\n if (typeof dataPath == \"undefined\") {\n return this.model;\n } else {\n return Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(this.model);\n }\n };\n\n /**\n * data_path에 값이 변경되는 이벤트 발생하면 callback을 실행합니다.\n * @method ax5binder.onChange\n * @param dataPath\n * @param callback\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.onChange(\"name\", function () {\n * console.log(this);\n * // el: domElement - 변경이 발생한 엘리먼트, 엘리먼트로 부터 다양한 속성을 추출할 수 있다.\n * // jquery : jQueryObject\n * // tagname: \"input\"\n * // value: \"changed value\"\n * console.log(this.el.id);\n * });\n * myModel.onChange(\"*\", function (n) {\n * console.log(n);\n * // console.log(this); 와 동일\n * });\n * ```\n */\n this.onChange = function (dataPath, callback) {\n this.change_trigger[dataPath || \"*\"] = callback;\n return this;\n };\n\n /**\n * data-ax-repeat=\"list\" 속성이 부여된 엘리먼트 하위에 태그중에 data-ax-repeat-click 속성을 가진 아이템에 대해 클릭 이벤트 발생하면 callback을 실행합니다.\n * @method ax5binder.onClick\n * @param dataPath\n * @param callback\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.onclick(\"list\", function () {\n * console.log(this);\n * // el: domElement\n * // jquery: jQueryObject\n * // item: Object - repeat item\n * // item_index: \"0\" - index of item\n * // item_path: \"list[0]\" - repeat data_path\n * // repeat_path: \"list\"\n * // tagname: \"button\"\n * // value: \"add\"\n * });\n * ```\n */\n this.onClick = function (dataPath, callback) {\n this.click_trigger[dataPath] = callback;\n return this;\n };\n\n /**\n * data-ax-repeat=\"list\" 하위아이템을 추가합니다.\n * @method ax5binder.add\n * @param dataPath\n * @param item\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.add(\"list\", {a:1});\n * ```\n */\n this.add = function (dataPath, item) {\n var list = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(this.model);\n var tmpl = this.tmpl[dataPath];\n item['@i'] = list.length;\n item['@r'] = list.length;\n item.__ADDED__ = true;\n Function(\"val\", \"this\" + get_real_path(dataPath) + \".push(val);\").call(this.model, item);\n\n // 다중 템플릿 처리\n for (var t in tmpl) {\n var fragdom = $(ax5.mustache.render(tmpl[t].content, item));\n fragdom.attr(\"data-ax-repeat-path\", dataPath);\n fragdom.attr(\"data-ax-repeat-i\", item['@i']);\n this.bind_event_tmpl(fragdom, dataPath);\n tmpl[t].container.append(fragdom);\n }\n\n this.change(\"*\");\n\n var callback = this.update_trigger[dataPath];\n if (callback) {\n var that = {\n repeat_path: dataPath,\n tmpl: tmpl,\n list: list\n };\n callback.call(that, that);\n }\n\n return this;\n };\n\n /**\n * data-ax-repeat=\"list\" 하위 아이템을 제거합니다. 단! 이 때 ADDED 값을 가진 아이템은 제거하고 그렇지 않은 아이템은 DELETED 값을 아이템에 추가합니다.\n * @method ax5binder.remove\n * @param dataPath\n * @param index\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.remove(\"list\", 0);\n * ```\n */\n this.remove = function (dataPath, index) {\n var list = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(this.model);\n var tmpl = this.tmpl[dataPath];\n if (typeof index == \"undefined\") index = list.length - 1;\n var remove_item = list[index];\n if (remove_item.__ADDED__) {\n list.splice(index, 1);\n } else {\n list[index].__DELETED__ = true;\n }\n\n for (var t in tmpl) {\n tmpl[t].container.empty();\n this.print_tmpl(dataPath, tmpl[t]);\n }\n\n this.change(\"*\");\n\n var callback = this.update_trigger[dataPath];\n if (callback) {\n var that = {\n repeat_path: dataPath,\n tmpl: tmpl,\n list: list\n };\n callback.call(that, that);\n }\n\n return this;\n };\n\n /**\n * data-ax-repeat=\"list\" 하위 아이템을 교체합니다.\n * @method ax5binder.update\n * @param dataPath\n * @param index\n * @param item\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.update(\"list\", 0, {a:1});\n * ```\n */\n this.update = function (dataPath, index, item) {\n var list = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(this.model);\n var tmpl = this.tmpl[dataPath];\n if (typeof index != \"undefined\" && item) list.splice(index, 1, item);\n\n for (var t in tmpl) {\n tmpl[t].container.empty();\n this.print_tmpl(dataPath, tmpl[t]);\n }\n\n this.change(\"*\");\n\n var callback = this.update_trigger[dataPath];\n if (callback) {\n var that = {\n repeat_path: dataPath,\n tmpl: tmpl,\n list: list\n };\n callback.call(that, that);\n }\n\n return this;\n };\n\n /**\n * @method ax5binder.childAdd\n * @param dataPath\n * @param index\n * @param child_path\n * @param child_item\n */\n this.childAdd = function (dataPath, index, child_path, child_item) {\n var _list = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(this.model);\n var list = Function(\"\", \"return this\" + get_real_path(dataPath) + \"[\" + index + \"].\" + child_path + \";\").call(this.model);\n child_item.__ADDED__ = true;\n list.push(child_item);\n this.update(dataPath, index, _list[index]);\n };\n\n /**\n * ax5binder.childRemove\n * @param dataPath\n * @param index\n * @param child_path\n * @param child_index\n */\n this.childRemove = function (dataPath, index, child_path, child_index) {\n var _list = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(this.model);\n var list = Function(\"\", \"return this\" + get_real_path(dataPath) + \"[\" + index + \"].\" + child_path + \";\").call(this.model);\n var remove_item = list[child_index];\n if (remove_item.__ADDED__) {\n list.splice(child_index, 1);\n } else {\n list[child_index].__DELETED__ = true;\n }\n this.update(dataPath, index, _list[index]);\n };\n\n /**\n * @method ax5binder.childUpdate\n * @param dataPath\n * @param index\n * @param child_path\n * @param child_index\n * @param child_item\n */\n this.childUpdate = function (dataPath, index, child_path, child_index, child_item) {\n var _list = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(this.model);\n var list = Function(\"\", \"return this\" + get_real_path(dataPath) + \"[\" + index + \"].\" + child_path + \";\").call(this.model);\n list[child_index] = child_item;\n this.update(dataPath, index, _list[index]);\n };\n\n /**\n * @method ax5binder.childSet\n * @param dataPath\n * @param index\n * @param child_path\n * @param value\n * @returns {ax5binder}\n */\n this.childSet = function (dataPath, index, child_path, value) {\n var _this = this,\n i;\n Function(\"val\", \"this\" + get_real_path(dataPath) + \"[\" + index + \"].\" + child_path + \" = val;\").call(this.model, value);\n\n // apply data value to els\n this.view_target.find('[data-ax-repeat=\"' + dataPath + '\"]').find('[data-ax-repeat-i=\"' + index + '\"]').find('[data-ax-item-path=\"' + child_path + '\"]').each(function () {\n _this.set_els_value(this, this.tagName.toLowerCase(), (this.type || \"\").toLowerCase(), value, dataPath + \"[\" + index + \"].\" + child_path);\n });\n return this;\n };\n\n /**\n * @method ax5binder.onUpdate\n * @param dataPath\n * @param callback\n * @returns {ax5binder}\n * @example\n * ```js\n * this.model.onupdate(\"moderator\", function () {\n * $('#moderator-add').val('');\n * $moderator.find('[data-role-user-btn]')\n * .unbind(\"click\")\n * .bind(\"click\", role_user_btn_onclick);\n * });\n * ```\n */\n this.onUpdate = function (dataPath, callback) {\n this.update_trigger[dataPath] = callback;\n return this;\n };\n\n this._binding = function (isupdate) {\n var _this = this;\n\n // apply data value to els\n this.view_target.find('[data-ax-path]').each(function () {\n var dom = $(this),\n dataPath = dom.attr(\"data-ax-path\"),\n this_type = (this.type || \"\").toLowerCase();\n\n var val;\n try {\n val = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(_this.model);\n } catch (e) {\n /**\n * onerror를 선언 한 경우에만 에러 출력\n * */\n if (_this.onerror) _this.onerror(\"not found target [model.\" + get_real_path(dataPath) + \"]\");\n }\n\n _this.set_els_value(this, this.tagName.toLowerCase(), this_type, val || \"\", dataPath);\n });\n\n if (typeof isupdate == \"undefined\") {\n // collect tmpl\n this.view_target.find('[data-ax-repeat]').each(function () {\n var dom = $(this),\n dataPath = dom.attr(\"data-ax-repeat\"),\n repeat_idx = dom.attr(\"data-ax-repeat-idx\");\n\n if (typeof _this.tmpl[dataPath] == \"undefined\") _this.tmpl[dataPath] = {};\n if (typeof repeat_idx != \"undefined\") {\n _this.tmpl[dataPath][repeat_idx] = {\n container: dom, content: dom.find(\"script\").html()\n };\n } else {\n _this.tmpl[dataPath][\"0\"] = {\n container: dom, content: dom.find(\"script\").html()\n };\n }\n //dom.empty().show();\n dom.empty();\n });\n } else {\n this.view_target.find('[data-ax-repeat]').each(function () {\n var dom = $(this);\n dom.empty().show();\n });\n }\n\n // binding event to els\n this.view_target.find('[data-ax-path]').unbind(\"change.axbinder\").bind(\"change.axbinder\", function (e) {\n\n var i,\n hasItem = false,\n checked,\n new_value = [],\n dom = $(e.target),\n dataPath = dom.attr(\"data-ax-path\"),\n origin_value = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(_this.model),\n this_type = (this.type || \"\").toLowerCase(),\n value_type = get_type(origin_value),\n setAllow = true;\n\n if (value_type == \"object\" || value_type == \"array\") {\n setAllow = false;\n }\n\n if (this_type == \"checkbox\") {\n // 동일한 체크박스가 여러개 인지 판단합니다.\n if (_this.view_target.find('[data-ax-path=\"' + dataPath + '\"]').length > 1) {\n\n if (get_type(origin_value) != \"array\") {\n if (typeof origin_value === \"undefined\" || origin_value == \"\") origin_value = [];else origin_value = [].concat(origin_value);\n }\n i = origin_value.length, hasItem = false, checked = this.checked;\n while (i--) {\n if (origin_value[i] == this.value) {\n hasItem = true;\n }\n }\n\n if (checked) {\n if (!hasItem) origin_value.push(this.value);\n } else {\n i = origin_value.length;\n while (i--) {\n if (origin_value[i] == this.value) {\n //hasItemIndex = i;\n } else {\n new_value.push(origin_value[i]);\n }\n }\n origin_value = new_value;\n }\n } else {\n origin_value = this.checked ? this.value : \"\";\n }\n\n Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\").call(_this.model, origin_value);\n _this.change(dataPath, {\n el: this, jquery: dom, tagname: this.tagName.toLowerCase(), value: origin_value\n });\n } else {\n if (setAllow) {\n Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\").call(_this.model, this.value);\n _this.change(dataPath, {\n el: this, jquery: dom, tagname: this.tagName.toLowerCase(), value: this.value\n });\n }\n }\n\n dom.data(\"changedTime\", new Date().getTime());\n });\n /*\n this.view_target.find('[data-ax-path]').unbind(\"blur.axbinder\").bind(\"blur.axbinder\", function (e) {\n var dom = $(e.target);\n if (typeof dom.data(\"changedTime\") == \"undefined\" || dom.data(\"changedTime\") < (new Date()).getTime() - 10) dom.trigger(\"change\");\n });\n */\n\n //_this.tmpl\n var callback;\n for (var tk in _this.tmpl) {\n for (var ix in _this.tmpl[tk]) {\n // console.log(_this.tmpl[tk][ix].content);\n this.print_tmpl(tk, _this.tmpl[tk][ix], \"isInit\");\n }\n\n if (callback = this.update_trigger[tk]) {\n var that = {\n repeat_path: tk,\n tmpl: _this.tmpl[tk],\n list: Function(\"\", \"return this.\" + tk + \";\").call(this.model)\n };\n callback.call(that, that);\n }\n }\n };\n\n this.set_els_value = function (el, tagname, type, value, dataPath, callChange) {\n if (typeof value === \"undefined\") value = [];else value = [].concat(value);\n var options, i;\n\n if (tagname == \"input\") {\n if (type == \"checkbox\" || type == \"radio\") {\n i = value.length;\n var checked = false;\n try {\n if (i > 0) {\n while (i--) {\n if (typeof value[i] !== \"undefined\" && el.value === value[i].toString()) {\n checked = true;\n }\n }\n }\n } catch (e) {\n console.log(e);\n }\n\n el.checked = checked;\n } else {\n el.value = value.join('');\n }\n } else if (tagname == \"select\") {\n options = el.options, i = options.length;\n var vi,\n option_matched = false;\n\n while (i--) {\n vi = value.length;\n while (vi--) {\n if (typeof value[vi] !== \"undefined\" && options[i].value === value[vi].toString()) {\n options[i].selected = true;\n option_matched = true;\n break;\n }\n }\n if (option_matched) break;\n }\n if (!option_matched) {\n if (options[0]) {\n options[0].selected = true;\n Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\").call(this.model, options[0].value);\n } else {\n Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\").call(this.model, \"\");\n }\n }\n\n if (window.AXSelect) {\n // AXISJ 사용가능\n $(typeof value !== \"undefined\" && el).bindSelectSetValue(value[value.length - 1]);\n }\n } else if (tagname == \"textarea\") {\n el.value = value.join('') || \"\";\n } else {\n if (el.innerText) {\n el.innerText = value.join(\"\");\n } else {\n el.innerHTML = value.join(\"\");\n }\n }\n\n if (callChange) {\n this.change(dataPath, { el: el, tagname: tagname, value: value });\n }\n return this;\n };\n\n this.change = function (dataPath, that) {\n var callback = this.change_trigger[dataPath];\n if (callback) {\n callback.call(that, that);\n }\n if (dataPath != \"*\" && this.change_trigger[\"*\"]) {\n this.change_trigger[\"*\"].call(that, that);\n }\n };\n\n this.click = function (dataPath, that) {\n var callback = this.click_trigger[dataPath];\n if (callback) {\n callback.call(that, that);\n }\n };\n\n this.sync_model = function () {};\n\n this.print_tmpl = function (dataPath, tmpl, isInit) {\n var list = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(this.model);\n if (list && get_type(list) == \"array\") {\n for (var i = 0, l = list.length; i < l; i++) {\n var item = list[i];\n if (jQuery.isPlainObject(item)) {\n item['@i'] = i;\n item['@r'] = i;\n if (i === 0) item['@first'] = true;\n } else {\n item = {\n \"@i\": i,\n \"@value\": item\n };\n if (i === 0) item['@first'] = true;\n console.log(item);\n }\n\n if (!item.__DELETED__) {\n var fragdom = $(ax5.mustache.render(tmpl.content, item));\n fragdom.attr(\"data-ax-repeat-path\", dataPath);\n fragdom.attr(\"data-ax-repeat-i\", item['@i']);\n this.bind_event_tmpl(fragdom, dataPath);\n tmpl.container.append(fragdom);\n }\n }\n }\n };\n\n this.bind_event_tmpl = function (target, dataPath) {\n var _this = this,\n index = target.attr(\"data-ax-repeat-i\");\n var list = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(this.model);\n\n target.find('[data-ax-repeat-click]').unbind(\"click.axbinder\").bind(\"click.axbinder\", function (e) {\n var target = ax5.util.findParentNode(e.target, function (el) {\n return el.getAttribute(\"data-ax-repeat-click\");\n });\n if (target) {\n var dom = $(target),\n value = dom.attr(\"data-ax-repeat-click\"),\n repeat_path = dom.attr(\"data-ax-repeat-path\");\n\n var that = {\n el: target,\n jquery: dom,\n tagname: target.tagName.toLowerCase(),\n value: value,\n repeat_path: dataPath,\n item: list[index],\n item_index: index,\n item_path: dataPath + \"[\" + index + \"]\"\n };\n _this.click(dataPath, that);\n }\n });\n\n // apply data value to els\n target.find('[data-ax-item-path]').each(function () {\n var dom = $(this),\n item_path = dom.attr(\"data-ax-item-path\"),\n mix_path = get_mix_path(dataPath, index, item_path),\n val,\n this_type = (this.type || \"\").toLowerCase();\n\n try {\n val = Function(\"\", \"return this.\" + mix_path + \";\").call(_this.model);\n } catch (e) {\n /**\n * onerror를 선언 한 경우에만 에러 출력\n * */\n if (_this.onerror) _this.onerror(\"not found target [model.\" + mix_path + \"]\");\n }\n //if (typeof val !== \"undefined\") _this.set_els_value(this, this.tagName.toLowerCase(), this_type, val, mix_path);\n _this.set_els_value(this, this.tagName.toLowerCase(), this_type, val || \"\", mix_path);\n });\n\n // binding event to els\n target.find('[data-ax-item-path]').unbind(\"change.axbinder\").bind(\"change.axbinder\", function (e) {\n var i,\n hasItem = false,\n checked,\n new_value = [],\n this_type = (this.type || \"\").toLowerCase(),\n dom = $(e.target),\n item_path = dom.attr(\"data-ax-item-path\"),\n mix_path = get_mix_path(dataPath, index, item_path),\n origin_value = Function(\"\", \"return this.\" + mix_path + \";\").call(_this.model),\n value_type = get_type(origin_value),\n setAllow = true;\n\n if (value_type == \"object\" || value_type == \"array\") {\n setAllow = false;\n }\n\n if (this_type == \"checkbox\") {\n if (target.find('[data-ax-item-path=\"' + item_path + '\"]').length > 1) {\n if (get_type(origin_value) != \"array\") {\n if (typeof origin_value === \"undefined\" || origin_value == \"\") origin_value = [];else origin_value = [].concat(origin_value);\n }\n i = origin_value.length, hasItem = false, checked = this.checked;\n while (i--) {\n if (origin_value[i] == this.value) {\n hasItem = true;\n }\n }\n\n if (checked) {\n if (!hasItem) origin_value.push(this.value);\n } else {\n i = origin_value.length;\n while (i--) {\n if (origin_value[i] == this.value) {\n //hasItemIndex = i;\n } else {\n new_value.push(origin_value[i]);\n }\n }\n origin_value = new_value;\n }\n } else {\n origin_value = this.checked ? this.value : \"\";\n }\n\n Function(\"val\", \"this.\" + mix_path + \" = val;\").call(_this.model, origin_value);\n _this.change(mix_path, {\n el: this, jquery: dom, tagname: this.tagName.toLowerCase(), value: origin_value\n });\n } else {\n if (setAllow) {\n Function(\"val\", \"this.\" + mix_path + \" = val;\").call(_this.model, this.value);\n _this.change(mix_path, {\n el: this, jquery: dom, tagname: this.tagName.toLowerCase(), value: this.value\n });\n }\n }\n\n dom.data(\"changedTime\", new Date().getTime());\n });\n target.find('[data-ax-item-path]').unbind(\"blur.axbinder\").bind(\"blur.axbinder\", function (e) {\n var dom = $(e.target);\n if (typeof dom.data(\"changedTime\") == \"undefined\" || dom.data(\"changedTime\") < new Date().getTime() - 10) dom.trigger(\"change\");\n });\n };\n\n /**\n * @method ax5binder.focus\n * @param dataPath\n * @returns {ax5binder}\n */\n this.focus = function (dataPath) {\n this.view_target.find('[data-ax-path=\"' + dataPath + '\"]').focus();\n //this.view_target.find('[data-ax-item-path=\"' + get_real_path(dataPath) + '\"]').focus();\n return this;\n };\n\n /**\n * @method ax5binder.validate\n * @returns {*}\n * @example\n * ```html\n *
\n * ```\n * ```js\n * var rs = myModel.validate(), _s;\n * console.log(rs); // 결과를 체크 해보세요\n * if(rs.error) {\n * _s = rs.error[0].jquery.attr(\"title\");\n * alert(\"\" + _s + \"(은)는 필수 입력사항입니다.\" + _s + \"(을)를 입력하세요\");\n * rs.error[0].el.focus();\n * return;\n * }\n * ```\n */\n this.validate = function () {\n var _this = this;\n var errors = [];\n this.view_target.find('[data-ax-path]').each(function () {\n var dom = $(this),\n dataPath = dom.attr(\"data-ax-path\"),\n is_validate = dom.attr(\"data-ax-validate\"),\n pattern = dom.attr(\"pattern\");\n\n if (is_validate) {\n var val, _val, is_error;\n\n val = Function(\"\", \"return this\" + get_real_path(dataPath) + \";\").call(_this.model);\n if (typeof val === \"undefined\") val = \"\";\n _val = val.toString();\n is_error = false;\n\n if (is_validate == \"required\" && _val.trim() == \"\") {\n is_error = true;\n } else if (is_validate == \"pattern\") {\n is_error = !new RegExp(pattern).test(_val);\n } else if (is_validate == \"email\") {\n is_error = !/[a-z0-9._%+-]+@[a-z0-9.-]+\\.[a-z]{2,4}$/.test(_val);\n } else if (!/\\D.?/g.test(is_validate) && _val.trim().length < is_validate.number()) {\n is_error = true;\n }\n\n if (is_error) {\n errors.push({\n type: is_validate,\n dataPath: dataPath,\n el: this,\n jquery: dom,\n value: val\n });\n }\n }\n });\n this.view_target.find('[data-ax-repeat-path]').each(function () {\n\n var dom = $(this),\n dataPath = dom.attr(\"data-ax-repeat-path\"),\n repeat_idx = dom.attr(\"data-ax-repeat-i\");\n\n dom.find('[data-ax-validate]').each(function () {\n var dom = $(this),\n is_validate = dom.attr(\"data-ax-validate\"),\n item_path = dom.attr(\"data-ax-item-path\");\n var val = Function(\"\", \"return this\" + get_real_path(dataPath) + \"[\" + repeat_idx + \"].\" + item_path + \";\").call(_this.model);\n if (typeof val === \"undefined\") val = \"\";\n var _val = val.toString();\n\n if (is_validate) {\n var is_error = false;\n if (is_validate == \"required\" && _val.trim() == \"\") {\n is_error = true;\n } else if (is_validate == \"pattern\") {\n is_error = !new RegExp(pattern).test(_val);\n } else if (is_validate == \"email\") {\n is_error = !/[a-z0-9._%+-]+@[a-z0-9.-]+\\.[a-z]{2,4}$/.test(_val);\n } else if (!/\\D.?/g.test(is_validate) && _val.trim().length < is_validate.number()) {\n is_error = true;\n }\n\n if (is_error) {\n errors.push({\n type: is_validate,\n dataPath: dataPath,\n el: this,\n jquery: dom,\n value: val\n });\n }\n }\n });\n });\n\n if (errors.length > 0) {\n return {\n error: errors\n };\n } else {\n return {};\n }\n };\n\n // 클래스 생성자\n this.main = function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }.apply(this, arguments);\n };\n return ax5binder;\n }());\n})();\n// ax5.ui.autocomplete\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var AUTOCOMPLETE;\n\n UI.addClass({\n className: \"autocomplete\",\n version: \"1.3.66\"\n }, function () {\n /**\n * @class ax5autocomplete\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var options = [];\n * options.push({value: \"1\", text: \"string\"});\n * options.push({value: \"2\", text: \"number\"});\n * options.push({value: \"3\", text: \"substr\"});\n * options.push({value: \"4\", text: \"substring\"});\n * options.push({value: \"5\", text: \"search\"});\n * options.push({value: \"6\", text: \"parseInt\"});\n * options.push({value: \"7\", text: \"toFixed\"});\n * options.push({value: \"8\", text: \"min\"});\n * options.push({value: \"9\", text: \"max\"});\n * options.push({value: \"10\", text: \"장기영\"});\n * options.push({value: \"11\", text: \"장서우\"});\n * options.push({value: \"12\", text: \"이영희\"});\n * options.push({value: \"13\", text: \"황인서\"});\n * options.push({value: \"14\", text: \"황세진\"});\n * options.push({value: \"15\", text: \"이서연\"});\n * options.push({value: \"16\", text: \"액시스제이\"});\n * options.push({value: \"17\", text: \"ax5\"});\n * options.push({value: \"18\", text: \"ax5grid\"});\n * options.push({value: \"19\", text: \"ax5combobox\"});\n * options.push({value: \"20\", text: \"ax5autocomplete\"});\n * options.push({value: \"21\", text: \"ax5binder\"});\n * options.push({value: \"22\", text: \"ax5select\"});\n * options.push({value: \"23\", text: \"ax5mask\"});\n * options.push({value: \"24\", text: \"ax5toast\"});\n * options.push({value: \"25\", text: \"ax5dialog\"});\n * options.push({value: \"26\", text: \"ax5modal\"});\n * var myUI = new ax5.ui.autocomplete({\n * theme: \"danger\",\n * removeIcon: '
'\n * });\n * ```\n */\n var ax5autocomplete = function ax5autocomplete() {\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 250,\n removeIcon: 'X',\n lang: {\n noSelected: '',\n noOptions: 'no options',\n loading: 'Now Processing'\n },\n columnKeys: {\n optionValue: 'value',\n optionText: 'text',\n optionSelected: 'selected'\n }\n };\n\n this.queue = [];\n this.activeautocompleteOptionGroup = null;\n this.activeautocompleteQueueIndex = -1;\n this.openTimer = null;\n this.closeTimer = null;\n this.waitOptionsCallback = null;\n this.keyUpTimer = null;\n\n cfg = this.config;\n\n var $window = jQuery(window);\n var ctrlKeys = {\n \"18\": \"KEY_ALT\",\n //\"8\": \"KEY_BACKSPACE\",\n \"17\": \"KEY_CONTROL\",\n \"46\": \"KEY_DELETE\",\n \"40\": \"KEY_DOWN\",\n \"35\": \"KEY_END\",\n \"187\": \"KEY_EQUAL\",\n //\"27\": \"KEY_ESC\",\n \"36\": \"KEY_HOME\",\n \"45\": \"KEY_INSERT\",\n \"37\": \"KEY_LEFT\",\n \"189\": \"KEY_MINUS\",\n \"34\": \"KEY_PAGEDOWN\",\n \"33\": \"KEY_PAGEUP\",\n // \"190\": \"KEY_PERIOD\",\n //\"13\": \"KEY_RETURN\",\n \"39\": \"KEY_RIGHT\",\n \"16\": \"KEY_SHIFT\",\n // \"32\": \"KEY_SPACE\",\n \"9\": \"KEY_TAB\",\n \"38\": \"KEY_UP\",\n \"91\": \"KEY_WINDOW\"\n //\"107\" : \"NUMPAD_ADD\",\n //\"194\" : \"NUMPAD_COMMA\",\n //\"110\" : \"NUMPAD_DECIMAL\",\n //\"111\" : \"NUMPAD_DIVIDE\",\n //\"12\" : \"NUMPAD_EQUAL\",\n //\"106\" : \"NUMPAD_MULTIPLY\",\n //\"109\" : \"NUMPAD_SUBTRACT\"\n },\n onStateChanged = function onStateChanged(item, that) {\n if (item && item.onStateChanged) {\n item.onStateChanged.call(that, that);\n } else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n if (that.state == \"changeValue\") {\n if (item && item.onChange) {\n item.onChange.call(that, that);\n } else if (this.onChange) {\n this.onChange.call(that, that);\n }\n }\n\n item = null;\n that = null;\n return true;\n },\n alignAutocompleteDisplay = function alignAutocompleteDisplay() {\n var i = this.queue.length,\n w;\n\n while (i--) {\n var item = this.queue[i];\n if (item.$display) {\n w = Math.max(item.$select.outerWidth(), U.number(item.minWidth));\n item.$display.css({\n \"min-width\": w\n });\n if (item.reset) {\n item.$display.find(\".addon-icon-reset\").css({\n \"line-height\": this.queue[i].$display.height() + \"px\"\n });\n }\n\n // 높이조절 처리\n if (item.multiple) {\n var displayTableHeightAdjust = function () {\n return U.number(item.$display.css(\"border-top-width\")) + U.number(item.$display.css(\"border-bottom-width\"));\n }.call(this);\n item.$target.height('');\n item.$display.height('');\n\n var displayTableHeight = item.$displayTable.outerHeight();\n if (Math.abs(displayTableHeight - item.$target.height()) > displayTableHeightAdjust) {\n item.$target.css({ height: displayTableHeight + displayTableHeightAdjust + 4 });\n item.$display.css({ height: displayTableHeight + displayTableHeightAdjust + 4 });\n }\n }\n }\n }\n\n i = null;\n w = null;\n return this;\n },\n alignAutocompleteOptionGroup = function alignAutocompleteOptionGroup(append) {\n if (append && !this.activeautocompleteOptionGroup) return this;\n\n var item = this.queue[this.activeautocompleteQueueIndex],\n pos = {},\n positionMargin = 0,\n dim = {},\n pickerDim = {},\n pickerDirection;\n\n if (!item) return this;\n if (append) jQuery(document.body).append(this.activeautocompleteOptionGroup);\n\n pos = item.$target.offset();\n dim = {\n width: item.$target.outerWidth(),\n height: item.$target.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), jQuery(document.body).width()),\n winHeight: Math.max($window.height(), jQuery(document.body).height()),\n width: this.activeautocompleteOptionGroup.outerWidth(),\n height: this.activeautocompleteOptionGroup.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n if (!item.direction || item.direction === \"\" || item.direction === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = item.direction;\n }\n\n if (append) {\n this.activeautocompleteOptionGroup.addClass(\"direction-\" + pickerDirection);\n }\n this.activeautocompleteOptionGroup.css(function () {\n if (pickerDirection == \"top\") {\n if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n\n var newTop = pos.top + pickerDim.height;\n if (newTop + pickerDim.height + positionMargin > pickerDim.winHeight) {\n newTop = 0;\n }\n if (newTop < 0) {\n newTop = 0;\n }\n\n return {\n left: pos.left,\n top: newTop,\n width: dim.width\n };\n }\n return {\n left: pos.left,\n top: pos.top + dim.height + 1,\n width: dim.width\n };\n } else if (pickerDirection == \"bottom\") {\n return {\n left: pos.left,\n top: pos.top - pickerDim.height - 1,\n width: dim.width\n };\n }\n }.call(this));\n },\n onBodyClick = function onBodyClick(e, target) {\n if (!this.activeautocompleteOptionGroup) return this;\n\n var item = this.queue[this.activeautocompleteQueueIndex],\n clickEl = \"display\";\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-option-value\")) {\n clickEl = \"optionItem\";\n return true;\n } else if (item.$target.get(0) == target) {\n clickEl = \"display\";\n return true;\n }\n });\n\n if (!target) {\n this.close();\n return this;\n } else if (clickEl === \"optionItem\") {\n setSelected.call(this, item.id, {\n optionIndex: {\n index: target.getAttribute(\"data-option-index\")\n }\n }, undefined, \"optionItemClick\");\n alignAutocompleteDisplay.call(this);\n alignAutocompleteOptionGroup.call(this);\n if (!item.multiple) {\n this.close();\n }\n } else {}\n\n return this;\n },\n getLabel = function getLabel(queIdx) {\n var item = this.queue[queIdx];\n\n // 템플릿에 전달 해야할 데이터 선언\n var data = {};\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5autocomplete-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n data.selected = item.selected;\n data.hasSelected = data.selected && data.selected.length > 0;\n data.removeIcon = item.removeIcon;\n\n return AUTOCOMPLETE.tmpl.get.call(this, \"label\", data, item.columnKeys);\n },\n syncLabel = function syncLabel(queIdx) {\n var item = this.queue[queIdx];\n\n if (!item.multiple && item.selected && item.selected.length > 0) {\n item.selected = [].concat(item.selected[item.selected.length - 1]);\n }\n\n item.selected.forEach(function (n, nindex) {\n n[\"@index\"] = nindex;\n });\n\n item.$select.html(AUTOCOMPLETE.tmpl.get.call(this, \"formSelectOptions\", {\n selected: item.selected\n }, item.columnKeys));\n },\n printLabel = function printLabel(queIdx) {\n var item = this.queue[queIdx];\n\n item.$displayLabel.find('[data-ax5autocomplete-selected-label]').remove();\n item.$displayLabelInput.before(getLabel.call(this, queIdx));\n },\n focusLabel = function focusLabel(queIdx) {\n if (this.queue[queIdx].disabled) return this;\n\n this.queue[queIdx].$displayLabel.trigger(\"focus\");\n this.queue[queIdx].$displayLabelInput.focus();\n },\n clearLabel = function clearLabel(queIdx) {\n this.queue[queIdx].$displayLabelInput.val('');\n },\n blurLabel = function blurLabel(queIdx) {\n this.queue[queIdx].$displayLabel.trigger(\"blur\");\n },\n onSearch = function onSearch(queIdx, searchWord) {\n if (this.activeautocompleteQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n var regExp = /[\\{\\}\\[\\]\\/?.,;:|\\)*~`!^\\-_+<>@\\#$%&\\\\\\=\\(\\'\\\"]/gi;\n searchWord = searchWord.replace(regExp, \"\");\n\n this.queue[queIdx].waitOptions = true;\n this.queue[queIdx].onSearch.call({\n self: this,\n item: this.queue[queIdx],\n searchWord: searchWord\n }, function (O) {\n\n var data = {};\n var item = this.queue[this.activeautocompleteQueueIndex];\n if (!item) return false;\n\n /// 현재 selected 검증후 처리\n (function (item, O) {\n var optionsMap = {};\n O.options.forEach(function (_O, _OIndex) {\n _O[\"@index\"] = _OIndex;\n _O[\"@findex\"] = _OIndex;\n optionsMap[_O[item.columnKeys.optionValue]] = _O;\n });\n if (U.isArray(item.selected)) {\n item.selected.forEach(function (_O) {\n if (optionsMap[_O[item.columnKeys.optionValue]]) {\n O.options[optionsMap[_O[item.columnKeys.optionValue]][\"@index\"]][item.columnKeys.optionSelected] = true;\n }\n });\n }\n })(item, O);\n\n item.options = O.options;\n\n alignAutocompleteDisplay.call(this);\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5autocomplete-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n this.activeautocompleteOptionGroup.find('[data-els=\"content\"]').html(jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"options\", data, item.columnKeys)));\n\n focusWord.call(this, this.activeautocompleteQueueIndex, searchWord);\n alignAutocompleteOptionGroup.call(this);\n\n setTimeout(function () {\n alignAutocompleteOptionGroup.call(this);\n }.bind(this));\n }.bind(this));\n },\n focusWord = function focusWord(queIdx, searchWord) {\n if (this.activeautocompleteQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n var collect_options = [],\n i = -1,\n l = this.queue[queIdx].options.length - 1,\n n;\n if (searchWord != \"\") {\n while (l - i++) {\n n = this.queue[queIdx].options[i];\n\n if (('' + n.text).toLowerCase() == searchWord.toLowerCase()) {\n collect_options = [{ '@findex': n['@findex'], optionsSort: 0 }];\n break;\n } else {\n var sort = ('' + n.text).toLowerCase().search(searchWord.toLowerCase());\n if (sort > -1) {\n collect_options.push({ '@findex': n['@findex'], optionsSort: sort });\n if (collect_options.length > 2) break;\n }\n sort = null;\n }\n }\n collect_options.sort(function (a, b) {\n return a.optionsSort - b.optionsSort;\n });\n }\n\n if (collect_options && collect_options.length > 0) {\n focusMove.call(this, queIdx, undefined, collect_options[0]['@findex']);\n } else {\n focusClear.call(this, queIdx);\n }\n },\n focusClear = function focusClear(queIdx) {\n if (this.activeautocompleteOptionGroup) {\n this.activeautocompleteOptionGroup.find('[data-option-focus-index]').removeClass(\"hover\").removeAttr(\"data-option-selected\");\n }\n\n this.queue[queIdx].optionFocusIndex = -1;\n },\n focusMove = function focusMove(queIdx, direction, findex) {\n var _focusIndex, _prevFocusIndex, focusOptionEl, optionGroupScrollContainer;\n var item = this.queue[queIdx];\n\n if (this.activeautocompleteOptionGroup && item.options && item.options.length > 0) {\n\n if (typeof findex !== \"undefined\") {\n _focusIndex = findex;\n } else {\n _prevFocusIndex = item.optionFocusIndex == -1 ? item.optionSelectedIndex || -1 : item.optionFocusIndex;\n if (_prevFocusIndex == -1) {\n _focusIndex = 0;\n //_focusIndex = (direction > 0) ? 0 : item.optionItemLength - 1; // 맨 끝으로 보낼것인가 말 것인가.\n } else {\n _focusIndex = _prevFocusIndex + direction;\n if (_focusIndex < 0) _focusIndex = 0;else if (_focusIndex > item.optionItemLength - 1) _focusIndex = item.optionItemLength - 1;\n }\n }\n\n item.optionFocusIndex = _focusIndex;\n\n // 포커스 인덱스가 hide아이템을 만나면 hide 아이템이 안나올 때까지 루프를 순회 합니다.\n if (item.options[_focusIndex] && item.options[_focusIndex].hide) {\n // 옵션이 없는 값이 선택된 경우\n if (typeof direction === \"undefined\") {\n return this;\n } else {\n var isStrop = false;\n while (item.options[_focusIndex].hide) {\n _focusIndex = _focusIndex + direction;\n if (_focusIndex < 0) {\n _focusIndex = 0;\n break;\n } else if (_focusIndex > item.optionItemLength - 1) {\n _focusIndex = item.optionItemLength - 1;\n break;\n }\n }\n }\n }\n\n if (typeof _focusIndex !== \"undefined\") {\n this.activeautocompleteOptionGroup.find('[data-option-focus-index]').removeClass(\"hover\");\n\n focusOptionEl = this.activeautocompleteOptionGroup.find('[data-option-focus-index=\"' + _focusIndex + '\"]').addClass(\"hover\");\n\n optionGroupScrollContainer = this.activeautocompleteOptionGroup.find('[data-els=\"content\"]');\n\n if (focusOptionEl.get(0)) {\n var focusOptionElHeight = focusOptionEl.outerHeight(),\n optionGroupScrollContainerHeight = optionGroupScrollContainer.innerHeight(),\n optionGroupScrollContainerScrollTop = optionGroupScrollContainer.scrollTop(),\n focusOptionElTop = focusOptionEl.position().top + optionGroupScrollContainer.scrollTop();\n\n if (optionGroupScrollContainerHeight + optionGroupScrollContainerScrollTop < focusOptionElTop + focusOptionElHeight) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop + focusOptionElHeight - optionGroupScrollContainerHeight);\n } else if (optionGroupScrollContainerScrollTop > focusOptionElTop) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop);\n }\n // optionGroup scroll check\n\n if (typeof direction !== \"undefined\") {\n item.$displayLabelInput.val(item.options[_focusIndex].text);\n }\n }\n }\n }\n },\n getQueIdx = function getQueIdx(boundID) {\n if (boundID instanceof jQuery) {\n boundID = boundID.data(\"data-ax5autocomplete-id\");\n } else if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-ax5autocomplete-id\");\n }\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"getQueIdx\"));\n return;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n },\n getSelected = function getSelected(_item, o, selected) {\n if (typeof selected === \"undefined\") {\n return _item.multiple ? !o : true;\n } else {\n return selected;\n }\n },\n clearSelected = function clearSelected(queIdx) {\n this.queue[queIdx].options.forEach(function (n) {\n if (n.optgroup) {\n n.options.forEach(function (nn) {\n nn.selected = false;\n });\n } else {\n n.selected = false;\n }\n });\n\n this.queue[queIdx].selected = [];\n this.queue[queIdx].$select.html(AUTOCOMPLETE.tmpl.get.call(this, \"formSelectOptions\", {\n selected: this.queue[queIdx].selected\n }, this.queue[queIdx].columnKeys));\n },\n setSelected = function () {\n var processor = {\n 'selectedIndex': function selectedIndex(queIdx, value, selected, setValueType) {},\n 'removeSelectedIndex': function removeSelectedIndex(queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx],\n addOptions = {};\n var newSelectedArray = [],\n optionIndex = 0;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i]['@index'] != value.removeSelectedIndex.index) {\n addOptions = { '@index': optionIndex, '@findex': optionIndex };\n addOptions[item.columnKeys.optionValue] = item.selected[i][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.selected[i][item.columnKeys.optionText];\n newSelectedArray.push(addOptions);\n optionIndex++;\n }\n }\n item.selected = newSelectedArray;\n },\n 'optionIndex': function optionIndex(queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx],\n addOptions = {};\n var optionIndex = item.selected.length;\n var pushOk = true;\n\n addOptions = {\n '@index': optionIndex, '@findex': optionIndex\n };\n addOptions[item.columnKeys.optionValue] = item.options[value.optionIndex.index][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.options[value.optionIndex.index][item.columnKeys.optionText];\n\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][item.columnKeys.optionValue] == addOptions[item.columnKeys.optionValue]) {\n pushOk = false;\n }\n }\n if (pushOk) item.selected.push(addOptions);\n },\n 'arr': function arr(queIdx, values, selected, setValueType) {\n values.forEach(function (value) {\n if (U.isString(value) || U.isNumber(value)) {\n processor.text.call(self, queIdx, value, selected, \"justSetValue\");\n } else {\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(self, queIdx, value, selected, \"justSetValue\");\n break;\n }\n }\n }\n });\n },\n 'value': function value(queIdx, _value4, selected, setValueType) {\n var item = this.queue[queIdx];\n var addOptions;\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionValue] == _value4.value[item.columnKeys.optionValue];\n });\n\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n\n if (item.options[optionIndex][item.columnKeys.optionSelected]) {\n var appendOk = true;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionValue] == item.options[optionIndex][cfg.columnKeys.optionValue]) {\n appendOk = false;\n break;\n }\n }\n if (appendOk) {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = item.options[optionIndex][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.options[optionIndex][item.columnKeys.optionText];\n item.selected.push(addOptions);\n }\n } else {\n var newSelectedArray = [];\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionValue] == item.options[optionIndex][cfg.columnKeys.optionValue]) {} else {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = item.selected[i][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.selected[i][item.columnKeys.optionText];\n newSelectedArray.push(addOptions);\n }\n }\n item.selected = newSelectedArray;\n }\n } else {\n // 새로운 값 추가\n var appendOk = true;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionValue] == _value4.value[cfg.columnKeys.optionValue]) {\n appendOk = false;\n break;\n }\n }\n\n if (appendOk) {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = _value4.value[cfg.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = _value4.value[cfg.columnKeys.optionText];\n item.selected.push(addOptions);\n }\n }\n },\n 'text': function text(queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx];\n var addOptions;\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionText] == value;\n });\n\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n\n if (item.options[optionIndex][item.columnKeys.optionSelected]) {\n var appendOk = true;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionText] == item.options[optionIndex][cfg.columnKeys.optionText]) {\n appendOk = false;\n break;\n }\n }\n if (appendOk) {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = item.options[optionIndex][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.options[optionIndex][item.columnKeys.optionText];\n item.selected.push(addOptions);\n }\n } else {\n var newSelectedArray = [];\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionText] == item.options[optionIndex][cfg.columnKeys.optionText]) {} else {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = item.selected[i][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.selected[i][item.columnKeys.optionText];\n newSelectedArray.push(addOptions);\n }\n }\n item.selected = newSelectedArray;\n }\n } else {\n // 새로운 값 추가\n var appendOk = true;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionText] == value) {\n appendOk = false;\n break;\n }\n }\n\n if (appendOk) {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = value;\n addOptions[item.columnKeys.optionText] = value;\n item.selected.push(addOptions);\n }\n }\n },\n 'clear': function clear(queIdx) {\n clearSelected.call(this, queIdx);\n focusClear.call(this, queIdx);\n\n if (this.activeautocompleteOptionGroup) {\n this.activeautocompleteOptionGroup.find('[data-option-index]').attr(\"data-option-Selected\", \"false\");\n }\n this.queue[queIdx].optionSelectedIndex = -1;\n }\n };\n return function (boundID, value, selected, _option) {\n\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n\n if (typeof value == \"undefined\") {\n throw \"error not found value\";\n } else if (U.isArray(value)) {\n processor.clear.call(this, queIdx);\n processor.arr.call(this, queIdx, this.queue[queIdx].multiple || value.length == 0 ? value : [value[value.length - 1]], selected);\n } else if (U.isString(value) || U.isNumber(value)) {\n if (typeof value !== \"undefined\" && value !== null && !this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n processor.text.call(this, queIdx, value, selected);\n } else {\n if (value === null) {\n processor.clear.call(this, queIdx);\n } else {\n if (!this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(this, queIdx, value, selected);\n break;\n }\n }\n }\n }\n\n syncLabel.call(this, queIdx);\n printLabel.call(this, queIdx);\n focusLabel.call(this, queIdx);\n alignAutocompleteOptionGroup.call(this);\n\n if (typeof value !== \"undefined\") {\n if (_option && !_option.noStateChange) {\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n item: this.queue[queIdx],\n state: \"changeValue\",\n value: this.queue[queIdx].selected\n });\n }\n }\n\n boundID = null;\n return this;\n };\n }();\n\n /// private end\n\n /**\n * Preferences of autocomplete UI\n * @method ax5autocomplete.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5autocomplete}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onChange = cfg.onChange;\n jQuery(window).bind(\"resize.ax5autocomplete-display-\" + this.instanceId, function () {\n alignAutocompleteDisplay.call(this);\n }.bind(this));\n };\n\n /**\n * bind autocomplete\n * @method ax5autocomplete.bind\n * @param {Object} item\n * @param {String} [item.id]\n * @param {String} [item.theme]\n * @param {Boolean} [item.multiple]\n * @param {Element} item.target\n * @returns {ax5autocomplete}\n */\n this.bind = function (item) {\n var bindAutocompleteTarget = function () {\n var debouncedFocusWord = U.debounce(function (queIdx) {\n if (this.activeautocompleteQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n onSearch.call(self, queIdx, this.queue[queIdx].$displayLabelInput.val());\n }, 150);\n\n var blurLabel = function blurLabel(queIdx) {\n clearLabel.call(this, queIdx);\n };\n\n var autocompleteEvent = {\n 'click': function click(queIdx, e) {\n var clickEl;\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-ax5autocomplete-remove\")) {\n clickEl = \"optionItemRemove\";\n return true;\n } else if (target.getAttribute(\"data-selected-clear\")) {\n clickEl = \"clear\";\n return true;\n }\n });\n\n if (target) {\n if (clickEl === \"optionItemRemove\") {\n var removeIndex = target.getAttribute(\"data-ax5autocomplete-remove-index\");\n this.queue[queIdx].selected.splice(removeIndex, 1);\n syncLabel.call(this, queIdx);\n printLabel.call(this, queIdx);\n focusLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n alignAutocompleteOptionGroup.call(this);\n U.stopEvent(e);\n return this;\n } else if (clickEl === \"clear\") {\n setSelected.call(this, queIdx, { clear: true });\n alignAutocompleteDisplay.call(this);\n alignAutocompleteOptionGroup.call(this);\n }\n } else {\n if (self.activeautocompleteQueueIndex == queIdx) {\n if (this.queue[queIdx].optionFocusIndex == -1) {\n // 아이템에 포커스가 활성화 된 후, 마우스 이벤트 이면 무시\n self.close();\n }\n } else {\n focusLabel.call(this, queIdx);\n }\n }\n },\n 'keyUp': function keyUp(queIdx, e) {\n /// 약속된 키 이벤트가 발생하면 stopEvent를 통해 keyUp 이벤트가 발생되지 않도록 막아주는 센스\n if (e.which == ax5.info.eventKeys.ESC && self.activeautocompleteQueueIndex === -1) {\n // ESC키를 누르고 옵션그룹이 열려있지 않은 경우\n U.stopEvent(e);\n return this;\n }\n if (e.which == ax5.info.eventKeys.TAB) {\n // nothing\n\n this.close();\n return this;\n }\n if (self.activeautocompleteQueueIndex != queIdx) {\n // 닫힌 상태 인경우\n self.open(queIdx); // open and align\n }\n if (ctrlKeys[e.which]) {\n U.stopEvent(e);\n } else {\n // backspace 감지 하여 input 값이 없으면 스탑이벤트 처리 할 것\n if (e.which == ax5.info.eventKeys.BACKSPACE && this.queue[queIdx].$displayLabelInput.val() == \"\") {\n // 마지막 아이템을 제거.\n this.queue[queIdx].selected.pop();\n syncLabel.call(this, queIdx);\n printLabel.call(this, queIdx);\n focusLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n alignAutocompleteOptionGroup.call(this);\n U.stopEvent(e);\n } else {\n debouncedFocusWord.call(this, queIdx);\n }\n }\n },\n 'keyDown': function keyDown(queIdx, e) {\n if (e.which == ax5.info.eventKeys.ESC) {\n clearLabel.call(this, queIdx);\n this.close();\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.RETURN) {\n var inputValue = this.queue[queIdx].$displayLabelInput.val();\n if (item.optionFocusIndex > -1) {\n setSelected.call(this, item.id, {\n optionIndex: {\n index: item.optionFocusIndex\n }\n }, undefined, \"optionItemClick\");\n } else if (inputValue != \"\") {\n setSelected.call(this, queIdx, inputValue, true);\n }\n clearLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n this.close();\n\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.DOWN) {\n focusMove.call(this, queIdx, 1);\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.UP) {\n focusMove.call(this, queIdx, -1);\n U.stopEvent(e);\n }\n },\n 'focus': function focus(queIdx, e) {\n // console.log(e);\n\n },\n 'blur': function blur(queIdx, e) {\n blurLabel.call(this, queIdx);\n U.stopEvent(e);\n },\n 'selectChange': function selectChange(queIdx, e) {\n setSelected.call(this, queIdx, { value: this.queue[queIdx].$select.val() }, true);\n }\n };\n\n return function (queIdx) {\n var item = this.queue[queIdx];\n var data = {};\n\n if (!item.$display) {\n /// 템플릿에 전달할 오브젝트 선언\n data.instanceId = this.instanceId;\n data.id = item.id;\n data.name = item.name;\n data.theme = item.theme;\n data.tabIndex = item.tabIndex;\n data.multiple = item.multiple;\n data.reset = item.reset;\n\n data.label = getLabel.call(this, queIdx);\n data.formSize = function () {\n return item.size ? \"input-\" + item.size : \"\";\n }();\n\n item.$display = jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"autocompleteDisplay\", data, item.columnKeys));\n item.$displayTable = item.$display.find('[data-els=\"display-table\"]');\n item.$displayLabel = item.$display.find('[data-ax5autocomplete-display=\"label\"]');\n item.$displayLabelInput = item.$display.find('[data-ax5autocomplete-display=\"input\"]');\n\n if (item.$target.find(\"select\").get(0)) {\n item.$select = item.$target.find(\"select\");\n item.$select.attr(\"tabindex\", \"-1\").attr(\"class\", \"form-control \" + data.formSize);\n\n if (data.name) {\n item.$select.attr(\"name\", \"name\");\n }\n item.$select.attr(\"multiple\", \"multiple\");\n } else {\n item.$select = jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"formSelect\", data, item.columnKeys));\n item.$target.append(item.$select);\n }\n\n item.$target.append(item.$display);\n } else {\n printLabel.call(this, queIdx);\n }\n\n alignAutocompleteDisplay.call(this);\n\n item.$display.unbind('click.ax5autocomplete').bind('click.ax5autocomplete', autocompleteEvent.click.bind(this, queIdx));\n\n // autocomplete 태그에 대한 이벤트 감시\n\n item.$displayLabelInput.off(\"focus.ax5autocomplete\").on(\"focus.ax5autocomplete\", autocompleteEvent.focus.bind(this, queIdx)).off(\"blur.ax5autocomplete\").on(\"blur.ax5autocomplete\", autocompleteEvent.blur.bind(this, queIdx)).off(\"keydown.ax5autocomplete\").on(\"keydown.ax5autocomplete\", autocompleteEvent.keyUp.bind(this, queIdx)).off(\"keyup.ax5autocomplete\").on(\"keyup.ax5autocomplete\", autocompleteEvent.keyDown.bind(this, queIdx));\n\n // select 태그에 대한 change 이벤트 감시\n\n item.$select.unbind('change.ax5autocomplete').bind('change.ax5autocomplete', autocompleteEvent.selectChange.bind(this, queIdx));\n\n data = null;\n item = null;\n queIdx = null;\n return this;\n };\n }();\n\n var autocompleteConfig = {},\n queIdx;\n\n item = jQuery.extend(true, autocompleteConfig, cfg, item);\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"401\", \"bind\"));\n return this;\n }\n\n item.$target = jQuery(item.target);\n\n if (!item.id) item.id = item.$target.data(\"data-ax5autocomplete-id\");\n if (!item.id) {\n item.id = 'ax5autocomplete-' + ax5.getGuid();\n item.$target.data(\"data-ax5autocomplete-id\", item.id);\n }\n item.name = item.$target.attr(\"data-ax5autocomplete\");\n\n item.options = [];\n item.selected = [];\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n item = jQuery.extend(true, item, data);\n }\n })(U.parseJson(item.$target.attr(\"data-ax5autocomplete-config\"), true));\n\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindAutocompleteTarget.call(this, this.queue.length - 1);\n } else {\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindAutocompleteTarget.call(this, queIdx);\n }\n\n autocompleteConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * open the optionBox of autocomplete\n * @method ax5autocomplete.open\n * @param {(String|Number|Element)} boundID\n * @param {Number} [tryCount]\n * @returns {ax5autocomplete}\n */\n this.open = function () {\n\n return function (boundID, tryCount) {\n this.waitOptionsCallback = null;\n\n /**\n * open autocomplete from the outside\n */\n var queIdx = U.isNumber(boundID) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n var data = {},\n focusTop,\n selectedOptionEl;\n\n if (item.$display.attr(\"disabled\")) return this;\n\n if (this.openTimer) clearTimeout(this.openTimer);\n if (this.activeautocompleteOptionGroup) {\n if (this.activeautocompleteQueueIndex == queIdx) {\n return this;\n }\n\n if (tryCount > 2) return this;\n this.close();\n this.openTimer = setTimeout(function () {\n this.open(queIdx, (tryCount || 0) + 1);\n }.bind(this), cfg.animateTime);\n\n return this;\n }\n\n item.optionFocusIndex = -1; // optionGroup이 열리면 포커스 인덱스 초기화 -1로\n if (item.selected && item.selected.length > 0) {\n item.optionSelectedIndex = item.selected[0][\"@findex\"];\n }\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5autocomplete-option-group-\" + item.size;\n data.multiple = item.multiple;\n\n data.lang = item.lang;\n item.$display.attr(\"data-autocomplete-option-group-opened\", \"true\");\n\n data.waitOptions = true;\n data.options = [];\n\n this.activeautocompleteOptionGroup = jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"optionGroup\", data, item.columnKeys));\n this.activeautocompleteOptionGroup.find('[data-els=\"content\"]').html(jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"options\", data, item.columnKeys)));\n this.activeautocompleteQueueIndex = queIdx;\n\n alignAutocompleteOptionGroup.call(this, \"append\"); // alignAutocompleteOptionGroup 에서 body append\n jQuery(window).bind(\"resize.ax5autocomplete-\" + this.instanceId, function () {\n alignAutocompleteOptionGroup.call(this);\n }.bind(this));\n\n if (item.selected && item.selected.length > 0) {\n selectedOptionEl = this.activeautocompleteOptionGroup.find('[data-option-index=\"' + item.selected[0][\"@index\"] + '\"]');\n if (selectedOptionEl.get(0)) {\n focusTop = selectedOptionEl.position().top - this.activeautocompleteOptionGroup.height() / 3;\n this.activeautocompleteOptionGroup.find('[data-els=\"content\"]').stop().animate({ scrollTop: focusTop }, item.animateTime, 'swing', function () {});\n }\n }\n\n jQuery(window).bind(\"click.ax5autocomplete-\" + this.instanceId, function (e) {\n e = e || window.event;\n onBodyClick.call(this, e);\n U.stopEvent(e);\n }.bind(this));\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"open\",\n item: item\n });\n\n data = null;\n focusTop = null;\n selectedOptionEl = null;\n return this;\n };\n }();\n\n /**\n * @method ax5autocomplete.setValue\n * @param {(jQueryObject|Element|Number)} _boundID\n * @param {(String|Array)} _value\n * @return {ax5autocomplete}\n * @example\n * ```js\n * myAutocomplete.setValue($('[data-ax5autocomplete=\"autocomplete1\"]'), {value:\"test\", text:\"test\"});\n * myAutocomplete.setValue($('[data-ax5autocomplete=\"autocomplete1\"]'), [{value:\"test1\", text:\"test1\"}, {value:\"test2\", text:\"test2\"}]);\n * myAutocomplete.setValue($('[data-ax5autocomplete=\"autocomplete1\"]'), null);\n * ```\n */\n this.setValue = function (_boundID, _value) {\n var queIdx = U.isNumber(_boundID) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n\n clearSelected.call(this, queIdx);\n\n if (U.isArray(_value)) {\n var _values = U.map(_value, function () {\n return { value: this };\n });\n setSelected.call(this, queIdx, _values, true, { noStateChange: true });\n } else if (U.isObject(_value)) {\n setSelected.call(this, queIdx, { value: _value }, true, { noStateChange: true });\n } else {\n printLabel.call(this, queIdx);\n }\n\n blurLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n\n return this;\n };\n\n /**\n * @method ax5autocomplete.setText\n * @param {(jQueryObject|Element|Number)} _boundID\n * @param {(String|Array)} _text\n * @returns {ax5autocomplete}\n * @example\n * ```js\n * myAutocomplete.setText($('[data-ax5autocomplete=\"autocomplete1\"]'), \"string\");\n * myAutocomplete.setText($('[data-ax5autocomplete=\"autocomplete1\"]'), [\"substring\", \"search\"]);\n * ```\n */\n this.setText = function (_boundID, _text) {\n var queIdx = U.isNumber(_boundID) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n this.queue[queIdx].selected = [];\n clearSelected.call(this, queIdx);\n setSelected.call(this, queIdx, _text, true, { noStateChange: true });\n blurLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n\n return this;\n };\n\n /**\n * @method ax5autocomplete.getSelectedOption\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {Array}\n */\n this.getSelectedOption = function (_boundID) {\n var queIdx = U.isNumber(_boundID) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n return U.deepCopy(this.queue[queIdx].selected);\n };\n\n /**\n * @method ax5autocomplete.close\n * @returns {ax5autocomplete}\n */\n this.close = function (item) {\n if (this.closeTimer) clearTimeout(this.closeTimer);\n if (!this.activeautocompleteOptionGroup) return this;\n\n item = this.queue[this.activeautocompleteQueueIndex];\n item.optionFocusIndex = -1;\n item.$display.removeAttr(\"data-autocomplete-option-group-opened\").trigger(\"focus\");\n\n this.activeautocompleteOptionGroup.addClass(\"destroy\");\n\n jQuery(window).unbind(\"resize.ax5autocomplete-\" + this.instanceId).unbind(\"click.ax5autocomplete-\" + this.instanceId).unbind(\"keyup.ax5autocomplete-\" + this.instanceId);\n\n this.closeTimer = setTimeout(function () {\n if (this.activeautocompleteOptionGroup) this.activeautocompleteOptionGroup.remove();\n this.activeautocompleteOptionGroup = null;\n this.activeautocompleteQueueIndex = -1;\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"close\"\n });\n }.bind(this), cfg.animateTime);\n this.waitOptionsCallback = null;\n return this;\n };\n\n /**\n * @method ax5autocomplete.blur\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5autocomplete}\n */\n this.blur = function (_boundID) {\n var queIdx = U.isNumber(_boundID) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n\n blurLabel.call(this, queIdx);\n return this;\n };\n\n /**\n * @method ax5autocomplete.enable\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5autocomplete}\n */\n this.enable = function (_boundID) {\n var queIdx = getQueIdx.call(this, _boundID);\n\n if (typeof queIdx !== \"undefined\") {\n this.queue[queIdx].disable = false;\n if (this.queue[queIdx].$display[0]) {\n this.queue[queIdx].$display.removeAttr(\"disabled\");\n this.queue[queIdx].$displayLabelInput.removeAttr(\"disabled\");\n }\n if (this.queue[queIdx].$select[0]) {\n this.queue[queIdx].$select.removeAttr(\"disabled\");\n }\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"enable\"\n });\n }\n\n return this;\n };\n\n /**\n * @method ax5autocomplete.disable\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5autocomplete}\n */\n this.disable = function (_boundID) {\n var queIdx = getQueIdx.call(this, _boundID);\n\n if (typeof queIdx !== \"undefined\") {\n this.queue[queIdx].disable = true;\n if (this.queue[queIdx].$display[0]) {\n this.queue[queIdx].$display.attr(\"disabled\", \"disabled\");\n this.queue[queIdx].$displayLabelInput.attr(\"disabled\", \"disabled\");\n }\n if (this.queue[queIdx].$select[0]) {\n this.queue[queIdx].$select.attr(\"disabled\", \"disabled\");\n }\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"disable\"\n });\n }\n\n return this;\n };\n\n /**\n * @method ax5autocomplete.align\n */\n this.align = function () {\n alignAutocompleteDisplay.call(this);\n return this;\n };\n\n // 클래스 생성자\n this.main = function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n } else {\n this.init();\n }\n }.apply(this, arguments);\n };\n return ax5autocomplete;\n }());\n\n AUTOCOMPLETE = ax5.ui.autocomplete;\n})();\n\n/**\n * autocomplete jquery extends\n * @namespace jQueryExtends\n */\n\n/**\n * @method jQueryExtends.ax5autocomplete\n * @param {String} methodName\n * @param [arguments]\n * @param [arguments]\n * @example\n * ```html\n *
\n * \n * ```\n */\nax5.ui.autocomplete_instance = new ax5.ui.autocomplete();\njQuery.fn.ax5autocomplete = function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"open\":\n return ax5.ui.autocomplete_instance.open(this);\n break;\n case \"close\":\n return ax5.ui.autocomplete_instance.close(this);\n break;\n case \"setValue\":\n return ax5.ui.autocomplete_instance.setValue(this, arguments[1], arguments[2], arguments[3], arguments[4] || \"justSetValue\");\n break;\n case \"setText\":\n return ax5.ui.autocomplete_instance.setText(this, arguments[1], arguments[2], arguments[3], arguments[4] || \"justSetValue\");\n break;\n case \"getSelectedOption\":\n return ax5.ui.autocomplete_instance.getSelectedOption(this);\n break;\n case \"enable\":\n return ax5.ui.autocomplete_instance.enable(this);\n break;\n case \"disable\":\n return ax5.ui.autocomplete_instance.disable(this);\n break;\n case \"blur\":\n return ax5.ui.autocomplete_instance.blur(this);\n default:\n return this;\n }\n } else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.autocomplete_instance.bind(config);\n });\n }\n return this;\n };\n}();\n\n// todo : editable 지원.\n// 아이템 박스 안에서 제거 할때 디스플레이 정렬\n// ax5.ui.autocomplete.tmpl\n(function () {\n var AUTOCOMPLETE = ax5.ui.autocomplete;\n var U = ax5.util;\n\n var optionGroup = function optionGroup(columnKeys) {\n return '\\n
\\n';\n };\n\n var autocompleteDisplay = function autocompleteDisplay(columnKeys) {\n return ' \\n
\\n
\\n
\\n
\\n
\\n {{#multiple}}{{#reset}}\\n {{{.}}}\\n {{/reset}}{{/multiple}}\\n
\\n
\\n\\n';\n };\n\n var formSelect = function formSelect(columnKeys) {\n return '\\n
\\n';\n };\n\n var formSelectOptions = function formSelectOptions(columnKeys) {\n return '\\n{{#selected}}\\n
\\n{{/selected}}\\n';\n };\n\n var options = function options(columnKeys) {\n return '\\n{{#waitOptions}}\\n
\\n
\\n \\n {{{lang.loading}}}\\n \\n
\\n
\\n{{/waitOptions}}\\n{{^waitOptions}}\\n {{#options}}\\n {{^hide}}\\n
\\n
\\n {{' + columnKeys.optionText + '}}\\n
\\n
\\n {{/hide}}\\n {{/options}}\\n {{^options}}\\n
\\n
\\n \\n {{{lang.noOptions}}}\\n \\n
\\n
\\n {{/options}}\\n{{/waitOptions}}\\n';\n };\n\n var label = function label(columnKeys) {\n return '{{#selected}}
{{/selected}}';\n };\n\n AUTOCOMPLETE.tmpl = {\n \"autocompleteDisplay\": autocompleteDisplay,\n \"formSelect\": formSelect,\n \"formSelectOptions\": formSelectOptions,\n \"optionGroup\": optionGroup,\n \"options\": options,\n \"label\": label,\n\n get: function get(tmplName, data, columnKeys) {\n return ax5.mustache.render(AUTOCOMPLETE.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();","(function () {\n 'use strict';\n\n // root of function\n var root = this, win = this;\n var doc = (win) ? win.document : null, docElem = (win) ? win.document.documentElement : null;\n var reIsJson = /^([\"'](\\\\.|[^\"\\\\\\n\\r])*?[\"']|[,:{}\\[\\]0-9.\\-+Eaeflnr-u \\n\\r\\t])+?$/,\n reMs = /^-ms-/,\n reSnakeCase = /[\\-_]([\\da-z])/gi,\n reCamelCase = /([A-Z])/g,\n reDot = /\\./,\n reInt = /[-|+]?[\\D]/gi,\n reNotNum = /\\D/gi,\n reMoneySplit = new RegExp('([0-9])([0-9][0-9][0-9][,.])'),\n reAmp = /&/g,\n reEq = /=/,\n reClassNameSplit = /[ ]+/g,\n\n /** @namespace {Object} ax5 */\n ax5 = {}, info, U, dom;\n\n /**\n * guid\n * @member {Number} ax5.guid\n */\n ax5.guid = 1;\n /**\n * ax5.guid를 구하고 증가시킵니다.\n * @method ax5.getGuid\n * @returns {Number} guid\n */\n ax5.getGuid = function () {\n return ax5.guid++;\n };\n\n /**\n * 상수모음\n * @namespace ax5.info\n */\n ax5.info = info = (function () {\n /**\n * ax5 version\n * @member {String} ax5.info.version\n */\n var version = \"1.3.66\";\n\n /**\n * ax5 library path\n * @member {String} ax5.info.baseUrl\n */\n var baseUrl = \"\";\n\n /**\n * ax5 에러 출력메세지 사용자 재 정의\n * @member {Object} ax5.info.onerror\n * @examples\n * ```\n * ax5.info.onerror = function(){\n\t\t * console.log(arguments);\n\t\t * }\n * ```\n */\n var onerror = function () {\n console.error(U.toArray(arguments).join(\":\"));\n };\n\n /**\n * event keyCodes\n * @member {Object} ax5.info.eventKeys\n * @example\n * ```\n * {\n\t\t * \tBACKSPACE: 8, TAB: 9,\n\t\t * \tRETURN: 13, ESC: 27, LEFT: 37, UP: 38, RIGHT: 39, DOWN: 40, DELETE: 46,\n\t\t * \tHOME: 36, END: 35, PAGEUP: 33, PAGEDOWN: 34, INSERT: 45, SPACE: 32\n\t\t * }\n * ```\n */\n var eventKeys = {\n BACKSPACE: 8, TAB: 9,\n RETURN: 13, ESC: 27, LEFT: 37, UP: 38, RIGHT: 39, DOWN: 40, DELETE: 46,\n HOME: 36, END: 35, PAGEUP: 33, PAGEDOWN: 34, INSERT: 45, SPACE: 32\n };\n\n /**\n * week names\n * @member {Object[]} weekNames\n * @member {string} weekNames[].label\n *\n * @example\n * ```\n * [\n * {label: \"SUN\"},{label: \"MON\"},{label: \"TUE\"},{label: \"WED\"},{label: \"THU\"},{label: \"FRI\"},{label: \"SAT\"}\n * ]\n * console.log( weekNames[0] );\n * console.log( ax5.info.weekNames[(new Date()).getDay()].label )\n * ```\n */\n var weekNames = [\n {label: \"SUN\"},\n {label: \"MON\"},\n {label: \"TUE\"},\n {label: \"WED\"},\n {label: \"THU\"},\n {label: \"FRI\"},\n {label: \"SAT\"}\n ];\n\n /**\n * 사용자 브라우저 식별용 오브젝트\n * @member {Object} ax5.info.browser\n * @example\n * ```\n * console.log( ax5.info.browser );\n * //Object {name: \"chrome\", version: \"39.0.2171.71\", mobile: false}\n * ```\n */\n var browser = (function (ua, mobile, browserName, match, browser, browserVersion) {\n if (!win || !win.navigator) return {};\n\n ua = navigator.userAgent.toLowerCase(), mobile = (ua.search(/mobile/g) != -1), browserName, match, browser, browserVersion;\n\n if (ua.search(/iphone/g) != -1) {\n return {name: \"iphone\", version: 0, mobile: true}\n }\n else if (ua.search(/ipad/g) != -1) {\n return {name: \"ipad\", version: 0, mobile: true}\n }\n else if (ua.search(/android/g) != -1) {\n match = /(android)[ \\/]([\\w.]+)/.exec(ua) || [];\n browserVersion = (match[2] || \"0\");\n return {name: \"android\", version: browserVersion, mobile: mobile}\n }\n else {\n browserName = \"\";\n match = /(opr)[ \\/]([\\w.]+)/.exec(ua) || /(chrome)[ \\/]([\\w.]+)/.exec(ua) || /(webkit)[ \\/]([\\w.]+)/.exec(ua) || /(msie) ([\\w.]+)/.exec(ua) || ua.indexOf(\"compatible\") < 0 && /(mozilla)(?:.*? rv:([\\w.]+)|)/.exec(ua) || [];\n browser = (match[1] || \"\");\n browserVersion = (match[2] || \"0\");\n\n if (browser == \"msie\") browser = \"ie\";\n return {\n name: browser,\n version: browserVersion,\n mobile: mobile\n }\n }\n ua = null, mobile = null, browserName = null, match = null, browser = null, browserVersion = null;\n })();\n\n /**\n * 브라우저 여부\n * @member {Boolean} ax5.info.isBrowser\n */\n var isBrowser = !!(typeof window !== 'undefined' && typeof navigator !== 'undefined' && win.document);\n\n /**\n * 브라우저에 따른 마우스 휠 이벤트이름\n * @member {Object} ax5.info.wheelEnm\n */\n var wheelEnm = (win && (/Firefox/i.test(navigator.userAgent)) ? \"DOMMouseScroll\" : \"mousewheel\");\n\n /**\n * 첫번째 자리수 동사 - (필요한것이 없을때 : 4, 실행오류 : 5)\n * 두번째 자리수 목적어 - 문자열 0, 숫자 1, 배열 2, 오브젝트 3, 함수 4, DOM 5, 파일 6, 기타 7\n * 세번째 자리수 옵션\n * @member {Object} ax5.info.errorMsg\n */\n var errorMsg = {};\n\n /**\n * 현재 페이지의 Url 정보를 리턴합니다.\n * @method ax5.info.urlUtil\n * @returns {Object}\n * @example\n * ```\n * console.log( ax5.util.toJson( ax5.info.urlUtil() ) );\n * {\n\t\t *\t\"baseUrl\": \"http://ax5:2018\",\n\t\t *\t\"href\": \"http://ax5:2018/samples/index.html?a=1&b=1#abc\",\n\t\t *\t\"param\": \"a=1&b=1\",\n\t\t *\t\"referrer\": \"\",\n\t\t *\t\"pathname\": \"/samples/index.html\",\n\t\t *\t\"hostname\": \"ax5\",\n\t\t *\t\"port\": \"2018\",\n\t\t *\t\"url\": \"http://ax5:2018/samples/index.html\",\n\t\t *\t\"hashdata\": \"abc\"\n\t\t * }\n * ```\n */\n function urlUtil(url, urls) {\n url = {\n href: win.location.href,\n param: win.location.search,\n referrer: doc.referrer,\n pathname: win.location.pathname,\n hostname: win.location.hostname,\n port: win.location.port\n }, urls = url.href.split(/[\\?#]/);\n url.param = url.param.replace(\"?\", \"\");\n url.url = urls[0];\n if (url.href.search(\"#\") > -1) {\n url.hashdata = U.last(urls);\n }\n urls = null;\n url.baseUrl = U.left(url.href, \"?\").replace(url.pathname, \"\");\n return url;\n }\n\n /**\n * ax5-error-msg.js 에 정의된 ax5 error를 반환합니다.\n * @method ax5.info.getError\n * @returns {Object}\n * @example\n * ```\n * console.log( ax5.info.getError(\"single-uploader\", \"460\", \"upload\") );\n *\n * if(!this.selectedFile){\n\t\t * if (cfg.onEvent) {\n\t\t * \tvar that = {\n\t\t * \t\taction: \"error\",\n\t\t * \t\terror: ax5.info.getError(\"single-uploader\", \"460\", \"upload\")\n\t\t * \t};\n\t\t * \tcfg.onEvent.call(that, that);\n\t\t * }\n\t\t * return this;\n\t\t * }\n * ```\n */\n function getError(className, errorCode, methodName) {\n if (info.errorMsg && info.errorMsg[className]) {\n return {\n className: className,\n errorCode: errorCode,\n methodName: methodName,\n msg: info.errorMsg[className][errorCode]\n };\n }\n else {\n return {className: className, errorCode: errorCode, methodName: methodName};\n }\n }\n\n /**\n * 브라우져의 터치 기능 유무를 확인합니다.\n * @method ax5.info.supportTouch\n * @returns {boolean}\n * @example\n * ```\n * var chkFlag = ax5.info.supportTouch;\n */\n let supportTouch = (win) ? (('ontouchstart' in win) || (navigator.maxTouchPoints > 0) || (navigator.msMaxTouchPoints > 0)) : false;\n\n let supportFileApi = (win) ? ( win.FileReader && win.File && win.FileList && win.Blob ) : false;\n\n return {\n errorMsg: errorMsg,\n version: version,\n baseUrl: baseUrl,\n onerror: onerror,\n eventKeys: eventKeys,\n weekNames: weekNames,\n browser: browser,\n isBrowser: isBrowser,\n supportTouch: supportTouch,\n supportFileApi: supportFileApi,\n wheelEnm: wheelEnm,\n urlUtil: urlUtil,\n getError: getError\n };\n })();\n\n /**\n * Refer to this by {@link ax5}.\n * @namespace ax5.util\n */\n ax5['util'] = U = (function () {\n var _toString = Object.prototype.toString;\n\n /**\n * Object나 Array의 아이템으로 사용자 함수를 호출합니다.\n * @method ax5.util.each\n * @param {Object|Array} O\n * @param {Function} _fn\n * @example\n * ```js\n * var axf = ax5.util;\n * axf.each([0,1,2], function(){\n\t\t * \t// with this\n\t\t * });\n * axf.each({a:1, b:2}, function(){\n\t\t * \t// with this\n\t\t * });\n * ```\n */\n function each(O, _fn) {\n if (isNothing(O)) return [];\n var key, i = 0, l = O.length,\n isObj = l === undefined || typeof O === \"function\";\n if (isObj) {\n for (key in O) {\n if (typeof O[key] != \"undefined\")\n if (_fn.call(O[key], key, O[key]) === false) break;\n }\n }\n else {\n for (; i < l;) {\n if (typeof O[i] != \"undefined\")\n if (_fn.call(O[i], i, O[i++]) === false) break;\n }\n }\n return O;\n }\n\n // In addition to using the http://underscorejs.org : map, reduce, reduceRight, find\n /**\n * 원본 아이템들을 이용하여 사용자 함수의 리턴값으로 이루어진 새로운 배열을 만듭니다.\n * @method ax5.util.map\n * @param {Object|Array} O\n * @param {Function} _fn\n * @returns {Array}\n * @example\n * ```js\n * var myArray = [0,1,2,3,4];\n * var myObject = {a:1, b:\"2\", c:{axj:\"what\", arrs:[0,2,\"3\"]},\n\t\t * fn: function(abcdd){\n\t\t * return abcdd;\n\t\t * }\n\t\t * };\n *\n * var _arr = ax5.util.map( myArray, function(index, I){\n\t\t * return index+1;\n\t\t * });\n * console.log(_arr);\n * // [1, 2, 3, 4, 5]\n *\n * var _arr = ax5.util.map( myObject, function(k, v){\n\t\t * return v * 2;\n\t\t * });\n * console.log(_arr);\n * // [2, 4, NaN, NaN]\n * ```\n */\n function map(O, _fn) {\n if (isNothing(O)) return [];\n var key, i = 0, l = O.length, results = [], fnResult;\n if (isObject(O)) {\n for (key in O) {\n if (typeof O[key] != \"undefined\") {\n fnResult = undefined;\n if ((fnResult = _fn.call(O[key], key, O[key])) === false) break;\n else results.push(fnResult);\n }\n }\n }\n else {\n for (; i < l;) {\n if (typeof O[i] != \"undefined\") {\n fnResult = undefined;\n if ((fnResult = _fn.call(O[i], i, O[i++])) === false) break;\n else results.push(fnResult);\n }\n }\n }\n return results;\n }\n\n /**\n * 원본 아이템들을 이용하여 사용자 함수의 리턴값이 참인 아이템의 위치나 키값을 반환합니다.\n * @method ax5.util.search\n * @param {Object|Array} O\n * @param {Function|String|Number} _fn - 함수 또는 값\n * @returns {Number|String}\n * @example\n * ```js\n * var myArray = [0,1,2,3,4,5,6];\n * var myObject = {a:\"123\",\"b\":\"123\",c:123};\n *\n * ax5.util.search(myArray, function(){\n\t\t * return this > 3;\n\t\t * });\n * // 4\n * ax5.util.search(myObject, function(k, v){\n\t\t * return v === 123;\n\t\t * });\n * // \"c\"\n * ax5.util.search([1,2,3,4], 3);\n * // 2\n * ax5.util.search([1,2], 4);\n * // -1\n * ax5.util.search([\"name\",\"value\"], \"value\");\n * // 1\n * ax5.util.search([\"name\",\"value\"], \"values\");\n * // -1\n * ax5.util.search({k1:\"name\",k2:\"value\"}, \"value2\");\n * // -1\n * ax5.util.search({k1:\"name\",k2:\"value\"}, \"value\");\n * // \"k2\"\n * ```\n */\n function search(O, _fn) {\n if (isNothing(O)) return -1;\n var key, i = 0, l = O.length;\n if (isObject(O)) {\n for (key in O) {\n if (typeof O[key] != \"undefined\" && isFunction(_fn) && _fn.call(O[key], key, O[key])) {\n return key;\n break;\n }\n else if (O[key] == _fn) {\n return key;\n break;\n }\n }\n }\n else {\n for (; i < l;) {\n if (typeof O[i] != \"undefined\" && isFunction(_fn) && _fn.call(O[i], i, O[i])) {\n return i;\n break;\n }\n else if (O[i] == _fn) {\n return i;\n break;\n }\n i++;\n }\n }\n return -1;\n }\n\n /**\n * @method ax5.util.sum\n * @param {Array|Object} O\n * @param {Number} [defaultValue]\n * @param {Function} _fn\n * @returns {Number}\n * @example\n * ```js\n * var arr = [\n * {name: \"122\", value: 9},\n * {name: \"122\", value: 10},\n * {name: \"123\", value: 11}\n * ];\n *\n * var rs = ax5.util.sum(arr, function () {\n * if(this.name == \"122\") {\n * return this.value;\n * }\n * });\n * console.log(rs); // 19\n *\n * console.log(ax5.util.sum(arr, 10, function () {\n * return this.value;\n * }));\n * // 40\n * ```\n */\n function sum(O, defaultValue, _fn) {\n var i, l, tokenValue;\n if (isFunction(defaultValue) && typeof _fn === \"undefined\") {\n _fn = defaultValue;\n defaultValue = 0;\n }\n if (typeof defaultValue === \"undefined\") defaultValue = 0;\n\n if (isArray(O)) {\n i = 0;\n l = O.length;\n for (; i < l; i++) {\n if (typeof O[i] !== \"undefined\") {\n if (( tokenValue = _fn.call(O[i], O[i]) ) === false) break;\n else if (typeof tokenValue !== \"undefined\") defaultValue += tokenValue;\n }\n }\n return defaultValue;\n }\n else if (isObject(O)) {\n for (i in O) {\n if (typeof O[i] != \"undefined\") {\n if (( tokenValue = _fn.call(O[i], O[i]) ) === false) break;\n else if (typeof tokenValue !== \"undefined\") defaultValue += tokenValue;\n }\n }\n return defaultValue;\n }\n else {\n console.error(\"argument error : ax5.util.sum - use Array or Object\");\n return defaultValue;\n }\n }\n\n\n /**\n * @method ax5.util.avg\n * @param {Array|Object} O\n * @param {Number} [defaultValue]\n * @param {Function} _fn\n * @returns {Number}\n * @example\n * ```js\n * var arr = [\n * {name: \"122\", value: 9},\n * {name: \"122\", value: 10},\n * {name: \"123\", value: 11}\n * ];\n *\n * var rs = ax5.util.avg(arr, function () {\n * return this.value;\n * });\n *\n * console.log(rs); // 10\n * ```\n */\n function avg(O, defaultValue, _fn) {\n var i, l, tokenValue;\n if (isFunction(defaultValue) && typeof _fn === \"undefined\") {\n _fn = defaultValue;\n defaultValue = 0;\n }\n if (typeof defaultValue === \"undefined\") defaultValue = 0;\n\n if (isArray(O)) {\n i = 0;\n l = O.length;\n for (; i < l; i++) {\n if (typeof O[i] !== \"undefined\") {\n if (( tokenValue = _fn.call(O[i], O[i]) ) === false) break;\n else if (typeof tokenValue !== \"undefined\") defaultValue += tokenValue;\n }\n }\n return defaultValue / l;\n }\n else if (isObject(O)) {\n for (i in O) {\n if (typeof O[i] != \"undefined\") {\n if (( tokenValue = _fn.call(O[i], O[i]) ) === false) break;\n else if (typeof tokenValue !== \"undefined\") defaultValue += tokenValue;\n }\n }\n return defaultValue / l;\n }\n else {\n console.error(\"argument error : ax5.util.sum - use Array or Object\");\n return defaultValue;\n }\n }\n\n /**\n * 배열의 왼쪽에서 오른쪽으로 연산을 진행하는데 수행한 결과가 왼쪽 값으로 반영되어 최종 왼쪽 값을 반환합니다.\n * @method ax5.util.reduce\n * @param {Array|Object} O\n * @param {Function} _fn\n * @returns {Alltypes}\n * @example\n * ```js\n * var aarray = [5,4,3,2,1];\n * result = ax5.util.reduce( aarray, function(p, n){\n\t\t * return p * n;\n\t\t * });\n * console.log(result, aarray);\n * // 120 [5, 4, 3, 2, 1]\n *\n * ax5.util.reduce({a:1, b:2}, function(p, n){\n\t\t * return parseInt(p|0) + parseInt(n);\n\t\t * });\n * // 3\n * ```\n */\n function reduce(O, _fn) {\n var i, l, tokenItem;\n if (isArray(O)) {\n i = 0, l = O.length, tokenItem = O[i];\n for (; i < l - 1;) {\n if (typeof O[i] != \"undefined\") {\n if (( tokenItem = _fn.call(root, tokenItem, O[++i]) ) === false) break;\n }\n }\n return tokenItem;\n }\n else if (isObject(O)) {\n for (i in O) {\n if (typeof O[i] != \"undefined\") {\n if (( tokenItem = _fn.call(root, tokenItem, O[i]) ) === false) break;\n }\n }\n return tokenItem;\n }\n else {\n console.error(\"argument error : ax5.util.reduce - use Array or Object\");\n return null;\n }\n }\n\n /**\n * 배열의 오른쪽에서 왼쪽으로 연산을 진행하는데 수행한 결과가 오른쪽 값으로 반영되어 최종 오른쪽 값을 반환합니다.\n * @method ax5.util.reduceRight\n * @param {Array} O\n * @param {Function} _fn\n * @returns {Alltypes}\n * @example\n * ```js\n * var aarray = [5,4,3,2,1];\n * result = ax5.util.reduceRight( aarray, function(p, n){\n\t\t * console.log( n );\n\t\t * return p * n;\n\t\t * });\n * console.log(result, aarray);\n * 120 [5, 4, 3, 2, 1]\n * ```\n */\n function reduceRight(O, _fn) {\n var i = O.length - 1, tokenItem = O[i];\n for (; i > 0;) {\n if (typeof O[i] != \"undefined\") {\n if (( tokenItem = _fn.call(root, tokenItem, O[--i]) ) === false) break;\n }\n }\n return tokenItem;\n }\n\n /**\n * 배열또는 오브젝트의 각 아이템을 인자로 하는 사용자 함수의 결과가 참인 아이템들의 배열을 반환합니다.\n * @method ax5.util.filter\n * @param {Object|Array} O\n * @param {Function} _fn\n * @returns {Array}\n * @example\n * ```js\n * var aarray = [5,4,3,2,1];\n * result = ax5.util.filter( aarray, function(){\n\t\t * return this % 2;\n\t\t * });\n * console.log(result);\n * // [5, 3, 1]\n *\n * var filObject = {a:1, s:\"string\", oa:{pickup:true, name:\"AXISJ\"}, os:{pickup:true, name:\"AX5\"}};\n * result = ax5.util.filter( filObject, function(){\n\t\t * \treturn this.pickup;\n\t\t * });\n * console.log( ax5.util.toJson(result) );\n * // [{\"pickup\": , \"name\": \"AXISJ\"}, {\"pickup\": , \"name\": \"AX5\"}]\n * ```\n */\n function filter(O, _fn) {\n if (isNothing(O)) return [];\n var k, i = 0, l = O.length, results = [], fnResult;\n if (isObject(O)) {\n for (k in O) {\n if (typeof O[k] != \"undefined\") {\n if (fnResult = _fn.call(O[k], k, O[k])) results.push(O[k]);\n }\n }\n }\n else {\n for (; i < l;) {\n if (typeof O[i] != \"undefined\") {\n if (fnResult = _fn.call(O[i], i, O[i])) results.push(O[i]);\n i++;\n }\n }\n }\n return results;\n }\n\n /**\n * Object를 JSONString 으로 반환합니다.\n * @method ax5.util.toJson\n * @param {Object|Array} O\n * @returns {String} JSON\n * @example\n * ```js\n * var ax = ax5.util;\n * var myObject = {\n\t\t * a:1, b:\"2\", c:{axj:\"what\", arrs:[0,2,\"3\"]},\n\t\t * fn: function(abcdd){\n\t\t * return abcdd;\n\t\t * }\n\t\t * };\n * console.log( ax.toJson(myObject) );\n * ```\n */\n function toJson(O) {\n var jsonString = \"\";\n if (ax5.util.isArray(O)) {\n var i = 0, l = O.length;\n jsonString += \"[\";\n for (; i < l; i++) {\n if (i > 0) jsonString += \",\";\n jsonString += toJson(O[i]);\n }\n jsonString += \"]\";\n }\n else if (ax5.util.isObject(O)) {\n jsonString += \"{\";\n var jsonObjectBody = [];\n each(O, function (key, value) {\n jsonObjectBody.push('\"' + key + '\": ' + toJson(value));\n });\n jsonString += jsonObjectBody.join(\", \");\n jsonString += \"}\";\n }\n else if (ax5.util.isString(O)) {\n jsonString = '\"' + O + '\"';\n }\n else if (ax5.util.isNumber(O)) {\n jsonString = O;\n }\n else if (ax5.util.isUndefined(O)) {\n jsonString = \"undefined\";\n }\n else if (ax5.util.isFunction(O)) {\n jsonString = '\"{Function}\"';\n }\n else {\n jsonString = O;\n }\n return jsonString;\n }\n\n /**\n * 관용의 JSON Parser\n * @method ax5.util.parseJson\n * @param {String} JSONString\n * @param {Boolean} [force] - 강제 적용 여부 (json 문자열 검사를 무시하고 오브젝트 변환을 시도합니다.)\n * @returns {Object}\n * @example\n * ```\n * console.log(ax5.util.parseJson('{\"a\":1}'));\n * // Object {a: 1}\n * console.log(ax5.util.parseJson(\"{'a':1, 'b':'b'}\"));\n * // Object {a: 1, b: \"b\"}\n * console.log(ax5.util.parseJson(\"{'a':1, 'b':function(){return 1;}}\", true));\n * // Object {a: 1, b: function}\n * console.log(ax5.util.parseJson(\"{a:1}\"));\n * // Object {a: 1}\n * console.log(ax5.util.parseJson(\"[1,2,3]\"));\n * // [1, 2, 3]\n * console.log(ax5.util.parseJson(\"['1','2','3']\"));\n * // [\"1\", \"2\", \"3\"]\n * console.log(ax5.util.parseJson(\"[{'a':'99'},'2','3']\"));\n * // [Object, \"2\", \"3\"]\n * ```\n */\n function parseJson(str, force) {\n if (force || (reIsJson).test(str)) {\n try {\n return (new Function('', 'return ' + str))();\n } catch (e) {\n return {error: 500, msg: 'syntax error'};\n }\n }\n else {\n return {error: 500, msg: 'syntax error'};\n }\n }\n\n /**\n * 인자의 타입을 반환합니다.\n * @method ax5.util.getType\n * @param {Object|Array|String|Number|Element|Etc} O\n * @returns {String} window|element|object|array|function|string|number|undefined|nodelist\n * @example\n * ```js\n * var axf = ax5.util;\n * var a = 11;\n * var b = \"11\";\n * console.log( axf.getType(a) );\n * console.log( axf.getType(b) );\n * ```\n */\n function getType(O) {\n var typeName;\n if (O != null && O == O.window) {\n typeName = \"window\";\n }\n else if (!!(O && O.nodeType == 1)) {\n typeName = \"element\";\n }\n else if (!!(O && O.nodeType == 11)) {\n typeName = \"fragment\";\n }\n else if (O === null) {\n typeName = \"null\";\n }\n else if (typeof O === \"undefined\") {\n typeName = \"undefined\";\n }\n else if (_toString.call(O) == \"[object Object]\") {\n typeName = \"object\";\n }\n else if (_toString.call(O) == \"[object Array]\") {\n typeName = \"array\";\n }\n else if (_toString.call(O) == \"[object String]\") {\n typeName = \"string\";\n }\n else if (_toString.call(O) == \"[object Number]\") {\n typeName = \"number\";\n }\n else if (_toString.call(O) == \"[object NodeList]\") {\n typeName = \"nodelist\";\n }\n else if (typeof O === \"function\") {\n typeName = \"function\";\n }\n return typeName;\n }\n\n /**\n * 오브젝트가 window 인지 판단합니다.\n * @method ax5.util.isWindow\n * @param {Object} O\n * @returns {Boolean}\n */\n function isWindow(O) {\n return O != null && O == O.window;\n }\n\n /**\n * 오브젝트가 HTML 엘리먼트여부인지 판단합니다.\n * @method ax5.util.isElement\n * @param {Object} O\n * @returns {Boolean}\n */\n function isElement(O) {\n return !!(O && (O.nodeType == 1 || O.nodeType == 11));\n }\n\n /**\n * 오브젝트가 Object인지 판단합니다.\n * @method ax5.util.isObject\n * @param {Object} O\n * @returns {Boolean}\n */\n function isObject(O) {\n return _toString.call(O) == \"[object Object]\";\n }\n\n /**\n * 오브젝트가 Array인지 판단합니다.\n * @method ax5.util.isArray\n * @param {Object} O\n * @returns {Boolean}\n */\n function isArray(O) {\n return _toString.call(O) == \"[object Array]\";\n }\n\n /**\n * 오브젝트가 Function인지 판단합니다.\n * @method ax5.util.isFunction\n * @param {Object} O\n * @returns {Boolean}\n */\n function isFunction(O) {\n return typeof O === \"function\";\n }\n\n /**\n * 오브젝트가 String인지 판단합니다.\n * @method ax5.util.isString\n * @param {Object} O\n * @returns {Boolean}\n */\n function isString(O) {\n return _toString.call(O) == \"[object String]\";\n }\n\n /**\n * 오브젝트가 Number인지 판단합니다.\n * @method ax5.util.isNumber\n * @param {Object} O\n * @returns {Boolean}\n */\n function isNumber(O) {\n return _toString.call(O) == \"[object Number]\";\n }\n\n /**\n * 오브젝트가 NodeList인지 판단합니다.\n * @method ax5.util.isNodelist\n * @param {Object} O\n * @returns {Boolean}\n */\n function isNodelist(O) {\n return !!(_toString.call(O) == \"[object NodeList]\" || (typeof O !== \"undefined\" && O && O[0] && O[0].nodeType == 1));\n }\n\n /**\n * 오브젝트가 undefined인지 판단합니다.\n * @method ax5.util.isUndefined\n * @param {Object} O\n * @returns {Boolean}\n */\n function isUndefined(O) {\n return typeof O === \"undefined\";\n }\n\n /**\n * 오브젝트가 undefined이거나 null이거나 빈값인지 판단합니다.\n * @method ax5.util.isNothing\n * @param {Object} O\n * @returns {Boolean}\n */\n function isNothing(O) {\n return (typeof O === \"undefined\" || O === null || O === \"\");\n }\n\n /**\n * 오브젝트가 날자값인지 판단합니다.\n * @method ax5.util.isDate\n * @param {Date} O\n * @returns {Boolean}\n * @example\n * ```js\n * ax5.util.isDate('2016-09-30');\n * // false\n * ax5.util.isDate( new Date('2016-09-30') );\n * // true\n * ```\n */\n function isDate(O) {\n return (O instanceof Date && !isNaN(O.valueOf()));\n }\n\n\n function isDateFormat(O) {\n var\n result = false\n ;\n if (!O) {\n }\n else if (O instanceof Date && !isNaN(O.valueOf())) {\n result = true;\n }\n else {\n if (O.length > 7) {\n if (date(O) instanceof Date) {\n return true;\n }\n }\n O = O.replace(/\\D/g, '');\n if (O.length > 7) {\n var\n mm = O.substr(4, 2),\n dd = O.substr(6, 2)\n ;\n O = date(O);\n if (O.getMonth() == (mm - 1) && O.getDate() == dd) {\n result = true;\n }\n }\n }\n return result;\n }\n\n /**\n * 오브젝트의 첫번째 아이템을 반환합니다.\n * @method ax5.util.first\n * @param {Object|Array} O\n * @returns {Object}\n * @example\n * ```js\n * ax5.util.first({a:1, b:2});\n * // Object {a: 1}\n * ax5.util.first([1,2,3,4]);\n * // 1\n * ```\n */\n function first(O) {\n if (isObject(O)) {\n var keys = Object.keys(O);\n var item = {};\n item[keys[0]] = O[keys[0]];\n return item;\n }\n else if (isArray(O)) {\n return O[0];\n }\n else {\n console.error(\"ax5.util.object.first\", \"argument type error\");\n return undefined;\n }\n }\n\n /**\n * 오브젝트의 마지막 아이템을 반환합니다.\n * @method ax5.util.last\n * @param {Object|Array} O\n * @returns {Object}\n * @example\n * ```js\n * ax5.util.last({a:1, b:2});\n * // Object {b: 2}\n * ax5.util.last([1,2,3,4]);\n * // 4\n * ```\n */\n function last(O) {\n if (isObject(O)) {\n var keys = Object.keys(O);\n var item = {};\n item[keys[keys.length - 1]] = O[keys[keys.length - 1]];\n return item;\n }\n else if (isArray(O)) {\n return O[O.length - 1];\n }\n else {\n console.error(\"ax5.util.object.last\", \"argument type error\");\n return undefined;\n }\n }\n\n /**\n * 쿠키를 설정합니다.\n * @method ax5.util.setCookie\n * @param {String} cname - 쿠키이름\n * @param {String} cvalue - 쿠키값\n * @param {Number} [exdays] - 쿠키 유지일수\n * @param {Object} [opts] - path, domain 설정 옵션\n * @example\n * ```js\n * ax5.util.setCookie(\"jslib\", \"AX5\");\n * ax5.util.setCookie(\"jslib\", \"AX5\", 3);\n * ax5.util.setCookie(\"jslib\", \"AX5\", 3, {path:\"/\", domain:\".axisj.com\"});\n * ```\n */\n function setCookie(cn, cv, exdays, opts) {\n var expire;\n if (typeof exdays === \"number\") {\n expire = new Date();\n expire.setDate(expire.getDate() + exdays);\n }\n opts = opts || {};\n return (doc.cookie = [\n escape(cn), '=', escape(cv),\n expire ? \"; expires=\" + expire.toUTCString() : \"\", // use expires attribute, max-age is not supported by IE\n opts.path ? \"; path=\" + opts.path : \"\",\n opts.domain ? \"; domain=\" + opts.domain : \"\",\n opts.secure ? \"; secure\" : \"\"\n ].join(\"\"));\n }\n\n /**\n * 쿠키를 가져옵니다.\n * @method ax5.util.getCookie\n * @param {String} cname\n * @returns {String} cookie value\n * @example\n * ```js\n * ax5.util.getCookie(\"jslib\");\n * ```\n */\n function getCookie(cname) {\n var name = cname + \"=\";\n var ca = doc.cookie.split(';'), i = 0, l = ca.length;\n for (; i < l; i++) {\n var c = ca[i];\n while (c.charAt(0) == ' ') c = c.substring(1);\n if (c.indexOf(name) != -1) return unescape(c.substring(name.length, c.length));\n }\n return \"\";\n }\n\n /**\n * jsonString 으로 alert 합니다.\n * @method ax5.util.alert\n * @param {Object|Array|String|Number} O\n * @returns {Object|Array|String|Number} O\n * @example ```js\n * ax5.util.alert({a:1,b:2});\n * ax5.util.alert(\"정말?\");\n * ```\n */\n function alert(O) {\n win.alert(toJson(O));\n return O;\n }\n\n /**\n * 문자열의 특정 문자열까지 잘라주거나 원하는 포지션까지 잘라줍니다.\n * @method ax5.util.left\n * @param {String} str - 문자열\n * @param {String|Number} pos - 찾을 문자열 또는 포지션\n * @returns {String}\n * @example\n * ```js\n * ax5.util.left(\"abcd.efd\", 3);\n * // abc\n * ax5.util.left(\"abcd.efd\", \".\");\n * // abcd\n * ```\n */\n function left(str, pos) {\n if (typeof str === \"undefined\" || typeof pos === \"undefined\") return \"\";\n if (isString(pos)) {\n return (str.indexOf(pos) > -1) ? str.substr(0, str.indexOf(pos)) : \"\";\n }\n else if (isNumber(pos)) {\n return str.substr(0, pos);\n }\n else {\n return \"\";\n }\n }\n\n /**\n * 문자열의 특정 문자열까지 잘라주거나 원하는 포지션까지 잘라줍니다.\n * @method ax5.util.right\n * @param {String} str - 문자열\n * @param {String|Number} pos - 찾을 문자열 또는 포지션\n * @returns {String}\n * @example\n * ```js\n * ax5.util.right(\"abcd.efd\", 3);\n * // efd\n * ax5.util.right(\"abcd.efd\", \".\");\n * // efd\n * ```\n */\n function right(str, pos) {\n if (typeof str === \"undefined\" || typeof pos === \"undefined\") return \"\";\n str = '' + str;\n if (isString(pos)) {\n return (str.lastIndexOf(pos) > -1) ? str.substr(str.lastIndexOf(pos) + 1) : \"\";\n }\n else if (isNumber(pos)) {\n return str.substr(str.length - pos);\n }\n else {\n return \"\";\n }\n }\n\n /**\n * css형 문자열이나 특수문자가 포함된 문자열을 카멜케이스로 바꾸어 반환합니다.\n * @method ax5.util.camelCase\n * @param {String} str\n * @returns {String}\n * @example\n * ```js\n * ax5.util.camelCase(\"inner-width\");\n * ax5.util.camelCase(\"innerWidth\");\n * // innerWidth\n * ```\n */\n function camelCase(str) {\n return str.replace(reMs, \"ms-\").replace(reSnakeCase, function (all, letter) {\n return letter.toUpperCase();\n });\n }\n\n /**\n * css형 문자열이나 카멜케이스문자열을 스네이크 케이스 문자열로 바꾸어 반환합니다.\n * @method ax5.util.snakeCase\n * @param {String} str\n * @returns {String}\n * @example\n * ```js\n * ax5.util.snakeCase(\"innerWidth\");\n * ax5.util.snakeCase(\"inner-Width\");\n * ax5.util.snakeCase(\"innerWidth\");\n * // inner-width\n * ```\n */\n function snakeCase(str) {\n return camelCase(str).replace(reCamelCase, function (all, letter) {\n return \"-\" + letter.toLowerCase();\n });\n }\n\n /**\n * 문자열에서 -. 을 제외한 모든 문자열을 제거하고 숫자로 반환합니다. 옵션에 따라 원하는 형식의 숫자로 변환 할 수 도 있습니다.\n * @method ax5.util.number\n * @param {String|Number} str\n * @param {Object} cond - 옵션\n * @returns {String|Number}\n * @example\n * ```js\n * var cond = {\n\t\t * \tround: {Number|Boolean} - 반올림할 자릿수,\n\t\t * \tmoney: {Boolean} - 통화,\n\t\t * \tabs: {Boolean} - 절대값,\n\t\t * \tbyte: {Boolean} - 바이트\n\t\t * }\n *\n * console.log(ax5.util.number(123456789.678, {round:1}));\n * console.log(ax5.util.number(123456789.678, {round:1, money:true}));\n * console.log(ax5.util.number(123456789.678, {round:2, byte:true}));\n * console.log(ax5.util.number(-123456789.8888, {abs:true, round:2, money:true}));\n * console.log(ax5.util.number(\"A-1234~~56789.8~888PX\", {abs:true, round:2, money:true}));\n *\n * //123456789.7\n * //123,456,789.7\n * //117.7MB\n * //123,456,789.89\n * //123,456,789.89\n * ```\n */\n function number(str, cond) {\n var result, pair = ('' + str).split(reDot), isMinus = (Number(pair[0]) < 0 || pair[0] == \"-0\"), returnValue = 0.0;\n pair[0] = pair[0].replace(reInt, \"\");\n if (pair[1]) {\n pair[1] = pair[1].replace(reNotNum, \"\");\n returnValue = Number(pair[0] + \".\" + pair[1]) || 0;\n }\n else {\n returnValue = Number(pair[0]) || 0;\n }\n result = (isMinus) ? -returnValue : returnValue;\n\n each(cond, function (k, c) {\n if (k == \"round\") {\n if (isNumber(c)) {\n if (c < 0) {\n result = +(Math.round(result + \"e-\" + Math.abs(c)) + \"e+\" + Math.abs(c));\n }\n else {\n result = +(Math.round(result + \"e+\" + c) + \"e-\" + c);\n }\n }\n else {\n result = Math.round(result);\n }\n }\n if (k == \"floor\") {\n result = Math.floor(result);\n }\n if (k == \"ceil\") {\n result = Math.ceil(result);\n }\n else if (k == \"money\") {\n result = (function (val) {\n var txtNumber = '' + val;\n if (isNaN(txtNumber) || txtNumber == \"\") {\n return \"\";\n }\n else {\n var arrNumber = txtNumber.split('.');\n arrNumber[0] += '.';\n do {\n arrNumber[0] = arrNumber[0].replace(reMoneySplit, '$1,$2');\n } while (reMoneySplit.test(arrNumber[0]));\n if (arrNumber.length > 1) {\n return arrNumber.join('');\n }\n else {\n return arrNumber[0].split('.')[0];\n }\n }\n })(result);\n }\n else if (k == \"abs\") {\n result = Math.abs(Number(result));\n }\n else if (k == \"byte\") {\n result = (function (val) {\n val = Number(result);\n var nUnit = \"KB\";\n var myByte = val / 1024;\n if (myByte / 1024 > 1) {\n nUnit = \"MB\";\n myByte = myByte / 1024;\n }\n if (myByte / 1024 > 1) {\n nUnit = \"GB\";\n myByte = myByte / 1024;\n }\n return number(myByte, {round: 1}) + nUnit;\n })(result);\n }\n });\n\n return result;\n }\n\n /**\n * 배열 비슷한 오브젝트를 배열로 변환해줍니다.\n * @method ax5.util.toArray\n * @param {Object|Elements|Arguments} O\n * @returns {Array}\n * @example\n * ```js\n * ax5.util.toArray(arguments);\n * //\n * ```\n */\n function toArray(O) {\n if (typeof O.length != \"undefined\") return Array.prototype.slice.call(O);\n return [];\n }\n\n /**\n * 첫번째 인자에 두번째 인자 아이템을 합쳐줍니다. concat과 같은 역할을 하지만. 인자가 Array타입이 아니어도 됩니다.\n * @method ax5.util.merge\n * @param {Array|ArrayLike} first\n * @param {Array|ArrayLike} second\n * @returns {Array} first\n * @example\n * ```\n *\n * ```\n */\n function merge(first, second) {\n var l = second.length,\n i = first.length,\n j = 0;\n\n if (typeof l === \"number\") {\n for (; j < l; j++) {\n first[i++] = second[j];\n }\n }\n else {\n while (second[j] !== undefined) {\n first[i++] = second[j++];\n }\n }\n\n first.length = i;\n\n return first;\n }\n\n /**\n * 오브젝트를 파라미터형식으로 또는 파라미터를 오브젝트 형식으로 변환합니다.\n * @method ax5.util.param\n * @param {Object|Array|String} O\n * @param {String} [cond] - param|object\n * @returns {Object|String}\n * @example\n * ```\n * ax5.util.param({a:1,b:'1232'}, \"param\");\n * ax5.util.param(\"a=1&b=1232\", \"param\");\n * // \"a=1&b=1232\"\n * ax5.util.param(\"a=1&b=1232\");\n * // {a: \"1\", b: \"1232\"}\n * ```\n */\n function param(O, cond) {\n var p;\n if (isString(O) && typeof cond !== \"undefined\" && cond == \"param\") {\n return O;\n }\n else if ((isString(O) && typeof cond !== \"undefined\" && cond == \"object\") || (isString(O) && typeof cond === \"undefined\")) {\n p = {};\n each(O.split(reAmp), function () {\n var item = this.split(reEq);\n if (!p[item[0]]) p[item[0]] = item[1];\n else {\n if (isString(p[item[0]])) p[item[0]] = [p[item[0]]];\n p[item[0]].push(item[1]);\n }\n });\n return p;\n }\n else {\n p = [];\n each(O, function (k, v) {\n p.push(k + \"=\" + escape(v));\n });\n return p.join('&');\n }\n }\n\n function encode(s) {\n return encodeURIComponent(s);\n }\n\n function decode(s) {\n return decodeURIComponent(s);\n }\n\n function error() {\n ax5.info.onerror.apply(this, arguments);\n }\n\n function localDate(yy, mm, dd, hh, mi, ss) {\n var utcD, localD;\n localD = new Date();\n if (typeof hh === \"undefined\") hh = 23;\n if (typeof mi === \"undefined\") mi = 59;\n utcD = new Date(Date.UTC(yy, mm, dd || 1, hh, mi, ss || 0));\n\n if (mm == 0 && dd == 1 && utcD.getUTCHours() + (utcD.getTimezoneOffset() / 60) < 0) {\n utcD.setUTCHours(0);\n }\n else {\n utcD.setUTCHours(utcD.getUTCHours() + (utcD.getTimezoneOffset() / 60));\n }\n return utcD;\n }\n\n /**\n * 날짜 형식의 문자열이나 Date객체를 조건에 맞게 처리 한 후 원하는 return 값으로 반환합니다.\n * @method ax5.util.date\n * @param {String|Date} d\n * @param {Object} cond\n * @returns {Date|String}\n * @example\n * ```js\n * ax5.util.date('2013-01-01'); // Tue Jan 01 2013 23:59:00 GMT+0900 (KST)\n * ax5.util.date((new Date()), {add:{d:10}, return:'yyyy/MM/dd'}); // \"2015/07/01\"\n * ax5.util.date('1919-03-01', {add:{d:10}, return:'yyyy/MM/dd hh:mm:ss'}); // \"1919/03/11 23:59:00\"\n * ```\n */\n function date(d, cond) {\n var yy, mm, dd, hh, mi,\n aDateTime, aTimes, aTime, aDate,\n utcD, localD,\n va;\n var ISO_8601 = /^\\d{4}(-\\d\\d(-\\d\\d(T\\d\\d:\\d\\d(:\\d\\d)?(\\.\\d+)?(([+-]\\d\\d:\\d\\d)|Z)?)?)?)?$/i;\n var ISO_8601_FULL = /^\\d{4}-\\d\\d-\\d\\dT\\d\\d:\\d\\d:\\d\\d(\\.\\d+)?(([+-]\\d\\d:\\d\\d)|Z)?$/i;\n\n if (isString(d)) {\n if (d.length == 0) {\n d = new Date();\n }\n else if (d.length > 15) {\n if (ISO_8601_FULL.test(d) || ISO_8601.test(d)) {\n d = new Date(d);\n } else {\n aDateTime = d.split(/ /g), aTimes, aTime,\n aDate = aDateTime[0].split(/\\D/g),\n yy = aDate[0];\n mm = parseFloat(aDate[1]);\n dd = parseFloat(aDate[2]);\n aTime = aDateTime[1] || \"09:00\";\n aTimes = aTime.substring(0, 5).split(\":\");\n hh = parseFloat(aTimes[0]);\n mi = parseFloat(aTimes[1]);\n if (right(aTime, 2) === \"AM\" || right(aTime, 2) === \"PM\") hh += 12;\n d = localDate(yy, mm - 1, dd, hh, mi);\n }\n }\n else if (d.length == 14) {\n va = d.replace(/\\D/g, \"\");\n d = localDate(va.substr(0, 4), va.substr(4, 2) - 1, number(va.substr(6, 2)), number(va.substr(8, 2)), number(va.substr(10, 2)), number(va.substr(12, 2)));\n }\n else if (d.length > 7) {\n va = d.replace(/\\D/g, \"\");\n d = localDate(va.substr(0, 4), va.substr(4, 2) - 1, number(va.substr(6, 2)));\n }\n else if (d.length > 4) {\n va = d.replace(/\\D/g, \"\");\n d = localDate(va.substr(0, 4), va.substr(4, 2) - 1, 1);\n }\n else if (d.length > 2) {\n va = d.replace(/\\D/g, \"\");\n return localDate(va.substr(0, 4), va.substr(4, 2) - 1, 1);\n }\n else {\n d = new Date();\n }\n }\n\n if (typeof cond === \"undefined\") {\n return d;\n }\n else {\n\n if (\"add\" in cond) {\n d = (function (_d, opts) {\n var\n yy, mm, dd, mxdd,\n DyMilli = ((1000 * 60) * 60) * 24;\n\n if (typeof opts[\"d\"] !== \"undefined\") {\n _d.setTime(_d.getTime() + (opts[\"d\"] * DyMilli));\n }\n else if (typeof opts[\"m\"] !== \"undefined\") {\n yy = _d.getFullYear();\n mm = _d.getMonth();\n dd = _d.getDate();\n yy = yy + parseInt(opts[\"m\"] / 12);\n mm += opts[\"m\"] % 12;\n mxdd = daysOfMonth(yy, mm);\n if (mxdd < dd) dd = mxdd;\n _d = new Date(yy, mm, dd, 12);\n }\n else if (typeof opts[\"y\"] !== \"undefined\") {\n _d.setTime(_d.getTime() + ((opts[\"y\"] * 365) * DyMilli));\n }\n return _d;\n })(new Date(d), cond[\"add\"]);\n }\n\n if (\"set\" in cond) {\n d = (function (_d, opts) {\n var\n yy, mm, dd,\n processor = {\n \"firstDayOfMonth\": function (date) {\n yy = date.getFullYear();\n mm = date.getMonth();\n dd = 1;\n return new Date(yy, mm, dd, 12);\n },\n \"lastDayOfMonth\": function (date) {\n yy = date.getFullYear();\n mm = date.getMonth();\n dd = daysOfMonth(yy, mm);\n return new Date(yy, mm, dd, 12);\n }\n };\n if (opts in processor) {\n return processor[opts](_d);\n } else {\n return _d;\n }\n })(new Date(d), cond[\"set\"]);\n }\n\n if (\"return\" in cond) {\n return (function () {\n var fStr = cond[\"return\"], nY, nM, nD, nH, nMM, nS, nDW;\n\n nY = d.getUTCFullYear();\n nM = setDigit(d.getMonth() + 1, 2);\n nD = setDigit(d.getDate(), 2);\n nH = setDigit(d.getHours(), 2);\n nMM = setDigit(d.getMinutes(), 2);\n nS = setDigit(d.getSeconds(), 2);\n nDW = d.getDay();\n\n var yre = /[^y]*(yyyy)[^y]*/gi;\n yre.exec(fStr);\n var regY = RegExp.$1;\n var mre = /[^m]*(MM)[^m]*/g;\n mre.exec(fStr);\n var regM = RegExp.$1;\n var dre = /[^d]*(dd)[^d]*/gi;\n dre.exec(fStr);\n var regD = RegExp.$1;\n var hre = /[^h]*(hh)[^h]*/gi;\n hre.exec(fStr);\n var regH = RegExp.$1;\n var mire = /[^m]*(mm)[^i]*/g;\n mire.exec(fStr);\n var regMI = RegExp.$1;\n var sre = /[^s]*(ss)[^s]*/gi;\n sre.exec(fStr);\n var regS = RegExp.$1;\n var dwre = /[^d]*(dw)[^w]*/gi;\n dwre.exec(fStr);\n var regDW = RegExp.$1;\n\n if (regY === \"yyyy\") {\n fStr = fStr.replace(regY, right(nY, regY.length));\n }\n if (regM === \"MM\") {\n if (regM.length == 1) nM = (d.getMonth() + 1);\n fStr = fStr.replace(regM, nM);\n }\n if (regD === \"dd\") {\n if (regD.length == 1) nD = d.getDate();\n fStr = fStr.replace(regD, nD);\n }\n if (regH === \"hh\") {\n fStr = fStr.replace(regH, nH);\n }\n if (regMI === \"mm\") {\n fStr = fStr.replace(regMI, nMM);\n }\n if (regS === \"ss\") {\n fStr = fStr.replace(regS, nS);\n }\n if (regDW == \"dw\") {\n fStr = fStr.replace(regDW, info.weekNames[nDW].label);\n }\n return fStr;\n })();\n }\n else {\n return d;\n }\n }\n }\n\n /**\n * 인자인 날짜가 오늘부터 몇일전인지 반환합니다. 또는 인자인 날짜가 가까운 미래에 몇일 후인지 반환합니다.\n * @method ax5.util.dday\n * @param {String|Data} d\n * @param {Object} cond\n * @returns {Number}\n * @example\n * ```js\n * ax5.util.dday('2016-01-29');\n * // 1\n * ax5.util.dday('2016-01-29', {today:'2016-01-28'});\n * // 1\n * ax5.util.dday('1977-03-29', {today:'2016-01-28', age:true});\n * // 39\n * ```\n */\n function dday(d, cond) {\n var memoryDay = date(d), DyMilli = ((1000 * 60) * 60) * 24, today = new Date(), diffnum, thisYearMemoryDay;\n\n function getDayTime(_d) {\n return Math.floor(_d.getTime() / DyMilli) * DyMilli;\n }\n\n if (typeof cond === \"undefined\") {\n diffnum = number((( getDayTime(memoryDay) - getDayTime(today) ) / DyMilli), {floor: true});\n return diffnum;\n }\n\n else {\n diffnum = number((( getDayTime(memoryDay) - getDayTime(today) ) / DyMilli), {floor: true});\n if (cond[\"today\"]) {\n today = date(cond.today);\n diffnum = number((( getDayTime(memoryDay) - getDayTime(today) ) / DyMilli), {floor: true});\n }\n if (cond[\"thisYear\"]) {\n thisYearMemoryDay = new Date(today.getFullYear(), memoryDay.getMonth(), memoryDay.getDate());\n diffnum = number((( getDayTime(thisYearMemoryDay) - getDayTime(today) ) / DyMilli), {floor: true});\n if (diffnum < 0) {\n thisYearMemoryDay = new Date(today.getFullYear() + 1, memoryDay.getMonth(), memoryDay.getDate());\n diffnum = number((( getDayTime(thisYearMemoryDay) - getDayTime(today) ) / DyMilli), {floor: true});\n }\n }\n if (cond[\"age\"]) {\n thisYearMemoryDay = new Date(today.getFullYear(), memoryDay.getMonth(), memoryDay.getDate());\n diffnum = thisYearMemoryDay.getFullYear() - memoryDay.getFullYear();\n }\n\n return diffnum;\n }\n }\n\n /**\n * 인자인 날짜가 몇년 몇월의 몇번째 주차인지 반환합니다.\n * @method ax5.util.weeksOfMonth\n * @param {String|Data} d\n * @returns {Object}\n * @example\n * ```js\n * ax5.util.weeksOfMonth(\"2015-10-01\"); // {year: 2015, month: 10, count: 1}\n * ax5.util.weeksOfMonth(\"2015-09-19\"); // {year: 2015, month: 9, count: 3}\n * ```\n */\n function weeksOfMonth(d) {\n var myDate = date(d);\n return {\n year: myDate.getFullYear(),\n month: myDate.getMonth() + 1,\n count: parseInt(myDate.getDate() / 7 + 1)\n };\n }\n\n /**\n * 년월에 맞는 날자수를 반환합니다.\n * (new Date()).getMonth() 기준으로 월값을 보냅니다. \"2월\" 인경우 \"1\" 을 넘기게 됩니다.\n * @method ax5.util.daysOfMonth\n * @param {Number} y\n * @param {Number} m\n * @returns {Number}\n * @examples\n * ```js\n * ax5.util.daysOfMonth(2015, 11); // 31\n * ax5.util.daysOfMonth(2015, 1); // 28\n * ```\n */\n function daysOfMonth(y, m) {\n if (m == 3 || m == 5 || m == 8 || m == 10) {\n return 30;\n }\n else if (m == 1) {\n return (((y % 4 == 0) && (y % 100 != 0)) || (y % 400 == 0)) ? 29 : 28;\n }\n else {\n return 31;\n }\n }\n\n /**\n * 원하는 횟수 만큼 자릿수 맞춤 문자열을 포함한 문자열을 반환합니다.\n * 문자열 길이보다 작은값을 보내면 무시됩니다.\n * @method ax5.util.setDigit\n * @param {String|Number} num\n * @param {Number} length\n * @param {String} [padder=0]\n * @param {Number} [radix]\n * @returns {String}\n * @example\n * ```\n * ax5.util.setDigit(2016, 6)\n * // \"002016\"\n * ax5.util.setDigit(2016, 2)\n * // \"2016\"\n * ```\n */\n function setDigit(num, length, padder, radix) {\n var s = num.toString(radix || 10);\n return times((padder || '0'), (length - s.length)) + s;\n }\n\n /**\n * 문자열을 지정된 수만큼 반복 합니다.\n * @param {String} s\n * @param {Number} count\n * @returns {string}\n * @example\n * ```\n * ax5.util.times(2016, 2)\n * //\"20162016\"\n * ```\n */\n function times(s, count) {\n return count < 1 ? '' : new Array(count + 1).join(s);\n }\n\n /**\n * 타겟엘리먼트의 부모 엘리멘트 트리에서 원하는 조건의 엘리먼트를 얻습니다.\n * @method ax5.util.findParentNode\n * @param {Element} _target - target element\n * @param {Object|Function} cond - 원하는 element를 찾을 조건\n * @returns {Element}\n * @example\n * ```\n * // cond 속성정의\n * var cond = {\n\t\t * \ttagname: {String} - 태그명 (ex. a, div, span..),\n\t\t * \tclazz: {String} - 클래스명\n\t\t * \t[, 그 외 찾고 싶은 attribute명들]\n\t\t * };\n * console.log(\n * console.log(\n * ax5.util.findParentNode(e.target, {tagname:\"a\", clazz:\"ax-menu-handel\", \"data-custom-attr\":\"attr_value\"})\n * );\n * // cond 함수로 처리하기\n * jQuery('#id').bind(\"click.app_expand\", function(e){\n\t\t * \tvar target = ax5.util.findParentNode(e.target, function(target){\n\t\t * \t\tif($(target).hasClass(\"aside\")){\n\t\t * \t\t\treturn true;\n\t\t * \t\t}\n\t\t * \t\telse{\n\t\t * \t\t\treturn true;\n\t\t * \t\t}\n\t\t * \t});\n\t\t * \t//client-aside\n\t\t * \tif(target.id !== \"client-aside\"){\n\t\t * \t\t// some action\n\t\t * \t}\n\t\t * });\n * ```\n */\n\n function findParentNode(_target, cond) {\n if (_target) {\n while ((function () {\n var result = true;\n if (typeof cond === \"undefined\") {\n _target = (_target.parentNode) ? _target.parentNode : false;\n }\n else if (isFunction(cond)) {\n result = cond(_target);\n }\n else if (isObject(cond)) {\n for (var k in cond) {\n if (k === \"tagname\") {\n if (_target.tagName.toLocaleLowerCase() != cond[k]) {\n result = false;\n break;\n }\n }\n else if (k === \"clazz\" || k === \"class_name\") {\n if (\"className\" in _target) {\n var klasss = _target.className.split(reClassNameSplit);\n var hasClass = false;\n for (var a = 0; a < klasss.length; a++) {\n if (klasss[a] == cond[k]) {\n hasClass = true;\n break;\n }\n }\n result = hasClass;\n }\n else {\n result = false;\n break;\n }\n }\n else { // 그외 속성값들.\n if (_target.getAttribute) {\n if (_target.getAttribute(k) != cond[k]) {\n result = false;\n break;\n }\n }\n else {\n result = false;\n break;\n }\n }\n }\n }\n return !result;\n })()) {\n if (_target.parentNode && _target.parentNode.parentNode) {\n _target = _target.parentNode;\n }\n else {\n _target = false;\n break;\n }\n }\n }\n return _target;\n }\n\n /**\n * @method ax5.util.cssNumber\n * @param {String|Number} val\n * @returns {String}\n * @example\n * ```\n * console.log(ax5.util.cssNumber(\"100px\"))\n * console.log(ax5.util.cssNumber(\"100%\"))\n * console.log(ax5.util.cssNumber(\"100\"))\n * console.log(ax5.util.cssNumber(100))\n * console.log(ax5.util.cssNumber(\"!!100@#\"))\n * ```\n */\n function cssNumber(val) {\n var re = /\\D?(\\d+)([a-zA-Z%]*)/i,\n found = ('' + val).match(re),\n unit = found[2] || \"px\"\n ;\n\n return found[1] + unit;\n }\n\n /**\n * css string 및 object 를 넘기면 object 및 string 으로 변환되어 리턴됩니다.\n * @method ax5.util.css\n * @param {Object|String} val - CSS String or CSS Object\n * @returns {String|Object}\n * @example\n * ```\n * console.log(ax5.util.css({background: \"#ccc\", padding: \"50px\", width: \"100px\"}));\n * //\"background:#ccc;padding:50px;width:100px;\"\n * console.log(ax5.util.css('width:100px;padding: 50px; background: #ccc'));\n * // object {width: \"100px\", padding: \"50px\", background: \"#ccc\"}\n * ```\n */\n function css(val) {\n var returns;\n if (isObject(val)) {\n returns = '';\n for (var k in val) {\n returns += k + ':' + val[k] + ';';\n }\n return returns;\n }\n else if (isString(val)) {\n returns = {};\n var valSplited = val.split(/[ ]*;[ ]*/g);\n valSplited.forEach(function (v) {\n if ((v = v.trim()) !== \"\") {\n var vSplited = v.split(/[ ]*:[ ]*/g);\n returns[vSplited[0]] = vSplited[1];\n }\n });\n return returns;\n }\n }\n\n /**\n * @method ax5.util.stopEvent\n * @param {Event} e\n * @example\n * ```\n * ax5.util.stopEvent(e);\n * ```\n */\n function stopEvent(e) {\n // 이벤트 중지 구문\n if (!e) var e = window.event;\n\n //e.cancelBubble is supported by IE -\n // this will kill the bubbling process.\n e.cancelBubble = true;\n e.returnValue = false;\n\n //e.stopPropagation works only in Firefox.\n if (e.stopPropagation) e.stopPropagation();\n if (e.preventDefault) e.preventDefault();\n\n return false;\n // 이벤트 중지 구문 끝\n }\n\n /**\n * @method ax5.util.selectRange\n * @param {Element} el\n * @param {Element} offset\n * @example\n * ```\n * ax5.util.selectRange($(\"#select-test-0\")); // selectAll\n * ax5.util.selectRange($(\"#select-test-0\"), \"selectAll\"); //selectAll\n * ax5.util.selectRange($(\"#select-test-0\"), \"start\"); // focus on start\n * ax5.util.selectRange($(\"#select-test-0\"), \"end\"); // focus on end\n * ax5.util.selectRange($(\"#select-test-0\"), [1, 5]); // select 1~5\n * ```\n */\n var selectRange = (function () {\n var processor = {\n 'textRange': {\n 'selectAll': function (el, range, offset) {\n\n },\n 'arr': function (el, range, offset) {\n range.moveStart(\"character\", offset[0]); // todo ie node select 체크필요\n range.collapse();\n range.moveEnd(\"character\", offset[1]);\n },\n 'start': function (el, range, offset) {\n range.moveStart(\"character\", 0);\n range.collapse();\n },\n 'end': function (el, range, offset) {\n range.moveStart(\"character\", range.text.length);\n range.collapse();\n }\n },\n 'range': {\n 'selectAll': function (el, range, offset) {\n range.selectNodeContents(el);\n },\n 'arr': function (el, range, offset) {\n if (isObject(offset[0])) {\n range.setStart(offset[0].node, offset[0].offset);\n range.setEnd(offset[1].node, offset[1].offset);\n }\n else {\n range.setStart(el.firstChild, offset[0]);\n range.setEnd(el.firstChild, offset[1]);\n }\n },\n 'start': function (el, range, offset) {\n range.selectNodeContents(el);\n range.collapse(true);\n },\n 'end': function (el, range, offset) {\n range.selectNodeContents(el);\n range.collapse(false);\n }\n }\n };\n return function (el, offset) {\n var range, rangeType, selection;\n\n if (el instanceof jQuery) {\n el = el.get(0);\n }\n if (!el) return;\n\n // 레인지 타입 선택\n if (doc.body.createTextRange) {\n range = document.body.createTextRange();\n range.moveToElementText(el);\n rangeType = \"textRange\";\n }\n else if (window.getSelection) {\n selection = window.getSelection();\n range = document.createRange();\n rangeType = \"range\";\n }\n\n // range 적용\n if (typeof offset == \"undefined\") {\n processor[rangeType].selectAll.call(this, el, range, offset);\n }\n else if (isArray(offset)) {\n processor[rangeType].arr.call(this, el, range, offset);\n }\n else {\n for (var key in processor[rangeType]) {\n if (offset == key) {\n processor[rangeType][key].call(this, el, range, offset);\n break;\n }\n }\n }\n\n // 포커스 및 셀렉트\n if (doc.body.createTextRange) {\n range.select();\n el.focus();\n }\n else if (window.getSelection) {\n el.focus();\n selection.removeAllRanges();\n selection.addRange(range);\n }\n\n }\n })();\n\n /**\n * 지정한 시간을 지연시켜 함수를 실행합니다.\n * @method ax5.util.debounce\n * @param {Function} func\n * @param {Number} wait\n * @param {Boolean} immediately\n * @returns {debounced}\n * @example\n * ```js\n * var debounceFn = ax5.util.debounce(function( val ) { console.log(val); }, 300);\n * $(document.body).click(function(){\n * debounceFn(new Date());\n * });\n * ```\n */\n var debounce = function (func, wait, immediately) {\n var timeout, removeTimeout;\n var debounced = function () {\n var args = toArray(arguments);\n\n if (removeTimeout) clearTimeout(removeTimeout);\n if (timeout) {\n // 두번째 호출\n if (timeout) clearTimeout(timeout);\n timeout = setTimeout((function (args) {\n func.apply(this, args);\n }).bind(this, args), wait);\n } else {\n // 첫 호출\n timeout = setTimeout((function (args) {\n func.apply(this, args);\n }).bind(this, args), (immediately) ? 0 : wait);\n }\n removeTimeout = setTimeout(function () {\n clearTimeout(timeout);\n timeout = null;\n }, wait);\n };\n debounced.cancel = function () {\n clearTimeout(timeout);\n clearTimeout(removeTimeout);\n timeout = null;\n };\n\n return debounced;\n };\n\n\n /**\n * @method ax5.util.deepCopy\n * @param {Object} obj\n * @returns {Object}\n * @example\n * ```js\n * var obj = [\n * {name:\"A\", child:[{name:\"a-1\"}]},\n * {name:\"B\", child:[{name:\"b-1\"}], callBack: function(){ console.log('callBack'); }}\n * ];\n * var copiedObj = ax5.util.deepCopy(obj)\n * ```\n */\n function deepCopy(obj) {\n var r, l;\n if (typeof obj == 'object') {\n if (U.isArray(obj)) {\n l = obj.length;\n r = new Array(l);\n for (var i = 0; i < l; i++) {\n r[i] = deepCopy(obj[i]);\n }\n return r;\n } else {\n return jQuery.extend({}, obj);\n }\n }\n return obj;\n }\n\n /**\n * HTML 문자열을 escape 처리합니다.\n * \"<\" represents the < sign.\n * \">\" represents the > sign.\n * \"&\" represents the & sign.\n * \"" represents the \" mark.\n * [Character entity references](https://www.w3.org/TR/html401/charset.html#h-5.3)\n * @method ax5.util.escapeHtml\n * @param {String} s\n * @returns {string}\n * @example\n * ```\n * ax5.util.escapeHtml('HTML
string & \"escape\"')\n * //\"HTML <span>string</span> & "escape"\"\n * ```\n */\n function escapeHtml(s) {\n if (_toString.call(s) != \"[object String]\") return s;\n if (!s) return \"\";\n return s.replace(/[\\<\\>\\&\\\"]/gm, function (match) {\n switch (match) {\n case \"<\":\n return \"<\";\n case \">\":\n return \">\";\n case \"&\":\n return \"&\";\n case \"\\\"\":\n return \""\";\n default:\n return match;\n }\n });\n }\n\n /**\n * HTML 문자열을 unescape 처리합니다.\n * escapeHtml를 참고하세요.\n * @method ax5.util.unescapeHtml\n * @param {String} s\n * @returns {string}\n * @example\n * ```\n * ax5.util.unescapeHtml('HTML <span>string</span> & "escape"')\n * //\"HTML
string & \"escape\"\"\n * ```\n */\n function unescapeHtml(s) {\n if (_toString.call(s) != \"[object String]\") return s;\n if (!s) return \"\";\n return s.replace(/(<)|(>)|(&)|(")/gm, function (match) {\n switch (match) {\n case \"<\":\n return \"<\";\n case \">\":\n return \">\";\n case \"&\":\n return \"&\";\n case \""\":\n return \"\\\"\";\n default:\n return match;\n }\n });\n }\n\n /**\n * @method ax5.util.string\n * @param {String} tmpl\n * @param {*} args\n * @return {ax5string}\n * @example\n * ```js\n * ax5.util.string(\"{0} is dead, but {1} is alive! {0} {2}\").format(\"ASP\", \"ASP.NET\");\n * ax5.util.string(\"{0} is dead, but {1} is alive! {0} {2}\").format([\"ASP\", \"ASP.NET\"]);\n * ax5.util.stinrg(\"{0} counts\").format(100);\n * ```\n */\n function string(_string) {\n function ax5string(_string) {\n this.value = _string;\n this.toString = function () {\n return this.value;\n };\n /**\n * @method ax5.util.string.format\n * @returns {*}\n */\n this.format = function () {\n var args = [];\n for(var i=0,l=arguments.length;i
>> 0;\n if (typeof fun !== \"function\") {\n throw TypeError();\n }\n var thisp = arguments[1], i;\n for (i = 0; i < len; i++) {\n if (i in t) {\n fun.call(thisp, t[i], i, t);\n }\n }\n };\n }\n\n // ES5 15.3.4.5 Function.prototype.bind ( thisArg [, arg1 [, arg2, ... ]] )\n // https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Function/bind\n if (!Function.prototype.bind) {\n Function.prototype.bind = function (o) {\n if (typeof this !== 'function') {\n throw TypeError(\"function\");\n }\n var slice = [].slice,\n args = slice.call(arguments, 1),\n self = this,\n bound = function () {\n return self.apply(this instanceof nop ? this : o,\n args.concat(slice.call(arguments)));\n };\n\n function nop() {}\n\n nop.prototype = self.prototype;\n bound.prototype = new nop();\n return bound;\n };\n }\n\n /*global document */\n /**\n * define document.querySelector & document.querySelectorAll for IE7\n *\n * A not very fast but small hack. The approach is taken from\n * http://weblogs.asp.net/bleroy/archive/2009/08/31/queryselectorall-on-old-ie-versions-something-that-doesn-t-work.aspx\n *\n */\n (function () {\n if (document.querySelectorAll || document.querySelector) {\n return;\n }\n if (!document.createStyleSheet) return;\n var style = document.createStyleSheet(),\n select = function (selector, maxCount) {\n var\n all = document.all,\n l = all.length,\n i,\n resultSet = [];\n\n style.addRule(selector, \"foo:bar\");\n for (i = 0; i < l; i += 1) {\n if (all[i].currentStyle.foo === \"bar\") {\n resultSet.push(all[i]);\n if (resultSet.length > maxCount) {\n break;\n }\n }\n }\n style.removeRule(0);\n return resultSet;\n };\n\n document.querySelectorAll = function (selector) {\n return select(selector, Infinity);\n };\n document.querySelector = function (selector) {\n return select(selector, 1)[0] || null;\n };\n }());\n\n if (!String.prototype.trim) {\n (function () {\n String.prototype.trim = function () {\n return this.replace(re_trim, '');\n };\n })();\n }\n\n if (!window.JSON) {\n window.JSON = {\n parse: function (sJSON) { return (new Function('', 'return ' + sJSON))(); },\n stringify: (function () {\n var r = /[\"]/g, f;\n return f = function (vContent) {\n var result, i, j;\n switch (result = typeof vContent) {\n case'string':\n return '\"' + vContent.replace(r, '\\\\\"') + '\"';\n case'number':\n case'boolean':\n return vContent.toString();\n case'undefined':\n return 'undefined';\n case'function':\n return '\"\"';\n case'object':\n if (!vContent) return 'null';\n result = '';\n if (vContent.splice) {\n for (i = 0, j = vContent.length; i < j; i++) result += ',' + f(vContent[i]);\n return '[' + result.substr(1) + ']';\n }\n else {\n for (i in vContent) if (vContent.hasOwnProperty(i) && vContent[i] !== undefined && typeof vContent[i] != 'function') result += ',\"' + i + '\":' + f(vContent[i]);\n return '{' + result.substr(1) + '}';\n }\n }\n };\n })()\n };\n }\n\n // splice ie8 <= polyfill\n (function () {\n if (!document.documentMode || document.documentMode >= 9) return false;\n var _splice = Array.prototype.splice;\n Array.prototype.splice = function () {\n var args = Array.prototype.slice.call(arguments);\n if (typeof args[1] === \"undefined\") args[1] = this.length - args[0];\n return _splice.apply(this, args);\n };\n })();\n\n /**\n * Shim for \"fixing\" IE's lack of support (IE < 9) for applying slice\n * on host objects like NamedNodeMap, NodeList, and HTMLCollection\n * (technically, since host objects have been implementation-dependent,\n * at least before ES6, IE hasn't needed to work this way).\n * Also works on strings, fixes IE < 9 to allow an explicit undefined\n * for the 2nd argument (as in Firefox), and prevents errors when\n * called on other DOM objects.\n */\n (function () {\n 'use strict';\n var _slice = Array.prototype.slice;\n\n try {\n // Can't be used with DOM elements in IE < 9\n _slice.call(document.documentElement);\n } catch (e) { // Fails in IE < 9\n // This will work for genuine arrays, array-like objects,\n // NamedNodeMap (attributes, entities, notations),\n // NodeList (e.g., getElementsByTagName), HTMLCollection (e.g., childNodes),\n // and will not fail on other DOM objects (as do DOM elements in IE < 9)\n Array.prototype.slice = function(begin, end) {\n // IE < 9 gets unhappy with an undefined end argument\n end = (typeof end !== 'undefined') ? end : this.length;\n\n // For native Array objects, we use the native slice function\n if (Object.prototype.toString.call(this) === '[object Array]'){\n return _slice.call(this, begin, end);\n }\n\n // For array like object we handle it ourselves.\n var i, cloned = [],\n size, len = this.length;\n\n // Handle negative value for \"begin\"\n var start = begin || 0;\n start = (start >= 0) ? start : Math.max(0, len + start);\n\n // Handle negative value for \"end\"\n var upTo = (typeof end == 'number') ? Math.min(end, len) : len;\n if (end < 0) {\n upTo = len + end;\n }\n \n // Actual expected size of the slice\n size = upTo - start;\n\n if (size > 0) {\n cloned = new Array(size);\n if (this.charAt) {\n for (i = 0; i < size; i++) {\n cloned[i] = this.charAt(start + i);\n }\n } else {\n for (i = 0; i < size; i++) {\n cloned[i] = this[start + i];\n }\n }\n }\n\n return cloned;\n };\n }\n }());\n\n // Console-polyfill. MIT license. https://github.com/paulmillr/console-polyfill\n // Make it safe to do console.log() always.\n (function (con) {\n var prop, method;\n var empty = {};\n var dummy = function () {};\n var properties = 'memory'.split(',');\n var methods = ('assert,clear,count,debug,dir,dirxml,error,exception,group,' +\n 'groupCollapsed,groupEnd,info,log,markTimeline,profile,profiles,profileEnd,' +\n 'show,table,time,timeEnd,timeline,timelineEnd,timeStamp,trace,warn').split(',');\n while (prop = properties.pop()) con[prop] = con[prop] || empty;\n while (method = methods.pop()) con[method] = con[method] || dummy;\n })(window.console || {}); // Using `this` for web workers.\n\n\n // Modernizr style test\n if (!(window.webkitMatchMedia || window.mozMatchMedia || window.oMatchMedia || window.msMatchMedia || window.matchMedia)) {\n var root = document.getElementsByTagName( 'html' )[0];\n root.className += ' no-matchmedia';\n }\n\n /*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas, David Knight. Dual MIT/BSD license */\n window.matchMedia || (window.matchMedia = function() {\n \"use strict\";\n\n // For browsers that support matchMedium api such as IE 9 and webkit\n var styleMedia = (window.styleMedia || window.media);\n\n // For those that don't support matchMedium\n if (!styleMedia) {\n var style = document.createElement('style'),\n script = document.getElementsByTagName('script')[0],\n info = null;\n\n style.type = 'text/css';\n style.id = 'matchmediajs-test';\n\n script.parentNode.insertBefore(style, script);\n\n // 'style.currentStyle' is used by IE <= 8 and 'window.getComputedStyle' for all other browsers\n info = ('getComputedStyle' in window) && window.getComputedStyle(style, null) || style.currentStyle;\n\n styleMedia = {\n matchMedium: function(media) {\n var text = '@media ' + media + '{ #matchmediajs-test { width: 1px; } }';\n\n // 'style.styleSheet' is used by IE <= 8 and 'style.textContent' for all other browsers\n if (style.styleSheet) {\n style.styleSheet.cssText = text;\n } else {\n style.textContent = text;\n }\n\n // Test if media query is true or false\n return info.width === '1px';\n }\n };\n }\n\n return function(media) {\n return {\n matches: styleMedia.matchMedium(media || 'all'),\n media: media || 'all'\n };\n };\n }());\n\n /*! matchMedia() polyfill addListener/removeListener extension. Author & copyright (c) 2012: Scott Jehl. Dual MIT/BSD license */\n (function(){\n // Bail out for browsers that have addListener support\n if (window.matchMedia && window.matchMedia('all').addListener) {\n return false;\n }\n\n var localMatchMedia = window.matchMedia,\n hasMediaQueries = localMatchMedia('only all').matches,\n isListening = false,\n timeoutID = 0, // setTimeout for debouncing 'handleChange'\n queries = [], // Contains each 'mql' and associated 'listeners' if 'addListener' is used\n handleChange = function(evt) {\n // Debounce\n clearTimeout(timeoutID);\n\n timeoutID = setTimeout(function() {\n for (var i = 0, il = queries.length; i < il; i++) {\n var mql = queries[i].mql,\n listeners = queries[i].listeners || [],\n matches = localMatchMedia(mql.media).matches;\n\n // Update mql.matches value and call listeners\n // Fire listeners only if transitioning to or from matched state\n if (matches !== mql.matches) {\n mql.matches = matches;\n\n for (var j = 0, jl = listeners.length; j < jl; j++) {\n listeners[j].call(window, mql);\n }\n }\n }\n }, 30);\n };\n\n window.matchMedia = function(media) {\n var mql = localMatchMedia(media),\n listeners = [],\n index = 0;\n\n mql.addListener = function(listener) {\n // Changes would not occur to css media type so return now (Affects IE <= 8)\n if (!hasMediaQueries) {\n return;\n }\n\n // Set up 'resize' listener for browsers that support CSS3 media queries (Not for IE <= 8)\n // There should only ever be 1 resize listener running for performance\n if (!isListening) {\n isListening = true;\n window.addEventListener('resize', handleChange, true);\n }\n\n // Push object only if it has not been pushed already\n if (index === 0) {\n index = queries.push({\n mql : mql,\n listeners : listeners\n });\n }\n\n listeners.push(listener);\n };\n\n mql.removeListener = function(listener) {\n for (var i = 0, il = listeners.length; i < il; i++){\n if (listeners[i] === listener){\n listeners.splice(i, 1);\n }\n }\n };\n\n return mql;\n };\n }());\n\n // extend innerWidth ..\n var html = document.getElementsByTagName('html')[0];\n var body = document.getElementsByTagName('body')[0];\n\n /*\n if (!window.innerWidth) window.innerWidth = html.clientWidth;\n if (!window.innerHeight) window.innerHeight = html.clientHeight;\n if (!window.scrollX) window.scrollX = window.pageXOffset || html.scrollLeft;\n if (!window.scrollY) window.scrollY = window.pageYOffset || html.scrollTop;\n */\n}.call(window));","/**\n * Refer to this by {@link ax5}.\n * @namespace ax5.ui\n */\n\n/**\n * @class ax5.ui.root\n * @classdesc ax5 ui class\n * @author tom@axisj.com\n * @example\n * ```\n * var myui = new ax5.ui.root();\n * ```\n */\nax5.ui = (function () {\n\n function axUi() {\n this.config = {};\n this.name = \"root\";\n\n /**\n * 클래스의 속성 정의 메소드 속성 확장후에 내부에 init 함수를 호출합니다.\n * @method ax5.ui.root.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Boolean} [callInit=true] - init 함수 호출 여부\n * @returns {ax5.ui.axUi}\n * @example\n * ```\n * var myui = new ax5.ui.root();\n * myui.setConfig({\n\t\t * \tid:\"abcd\"\n\t\t * });\n * ```\n */\n this.setConfig = function (cfg, callInit) {\n jQuery.extend(true, this.config, cfg);\n if (typeof callInit == \"undefined\" || callInit === true) {\n this.init();\n }\n return this;\n };\n this.init = function () {\n console.log(this.config);\n };\n\n this.bindWindowResize = function (callBack) {\n setTimeout((function () {\n jQuery(window).resize((function () {\n if (this.bindWindowResize__) clearTimeout(this.bindWindowResize__);\n this.bindWindowResize__ = setTimeout((function () {\n callBack.call(this);\n }).bind(this), 10);\n }).bind(this));\n }).bind(this), 100);\n };\n\n this.stopEvent = function (e) {\n if (e.preventDefault) e.preventDefault();\n if (e.stopPropagation) e.stopPropagation();\n e.cancelBubble = true;\n return false;\n };\n\n this.toString = function () {\n return this.name + '@' + this.version;\n };\n\n // instance init\n this.main = (function () {\n\n }).apply(this, arguments);\n\n }\n\n /**\n * @method ax5.ui.addClass\n * @param {Object} config\n * @param {String} config.className - name of Class\n * @param {String} [config.version=\"\"] - version of Class\n * @param {Object} [config.classStore=ax5.ui] - 클래스가 저장될 경로\n * @param {Function} [config.superClass=ax5.ui.root]\n * @param {Function} cls - Class Function\n */\n function addClass(config, cls) {\n if (!config || !config.className) throw 'invalid call';\n var classStore = (config.classStore) ? config.classStore : ax5.ui;\n if (!classStore) throw 'invalid classStore';\n\n // make ui definition variable\n ax5.def[config.className] = {\n version: config.version\n };\n\n var factory = function (cls, arg) {\n switch (arg.length) {\n case 0:\n return new cls();\n break;\n case 1:\n return new cls(arg[0]);\n break;\n case 2:\n return new cls(arg[0], arg[1]);\n break;\n case 3:\n return new cls(arg[0], arg[1], arg[2]);\n break;\n }\n };\n var initInstance = function (name, version, instance) {\n instance.name = name;\n instance.version = version;\n instance.instanceId = ax5.getGuid();\n return instance;\n };\n var initPrototype = function (cls) {\n var superClass = (config.superClass) ? config.superClass : ax5.ui.root;\n if (!ax5.util.isFunction(superClass)) throw 'invalid superClass';\n superClass.call(this); // 부모호출\n cls.prototype = new superClass(); // 상속\n };\n var wrapper = function () {\n if (!this || !(this instanceof wrapper)) throw 'invalid call';\n var instance = factory(cls, arguments);\n return initInstance(config.className, config.version || \"\", instance);\n };\n initPrototype.call(this, cls);\n classStore[config.className] = wrapper;\n }\n\n return {\n root: axUi,\n addClass: addClass\n }\n})();\n","/*!\n * mustache.js - Logic-less {{mustache}} templates with JavaScript\n * http://github.com/janl/mustache.js\n * https://github.com/thomasJang/mustache.js -- imporove some variables\n */\n\n(function defineMustache(global, factory) {\n\n factory(global.mustache = {});\n\n}(window.ax5, function mustacheFactory(mustache) {\n\n var objectToString = Object.prototype.toString;\n var isArray = Array.isArray || function isArrayPolyfill(object) {\n return objectToString.call(object) === '[object Array]';\n };\n\n function isFunction(object) {\n return typeof object === 'function';\n }\n\n /**\n * More correct typeof string handling array\n * which normally returns typeof 'object'\n */\n function typeStr(obj) {\n return isArray(obj) ? 'array' : typeof obj;\n }\n\n function escapeRegExp(string) {\n return string.replace(/[\\-\\[\\]{}()*+?.,\\\\\\^$|#\\s]/g, '\\\\$&');\n }\n\n /**\n * Null safe way of checking whether or not an object,\n * including its prototype, has a given property\n */\n function hasProperty(obj, propName) {\n return obj != null && typeof obj === 'object' && (propName in obj);\n }\n\n // Workaround for https://issues.apache.org/jira/browse/COUCHDB-577\n // See https://github.com/janl/mustache.js/issues/189\n var regExpTest = RegExp.prototype.test;\n\n function testRegExp(re, string) {\n return regExpTest.call(re, string);\n }\n\n var nonSpaceRe = /\\S/;\n\n function isWhitespace(string) {\n return !testRegExp(nonSpaceRe, string);\n }\n\n var entityMap = {\n '&': '&', '<': '<', '>': '>', '\"': '"', \"'\": ''', '/': '/'\n };\n\n function escapeHtml(string) {\n return String(string).replace(/[&<>\"'\\/]/g, function fromEntityMap(s) {\n return entityMap[s];\n });\n }\n\n var whiteRe = /\\s*/;\n var spaceRe = /\\s+/;\n var equalsRe = /\\s*=/;\n var curlyRe = /\\s*\\}/;\n var tagRe = /#|\\^|\\/|>|\\{|&|=|!/;\n\n /**\n * Breaks up the given `template` string into a tree of tokens. If the `tags`\n * argument is given here it must be an array with two string values: the\n * opening and closing tags used in the template (e.g. [ \"<%\", \"%>\" ]). Of\n * course, the default is to use mustaches (i.e. mustache.tags).\n *\n * A token is an array with at least 4 elements. The first element is the\n * mustache symbol that was used inside the tag, e.g. \"#\" or \"&\". If the tag\n * did not contain a symbol (i.e. {{myValue}}) this element is \"name\". For\n * all text that appears outside a symbol this element is \"text\".\n *\n * The second element of a token is its \"value\". For mustache tags this is\n * whatever else was inside the tag besides the opening symbol. For text tokens\n * this is the text itself.\n *\n * The third and fourth elements of the token are the start and end indices,\n * respectively, of the token in the original template.\n *\n * Tokens that are the root node of a subtree contain two more elements: 1) an\n * array of tokens in the subtree and 2) the index in the original template at\n * which the closing tag for that section begins.\n */\n function parseTemplate(template, tags) {\n if (!template)\n return [];\n\n var sections = []; // Stack to hold section tokens\n var tokens = []; // Buffer to hold the tokens\n var spaces = []; // Indices of whitespace tokens on the current line\n var hasTag = false; // Is there a {{tag}} on the current line?\n var nonSpace = false; // Is there a non-space char on the current line?\n\n // Strips all whitespace tokens array for the current line\n // if there was a {{#tag}} on it and otherwise only space.\n function stripSpace() {\n if (hasTag && !nonSpace) {\n while (spaces.length)\n delete tokens[spaces.pop()];\n }\n else {\n spaces = [];\n }\n\n hasTag = false;\n nonSpace = false;\n }\n\n var openingTagRe, closingTagRe, closingCurlyRe;\n\n function compileTags(tagsToCompile) {\n if (typeof tagsToCompile === 'string')\n tagsToCompile = tagsToCompile.split(spaceRe, 2);\n\n if (!isArray(tagsToCompile) || tagsToCompile.length !== 2)\n throw new Error('Invalid tags: ' + tagsToCompile);\n\n openingTagRe = new RegExp(escapeRegExp(tagsToCompile[0]) + '\\\\s*');\n closingTagRe = new RegExp('\\\\s*' + escapeRegExp(tagsToCompile[1]));\n closingCurlyRe = new RegExp('\\\\s*' + escapeRegExp('}' + tagsToCompile[1]));\n }\n\n compileTags(tags || mustache.tags);\n\n var scanner = new Scanner(template);\n\n var start, type, value, chr, token, openSection;\n while (!scanner.eos()) {\n start = scanner.pos;\n\n // Match any text between tags.\n value = scanner.scanUntil(openingTagRe);\n\n if (value) {\n for (var i = 0, valueLength = value.length; i < valueLength; ++i) {\n chr = value.charAt(i);\n\n if (isWhitespace(chr)) {\n spaces.push(tokens.length);\n }\n else {\n nonSpace = true;\n }\n\n tokens.push(['text', chr, start, start + 1]);\n start += 1;\n\n // Check for whitespace on the current line.\n if (chr === '\\n')\n stripSpace();\n }\n }\n\n // Match the opening tag.\n if (!scanner.scan(openingTagRe))\n break;\n\n hasTag = true;\n\n // Get the tag type.\n type = scanner.scan(tagRe) || 'name';\n scanner.scan(whiteRe);\n\n // Get the tag value.\n if (type === '=') {\n value = scanner.scanUntil(equalsRe);\n scanner.scan(equalsRe);\n scanner.scanUntil(closingTagRe);\n }\n else if (type === '{') {\n value = scanner.scanUntil(closingCurlyRe);\n scanner.scan(curlyRe);\n scanner.scanUntil(closingTagRe);\n type = '&';\n }\n else {\n value = scanner.scanUntil(closingTagRe);\n }\n\n // Match the closing tag.\n if (!scanner.scan(closingTagRe))\n throw new Error('Unclosed tag at ' + scanner.pos);\n\n token = [type, value, start, scanner.pos];\n tokens.push(token);\n\n if (type === '#' || type === '^') {\n sections.push(token);\n }\n else if (type === '/') {\n // Check section nesting.\n openSection = sections.pop();\n\n if (!openSection)\n throw new Error('Unopened section \"' + value + '\" at ' + start);\n\n if (openSection[1] !== value)\n throw new Error('Unclosed section \"' + openSection[1] + '\" at ' + start);\n }\n else if (type === 'name' || type === '{' || type === '&') {\n nonSpace = true;\n }\n else if (type === '=') {\n // Set the tags for the next time around.\n compileTags(value);\n }\n }\n\n // Make sure there are no open sections when we're done.\n openSection = sections.pop();\n\n if (openSection)\n throw new Error('Unclosed section \"' + openSection[1] + '\" at ' + scanner.pos);\n\n return nestTokens(squashTokens(tokens));\n }\n\n /**\n * Combines the values of consecutive text tokens in the given `tokens` array\n * to a single token.\n */\n function squashTokens(tokens) {\n var squashedTokens = [];\n\n var token, lastToken;\n for (var i = 0, numTokens = tokens.length; i < numTokens; ++i) {\n token = tokens[i];\n\n if (token) {\n if (token[0] === 'text' && lastToken && lastToken[0] === 'text') {\n lastToken[1] += token[1];\n lastToken[3] = token[3];\n }\n else {\n squashedTokens.push(token);\n lastToken = token;\n }\n }\n }\n\n return squashedTokens;\n }\n\n /**\n * Forms the given array of `tokens` into a nested tree structure where\n * tokens that represent a section have two additional items: 1) an array of\n * all tokens that appear in that section and 2) the index in the original\n * template that represents the end of that section.\n */\n function nestTokens(tokens) {\n var nestedTokens = [];\n var collector = nestedTokens;\n var sections = [];\n\n var token, section;\n for (var i = 0, numTokens = tokens.length; i < numTokens; ++i) {\n token = tokens[i];\n\n switch (token[0]) {\n case '#':\n case '^':\n collector.push(token);\n sections.push(token);\n collector = token[4] = [];\n break;\n case '/':\n section = sections.pop();\n section[5] = token[2];\n collector = sections.length > 0 ? sections[sections.length - 1][4] : nestedTokens;\n break;\n default:\n collector.push(token);\n }\n }\n\n return nestedTokens;\n }\n\n /**\n * A simple string scanner that is used by the template parser to find\n * tokens in template strings.\n */\n function Scanner(string) {\n this.string = string;\n this.tail = string;\n this.pos = 0;\n }\n\n /**\n * Returns `true` if the tail is empty (end of string).\n */\n Scanner.prototype.eos = function eos() {\n return this.tail === '';\n };\n\n /**\n * Tries to match the given regular expression at the current position.\n * Returns the matched text if it can match, the empty string otherwise.\n */\n Scanner.prototype.scan = function scan(re) {\n var match = this.tail.match(re);\n\n if (!match || match.index !== 0)\n return '';\n\n var string = match[0];\n\n this.tail = this.tail.substring(string.length);\n this.pos += string.length;\n\n return string;\n };\n\n /**\n * Skips all text until the given regular expression can be matched. Returns\n * the skipped string, which is the entire tail if no match can be made.\n */\n Scanner.prototype.scanUntil = function scanUntil(re) {\n var index = this.tail.search(re), match;\n\n switch (index) {\n case -1:\n match = this.tail;\n this.tail = '';\n break;\n case 0:\n match = '';\n break;\n default:\n match = this.tail.substring(0, index);\n this.tail = this.tail.substring(index);\n }\n\n this.pos += match.length;\n\n return match;\n };\n\n /**\n * Represents a rendering context by wrapping a view object and\n * maintaining a reference to the parent context.\n */\n function Context(view, parentContext) {\n this.view = view;\n this.cache = {\n '.': this.view,\n '@each': function () {\n var returns = [];\n for (var k in this) {\n returns.push({'@key': k, '@value': this[k]});\n }\n return returns;\n }\n };\n this.parent = parentContext;\n }\n\n /**\n * Creates a new context using the given view with this context\n * as the parent.\n */\n Context.prototype.push = function push(view) {\n return new Context(view, this);\n };\n\n /**\n * Returns the value of the given name in this context, traversing\n * up the context hierarchy if the value is absent in this context's view.\n */\n Context.prototype.lookup = function lookup(name) {\n var cache = this.cache;\n\n var value;\n if (cache.hasOwnProperty(name)) {\n value = cache[name];\n }\n else {\n var context = this, names, index, lookupHit = false;\n\n while (context) {\n if (name.indexOf('.') > 0) {\n value = context.view;\n names = name.split('.');\n index = 0;\n\n /**\n * Using the dot notion path in `name`, we descend through the\n * nested objects.\n *\n * To be certain that the lookup has been successful, we have to\n * check if the last object in the path actually has the property\n * we are looking for. We store the result in `lookupHit`.\n *\n * This is specially necessary for when the value has been set to\n * `undefined` and we want to avoid looking up parent contexts.\n **/\n while (value != null && index < names.length) {\n if (index === names.length - 1)\n lookupHit = hasProperty(value, names[index]);\n\n value = value[names[index++]];\n }\n }\n else {\n value = context.view[name];\n lookupHit = hasProperty(context.view, name);\n }\n\n if (lookupHit)\n break;\n\n context = context.parent;\n }\n\n cache[name] = value;\n }\n\n if (isFunction(value))\n value = value.call(this.view);\n\n return value;\n };\n\n /**\n * A Writer knows how to take a stream of tokens and render them to a\n * string, given a context. It also maintains a cache of templates to\n * avoid the need to parse the same template twice.\n */\n function Writer() {\n this.cache = {};\n }\n\n /**\n * Clears all cached templates in this writer.\n */\n Writer.prototype.clearCache = function clearCache() {\n this.cache = {};\n };\n\n /**\n * Parses and caches the given `template` and returns the array of tokens\n * that is generated from the parse.\n */\n Writer.prototype.parse = function parse(template, tags) {\n var cache = this.cache;\n var tokens = cache[template];\n\n if (tokens == null)\n tokens = cache[template] = parseTemplate(template, tags);\n\n return tokens;\n };\n\n /**\n * High-level method that is used to render the given `template` with\n * the given `view`.\n *\n * The optional `partials` argument may be an object that contains the\n * names and templates of partials that are used in the template. It may\n * also be a function that is used to load partial templates on the fly\n * that takes a single argument: the name of the partial.\n */\n Writer.prototype.render = function render(template, view, partials) {\n var tokens = this.parse(template);\n var context = (view instanceof Context) ? view : new Context(view);\n return this.renderTokens(tokens, context, partials, template);\n };\n\n /**\n * Low-level method that renders the given array of `tokens` using\n * the given `context` and `partials`.\n *\n * Note: The `originalTemplate` is only ever used to extract the portion\n * of the original template that was contained in a higher-order section.\n * If the template doesn't use higher-order sections, this argument may\n * be omitted.\n */\n Writer.prototype.renderTokens = function renderTokens(tokens, context, partials, originalTemplate) {\n var buffer = '';\n var token, symbol, value;\n for (var i = 0, numTokens = tokens.length; i < numTokens; ++i) {\n value = undefined;\n token = tokens[i];\n symbol = token[0];\n\n if (symbol === '#') value = this.renderSection(token, context, partials, originalTemplate);\n else if (symbol === '^') value = this.renderInverted(token, context, partials, originalTemplate);\n else if (symbol === '>') value = this.renderPartial(token, context, partials, originalTemplate);\n else if (symbol === '&') value = this.unescapedValue(token, context);\n else if (symbol === 'name') value = this.escapedValue(token, context);\n else if (symbol === 'text') value = this.rawValue(token);\n\n if (value !== undefined)\n buffer += value;\n }\n\n return buffer;\n };\n\n Writer.prototype.renderSection = function renderSection(token, context, partials, originalTemplate) {\n var self = this;\n var buffer = '';\n\n var value = context.lookup(token[1]);\n\n // This function is used to render an arbitrary template\n // in the current context by higher-order sections.\n function subRender(template) {\n return self.render(template, context, partials);\n }\n\n if (!value) return;\n\n if (isArray(value)) {\n for (var j = 0, valueLength = value.length; j < valueLength; ++j) {\n if (value[j]) {\n if (typeof value[j] === 'object') {\n value[j]['@i'] = j;\n value[j]['@first'] = (j === 0);\n }\n\n buffer += this.renderTokens(token[4], context.push(value[j]), partials, originalTemplate);\n }\n }\n }\n else if (typeof value === 'object' || typeof value === 'string' || typeof value === 'number') {\n buffer += this.renderTokens(token[4], context.push(value), partials, originalTemplate);\n }\n else if (isFunction(value)) {\n if (typeof originalTemplate !== 'string')\n throw new Error('Cannot use higher-order sections without the original template');\n\n // Extract the portion of the original template that the section contains.\n value = value.call(context.view, originalTemplate.slice(token[3], token[5]), subRender);\n\n if (value != null)\n buffer += value;\n }\n else {\n buffer += this.renderTokens(token[4], context, partials, originalTemplate);\n }\n return buffer;\n };\n\n Writer.prototype.renderInverted = function renderInverted(token, context, partials, originalTemplate) {\n var value = context.lookup(token[1]);\n\n // Use JavaScript's definition of falsy. Include empty arrays.\n // See https://github.com/janl/mustache.js/issues/186\n if (!value || (isArray(value) && value.length === 0))\n return this.renderTokens(token[4], context, partials, originalTemplate);\n };\n\n Writer.prototype.renderPartial = function renderPartial(token, context, partials) {\n if (!partials) return;\n\n var value = isFunction(partials) ? partials(token[1]) : partials[token[1]];\n if (value != null)\n return this.renderTokens(this.parse(value), context, partials, value);\n };\n\n Writer.prototype.unescapedValue = function unescapedValue(token, context) {\n var value = context.lookup(token[1]);\n if (value != null)\n return value;\n };\n\n Writer.prototype.escapedValue = function escapedValue(token, context) {\n var value = context.lookup(token[1]);\n if (value != null)\n return mustache.escape(value);\n };\n\n Writer.prototype.rawValue = function rawValue(token) {\n return token[1];\n };\n\n mustache.name = 'mustache.js';\n mustache.version = '2.1.3';\n mustache.tags = ['{{', '}}'];\n\n // All high-level mustache.* functions use this writer.\n var defaultWriter = new Writer();\n\n /**\n * Clears all cached templates in the default writer.\n */\n mustache.clearCache = function clearCache() {\n return defaultWriter.clearCache();\n };\n\n /**\n * Parses and caches the given template in the default writer and returns the\n * array of tokens it contains. Doing this ahead of time avoids the need to\n * parse templates on the fly as they are rendered.\n */\n mustache.parse = function parse(template, tags) {\n return defaultWriter.parse(template, tags);\n };\n\n /**\n * Renders the `template` with the given `view` and `partials` using the\n * default writer.\n */\n mustache.render = function render(template, view, partials) {\n if (typeof template !== 'string') {\n throw new TypeError('Invalid template! Template should be a \"string\" ' + 'but \"' + typeStr(template) + '\" was given as the first ' + 'argument for mustache#render(template, view, partials)');\n }\n\n return defaultWriter.render(template, view, partials);\n };\n\n // This is here for backwards compatibility with 0.4.x.,\n /*eslint-disable */ // eslint wants camel cased function name\n mustache.to_html = function to_html(template, view, partials, send) {\n /*eslint-enable*/\n\n var result = mustache.render(template, view, partials);\n\n if (isFunction(send)) {\n send(result);\n }\n else {\n return result;\n }\n };\n\n // Export the escaping function so that the user may override it.\n // See https://github.com/janl/mustache.js/issues/244\n mustache.escape = escapeHtml;\n\n // Export these mainly for testing, but also for advanced usage.\n mustache.Scanner = Scanner;\n mustache.Context = Context;\n mustache.Writer = Writer;\n\n}));","// ax5.ui.dialog\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var DIALOG;\n\n UI.addClass({\n className: \"dialog\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5dialog\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var dialog = new ax5.ui.dialog();\n * var mask = new ax5.ui.mask();\n * dialog.setConfig({\n * zIndex: 5000,\n * onStateChanged: function () {\n * if (this.state === \"open\") {\n * mask.open();\n * }\n * else if (this.state === \"close\") {\n * mask.close();\n * }\n * }\n * });\n *\n * dialog.alert({\n * theme: 'default',\n * title: 'Alert default',\n * msg: theme + ' color'\n * }, function () {\n * console.log(this);\n * });\n * ```\n */\n var ax5dialog = function () {\n var\n self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n id: 'ax5-dialog-' + this.instanceId,\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchend\" : \"click\"),\n theme: 'default',\n width: 300,\n title: '',\n msg: '',\n lang: {\n \"ok\": \"ok\", \"cancel\": \"cancel\"\n },\n animateTime: 150\n };\n this.activeDialog = null;\n cfg = this.config;\n\n var\n onStateChanged = function (opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n that = null;\n return true;\n },\n /**\n * @method ax5dialog.getContent\n * @param {String} dialogId\n * @param {Object} opts\n * @returns dialogDisplay\n */\n getContent = function (dialogId, opts) {\n var\n data = {\n dialogId: dialogId,\n title: (opts.title || cfg.title || \"\"),\n msg: (opts.msg || cfg.msg || \"\").replace(/\\n/g, \"
\"),\n input: opts.input,\n btns: opts.btns,\n '_crlf': function () {\n return this.replace(/\\n/g, \"
\");\n }\n };\n\n try {\n return DIALOG.tmpl.get.call(this, \"dialogDisplay\", data);\n }\n finally {\n data = null;\n }\n },\n /**\n * @method ax5dialog.open\n * @param {Object} opts\n * @param callback\n */\n open = function (opts, callback) {\n var pos = {}, box;\n\n opts.id = (opts.id || cfg.id);\n\n box = {\n width: opts.width\n };\n jQuery(document.body).append(getContent.call(this, opts.id, opts));\n\n this.activeDialog = jQuery('#' + opts.id);\n this.activeDialog.css({width: box.width});\n\n // dialog 높이 구하기 - 너비가 정해지면 높이가 변경 될 것.\n opts.height = box.height = this.activeDialog.height();\n\n //- position 정렬\n if (typeof opts.position === \"undefined\" || opts.position === \"center\") {\n pos.top = jQuery(window).height() / 2 - box.height / 2;\n pos.left = jQuery(window).width() / 2 - box.width / 2;\n }\n else {\n pos.left = opts.position.left || 0;\n pos.top = opts.position.top || 0;\n }\n if (cfg.zIndex) {\n pos[\"z-index\"] = cfg.zIndex;\n }\n this.activeDialog.css(pos);\n\n // bind button event\n if (opts.dialogType === \"prompt\") {\n this.activeDialog.find(\"[data-dialog-prompt]\").get(0).focus();\n }\n else {\n this.activeDialog.find(\"[data-dialog-btn]\").get(0).focus();\n }\n\n this.activeDialog.find(\"[data-dialog-btn]\").on(cfg.clickEventName, (function (e) {\n btnOnClick.call(this, e || window.event, opts, callback);\n }).bind(this));\n\n // bind key event\n jQuery(window).bind(\"keydown.ax5dialog\", (function (e) {\n onKeyup.call(this, e || window.event, opts, callback);\n }).bind(this));\n\n jQuery(window).bind(\"resize.ax5dialog\", (function (e) {\n align.call(this, e || window.event);\n }).bind(this));\n\n onStateChanged.call(this, opts, {\n self: this,\n state: \"open\"\n });\n\n pos = null;\n box = null;\n },\n align = function (e) {\n if (!this.activeDialog) return this;\n var\n opts = self.dialogConfig,\n box = {\n width: opts.width,\n height: opts.height\n };\n //- position 정렬\n if (typeof opts.position === \"undefined\" || opts.position === \"center\") {\n box.top = window.innerHeight / 2 - box.height / 2;\n box.left = window.innerWidth / 2 - box.width / 2;\n }\n else {\n box.left = opts.position.left || 0;\n box.top = opts.position.top || 0;\n }\n if (box.left < 0) box.left = 0;\n if (box.top < 0) box.top = 0;\n\n this.activeDialog.css(box);\n\n opts = null;\n box = null;\n\n return this;\n },\n btnOnClick = function (e, opts, callback, target, k) {\n var that;\n if (e.srcElement) e.target = e.srcElement;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-dialog-btn\")) {\n return true;\n }\n });\n\n if (target) {\n k = target.getAttribute(\"data-dialog-btn\");\n\n that = {\n self: this,\n key: k, value: opts.btns[k],\n dialogId: opts.id,\n btnTarget: target\n };\n if (opts.dialogType === \"prompt\") {\n var emptyKey = null;\n for (var oi in opts.input) {\n that[oi] = this.activeDialog.find('[data-dialog-prompt=' + oi + ']').val();\n if (that[oi] == \"\" || that[oi] == null) {\n emptyKey = oi;\n break;\n }\n }\n }\n if (opts.btns[k].onClick) {\n opts.btns[k].onClick.call(that, k);\n }\n else if (opts.dialogType === \"alert\") {\n if (callback) callback.call(that, k);\n this.close({doNotCallback: true});\n }\n else if (opts.dialogType === \"confirm\") {\n if (callback) callback.call(that, k);\n this.close({doNotCallback: true});\n }\n else if (opts.dialogType === \"prompt\") {\n if (k === 'ok') {\n if (emptyKey) {\n this.activeDialog.find('[data-dialog-prompt=\"' + emptyKey + '\"]').get(0).focus();\n return false;\n }\n }\n if (callback) callback.call(that, k);\n this.close({doNotCallback: true});\n }\n }\n\n that = null;\n opts = null;\n callback = null;\n target = null;\n k = null;\n },\n onKeyup = function (e, opts, callback, target, k) {\n var\n that,\n emptyKey = null;\n\n if (e.keyCode == ax5.info.eventKeys.ESC) {\n this.close();\n }\n if (opts.dialogType === \"prompt\") {\n if (e.keyCode == ax5.info.eventKeys.RETURN) {\n that = {\n self: this,\n key: k, value: opts.btns[k],\n dialogId: opts.id,\n btnTarget: target\n };\n\n for (var oi in opts.input) {\n that[oi] = this.activeDialog.find('[data-dialog-prompt=' + oi + ']').val();\n if (that[oi] == \"\" || that[oi] == null) {\n emptyKey = oi;\n break;\n }\n }\n if (emptyKey) {\n that = null;\n emptyKey = null;\n return false;\n }\n if (callback) callback.call(that, k);\n this.close({doNotCallback: true});\n }\n }\n\n that = null;\n emptyKey = null;\n opts = null;\n callback = null;\n target = null;\n k = null;\n };\n\n /**\n * Preferences of dialog UI\n * @method ax5dialog.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Number} [config.zIndex]\n * @returns {ax5dialog}\n * @example\n * ```\n * ```\n */\n //== class body start\n this.init = function () {\n\n this.onStateChanged = cfg.onStateChanged;\n // this.onLoad = cfg.onLoad;\n\n };\n\n /**\n * open the dialog of alert type\n * @method ax5dialog.alert\n * @param {Object|String} [{theme, title, msg, btns}|msg] - dialog 속성을 json으로 정의하거나 msg만 전달\n * @param {Function} [callback] - 사용자 확인 이벤트시 호출될 callback 함수\n * @returns {ax5dialog}\n * @example\n * ```\n * myDialog.alert({\n * title: 'app title',\n * msg: 'alert'\n * }, function(){});\n * ```\n */\n this.alert = function (opts, callback, tryCount) {\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n }\n }\n\n if (this.activeDialog) {\n // try one more\n if (!tryCount) {\n setTimeout((function () {\n this.alert(opts, callback, 1);\n }).bind(this), Number(cfg.animateTime) + 100);\n } else {\n console.log(ax5.info.getError(\"ax5dialog\", \"501\", \"alert\"));\n }\n return this;\n }\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n\n\n opts.dialogType = \"alert\";\n opts.theme = (opts.theme || cfg.theme || \"\");\n opts.callback = callback;\n\n if (typeof opts.btns === \"undefined\") {\n opts.btns = {\n ok: {label: cfg.lang[\"ok\"], theme: opts.theme}\n };\n }\n open.call(this, opts, callback);\n\n return this;\n };\n\n /**\n * open the dialog of confirm type\n * @method ax5dialog.confirm\n * @param {Object|String} [{theme, title, msg, btns}|msg] - dialog 속성을 json으로 정의하거나 msg만 전달\n * @param {Function} [callback] - 사용자 확인 이벤트시 호출될 callback 함수\n * @returns {ax5dialog}\n * @example\n * ```\n * myDialog.confirm({\n * title: 'app title',\n * msg: 'confirm'\n * }, function(){});\n * ```\n */\n this.confirm = function (opts, callback, tryCount) {\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n }\n }\n\n if (this.activeDialog) {\n // try one more\n if (!tryCount) {\n setTimeout((function () {\n this.confirm(opts, callback, 1);\n }).bind(this), Number(cfg.animateTime) + 100);\n } else {\n console.log(ax5.info.getError(\"ax5dialog\", \"501\", \"confirm\"));\n }\n return this;\n }\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n\n opts.dialogType = \"confirm\";\n opts.theme = (opts.theme || cfg.theme || \"\");\n opts.callback = callback;\n\n if (typeof opts.btns === \"undefined\") {\n opts.btns = {\n ok: {label: cfg.lang[\"ok\"], theme: opts.theme},\n cancel: {label: cfg.lang[\"cancel\"]}\n };\n }\n open.call(this, opts, callback);\n\n return this;\n };\n\n /**\n * open the dialog of prompt type\n * @method ax5dialog.prompt\n * @param {Object|String} [{theme, title, msg, btns, input}|msg] - dialog 속성을 json으로 정의하거나 msg만 전달\n * @param {Function} [callback] - 사용자 확인 이벤트시 호출될 callback 함수\n * @returns {ax5dialog}\n * @example\n * ```\n * myDialog.prompt({\n * title: 'app title',\n * msg: 'alert'\n * }, function(){});\n * ```\n */\n this.prompt = function (opts, callback, tryCount) {\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n }\n }\n\n if (this.activeDialog) {\n // try one more\n if (!tryCount) {\n setTimeout((function () {\n this.prompt(opts, callback, 1);\n }).bind(this), Number(cfg.animateTime) + 100);\n } else {\n console.log(ax5.info.getError(\"ax5dialog\", \"501\", \"prompt\"));\n }\n return this;\n }\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n opts.dialogType = \"prompt\";\n opts.theme = (opts.theme || cfg.theme || \"\");\n opts.callback = callback;\n\n if (typeof opts.input === \"undefined\") {\n opts.input = {\n value: {label: \"\"}\n };\n }\n if (typeof opts.btns === \"undefined\") {\n opts.btns = {\n ok: {label: cfg.lang[\"ok\"], theme: opts.theme},\n cancel: {label: cfg.lang[\"cancel\"]}\n };\n }\n open.call(this, opts, callback);\n\n return this;\n };\n\n /**\n * close the dialog\n * @method ax5dialog.close\n * @returns {ax5dialog}\n * @example\n * ```\n * myDialog.close();\n * ```\n */\n this.close = function (_option) {\n var opts, that;\n if (this.activeDialog) {\n opts = self.dialogConfig;\n this.activeDialog.addClass(\"destroy\");\n jQuery(window).unbind(\"keydown.ax5dialog\");\n jQuery(window).unbind(\"resize.ax5dialog\");\n\n setTimeout((function () {\n if (this.activeDialog) {\n this.activeDialog.remove();\n this.activeDialog = null;\n }\n\n that = {\n self: this,\n state: \"close\",\n dialogId: opts.id\n };\n\n if (opts.callback && (!_option || !_option.doNotCallback)) {\n opts.callback.call(that);\n }\n\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n opts = null;\n that = null;\n }).bind(this), cfg.animateTime);\n }\n return this;\n };\n\n // 클래스 생성자\n this.main = (function () {\n\n UI.dialog_instance = UI.dialog_instance || [];\n UI.dialog_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }).apply(this, arguments);\n };\n return ax5dialog;\n })());\n DIALOG = ax5.ui.dialog;\n})();\n","// ax5.ui.dialog.tmpl\n(function () {\n\n var DIALOG = ax5.ui.dialog;\n\n var dialogDisplay = function(columnKeys) {\n return ` \n \n \n
\n
{{{msg}}}
\n \n {{#input}}\n
\n {{#@each}}\n
\n {{/@each}}\n
\n {{/input}}\n \n
\n
\n
\n `;\n };\n\n DIALOG.tmpl = {\n \"dialogDisplay\": dialogDisplay,\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(DIALOG.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n\n})();","// ax5.ui.mask\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var MASK;\n\n UI.addClass({\n className: \"mask\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5mask\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var customMask = function customMask() {\n * var cTmpl = '' +\n * '' +\n * '
' +\n * '
' +\n * ' {{{body}}}' +\n * '
' +\n * '
';\n * return cTmpl;\n * };\n * ax5.ui.mask.tmpl.customMask = customMask;\n *\n * var mask = new ax5.ui.mask();\n *\n * mask.open({\n * templateName: 'customMask',\n * content: 'custom MASK on target',\n * target: $(\"#user-content\").get(0),\n * onClick: function(){\n * console.log(this);\n * }\n * });\n * ```\n */\n var ax5mask = function () {\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: '',\n target: jQuery(document.body).get(0),\n animateTime: 250\n };\n this.maskContent = '';\n this.status = \"off\";\n\n cfg = this.config;\n\n var\n onStateChanged = function (opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n opts = null;\n that = null;\n return true;\n },\n getBodyTmpl = function (data) {\n if (typeof data.templateName === \"undefined\") data.templateName = \"defaultMask\";\n return MASK.tmpl.get.call(this, data.templateName, data);\n },\n setBody = function (content) {\n this.maskContent = content;\n };\n\n /**\n * Preferences of Mask UI\n * @method ax5mask.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5mask}\n * @example\n * ```\n * setConfig({\n * target : {Element|AX5 nodelist}, // 마스크 처리할 대상\n * content : {String}, // 마스크안에 들어가는 내용물\n * onStateChanged: function(){} // 마스크 상태변경 시 호출되는 함수 this.type으로 예외처리 가능\n * }\n * ```\n */\n this.init = function () {\n // after setConfig();\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n if (this.config.content) setBody.call(this, this.config.content);\n };\n\n /**\n * open mask\n * target 을 주지 않으면 기본적으로 body 에 마스크가 적용되고 원하는 타겟을 지정해서 마스크를 씌울 수 있습니다.\n * 기본 정의된 마스크 외에 사용자가 템플릿을 정의해서 마스크를 사용 가능합니다.\n * @method ax5mask.open\n * @param {Object} config\n * @param {String} config\n * @returns {ax5mask}\n * @example\n * ```js\n * my_mask.open({\n * target: document.body,\n * content: \"Loading..
\",\n * onStateChanged: function () {\n *\n * }\n * });\n *\n * my_mask.open({\n * target: $(\"#mask-target\").get(0), // dom Element\n * content: \"Loading..
\",\n * onStateChanged: function () {\n *\n * }\n * });\n *\n *\n * var customMask = function customMask() {\n * var cTmpl = '' +\n * '' +\n * '
' +\n * '
' +\n * ' {{{body}}}' +\n * '
' +\n * '
';\n * return cTmpl;\n * };\n * ax5.ui.mask.tmpl.customMask = customMask;\n *\n * my_mask.open({\n * target: $(\"#mask-target\").get(0), // dom Element\n * content: \"Loading..
\",\n * \n * onStateChanged: function () {\n *\n * }\n * });\n * ```\n */\n this.open = function (options) {\n\n if (this.status === \"on\") this.close();\n if (options && options.content) setBody.call(this, options.content);\n if (options && typeof options.templateName === \"undefined\") options.templateName = \"defaultMask\";\n self.maskConfig = {};\n\n jQuery.extend(true, self.maskConfig, this.config, options);\n\n var _cfg = self.maskConfig,\n target = _cfg.target,\n $target = jQuery(target),\n maskId = 'ax-mask-' + ax5.getGuid(),\n $mask,\n css = {},\n that = {},\n templateName = _cfg.templateName,\n /*\n bodyTmpl = getBodyTmpl(),\n body = ax5.mustache.render(bodyTmpl, {\n theme: _cfg.theme,\n maskId: maskId,\n body: this.maskContent\n });\n */\n body = getBodyTmpl({\n theme: _cfg.theme,\n maskId: maskId,\n body: this.maskContent,\n templateName: templateName\n });\n\n jQuery(document.body).append(body);\n\n\n // 마스크의 타겟이 html body 가 아니라면\n if (target && target !== jQuery(document.body).get(0)) {\n css = {\n position: _cfg.position || \"absolute\",\n left: $target.offset().left,\n top: $target.offset().top,\n width: $target.outerWidth(),\n height: $target.outerHeight()\n };\n\n if (typeof self.maskConfig.zIndex !== \"undefined\") {\n css[\"z-index\"] = self.maskConfig.zIndex;\n }\n $target.addClass(\"ax-masking\");\n\n // 마스크의 타겟이 html body가 아닌경우 window resize 이벤트를 추적하여 엘리먼트 마스크의 CSS 속성 변경\n jQuery(window).bind(\"resize.ax5mask-\" + this.instanceId, (function (_$target) {\n this.align();\n }).bind(this));\n }\n\n this.$mask = $mask = jQuery(\"#\" + maskId);\n this.$target = $target;\n this.status = \"on\";\n $mask.css(css);\n\n if (_cfg.onClick) {\n $mask.on(\"click\", function (e) {\n that = {\n self: self,\n state: \"open\",\n type: \"click\"\n };\n self.maskConfig.onClick.call(that, that);\n });\n }\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"open\"\n });\n\n options = null;\n _cfg = null;\n target = null;\n $target = null;\n maskId = null;\n $mask = null;\n css = null;\n that = null;\n templateName = null;\n body = null;\n\n return this;\n };\n\n /**\n * close mask\n * @method ax5mask.close\n * @param {Number} [_delay=0]\n * @returns {ax5mask}\n * @example\n * ```\n * my_mask.close();\n * ```\n */\n this.close = function (_delay) {\n if (this.$mask) {\n let _close = function () {\n this.status = \"off\";\n this.$mask.remove();\n this.$target.removeClass(\"ax-masking\");\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"close\"\n });\n\n jQuery(window).unbind(\"resize.ax5mask-\" + this.instanceId);\n };\n\n if (_delay) {\n setTimeout((function () {\n _close.call(this);\n }).bind(this), _delay);\n } else {\n _close.call(this);\n }\n }\n return this;\n };\n\n /**\n * @method ax5mask.fadeOut\n * @returns {ax5mask}\n */\n this.fadeOut = function () {\n if (this.$mask) {\n let _close = function () {\n this.status = \"off\";\n this.$mask.remove();\n this.$target.removeClass(\"ax-masking\");\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"close\"\n });\n\n jQuery(window).unbind(\"resize.ax5mask-\" + this.instanceId);\n };\n\n\n this.$mask.addClass(\"fade-out\");\n setTimeout((function () {\n _close.call(this);\n }).bind(this), cfg.animateTime);\n }\n return this;\n };\n\n /**\n * @method ax5mask.align\n * @returns {ax5mask}\n */\n this.align = function () {\n if (this.maskConfig && this.maskConfig.target && this.maskConfig.target !== jQuery(document.body).get(0)) {\n try {\n var css = {\n position: this.maskConfig.position || \"absolute\",\n left: this.$target.offset().left,\n top: this.$target.offset().top,\n width: this.$target.outerWidth(),\n height: this.$target.outerHeight()\n };\n this.$mask.css(css);\n } catch (e) {\n\n }\n }\n return this;\n };\n\n\n this.pullRequest = function () {\n console.log(\"test pullRequest01\");\n console.log(\"test pullRequest02\");\n };\n\n // 클래스 생성자\n this.main = (function () {\n\n UI.mask_instance = UI.mask_instance || [];\n UI.mask_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }).apply(this, arguments);\n };\n return ax5mask;\n })());\n MASK = ax5.ui.mask;\n})();","// ax5.ui.mask.tmpl\n(function () {\n\n var MASK = ax5.ui.mask;\n\n var defaultMask = function(columnKeys) {\n return `\n \n `;\n };\n\n MASK.tmpl = {\n \"defaultMask\": defaultMask,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(MASK.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n\n})();","// ax5.ui.toast\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var TOAST;\n\n UI.addClass({\n className: \"toast\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5toast\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```\n * ```js\n * var toast = new ax5.ui.toast();\n * toast.setConfig({\n * icon: '',\n * containerPosition: \"bottom-right\",\n * closeIcon: ''\n * });\n *\n * toast.onStateChanged = function(){\n * console.log(this);\n * };\n *\n * toast.push({\n * icon: '',\n * msg:\"999999\"\n * });\n *\n * toast.push({\n * theme: theme,\n * msg: 'toast message'\n * });\n * ```\n */\n var ax5toast = function () {\n var\n self = this,\n cfg,\n toastSeq = 0, toastSeqClear = null;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchstart\" : \"click\"),\n theme: 'default',\n width: 300,\n icon: '',\n closeIcon: '',\n msg: '',\n lang: {\n \"ok\": \"ok\", \"cancel\": \"cancel\"\n },\n displayTime: 3000,\n animateTime: 250,\n containerPosition: \"bottom-left\"\n };\n this.toastContainer = null;\n this.queue = [];\n\n cfg = this.config;\n\n var\n onStateChanged = function (opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n opts = null;\n that = null;\n return true;\n },\n /**\n * @method ax5toast.getContent\n * @param {String} toastId\n * @param {Object} opts\n * @returns toastDisplay\n * @example\n * ```js\n * ax5toast.getContent('ax5-toast-3-1', opts);\n * ```\n */\n getContent = function (toastId, opts) {\n\n var\n data = {\n toastId: toastId,\n theme: opts.theme,\n icon: opts.icon,\n msg: (opts.msg || \"\").replace(/\\n/g, \"
\"),\n btns: opts.btns,\n closeIcon: opts.closeIcon\n };\n\n try {\n return TOAST.tmpl.get.call(this, \"toastDisplay\", data);\n }\n finally {\n toastId = null;\n data = null;\n }\n },\n /**\n * @method ax5toast.open\n * @param opts\n * @param callBack\n * @returns {ax5toast}\n */\n open = function (opts, callBack) {\n if (toastSeqClear) clearTimeout(toastSeqClear);\n\n var\n toastBox,\n box = {\n width: opts.width\n };\n\n opts.id = 'ax5-toast-' + self.containerId + '-' + (++toastSeq);\n if (jQuery('#' + opts.id).get(0)) return this;\n\n if (U.left(cfg.containerPosition, '-') == 'bottom') {\n this.toastContainer.append(getContent(opts.id, opts));\n }\n else {\n this.toastContainer.prepend(getContent(opts.id, opts));\n }\n\n toastBox = jQuery('#' + opts.id);\n toastBox.css({width: box.width});\n opts.toastBox = toastBox;\n this.queue.push(opts);\n\n onStateChanged.call(this, opts, {\n self: this,\n state: \"open\",\n toastId: opts.id\n });\n\n if (opts.toastType === \"push\") {\n // 자동 제거 타이머 시작\n setTimeout((function () {\n this.close(opts, callBack);\n }).bind(this), cfg.displayTime);\n\n toastBox.find(\"[data-ax-toast-btn]\").on(cfg.clickEventName, (function (e) {\n btnOnClick.call(this, e || window.event, opts, toastBox, callBack);\n }).bind(this));\n }\n else if (opts.toastType === \"confirm\") {\n toastBox.find(\"[data-ax-toast-btn]\").on(cfg.clickEventName, (function (e) {\n btnOnClick.call(this, e || window.event, opts, toastBox, callBack);\n }).bind(this));\n }\n\n box = null;\n },\n btnOnClick = function (e, opts, toastBox, callBack, target, k) {\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-ax-toast-btn\")) {\n return true;\n }\n });\n\n if (target) {\n k = target.getAttribute(\"data-ax-toast-btn\");\n\n var that = {\n key: k, value: (opts.btns) ? opts.btns[k] : k,\n toastId: opts.id,\n btn_target: target\n };\n\n if (opts.btns && opts.btns[k].onClick) {\n opts.btns[k].onClick.call(that, k);\n }\n else if (opts.toastType === \"push\") {\n if (callBack) callBack.call(that, k);\n this.close(opts, callBack);\n }\n else if (opts.toastType === \"confirm\") {\n if (callBack) callBack.call(that, k);\n this.close(opts, callBack);\n }\n }\n\n e = null;\n opts = null;\n toastBox = null;\n callBack = null;\n target = null;\n k = null;\n };\n\n /**\n * Preferences of toast UI\n * @method ax5toast.set_config\n * @param {Object} config - 클래스 속성값\n * @returns {ax5toast}\n * @example\n * ```\n * ```\n */\n //== class body start\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n // after set_config();\n self.containerId = ax5.getGuid();\n var styles = [];\n if (cfg.zIndex) {\n styles.push(\"z-index:\" + cfg.zIndex);\n }\n jQuery(document.body).append('');\n this.toastContainer = jQuery('[data-toast-container=\"' + self.containerId + '\"]');\n };\n\n /**\n * @method ax5toast.push\n * @param opts\n * @param callBack\n * @returns {ax5toast}\n */\n this.push = function (opts, callBack) {\n if (!self.containerId) {\n this.init();\n }\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n }\n }\n opts.toastType = \"push\";\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n\n open.call(this, opts, callBack);\n\n opts = null;\n callBack = null;\n return this;\n };\n\n /**\n * @method ax5toast.confirm\n * @param opts\n * @param callBack\n * @returns {ax5toast}\n */\n this.confirm = function (opts, callBack) {\n if (!self.containerId) {\n this.init();\n }\n if (U.isString(opts)) {\n opts = {\n title: cfg.title,\n msg: opts\n }\n }\n opts.toastType = \"confirm\";\n\n self.dialogConfig = {};\n jQuery.extend(true, self.dialogConfig, cfg, opts);\n opts = self.dialogConfig;\n\n if (typeof opts.btns === \"undefined\") {\n opts.btns = {\n ok: {label: cfg.lang[\"ok\"], theme: opts.theme}\n };\n }\n open.call(this, opts, callBack);\n\n opts = null;\n callBack = null;\n return this;\n };\n\n /**\n * close the toast\n * @method ax5toast.close\n * @returns {ax5toast}\n * @example\n * ```\n * my_toast.close();\n * ```\n */\n this.close = function (opts, callBack) {\n if (typeof opts === \"undefined\") {\n opts = U.last(this.queue);\n }\n\n var toastBox = opts.toastBox;\n toastBox.addClass((opts.toastType == \"push\") ? \"removed\" : \"destroy\");\n this.queue = U.filter(this.queue, function () {\n return opts.id != this.id;\n });\n setTimeout((function () {\n var that = {\n toastId: opts.id\n };\n\n toastBox.remove();\n if (callBack) callBack.call(that);\n\n that = {\n self: this,\n state: \"close\",\n toastId: opts.id\n };\n onStateChanged.call(this, opts, that);\n\n // 3초후에도 아무 일이 없다면 완전히 제거\n if (this.queue.length === 0) {\n if (toastSeqClear) clearTimeout(toastSeqClear);\n toastSeqClear = setTimeout((function () {\n /// console.log(\"try clear seq\");\n if (this.queue.length === 0) toastSeq = 0;\n }).bind(this), 3000);\n }\n\n that = null;\n opts = null;\n callBack = null;\n toastBox = null;\n }).bind(this), cfg.animateTime);\n\n return this;\n };\n\n // 클래스 생성자\n this.main = (function () {\n\n UI.toast_instance = UI.toast_instance || [];\n UI.toast_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }).apply(this, arguments);\n };\n return ax5toast;\n })());\n TOAST = ax5.ui.toast;\n})();","// ax5.ui.toast.tmpl\n(function () {\n\n var TOAST = ax5.ui.toast;\n\n var toastDisplay = function(columnKeys) {\n return `\n \n {{#icon}}\n
{{{.}}}
\n {{/icon}}\n
{{{msg}}}
\n {{#btns}}\n
\n {{/btns}}\n {{^btns}}\n
{{{closeIcon}}}\n {{/btns}}\n
\n
`;\n };\n\n TOAST.tmpl = {\n \"toastDisplay\": toastDisplay,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(TOAST.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n\n})();","// ax5.ui.modal\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var MODAL;\n\n UI.addClass({\n className: \"modal\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5modal\n * @alias ax5.ui.modal\n * @author tom@axisj.com\n * @example\n * ```js\n * var modal = new ax5.ui.modal({\n * iframeLoadingMsg: '',\n * header: {\n * title: \"MODAL TITLE\",\n * btns: {\n * minimize: {\n * label: '', onClick: function () {\n * modal.minimize();\n * }\n * },\n * maximize: {\n * label: '', onClick: function () {\n * modal.maximize();\n * }\n * },\n * close: {\n * label: '', onClick: function () {\n * modal.close();\n * }\n * }\n * }\n * }\n * });\n *\n * modal.open({\n * width: 800,\n * height: 600,\n * fullScreen: function(){\n * return ($(window).width() < 600);\n * },\n * iframe: {\n * method: \"get\",\n * url: \"http://chequer-app:2017/html/login.html\",\n * param: \"callback=modalCallback\"\n * }\n * });\n * ```\n */\n var ax5modal = function () {\n let self = this,\n cfg,\n ENM = {\n \"mousedown\": (ax5.info.supportTouch) ? \"touchstart\" : \"mousedown\",\n \"mousemove\": (ax5.info.supportTouch) ? \"touchmove\" : \"mousemove\",\n \"mouseup\": (ax5.info.supportTouch) ? \"touchend\" : \"mouseup\"\n },\n getMousePosition = function (e) {\n let mouseObj = e;\n if ('changedTouches' in e) {\n mouseObj = e.changedTouches[0];\n }\n return {\n clientX: mouseObj.clientX,\n clientY: mouseObj.clientY\n }\n };\n\n this.instanceId = ax5.getGuid();\n this.config = {\n id: 'ax5-modal-' + this.instanceId,\n position: {\n left: \"center\",\n top: \"middle\",\n margin: 10\n },\n minimizePosition: \"bottom-right\",\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchstart\" : \"click\"),\n theme: 'default',\n width: 300,\n height: 400,\n closeToEsc: true,\n disableDrag: false,\n animateTime: 250\n };\n this.activeModal = null;\n this.watingModal = false;\n this.$ = {}; // UI inside of the jQuery object store\n\n cfg = this.config; // extended config copy cfg\n\n let onStateChanged = function (opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n return true;\n },\n getContent = function (modalId, opts) {\n let data = {\n modalId: modalId,\n theme: opts.theme,\n header: opts.header,\n fullScreen: (opts.fullScreen ? \"fullscreen\" : \"\"),\n styles: \"\",\n iframe: opts.iframe,\n iframeLoadingMsg: opts.iframeLoadingMsg\n };\n\n if (opts.zIndex) {\n data.styles += \"z-index:\" + opts.zIndex + \";\";\n }\n if (opts.absolute) {\n data.styles += \"position:absolute;\";\n }\n\n if (data.iframe && typeof data.iframe.param === \"string\") {\n data.iframe.param = ax5.util.param(data.iframe.param);\n }\n\n return MODAL.tmpl.get.call(this, \"content\", data, {});\n },\n open = function (opts, callback) {\n let that;\n jQuery(document.body).append(getContent.call(this, opts.id, opts));\n\n this.activeModal = jQuery('#' + opts.id);\n\n // 파트수집\n this.$ = {\n \"root\": this.activeModal,\n \"header\": this.activeModal.find('[data-modal-els=\"header\"]'),\n \"body\": this.activeModal.find('[data-modal-els=\"body\"]')\n };\n\n if (opts.iframe) {\n this.$[\"iframe-wrap\"] = this.activeModal.find('[data-modal-els=\"iframe-wrap\"]');\n this.$[\"iframe\"] = this.activeModal.find('[data-modal-els=\"iframe\"]');\n this.$[\"iframe-form\"] = this.activeModal.find('[data-modal-els=\"iframe-form\"]');\n this.$[\"iframe-loading\"] = this.activeModal.find('[data-modal-els=\"iframe-loading\"]');\n }\n\n //- position 정렬\n this.align();\n\n that = {\n self: this,\n id: opts.id,\n theme: opts.theme,\n width: opts.width,\n height: opts.height,\n state: \"open\",\n $: this.$\n };\n\n if (opts.iframe) {\n this.$[\"iframe-wrap\"].css({height: opts.height});\n this.$[\"iframe\"].css({height: opts.height});\n\n // iframe content load\n this.$[\"iframe-form\"].attr({\"method\": opts.iframe.method});\n this.$[\"iframe-form\"].attr({\"target\": opts.id + \"-frame\"});\n this.$[\"iframe-form\"].attr({\"action\": opts.iframe.url});\n this.$[\"iframe\"].on(\"load\", (function () {\n that.state = \"load\";\n if (opts.iframeLoadingMsg) {\n this.$[\"iframe-loading\"].hide();\n }\n onStateChanged.call(this, opts, that);\n }).bind(this));\n if (!opts.iframeLoadingMsg) {\n this.$[\"iframe\"].show();\n }\n this.$[\"iframe-form\"].submit();\n }\n\n if (callback) callback.call(that);\n\n if (!this.watingModal) {\n onStateChanged.call(this, opts, that);\n }\n\n // bind key event\n if (opts.closeToEsc) {\n jQuery(window).bind(\"keydown.ax-modal\", (function (e) {\n onkeyup.call(this, e || window.event);\n }).bind(this));\n }\n jQuery(window).bind(\"resize.ax-modal\", (function (e) {\n this.align(null, e || window.event);\n }).bind(this));\n\n this.activeModal.find(\"[data-modal-header-btn]\").on(cfg.clickEventName, (function (e) {\n btnOnClick.call(this, e || window.event, opts);\n }).bind(this));\n\n this.$.header\n .bind(ENM[\"mousedown\"], function (e) {\n if (opts.isFullScreen) return false;\n\n /// 이벤트 필터링 추가 : 버튼엘리먼트로 부터 발생된 이벤트이면 moveModal 시작하지 않도록 필터링\n let isButton = U.findParentNode(e.target, function (_target) {\n if (_target.getAttribute(\"data-modal-header-btn\")) {\n return true;\n }\n });\n\n if (!isButton && opts.disableDrag != true) {\n self.mousePosition = getMousePosition(e);\n moveModal.on.call(self);\n }\n })\n .bind(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n },\n btnOnClick = function (e, opts, callback, target, k) {\n let that;\n if (e.srcElement) e.target = e.srcElement;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-modal-header-btn\")) {\n return true;\n }\n });\n\n if (target) {\n k = target.getAttribute(\"data-modal-header-btn\");\n\n that = {\n self: this,\n key: k, value: opts.header.btns[k],\n dialogId: opts.id,\n btnTarget: target\n };\n\n if (opts.header.btns[k].onClick) {\n opts.header.btns[k].onClick.call(that, k);\n }\n }\n\n that = null;\n opts = null;\n callback = null;\n target = null;\n k = null;\n },\n onkeyup = function (e) {\n if (e.keyCode == ax5.info.eventKeys.ESC) {\n this.close();\n }\n },\n alignProcessor = {\n \"top-left\": function () {\n this.align({left: \"left\", top: \"top\"});\n },\n \"top-right\": function () {\n this.align({left: \"right\", top: \"top\"});\n },\n \"bottom-left\": function () {\n this.align({left: \"left\", top: \"bottom\"});\n },\n \"bottom-right\": function () {\n this.align({left: \"right\", top: \"bottom\"});\n },\n \"center-middle\": function () {\n this.align({left: \"center\", top: \"middle\"});\n }\n },\n moveModal = {\n \"on\": function () {\n let modalZIndex = this.activeModal.css(\"z-index\"),\n modalOffset = this.activeModal.position(),\n modalBox = {\n width: this.activeModal.outerWidth(), height: this.activeModal.outerHeight()\n },\n windowBox = {\n width: jQuery(window).width(),\n height: jQuery(window).height()\n },\n getResizerPosition = function (e) {\n self.__dx = e.clientX - self.mousePosition.clientX;\n self.__dy = e.clientY - self.mousePosition.clientY;\n\n var minX = 0;\n var maxX = windowBox.width - modalBox.width;\n var minY = 0;\n var maxY = windowBox.height - modalBox.height;\n\n if (minX > modalOffset.left + self.__dx) {\n self.__dx = -modalOffset.left;\n }\n else if (maxX < modalOffset.left + self.__dx) {\n self.__dx = (maxX) - modalOffset.left;\n }\n\n if (minY > modalOffset.top + self.__dy) {\n self.__dy = -modalOffset.top;\n }\n else if (maxY < modalOffset.top + self.__dy) {\n self.__dy = (maxY) - modalOffset.top;\n }\n\n return {\n left: modalOffset.left + self.__dx + $(document).scrollLeft(),\n top: modalOffset.top + self.__dy + $(document).scrollTop()\n };\n };\n\n self.__dx = 0; // 변화량 X\n self.__dy = 0; // 변화량 Y\n\n if (!self.resizer) {\n // self.resizerBg : body 가 window보다 작을 때 문제 해결을 위한 DIV\n self.resizerBg = jQuery('');\n self.resizer = jQuery('');\n self.resizerBg.css({zIndex: modalZIndex});\n self.resizer.css({\n left: modalOffset.left,\n top: modalOffset.top,\n width: modalBox.width,\n height: modalBox.height,\n zIndex: modalZIndex + 1\n });\n jQuery(document.body)\n .append(self.resizerBg)\n .append(self.resizer);\n self.activeModal.addClass(\"draged\");\n }\n\n jQuery(document.body)\n .bind(ENM[\"mousemove\"] + \".ax5modal-\" + cfg.id, function (e) {\n self.resizer.css(getResizerPosition(e));\n })\n .bind(ENM[\"mouseup\"] + \".ax5layout-\" + this.instanceId, function (e) {\n moveModal.off.call(self);\n })\n .bind(\"mouseleave.ax5layout-\" + this.instanceId, function (e) {\n moveModal.off.call(self);\n });\n\n jQuery(document.body)\n .attr('unselectable', 'on')\n .css('user-select', 'none')\n .on('selectstart', false);\n },\n \"off\": function () {\n let setModalPosition = function () {\n let box = this.activeModal.offset();\n box.left += this.__dx - $(document).scrollLeft();\n box.top += this.__dy - $(document).scrollTop();\n this.activeModal.css(box);\n };\n\n if (this.resizer) {\n this.activeModal.removeClass(\"draged\");\n this.resizer.remove();\n this.resizer = null;\n this.resizerBg.remove();\n this.resizerBg = null;\n setModalPosition.call(this);\n //this.align();\n }\n\n jQuery(document.body)\n .unbind(ENM[\"mousemove\"] + \".ax5modal-\" + cfg.id)\n .unbind(ENM[\"mouseup\"] + \".ax5modal-\" + cfg.id)\n .unbind(\"mouseleave.ax5modal-\" + cfg.id);\n\n jQuery(document.body)\n .removeAttr('unselectable')\n .css('user-select', 'auto')\n .off('selectstart');\n\n }\n };\n\n /// private end\n\n /**\n * Preferences of modal UI\n * @method ax5modal.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Number} [config.zIndex]\n * @param {Boolean} [config.absolute=false]\n * @returns {ax5modal}\n * @example\n * ```\n * ```\n */\n //== class body start\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n };\n\n /**\n * open the modal\n * @method ax5modal.open\n * @returns {ax5modal}\n * @example\n * ```\n * my_modal.open();\n * ```\n */\n this.open = function (opts, callback, tryCount) {\n if (typeof tryCount === \"undefined\") tryCount = 0;\n if (!this.activeModal) {\n opts = self.modalConfig = jQuery.extend(true, {}, cfg, opts);\n open.call(this, opts, callback);\n this.watingModal = false;\n }\n else if (tryCount < 3) {\n // 3번까지 재 시도\n this.watingModal = true;\n setTimeout((function () {\n this.open(opts, callback, tryCount + 1);\n }).bind(this), cfg.animateTime);\n }\n return this;\n };\n\n /**\n * close the modal\n * @method ax5modal.close\n * @returns {ax5modal}\n * @example\n * ```\n * my_modal.close();\n * ```\n */\n this.close = function (opts) {\n if (this.activeModal) {\n opts = self.modalConfig;\n this.activeModal.addClass(\"destroy\");\n jQuery(window).unbind(\"keydown.ax-modal\");\n jQuery(window).unbind(\"resize.ax-modal\");\n\n setTimeout((function () {\n if (this.activeModal) {\n\n // 프레임 제거\n if (opts.iframe) {\n var $iframe = this.$[\"iframe\"]; // iframe jQuery Object\n if ($iframe) {\n var iframeObject = $iframe.get(0),\n idoc = (iframeObject.contentDocument) ? iframeObject.contentDocument : iframeObject.contentWindow.document;\n\n try {\n $(idoc.body).children().each(function () {\n $(this).remove();\n });\n } catch (e) {\n\n }\n idoc.innerHTML = \"\";\n $iframe\n .attr('src', 'about:blank')\n .remove();\n\n // force garbarge collection for IE only\n window.CollectGarbage && window.CollectGarbage();\n }\n }\n\n this.activeModal.remove();\n this.activeModal = null;\n }\n // 모달 오픈 대기중이면 닫기 상태 전달 안함.\n if (!this.watingModal) {\n onStateChanged.call(this, opts, {\n self: this,\n state: \"close\"\n });\n }\n }).bind(this), cfg.animateTime);\n }\n\n this.minimized = false; // hoksi\n\n return this;\n };\n\n /**\n * @method ax5modal.minimize\n * @returns {ax5modal}\n */\n this.minimize = (function () {\n\n return function (minimizePosition) {\n\n if (this.minimized !== true) {\n\n var opts = self.modalConfig;\n if (typeof minimizePosition === \"undefined\") minimizePosition = cfg.minimizePosition;\n\n this.minimized = true;\n this.$.body.hide();\n self.modalConfig.originalHeight = opts.height;\n self.modalConfig.height = 0;\n alignProcessor[minimizePosition].call(this);\n\n onStateChanged.call(this, opts, {\n self: this,\n state: \"minimize\"\n });\n }\n\n return this;\n };\n })();\n\n /**\n * @method ax5modal.maximize\n * @returns {ax5modal}\n */\n this.maximize = function () {\n var opts = self.modalConfig;\n if (this.minimized) {\n this.minimized = false;\n this.$.body.show();\n self.modalConfig.height = self.modalConfig.originalHeight;\n self.modalConfig.originalHeight = undefined;\n\n this.align({left: \"center\", top: \"middle\"});\n onStateChanged.call(this, opts, {\n self: this,\n state: \"restore\"\n });\n }\n return this;\n };\n\n /**\n * setCSS\n * @method ax5modal.css\n * @param {Object} css -\n * @returns {ax5modal}\n */\n this.css = function (css) {\n if (this.activeModal && !self.fullScreen) {\n this.activeModal.css(css);\n if (css.width) {\n self.modalConfig.width = this.activeModal.width();\n }\n if (css.height) {\n self.modalConfig.height = this.activeModal.height();\n if (this.$[\"iframe\"]) {\n this.$[\"iframe-wrap\"].css({height: self.modalConfig.height});\n this.$[\"iframe\"].css({height: self.modalConfig.height});\n }\n }\n }\n return this;\n };\n\n /**\n * @method ax5modal.setModalConfig\n * @param _config\n * @returns {ax5.ui.ax5modal}\n */\n this.setModalConfig = function (_config) {\n self.modalConfig = jQuery.extend({}, self.modalConfig, _config);\n this.align();\n return this;\n };\n\n /**\n * @method ax5modal.align\n * @param position\n * @param e\n * @returns {ax5modal}\n */\n this.align = (function () {\n\n return function (position, e) {\n if (!this.activeModal) return this;\n\n var opts = self.modalConfig,\n box = {\n width: opts.width,\n height: opts.height\n };\n\n var fullScreen = opts.isFullScreen = (function (_fullScreen) {\n if (typeof _fullScreen === \"undefined\") {\n return false;\n } else if (U.isFunction(_fullScreen)) {\n return _fullScreen();\n }\n })(opts.fullScreen);\n\n if (fullScreen) {\n if (opts.header) this.$.header.show();\n box.width = jQuery(window).width();\n box.height = opts.height;\n box.left = 0;\n box.top = 0;\n }\n else {\n if (opts.header) this.$.header.show();\n if (position) {\n jQuery.extend(true, opts.position, position);\n }\n\n if (opts.header) {\n opts.headerHeight = this.$.header.outerHeight();\n box.height += opts.headerHeight;\n } else {\n opts.headerHeight = 0;\n }\n\n //- position 정렬\n if (opts.position.left == \"left\") {\n box.left = (opts.position.margin || 0);\n }\n else if (opts.position.left == \"right\") {\n // window.innerWidth;\n box.left = jQuery(window).width() - box.width - (opts.position.margin || 0);\n }\n else if (opts.position.left == \"center\") {\n box.left = jQuery(window).width() / 2 - box.width / 2;\n }\n else {\n box.left = opts.position.left || 0;\n }\n\n if (opts.position.top == \"top\") {\n box.top = (opts.position.margin || 0);\n }\n else if (opts.position.top == \"bottom\") {\n box.top = jQuery(window).height() - box.height - (opts.position.margin || 0);\n }\n else if (opts.position.top == \"middle\") {\n box.top = jQuery(window).height() / 2 - box.height / 2;\n }\n else {\n box.top = opts.position.top || 0;\n }\n if (box.left < 0) box.left = 0;\n if (box.top < 0) box.top = 0;\n }\n\n this.activeModal.css(box);\n\n if (opts.iframe) {\n this.$[\"iframe-wrap\"].css({height: box.height - opts.headerHeight});\n this.$[\"iframe\"].css({height: box.height - opts.headerHeight});\n }\n return this;\n };\n })();\n\n // 클래스 생성자\n this.main = (function () {\n\n UI.modal_instance = UI.modal_instance || [];\n UI.modal_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n\n }).apply(this, arguments);\n };\n return ax5modal;\n })());\n\n MODAL = ax5.ui.modal;\n})();\n","// ax5.ui.modal.tmpl\n(function () {\n var MODAL = ax5.ui.modal;\n \n var content = function () {\n return ` \n \n {{#header}}\n \n {{/header}}\n
\n {{#iframe}}\n \n
\n
\n {{/iframe}}\n
\n
\n
\n `;\n };\n\n MODAL.tmpl = {\n \"content\" : content,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(MODAL.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();","// ax5.ui.calendar\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var CALENDAR;\n\n UI.addClass({\n className: \"calendar\",\n version: \"1.3.66\"\n }, (function () {\n\n /**\n * @class ax5calendar\n * @classdesc\n * @author tom@axisj.com\n * @logs\n * 2014-06-21 tom : 시작\n * @example\n * ```js\n * ax5.info.months = [\"1월\",\"2월\",\"3월\",\"4월\",\"5월\",\"6월\",\"7월\",\"8월\",\"9월\",\"10월\",\"11월\"];\n * ax5.info.weekNames = [\n * {label: \"일\"},\n * {label: \"월\"},\n * {label: \"화\"},\n * {label: \"수\"},\n * {label: \"목\"},\n * {label: \"금\"},\n * {label: \"토\"}\n * ];\n *\n * var myCalendar = new ax5.ui.calendar({\n * control: {\n * left: '≪',\n * yearTmpl: '%s',\n * monthTmpl: '%s',\n * right: '≫',\n * yearFirst: true\n * },\n *\n * dimensions: {\n * itemPadding: 1,\n * height: 200\n * },\n *\n * target: document.getElementById(\"calendar-target\"),\n * displayDate: (new Date()),\n * mode: \"day\",\n * selectMode: \"day\",\n *\n * marker: (function () {\n * var marker = {};\n * marker[_c_date(today, {'return': 'yyyy-MM-dd', 'add': {d: -1}})] = true;\n * marker[_c_date(today, {'return': 'yyyy-MM-dd', 'add': {d: 0}})] = true;\n * marker[_c_date(today, {'return': 'yyyy-MM-dd', 'add': {d: 1}})] = true;\n *\n\t * return marker;\n * })(),\n * onClick: function () {\n * console.log(myCalendar.getSelection());\n * },\n * onStateChanged: function () {\n * console.log(this);\n * }\n * , multipleSelect: 2\n * });\n * ```\n */\n var ax5calendar = function () {\n var\n self = this,\n cfg,\n selectableCount = 1\n ;\n\n this.instanceId = ax5.getGuid();\n this.target = null;\n this.selection = [];\n this.selectionMap = {};\n this.selectableMap = {};\n this.markerMap = {};\n this.printedDay = {\n start: \"\", end: \"\"\n };\n this.config = {\n clickEventName: \"click\",\n theme: 'default',\n startOfWeek: 0,\n mode: 'day', // day|month|year,\n dateFormat: 'yyyy-MM-dd',\n displayDate: (new Date()),\n animateTime: 100,\n dimensions: {\n controlHeight: '40',\n controlButtonWidth: '40',\n colHeadHeight: '30',\n itemPadding: 2\n },\n lang: {\n yearHeading: \"Choose the year\",\n monthHeading: \"Choose the month\",\n yearTmpl: \"%s\",\n months: ax5.info.months || ['JAN', 'FEB', 'MAR', 'APR', 'MAY', 'JUN', 'JUL', 'AUG', 'SEP', 'OCT', 'NOV', 'DEC'],\n dayTmpl: \"%s\"\n },\n multipleSelect: false,\n selectMode: 'day',\n defaultMarkerTheme: 'holiday',\n defaultPeriodTheme: 'period'\n };\n\n cfg = this.config;\n\n var\n onStateChanged = function (opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n that = null;\n },\n getFrame = function () {\n var\n data = jQuery.extend(true, {}, cfg, {\n controlCSS: {},\n controlButtonCSS: {}\n });\n\n data.controlButtonCSS[\"height\"] = data.controlCSS[\"height\"] = U.cssNumber(cfg.dimensions.controlHeight);\n data.controlButtonCSS[\"line-height\"] = data.controlCSS[\"line-height\"] = U.cssNumber(cfg.dimensions.controlHeight);\n data.controlButtonCSS[\"width\"] = U.cssNumber(cfg.dimensions.controlHeight);\n\n data.controlCSS = U.css(data.controlCSS);\n data.controlButtonCSS = U.css(data.controlButtonCSS);\n\n try {\n return CALENDAR.tmpl.get.call(this, \"frameTmpl\", data);\n }\n finally {\n data = null;\n }\n },\n setDisplay = function () {\n var\n myDate = U.date(cfg.displayDate),\n yy = \"\",\n mm = \"\",\n yy1, yy2;\n\n if (cfg.control) {\n if (cfg.mode == \"day\" || cfg.mode == \"d\") {\n yy = (cfg.control.yearTmpl) ? cfg.control.yearTmpl.replace('%s', myDate.getFullYear()) : myDate.getFullYear();\n mm = (cfg.control.monthTmpl) ? cfg.control.monthTmpl.replace('%s', cfg.lang.months[myDate.getMonth()]) : cfg.lang.months[myDate.getMonth()];\n\n this.$[\"control-display\"].html((function () {\n if (cfg.control.yearFirst) {\n return '' + yy + '' +\n '' + mm + '';\n }\n else {\n return '' + mm + '' +\n '' + yy + '';\n }\n\n })());\n }\n else if (cfg.mode == \"month\" || cfg.mode == \"m\") {\n yy = (cfg.control.yearTmpl) ? cfg.control.yearTmpl.replace('%s', myDate.getFullYear()) : myDate.getFullYear();\n this.$[\"control-display\"].html('' + yy + '');\n }\n else if (cfg.mode == \"year\" || cfg.mode == \"y\") {\n yy1 = (cfg.control.yearTmpl) ? cfg.control.yearTmpl.replace('%s', myDate.getFullYear() - 10) : myDate.getFullYear() - 10;\n yy2 = (cfg.control.yearTmpl) ? cfg.control.yearTmpl.replace('%s', Number(myDate.getFullYear()) + 9) : Number(myDate.getFullYear()) + 9;\n this.$[\"control-display\"].html(yy1 + ' ~ ' + yy2);\n }\n\n this.$[\"control-display\"].find('[data-calendar-display]').on(cfg.clickEventName, (function (e) {\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-calendar-display\")) {\n return true;\n }\n }), mode;\n if (target) {\n mode = target.getAttribute(\"data-calendar-display\");\n this.changeMode(mode);\n }\n target = null;\n mode = null;\n }).bind(this));\n }\n\n myDate = null;\n yy = null;\n mm = null;\n yy1 = null;\n yy2 = null;\n return this;\n },\n printDay = function (nowDate) {\n var\n dotDate = U.date(nowDate),\n monthStratDate = new Date(dotDate.getFullYear(), dotDate.getMonth(), 1, 12),\n _today = cfg.displayDate,\n tableStartDate = (function () {\n var day = monthStratDate.getDay();\n if (day == 0) day = 7;\n day -= cfg.startOfWeek;\n\n try {\n return U.date(monthStratDate, {add: {d: -day}});\n }\n finally {\n day = null;\n }\n })(),\n loopDate,\n thisMonth = dotDate.getMonth(),\n itemStyles = {},\n i,\n k, _k,\n frameWidth = this.$[\"body\"].width(),\n frameHeight = Math.floor(frameWidth * (6 / 7)), // 1week = 7days, 1month = 6weeks\n data,\n tmpl;\n\n if (cfg.dimensions.height) {\n frameHeight = U.number(cfg.dimensions.height) - U.number(cfg.dimensions.colHeadHeight);\n }\n\n itemStyles['height'] = Math.floor(frameHeight / 6) - U.number(cfg.dimensions.itemPadding) * 2 + 'px';\n itemStyles['line-height'] = itemStyles['height'];\n itemStyles['padding'] = U.cssNumber(cfg.dimensions.itemPadding);\n\n data = {\n weekNames: [].concat(ax5.info.weekNames),\n list: []\n };\n\n if(cfg.startOfWeek) {\n data.weekNames = data.weekNames.concat(data.weekNames.slice(0, cfg.startOfWeek)).splice(cfg.startOfWeek);\n }\n\n data.weekNames.forEach(function (n) {\n n.colHeadHeight = U.cssNumber(cfg.dimensions.colHeadHeight);\n });\n\n loopDate = tableStartDate;\n i = 0;\n while (i < 6) {\n k = 0;\n while (k < 7) {\n _k = (7 + (k - cfg.startOfWeek)) % 7;\n var\n thisDate = '' + U.date(loopDate, {\"return\": cfg.dateFormat}),\n _date = {\n 'row': i,\n 'col': k,\n isStartOfWeek: (k == 0),\n thisDate: '' + thisDate,\n thisDataLabel: cfg.lang.dayTmpl.replace('%s', loopDate.getDate()),\n itemStyles: U.css(itemStyles),\n addClass: (function () {\n\n var classNames = \"\";\n\n if (cfg.selectable) {\n if (self.selectableMap[thisDate]) {\n classNames += ( loopDate.getMonth() == thisMonth ) ? \" live\" : \"\";\n }\n else {\n classNames += \" disable\";\n }\n }\n else {\n if(loopDate.getMonth() == thisMonth){\n if(thisDate == U.date(_today, {\"return\": \"yyyyMMdd\"})){\n classNames += \" focus\";\n }else{\n classNames += \" live\";\n }\n\n if(loopDate.getDay() == 0){\n classNames += \" sunday\";\n }\n if(loopDate.getDay() == 6){\n classNames += \" saturday\";\n }\n }\n }\n\n return classNames;\n })()\n + ' '\n + (function () {\n return (self.markerMap[thisDate]) ? self.markerMap[thisDate].theme || cfg.defaultMarkerTheme : '';\n })()\n + ' '\n + (function () {\n return (self.selectionMap[thisDate]) ? \"selected-day\" : '';\n })()\n };\n data.list.push(_date);\n\n k++;\n loopDate = U.date(loopDate, {add: {d: 1}});\n\n thisDate = null;\n _date = null;\n }\n i++;\n }\n tmpl = CALENDAR.tmpl.get.call(this, \"dayTmpl\", data);\n this.$[\"body\"].html(tmpl);\n this.$[\"body\"].find('[data-calendar-item-date]').on(cfg.clickEventName, function (e) {\n e = e || window.event;\n onclick.call(self, e, 'date');\n U.stopEvent(e);\n });\n\n this.printedDay = {\n start: tableStartDate, end: loopDate\n };\n\n onStateChanged.call(this, null, {\n self: this,\n action: \"printDay\",\n printedDay: this.printedDay\n });\n setDisplay.call(this);\n\n dotDate = null;\n monthStratDate = null;\n _today = null;\n tableStartDate = null;\n loopDate = null;\n thisMonth = null;\n itemStyles = null;\n i = null;\n k = null;\n frameWidth = null;\n frameHeight = null;\n data = null;\n tmpl = null;\n },\n printMonth = function (nowDate) {\n var\n dotDate = U.date(nowDate),\n nMonth = dotDate.getMonth(),\n itemStyles = {},\n i,\n k,\n m,\n tableStartMonth,\n frameWidth = this.$[\"body\"].width(),\n frameHeight = Math.floor(frameWidth * (6 / 7)),\n data,\n tmpl;\n\n if (cfg.dimensions.height) {\n frameHeight = U.number(cfg.dimensions.height) - U.number(cfg.dimensions.colHeadHeight);\n }\n\n itemStyles['height'] = Math.floor(frameHeight / 4) - U.number(cfg.dimensions.itemPadding) * 2 + 'px';\n itemStyles['line-height'] = itemStyles['height'];\n itemStyles['padding'] = U.cssNumber(cfg.dimensions.itemPadding);\n\n data = {\n colHeadHeight: U.cssNumber(cfg.dimensions.colHeadHeight),\n colHeadLabel: cfg.lang.monthHeading,\n list: []\n };\n\n tableStartMonth = 0;\n m = 0;\n i = 0;\n while (i < 4) {\n k = 0;\n while (k < 3) {\n var\n _month = {\n row: i,\n col: k,\n isStartOfRow: (k == 0),\n thisMonth: dotDate.getFullYear() + '-' + U.setDigit(m + 1, 2) + '-' + U.setDigit(dotDate.getDate(), 2),\n thisMonthLabel: cfg.lang.months[m],\n itemStyles: U.css(itemStyles),\n addClass: (function () {\n if (cfg.selectable) {\n return (self.selectableMap[m]) ? 'live' : 'disable';\n }\n else {\n return 'live';\n }\n })()\n + ' '\n + (function () {\n return ( m == nMonth ) ? \"focus\" : \"\";\n })()\n + ' '\n + (function () {\n return (self.markerMap[m]) ? self.markerMap[m].theme || cfg.defaultMarkerTheme : '';\n })()\n };\n data.list.push(_month);\n m++;\n k++;\n _month = null;\n }\n i++;\n }\n tmpl = CALENDAR.tmpl.get.call(this, \"monthTmpl\", data);\n this.$[\"body\"].html(tmpl);\n this.$[\"body\"].find('[data-calendar-item-month]').on(cfg.clickEventName, function (e) {\n e = e || window.event;\n onclick.call(self, e, 'month');\n U.stopEvent(e);\n });\n\n this.printedDay = {\n start: dotDate.getFullYear() + '-' + U.setDigit(tableStartMonth + 1, 2),\n end: dotDate.getFullYear() + '-' + U.setDigit(m, 2)\n };\n\n onStateChanged.call(this, null, {\n self: this,\n action: \"printMonth\",\n printedDay: this.printedDay\n });\n setDisplay.call(this);\n\n dotDate = null;\n nMonth = null;\n itemStyles = null;\n i = null;\n k = null;\n m = null;\n tableStartMonth = null;\n frameWidth = null;\n frameHeight = null;\n data = null;\n tmpl = null;\n },\n printYear = function (nowDate) {\n var\n dotDate = U.date(nowDate),\n nYear = dotDate.getFullYear(),\n itemStyles = {},\n i,\n k,\n y,\n tableStartYear,\n frameWidth = this.$[\"body\"].width(),\n frameHeight = Math.floor(frameWidth * (6 / 7)),\n data,\n tmpl;\n\n if (cfg.dimensions.height) {\n frameHeight = U.number(cfg.dimensions.height) - U.number(cfg.dimensions.colHeadHeight);\n }\n\n itemStyles['height'] = Math.floor(frameHeight / 5) - U.number(cfg.dimensions.itemPadding) * 2 + 'px';\n itemStyles['line-height'] = itemStyles['height'];\n itemStyles['padding'] = U.cssNumber(cfg.dimensions.itemPadding);\n\n data = {\n colHeadHeight: U.cssNumber(cfg.dimensions.colHeadHeight),\n colHeadLabel: cfg.lang.yearHeading,\n list: []\n };\n\n tableStartYear = nYear - 10;\n y = nYear - 10;\n i = 0;\n while (i < 5) {\n k = 0;\n while (k < 4) {\n var\n _year = {\n row: i,\n col: k,\n isStartOfRow: (k == 0),\n thisYear: y + '-' + U.setDigit(dotDate.getMonth() + 1, 2) + '-' + U.setDigit(dotDate.getDate(), 2),\n thisYearLabel: cfg.lang.yearTmpl.replace('%s', (y)),\n itemStyles: U.css(itemStyles),\n addClass: (function () {\n if (cfg.selectable) {\n return (self.selectableMap[y]) ? 'live' : 'disable';\n }\n else {\n return 'live';\n }\n })()\n + ' '\n + (function () {\n return ( y == nYear ) ? \"focus\" : \"\";\n })()\n + ' '\n + (function () {\n return (self.selectableMap[y]) ? self.selectableMap[y].theme || cfg.defaultMarkerTheme : '';\n })()\n };\n data.list.push(_year);\n y++;\n k++;\n _year = null;\n }\n i++;\n }\n tmpl = CALENDAR.tmpl.get.call(this, \"yearTmpl\", data);\n this.$[\"body\"].html(tmpl);\n this.$[\"body\"].find('[data-calendar-item-year]').on(cfg.clickEventName, function (e) {\n e = (e || window.event);\n onclick.call(this, e, 'year');\n U.stopEvent(e);\n });\n\n this.printedDay = {\n start: tableStartYear, end: y - 1\n };\n\n onStateChanged.call(this, null, {\n self: this,\n action: \"printYear\",\n printedDay: this.printedDay\n });\n setDisplay.call(this);\n\n dotDate = null;\n nYear = null;\n itemStyles = null;\n i = null;\n k = null;\n y = null;\n tableStartYear = null;\n frameWidth = null;\n frameHeight = null;\n data = null;\n tmpl = null;\n },\n onclick = function (e, mode, target, value) {\n var\n removed,\n dt,\n selectable;\n\n mode = mode || \"date\";\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-calendar-item-\" + mode)) {\n return true;\n }\n });\n if (target) {\n value = target.getAttribute(\"data-calendar-item-\" + mode);\n\n dt = U.date(value, {\"return\": cfg.dateFormat});\n selectable = true;\n selectableCount = (cfg.multipleSelect) ? (U.isNumber(cfg.multipleSelect)) ? cfg.multipleSelect : 2 : 1;\n\n if (cfg.selectable) {\n if (!self.selectableMap[dt]) selectable = false;\n }\n\n if (mode == \"date\") {\n if (selectable) {\n\n if (self.selection.length >= selectableCount) {\n removed = self.selection.splice(0, self.selection.length - (selectableCount - 1));\n removed.forEach(function (d) {\n self.$[\"body\"].find('[data-calendar-item-date=\"' + U.date(d, {\"return\": cfg.dateFormat}) + '\"]').removeClass(\"selected-day\");\n });\n }\n\n jQuery(target).addClass(\"selected-day\");\n self.selection.push(value);\n\n if (self.onClick) {\n self.onClick.call({\n self: this, date: value, target: this.target, dateElement: target\n });\n }\n }\n }\n else if (mode == \"month\") {\n if (cfg.selectMode == \"month\") {\n if (selectable) {\n if (self.selection.length >= selectableCount) {\n removed = self.selection.splice(0, self.selection.length - (selectableCount - 1));\n removed.forEach(function (d) {\n self.$[\"body\"].find('[data-calendar-item-month=\"' + U.date(d, {\"return\": 'yyyy-MM-dd'}) + '\"]').removeClass(\"selected-month\");\n });\n }\n\n jQuery(target).addClass(\"selected-month\");\n self.selection.push(value);\n\n if (self.onClick) {\n self.onClick.call({\n self: this, date: value, target: this.target, dateElement: target\n });\n }\n }\n }\n else {\n self.changeMode(\"day\", value);\n }\n }\n else if (mode == \"year\") {\n if (cfg.selectMode == \"year\") {\n if (selectable) {\n if (self.selection.length >= selectableCount) {\n removed = self.selection.splice(0, self.selection.length - (selectableCount - 1));\n removed.forEach(function (d) {\n self.$[\"body\"].find('[data-calendar-item-year=\"' + U.date(d, {\"return\": 'yyyy-MM-dd'}) + '\"]').removeClass(\"selected-year\");\n });\n }\n\n jQuery(target).addClass(\"selected-year\");\n self.selection.push(value);\n\n if (self.onClick) {\n self.onClick.call({\n self: this, date: value, target: this.target, dateElement: target\n });\n }\n }\n }\n else {\n self.changeMode(\"month\", value);\n }\n }\n }\n\n mode = null;\n target = null;\n value = null;\n removed = null;\n dt = null;\n selectable = null;\n },\n move = function (e, target, value) {\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-calendar-move\")) {\n return true;\n }\n });\n if (target) {\n value = target.getAttribute(\"data-calendar-move\");\n if (cfg.mode == \"day\" || cfg.mode == \"d\") {\n if (value == \"left\") {\n cfg.displayDate = U.date(cfg.displayDate, {add: {m: -1}});\n }\n else {\n cfg.displayDate = U.date(cfg.displayDate, {add: {m: 1}});\n }\n printDay.call(this, cfg.displayDate);\n }\n else if (cfg.mode == \"month\" || cfg.mode == \"m\") {\n if (value == \"left\") {\n cfg.displayDate = U.date(cfg.displayDate, {add: {y: -1}});\n }\n else {\n cfg.displayDate = U.date(cfg.displayDate, {add: {y: 1}});\n }\n printMonth.call(this, cfg.displayDate);\n }\n else if (cfg.mode == \"year\" || cfg.mode == \"y\") {\n if (value == \"left\") {\n cfg.displayDate = U.date(cfg.displayDate, {add: {y: -10}});\n }\n else {\n cfg.displayDate = U.date(cfg.displayDate, {add: {y: 10}});\n }\n printYear.call(this, cfg.displayDate);\n }\n }\n\n target = null;\n value = null;\n },\n applyMarkerMap = function () {\n setTimeout((function () {\n if (cfg.mode === \"day\" || cfg.mode === \"d\") {\n for (var k in this.markerMap) {\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').addClass(this.markerMap[k].theme || cfg.defaultMarkerTheme);\n }\n }\n }).bind(this));\n },\n applySelectionMap = function () {\n setTimeout((function () {\n for (var k in this.selectionMap) {\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').addClass(\"selected-day\");\n }\n }).bind(this));\n },\n applyPeriodMap = function () {\n setTimeout((function () {\n if (cfg.mode === \"day\" || cfg.mode === \"d\") {\n for (var k in this.periodMap) {\n if (this.periodMap[k].label) {\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').find(\".addon-footer\").html(this.periodMap[k].label);\n }\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').addClass(this.periodMap[k].theme);\n }\n }\n }).bind(this));\n },\n clearPeriodMap = function () {\n if (cfg.mode === \"day\" || cfg.mode === \"d\") {\n for (var k in this.periodMap) {\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').find(\".addon-footer\").empty();\n this.$[\"body\"].find('[data-calendar-item-date=\"' + k + '\"]').removeClass(this.periodMap[k].theme);\n }\n }\n };\n\n /**\n * Preferences of calendar UI\n * @method ax5calendar.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Element|nodelist} config.target\n * @param {String} [config.mode=day|month|year]\n * @param {Function} [config.onClick}\n * @returns {ax5calendar}\n * @example\n * ```js\n * var myCalendar = new ax5.ui.calendar();\n * myCalendar.setConfig({\n * target: $(\"#target\"),\n * mode: \"day\"\n * });\n * ```\n */\n //== class body start\n this.init = function () {\n // after setConfig();\n\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n\n if (!cfg.target) {\n console.log(ax5.info.getError(\"ax5calendar\", \"401\", \"setConfig\"));\n }\n this.target = jQuery(cfg.target);\n\n cfg.displayDate = U.date(cfg.displayDate);\n this.target.html(getFrame.call(this));\n\n // 파트수집\n this.$ = {\n \"root\": this.target.find('[data-calendar-els=\"root\"]'),\n \"control\": this.target.find('[data-calendar-els=\"control\"]'),\n \"control-display\": this.target.find('[data-calendar-els=\"control-display\"]'),\n \"body\": this.target.find('[data-calendar-els=\"body\"]')\n };\n\n if (cfg.control) {\n this.$[\"root\"].on(cfg.clickEventName, '[data-calendar-move]', (function (e) {\n move.call(this, e || window.event);\n }).bind(this));\n }\n\n // collect selectableMap\n if (cfg.selection) {\n this.setSelection(cfg.selection, false);\n }\n // collect selectableMap\n if (cfg.selectable) {\n this.setSelectable(cfg.selectable, false);\n }\n // collect markerMap\n if (cfg.marker) {\n this.setMarker(cfg.marker, false);\n }\n\n setTimeout((function () {\n if (cfg.mode === \"day\" || cfg.mode === \"d\") {\n printDay.call(this, cfg.displayDate);\n }\n else if (cfg.mode === \"month\" || cfg.mode === \"m\") {\n printMonth.call(this, cfg.displayDate);\n }\n else if (cfg.mode === \"year\" || cfg.mode === \"y\") {\n printYear.call(this, cfg.displayDate);\n }\n }).bind(this));\n };\n\n /**\n * @method ax5calendar.changeMode\n * @param {String} mode\n * @param {String} changeDate\n * @returns {ax5calendar}\n */\n this.changeMode = function (mode, changeDate) {\n if (typeof changeDate != \"undefined\") cfg.displayDate = changeDate;\n if (mode) cfg.mode = mode;\n\n this.$[\"body\"].removeClass(\"fadein\").addClass(\"fadeout\");\n setTimeout((function () {\n if (cfg.mode == \"day\" || cfg.mode == \"d\") {\n printDay.call(this, cfg.displayDate);\n }\n else if (cfg.mode == \"month\" || cfg.mode == \"m\") {\n printMonth.call(this, cfg.displayDate);\n }\n else if (cfg.mode == \"year\" || cfg.mode == \"y\") {\n printYear.call(this, cfg.displayDate);\n }\n this.$[\"body\"].removeClass(\"fadeout\").addClass(\"fadein\");\n }).bind(this), cfg.animateTime);\n\n return this;\n };\n\n /**\n * @method ax5calendar.setSelection\n * @param {Array} selection\n * @returns {ax5calendar}\n * @example\n * ```\n *\n * ```\n */\n this.setSelection = (function () {\n self.selectionMap = {};\n var processor = {\n 'arr': function (v, map, count) {\n map = {};\n if (!U.isArray(v)) return map;\n self.selection = v = v.splice(0, count);\n v.forEach(function (n) {\n if (U.isDate(n))\n n = U.date(n, {'return': cfg.dateFormat});\n map[n] = true;\n });\n return map;\n }\n };\n\n return function (selection, isPrint) {\n var\n result = {}\n ;\n selectableCount = (cfg.multipleSelect) ? (U.isNumber(cfg.multipleSelect)) ? cfg.multipleSelect : 2 : 1;\n\n if (cfg.selection = selection) {\n if (U.isArray(selection)) {\n result = processor.arr(selection, {}, selectableCount);\n } else {\n return this;\n }\n }\n\n this.selectionMap = jQuery.extend({}, result);\n // 변경내용 적용하여 출력\n\n if (isPrint !== false) applySelectionMap.call(this);\n\n result = null;\n\n return this;\n };\n })();\n\n /**\n * @method ax5calendar.getSelection\n */\n this.getSelection = function () {\n return this.selection;\n };\n\n /**\n * @method ax5calendar.setSelectable\n */\n this.setSelectable = (function () {\n self.selectableMap = {};\n var processor = {\n 'arr': function (v, map) {\n map = {};\n if (!U.isArray(v)) return map;\n v.forEach(function (n) {\n if (U.isDate(n))\n n = U.date(n, {'return': cfg.dateFormat});\n map[n] = true;\n });\n return map;\n },\n 'obj': function (v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (v.range) return map;\n for (var k in v) {\n map[k] = v[k];\n }\n return map;\n },\n 'range': function (v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (!v.range) return map;\n\n v.range.forEach(function (n) {\n if (U.isDateFormat(n.from) && U.isDateFormat(n.to)) {\n for (var d = U.date(n.from); d <= U.date(n.to); d.setDate(d.getDate() + 1)) {\n map[U.date(d, {\"return\": cfg.dateFormat})] = true;\n }\n }\n else {\n for (var i = n.from; i <= n.to; i++) {\n map[i] = true;\n }\n }\n });\n\n return map;\n }\n };\n\n return function (selectable, isPrint) {\n\n var\n key,\n result = {}\n ;\n\n if (cfg.selectable = selectable) {\n if (U.isArray(selectable)) {\n result = processor.arr(selectable);\n }\n else {\n for (key in processor) {\n if (selectable[key]) {\n result = processor[key](selectable);\n break;\n }\n }\n if (Object.keys(result).length === 0) {\n result = processor.obj(selectable);\n }\n }\n }\n\n this.selectableMap = result;\n // 변경내용 적용하여 출력\n if (isPrint !== false) this.changeMode();\n\n return this;\n };\n })();\n\n /**\n * @method ax5calendar.setMarker\n */\n this.setMarker = (function () {\n self.markerMap = {};\n var processor = {\n 'obj': function (v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (v.range) return map;\n for (var k in v) {\n map[k] = v[k];\n }\n\n v = null;\n return map;\n },\n 'range': function (v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (!v.range) return map;\n\n v.range.forEach(function (n) {\n if (U.isDateFormat(n.from) && U.isDateFormat(n.to)) {\n for (var d = U.date(n.from); d <= U.date(n.to); d.setDate(d.getDate() + 1)) {\n map[U.date(d, {\"return\": cfg.dateFormat})] = {theme: n.theme, label: n.label};\n }\n }\n else {\n for (var i = n.from; i <= n.to; i++) {\n map[i] = {theme: n.theme, label: n.label};\n }\n }\n });\n\n v = null;\n return map;\n }\n };\n\n return function (marker, isApply) {\n\n var\n key,\n result = {}\n ;\n\n if (cfg.marker = marker) {\n for (key in processor) {\n if (marker[key]) {\n result = processor[key](marker);\n break;\n }\n }\n if (Object.keys(result).length === 0) {\n result = processor.obj(marker);\n }\n }\n\n this.markerMap = result;\n // 변경내용 적용하여 출력\n if (isApply !== false) applyMarkerMap.call(this);\n return this;\n };\n })();\n\n /**\n * @method ax5calendar.setPeriod\n */\n this.setPeriod = (function () {\n self.periodMap = {};\n\n var processor = {\n 'range': function (v, map) {\n map = {};\n if (U.isArray(v)) return map;\n if (!v.range) return map;\n\n v.range.forEach(function (n) {\n if (U.isDateFormat(n.from) && U.isDateFormat(n.to)) {\n for (var d = new Date(U.date(n.from)); d <= U.date(n.to); d.setDate(d.getDate() + 1)) {\n if (d.getTime() == U.date(n.from).getTime()) {\n map[U.date(d, {\"return\": cfg.dateFormat})] = {theme: n.theme || cfg.defaultPeriodTheme, label: n.fromLabel};\n } else if (d.getTime() == U.date(n.to).getTime()) {\n map[U.date(d, {\"return\": cfg.dateFormat})] = {theme: n.theme || cfg.defaultPeriodTheme, label: n.toLabel};\n } else {\n map[U.date(d, {\"return\": cfg.dateFormat})] = {theme: n.theme || cfg.defaultPeriodTheme};\n }\n }\n }\n });\n\n v = null;\n return map;\n }\n };\n\n return function (period, isApply) {\n\n var\n key,\n result = {}\n ;\n\n // 변경내용 적용하여 출력\n if (isApply !== false) {\n clearPeriodMap.call(this);\n }\n\n if (cfg.period = period) {\n result = processor.range(period);\n }\n\n this.periodMap = result;\n\n //console.log(this.periodMap);\n\n // 변경내용 적용하여 출력\n if (isApply !== false) {\n applyPeriodMap.call(this);\n }\n return this;\n };\n })();\n\n // 클래스 생성자\n this.main = (function () {\n\n UI.calendar_instance = UI.calendar_instance || [];\n UI.calendar_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }).apply(this, arguments);\n };\n return ax5calendar;\n })());\n CALENDAR = ax5.ui.calendar;\n})();","// ax5.ui.calendar.tmpl\n(function () {\n\n var CALENDAR = ax5.ui.calendar;\n\n var frameTmpl = function (columnKeys) {\n return `\n \n {{#control}}\n
\n {{/control}}\n
\n
\n `;\n };\n var dayTmpl = function (columnKeys) {\n return `\n \n \n \n {{#weekNames}}\n \n {{label}}\n | \n {{/weekNames}}\n
\n \n \n \n {{#list}} \n {{#isStartOfWeek}}\n {{^@first}}\n
\n \n {{/@first}}\n {{/isStartOfWeek}}\n \n \n \n {{thisDataLabel}}\n \n \n | \n {{/list}}\n
\n \n
\n `;\n };\n var monthTmpl = function (columnKeys) {\n return `\n \n \n \n \n {{colHeadLabel}}\n | \n
\n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n
\n \n {{/@first}}\n {{/isStartOfRow}}\n \n \n \n {{thisMonthLabel}}\n \n \n | \n {{/list}}\n
\n \n
\n `;\n };\n var yearTmpl = function (columnKeys) {\n return `\n \n \n \n \n {{colHeadLabel}}\n | \n
\n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n
\n \n {{/@first}}\n {{/isStartOfRow}}\n \n \n \n {{thisYearLabel}}\n \n \n | \n {{/list}}\n
\n \n
\n `;\n };\n\n CALENDAR.tmpl = {\n \"frameTmpl\": frameTmpl,\n \"dayTmpl\": dayTmpl,\n \"monthTmpl\": monthTmpl,\n \"yearTmpl\": yearTmpl,\n \n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(CALENDAR.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n\n})();","// ax5.ui.picker\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var PICKER;\n\n UI.addClass({\n className: \"picker\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5picker\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * ax5.def.picker.date_leftArrow = '';\n * ax5.def.picker.date_yearTmpl = '%s';\n * ax5.def.picker.date_monthTmpl = '%s';\n * def.picker.date_rightArrow = '';\n *\n * var picker = new ax5.ui.picker({\n * onStateChanged: function () {\n * console.log(this);\n * }\n * });\n *\n * picker.bind({\n * target: $('[data-picker-date]'),\n * direction: \"auto\",\n * content: {\n * type: 'date',\n * formatter: {\n * pattern: 'date'\n * }\n * }\n * });\n * ```\n */\n var ax5picker = function () {\n let self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchend\" : \"click\"),\n theme: 'default',\n title: '',\n lang: {\n \"ok\": \"ok\",\n \"cancel\": \"cancel\"\n },\n animateTime: 100,\n calendar: {\n multipleSelect: false,\n control: {\n left: ax5.def.picker.date_leftArrow || '←',\n yearTmpl: ax5.def.picker.date_yearTmpl || '%s',\n monthTmpl: ax5.def.picker.date_monthTmpl || '%s',\n right: ax5.def.picker.date_rightArrow || '→',\n yearFirst: true\n }\n }\n };\n this.queue = [];\n this.activePicker = null;\n this.activePickerQueueIndex = -1;\n this.openTimer = null;\n this.closeTimer = null;\n\n cfg = this.config;\n\n let onStateChanged = function (item, that) {\n if (item && item.onStateChanged) {\n item.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n return true;\n },\n bindPickerTarget = (function () {\n\n var pickerEvent = {\n 'focus': function (queIdx, e) {\n this.open(queIdx);\n },\n 'click': function (queIdx, e) {\n this.open(queIdx);\n }\n };\n\n var pickerType = {\n '@fn': function (queIdx, _input) {\n var item = this.queue[queIdx],\n inputLength = _input.length,\n config = {\n inputLength: inputLength || 1\n };\n\n if (inputLength > 1) {\n config.btns = {\n ok: {label: cfg.lang[\"ok\"], theme: cfg.theme}\n };\n }\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n config = null;\n inputLength = null;\n },\n 'date': function (queIdx, _input) {\n // 1. 이벤트 바인딩\n // 2. ui 준비\n\n var item = this.queue[queIdx],\n contentWidth = (item.content) ? item.content.width || 270 : 270,\n contentMargin = (item.content) ? item.content.margin || 5 : 5,\n inputLength = _input.length,\n config = {\n contentWidth: (contentWidth * inputLength) + ((inputLength - 1) * contentMargin),\n content: {width: contentWidth, margin: contentMargin},\n inputLength: inputLength || 1\n };\n\n if (inputLength > 1 && !item.btns) {\n config.btns = {\n ok: {label: cfg.lang[\"ok\"], theme: cfg.theme}\n };\n }\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n contentWidth = null;\n contentMargin = null;\n config = null;\n inputLength = null;\n },\n 'secure-num': function (queIdx, _input) {\n var item = this.queue[queIdx],\n inputLength = _input.length,\n config = {\n inputLength: inputLength || 1\n };\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n config = null;\n inputLength = null;\n },\n 'keyboard': function (queIdx, _input) {\n var item = this.queue[queIdx],\n inputLength = _input.length,\n config = {\n inputLength: inputLength || 1\n };\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n config = null;\n inputLength = null;\n },\n 'numpad': function (queIdx, _input) {\n var item = this.queue[queIdx],\n inputLength = _input.length,\n config = {\n inputLength: inputLength || 1\n };\n\n this.queue[queIdx] = jQuery.extend(true, config, item);\n\n config = null;\n inputLength = null;\n }\n };\n\n return function (queIdx) {\n var item = this.queue[queIdx],\n input;\n\n if (!item.content) {\n console.log(ax5.info.getError(\"ax5picker\", \"501\", \"bind\"));\n return this;\n }\n\n input = (item.$target.get(0).tagName.toUpperCase() == \"INPUT\") ? item.$target : item.$target.find('input[type]');\n\n // 함수타입\n if (U.isFunction(item.content)) {\n pickerType[\"@fn\"].call(this, queIdx, input);\n }\n else {\n for (var key in pickerType) {\n if (item.content.type == key) {\n pickerType[key].call(this, queIdx, input);\n break;\n }\n }\n }\n\n input\n .unbind('focus.ax5picker')\n .unbind('click.ax5picker')\n .bind('focus.ax5picker', pickerEvent.focus.bind(this, queIdx))\n .bind('click.ax5picker', pickerEvent.click.bind(this, queIdx));\n\n item.$target\n .find('.input-group-addon')\n .unbind('click.ax5picker')\n .bind('click.ax5picker', pickerEvent.click.bind(this, queIdx));\n\n if (item.content.formatter && ax5.ui.formatter) {\n input.ax5formatter(item.content.formatter);\n }\n\n input = null;\n item = null;\n queIdx = null;\n return this;\n }\n\n })(),\n\n alignPicker = function (append) {\n if (!this.activePicker) return this;\n\n var _alignPicker = function (item) {\n var $window = jQuery(window), $body = jQuery(document.body);\n var pos = {}, positionMargin = 12,\n dim = {}, pickerDim = {},\n pickerDirection;\n\n pos = item.$target.offset();\n dim = {\n width: item.$target.outerWidth(),\n height: item.$target.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), $body.width()),\n winHeight: Math.max($window.height(), $body.height()),\n width: this.activePicker.outerWidth(),\n height: this.activePicker.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n\n if (!item.direction || item.direction === \"\" || item.direction === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = item.direction;\n }\n\n if (append) {\n this.activePicker\n .addClass(\"direction-\" + pickerDirection);\n }\n\n var positionCSS = (function () {\n var css = {left: 0, top: 0};\n switch (pickerDirection) {\n case \"top\":\n css.left = pos.left + dim.width / 2 - pickerDim.width / 2;\n css.top = pos.top + dim.height + positionMargin;\n break;\n case \"bottom\":\n css.left = pos.left + dim.width / 2 - pickerDim.width / 2;\n css.top = pos.top - pickerDim.height - positionMargin;\n break;\n case \"left\":\n css.left = pos.left + dim.width + positionMargin;\n css.top = pos.top - pickerDim.height / 2 + dim.height / 2;\n break;\n case \"right\":\n css.left = pos.left - pickerDim.width - positionMargin;\n css.top = pos.top - pickerDim.height / 2 + dim.height / 2;\n break;\n }\n return css;\n })();\n\n (function () {\n if (pickerDirection == \"top\" || pickerDirection == \"bottom\") {\n if (positionCSS.left < 0) {\n positionCSS.left = positionMargin;\n this.activePickerArrow.css({left: (pos.left + dim.width / 2) - positionCSS.left});\n } else if (positionCSS.left + pickerDim.width > pickerDim.winWidth) {\n positionCSS.left = pickerDim.winWidth - pickerDim.width - positionMargin;\n this.activePickerArrow.css({left: (pos.left + dim.width / 2) - positionCSS.left});\n }\n }\n }).call(this);\n\n this.activePicker\n .css(positionCSS);\n };\n\n var item = this.queue[this.activePickerQueueIndex];\n\n this.activePicker.css({top: -999});\n\n if (append) jQuery(document.body).append(this.activePicker);\n setTimeout((function () {\n _alignPicker.call(this, item);\n }).bind(this));\n },\n onBodyClick = function (e, target) {\n if (!this.activePicker) return this;\n\n var\n item = this.queue[this.activePickerQueueIndex]\n ;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-picker-els\")) {\n return true;\n }\n else if (item.$target.get(0) == target) {\n return true;\n }\n });\n if (!target) {\n //console.log(\"i'm not picker\");\n this.close();\n return this;\n }\n //console.log(\"i'm picker\");\n return this;\n },\n onBtnClick = function (e, target) {\n // console.log('btn click');\n if (e.srcElement) e.target = e.srcElement;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-picker-btn\")) {\n return true;\n }\n });\n\n if (target) {\n let\n item = this.queue[this.activePickerQueueIndex],\n k = target.getAttribute(\"data-picker-btn\")\n ;\n\n if (item.btns && item.btns[k].onClick) {\n let that = {\n key: k,\n value: item.btns[k],\n self: this,\n item: item\n };\n item.btns[k].onClick.call(that, k);\n }\n else {\n this.close();\n }\n }\n },\n onBodyKeyup = function (e) {\n if (e.keyCode == ax5.info.eventKeys.ESC) {\n this.close();\n }\n },\n getQueIdx = function (boundID) {\n if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-axpicker-id\");\n }\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5picker\", \"402\", \"getQueIdx\"));\n return;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n };\n /// private end\n\n /**\n * Preferences of picker UI\n * @method ax5picker.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5picker}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n };\n\n /**\n * bind picker UI\n * @method ax5picker.bind\n * @param {Object} item\n * @param {Element} item.target\n * @param {String} item.direction - top|left|right|bottom|auto\n * @param {Number} item.contentWidth\n * @param {Boolean} item.disableChangeTrigger\n * @param {Function} item.onStateChanged\n * @param {Object} item.btns\n * @param {Object} item.content\n * @param {Number} item.content.width\n * @param {Number} item.content.margin\n * @param {String} item.content.type\n * @param {Object} item.content.config - binded UI config\n * @param {Object} item.content.formatter\n * @param {String} item.content.formatter.pattern\n * @returns {ax5picker}\n * @example\n * ```js\n * var picker = new ax5.ui.picker();\n * $(document.body).ready(function () {\n * picker.bind({\n * target: $('[data-ax5picker=\"basic\"]'),\n * direction: \"top\",\n * content: {\n * width: 270,\n * margin: 10,\n * type: 'date',\n * config: {\n * control: {\n * left: '',\n * yearTmpl: '%s',\n * monthTmpl: '%s',\n * right: ''\n * },\n * lang: {\n * yearTmpl: \"%s년\",\n * months: ['01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12'],\n * dayTmpl: \"%s\"\n * }\n * },\n * formatter: {\n * pattern: 'date'\n * }\n * },\n * onStateChanged: function () {\n *\n * }\n * });\n * });\n * ```\n */\n this.bind = function (item) {\n let pickerConfig = {},\n queIdx;\n\n item = jQuery.extend(true, pickerConfig, cfg, item);\n\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5picker\", \"401\", \"bind\"));\n return this;\n }\n item.$target = jQuery(item.target);\n\n if (!item.$target.get(0)) {\n console.log(ax5.info.getError(\"ax5picker\", \"401\", \"bind\"));\n return this;\n }\n\n if (!item.id) item.id = item.$target.data(\"data-axpicker-id\");\n\n if (!item.id) {\n item.id = 'ax5-picker-' + ax5.getGuid();\n item.$target.data(\"data-axpicker-id\", item.id);\n }\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindPickerTarget.call(this, this.queue.length - 1);\n }\n else {\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindPickerTarget.call(this, queIdx);\n }\n\n pickerConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * @method ax5picker.setContentValue\n * @param {String} boundID\n * @param {Number} inputIndex\n * @param {String} val\n * @returns {ax5picker} this\n */\n this.setContentValue = (function () {\n\n var multipleInputProcessor = {\n \"date\": function (_item, _inputIndex, _val) {\n var values = [],\n diffDay, prevInputValue, nextInputValue;\n\n if (_item.$target.get(0).tagName.toUpperCase() !== \"INPUT\") {\n _item.$target.find('input[type]').each(function () {\n values.push(this.value);\n });\n }\n\n if (_inputIndex == 0) {\n if (values.length > 1 && values[1] !== \"\") {\n // 값 검증\n diffDay = ax5.util.dday(values[1], {today: values[0]});\n if (diffDay < 0) {\n // 다음날짜 달력을 변경합니다.\n nextInputValue = _val;\n }else{\n\n }\n }else{\n nextInputValue = _val;\n }\n\n if(nextInputValue) {\n _item.pickerCalendar[1].ax5uiInstance.setSelection([nextInputValue], false).changeMode(\"d\", nextInputValue);\n this.setContentValue(_item.id, 1, nextInputValue);\n }\n\n return _val;\n\n } else if (_inputIndex == 1) {\n if (values.length > 1) {\n // 값 검증\n diffDay = ax5.util.dday(values[1], {today: values[0]});\n if (diffDay < 0) {\n // 다음날짜 달력을 변경합니다.\n prevInputValue = values[1];\n }\n }\n\n if(prevInputValue) {\n _item.pickerCalendar[0].ax5uiInstance.setSelection([prevInputValue], false).changeMode(\"d\", prevInputValue);\n this.setContentValue(_item.id, 0, prevInputValue);\n }\n\n return _val;\n }\n }\n };\n\n return function (boundID, inputIndex, val) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n var _input;\n\n if (item) {\n\n _input = (item.$target.get(0).tagName.toUpperCase() == \"INPUT\") ? item.$target : jQuery(item.$target.find('input[type]').get(inputIndex));\n _input.val(val);\n\n if (!item.disableChangeTrigger) {\n _input.trigger(\"change\");\n }\n\n // picker의 입력이 2개이상인 경우\n //console.log(item.inputLength);\n if (item.inputLength > 1) {\n // 경우에 따라 첫번 선택에 따라 해야할 일들 처리\n if (multipleInputProcessor[item.content.type]) {\n val = multipleInputProcessor[item.content.type].call(this, item, inputIndex, val);\n }\n }\n\n var that = {\n self: self,\n state: \"changeValue\",\n item: item,\n inputIndex: inputIndex,\n value: val,\n values: [val]\n };\n if (item.$target.get(0).tagName.toUpperCase() !== \"INPUT\") {\n that.values = [];\n item.$target.find('input[type]').each(function () {\n that.values.push(this.value);\n });\n }\n\n onStateChanged.call(this, item, that);\n\n if (item.inputLength == 1) {\n this.close();\n }\n }\n\n item = null;\n boundID = null;\n inputIndex = null;\n val = null;\n return this;\n };\n })();\n\n /**\n * @method ax5picker.open\n * @param {String} boundObjectId\n * @returns {ax5picker} this\n */\n this.open = (function () {\n\n var pickerContent = {\n '@fn': function (queIdx, callback) {\n var item = this.queue[queIdx];\n item.content.call(item, function (html) {\n callback(html);\n });\n return true;\n },\n 'date': function (queIdx) {\n var item = this.queue[queIdx];\n var html = [];\n for (var i = 0; i < item.inputLength; i++) {\n html.push('');\n if (i < item.inputLength - 1) html.push('');\n }\n html.push('');\n item.pickerContent.html(html.join(''));\n\n var calendarConfig = jQuery.extend({}, cfg.calendar, {displayDate: (new Date())});\n var input = (item.$target.get(0).tagName.toUpperCase() == \"INPUT\") ? item.$target : item.$target.find('input[type]');\n\n // calendar bind\n item.pickerCalendar = [];\n item.pickerContent.find('[data-calendar-target]').each(function () {\n\n // calendarConfig extend ~\n var\n idx = this.getAttribute(\"data-calendar-target\"),\n dValue = input.get(idx).value,\n d = ax5.util.date(dValue);\n\n calendarConfig.displayDate = d;\n if (dValue) calendarConfig.selection = [d];\n calendarConfig = jQuery.extend(true, calendarConfig, item.content.config || {});\n calendarConfig.target = this;\n calendarConfig.onClick = function () {\n self.setContentValue(item.id, idx, this.date);\n };\n\n item.pickerCalendar.push({\n itemId: item.id,\n inputIndex: idx,\n ax5uiInstance: new ax5.ui.calendar(calendarConfig)\n });\n });\n\n },\n 'secure-num': function (queIdx) {\n var item = this.queue[queIdx];\n var html = [];\n for (var i = 0; i < item.inputLength; i++) {\n html.push('');\n if (i < item.inputLength - 1) html.push('');\n }\n html.push('');\n item.pickerContent.html(html.join(''));\n\n // secure-num bind\n item.pickerContent.find('[data-secure-num-target]').each(function () {\n var idx = this.getAttribute(\"data-secure-num-target\"),\n po = [];\n\n var numArray = (function (a) {\n var j, x, i;\n for (i = a.length; i; i -= 1) {\n j = Math.floor(Math.random() * i);\n x = a[i - 1];\n a[i - 1] = a[j];\n a[j] = x;\n }\n return a;\n })([0, 1, 2, 3, 4, 5, 6, 7, 8, 9]);\n\n var specialArray = [\n {label: \"←\", fn: \"back\"}, {label: \"C\", fn: \"clear\"}\n ];\n\n numArray.forEach(function (n) {\n po.push('');\n po.push('');\n po.push('
');\n });\n specialArray.forEach(function (n) {\n po.push('');\n po.push('');\n po.push('
');\n });\n\n po.push('');\n\n $(this).html(po.join('')).on(\"click\", '[data-secure-num-value]', function () {\n var act = this.getAttribute(\"data-secure-num-value\");\n var _input = (item.$target.get(0).tagName.toUpperCase() == \"INPUT\") ? item.$target : jQuery(item.$target.find('input[type]').get(idx));\n var val = _input.val();\n\n if (act == \"back\") {\n _input.val(val.substring(0, val.length - 1));\n }\n else if (act == \"clear\") {\n _input.val('');\n }\n else {\n _input.val(val + act);\n }\n\n onStateChanged.call(this, item, {\n self: self,\n state: \"changeValue\",\n item: item,\n value: _input.val()\n });\n });\n });\n },\n 'keyboard': function (queIdx) {\n var item = this.queue[queIdx];\n var html = [];\n for (var i = 0; i < item.inputLength; i++) {\n html.push('');\n if (i < item.inputLength - 1) html.push('');\n }\n html.push('');\n item.pickerContent.html(html.join(''));\n\n var keyArray = [\n [\n {value: \"`\", shiftValue: \"~\"},\n {value: \"1\", shiftValue: \"!\"},\n {value: \"2\", shiftValue: \"@\"},\n {value: \"3\", shiftValue: \"#\"},\n {value: \"4\", shiftValue: \"$\"},\n {value: \"5\", shiftValue: \"%\"},\n {value: \"6\", shiftValue: \"^\"},\n {value: \"7\", shiftValue: \"&\"},\n {value: \"8\", shiftValue: \"*\"},\n {value: \"9\", shiftValue: \"(\"},\n {value: \"0\", shiftValue: \")\"},\n {value: \"-\", shiftValue: \"_\"},\n {value: \"=\", shiftValue: \"+\"},\n {label: \"←\", fn: \"back\"}\n ],\n [\n {value: \"q\", shiftValue: \"Q\"},\n {value: \"w\", shiftValue: \"W\"},\n {value: \"e\", shiftValue: \"E\"},\n {value: \"r\", shiftValue: \"R\"},\n {value: \"t\", shiftValue: \"T\"},\n {value: \"y\", shiftValue: \"Y\"},\n {value: \"u\", shiftValue: \"U\"},\n {value: \"i\", shiftValue: \"I\"},\n {value: \"o\", shiftValue: \"O\"},\n {value: \"p\", shiftValue: \"P\"},\n {value: \"[\", shiftValue: \"{\"},\n {value: \"]\", shiftValue: \"}\"},\n {value: \"\\\\\", shiftValue: \"|\"}\n ],\n [\n {label: \"Clear\", fn: \"clear\"},\n {value: \"a\", shiftValue: \"A\"},\n {value: \"s\", shiftValue: \"S\"},\n {value: \"d\", shiftValue: \"D\"},\n {value: \"f\", shiftValue: \"F\"},\n {value: \"g\", shiftValue: \"G\"},\n {value: \"h\", shiftValue: \"H\"},\n {value: \"j\", shiftValue: \"J\"},\n {value: \"k\", shiftValue: \"K\"},\n {value: \"l\", shiftValue: \"L\"},\n {value: \";\", shiftValue: \":\"},\n {value: \"'\", shiftValue: \"\\\"\"}\n\n\n ],\n [\n {label: \"Shift\", fn: \"shift\"},\n {value: \"z\", shiftValue: \"Z\"},\n {value: \"x\", shiftValue: \"X\"},\n {value: \"c\", shiftValue: \"C\"},\n {value: \"v\", shiftValue: \"V\"},\n {value: \"b\", shiftValue: \"B\"},\n {value: \"n\", shiftValue: \"N\"},\n {value: \"m\", shiftValue: \"M\"},\n {value: \",\", shiftValue: \"<\"},\n {value: \".\", shiftValue: \">\"},\n {value: \"/\", shiftValue: \"?\"},\n {label: \"Close\", fn: \"close\"}\n ]\n ];\n var specialArray = [\n {label: \"←\", fn: \"back\"}, {label: \"C\", fn: \"clear\"}\n ];\n\n var getKeyBoard = function (isShiftKey) {\n var po = [];\n keyArray.forEach(function (row) {\n po.push('');\n row.forEach(function (n) {\n\n var keyValue, keyLabel, btnWrapStyle, btnTheme, btnStyle;\n if (n.fn) {\n keyValue = n.fn;\n keyLabel = n.label;\n btnWrapStyle = item.content.config.specialBtnWrapStyle;\n btnTheme = item.content.config.specialBtnTheme;\n btnStyle = item.content.config.specialBtnStyle;\n } else {\n keyLabel = keyValue = ((isShiftKey) ? n.shiftValue : n.value);\n btnWrapStyle = item.content.config.btnWrapStyle;\n btnTheme = item.content.config.btnTheme;\n btnStyle = item.content.config.btnStyle;\n }\n\n po.push('
');\n po.push('');\n po.push('
');\n });\n po.push('
');\n });\n return po.join('');\n };\n\n // secure-num bind\n item.pickerContent.find('[data-keyboard-target]').each(function () {\n var idx = this.getAttribute(\"data-keyboard-target\");\n var $this = $(this);\n var isShiftKey = false;\n var toggleShift = function () {\n isShiftKey = !isShiftKey;\n $this.html(getKeyBoard(isShiftKey));\n };\n $this.html(getKeyBoard(isShiftKey)).on(\"mousedown\", '[data-keyboard-value]', function () {\n var act = this.getAttribute(\"data-keyboard-value\");\n var _input = (item.$target.get(0).tagName.toUpperCase() == \"INPUT\") ? item.$target : jQuery(item.$target.find('input[type]').get(idx));\n var val = _input.val();\n\n switch (act) {\n case \"back\":\n _input.val(val.substring(0, val.length - 1));\n break;\n case \"clear\":\n _input.val('');\n break;\n case \"shift\":\n toggleShift();\n return false;\n break;\n case \"close\":\n self.close();\n return false;\n break;\n default:\n _input.val(val + act);\n }\n\n onStateChanged.call(this, item, {\n self: self,\n state: \"changeValue\",\n item: item,\n value: _input.val()\n });\n });\n });\n },\n 'numpad': function (queIdx) {\n var item = this.queue[queIdx];\n var html = [];\n for (var i = 0; i < item.inputLength; i++) {\n html.push('');\n if (i < item.inputLength - 1) html.push('');\n }\n html.push('');\n item.pickerContent.html(html.join(''));\n\n // secure-num bind\n item.pickerContent.find('[data-numpad-target]').each(function () {\n var idx = this.getAttribute(\"data-numpad-target\"),\n po = [];\n\n var keyArray = item.content.config.keyArray || [\n {value: \"7\"},\n {value: \"8\"},\n {value: \"9\"},\n {label: \"BS\", fn: \"back\"},\n {value: \"4\"},\n {value: \"5\"},\n {value: \"6\"},\n {label: \"CLS\", fn: \"clear\"},\n {value: \"1\"},\n {value: \"2\"},\n {value: \"3\"},\n {value: \"\"},\n {value: \".\"},\n {value: \"0\"},\n {value: \"\"},\n {label: \"OK\", fn: \"enter\"}\n ];\n\n keyArray.forEach(function (n) {\n var keyValue, keyLabel, btnWrapStyle, btnTheme, btnStyle;\n\n if (n.fn) {\n keyValue = n.fn;\n keyLabel = n.label;\n btnTheme = item.content.config.specialBtnTheme;\n btnWrapStyle = item.content.config.specialBtnWrapStyle;\n btnStyle = item.content.config.specialBtnStyle;\n } else {\n keyLabel = keyValue = n.value;\n btnTheme = (keyValue) ? item.content.config.btnTheme : \"\";\n btnWrapStyle = item.content.config.btnWrapStyle;\n btnStyle = item.content.config.btnStyle;\n }\n\n po.push('');\n po.push('');\n po.push('
');\n });\n\n po.push('');\n\n $(this).html(po.join('')).on(\"mousedown\", '[data-numpad-value]', function () {\n var act = this.getAttribute(\"data-numpad-value\");\n var _input = (item.$target.get(0).tagName.toUpperCase() == \"INPUT\") ? item.$target : jQuery(item.$target.find('input[type]').get(idx));\n var val = _input.val();\n var state = \"\";\n\n switch (act) {\n case \"back\":\n state = \"changeValue\";\n _input.val(val.substring(0, val.length - 1));\n break;\n case \"clear\":\n state = \"changeValue\";\n _input.val('');\n break;\n case \"enter\":\n self.close(item, \"enter\");\n return false;\n break;\n case \"close\":\n self.close();\n return false;\n break;\n default:\n state = \"changeValue\";\n _input.val(val + act);\n }\n\n onStateChanged.call(this, item, {\n self: self,\n state: state,\n item: item,\n value: _input.val()\n });\n });\n });\n }\n };\n\n return function (boundID, tryCount) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n\n /**\n 다른 피커가 있는 경우와 다른 피커를 닫고 다시 오픈 명령이 내려진 경우에 대한 예외 처리 구문\n */\n if (this.openTimer) clearTimeout(this.openTimer);\n if (this.activePicker) {\n if (this.activePickerQueueIndex == queIdx) {\n return this;\n }\n\n if (tryCount > 2) return this;\n this.close();\n this.openTimer = setTimeout((function () {\n this.open(queIdx, (tryCount || 0) + 1);\n }).bind(this), cfg.animateTime);\n return this;\n }\n\n this.activePicker = jQuery(PICKER.tmpl.get.call(this, \"pickerTmpl\", item));\n this.activePickerArrow = this.activePicker.find(\".ax-picker-arrow\");\n this.activePickerQueueIndex = queIdx;\n item.pickerContent = this.activePicker.find('[data-picker-els=\"content\"]');\n\n if (U.isFunction(item.content)) {\n // 함수타입\n item.pickerContent.html(\"Loading..\");\n pickerContent[\"@fn\"].call(this, queIdx, function (html) {\n item.pickerContent.html(html);\n });\n }\n else {\n if (item.content.type in pickerContent) {\n pickerContent[item.content.type].call(this, queIdx);\n }\n }\n\n // bind event picker btns\n this.activePicker.find(\"[data-picker-btn]\").on(cfg.clickEventName, (function (e) {\n onBtnClick.call(this, e || window.event, queIdx);\n }).bind(this));\n\n alignPicker.call(this, \"append\");\n\n jQuery(window).bind(\"resize.ax5picker\", (function () {\n alignPicker.call(this);\n }).bind(this));\n\n // bind key event\n jQuery(window).bind(\"keyup.ax5picker\", (function (e) {\n e = e || window.event;\n onBodyKeyup.call(this, e);\n U.stopEvent(e);\n }).bind(this));\n\n jQuery(window).bind(\"click.ax5picker\", (function (e) {\n e = e || window.event;\n onBodyClick.call(this, e);\n U.stopEvent(e);\n }).bind(this));\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"open\",\n item: item\n });\n\n return this;\n };\n })();\n\n /**\n * @method ax5picker.close\n * @returns {ax5picker} this\n */\n this.close = function (item, state) {\n if (this.closeTimer) clearTimeout(this.closeTimer);\n if (!this.activePicker) return this;\n\n item = this.queue[this.activePickerQueueIndex];\n\n this.activePicker.addClass(\"destroy\");\n jQuery(window).unbind(\"resize.ax5picker\");\n jQuery(window).unbind(\"click.ax5picker\");\n jQuery(window).unbind(\"keyup.ax5picker\");\n\n this.closeTimer = setTimeout((function () {\n if (this.activePicker) this.activePicker.remove();\n this.activePicker = null;\n this.activePickerQueueIndex = -1;\n\n onStateChanged.call(this, item, {\n self: this,\n state: state || \"close\"\n });\n\n }).bind(this), cfg.animateTime);\n\n return this;\n };\n\n // 클래스 생성자\n this.main = (function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }).apply(this, arguments);\n };\n return ax5picker;\n })());\n\n PICKER = ax5.ui.picker;\n})();\n\n/**\n * ax5.ui.picker_instance\n * @type {ax5picker}\n * @example\n * ```js\n * // picker 기본 속성을 변경해야 한다면\n * ax5.ui.picker_instance.setConfig({\n * });\n *\n * ```\n */\nax5.ui.picker_instance = new ax5.ui.picker();\n\njQuery.fn.ax5picker = (function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"open\":\n return ax5.ui.picker_instance.open(this);\n break;\n case \"close\":\n return ax5.ui.picker_instance.close(this);\n break;\n case \"setValue\":\n return ax5.ui.picker_instance.setContentValue(this, arguments[1], arguments[2]);\n break;\n default:\n return this;\n }\n }\n else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend(true, config, defaultConfig);\n ax5.ui.picker_instance.bind(config);\n });\n }\n return this;\n };\n})();","// ax5.ui.picker.tmpl\n(function () {\n var PICKER = ax5.ui.picker;\n var U = ax5.util;\n\n var pickerTmpl = function () {\n return `\n\n {{#title}}\n
{{title}}
\n {{/title}}\n
\n
\n {{#btns}}\n
\n {{#btns}}\n {{#@each}}\n \n {{/@each}}\n {{/btns}}\n
\n {{/btns}}\n
\n
\n
\n`;\n };\n\n PICKER.tmpl = {\n \"pickerTmpl\": pickerTmpl,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(PICKER.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();","// ax5.ui.formatter\n(function () {\n var UI = ax5.ui;\n var U = ax5.util;\n var FORMATTER;\n\n UI.addClass({\n className: \"formatter\",\n version: \"1.3.66\"\n }, (function () {\n var TODAY = new Date();\n var setSelectionRange = function (input, pos) {\n if (typeof pos == \"undefined\") {\n pos = input.value.length;\n }\n if (input.setSelectionRange) {\n input.focus();\n input.setSelectionRange(pos, pos);\n }\n else if (input.createTextRange) {\n var range = input.createTextRange();\n range.collapse(true);\n range.moveEnd('character', pos);\n range.moveStart('character', pos);\n range.select();\n }\n else if (input.selectionStart) {\n input.focus();\n input.selectionStart = pos;\n input.selectionEnd = pos;\n }\n };\n\n /**\n * @class ax5formatter\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * $('#idInputTime').attr('data-ax5formatter', 'time').ax5formatter();\n * $('#idInputMoney').attr('data-ax5formatter', 'money').ax5formatter();\n * $('#idInputPhone').attr('data-ax5formatter', 'phone').ax5formatter();\n * $('#idInputDate').attr('data-ax5formatter', 'date').ax5formatter();\n *\n * $('#ax5formatter-custom').ax5formatter({\n * pattern: \"custom\",\n * getEnterableKeyCodes: function(){\n * return {\n * '65':'a',\n * '66':'b',\n * '67':'c',\n * '68':'d',\n * '69':'e',\n * '70':'f'\n * };\n * },\n * getPatternValue: function(obj){\n * return obj.value.replace(/./g, \"*\");\n * }\n * });\n * ```\n */\n var ax5formatter = function () {\n var\n self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n animateTime: 250\n };\n\n this.queue = [];\n this.openTimer = null;\n this.closeTimer = null;\n\n cfg = this.config;\n\n var\n formatterEvent = {\n 'focus': function (opts, optIdx, e) {\n if (!opts.$input.data(\"__originValue__\")) opts.$input.data(\"__originValue__\", opts.$input.val());\n },\n /* 키 다운 이벤트에서 입력할 수 없는 키 입력을 방어 */\n 'keydown': function (opts, optIdx, e) {\n var isStop = false;\n if (!opts.enterableKeyCodes) {\n\n }\n else if (e.which && opts.enterableKeyCodes[e.which]) {\n\n }\n else if (!e.metaKey && !e.ctrlKey && !e.shiftKey) {\n //console.log(e.which, opts.enterableKeyCodes);\n isStop = true;\n }\n if (isStop) ax5.util.stopEvent(e);\n },\n /* 키 업 이벤트에서 패턴을 적용 */\n 'keyup': function (opts, optIdx, e) {\n var elem = opts.$input.get(0),\n elemFocusPosition,\n beforeValue,\n newValue,\n selection, selectionLength\n ;\n\n if ('selectionStart' in elem) {\n // Standard-compliant browsers\n elemFocusPosition = elem.selectionStart;\n }\n else if (document.selection) {\n // IE\n //elem.focus();\n selection = document.selection.createRange();\n selectionLength = document.selection.createRange().text.length;\n selection.moveStart('character', -elem.value.length);\n elemFocusPosition = selection.text.length - selectionLength;\n }\n\n beforeValue = elem.value;\n if (opts.pattern in FORMATTER.formatter) {\n newValue = FORMATTER.formatter[opts.pattern].getPatternValue.call(this, opts, optIdx, e, elem.value);\n } else {\n newValue = beforeValue\n }\n\n if (newValue != beforeValue) {\n opts.$input.val(newValue).trigger(\"change\");\n setSelectionRange(elem, elemFocusPosition + newValue.length - beforeValue.length);\n }\n },\n 'blur': function (opts, optIdx, e, _force) {\n var elem = opts.$input.get(0),\n beforeValue,\n newValue\n ;\n\n opts.$input.removeData(\"__originValue__\");\n\n beforeValue = elem.value;\n if (opts.pattern in FORMATTER.formatter) {\n newValue = FORMATTER.formatter[opts.pattern].getPatternValue.call(this, opts, optIdx, e, elem.value, 'blur');\n } else {\n newValue = beforeValue\n }\n\n if (_force) {\n opts.$input.val(newValue);\n } else {\n if (newValue != beforeValue) {\n opts.$input.val(newValue).trigger(\"change\");\n }\n }\n }\n },\n bindFormatterTarget = function (opts, optIdx) {\n\n if (!opts.pattern) {\n if (opts.$target.get(0).tagName == \"INPUT\") {\n opts.pattern = opts.$target\n .attr('data-ax5formatter');\n }\n else {\n opts.pattern = opts.$target\n .find('input[type=\"text\"]')\n .attr('data-ax5formatter');\n }\n if (!opts.pattern) {\n console.log(ax5.info.getError(\"ax5formatter\", \"501\", \"bind\"));\n console.log(opts.target);\n return this;\n }\n }\n\n var re = /[^\\(^\\))]+/gi,\n matched = opts.pattern.match(re);\n\n opts.pattern = matched[0];\n opts.patternArgument = matched[1] || \"\";\n\n // 함수타입\n if (opts.pattern in FORMATTER.formatter) {\n opts.enterableKeyCodes = FORMATTER.formatter[opts.pattern].getEnterableKeyCodes.call(this, opts, optIdx);\n }\n\n opts.$input\n .unbind('focus.ax5formatter')\n .bind('focus.ax5formatter', formatterEvent.focus.bind(this, this.queue[optIdx], optIdx));\n\n opts.$input\n .unbind('keydown.ax5formatter')\n .bind('keydown.ax5formatter', formatterEvent.keydown.bind(this, this.queue[optIdx], optIdx));\n\n opts.$input\n .unbind('keyup.ax5formatter')\n .bind('keyup.ax5formatter', formatterEvent.keyup.bind(this, this.queue[optIdx], optIdx));\n\n opts.$input\n .unbind('blur.ax5formatter')\n .bind('blur.ax5formatter', formatterEvent.blur.bind(this, this.queue[optIdx], optIdx));\n\n formatterEvent.blur.call(this, this.queue[optIdx], optIdx);\n\n return this;\n\n },\n getQueIdx = function (boundID) {\n if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-formatter\");\n }\n /*\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5formatter\", \"402\", \"getQueIdx\"));\n return;\n }\n */\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n };\n\n /**\n * Preferences of formatter UI\n * @method ax5formatter.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5.ui.formatter}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n\n };\n\n this.bind = function (opts) {\n var\n formatterConfig = {},\n optIdx;\n\n jQuery.extend(true, formatterConfig, cfg);\n if (opts) jQuery.extend(true, formatterConfig, opts);\n opts = formatterConfig;\n\n if (!opts.target) {\n console.log(ax5.info.getError(\"ax5formatter\", \"401\", \"bind\"));\n return this;\n }\n opts.$target = jQuery(opts.target);\n\n if (opts.$target.get(0).tagName == \"INPUT\") {\n opts.$input = opts.$target;\n }\n else {\n opts.$input = opts.$target.find('input[type=\"text\"]');\n if (opts.$input.length > 1) {\n opts.$input.each(function () {\n opts.target = this;\n self.bind(opts);\n });\n return this;\n }\n }\n\n opts.$input = (opts.$target.get(0).tagName == \"INPUT\") ? opts.$target : opts.$target.find('input[type=\"text\"]');\n if (!opts.id) opts.id = opts.$input.data(\"ax5-formatter\");\n\n if (!opts.id) {\n opts.id = 'ax5-formatter-' + ax5.getGuid();\n opts.$input.data(\"ax5-formatter\", opts.id);\n }\n optIdx = U.search(this.queue, function () {\n return this.id == opts.id;\n });\n\n if (optIdx === -1) {\n this.queue.push(opts);\n bindFormatterTarget.call(this, this.queue[this.queue.length - 1], this.queue.length - 1);\n }\n else {\n this.queue[optIdx] = opts;\n bindFormatterTarget.call(this, this.queue[optIdx], optIdx);\n }\n\n return this;\n };\n\n /**\n * formatter value 를 다시 적용합니다.\n * @method ax5formatter.formatting\n * @returns {ax5formatter}\n * @example\n * ```js\n * $('[data-ax5formatter=\"time\"]').ax5formatter(\"formatting\"); // 하나만\n * $('[data-ax5formatter]').ax5formatter(\"formatting\"); // 모두\n * ```\n */\n this.formatting = function (boundID) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n var i = this.queue.length;\n while (i--) {\n formatterEvent.blur.call(this, this.queue[i], i, null, true);\n }\n } else {\n formatterEvent.blur.call(this, this.queue[queIdx], queIdx, null, true);\n }\n return this;\n };\n\n this.unbind = function () {\n// 구현해야함.\n };\n\n // 클래스 생성자\n this.main = (function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }).apply(this, arguments);\n };\n return ax5formatter;\n })());\n\n FORMATTER = ax5.ui.formatter;\n})();\n\nax5.ui.formatter_instance = new ax5.ui.formatter();\n\njQuery.fn.ax5formatter = (function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"formatting\":\n return ax5.ui.formatter_instance.formatting(this);\n break;\n\n case \"unbind\":\n return ax5.ui.formatter_instance.unbind(this);\n break;\n\n default:\n return this;\n }\n }\n else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.formatter_instance.bind(config);\n });\n }\n return this;\n }\n})();\n","// ax5.ui.formatter.formatter\n(function () {\n\n var FORMATTER = ax5.ui.formatter;\n var U = ax5.util;\n var ctrlKeys = {\n \"18\": \"KEY_ALT\",\n \"8\": \"KEY_BACKSPACE\",\n \"17\": \"KEY_CONTROL\",\n \"46\": \"KEY_DELETE\",\n \"40\": \"KEY_DOWN\",\n \"35\": \"KEY_END\",\n \"187\": \"KEY_EQUAL\",\n \"27\": \"KEY_ESC\",\n \"36\": \"KEY_HOME\",\n \"45\": \"KEY_INSERT\",\n \"37\": \"KEY_LEFT\",\n \"189\": \"KEY_MINUS\",\n \"34\": \"KEY_PAGEDOWN\",\n \"33\": \"KEY_PAGEUP\",\n // \"190\": \"KEY_PERIOD\",\n \"13\": \"KEY_RETURN\",\n \"39\": \"KEY_RIGHT\",\n \"16\": \"KEY_SHIFT\",\n // \"32\": \"KEY_SPACE\",\n \"9\": \"KEY_TAB\",\n \"38\": \"KEY_UP\",\n \"91\": \"KEY_WINDOW\"\n //\"107\" : \"NUMPAD_ADD\",\n //\"194\" : \"NUMPAD_COMMA\",\n //\"110\" : \"NUMPAD_DECIMAL\",\n //\"111\" : \"NUMPAD_DIVIDE\",\n //\"12\" : \"NUMPAD_EQUAL\",\n //\"106\" : \"NUMPAD_MULTIPLY\",\n //\"109\" : \"NUMPAD_SUBTRACT\"\n };\n var numKeys = {\n '48': 1, '49': 1, '50': 1, '51': 1, '52': 1, '53': 1, '54': 1, '55': 1, '56': 1, '57': 1,\n '96': 1, '97': 1, '98': 1, '99': 1, '100': 1, '101': 1, '102': 1, '103': 1, '104': 1, '105': 1\n };\n var pattern_money = {\n getEnterableKeyCodes: function (_opts) {\n var enterableKeyCodes = {\n '188': ','\n };\n if (_opts.patternArgument == \"int\") {\n // 소수점 입력 안됨\n }\n else {\n enterableKeyCodes['190'] = \".\"; // 소수점 입력 허용\n }\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function (_opts, optIdx, e, val, eType) {\n val = val.replace(/[^0-9^\\.^\\-]/g, \"\");\n var regExpPattern = new RegExp('([0-9])([0-9][0-9][0-9][,.])'),\n arrNumber = val.split('.'),\n returnValue;\n\n arrNumber[0] += '.';\n\n do {\n arrNumber[0] = arrNumber[0].replace(regExpPattern, '$1,$2');\n } while (regExpPattern.test(arrNumber[0]));\n\n if (arrNumber.length > 1) {\n if (U.isNumber(_opts.maxRound)) {\n returnValue = arrNumber[0] + U.left(arrNumber[1], _opts.maxRound);\n }\n else {\n returnValue = arrNumber.join('');\n }\n }\n else {\n returnValue = arrNumber[0].split('.')[0];\n }\n\n return returnValue;\n }\n };\n\n var pattern_number = {\n getEnterableKeyCodes: function (_opts) {\n var enterableKeyCodes = {\n '190': '.'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function (_opts, optIdx, e, val, eType) {\n val = val.replace(/[^0-9^\\.^\\-]/g, \"\");\n var arrNumber = val.split('.'),\n returnValue\n ;\n\n if (arrNumber.length > 1) {\n if (U.isNumber(_opts.maxRound)) {\n returnValue = arrNumber[0] + U.left(arrNumber[1], _opts.maxRound);\n }\n else {\n returnValue = arrNumber.join('');\n }\n }\n else {\n returnValue = arrNumber[0].split('.')[0];\n }\n\n return returnValue;\n }\n };\n\n var pattern_date = {\n getEnterableKeyCodes: function (_opts) {\n var enterableKeyCodes = {\n '189': '-', '191': '/'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function (_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\");\n if (val == \"\") return val;\n var regExpPattern = /^([0-9]{4})\\-?([0-9]{1,2})?\\-?([0-9]{1,2})?.*$/;\n\n if (_opts.patternArgument == \"time\") {\n regExpPattern = /^([0-9]{4})\\-?([0-9]{1,2})?\\-?([0-9]{1,2})? ?([0-9]{1,2})?:?([0-9]{1,2})?:?([0-9]{1,2})?.*$/;\n }\n\n var matchedPattern = val.match(regExpPattern),\n returnValue = \"\",\n inspectValue = function (val, format, inspect, data) {\n var _val = {\n 'Y': function (v) {\n if (typeof v == \"undefined\") v = TODAY.getFullYear();\n if (v == '' || v == '0000') v = TODAY.getFullYear();\n return (v.length < 4) ? U.setDigit(v, 4) : v;\n },\n 'M': function (v) {\n if (typeof v == \"undefined\") v = TODAY.getMonth() + 1;\n return v > 12 ? 12 : v == 0 ? '01' : U.setDigit(v, 2);\n },\n 'D': function (v) {\n if (typeof v == \"undefined\") v = TODAY.getDate() + 1;\n var dLen = U.daysOfMonth(data[1], data[2] - 1);\n return v > dLen ? dLen : v == 0 ? '01' : U.setDigit(v, 2);\n },\n 'h': function (v) {\n if (!v) v = 0;\n return v > 23 ? 23 : U.setDigit(v, 2);\n },\n 'm': function (v) {\n if (!v) v = 0;\n return v > 59 ? 59 : U.setDigit(v, 2);\n },\n 's': function (v) {\n if (!v) v = 0;\n return v > 59 ? 59 : U.setDigit(v, 2);\n }\n };\n return (inspect) ? _val[format](val) : val;\n };\n\n returnValue = val.replace(regExpPattern, function (a, b) {\n var nval = [inspectValue(arguments[1], \"Y\", eType)];\n if (arguments[2] || eType) nval.push('-' + inspectValue(arguments[2], \"M\", eType));\n if (arguments[3] || eType) nval.push('-' + inspectValue(arguments[3], \"D\", eType, arguments));\n if (_opts.patternArgument == \"time\") {\n if (arguments[4] || eType) nval.push(' ' + inspectValue(arguments[4], \"h\", eType));\n if (arguments[5] || eType) nval.push(':' + inspectValue(arguments[5], \"m\", eType));\n if (arguments[6] || eType) nval.push(':' + inspectValue(arguments[6], \"s\", eType));\n }\n return nval.join('');\n });\n\n if (eType == 'blur' && !matchedPattern) {\n returnValue = (function () {\n var nval = [inspectValue(returnValue, \"Y\", eType)];\n nval.push('-' + inspectValue(0, \"M\", eType));\n nval.push('-' + inspectValue(0, \"D\", eType, arguments));\n if (_opts.patternArgument == \"time\") {\n nval.push(' ' + inspectValue(0, \"h\", eType));\n nval.push(':' + inspectValue(0, \"m\", eType));\n nval.push(':' + inspectValue(0, \"s\", eType));\n }\n return nval.join('');\n })();\n }\n else if (!matchedPattern) returnValue = (returnValue.length > 4) ? U.left(returnValue, 4) : returnValue;\n\n return returnValue;\n }\n };\n\n var pattern_time = {\n getEnterableKeyCodes: function (_opts) {\n var enterableKeyCodes = {\n '186': ':'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function (_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\");\n var regExpPattern = /^([0-9]{1,2})?:?([0-9]{1,2})?:?([0-9]{1,2})?.*$/;\n\n var matchedPattern = val.match(regExpPattern),\n returnValue = val.replace(regExpPattern, function (a, b) {\n var nval = [arguments[1]];\n if (arguments[2]) nval.push(':' + arguments[2]);\n if (arguments[3]) nval.push(':' + arguments[3]);\n return nval.join('');\n });\n\n if (!matchedPattern) returnValue = (returnValue.length > 2) ? U.left(returnValue, 2) : returnValue;\n\n return returnValue;\n }\n };\n\n var pattern_bizno = {\n getEnterableKeyCodes: function (_opts) {\n var enterableKeyCodes = {\n '189': '-'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function (_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\");\n var regExpPattern = /^([0-9]{3})\\-?([0-9]{1,2})?\\-?([0-9]{1,5})?.*$/,\n returnValue = val.replace(regExpPattern, function (a, b) {\n var nval = [arguments[1]];\n if (arguments[2]) nval.push(arguments[2]);\n if (arguments[3]) nval.push(arguments[3]);\n return nval.join(\"-\");\n });\n\n return returnValue;\n }\n };\n\n var pattern_phone = {\n getEnterableKeyCodes: function (_opts) {\n var enterableKeyCodes = {\n '189': '-', '188': ','\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function (_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\");\n var regExpPattern3 = /^([0-9]{3})\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?/;\n if (val.substr(0, 2) == \"02\") {\n regExpPattern3 = /^([0-9]{2})\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?\\-?([0-9]{1,4})?/;\n }\n\n var returnValue = val.replace(regExpPattern3, function (a, b) {\n var nval = [arguments[1]];\n if (arguments[2]) nval.push(arguments[2]);\n if (arguments[3]) nval.push(arguments[3]);\n if (arguments[4]) nval.push(arguments[4]);\n if (arguments[5]) nval.push(arguments[5]);\n return nval.join(\"-\");\n });\n return returnValue;\n }\n };\n\n var pattern_credit = {\n getEnterableKeyCodes: function (_opts) {\n var enterableKeyCodes = {\n '189': '-'\n };\n return jQuery.extend(enterableKeyCodes, FORMATTER.formatter.ctrlKeys, FORMATTER.formatter.numKeys);\n },\n getPatternValue: function (_opts, optIdx, e, val, eType) {\n val = val.replace(/\\D/g, \"\").substring(0, 16);\n\n var regExpPattern3 = /^([0-9]{4})\\-?([0-9]{4})?\\-?([0-9]{4})?\\-?([0-9]{4})?/,\n returnValue = val.replace(regExpPattern3, function (a, b) {\n var nval = [arguments[1]];\n if (arguments[2]) nval.push(arguments[2]);\n if (arguments[3]) nval.push(arguments[3]);\n if (arguments[4]) nval.push(arguments[4]);\n return nval.join(\"-\");\n });\n return returnValue;\n }\n };\n\n var pattern_custom = {\n getEnterableKeyCodes: function (_opts) {\n if (_opts.getEnterableKeyCodes) {\n return _opts.getEnterableKeyCodes.call(_opts, {$input: _opts.$input});\n }\n else {\n return null;\n }\n },\n getPatternValue: function (_opts, optIdx, e, val, eType) {\n if (_opts.getPatternValue) {\n return _opts.getPatternValue.call(_opts, {event: e, $input: _opts.$input, value: val});\n }\n }\n };\n\n FORMATTER.formatter = {\n ctrlKeys: ctrlKeys,\n numKeys: numKeys,\n money: pattern_money,\n number: pattern_number,\n date: pattern_date,\n time: pattern_time,\n bizno: pattern_bizno,\n phone: pattern_phone,\n credit: pattern_credit,\n custom: pattern_custom\n };\n\n})();","// ax5.ui.menu\n(function () {\n var UI = ax5.ui;\n var U = ax5.util;\n var MENU;\n\n UI.addClass({\n className: \"menu\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5.ui.menu\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var menu = new ax5.ui.menu({\n * theme: 'primary',\n * iconWidth: 20,\n * acceleratorWidth: 100,\n * itemClickAndClose: false,\n * icons: {\n * 'arrow': ''\n * },\n * columnKeys: {\n * label: 'name',\n * items: 'chidren'\n * },\n * items: [\n * {\n * icon: '',\n * name: \"Menu Parent 0\",\n * chidren: [\n * {\n * check: {\n * type: 'checkbox',\n * name: 'A',\n * value: '0',\n * checked: false\n * },\n * name: \"Menu Z\",\n * data: {},\n * role: \"\",\n * accelerator: \"CmdOrCtrl+Z\"\n * },\n * {\n * check: {\n * type: 'checkbox',\n * name: 'A',\n * value: '1',\n * checked: true\n * },\n * name: \"Menu A\",\n * data: {},\n * role: \"\"\n * }\n * ],\n * filterType: \"A\"\n * },\n * {\n * divide: true,\n * filterType: \"A\"\n * },\n * {\n * icon: '',\n * name: \"Menu Parent 1\",\n * chidren: [\n * {\n * name: \"Menu Z\",\n * data: {},\n * role: \"\",\n * chidren: [\n * {\n * name: \"Menu Z\",\n * data: {},\n * role: \"\"\n * },\n * {\n * name: \"Menu A\",\n * data: {},\n * role: \"\"\n * }\n * ]\n * },\n * {\n * name: \"Menu A\",\n * data: {},\n * role: \"\"\n * }\n * ],\n * filterType: \"A\"\n * },\n * {\n * check: {\n * type: 'radio',\n * name: 'radioName',\n * value: '1',\n * checked: false\n * },\n * icon: '',\n * name: \"Menu Parent 2\"\n * },\n * {\n * check: {\n * type: 'radio',\n * name: 'radioName',\n * value: '2',\n * checked: false\n * },\n * name: \"Menu Parent 3\"\n * },\n * {\n * check: {\n * type: 'radio',\n * name: 'radioName',\n * value: '3',\n * checked: false\n * },\n * name: \"Menu Parent 4\"\n * },\n * {divide: true},\n * {\n * html: function () {\n * return '' +\n * ' ' +\n * '' +\n * '
';\n * }\n * }\n * ]\n * });\n * ```\n */\n var ax5menu = function () {\n var\n self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: \"default\",\n iconWidth: 22,\n acceleratorWidth: 100,\n menuBodyPadding: 5,\n //direction: \"top\", // top|bottom\n offset: {left: 0, top: 0},\n position: \"fixed\",\n animateTime: 250,\n items: [],\n itemClickAndClose: true,\n columnKeys: {\n label: 'label',\n items: 'items'\n }\n };\n\n this.openTimer = null;\n this.closeTimer = null;\n this.queue = [];\n this.menuBar = {};\n this.state = undefined;\n\n cfg = this.config;\n\n var\n appEventAttach = function (active) {\n if (active) {\n jQuery(document).unbind(\"click.ax5menu-\" + this.menuId).bind(\"click.ax5menu-\" + this.menuId, clickItem.bind(this));\n jQuery(window).unbind(\"keydown.ax5menu-\" + this.menuId).bind(\"keydown.ax5menu-\" + this.menuId, function (e) {\n if (e.which == ax5.info.eventKeys.ESC) {\n self.close();\n }\n });\n jQuery(window).unbind(\"resize.ax5menu-\" + this.menuId).bind(\"resize.ax5menu-\" + this.menuId, function (e) {\n self.close();\n });\n }\n else {\n jQuery(document).unbind(\"click.ax5menu-\" + this.menuId);\n jQuery(window).unbind(\"keydown.ax5menu-\" + this.menuId);\n jQuery(window).unbind(\"resize.ax5menu-\" + this.menuId);\n }\n },\n onStateChanged = function (opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n self.state = that.state;\n opts = null;\n that = null;\n return true;\n },\n onLoad = function (that) {\n if (this.onLoad) {\n this.onLoad.call(that, that);\n }\n\n that = null;\n return true;\n },\n popup = function (opt, items, depth, path) {\n var\n data = opt,\n activeMenu,\n removed\n ;\n\n data.theme = opt.theme || cfg.theme;\n data.cfg = {\n icons: jQuery.extend({}, cfg.icons),\n iconWidth: opt.iconWidth || cfg.iconWidth,\n acceleratorWidth: opt.acceleratorWidth || cfg.acceleratorWidth\n };\n\n items.forEach(function (n) {\n if (n.html || n.divide) {\n n['@isMenu'] = false;\n if (n.html) {\n n['@html'] = n.html.call({\n item: n,\n config: cfg,\n opt: opt\n });\n }\n }\n else {\n n['@isMenu'] = true;\n }\n });\n\n data[cfg.columnKeys.items] = items;\n data['@depth'] = depth;\n data['@path'] = path || \"root\";\n data['@hasChild'] = function () {\n return this[cfg.columnKeys.items] && this[cfg.columnKeys.items].length > 0;\n };\n activeMenu = jQuery(MENU.tmpl.get.call(this, \"tmpl\", data, cfg.columnKeys));\n jQuery(document.body).append(activeMenu);\n\n // remove queue\n\n removed = this.queue.splice(depth);\n removed.forEach(function (n) {\n n.$target.remove();\n });\n\n this.queue.push({\n '$target': activeMenu,\n 'data': jQuery.extend({}, data)\n });\n\n activeMenu.find('[data-menu-item-index]').bind(\"mouseover\", function () {\n var\n depth = this.getAttribute(\"data-menu-item-depth\"),\n index = this.getAttribute(\"data-menu-item-index\"),\n path = this.getAttribute(\"data-menu-item-path\"),\n $this,\n offset,\n scrollTop,\n childOpt,\n _items,\n _activeMenu;\n\n if (depth != null && typeof depth != \"undefined\") {\n _items = self.queue[depth].data[cfg.columnKeys.items][index][cfg.columnKeys.items];\n _activeMenu = self.queue[depth].$target;\n _activeMenu.find('[data-menu-item-index]').removeClass(\"hover\");\n jQuery(this).addClass(\"hover\");\n\n if (_activeMenu.attr(\"data-selected-menu-item-index\") != index) {\n _activeMenu.attr(\"data-selected-menu-item-index\", index);\n\n if (_items && _items.length > 0) {\n\n $this = jQuery(this);\n offset = $this.offset();\n scrollTop = (cfg.position == \"fixed\" ? jQuery(document).scrollTop() : 0);\n childOpt = {\n '@parent': {\n left: offset.left,\n top: offset.top,\n width: $this.outerWidth(),\n height: $this.outerHeight()\n },\n left: offset.left + $this.outerWidth() - cfg.menuBodyPadding,\n top: offset.top - cfg.menuBodyPadding - 1 - scrollTop\n };\n\n childOpt = jQuery.extend(true, opt, childOpt);\n popup.call(self, childOpt, _items, (Number(depth) + 1), path);\n }\n else {\n self.queue.splice(Number(depth) + 1).forEach(function (n) {\n n.$target.remove();\n });\n }\n }\n }\n\n depth = null;\n index = null;\n path = null;\n $this = null;\n offset = null;\n scrollTop = null;\n childOpt = null;\n _items = null;\n _activeMenu = null;\n });\n\n // mouse out\n activeMenu.find('[data-menu-item-index]').bind(\"mouseout\", function () {\n var depth = this.getAttribute(\"data-menu-item-depth\"),\n index = this.getAttribute(\"data-menu-item-index\"),\n path = this.getAttribute(\"data-menu-item-path\"),\n _items;\n\n _items = self.queue[depth].data[cfg.columnKeys.items][index][cfg.columnKeys.items];\n if (_items && _items.length > 0) {\n\n }else{\n jQuery(this).removeClass(\"hover\");\n }\n });\n\n // is Root\n if (depth == 0) {\n if (data.direction) activeMenu.addClass(\"direction-\" + data.direction);\n onStateChanged.call(this, null, {\n self: this,\n items: items,\n parent: (function (path) {\n if (!path) return false;\n var item = null;\n try {\n item = (Function(\"\", \"return this.config.items[\" + path.substring(5).replace(/\\./g, '].items[') + \"];\")).call(self);\n } catch (e) {\n\n }\n return item;\n })(data['@path']),\n state: \"popup\"\n });\n }\n\n align.call(this, activeMenu, data);\n onLoad.call(this, {\n self: this,\n items: items,\n element: activeMenu.get(0)\n });\n\n data = null;\n activeMenu = null;\n removed = null;\n opt = null;\n items = null;\n depth = null;\n path = null;\n\n return this;\n },\n clickItem = function (e, target, item) {\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-menu-item-index\")) {\n return true;\n }\n });\n if (target) {\n item = (function (path) {\n if (!path) return false;\n var item;\n try {\n item = (Function(\"\", \"return this.config.items[\" + path.substring(5).replace(/\\./g, '].' + cfg.columnKeys.items + '[') + \"];\")).call(self);\n } catch (e) {\n console.log(ax5.info.getError(\"ax5menu\", \"501\", \"menuItemClick\"));\n }\n\n try {\n return item;\n }\n finally {\n item = null;\n }\n })(target.getAttribute(\"data-menu-item-path\"));\n\n if (!item) return this;\n\n if (item.check) {\n (function (items) {\n var setValue = {\n 'checkbox': function (value) {\n this.checked = !value;\n },\n 'radio': function (value) {\n var name = this.name;\n items.forEach(function (n) {\n if (n.check && n.check.type === 'radio' && n.check.name == name) {\n n.check.checked = false;\n }\n });\n this.checked = !value;\n }\n };\n if (setValue[this.type]) setValue[this.type].call(this, this.checked);\n setValue = null;\n }).call(item.check, cfg.items);\n\n if (!cfg.itemClickAndClose) {\n self.queue.forEach(function (n) {\n n.$target.find('[data-menu-item-index]').each(function () {\n var item = n.data[cfg.columnKeys.items][this.getAttribute(\"data-menu-item-index\")];\n if (item.check) {\n jQuery(this).find(\".item-checkbox-wrap\").attr(\"data-item-checked\", item.check.checked);\n }\n });\n });\n }\n }\n\n if (self.onClick) {\n self.onClick.call(item, item);\n }\n if ((!item[cfg.columnKeys.items] || item[cfg.columnKeys.items].length == 0) && cfg.itemClickAndClose) self.close();\n }\n else {\n self.close();\n }\n\n target = null;\n item = null;\n return this;\n },\n align = function (activeMenu, data) {\n //console.log(data['@parent']);\n var\n $window = jQuery(window),\n $document = jQuery(document),\n wh = (cfg.position == \"fixed\") ? $window.height() : $document.height(),\n ww = $window.width(),\n h = activeMenu.outerHeight(),\n w = activeMenu.outerWidth(),\n l = data.left,\n t = data.top,\n position = cfg.position || \"fixed\";\n\n if (l + w > ww) {\n if (data['@parent']) {\n l = data['@parent'].left - w + cfg.menuBodyPadding;\n }\n else {\n l = ww - w;\n }\n }\n\n if (t + h > wh) {\n t = wh - h;\n }\n\n activeMenu.css({left: l, top: t, position: position});\n\n activeMenu = null;\n data = null;\n $window = null;\n $document = null;\n wh = null;\n ww = null;\n h = null;\n w = null;\n l = null;\n t = null;\n position = null;\n return this;\n };\n\n /// private end\n\n this.init = function () {\n self.menuId = ax5.getGuid();\n\n /**\n * config에 선언된 이벤트 함수들을 this로 이동시켜 주어 나중에 인스턴스.on... 으로 처리 가능 하도록 변경\n */\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n this.onLoad = cfg.onLoad;\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"init\"\n });\n };\n\n /**\n * @method ax5.ui.menu.popup\n * @param {Event|Object} e - Event or Object\n * @param {Object} [opt]\n * @param {String} [opt.theme]\n * @param {Function} [opt.filter]\n * @returns {ax5.ui.menu} this\n */\n this.popup = (function () {\n\n var getOption = {\n 'event': function (e, opt) {\n //var xOffset = Math.max(document.documentElement.scrollLeft, document.body.scrollLeft);\n //var yOffset = Math.max(document.documentElement.scrollTop, document.body.scrollTop);\n //console.log(e.pageY);\n\n e = {\n left: e.clientX,\n top: (cfg.position == \"fixed\") ? e.clientY : e.pageY,\n width: cfg.width,\n theme: cfg.theme\n };\n\n if (cfg.offset) {\n if (cfg.offset.left) e.left += cfg.offset.left;\n if (cfg.offset.top) e.top += cfg.offset.top;\n }\n opt = jQuery.extend(true, e, opt);\n\n try {\n return opt;\n }\n finally {\n e = null;\n //opt = null;\n }\n },\n 'object': function (e, opt) {\n e = {\n left: e.left,\n top: e.top,\n width: e.width || cfg.width,\n theme: e.theme || cfg.theme\n };\n\n if (cfg.offset) {\n if (cfg.offset.left) e.left += cfg.offset.left;\n if (cfg.offset.top) e.top += cfg.offset.top;\n }\n\n opt = jQuery.extend(true, e, opt);\n\n try {\n return opt;\n }\n finally {\n e = null;\n //opt = null;\n }\n }\n };\n var updateTheme = function (theme) {\n if (theme) cfg.theme = theme;\n };\n\n return function (e, opt) {\n\n if (!e) return this;\n opt = getOption[((typeof e.clientX == \"undefined\") ? \"object\" : \"event\")].call(this, e, opt);\n updateTheme(opt.theme);\n\n var items = [].concat(cfg.items);\n if (opt.filter) {\n var filteringItem = function (_items) {\n var arr = [];\n _items.forEach(function (n) {\n if (n.items && n.items.length > 0) {\n n.items = filteringItem(n.items);\n }\n if (opt.filter.call(n)) {\n arr.push(n);\n }\n });\n return arr;\n };\n items = filteringItem(items);\n }\n\n if (items.length) {\n popup.call(this, opt, items, 0); // 0 is seq of queue\n appEventAttach.call(this, true); // 이벤트 연결\n }\n\n e = null;\n //opt = null;\n return this;\n }\n })();\n\n /**\n * @method ax5.ui.menu.attach\n * @param {Element|jQueryObject} el\n * @returns {ax5.ui.menu} this\n */\n this.attach = (function () {\n\n var getOption = {\n 'object': function (e, opt) {\n e = {\n left: e.left,\n top: e.top,\n width: e.width || cfg.width,\n theme: e.theme || cfg.theme,\n direction: e.direction || cfg.direction\n };\n opt = jQuery.extend(true, opt, e);\n\n try {\n return opt;\n }\n finally {\n e = null;\n opt = null;\n }\n }\n };\n\n var popUpChildMenu = function (target, opt, eType) {\n var\n $target = jQuery(target),\n offset = $target.offset(),\n height = $target.outerHeight(),\n index = Number(target.getAttribute(\"data-menu-item-index\")),\n scrollTop = (cfg.position == \"fixed\") ? jQuery(document).scrollTop() : 0;\n\n\n if (cfg.items && cfg.items[index][cfg.columnKeys.items] && cfg.items[index][cfg.columnKeys.items].length) {\n\n if (self.menuBar.openedIndex == index) {\n if (eType == \"click\") self.close();\n return false;\n }\n\n self.menuBar.target.find('[data-menu-item-index]').removeClass(\"hover\");\n self.menuBar.opened = true;\n self.menuBar.openedIndex = index;\n\n $target.attr(\"data-menu-item-opened\", \"true\");\n $target.addClass(\"hover\");\n\n if (cfg.offset) {\n if (cfg.offset.left) offset.left += cfg.offset.left;\n if (cfg.offset.top) offset.top += cfg.offset.top;\n }\n\n opt = getOption[\"object\"].call(this, {left: offset.left, top: offset.top + height - scrollTop}, opt);\n\n popup.call(self, opt, cfg.items[index][cfg.columnKeys.items], 0, 'root.' + target.getAttribute(\"data-menu-item-index\")); // 0 is seq of queue\n appEventAttach.call(self, true); // 이벤트 연결\n }\n\n target = null;\n opt = null;\n $target = null;\n offset = null;\n height = null;\n index = null;\n scrollTop = null;\n };\n var clickParentMenu = function (target, opt, eType) {\n var\n $target = jQuery(target),\n offset = $target.offset(),\n height = $target.outerHeight(),\n index = Number(target.getAttribute(\"data-menu-item-index\")),\n scrollTop = (cfg.position == \"fixed\") ? jQuery(document).scrollTop() : 0;\n if (cfg.items && (!cfg.items[index][cfg.columnKeys.items] || cfg.items[index][cfg.columnKeys.items].length == 0)) {\n if (self.onClick) {\n self.onClick.call(cfg.items[index], cfg.items[index]);\n }\n }\n };\n\n return function (el, opt) {\n var\n data = {},\n items = cfg.items,\n activeMenu;\n\n if (typeof opt === \"undefined\") opt = {};\n\n data.theme = opt.theme || cfg.theme;\n data.cfg = {\n icons: jQuery.extend({}, cfg.icons),\n iconWidth: opt.iconWidth || cfg.iconWidth,\n acceleratorWidth: opt.acceleratorWidth || cfg.acceleratorWidth\n };\n\n items.forEach(function (n) {\n if (n.html || n.divide) {\n n['@isMenu'] = false;\n if (n.html) {\n n['@html'] = n.html.call({\n item: n,\n config: cfg,\n opt: opt\n });\n }\n }\n else {\n n['@isMenu'] = true;\n }\n });\n\n data[cfg.columnKeys.items] = items;\n\n activeMenu = jQuery(MENU.tmpl.get.call(this, \"tmplMenubar\", data, cfg.columnKeys));\n self.menuBar = {\n target: jQuery(el),\n opened: false\n };\n self.menuBar.target.html(activeMenu);\n\n // click, mouseover\n self.menuBar.target.bind(\"click\", function (e) {\n if (!e) return this;\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-menu-item-index\")) {\n return true;\n }\n });\n if (target) {\n clickParentMenu(target, opt, \"click\");\n popUpChildMenu(target, opt, \"click\");\n }\n\n target = null;\n });\n self.menuBar.target.bind(\"mouseover\", function (e) {\n if (!self.menuBar.opened) return false;\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-menu-item-index\")) {\n return true;\n }\n });\n if (target) popUpChildMenu(target, opt, \"mouseover\");\n\n target = null;\n });\n\n el = null;\n opt = null;\n data = null;\n items = null;\n activeMenu = null;\n\n return this;\n }\n })();\n\n /**\n * @method ax5.ui.menu.close\n * @returns {ax5.ui.menu} this\n */\n this.close = function () {\n\n if (self.menuBar && self.menuBar.target) {\n self.menuBar.target.find('[data-menu-item-index]').removeClass(\"hover\");\n self.menuBar.opened = false;\n self.menuBar.openedIndex = null;\n }\n\n appEventAttach.call(this, false); // 이벤트 제거\n\n this.queue.forEach(function (n) {\n n.$target.remove();\n });\n this.queue = [];\n\n onStateChanged.call(this, null, {\n self: this,\n state: \"close\"\n });\n\n return this;\n };\n\n /**\n * @method ax5.ui.menu.getCheckValue\n * @returns {Object} statusCheckItem\n */\n this.getCheckValue = function () {\n var checkItems = {},\n collectItem = function (items) {\n var i = items.length;\n while (i--) {\n if (items[i].check && items[i].check.checked) {\n if (!checkItems[items[i].check.name]) checkItems[items[i].check.name] = items[i].check.value;\n else {\n if (U.isString(checkItems[items[i].check.name])) checkItems[items[i].check.name] = [checkItems[items[i].check.name]];\n checkItems[items[i].check.name].push(items[i].check.value);\n }\n }\n if (items[i].items && items[i].items.length > 0) collectItem(items[i].items);\n }\n };\n\n collectItem(cfg.items);\n\n try {\n return checkItems;\n }\n finally {\n checkItems = null;\n collectItem = null;\n }\n };\n\n // 클래스 생성자\n this.main = (function () {\n\n UI.menu_instance = UI.menu_instance || [];\n UI.menu_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }).apply(this, arguments);\n };\n return ax5menu;\n })());\n\n MENU = ax5.ui.menu;\n})();\n\n// todo : menu 드랍다운 아이콘 설정 기능 추가","// ax5.ui.menu.tmpl\n(function () {\n var MENU = ax5.ui.menu;\n \n var tmpl = function (columnKeys) {\n return `\n \n `;\n };\n var tmplMenubar = function (columnKeys) {\n return `\n \n `;\n };\n\n MENU.tmpl = {\n \"tmpl\" : tmpl,\n \"tmplMenubar\" : tmplMenubar,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(MENU.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();","// ax5.ui.select\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var SELECT;\n\n UI.addClass({\n className: \"select\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5select\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var options = [];\n * for (var i = 0; i < 20; i++) {\n * options.push({value: i, text: \"optionText\" + i});\n * }\n\n * var mySelect = new ax5.ui.select({\n * theme: \"danger\"\n * });\n\n * mySelect.bind({\n * theme: \"primary\",\n * target: $('[data-ax5select=\"select1\"]'),\n * options: options,\n * onChange: function () {\n * console.log(this);\n * },\n * onClose: function () {\n * console.log(this);\n * },\n * onStateChanged: function () {\n * console.log(this);\n * }\n * });\n * ```\n */\n var ax5select = function () {\n var\n self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 100,\n lang: {\n noSelected: '',\n noOptions: 'no options',\n loading: 'now loading..',\n multipleLabel: '\"{{label}}\"외 {{length}}건'\n },\n columnKeys: {\n optionValue: 'value',\n optionText: 'text',\n optionSelected: 'selected'\n }\n };\n this.queue = [];\n this.activeSelectOptionGroup = null;\n this.activeSelectQueueIndex = -1;\n this.openTimer = null;\n this.closeTimer = null;\n this.waitOptionsCallback = null;\n this.keyUpTimer = null;\n this.xvar = {};\n\n cfg = this.config;\n\n var $window = jQuery(window);\n var\n ctrlKeys = {\n \"18\": \"KEY_ALT\",\n \"8\": \"KEY_BACKSPACE\",\n \"17\": \"KEY_CONTROL\",\n \"46\": \"KEY_DELETE\",\n \"40\": \"KEY_DOWN\",\n \"35\": \"KEY_END\",\n \"187\": \"KEY_EQUAL\",\n \"27\": \"KEY_ESC\",\n \"36\": \"KEY_HOME\",\n \"45\": \"KEY_INSERT\",\n \"37\": \"KEY_LEFT\",\n \"189\": \"KEY_MINUS\",\n \"34\": \"KEY_PAGEDOWN\",\n \"33\": \"KEY_PAGEUP\",\n // \"190\": \"KEY_PERIOD\",\n \"13\": \"KEY_RETURN\",\n \"39\": \"KEY_RIGHT\",\n \"16\": \"KEY_SHIFT\",\n // \"32\": \"KEY_SPACE\",\n \"9\": \"KEY_TAB\",\n \"38\": \"KEY_UP\",\n \"91\": \"KEY_WINDOW\"\n //\"107\" : \"NUMPAD_ADD\",\n //\"194\" : \"NUMPAD_COMMA\",\n //\"110\" : \"NUMPAD_DECIMAL\",\n //\"111\" : \"NUMPAD_DIVIDE\",\n //\"12\" : \"NUMPAD_EQUAL\",\n //\"106\" : \"NUMPAD_MULTIPLY\",\n //\"109\" : \"NUMPAD_SUBTRACT\"\n },\n onStateChanged = function (item, that) {\n if (item && item.onStateChanged) {\n item.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n if (that.state == \"changeValue\") {\n if (item && item.onChange) {\n item.onChange.call(that, that);\n }\n else if (this.onChange) {\n this.onChange.call(that, that);\n }\n }\n\n item = null;\n that = null;\n return true;\n },\n alignSelectDisplay = function () {\n var i = this.queue.length, w;\n while (i--) {\n if (this.queue[i].$display) {\n w = Math.max(this.queue[i].$select.outerWidth(), U.number(this.queue[i].minWidth));\n this.queue[i].$display.css({\n \"min-width\": w\n });\n if (this.queue[i].reset) {\n this.queue[i].$display.find(\".addon-icon-reset\").css({\n \"line-height\": this.queue[i].$display.height() + \"px\"\n });\n }\n }\n }\n\n i = null;\n w = null;\n return this;\n },\n alignSelectOptionGroup = function (append) {\n if (!this.activeSelectOptionGroup) return this;\n\n var item = this.queue[this.activeSelectQueueIndex],\n pos = {}, positionMargin = 0,\n dim = {}, pickerDim = {},\n pickerDirection;\n\n if (append) jQuery(document.body).append(this.activeSelectOptionGroup);\n\n pos = item.$target.offset();\n dim = {\n width: item.$target.outerWidth(),\n height: item.$target.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), jQuery(document.body).width()),\n winHeight: Math.max($window.height(), jQuery(document.body).height()),\n width: this.activeSelectOptionGroup.outerWidth(),\n height: this.activeSelectOptionGroup.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n if (!item.direction || item.direction === \"\" || item.direction === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = item.direction;\n }\n // todo : 표현할 공간이 없다면..\n if (append) {\n this.activeSelectOptionGroup\n .addClass(\"direction-\" + pickerDirection);\n }\n this.activeSelectOptionGroup\n .css((function () {\n if (pickerDirection == \"top\") {\n if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n\n var newTop = pos.top + dim.height / 2 - pickerDim.height / 2;\n if (newTop + pickerDim.height + positionMargin > pickerDim.winHeight) {\n newTop = 0;\n }\n if(newTop < 0){\n newTop = 0;\n }\n\n return {\n left: pos.left,\n top: newTop,\n width: dim.width\n }\n }\n return {\n left: pos.left,\n top: pos.top + dim.height + 1,\n width: dim.width\n }\n }\n else if (pickerDirection == \"bottom\") {\n return {\n left: pos.left,\n top: pos.top - pickerDim.height - 1,\n width: dim.width\n }\n }\n }).call(this));\n },\n onBodyClick = function (e, target) {\n if (!this.activeSelectOptionGroup) return this;\n\n var\n item = this.queue[this.activeSelectQueueIndex],\n clickEl = \"display\"\n ;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-option-value\")) {\n clickEl = \"optionItem\";\n return true;\n }\n else if (item.$target.get(0) == target) {\n clickEl = \"display\";\n return true;\n }\n });\n\n if (!target) {\n this.close();\n return this;\n }\n else if (clickEl === \"optionItem\") {\n this.val(item.id, {\n index: {\n gindex: target.getAttribute(\"data-option-group-index\"),\n index: target.getAttribute(\"data-option-index\")\n }\n }, undefined, \"internal\");\n item.$select.trigger(\"change\");\n item.$display.focus();\n if (!item.multiple) this.close();\n }\n else {\n //open and display click\n //console.log(this.instanceId);\n }\n\n return this;\n },\n onBodyKeyup = function (e) {\n if (e.keyCode == ax5.info.eventKeys.ESC) {\n this.close();\n }\n else if (e.which == ax5.info.eventKeys.RETURN) {\n if (this.queue[this.activeSelectQueueIndex].optionFocusIndex > -1) { // 아이템에 포커스가 활성화 된 후, 마우스 이벤트 이면 무시\n var $option = this.activeSelectOptionGroup.find('[data-option-focus-index=\"' + this.queue[this.activeSelectQueueIndex].optionFocusIndex + '\"]');\n this.val(this.queue[this.activeSelectQueueIndex].id, {\n index: {\n gindex: $option.attr(\"data-option-group-index\"),\n index: $option.attr(\"data-option-index\")\n }\n }, undefined, \"internal\");\n this.queue[this.activeSelectQueueIndex].$select.trigger(\"change\");\n if (!this.queue[this.activeSelectQueueIndex].multiple) this.close();\n } else {\n this.close();\n }\n }\n },\n getLabel = function (queIdx) {\n var item = this.queue[queIdx];\n var labels = [];\n\n if (U.isArray(item.selected) && item.selected.length > 0) {\n item.selected.forEach(function (n) {\n if (n.selected) labels.push(n[item.columnKeys.optionText]);\n });\n }\n else {\n if (!item.multiple && item.options && item.options[0]) {\n if (item.options[0].optgroup) {\n labels[0] = item.options[0].options[0][item.columnKeys.optionText];\n }\n else {\n labels[0] = item.options[0][item.columnKeys.optionText];\n }\n }\n else {\n labels[0] = item.lang.noSelected;\n }\n }\n\n return (function () {\n if (item.multiple && labels.length > 1) {\n var data = {\n label: labels[0],\n length: labels.length - 1\n };\n return ax5.mustache.render(item.lang.multipleLabel, data);\n }\n else {\n return labels[0];\n }\n })();\n },\n syncLabel = function (queIdx) {\n this.queue[queIdx].$displayLabel\n .html(getLabel.call(this, queIdx));\n },\n focusWord = function (queIdx, searchWord) {\n var options = [], i = -1, l = this.queue[queIdx].indexedOptions.length - 1, n;\n if (searchWord) {\n while (l - i++) {\n n = this.queue[queIdx].indexedOptions[i];\n if (('' + n.value).toLowerCase() == searchWord.toLowerCase()) {\n options = [{'@findex': n['@findex'], optionsSort: 0}];\n break;\n } else {\n var sort = ('' + n.value).toLowerCase().search(searchWord.toLowerCase());\n if (sort > -1) {\n options.push({'@findex': n['@findex'], optionsSort: sort});\n if (options.length > 2) break;\n }\n sort = null;\n }\n }\n options.sort(function (a, b) {\n return a.optionsSort - b.optionsSort;\n });\n }\n if (options && options.length > 0) {\n focusMove.call(this, queIdx, undefined, options[0]['@findex']);\n }\n\n try {\n return options;\n } finally {\n options = null;\n i = null;\n l = null;\n n = null;\n }\n },\n focusMove = function (queIdx, direction, findex) {\n var _focusIndex,\n _prevFocusIndex,\n focusOptionEl,\n optionGroupScrollContainer;\n if (this.activeSelectOptionGroup && this.queue[queIdx].options && this.queue[queIdx].options.length > 0) {\n\n if (typeof findex !== \"undefined\") {\n _focusIndex = findex\n }\n else {\n _prevFocusIndex = (this.queue[queIdx].optionFocusIndex == -1) ? this.queue[queIdx].optionSelectedIndex || -1 : this.queue[queIdx].optionFocusIndex;\n if (_prevFocusIndex == -1) {\n _focusIndex = (direction > 0) ? 0 : this.queue[queIdx].optionItemLength - 1;\n }\n else {\n _focusIndex = _prevFocusIndex + direction;\n if (_focusIndex < 0) _focusIndex = 0;\n else if (_focusIndex > this.queue[queIdx].optionItemLength - 1) _focusIndex = this.queue[queIdx].optionItemLength - 1;\n }\n }\n\n this.queue[queIdx].optionFocusIndex = _focusIndex;\n\n this.activeSelectOptionGroup\n .find('[data-option-focus-index]')\n .removeClass(\"hover\");\n\n focusOptionEl = this.activeSelectOptionGroup\n .find('[data-option-focus-index=\"' + _focusIndex + '\"]')\n .addClass(\"hover\");\n\n optionGroupScrollContainer = this.activeSelectOptionGroup.find('[data-els=\"content\"]');\n\n let focusOptionElHeight = focusOptionEl.outerHeight(),\n optionGroupScrollContainerHeight = optionGroupScrollContainer.innerHeight(),\n optionGroupScrollContainerScrollTop = optionGroupScrollContainer.scrollTop(),\n focusOptionElTop = focusOptionEl.position().top + optionGroupScrollContainer.scrollTop();\n\n if (optionGroupScrollContainerHeight + optionGroupScrollContainerScrollTop < focusOptionElTop + focusOptionElHeight) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop + focusOptionElHeight - optionGroupScrollContainerHeight);\n }\n else if (optionGroupScrollContainerScrollTop > focusOptionElTop) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop);\n }\n // optionGroup scroll check\n }\n },\n bindSelectTarget = (function () {\n var focusWordCall = U.debounce(function (searchWord, queIdx) {\n focusWord.call(self, queIdx, searchWord);\n self.queue[queIdx].$displayInput.val('');\n }, 300);\n\n var selectEvent = {\n 'click': function (queIdx, e) {\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-selected-clear\")) {\n //clickEl = \"clear\";\n return true;\n }\n });\n\n if (target) {\n this.val(queIdx, {clear: true});\n }\n else {\n if (self.activeSelectQueueIndex == queIdx) {\n if (this.queue[queIdx].optionFocusIndex == -1) { // 아이템에 포커스가 활성화 된 후, 마우스 이벤트 이면 무시\n self.close();\n }\n }\n else {\n self.open(queIdx);\n U.stopEvent(e);\n }\n }\n },\n 'keyUp': function (queIdx, e) {\n if (e.which == ax5.info.eventKeys.SPACE) {\n selectEvent.click.call(this, queIdx, e);\n }\n else if (!ctrlKeys[e.which]) {\n // 사용자 입력이 뜸해지면 찾고 검색 값 제거...\n focusWordCall(this.queue[queIdx].$displayInput.val(), queIdx);\n }\n },\n 'keyDown': function (queIdx, e) {\n if (e.which == ax5.info.eventKeys.DOWN) {\n focusMove.call(this, queIdx, 1);\n U.stopEvent(e);\n }\n else if (e.which == ax5.info.eventKeys.UP) {\n focusMove.call(this, queIdx, -1);\n U.stopEvent(e);\n }\n },\n 'blur': function (queIdx, e) {\n\n },\n 'selectChange': function (queIdx, e) {\n this.val(queIdx, this.queue[queIdx].$select.val(), true);\n }\n };\n return function (queIdx) {\n var item = this.queue[queIdx];\n var data = {};\n item.selected = [];\n\n if (!item.$display) {\n /// 템플릿에 전달할 오브젝트 선언\n data.instanceId = this.instanceId;\n data.id = item.id;\n data.name = item.name;\n data.theme = item.theme;\n data.tabIndex = item.tabIndex;\n data.multiple = item.multiple;\n data.reset = item.reset;\n\n data.label = getLabel.call(this, queIdx);\n data.formSize = (function () {\n return (item.size) ? \"input-\" + item.size : \"\";\n })();\n\n item.$display = SELECT.tmpl.get.call(this, \"tmpl\", data);\n item.$displayLabel = item.$display.find('[data-ax5select-display=\"label\"]');\n\n if (item.$target.find(\"select\").get(0)) {\n item.$select = item.$target.find(\"select\");\n // select 속성만 변경\n item.$select\n .attr(\"tabindex\", \"-1\")\n .attr(\"class\", \"form-control \" + data.formSize);\n if (data.name) {\n item.$select.attr(\"name\", \"name\");\n }\n if (data.multiple) {\n item.$select.attr(\"multiple\", \"multiple\");\n }\n }\n else {\n item.$select = SELECT.tmpl.get.call(this, \"selectTmpl\", data);\n item.$target.append(item.$select);\n // select append\n }\n\n item.$target.append(item.$display);\n item.$displayInput = item.$display.find('[data-ax5select-display=\"input\"]'); // 사용자 입력값을 받기위한 숨음 입력필드\n item.options = syncSelectOptions.call(this, queIdx, item.options);\n\n alignSelectDisplay.call(this);\n\n item.$displayInput\n .unbind(\"blur.ax5select\")\n .bind(\"blur.ax5select\", selectEvent.blur.bind(this, queIdx))\n .unbind('keyup.ax5select')\n .bind('keyup.ax5select', selectEvent.keyUp.bind(this, queIdx))\n .unbind(\"keydown.ax5select\")\n .bind(\"keydown.ax5select\", selectEvent.keyDown.bind(this, queIdx));\n }\n else {\n item.$displayLabel\n .html(getLabel.call(this, queIdx));\n item.options = syncSelectOptions.call(this, queIdx, item.options);\n\n alignSelectDisplay.call(this);\n }\n\n item.$display\n .unbind('click.ax5select')\n .bind('click.ax5select', selectEvent.click.bind(this, queIdx))\n .unbind('keyup.ax5select')\n .bind('keyup.ax5select', selectEvent.keyUp.bind(this, queIdx));\n\n // select 태그에 대한 change 이벤트 감시\n item.$select\n .unbind('change.ax5select')\n .bind('change.ax5select', selectEvent.selectChange.bind(this, queIdx));\n\n data = null;\n item = null;\n queIdx = null;\n return this;\n };\n })(),\n syncSelectOptions = (function () {\n var setSelected = function (queIdx, O) {\n if (!O) {\n this.queue[queIdx].selected = [];\n }\n else {\n if (this.queue[queIdx].multiple) this.queue[queIdx].selected.push(jQuery.extend({}, O));\n else this.queue[queIdx].selected[0] = jQuery.extend({}, O);\n }\n };\n\n return function (queIdx, options) {\n var item = this.queue[queIdx];\n var po, elementOptions, newOptions, focusIndex = 0;\n setSelected.call(this, queIdx, false); // item.selected 초기화\n\n if (options) {\n item.options = options;\n item.indexedOptions = [];\n\n // select options 태그 생성\n po = [];\n item.options.forEach(function (O, OIndex) {\n if (O.optgroup) {\n // todo\n O['@gindex'] = OIndex;\n O.options.forEach(function (OO, OOIndex) {\n OO['@index'] = OOIndex;\n OO['@findex'] = focusIndex;\n po.push('');\n if (OO[item.columnKeys.optionSelected]) {\n setSelected.call(self, queIdx, OO);\n }\n\n item.indexedOptions.push({\n '@findex': focusIndex, value: OO[item.columnKeys.optionValue], text: OO[item.columnKeys.optionText]\n });\n focusIndex++;\n });\n }\n else {\n O['@index'] = OIndex;\n O['@findex'] = focusIndex;\n po.push('');\n if (O[item.columnKeys.optionSelected]) {\n setSelected.call(self, queIdx, O);\n }\n\n item.indexedOptions.push({\n '@findex': focusIndex, value: O[item.columnKeys.optionValue], text: O[item.columnKeys.optionText]\n });\n focusIndex++;\n }\n });\n\n item.optionItemLength = focusIndex;\n item.$select.html(po.join(''));\n }\n else {\n /// select > options 태그로 스크립트 options를 만들어주는 역할\n elementOptions = U.toArray(item.$select.get(0).options);\n // select option 스크립트 생성\n newOptions = [];\n elementOptions.forEach(function (O, OIndex) {\n var option = {};\n //if (O.value != \"\") {\n option[item.columnKeys.optionValue] = O.value;\n option[item.columnKeys.optionText] = O.text;\n option[item.columnKeys.optionSelected] = O.selected;\n option['@index'] = OIndex;\n option['@findex'] = OIndex;\n if (O.selected) setSelected.call(self, queIdx, option);\n newOptions.push(option);\n //}\n option = null;\n });\n item.options = newOptions;\n item.indexedOptions = newOptions;\n }\n\n if (!item.multiple && item.selected.length == 0 && item.options && item.options[0]) {\n if (item.options[0].optgroup) {\n item.options[0].options[0][item.columnKeys.optionSelected] = true;\n item.selected.push(jQuery.extend({}, item.options[0].options[0]));\n }\n else {\n item.options[0][item.columnKeys.optionSelected] = true;\n item.selected.push(jQuery.extend({}, item.options[0]));\n }\n }\n\n po = null;\n elementOptions = null;\n newOptions = null;\n return item.options;\n }\n })(),\n getQueIdx = function (boundID) {\n if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-ax5select-id\");\n }\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5select\", \"402\", \"getQueIdx\"));\n return;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n };\n /// private end\n\n /**\n * Preferences of select UI\n * @method ax5select.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5select}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onChange = cfg.onChange;\n\n jQuery(window).bind(\"resize.ax5select-display-\" + this.instanceId, (function () {\n alignSelectDisplay.call(this);\n }).bind(this));\n };\n\n /**\n * bind select\n * @method ax5select.bind\n * @param {Object} item\n * @param {String} [item.id]\n * @param {String} [item.theme]\n * @param {Boolean} [item.multiple]\n * @param {Element} item.target\n * @param {Object[]} item.options\n * @returns {ax5select}\n */\n this.bind = function (item) {\n var\n selectConfig = {},\n queIdx;\n\n\n item = jQuery.extend(true, selectConfig, cfg, item);\n\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5select\", \"401\", \"bind\"));\n return this;\n }\n\n item.$target = jQuery(item.target);\n\n if (!item.id) item.id = item.$target.data(\"data-ax5select-id\");\n if (!item.id) {\n item.id = 'ax5select-' + ax5.getGuid();\n item.$target.data(\"data-ax5select-id\", item.id);\n }\n item.name = item.$target.attr(\"data-ax5select\");\n\n if (item.options) {\n item.options = JSON.parse(JSON.stringify(item.options));\n }\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n item = jQuery.extend(true, item, data);\n }\n })(U.parseJson(item.$target.attr(\"data-ax5select-config\"), true));\n\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindSelectTarget.call(this, this.queue.length - 1);\n }\n else {\n this.queue[queIdx].selected = [];\n this.queue[queIdx].options = item.options;\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindSelectTarget.call(this, queIdx);\n }\n\n selectConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * open the optionBox of select\n * @method ax5select.open\n * @param {(String|Number|Element)} boundID\n * @param {Number} [tryCount]\n * @returns {ax5select}\n */\n this.open = (function () {\n\n var onExpand = function (item) {\n item.onExpand.call({\n self: this,\n item: item\n }, (function (O) {\n if (this.waitOptionsCallback) {\n var data = {};\n var item = this.queue[this.activeSelectQueueIndex];\n\n /// 현재 selected 검증후 처리\n (function (item, O) {\n var optionsMap = {};\n O.options.forEach(function (_O, _OIndex) {\n _O[\"@index\"] = _OIndex;\n optionsMap[_O[item.columnKeys.optionValue]] = _O;\n });\n if (U.isArray(item.selected)) {\n item.selected.forEach(function (_O) {\n if (optionsMap[_O[item.columnKeys.optionValue]]) {\n O.options[optionsMap[_O[item.columnKeys.optionValue]][\"@index\"]][item.columnKeys.optionSelected] = true;\n }\n });\n }\n })(item, O);\n\n\n item.$displayLabel\n .html(getLabel.call(this, this.activeSelectQueueIndex));\n item.options = syncSelectOptions.call(this, this.activeSelectQueueIndex, O.options);\n\n alignSelectDisplay.call(this);\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5select-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n this.activeSelectOptionGroup.find('[data-els=\"content\"]').html(SELECT.tmpl.get.call(this, \"optionsTmpl\", data, item.columnKeys));\n }\n }).bind(this));\n };\n\n return function (boundID, tryCount) {\n this.waitOptionsCallback = null;\n\n /**\n * open select from the outside\n */\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n var data = {}, focusTop, selectedOptionEl;\n\n if (item.$display.attr(\"disabled\")) return this;\n\n if (this.openTimer) clearTimeout(this.openTimer);\n if (this.activeSelectOptionGroup) {\n if (this.activeSelectQueueIndex == queIdx) {\n return this;\n }\n\n if (tryCount > 2) return this;\n this.close();\n this.openTimer = setTimeout((function () {\n this.open(queIdx, (tryCount || 0) + 1);\n }).bind(this), cfg.animateTime);\n\n return this;\n }\n\n item.optionFocusIndex = -1; // optionGroup이 열리면 포커스 인덱스 초기화 -1로\n if (item.selected && item.selected.length > 0) {\n item.optionSelectedIndex = item.selected[0][\"@findex\"];\n }\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5select-option-group-\" + item.size;\n data.multiple = item.multiple;\n\n data.lang = item.lang;\n item.$display.attr(\"data-select-option-group-opened\", \"true\");\n //console.log(data.lang);\n\n if (item.onExpand) {\n // onExpand 인 경우 UI 대기모드 추가\n data.waitOptions = true;\n }\n\n data.options = item.options;\n this.activeSelectOptionGroup = SELECT.tmpl.get.call(this, \"optionGroupTmpl\", data);\n this.activeSelectOptionGroup.find('[data-els=\"content\"]').html(SELECT.tmpl.get.call(this, \"optionsTmpl\", data, item.columnKeys));\n this.activeSelectQueueIndex = queIdx;\n\n alignSelectOptionGroup.call(this, \"append\"); // alignSelectOptionGroup 에서 body append\n jQuery(window).bind(\"resize.ax5select-\" + this.instanceId, (function () {\n alignSelectOptionGroup.call(this);\n }).bind(this));\n\n if (item.selected && item.selected.length > 0) {\n selectedOptionEl = this.activeSelectOptionGroup.find('[data-option-index=\"' + item.selected[0][\"@index\"] + '\"]');\n\n if (selectedOptionEl.get(0)) {\n focusTop = selectedOptionEl.position().top - this.activeSelectOptionGroup.height() / 3;\n this.activeSelectOptionGroup.find('[data-els=\"content\"]')\n .stop().animate({scrollTop: focusTop}, item.animateTime, 'swing', function () {\n });\n }\n }\n\n /// 사용자 입력으로 옵션을 검색하기 위한 시나리오\n // 옵션그룹이 활성화 되면 사용자 입력을 받기위한 input 값 초기화 및 포커스 다른 select가 닫히면서 display focus 이벤트와 충돌하는 문제가 있으므로\n // 1밀리세컨 지연후 포커스 처리. input에 포커스가 되므로 input value로 options를 검색 할 수 있게 됩니다.\n item.$displayInput.val('');\n\n setTimeout((function () {\n item.$displayInput.trigger(\"focus\");\n\n jQuery(window).bind(\"keyup.ax5select-\" + this.instanceId, (function (e) {\n e = e || window.event;\n onBodyKeyup.call(this, e);\n U.stopEvent(e);\n }).bind(this));\n\n jQuery(window).bind(\"click.ax5select-\" + this.instanceId, (function (e) {\n e = e || window.event;\n onBodyClick.call(this, e);\n U.stopEvent(e);\n }).bind(this));\n\n }).bind(this), 300);\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"open\",\n item: item\n });\n\n // waitOption timer\n if (item.onExpand) {\n this.waitOptionsCallback = true;\n onExpand.call(this, item);\n }\n\n data = null;\n focusTop = null;\n selectedOptionEl = null;\n return this;\n }\n })();\n\n /**\n * @method ax5select.update\n * @param {(Object|String)} item\n * @returns {ax5select}\n */\n this.update = function (_item) {\n this.bind(_item);\n return this;\n };\n\n /**\n * @method ax5select.val\n * @param {(String|Number|Element)} boundID\n * @param {(String|Object|Array)} [value]\n * @param {Boolean} [selected]\n * @returns {ax5select}\n */\n this.val = (function () {\n\n // todo : val 함수 리팩토링 필요\n var getSelected = function (_item, o, selected) {\n if (typeof selected === \"undefined\") {\n return (_item.multiple) ? !o : true;\n } else {\n return selected;\n }\n };\n var clearSelected = function (queIdx) {\n this.queue[queIdx].options.forEach(function (n) {\n if (n.optgroup) {\n n.options.forEach(function (nn) {\n nn.selected = false;\n });\n }\n else {\n n.selected = false;\n }\n });\n };\n\n var processor = {\n 'index': function (queIdx, value, selected) {\n // 클래스 내부에서 호출된 형태, 그런 이유로 옵션그룹에 대한 상태를 변경 하고 있다.\n var item = this.queue[queIdx];\n\n /*\n if (U.isArray(value.index)) {\n value.index.forEach(function (n) {\n item.options[n][item.columnKeys.optionSelected] = getSelected(item, item.options[n][item.columnKeys.optionSelected], selected);\n self.activeSelectOptionGroup\n .find('[data-option-index=\"' + n + '\"]')\n .attr(\"data-option-selected\", item.options[n][item.columnKeys.optionSelected].toString());\n });\n }\n else {\n }\n */\n if (U.isString(value.index.gindex)) {\n item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected] = getSelected(item, item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected], selected);\n self.activeSelectOptionGroup\n .find('[data-option-group-index=\"' + value.index.gindex + '\"][data-option-index=\"' + value.index.index + '\"]')\n .attr(\"data-option-selected\", item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected].toString());\n }\n else {\n item.options[value.index.index][item.columnKeys.optionSelected] = getSelected(item, item.options[value.index.index][item.columnKeys.optionSelected], selected);\n self.activeSelectOptionGroup\n .find('[data-option-index=\"' + value.index.index + '\"]')\n .attr(\"data-option-selected\", item.options[value.index.index][item.columnKeys.optionSelected].toString());\n\n }\n\n syncSelectOptions.call(this, queIdx, item.options);\n syncLabel.call(this, queIdx);\n alignSelectOptionGroup.call(this);\n },\n 'arr': function (queIdx, values, selected) {\n values.forEach(function (value) {\n if (U.isString(value) || U.isNumber(value)) {\n processor.value.call(self, queIdx, value, selected);\n }\n else {\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(self, queIdx, value, selected);\n break;\n }\n }\n }\n });\n },\n 'value': function (queIdx, value, selected) {\n var item = this.queue[queIdx];\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionValue] == value;\n });\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n }\n else {\n console.log(ax5.info.getError(\"ax5select\", \"501\", \"val\"));\n return;\n }\n\n syncSelectOptions.call(this, queIdx, item.options);\n syncLabel.call(this, queIdx);\n },\n 'text': function (queIdx, value, selected) {\n var item = this.queue[queIdx];\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionText] == value;\n });\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected] = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n }\n else {\n console.log(ax5.info.getError(\"ax5select\", \"501\", \"val\"));\n return;\n }\n\n syncSelectOptions.call(this, queIdx, item.options);\n syncLabel.call(this, queIdx);\n },\n 'clear': function (queIdx) {\n clearSelected.call(this, queIdx);\n syncSelectOptions.call(this, queIdx, this.queue[queIdx].options);\n syncLabel.call(this, queIdx);\n\n if (this.activeSelectOptionGroup) {\n this.activeSelectOptionGroup\n .find('[data-option-index]')\n .attr(\"data-option-selected\", \"false\");\n }\n }\n };\n\n return function (boundID, value, selected, internal) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5select\", \"402\", \"val\"));\n return;\n }\n\n // setValue 이면 현재 선택값 초기화\n if (typeof value !== \"undefined\" && !this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n\n if (typeof value == \"undefined\") {\n return this.queue[queIdx].selected;\n }\n else if (U.isArray(value)) {\n processor.arr.call(this, queIdx, value, selected);\n }\n else if (U.isString(value) || U.isNumber(value)) {\n processor.value.call(this, queIdx, value, selected);\n }\n else {\n if (value === null) {\n processor.clear.call(this, queIdx);\n }\n else {\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(this, queIdx, value, selected);\n break;\n }\n }\n }\n }\n\n if (typeof value !== \"undefined\") {\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n item: this.queue[queIdx],\n state: (internal) ? \"changeValue\" : \"setValue\",\n value: this.queue[queIdx].selected,\n internal: internal\n });\n }\n\n boundID = null;\n return this;\n };\n })();\n\n /**\n * @method ax5select.close\n * @returns {ax5select}\n */\n this.close = function (item) {\n if (this.closeTimer) clearTimeout(this.closeTimer);\n if (!this.activeSelectOptionGroup) return this;\n\n item = this.queue[this.activeSelectQueueIndex];\n item.optionFocusIndex = -1;\n\n item.$displayInput.val('').trigger(\"blur\");\n item.$display.removeAttr(\"data-select-option-group-opened\").trigger(\"focus\");\n\n this.activeSelectOptionGroup.addClass(\"destroy\");\n\n jQuery(window)\n .unbind(\"resize.ax5select-\" + this.instanceId)\n .unbind(\"click.ax5select-\" + this.instanceId)\n .unbind(\"keyup.ax5select-\" + this.instanceId);\n\n this.closeTimer = setTimeout((function () {\n if (this.activeSelectOptionGroup) this.activeSelectOptionGroup.remove();\n this.activeSelectOptionGroup = null;\n this.activeSelectQueueIndex = -1;\n\n var that = {\n self: this,\n item: item,\n value: item.selected,\n state: \"close\"\n };\n\n onStateChanged.call(this, item, that);\n\n // waitOption timer\n if (item.onClose) {\n item.onClose.call(that);\n }\n }).bind(this), cfg.animateTime);\n this.waitOptionsCallback = null;\n return this;\n };\n\n this.enable = function (boundID) {\n var queIdx = getQueIdx.call(this, boundID);\n this.queue[queIdx].$display.removeAttr(\"disabled\");\n this.queue[queIdx].$select.removeAttr(\"disabled\");\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"enable\"\n });\n\n return this;\n };\n\n this.disable = function (boundID) {\n var queIdx = getQueIdx.call(this, boundID);\n this.queue[queIdx].$display.attr(\"disabled\", \"disabled\");\n this.queue[queIdx].$select.attr(\"disabled\", \"disabled\");\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"disable\"\n });\n\n return this;\n };\n\n // 클래스 생성자\n this.main = (function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n else {\n this.init();\n }\n }).apply(this, arguments);\n };\n return ax5select;\n })());\n SELECT = ax5.ui.select;\n})();\n\nax5.ui.select_instance = new ax5.ui.select();\njQuery.fn.ax5select = (function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"open\":\n return ax5.ui.select_instance.open(this);\n break;\n case \"close\":\n return ax5.ui.select_instance.close(this);\n break;\n case \"setValue\":\n return ax5.ui.select_instance.val(this, arguments[1], arguments[2]);\n break;\n case \"getValue\":\n return ax5.ui.select_instance.val(this);\n break;\n case \"enable\":\n return ax5.ui.select_instance.enable(this);\n break;\n case \"disable\":\n return ax5.ui.select_instance.disable(this);\n break;\n default:\n return this;\n }\n }\n else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.select_instance.bind(config);\n });\n }\n return this;\n }\n\n})();\n\n\n// muliple 속성이 없는 select의 기본 선택 해제 방법.. 결정 필요..\n// onExpand 가 있으면..?","// ax5.ui.select.tmpl\n(function () {\n\n var SELECT = ax5.ui.select;\n\n var optionGroupTmpl = function (columnKeys) {\n return `\n\n`;\n };\n var tmpl = function (columnKeys) {\n return `\n\n \n
{{label}}
\n
\n {{#multiple}}{{#reset}}\n {{{.}}}\n {{/reset}}{{/multiple}}\n {{#icons}}\n {{clesed}}\n {{opened}}\n {{/icons}}\n {{^icons}}\n \n \n {{/icons}}\n
\n
\n \n\n`;\n };\n var selectTmpl = function (columnKeys) {\n return `\n\n`;\n };\n var optionsTmpl = function (columnKeys) {\n return `\n{{#waitOptions}}\n \n
\n \n {{{lang.loading}}}\n \n
\n
\n{{/waitOptions}}\n{{^waitOptions}}\n {{#options}}\n {{#optgroup}}\n \n
\n \n {{{.}}}\n \n
\n {{#options}}\n
\n
\n {{#multiple}}\n \n \n \n {{/multiple}}\n {{${columnKeys.optionText}}}\n
\n
\n {{/options}}\n
\n {{/optgroup}}\n {{^optgroup}}\n \n
\n {{#multiple}}\n \n \n \n {{/multiple}}\n {{${columnKeys.optionText}}}\n
\n
\n {{/optgroup}}\n {{/options}}\n {{^options}}\n \n
\n \n {{{lang.noOptions}}}\n \n
\n
\n {{/options}}\n{{/waitOptions}}\n`;\n };\n\n SELECT.tmpl = {\n \"optionGroupTmpl\": optionGroupTmpl,\n \"tmpl\": tmpl,\n \"selectTmpl\": selectTmpl,\n \"optionsTmpl\": optionsTmpl,\n\n get: function (tmplName, data, columnKeys) {\n return jQuery(ax5.mustache.render(SELECT.tmpl[tmplName].call(this, columnKeys), data));\n }\n };\n\n})();","/*\n * Copyright (c) 2016. tom@axisj.com\n * - github.com/thomasjang\n * - www.axisj.com\n */\n\n// ax5.ui.grid\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var GRID;\n\n UI.addClass({\n className: \"grid\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5grid\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```\n * var myGrid = new ax5.ui.grid();\n * ```\n */\n var ax5grid = function () {\n var\n self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 250,\n\n // 틀고정 속성\n frozenColumnIndex: 0,\n frozenRowIndex: 0,\n showLineNumber: false,\n showRowSelector: false,\n multipleSelect: true,\n\n height: 0,\n columnMinWidth: 100,\n lineNumberColumnWidth: 30,\n rowSelectorColumnWidth: 26,\n sortable: undefined,\n remoteSort: false,\n\n header: {\n align: false,\n columnHeight: 26,\n columnPadding: 3,\n columnBorderWidth: 1\n },\n body: {\n align: false,\n columnHeight: 26,\n columnPadding: 3,\n columnBorderWidth: 1,\n grouping: false\n },\n rightSum: false,\n footSum: false,\n page: {\n height: 25,\n display: true,\n navigationItemCount: 5\n },\n scroller: {\n size: 15,\n barMinSize: 15,\n trackPadding: 4\n },\n columnKeys: {\n selected: '__selected__',\n modified: '__modified__',\n deleted: '__deleted__',\n disableSelection: '__disable_selection__'\n }\n };\n this.xvar = {\n bodyTrHeight: 0, // 한줄의 높이\n scrollContentWidth: 0, // 스크롤 될 내용물의 너비 (스크롤 될 내용물 : panel['body-scroll'] 안에 컬럼이 있는)\n scrollContentHeight: 0 // 스크롤 된 내용물의 높이\n };\n\n // 그리드 데이터셋\n this.columns = []; // config.columns에서 복제된 오브젝트\n this.colGroup = []; // columns를 table태그로 출력하기 좋게 변환한 오브젝트\n this.footSumColumns = [];\n this.bodyGrouping = {};\n\n this.list = []; // 그리드의 데이터\n this.page = {}; // 그리드의 페이지 정보\n this.selectedDataIndexs = [];\n this.deletedList = [];\n this.sortInfo = {}; // 그리드의 헤더 정렬 정보\n this.focusedColumn = {}; // 그리드 바디의 포커스된 셀 정보\n this.selectedColumn = {}; // 그리드 바디의 선택된 셀 정보\n this.isInlineEditing = false;\n this.inlineEditing = {};\n\n // header\n this.headerTable = {};\n this.leftHeaderData = {};\n this.headerData = {};\n this.rightHeaderData = {};\n\n // body\n this.bodyRowTable = {};\n this.leftBodyRowData = {};\n this.bodyRowData = {};\n this.rightBodyRowData = {};\n this.bodyRowMap = {};\n\n this.bodyGroupingTable = {};\n this.leftBodyGroupingData = {};\n this.bodyGroupingData = {};\n this.rightBodyGroupingData = {};\n\n // footSum\n this.footSumTable = {}; // footSum의 출력레이아웃\n this.leftFootSumData = {}; // frozenColumnIndex 를 기준으로 나누어진 출력 레이아웃 왼쪽\n this.footSumData = {}; // frozenColumnIndex 를 기준으로 나누어진 출력 레이아웃 오른쪽\n this.needToPaintSum = true; // 데이터 셋이 변경되어 summary 변경 필요여부\n\n cfg = this.config;\n\n var\n onStateChanged = function (_opts, _that) {\n if (_opts && _opts.onStateChanged) {\n _opts.onStateChanged.call(_that, _that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(_that, _that);\n }\n return true;\n },\n initGrid = function () {\n // 그리드 템플릿에 전달하고자 하는 데이터를 정리합시다.\n\n var data = {\n instanceId: this.id\n };\n\n this.$target.html(GRID.tmpl.get(\"main\", data));\n\n // 그리드 패널 프레임의 각 엘리먼트를 캐쉬합시다.\n this.$ = {\n \"container\": {\n \"hidden\": this.$target.find('[data-ax5grid-container=\"hidden\"]'),\n \"root\": this.$target.find('[data-ax5grid-container=\"root\"]'),\n \"header\": this.$target.find('[data-ax5grid-container=\"header\"]'),\n \"body\": this.$target.find('[data-ax5grid-container=\"body\"]'),\n \"page\": this.$target.find('[data-ax5grid-container=\"page\"]'),\n \"scroller\": this.$target.find('[data-ax5grid-container=\"scroller\"]')\n },\n \"panel\": {\n \"aside-header\": this.$target.find('[data-ax5grid-panel=\"aside-header\"]'),\n \"left-header\": this.$target.find('[data-ax5grid-panel=\"left-header\"]'),\n \"header\": this.$target.find('[data-ax5grid-panel=\"header\"]'),\n \"header-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"header\"]'),\n \"right-header\": this.$target.find('[data-ax5grid-panel=\"right-header\"]'),\n \"top-aside-body\": this.$target.find('[data-ax5grid-panel=\"top-aside-body\"]'),\n \"top-left-body\": this.$target.find('[data-ax5grid-panel=\"top-left-body\"]'),\n \"top-body\": this.$target.find('[data-ax5grid-panel=\"top-body\"]'),\n \"top-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"top-body\"]'),\n \"top-right-body\": this.$target.find('[data-ax5grid-panel=\"top-right-body\"]'),\n \"aside-body\": this.$target.find('[data-ax5grid-panel=\"aside-body\"]'),\n \"aside-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"aside-body\"]'),\n \"left-body\": this.$target.find('[data-ax5grid-panel=\"left-body\"]'),\n \"left-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"left-body\"]'),\n \"body\": this.$target.find('[data-ax5grid-panel=\"body\"]'),\n \"body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"body\"]'),\n \"right-body\": this.$target.find('[data-ax5grid-panel=\"right-body\"]'),\n \"right-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"right-body\"]'),\n \"bottom-aside-body\": this.$target.find('[data-ax5grid-panel=\"bottom-aside-body\"]'),\n \"bottom-left-body\": this.$target.find('[data-ax5grid-panel=\"bottom-left-body\"]'),\n \"bottom-body\": this.$target.find('[data-ax5grid-panel=\"bottom-body\"]'),\n \"bottom-body-scroll\": this.$target.find('[data-ax5grid-panel-scroll=\"bottom-body\"]'),\n \"bottom-right-body\": this.$target.find('[data-ax5grid-panel=\"bottom-right-body\"]')\n },\n \"livePanelKeys\": [], // 현재 사용중인 패널들 (grid-body repaint에서 수집하여 처리)\n \"scroller\": {\n \"vertical\": this.$target.find('[data-ax5grid-scroller=\"vertical\"]'),\n \"vertical-bar\": this.$target.find('[data-ax5grid-scroller=\"vertical-bar\"]'),\n \"horizontal\": this.$target.find('[data-ax5grid-scroller=\"horizontal\"]'),\n \"horizontal-bar\": this.$target.find('[data-ax5grid-scroller=\"horizontal-bar\"]'),\n \"corner\": this.$target.find('[data-ax5grid-scroller=\"corner\"]')\n },\n \"page\": {\n \"navigation\": this.$target.find('[data-ax5grid-page=\"navigation\"]'),\n \"status\": this.$target.find('[data-ax5grid-page=\"status\"]')\n },\n \"form\": {\n \"clipboard\": this.$target.find('[data-ax5grid-form=\"clipboard\"]')\n },\n \"resizer\": {\n \"vertical\": this.$target.find('[data-ax5grid-resizer=\"vertical\"]'),\n \"horizontal\": this.$target.find('[data-ax5grid-resizer=\"horizontal\"]')\n }\n };\n\n this.$[\"container\"][\"root\"].css({height: this.config.height});\n\n return this;\n },\n initColumns = function (_columns) {\n this.columns = U.deepCopy(_columns);\n this.headerTable = GRID.util.makeHeaderTable.call(this, this.columns);\n this.xvar.frozenColumnIndex = (cfg.frozenColumnIndex > this.columns.length) ? this.columns.length : cfg.frozenColumnIndex;\n\n this.bodyRowTable = GRID.util.makeBodyRowTable.call(this, this.columns);\n this.bodyRowMap = GRID.util.makeBodyRowMap.call(this, this.bodyRowTable);\n // 바디에 표현될 한줄의 높이를 계산합니다.\n this.xvar.bodyTrHeight = this.bodyRowTable.rows.length * this.config.body.columnHeight;\n\n var colGroupMap = {};\n for (var r = 0, rl = this.headerTable.rows.length; r < rl; r++) {\n var row = this.headerTable.rows[r];\n for (var c = 0, cl = row.cols.length; c < cl; c++) {\n colGroupMap[row.cols[c].colIndex] = jQuery.extend({}, row.cols[c]);\n }\n }\n\n this.colGroup = [];\n for (var k in colGroupMap) {\n this.colGroup.push(colGroupMap[k]);\n }\n\n return this;\n },\n onResetColumns = function () {\n initColumns.call(this, this.config.columns);\n resetColGroupWidth.call(this);\n if (this.config.footSum) {\n initFootSum.call(this, this.config.footSum);\n this.needToPaintSum = true;\n }\n if (this.config.body.grouping) initBodyGroup.call(this, this.config.body.grouping);\n alignGrid.call(this, true);\n GRID.header.repaint.call(this, true);\n GRID.body.repaint.call(this, true);\n GRID.scroller.resize.call(this);\n },\n resetColGroupWidth = function () {\n /// !! 그리드 target의 크기가 변경되면 이 함수를 호출하려 this.colGroup의 _width 값을 재 계산 하여야 함. [tom]\n var CT_WIDTH = this.$[\"container\"][\"root\"].width() - (function () {\n var width = 0;\n if (cfg.showLineNumber) width += cfg.lineNumberColumnWidth;\n if (cfg.showRowSelector) width += cfg.rowSelectorColumnWidth;\n return width;\n })();\n var totalWidth = 0;\n var computedWidth;\n var autoWidthColgroupIndexs = [];\n var colGroup = this.colGroup;\n var i, l;\n\n for (i = 0, l = colGroup.length; i < l; i++) {\n if (U.isNumber(colGroup[i].width)) {\n totalWidth += colGroup[i]._width = colGroup[i].width;\n } else if (colGroup[i].width === \"*\") {\n autoWidthColgroupIndexs.push(i);\n } else if (U.right(colGroup[i].width, 1) === \"%\") {\n totalWidth += colGroup[i]._width = CT_WIDTH * U.left(colGroup[i].width, \"%\") / 100;\n }\n }\n if (autoWidthColgroupIndexs.length > 0) {\n computedWidth = (CT_WIDTH - totalWidth) / autoWidthColgroupIndexs.length;\n for (i = 0, l = autoWidthColgroupIndexs.length; i < l; i++) {\n colGroup[autoWidthColgroupIndexs[i]]._width = computedWidth;\n }\n }\n },\n initFootSum = function (_footSum) {\n if (U.isArray(_footSum)) {\n this.footSumTable = GRID.util.makeFootSumTable.call(this, this.footSumColumns = _footSum);\n } else {\n this.footSumColumns = [];\n this.footSumTable = {};\n }\n },\n initBodyGroup = function (_grouping) {\n var grouping = jQuery.extend({}, _grouping);\n if (\"by\" in grouping && \"columns\" in grouping) {\n\n this.bodyGrouping = {\n by: grouping.by,\n columns: grouping.columns\n };\n this.bodyGroupingTable = GRID.util.makeBodyGroupingTable.call(this, this.bodyGrouping.columns);\n this.sortInfo = (function () {\n var sortInfo = {};\n for (var k = 0, kl = this.bodyGrouping.by.length; k < kl; k++) {\n sortInfo[this.bodyGrouping.by[k]] = {\n orderBy: \"asc\",\n seq: k,\n fixed: true\n };\n for (var c = 0, cl = this.colGroup.length; c < cl; c++) {\n if (this.colGroup[c].key === this.bodyGrouping.by[k]) {\n this.colGroup[c].sort = \"asc\";\n this.colGroup[c].sortFixed = true;\n }\n }\n }\n return sortInfo;\n }).call(this);\n } else {\n cfg.body.grouping = false;\n }\n },\n alignGrid = function (_isFirst) {\n // isFirst : 그리드 정렬 메소드가 처음 호출 되었는지 판단 하는 아규먼트\n var CT_WIDTH = this.$[\"container\"][\"root\"].width();\n var CT_HEIGHT = this.$[\"container\"][\"root\"].height();\n var CT_INNER_WIDTH = CT_WIDTH;\n var CT_INNER_HEIGHT = CT_HEIGHT;\n\n var asidePanelWidth = cfg.asidePanelWidth = (function () {\n var width = 0;\n\n if (cfg.showLineNumber) width += cfg.lineNumberColumnWidth;\n if (cfg.showRowSelector) width += cfg.rowSelectorColumnWidth;\n return width;\n })();\n\n var frozenPanelWidth = cfg.frozenPanelWidth = (function (colGroup, endIndex) {\n var width = 0;\n for (var i = 0, l = endIndex; i < l; i++) {\n width += colGroup[i]._width;\n }\n return width;\n })(this.colGroup, cfg.frozenColumnIndex);\n\n var rightPanelWidth = 0; // todo : 우측 함계컬럼 넘비 계산\n\n var frozenRowHeight = (function (bodyTrHeight) {\n return cfg.frozenRowIndex * bodyTrHeight;\n })(this.xvar.bodyTrHeight);\n\n var footSumHeight = (function (bodyTrHeight) {\n return this.footSumColumns.length * bodyTrHeight;\n }).call(this, this.xvar.bodyTrHeight);\n\n var headerHeight = this.headerTable.rows.length * cfg.header.columnHeight;\n var pageHeight = (cfg.page.display) ? cfg.page.height : 0;\n\n // 데이터의 길이가 body보다 높을때. 수직 스크롤러 활성화\n var verticalScrollerWidth, horizontalScrollerHeight;\n\n (function () {\n verticalScrollerWidth = ((CT_HEIGHT - headerHeight - pageHeight - footSumHeight) < this.list.length * this.xvar.bodyTrHeight) ? this.config.scroller.size : 0;\n // 남은 너비가 colGroup의 너비보다 넓을때. 수평 스크롤 활성화.\n horizontalScrollerHeight = (function () {\n var totalColGroupWidth = 0;\n // aside 빼고 너비\n // 수직 스크롤이 있으면 또 빼고 비교\n var bodyWidth = CT_WIDTH - asidePanelWidth - verticalScrollerWidth;\n for (var i = 0, l = this.colGroup.length; i < l; i++) {\n totalColGroupWidth += this.colGroup[i]._width;\n }\n return (totalColGroupWidth > bodyWidth) ? this.config.scroller.size : 0;\n }).call(this);\n\n if (horizontalScrollerHeight > 0) {\n verticalScrollerWidth = ((CT_HEIGHT - headerHeight - pageHeight - footSumHeight - horizontalScrollerHeight) < this.list.length * this.xvar.bodyTrHeight) ? this.config.scroller.size : 0;\n }\n }).call(this);\n\n // 수평 너비 결정\n CT_INNER_WIDTH = CT_WIDTH - verticalScrollerWidth;\n // 수직 스크롤러의 높이 결정.\n CT_INNER_HEIGHT = CT_HEIGHT - pageHeight - horizontalScrollerHeight;\n\n var bodyHeight = CT_INNER_HEIGHT - headerHeight;\n\n var panelDisplayProcess = function (panel, vPosition, hPosition, containerType) {\n var css = {};\n var isHide = false;\n\n switch (hPosition) {\n case \"aside\":\n if (asidePanelWidth === 0) {\n isHide = true;\n } else {\n css[\"left\"] = 0;\n css[\"width\"] = asidePanelWidth;\n }\n break;\n case \"left\":\n if (cfg.frozenColumnIndex === 0) {\n isHide = true;\n } else {\n css[\"left\"] = asidePanelWidth;\n css[\"width\"] = frozenPanelWidth;\n }\n break;\n case \"right\":\n if (!cfg.rightSum) {\n isHide = true;\n } else {\n\n }\n break;\n default:\n if (containerType !== \"page\") {\n if (cfg.frozenColumnIndex === 0) {\n css[\"left\"] = asidePanelWidth;\n } else {\n css[\"left\"] = frozenPanelWidth + asidePanelWidth;\n }\n css[\"width\"] = CT_INNER_WIDTH - asidePanelWidth - frozenPanelWidth - rightPanelWidth;\n }\n break;\n }\n\n if (isHide) {\n panel.hide();\n // 프로세스 중지\n return this;\n }\n\n if (containerType === \"body\") {\n switch (vPosition) {\n case \"top\":\n if (cfg.frozenRowIndex == 0) {\n isHide = true;\n } else {\n css[\"top\"] = 0;\n css[\"height\"] = frozenRowHeight;\n }\n break;\n case \"bottom\":\n if (!cfg.footSum) {\n isHide = true;\n } else {\n css[\"top\"] = bodyHeight - footSumHeight;\n css[\"height\"] = footSumHeight; // footSum height\n }\n break;\n default:\n\n css[\"top\"] = frozenRowHeight;\n css[\"height\"] = bodyHeight - frozenRowHeight - footSumHeight;\n\n break;\n }\n } else if (containerType === \"header\") {\n css[\"height\"] = headerHeight;\n } else if (containerType === \"page\") {\n if (pageHeight == 0) {\n isHide = true;\n } else {\n css[\"height\"] = pageHeight;\n }\n }\n\n if (isHide) {\n panel.hide();\n // 프로세스 중지\n return this;\n }\n\n panel.css(css);\n return this;\n };\n var scrollerDisplayProcess = function (panel, scrollerWidth, scrollerHeight, containerType) {\n var css = {};\n var isHide = false;\n\n switch (containerType) {\n case \"vertical\":\n if (scrollerWidth > 0) {\n css[\"width\"] = scrollerWidth;\n css[\"height\"] = CT_INNER_HEIGHT;\n css[\"bottom\"] = scrollerHeight + pageHeight;\n } else {\n isHide = true;\n }\n break;\n case \"horizontal\":\n if (scrollerHeight > 0) {\n css[\"width\"] = CT_INNER_WIDTH;\n css[\"height\"] = scrollerHeight;\n css[\"right\"] = scrollerWidth;\n css[\"bottom\"] = pageHeight;\n } else {\n isHide = true;\n }\n break;\n case \"corner\":\n if (scrollerWidth > 0 && scrollerHeight > 0) {\n css[\"width\"] = scrollerWidth;\n css[\"height\"] = scrollerHeight;\n css[\"bottom\"] = pageHeight;\n } else {\n isHide = true;\n }\n break;\n }\n\n if (isHide) {\n panel.hide();\n // 프로세스 중지\n return this;\n }\n\n panel.show().css(css);\n };\n\n this.$[\"container\"][\"header\"].css({height: headerHeight});\n this.$[\"container\"][\"body\"].css({height: bodyHeight});\n\n // 각 패널들의 크기 표시여부를 결정합니다\n panelDisplayProcess.call(this, this.$[\"panel\"][\"aside-header\"], \"\", \"aside\", \"header\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"left-header\"], \"\", \"left\", \"header\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"header\"], \"\", \"\", \"header\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"right-header\"], \"\", \"right\", \"header\");\n\n panelDisplayProcess.call(this, this.$[\"panel\"][\"top-aside-body\"], \"top\", \"aside\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"top-left-body\"], \"top\", \"left\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"top-body\"], \"top\", \"\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"top-right-body\"], \"top\", \"right\", \"body\");\n\n panelDisplayProcess.call(this, this.$[\"panel\"][\"aside-body\"], \"\", \"aside\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"left-body\"], \"\", \"left\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"body\"], \"\", \"\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"right-body\"], \"\", \"right\", \"body\");\n\n panelDisplayProcess.call(this, this.$[\"panel\"][\"bottom-aside-body\"], \"bottom\", \"aside\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"bottom-left-body\"], \"bottom\", \"left\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"bottom-body\"], \"bottom\", \"\", \"body\");\n panelDisplayProcess.call(this, this.$[\"panel\"][\"bottom-right-body\"], \"bottom\", \"right\", \"body\");\n\n\n scrollerDisplayProcess.call(this, this.$[\"scroller\"][\"vertical\"], verticalScrollerWidth, horizontalScrollerHeight, \"vertical\");\n scrollerDisplayProcess.call(this, this.$[\"scroller\"][\"horizontal\"], verticalScrollerWidth, horizontalScrollerHeight, \"horizontal\");\n scrollerDisplayProcess.call(this, this.$[\"scroller\"][\"corner\"], verticalScrollerWidth, horizontalScrollerHeight, \"corner\");\n\n panelDisplayProcess.call(this, this.$[\"container\"][\"page\"], \"\", \"\", \"page\");\n },\n sortColumns = function (_sortInfo) {\n GRID.header.repaint.call(this);\n\n if (U.isFunction(this.config.remoteSort)) {\n var that = {sortInfo: []};\n for (var k in _sortInfo) {\n that.sortInfo.push({\n key: k,\n orderBy: _sortInfo[k].orderBy,\n seq: _sortInfo[k].seq\n });\n }\n that.sortInfo.sort(function (a, b) {\n return a.seq > b.seq;\n });\n this.config.remoteSort.call(that, that);\n } else {\n if (this.config.body.grouping) {\n this.list = GRID.data.initData.call(this,\n GRID.data.sort.call(this,\n _sortInfo,\n GRID.data.clearGroupingData.call(this,\n this.list\n )\n )\n );\n }\n else {\n this.list = GRID.data.sort.call(this, _sortInfo,\n GRID.data.clearGroupingData.call(this,\n this.list\n )\n );\n }\n GRID.body.repaint.call(this, true);\n GRID.scroller.resize.call(this);\n }\n };\n\n /// private end\n\n /**\n * Preferences of grid UI\n * @method ax5grid.setConfig\n * @param {Object} _config - 클래스 속성값\n * @param {Element} _config.target\n * @param {Number} [_config.frozenColumnIndex=0]\n * @param {Number} [_config.frozenRowIndex=0]\n * @param {Boolean} [_config.showLineNumber=false]\n * @param {Boolean} [_config.showRowSelector=false]\n * @param {Boolean} [_config.multipleSelect=true]\n * @param {Number} [_config.columnMinWidth=100]\n * @param {Number} [_config.lineNumberColumnWidth=30]\n * @param {Number} [_config.rowSelectorColumnWidth=25]\n * @param {Boolean} [_config.sortable=false]\n * @param {Boolean} [_config.multiSort=false]\n * @param {Function} [_config.remoteSort=false]\n * @param {Object} [_config.header]\n * @param {String} [_config.header.align]\n * @param {Number} [_config.header.columnHeight=25]\n * @param {Number} [_config.header.columnPadding=3]\n * @param {Number} [_config.header.columnBorderWidth=1]\n * @param {Object} [_config.body]\n * @param {String} [_config.body.align]\n * @param {Number} [_config.body.columnHeight=25]\n * @param {Number} [_config.body.columnPadding=3]\n * @param {Number} [_config.body.columnBorderWidth=1]\n * @param {Object} [_config.body.grouping]\n * @param {Array} [_config.body.grouping.by] - list grouping keys\n * @param {Array} [_config.body.grouping.columns] - list grouping columns\n * @param {Object} [_config.page]\n * @param {Number} [_config.page.height=25]\n * @param {Boolean} [_config.page.display=true]\n * @param {Number} [_config.page.navigationItemCount=5]\n * @param {Object} [_config.scroller]\n * @param {Number} [_config.scroller.size=15]\n * @param {Number} [_config.scroller.barMinSize=15]\n * @param {Number} [_config.scroller.trackPadding=4]\n * @param {Object} [_config.columnKeys]\n * @param {String} [_config.columnKeys.selected=\"_SELECTED\"]\n * @param {Object[]} _config.columns\n * @param {String} _config.columns[].key\n * @param {String} _config.columns[].label\n * @param {Number} _config.columns[].width\n * @param {(String|Function)} _config.columns[].styleClass\n * @param {Boolean} _config.columns[].enableFilter\n * @param {Boolean} _config.columns[].sortable\n * @param {String} _config.columns[].align\n * @param {(String|Function)} _config.columns[].formatter\n * @param {Object} _config.columns[].editor\n * @param {String} _config.columns[].editor.type - text,number,money,date\n * @param {Object} _config.columns[].editor.config\n * @param {Array} _config.columns[].editor.updateWith\n * @parem {Function} _config.columns[].editor.disabled - disable editor\n * @returns {ax5grid}\n * @example\n * ```js\n * var firstGrid = new ax5.ui.grid();\n *\n * ax5.ui.grid.formatter[\"myType\"] = function () {\n * return \"myType\" + (this.value || \"\");\n * };\n * ax5.ui.grid.formatter[\"capital\"] = function(){\n * return (''+this.value).toUpperCase();\n * };\n *\n * ax5.ui.grid.collector[\"myType\"] = function () {\n * return \"myType\" + (this.value || \"\");\n * };\n *\n * var sampleData = [\n * {a: \"A\", b: \"A01\", price: 1000, amount: 12, cost: 12000, saleDt: \"2016-08-29\", customer: \"장기영\", saleType: \"A\"},\n * {companyJson: {\"대표자명\":\"abcd\"}, a: \"A\", b: \"B01\", price: 1100, amount: 11, cost: 12100, saleDt: \"2016-08-28\", customer: \"장서우\", saleType: \"B\"},\n * {companyJson: {\"대표자명\":\"abcd\"}, a: \"A\", b: \"C01\", price: 1200, amount: 10, cost: 12000, saleDt: \"2016-08-27\", customer: \"이영희\", saleType: \"A\"},\n * {companyJson: {\"대표자명\":\"위세라\"}, a: \"A\", b: \"A01\", price: 1300, amount: 8, cost: 10400, saleDt: \"2016-08-25\", customer: \"황인서\", saleType: \"C\"},\n * {companyJson: {\"대표자명\":\"abcd\"}, a: \"A\", b: \"B01\", price: 1400, amount: 5, cost: 7000, saleDt: \"2016-08-29\", customer: \"황세진\", saleType: \"D\"},\n * {companyJson: {\"대표자명\":\"abcd\"}, a: \"A\", b: \"A01\", price: 1500, amount: 2, cost: 3000, saleDt: \"2016-08-26\", customer: \"이서연\", saleType: \"A\"}\n * ];\n *\n * var gridView = {\n * initView: function () {\n * firstGrid.setConfig({\n * target: $('[data-ax5grid=\"first-grid\"]'),\n * columns: [\n * {\n * key: \"companyJson['대표자명']\",\n * label: \"필드A\",\n * width: 80,\n * styleClass: function () {\n * return \"ABC\";\n * },\n * enableFilter: true,\n * align: \"center\",\n * editor: {type:\"text\"}\n * },\n * {key: \"b\", label: \"필드B\", align: \"center\"},\n * {\n * key: undefined, label: \"필드C\", columns: [\n * {key: \"price\", label: \"단가\", formatter: \"money\", align: \"right\"},\n * {key: \"amount\", label: \"수량\", formatter: \"money\", align: \"right\"},\n * {key: \"cost\", label: \"금액\", align: \"right\", formatter: \"money\"}\n * ]\n * },\n * {key: \"saleDt\", label: \"판매일자\", align: \"center\"},\n * {key: \"customer\", label: \"고객명\"},\n * {key: \"saleType\", label: \"판매타입\"}\n * ]\n * });\n * return this;\n * },\n * setData: function (_pageNo) {\n *\n * firstGrid.setData(sampleData);\n *\n * return this;\n * }\n * };\n * ```\n */\n this.init = function (_config) {\n cfg = jQuery.extend(true, {}, cfg, _config);\n if (!cfg.target) {\n console.log(ax5.info.getError(\"ax5grid\", \"401\", \"init\"));\n return this;\n }\n\n // 그리드의 이벤트 정의 구간\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n this.onLoad = cfg.onLoad;\n this.onDataChanged = cfg.body.onDataChanged;\n // todo event에 대한 추가 정의 필요\n\n this.$target = jQuery(cfg.target);\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n cfg = jQuery.extend(true, cfg, data);\n }\n }).call(this, U.parseJson(this.$target.attr(\"data-ax5grid-config\"), true));\n\n var grid = this.config = cfg;\n\n if (!this.config.height) {\n this.config.height = this.$target.height();\n }\n\n if (!this.id) this.id = this.$target.data(\"data-ax5grid-id\");\n if (!this.id) {\n //this.id = 'ax5grid-' + ax5.getGuid();\n this.id = 'ax5grid-' + this.instanceId;\n this.$target.data(\"data-ax5grid-id\", grid.id);\n }\n\n ///========\n // 그리드를 그리기 위한 가장 기초적인 작업 뼈대와 틀을 준비합니다. 이 메소드는 초기화 시 한번만 호출 되게 됩니다.\n initGrid.call(this);\n\n // columns데이터를 분석하여 미리 처리해야하는 데이터를 정리합니다.\n initColumns.call(this, grid.columns);\n resetColGroupWidth.call(this);\n\n // footSum 데이터를 분석하여 미리 처리해야 하는 데이터를 정리\n if (grid.footSum) initFootSum.call(this, grid.footSum);\n\n // bodyGrouping 데이터를 분석하여 미리 처리해야 하는 데이터를 정리\n if (grid.body.grouping) initBodyGroup.call(this, grid.body.grouping);\n\n // 그리드의 각 요소의 크기를 맞춤니다.\n alignGrid.call(this, true);\n\n // columns의 데이터로 header데이터를 만들고\n GRID.header.init.call(this);\n // header를 출력합니다.\n GRID.header.repaint.call(this);\n\n // columns의 데이터로 body데이터를 만들고\n GRID.body.init.call(this);\n // body를 출력합니다.\n GRID.body.repaint.call(this);\n\n // scroller\n GRID.scroller.init.call(this);\n GRID.scroller.resize.call(this);\n\n jQuery(window).bind(\"resize.ax5grid-\" + this.id, function () {\n alignGrid.call(this);\n GRID.scroller.resize.call(this);\n }.bind(this));\n\n jQuery(document.body).on(\"click.ax5grid-\" + this.id, (function (e) {\n var isPickerClick = false;\n var target = U.findParentNode(e.target, function (_target) {\n if (isPickerClick = _target.getAttribute(\"data-ax5grid-inline-edit-picker\")) {\n return true;\n }\n return _target.getAttribute(\"data-ax5grid-container\") === \"root\";\n });\n\n if (target && target.getAttribute(\"data-ax5grid-instance\") === this.id) {\n self.focused = true;\n } else {\n self.focused = false;\n GRID.body.blur.call(this);\n }\n }).bind(this));\n\n var ctrlKeys = {\n \"33\": \"KEY_PAGEUP\",\n \"34\": \"KEY_PAGEDOWN\",\n \"35\": \"KEY_END\",\n \"36\": \"KEY_HOME\",\n \"37\": \"KEY_LEFT\",\n \"38\": \"KEY_UP\",\n \"39\": \"KEY_RIGHT\",\n \"40\": \"KEY_DOWN\"\n };\n jQuery(window).on(\"keydown.ax5grid-\" + this.instanceId, function (e) {\n if (self.focused) {\n if (self.isInlineEditing) {\n\n if (e.which == ax5.info.eventKeys.ESC) {\n self.keyDown(\"ESC\", e.originalEvent);\n }\n else if (e.which == ax5.info.eventKeys.RETURN) {\n self.keyDown(\"RETURN\", e.originalEvent);\n }\n else if (e.which == ax5.info.eventKeys.TAB) {\n self.keyDown(\"TAB\", e.originalEvent);\n U.stopEvent(e);\n }\n else if (e.which == ax5.info.eventKeys.UP) {\n self.keyDown(\"RETURN\", {shiftKey: true});\n }\n else if (e.which == ax5.info.eventKeys.DOWN) {\n self.keyDown(\"RETURN\", {});\n }\n\n }\n else {\n\n if (e.metaKey || e.ctrlKey) {\n if (e.which == 67) { // c\n self.copySelect();\n }\n } else {\n if (ctrlKeys[e.which]) {\n self.keyDown(ctrlKeys[e.which], e.originalEvent);\n U.stopEvent(e);\n } else if (e.which == ax5.info.eventKeys.ESC) {\n if (self.focused) {\n GRID.body.blur.call(self);\n }\n } else if (e.which == ax5.info.eventKeys.RETURN) {\n self.keyDown(\"RETURN\", e.originalEvent);\n } else if (e.which == ax5.info.eventKeys.TAB) {\n //self.keyDown(\"RETURN\", e.originalEvent);\n U.stopEvent(e);\n } else if (e.which != ax5.info.eventKeys.SPACE && Object.keys(self.focusedColumn).length) {\n self.keyDown(\"INLINE_EDIT\", e.originalEvent);\n }\n }\n\n }\n }\n });\n\n // 그리드 레이아웃이 모든 준비를 마친시점에 onLoad존재 여부를 확인하고 호출하여 줍니다.\n setTimeout((function () {\n if (this.onLoad) {\n this.onLoad.call({\n self: this\n })\n }\n }).bind(this));\n return this;\n };\n\n /**\n * align grid size\n * @method ax5grid.align\n * @returns {ax5grid}\n */\n this.align = function () {\n alignGrid.call(this);\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.keyDown\n * @param {String} _keyName\n * @param {Event|Object} _data\n * @return {ax5grid}\n */\n this.keyDown = (function () {\n var processor = {\n \"KEY_UP\": function () {\n GRID.body.moveFocus.call(this, \"UP\");\n },\n \"KEY_DOWN\": function () {\n GRID.body.moveFocus.call(this, \"DOWN\");\n },\n \"KEY_LEFT\": function () {\n GRID.body.moveFocus.call(this, \"LEFT\");\n },\n \"KEY_RIGHT\": function () {\n GRID.body.moveFocus.call(this, \"RIGHT\");\n },\n \"KEY_HOME\": function () {\n GRID.body.moveFocus.call(this, \"HOME\");\n },\n \"KEY_END\": function () {\n GRID.body.moveFocus.call(this, \"END\");\n },\n \"INLINE_EDIT\": function (_e) {\n GRID.body.inlineEdit.active.call(this, this.focusedColumn, _e);\n if (!/[0-9a-zA-Z]/.test(_e.key)) {\n U.stopEvent(_e);\n }\n },\n \"ESC\": function (_e) {\n GRID.body.inlineEdit.keydown.call(this, \"ESC\");\n },\n \"RETURN\": function (_e) {\n var activeEditLength = 0;\n for (var columnKey in this.inlineEditing) {\n activeEditLength++;\n\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\", columnKey);\n // next focus\n if (activeEditLength == 1) {\n if (GRID.body.moveFocus.call(this, (_e.shiftKey) ? \"UP\" : \"DOWN\")) {\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\");\n }\n }\n }\n if (activeEditLength == 0) {\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\");\n }\n },\n \"TAB\": function (_e) {\n\n var activeEditLength = 0;\n for (var columnKey in this.inlineEditing) {\n activeEditLength++;\n\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\", columnKey, {moveFocus: true});\n // next focus\n if (activeEditLength == 1) {\n if (GRID.body.moveFocus.call(this, (_e.shiftKey) ? \"LEFT\" : \"RIGHT\")) {\n GRID.body.inlineEdit.keydown.call(this, \"RETURN\", undefined, {moveFocus: true});\n }\n }\n }\n }\n };\n return function (_act, _data) {\n if (_act in processor) processor[_act].call(this, _data);\n return this;\n }\n })();\n\n /**\n * @method ax5grid.copySelect\n * @returns {Boolean} copysuccess\n */\n this.copySelect = function () {\n var copysuccess;\n var $clipBoard = this.$[\"form\"][\"clipboard\"];\n var copyTextArray = [];\n var copyText = \"\";\n\n var _rowIndex, _colIndex, _dindex;\n var _di = 0;\n for (var c in this.selectedColumn) {\n var _column = this.selectedColumn[c];\n\n if (_column) {\n if (typeof _dindex === \"undefined\") {\n _dindex = _column.dindex;\n _rowIndex = _column.rowIndex;\n _colIndex = _column.rowIndex;\n }\n\n if (_dindex != _column.dindex || _rowIndex != _column.rowIndex) {\n _di++;\n }\n\n if (!copyTextArray[_di]) {\n copyTextArray[_di] = [];\n }\n var originalColumn = this.bodyRowMap[_column.rowIndex + \"_\" + _column.colIndex];\n if (originalColumn) {\n if (this.list[_column.dindex].__isGrouping) {\n copyTextArray[_di].push(this.list[_column.dindex][_column.colIndex]);\n } else {\n copyTextArray[_di].push(this.list[_column.dindex][originalColumn.key]);\n }\n } else {\n copyTextArray[_di].push(\"\");\n }\n\n _dindex = _column.dindex;\n _rowIndex = _column.rowIndex;\n }\n }\n\n copyTextArray.forEach(function (r) {\n copyText += r.join('\\t') + \"\\n\";\n });\n\n $clipBoard.get(0).innerText = copyText;\n $clipBoard.select();\n\n try {\n copysuccess = document.execCommand(\"copy\");\n } catch (e) {\n copysuccess = false;\n }\n return copysuccess;\n };\n\n /**\n * @method ax5grid.setData\n * @param {Array} _data\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.setData({\n * list: [],\n * page: {\n * currentPage: 0,\n * pageSize: 50,\n * totalElements: 500,\n * totalPages: 100\n * }\n * });\n *\n * // onlyList\n * ax5Grid.setData([]);\n * ```\n */\n this.setData = function (_data) {\n GRID.data.set.call(this, _data);\n alignGrid.call(this);\n GRID.body.repaint.call(this);\n GRID.scroller.resize.call(this);\n GRID.page.navigationUpdate.call(this);\n GRID.body.scrollTo.call(this, {top: 0});\n return this;\n };\n\n /**\n * @method ax5grid.getList\n * @param {String} _type\n * @returns {Array}\n * @example\n * ```js\n * ax5Grid.getList();\n * ax5Grid.getList(\"modified\");\n * ax5Grid.getList(\"deleted\");\n * ```\n */\n this.getList = function (_type) {\n return GRID.data.getList.call(this, _type);\n };\n\n /**\n * @method ax5grid.setHeight\n * @param {Number} _height\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.setHeight(height);\n * ```\n */\n this.setHeight = function (_height) {\n //console.log(this.$target);\n if (_height == \"100%\") {\n _height = this.$target.offsetParent().innerHeight();\n }\n this.$target.css({height: _height});\n this.$[\"container\"][\"root\"].css({height: _height});\n alignGrid.call(this);\n GRID.body.repaint.call(this, \"reset\");\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.addRow\n * @param {Object} _row\n * @param {Number|String} [_dindex=last]\n * @param {Object} [_options] - options of addRow\n * @param {Boolean} [_options.sort] - sortData\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.addRow($.extend({}, {...}), \"first\");\n * ```\n */\n this.addRow = function (_row, _dindex, _options) {\n GRID.data.add.call(this, _row, _dindex, _options);\n alignGrid.call(this);\n GRID.body.repaint.call(this, \"reset\");\n GRID.body.moveFocus.call(this, (this.config.body.grouping) ? \"START\" : \"END\");\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.removeRow\n * @param {Number|String} [_dindex=last]\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.removeRow();\n * ax5Grid.removeRow(\"first\");\n * ax5Grid.removeRow(\"last\");\n * ax5Grid.removeRow(1);\n * ```\n */\n this.removeRow = function (_dindex) {\n GRID.data.remove.call(this, _dindex);\n alignGrid.call(this);\n GRID.body.repaint.call(this, \"reset\");\n GRID.body.moveFocus.call(this, (this.config.body.grouping) ? \"START\" : \"END\");\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.updateRow\n * @param {Object} _row\n * @param {Number} _dindex\n * @returns {ax5grid}\n */\n this.updateRow = function (_row, _dindex) {\n GRID.data.update.call(this, _row, _dindex);\n GRID.body.repaintRow.call(this, _dindex);\n return this;\n };\n\n /**\n * @method ax5grid.deleteRow\n * @param {Number|String} _dindex\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.deleteRow(\"first\");\n * ax5Grid.deleteRow(\"last\");\n * ax5Grid.deleteRow(1);\n * ax5Grid.deleteRow(\"selected\");\n * ```\n */\n this.deleteRow = function (_dindex) {\n GRID.data.deleteRow.call(this, _dindex);\n alignGrid.call(this);\n GRID.body.repaint.call(this, \"reset\");\n // 삭제시엔 포커스 ?\n // GRID.body.moveFocus.call(this, (this.config.body.grouping) ? \"START\" : \"END\");\n GRID.scroller.resize.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.setValue\n * @param _dindex\n * @param _key\n * @param _value\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5Grid.setValue(0, \"price\", 100);\n * ```\n */\n this.setValue = function (_dindex, _key, _value) {\n // getPanelname;\n if (GRID.data.setValue.call(this, _dindex, _key, _value)) {\n let repaintCell = function (_panelName, _rows, __dindex, __key, __value) {\n for (let r = 0, rl = _rows.length; r < rl; r++) {\n for (let c = 0, cl = _rows[r].cols.length; c < cl; c++) {\n if (_rows[r].cols[c].key == __key) {\n if (this.xvar.frozenRowIndex > __dindex) {\n GRID.body.repaintCell.call(this, \"top-\" + _panelName, __dindex, r, c, __value);\n } else {\n GRID.body.repaintCell.call(this, _panelName + \"-scroll\", __dindex, r, c, __value);\n }\n }\n }\n }\n };\n\n repaintCell.call(this, \"left-body\", this.leftBodyRowData.rows, _dindex, _key, _value);\n repaintCell.call(this, \"body\", this.bodyRowData.rows, _dindex, _key, _value);\n\n }\n\n return this;\n };\n\n /**\n * @method ax5grid.addColumn\n * @param {Object} _column\n * @param {Number|String} [_cindex=last]\n * @returns {ax5grid}\n */\n this.addColumn = (function () {\n let processor = {\n \"first\": function (_column) {\n this.config.columns = [].concat(_column).concat(this.config.columns);\n },\n \"last\": function (_column) {\n this.config.columns = this.config.columns.concat([].concat(_column));\n }\n };\n\n return function (_column, _cindex) {\n if (typeof _column === \"undefined\") throw '_column must not be null';\n if (typeof _cindex === \"undefined\") _cindex = \"last\";\n if (_cindex in processor) {\n processor[_cindex].call(this, _column);\n } else {\n if (!U.isNumber(_cindex)) {\n throw 'invalid argument _cindex';\n }\n this.config.columns.splice(_cindex, [].concat(_column))\n }\n onResetColumns.call(this); // 컬럼이 변경되었을 때.\n return this;\n }\n })();\n\n /**\n * @method ax5grid.removeCloumn\n * @param {Number|String} [_cindex=last]\n * @returns {ax5grid}\n */\n this.removeColumn = (function () {\n let processor = {\n \"first\": function (_cindex) {\n this.config.columns.splice(_cindex, 1);\n },\n \"last\": function () {\n this.config.columns.splice(this.config.columns.length - 1, 1);\n }\n };\n return function (_cindex) {\n if (typeof _cindex === \"undefined\") _cindex = \"last\";\n if (_cindex in processor) {\n processor[_cindex].call(this, _cindex);\n } else {\n if (!U.isNumber(_cindex)) {\n throw 'invalid argument _cindex';\n }\n //\n this.config.columns.splice(_cindex, 1);\n }\n onResetColumns.call(this); // 컬럼이 변경되었을 때.\n return this;\n }\n })();\n\n /**\n * @method ax5grid.updateColumn\n * @param {Object} _column\n * @param {Number} _cindex\n * @returns {ax5grid}\n */\n this.updateColumn = function (_column, _cindex) {\n if (!U.isNumber(_cindex)) {\n throw 'invalid argument _cindex';\n }\n //\n this.config.columns.splice(_cindex, 1, _column);\n onResetColumns.call(this); // 컬럼이 변경되었을 때.\n return this;\n };\n\n /**\n * @method ax5grid.setColumnWidth\n * @param {Number} _width\n * @param {Number} _cindex\n * @returns {ax5grid}\n */\n this.setColumnWidth = function (_width, _cindex) {\n this.colGroup[this.xvar.columnResizerIndex]._width = _width;\n this.needToPaintSum = true;\n\n // 컬럼너비 변경사항 적용.\n GRID.header.repaint.call(this);\n GRID.body.repaint.call(this, true);\n GRID.scroller.resize.call(this);\n\n alignGrid.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.getColumnSortInfo\n * @returns {Object} sortInfo\n */\n this.getColumnSortInfo = function () {\n let that = {sortInfo: []};\n for (let k in this.sortInfo) {\n that.sortInfo.push({\n key: k,\n orderBy: this.sortInfo[k].orderBy,\n seq: this.sortInfo[k].seq\n });\n }\n that.sortInfo.sort(function (a, b) {\n return a.seq > b.seq;\n });\n return that.sortInfo;\n };\n\n /**\n * @method ax5grid.setColumnSort\n * @param {Object} _sortInfo\n * @param {Object} _sortInfo.key\n * @param {Number} _sortInfo.key.seq - seq of sortOrder\n * @param {String} _sortInfo.key.orderBy - \"desc\"|\"asc\"\n * @returns {ax5grid}\n * @example\n * ```js\n * ax5grid.setColumnSort({a:{seq:0, orderBy:\"desc\"}, b:{seq:1, orderBy:\"asc\"}});\n * ```\n */\n this.setColumnSort = function (_sortInfo) {\n if (typeof _sortInfo !== \"undefined\") {\n this.sortInfo = _sortInfo;\n GRID.header.applySortStatus.call(this, _sortInfo);\n }\n\n sortColumns.call(this, _sortInfo || this.sortInfo);\n return this;\n };\n\n /**\n * @method ax5grid.select\n * @param {Number|Object} _selectObject\n * @param {Number} _selectObject.index - index of row\n * @param {Number} _selectObject.rowIndex - rowIndex of columns\n * @param {Number} _selectObject.conIndex - colIndex of columns\n * @param {Object} _options\n * @param {Boolean} _options.selectedClear\n * @param {Boolean} _options.selected\n * @returns {ax5grid}\n * @example\n * ```js\n * firstGrid.select(0);\n * firstGrid.select(0, {selected: true});\n * firstGrid.select(0, {selected: false});\n * firstGrid.select(0, {selectedClear: true});\n * ```\n */\n this.select = function (_selectObject, _options) {\n if (U.isNumber(_selectObject)) {\n let dindex = _selectObject;\n\n if (!this.config.multipleSelect) {\n this.clearSelect();\n } else {\n if (_options && _options.selectedClear) {\n this.clearSelect();\n }\n }\n\n GRID.data.select.call(this, dindex, _options && _options.selected);\n GRID.body.updateRowState.call(this, [\"selected\"], dindex);\n }\n return this;\n };\n\n /**\n * @method ax5grid.clearSelect\n * @returns {ax5grid}\n * @example\n * ```js\n * firstGrid.clearSelect();\n * ```\n */\n this.clearSelect = function () {\n GRID.body.updateRowState.call(this, [\"selectedClear\"]);\n GRID.data.clearSelect.call(this);\n return this;\n };\n\n /**\n * @method ax5grid.selectAll\n * @param {Object} _options\n * @param {Boolean} _options.selected\n * @param {Function} _options.filter\n * @returns {ax5grid}\n * @example\n * ```js\n * firstGrid.selectAll();\n * firstGrid.selectAll({selected: true});\n * firstGrid.selectAll({selected: false});\n * firstGrid.selectAll({filter: function(){\n * return this[\"b\"] == \"A01\";\n * });\n * firstGrid.selectAll({selected: true, filter: function(){\n * return this[\"b\"] == \"A01\";\n * });\n * ```\n */\n this.selectAll = function (_options) {\n GRID.data.selectAll.call(this, _options && _options.selected, _options);\n GRID.body.updateRowStateAll.call(this, [\"selected\"]);\n return this;\n };\n\n /**\n * @method ax5grid.exportExcel\n * @param {String} _fileName\n * @returns {ax5grid|String}\n * @example\n * ```js\n * firstGrid.exportExcel(\"grid-to-excel.xls\");\n * console.log(firstGrid.exportExcel());\n * ```\n */\n this.exportExcel = function (_fileName) {\n let table = [];\n table.push('');\n table.push(GRID.header.getExcelString.call(this));\n table.push(GRID.body.getExcelString.call(this));\n table.push('
');\n\n if (typeof _fileName === \"undefined\") {\n return table.join('');\n }\n else {\n GRID.excel.export.call(this, [table.join('')], _fileName);\n }\n\n return this;\n };\n\n /**\n * @method ax5grid.focus\n * @param {String|Number} _pos - UP, DOWN, LEFT, RIGHT, HOME, END\n * @returns {ax5grid}\n * @example\n * ```js\n * firstGrid.focus(\"UP\");\n * firstGrid.focus(\"DOWN\");\n * firstGrid.focus(\"HOME\");\n * firstGrid.focus(\"END\");\n * ```\n */\n this.focus = function (_pos) {\n if (GRID.body.moveFocus.call(this, _pos)) {\n let focusedColumn;\n for (let c in this.focusedColumn) {\n focusedColumn = jQuery.extend({}, this.focusedColumn[c], true);\n break;\n }\n if (focusedColumn) {\n this.select(focusedColumn.dindex, {selectedClear: true});\n }\n }\n else {\n if (typeof this.selectedDataIndexs[0] === \"undefined\") {\n this.select(0);\n } else {\n let selectedIndex = this.selectedDataIndexs[0];\n let processor = {\n \"UP\": function () {\n if (selectedIndex > 0) {\n this.select(selectedIndex - 1, {selectedClear: true});\n GRID.body.moveFocus.call(this, selectedIndex - 1);\n }\n },\n \"DOWN\": function () {\n if (selectedIndex < this.list.length - 1) {\n this.select(selectedIndex + 1, {selectedClear: true});\n GRID.body.moveFocus.call(this, selectedIndex + 1);\n }\n },\n \"HOME\": function () {\n this.select(0, {selectedClear: true});\n GRID.body.moveFocus.call(this, 0);\n },\n \"END\": function () {\n this.select(this.list.length - 1, {selectedClear: true});\n GRID.body.moveFocus.call(this, this.list.length - 1);\n }\n };\n\n if (_pos in processor) {\n processor[_pos].call(this);\n }\n }\n }\n return this;\n };\n\n // 클래스 생성자\n this.main = (function () {\n UI.grid_instance = UI.grid_instance || [];\n UI.grid_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }).apply(this, arguments);\n };\n return ax5grid;\n })());\n\n GRID = ax5.ui.grid;\n})();\n\n// todo : excel export\n// todo : merge cells\n// todo : filter\n// todo : body menu\n// todo : column reorder\n// todo : editor 필수값 속성 지정\n\n\n\n","// ax5.ui.grid.body\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var columnSelect = {\n focusClear: function () {\n var self = this;\n for (var c in self.focusedColumn) {\n var _column = self.focusedColumn[c];\n if (_column) {\n self.$.panel[_column.panelName]\n .find('[data-ax5grid-tr-data-index=\"' + _column.dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + _column.rowIndex + '\"][data-ax5grid-column-colindex=\"' + _column.colIndex + '\"]')\n .removeAttr('data-ax5grid-column-focused');\n }\n }\n self.focusedColumn = {};\n },\n clear: function () {\n var self = this;\n for (var c in self.selectedColumn) {\n var _column = self.selectedColumn[c];\n if (_column) {\n self.$.panel[_column.panelName]\n .find('[data-ax5grid-tr-data-index=\"' + _column.dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + _column.rowIndex + '\"][data-ax5grid-column-colindex=\"' + _column.colIndex + '\"]')\n .removeAttr('data-ax5grid-column-selected');\n }\n }\n self.selectedColumn = {};\n },\n init: function (column) {\n var self = this;\n if (this.isInlineEditing) {\n for (var editKey in this.inlineEditing) {\n if (editKey == column.dindex + \"_\" + column.colIndex + \"_\" + column.rowIndex) {\n return this;\n }\n }\n }\n\n // focus\n columnSelect.focusClear.call(self);\n self.focusedColumn[column.dindex + \"_\" + column.colIndex + \"_\" + column.rowIndex] = {\n panelName: column.panelName,\n dindex: column.dindex,\n rowIndex: column.rowIndex,\n colIndex: column.colIndex,\n colspan: column.colspan\n };\n\n // select\n columnSelect.clear.call(self);\n self.xvar.selectedRange = {\n start: [column.dindex, column.rowIndex, column.colIndex, column.colspan - 1],\n end: null\n };\n self.selectedColumn[column.dindex + \"_\" + column.colIndex + \"_\" + column.rowIndex] = (function (data) {\n if (data) {\n return false;\n } else {\n return {\n panelName: column.panelName,\n dindex: column.dindex,\n rowIndex: column.rowIndex,\n colIndex: column.colIndex,\n colspan: column.colspan\n }\n }\n })(self.selectedColumn[column.dindex + \"_\" + column.colIndex + \"_\" + column.rowIndex]);\n\n this.$.panel[column.panelName]\n .find('[data-ax5grid-tr-data-index=\"' + column.dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + column.rowIndex + '\"][data-ax5grid-column-colindex=\"' + column.colIndex + '\"]')\n .attr('data-ax5grid-column-focused', \"true\")\n .attr('data-ax5grid-column-selected', \"true\");\n\n if (this.isInlineEditing) {\n GRID.body.inlineEdit.deActive.call(this, \"RETURN\");\n }\n },\n update: function (column) {\n var self = this;\n var dindex, colIndex, rowIndex, trl;\n\n self.xvar.selectedRange[\"end\"] = [column.dindex, column.rowIndex, column.colIndex, column.colspan - 1];\n columnSelect.clear.call(self);\n\n var range = {\n r: {\n s: Math.min(self.xvar.selectedRange[\"start\"][0], self.xvar.selectedRange[\"end\"][0]),\n e: Math.max(self.xvar.selectedRange[\"start\"][0], self.xvar.selectedRange[\"end\"][0])\n },\n c: {\n s: Math.min(self.xvar.selectedRange[\"start\"][2], self.xvar.selectedRange[\"end\"][2]),\n e: Math.max(self.xvar.selectedRange[\"start\"][2] + self.xvar.selectedRange[\"start\"][3], self.xvar.selectedRange[\"end\"][2] + self.xvar.selectedRange[\"end\"][3])\n }\n };\n\n dindex = range.r.s;\n for (; dindex <= range.r.e; dindex++) {\n\n\n trl = this.bodyRowTable.rows.length;\n rowIndex = 0;\n for (; rowIndex < trl; rowIndex++) {\n colIndex = range.c.s;\n for (; colIndex <= range.c.e; colIndex++) {\n var _panels = [],\n panelName = \"\";\n\n if (self.xvar.frozenRowIndex > dindex) _panels.push(\"top\");\n if (self.xvar.frozenColumnIndex > colIndex) _panels.push(\"left\");\n _panels.push(\"body\");\n if (_panels[0] !== \"top\") _panels.push(\"scroll\");\n panelName = _panels.join(\"-\");\n\n self.selectedColumn[dindex + \"_\" + colIndex + \"_\" + rowIndex] = {\n panelName: panelName,\n dindex: dindex,\n rowIndex: rowIndex,\n colIndex: colIndex,\n colspan: column.colspan\n };\n\n _panels = null;\n panelName = null;\n }\n }\n }\n dindex = null;\n colIndex = null;\n rowIndex = null;\n\n for (var c in self.selectedColumn) {\n var _column = self.selectedColumn[c];\n if (_column) {\n self.$.panel[_column.panelName]\n .find('[data-ax5grid-tr-data-index=\"' + _column.dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + _column.rowIndex + '\"][data-ax5grid-column-colindex=\"' + _column.colIndex + '\"]')\n .attr('data-ax5grid-column-selected', 'true');\n }\n }\n\n }\n };\n\n var columnSelector = {\n \"on\": function (cell) {\n var self = this;\n\n if (this.inlineEditing[cell.dindex + \"_\" + cell.colIndex + \"_\" + cell.rowIndex]) {\n return;\n }\n\n columnSelect.init.call(self, cell);\n\n this.$[\"container\"][\"body\"]\n .on(\"mousemove.ax5grid-\" + this.instanceId, '[data-ax5grid-column-attr=\"default\"]', function (e) {\n if (this.getAttribute(\"data-ax5grid-column-rowIndex\")) {\n columnSelect.update.call(self, {\n panelName: this.getAttribute(\"data-ax5grid-panel-name\"),\n dindex: Number(this.getAttribute(\"data-ax5grid-data-index\")),\n rowIndex: Number(this.getAttribute(\"data-ax5grid-column-rowIndex\")),\n colIndex: Number(this.getAttribute(\"data-ax5grid-column-colIndex\")),\n colspan: Number(this.getAttribute(\"colspan\"))\n });\n U.stopEvent(e);\n }\n })\n .on(\"mouseup.ax5grid-\" + this.instanceId, function () {\n columnSelector.off.call(self);\n })\n .on(\"mouseleave.ax5grid-\" + this.instanceId, function () {\n columnSelector.off.call(self);\n });\n\n jQuery(document.body)\n .attr('unselectable', 'on')\n .css('user-select', 'none')\n .on('selectstart', false);\n },\n \"off\": function () {\n\n this.$[\"container\"][\"body\"]\n .off(\"mousemove.ax5grid-\" + this.instanceId)\n .off(\"mouseup.ax5grid-\" + this.instanceId)\n .off(\"mouseleave.ax5grid-\" + this.instanceId);\n\n jQuery(document.body)\n .removeAttr('unselectable')\n .css('user-select', 'auto')\n .off('selectstart');\n }\n };\n\n var updateRowState = function (_states, _dindex, _data) {\n var self = this;\n var cfg = this.config;\n\n var processor = {\n \"selected\": function (_dindex) {\n var i = this.$.livePanelKeys.length;\n while (i--) {\n this.$.panel[this.$.livePanelKeys[i]]\n .find('[data-ax5grid-tr-data-index=\"' + _dindex + '\"]')\n .attr(\"data-ax5grid-selected\", this.list[_dindex][cfg.columnKeys.selected]);\n }\n },\n \"selectedClear\": function () {\n var si = this.selectedDataIndexs.length;\n while (si--) {\n var dindex = this.selectedDataIndexs[si];\n var i = this.$.livePanelKeys.length;\n while (i--) {\n this.$.panel[this.$.livePanelKeys[i]]\n .find('[data-ax5grid-tr-data-index=\"' + dindex + '\"]')\n .attr(\"data-ax5grid-selected\", false);\n this.list[dindex][cfg.columnKeys.selected] = false;\n }\n }\n },\n \"cellChecked\": function (_dindex, _data) {\n var key = _data.key;\n var rowIndex = _data.rowIndex;\n var colIndex = _data.colIndex;\n\n var panelName = (function () {\n var _panels = [];\n if (this.xvar.frozenRowIndex > _dindex) _panels.push(\"top\");\n if (this.xvar.frozenColumnIndex > colIndex) _panels.push(\"left\");\n _panels.push(\"body\");\n if (_panels[0] !== \"top\") _panels.push(\"scroll\");\n return _panels.join(\"-\");\n }).call(this);\n\n this.$.panel[panelName]\n .find('[data-ax5grid-tr-data-index=\"' + _dindex + '\"]')\n .find('[data-ax5grid-column-rowIndex=\"' + rowIndex + '\"][data-ax5grid-column-colIndex=\"' + colIndex + '\"]')\n .find('[data-ax5grid-editor=\"checkbox\"]')\n .attr(\"data-ax5grid-checked\", '' + _data.checked);\n }\n };\n _states.forEach(function (_state) {\n if (!processor[_state]) throw 'invaild state name';\n processor[_state].call(self, _dindex, _data);\n });\n };\n\n var updateRowStateAll = function (_states, _data) {\n var self = this;\n var cfg = this.config;\n\n var processor = {\n \"selected\": function (_dindex) {\n GRID.body.repaint.call(this, true);\n }\n };\n _states.forEach(function (_state) {\n if (!processor[_state]) throw 'invaild state name';\n processor[_state].call(self, _data);\n });\n };\n\n var init = function () {\n var self = this;\n\n this.$[\"container\"][\"body\"].on(\"click\", '[data-ax5grid-column-attr]', function (e) {\n var panelName, attr, row, col, dindex, rowIndex, colIndex, disableSelection;\n var targetClick = {\n \"default\": function (_column) {\n var column = self.bodyRowMap[_column.rowIndex + \"_\" + _column.colIndex];\n var that = {\n self: self,\n page: self.page,\n list: self.list,\n item: self.list[_column.dindex],\n dindex: _column.dindex,\n rowIndex: _column.rowIndex,\n colIndex: _column.colIndex,\n column: column,\n value: self.list[_column.dindex][column.key]\n };\n\n if (column.editor && column.editor.type == \"checkbox\") { // todo : GRID.inlineEditor에서 처리 할수 있도록 구문 변경 필요.\n var value = GRID.data.getValue.call(self, _column.dindex, column.key);\n\n var checked, newValue;\n if (column.editor.config && column.editor.config.trueValue) {\n if (checked = !(value == column.editor.config.trueValue)) {\n newValue = column.editor.config.trueValue;\n } else {\n newValue = column.editor.config.falseValue;\n }\n } else {\n newValue = checked = (value == false || value == \"false\" || value < \"1\") ? \"true\" : \"false\";\n }\n\n GRID.data.setValue.call(self, _column.dindex, column.key, newValue);\n\n updateRowState.call(self, [\"cellChecked\"], _column.dindex, {\n key: column.key, rowIndex: _column.rowIndex, colIndex: _column.colIndex,\n editorConfig: column.editor.config, checked: checked\n });\n } else {\n if (self.config.body.onClick) {\n self.config.body.onClick.call(that);\n }\n }\n },\n \"rowSelector\": function (_column) {\n if (self.list[_column.dindex][self.config.columnKeys.disableSelection]) {\n return false;\n }\n\n if (!self.config.multipleSelect && self.selectedDataIndexs[0] !== _column.dindex) {\n GRID.body.updateRowState.call(self, [\"selectedClear\"]);\n GRID.data.clearSelect.call(self);\n }\n\n GRID.data.select.call(self, _column.dindex, undefined, {\n internalCall: true\n });\n updateRowState.call(self, [\"selected\"], _column.dindex);\n },\n \"lineNumber\": function (_column) {\n\n }\n };\n\n panelName = this.getAttribute(\"data-ax5grid-panel-name\");\n attr = this.getAttribute(\"data-ax5grid-column-attr\");\n row = Number(this.getAttribute(\"data-ax5grid-column-row\"));\n col = Number(this.getAttribute(\"data-ax5grid-column-col\"));\n rowIndex = Number(this.getAttribute(\"data-ax5grid-column-rowIndex\"));\n colIndex = Number(this.getAttribute(\"data-ax5grid-column-colIndex\"));\n dindex = Number(this.getAttribute(\"data-ax5grid-data-index\"));\n\n if (attr in targetClick) {\n targetClick[attr]({\n panelName: panelName,\n attr: attr,\n row: row,\n col: col,\n dindex: dindex,\n rowIndex: rowIndex,\n colIndex: colIndex\n });\n }\n });\n this.$[\"container\"][\"body\"].on(\"dblclick\", '[data-ax5grid-column-attr]', function (e) {\n var panelName, attr, row, col, dindex, rowIndex, colIndex;\n var targetClick = {\n \"default\": function (_column) {\n\n if (this.isInlineEditing) {\n for (var columnKey in this.inlineEditing) {\n if (columnKey == _column.dindex + \"_\" + _column.colIndex + \"_\" + _column.rowIndex) {\n return this;\n }\n }\n }\n\n var column = self.bodyRowMap[_column.rowIndex + \"_\" + _column.colIndex];\n var value = \"\";\n if (column) {\n if (!self.list[dindex].__isGrouping) {\n value = GRID.data.getValue.call(self, dindex, column.key);\n }\n }\n GRID.body.inlineEdit.active.call(self, self.focusedColumn, e, value);\n },\n \"rowSelector\": function (_column) {\n\n },\n \"lineNumber\": function (_column) {\n\n }\n };\n\n panelName = this.getAttribute(\"data-ax5grid-panel-name\");\n attr = this.getAttribute(\"data-ax5grid-column-attr\");\n row = Number(this.getAttribute(\"data-ax5grid-column-row\"));\n col = Number(this.getAttribute(\"data-ax5grid-column-col\"));\n rowIndex = Number(this.getAttribute(\"data-ax5grid-column-rowIndex\"));\n colIndex = Number(this.getAttribute(\"data-ax5grid-column-colIndex\"));\n dindex = Number(this.getAttribute(\"data-ax5grid-data-index\"));\n\n if (attr in targetClick) {\n targetClick[attr]({\n panelName: panelName,\n attr: attr,\n row: row,\n col: col,\n dindex: dindex,\n rowIndex: rowIndex,\n colIndex: colIndex\n });\n }\n });\n this.$[\"container\"][\"body\"].on(\"mouseover\", \"tr\", function () {\n return;\n var dindex = this.getAttribute(\"data-ax5grid-tr-data-index\");\n var i = self.$.livePanelKeys.length;\n while (i--) {\n if (typeof self.xvar.dataHoveredIndex !== \"undefined\") self.$.panel[self.$.livePanelKeys[i]].find('[data-ax5grid-tr-data-index=\"' + self.xvar.dataHoveredIndex + '\"]').removeClass(\"hover\");\n self.$.panel[self.$.livePanelKeys[i]].find('[data-ax5grid-tr-data-index=\"' + dindex + '\"]').addClass(\"hover\");\n }\n self.xvar.dataHoveredIndex = dindex;\n });\n this.$[\"container\"][\"body\"]\n .on(\"mousedown\", '[data-ax5grid-column-attr=\"default\"]', function (e) {\n if(self.xvar.touchmoved) return false;\n if (this.getAttribute(\"data-ax5grid-column-rowIndex\")) {\n columnSelector.on.call(self, {\n panelName: this.getAttribute(\"data-ax5grid-panel-name\"),\n dindex: Number(this.getAttribute(\"data-ax5grid-data-index\")),\n rowIndex: Number(this.getAttribute(\"data-ax5grid-column-rowIndex\")),\n colIndex: Number(this.getAttribute(\"data-ax5grid-column-colIndex\")),\n colspan: Number(this.getAttribute(\"colspan\"))\n });\n }\n })\n .on(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n resetFrozenColumn.call(this);\n };\n\n var resetFrozenColumn = function () {\n var cfg = this.config;\n var dividedBodyRowObj = GRID.util.divideTableByFrozenColumnIndex(this.bodyRowTable, this.xvar.frozenColumnIndex);\n this.asideBodyRowData = (function (dataTable) {\n var data = {rows: []};\n for (var i = 0, l = dataTable.rows.length; i < l; i++) {\n data.rows[i] = {cols: []};\n if (i === 0) {\n var col = {\n label: \"\",\n colspan: 1,\n rowspan: dataTable.rows.length,\n colIndex: null\n }, _col = {};\n\n if (cfg.showLineNumber) {\n _col = jQuery.extend({}, col, {\n width: cfg.lineNumberColumnWidth,\n _width: cfg.lineNumberColumnWidth,\n columnAttr: \"lineNumber\",\n label: \" \", key: \"__d-index__\"\n });\n data.rows[i].cols.push(_col);\n }\n if (cfg.showRowSelector) {\n _col = jQuery.extend({}, col, {\n width: cfg.rowSelectorColumnWidth,\n _width: cfg.rowSelectorColumnWidth,\n columnAttr: \"rowSelector\",\n label: \"\", key: \"__d-checkbox__\"\n });\n data.rows[i].cols.push(_col);\n }\n }\n }\n\n return data;\n }).call(this, this.bodyRowTable);\n this.leftBodyRowData = dividedBodyRowObj.leftData;\n this.bodyRowData = dividedBodyRowObj.rightData;\n\n if (cfg.body.grouping) {\n var dividedBodyGroupingObj = GRID.util.divideTableByFrozenColumnIndex(this.bodyGroupingTable, this.xvar.frozenColumnIndex);\n this.asideBodyGroupingData = (function (dataTable) {\n var data = {rows: []};\n for (var i = 0, l = dataTable.rows.length; i < l; i++) {\n data.rows[i] = {cols: []};\n if (i === 0) {\n var col = {\n label: \"\",\n colspan: 1,\n rowspan: dataTable.rows.length,\n colIndex: null\n }, _col = {};\n\n if (cfg.showLineNumber) {\n _col = jQuery.extend({}, col, {\n width: cfg.lineNumberColumnWidth,\n _width: cfg.lineNumberColumnWidth,\n columnAttr: \"lineNumber\",\n label: \" \", key: \"__d-index__\"\n });\n data.rows[i].cols.push(_col);\n }\n if (cfg.showRowSelector) {\n _col = jQuery.extend({}, col, {\n width: cfg.rowSelectorColumnWidth,\n _width: cfg.rowSelectorColumnWidth,\n columnAttr: \"rowSelector\",\n label: \"\", key: \"__d-checkbox__\"\n });\n data.rows[i].cols.push(_col);\n }\n }\n }\n\n return data;\n }).call(this, this.bodyGroupingTable);\n this.leftBodyGroupingData = dividedBodyGroupingObj.leftData;\n this.bodyGroupingData = dividedBodyGroupingObj.rightData;\n }\n\n this.leftFootSumData = {};\n this.footSumData = {};\n if (this.config.footSum) {\n var dividedFootSumObj = GRID.util.divideTableByFrozenColumnIndex(this.footSumTable, this.xvar.frozenColumnIndex);\n this.leftFootSumData = dividedFootSumObj.leftData;\n this.footSumData = dividedFootSumObj.rightData;\n }\n };\n\n var getFieldValue = function (_list, _item, _index, _col, _value, _returnPlainText) {\n let _key = _col.key, tagsToReplace = {\n '<': '<',\n '>': '>'\n };\n\n if (_key === \"__d-index__\") {\n return (typeof _item[\"__index\"] !== \"undefined\") ? _item[\"__index\"] + 1 : \"\";\n }\n else if (_key === \"__d-checkbox__\") {\n return '';\n }\n else {\n if (_col.editor && (function (_editor) {\n if (_editor.type in GRID.inlineEditor) {\n return (GRID.inlineEditor[_editor.type].editMode == \"inline\");\n }\n return false;\n })(_col.editor)) {\n\n _value = _value || GRID.data.getValue.call(this, _index, _key);\n \n if (U.isFunction(_col.editor.disabled)) {\n if (_col.editor.disabled.call({\n list: _list,\n dindex: _index,\n item: _list[_index],\n key: _key,\n value: _value\n })) {\n return _value;\n }\n }\n\n // print editor\n return _returnPlainText ? _value : GRID.inlineEditor[_col.editor.type].getHtml(this, _col.editor, _value);\n }\n if (_col.formatter) {\n var that = {\n key: _key,\n value: _value || GRID.data.getValue.call(this, _index, _key),\n dindex: _index,\n item: _item,\n list: _list\n };\n if (U.isFunction(_col.formatter)) {\n return _col.formatter.call(that);\n } else {\n return GRID.formatter[_col.formatter].call(that);\n }\n }\n else {\n var returnValue = \"\";\n\n if (typeof _value !== \"undefined\") {\n returnValue = _value;\n } else {\n _value = GRID.data.getValue.call(this, _index, _key);\n if (_value !== null && typeof _value !== \"undefined\") returnValue = _value;\n }\n\n return (typeof returnValue === \"number\") ? returnValue : returnValue.replace(/[<>]/g, function (tag) {\n return tagsToReplace[tag] || tag;\n });\n }\n }\n };\n\n var getGroupingValue = function (_item, _index, _col) {\n var value, that, _key = _col.key, _label = _col.label;\n\n if (typeof _key === \"undefined\") {\n that = {\n key: _key,\n list: _item.__groupingList,\n groupBy: _item.__groupingBy\n };\n if (U.isFunction(_label)) {\n value = _label.call(that);\n } else {\n value = _label;\n }\n _item[_col.colIndex] = value;\n return value;\n }\n else if (_key === \"__d-index__\") {\n return '';\n }\n else if (_key === \"__d-checkbox__\") {\n return '';\n }\n else {\n if (_col.collector) {\n that = {\n key: _key,\n list: _item.__groupingList\n };\n if (U.isFunction(_col.collector)) {\n value = _col.collector.call(that);\n } else {\n value = GRID.collector[_col.collector].call(that);\n }\n _item[_col.colIndex] = value;\n\n if (_col.formatter) {\n that.value = value;\n if (U.isFunction(_col.formatter)) {\n return _col.formatter.call(that);\n } else {\n return GRID.formatter[_col.formatter].call(that);\n }\n } else {\n return value;\n }\n } else {\n return \" \";\n }\n }\n };\n\n var getSumFieldValue = function (_list, _col) {\n var _key = _col.key, _label = _col.label;\n //, _collector, _formatter\n if (typeof _key === \"undefined\") {\n return _label;\n }\n else if (_key === \"__d-index__\" || _key === \"__d-checkbox__\") {\n return ' ';\n }\n else {\n if (_col.collector) {\n var that = {\n key: _key,\n list: _list\n };\n var value;\n if (U.isFunction(_col.collector)) {\n value = _col.collector.call(that);\n } else {\n value = GRID.collector[_col.collector].call(that);\n }\n\n if (_col.formatter) {\n that.value = value;\n if (U.isFunction(_col.formatter)) {\n return _col.formatter.call(that);\n } else {\n return GRID.formatter[_col.formatter].call(that);\n }\n } else {\n return value;\n }\n\n } else {\n return \" \";\n }\n }\n };\n\n let repaint = function (_reset) {\n let cfg = this.config,\n list = this.list;\n\n /// repaint reset 타입이면 고정컬럼을 재조정\n if (_reset) {\n resetFrozenColumn.call(this);\n // 틀고정 이 변경되면 출력 시작 인덱스 값을 초기화\n this.xvar.paintStartRowIndex = undefined;\n }\n\n /// 출력시작 인덱스\n let paintStartRowIndex = Math.floor(Math.abs(this.$.panel[\"body-scroll\"].position().top) / this.xvar.bodyTrHeight) + this.xvar.frozenRowIndex;\n if (this.xvar.dataRowCount === list.length && this.xvar.paintStartRowIndex === paintStartRowIndex) return this; // 스크롤 포지션 변경 여부에 따라 프로세스 진행여부 결정\n\n let isFirstPaint = (typeof this.xvar.paintStartRowIndex === \"undefined\"),\n asideBodyRowData = this.asideBodyRowData,\n leftBodyRowData = this.leftBodyRowData,\n bodyRowData = this.bodyRowData,\n leftFootSumData = this.leftFootSumData,\n footSumData = this.footSumData,\n asideBodyGroupingData = this.asideBodyGroupingData,\n leftBodyGroupingData = this.leftBodyGroupingData,\n bodyGroupingData = this.bodyGroupingData,\n bodyAlign = cfg.body.align,\n paintRowCount = Math.ceil(this.$.panel[\"body\"].height() / this.xvar.bodyTrHeight) + 1;\n\n if (document.addEventListener && ax5.info.supportTouch) {\n paintRowCount = paintRowCount * 2;\n }\n\n /// 스크롤 컨텐츠의 높이 : 그리드 스크롤의 실제 크기와는 관계 없이 데이터 갯수에 따라 스크롤 컨텐츠 높이값 구해서 저장해두기.\n this.xvar.scrollContentHeight = this.xvar.bodyTrHeight * (this.list.length - this.xvar.frozenRowIndex);\n /// 사용된 패널들의 키 모음\n this.$.livePanelKeys = [];\n\n // 그리드 바디 영역 페인트 함수\n let repaintBody = function (_elTargetKey, _colGroup, _bodyRow, _groupRow, _list, _scrollConfig) {\n let _elTarget = this.$.panel[_elTargetKey];\n\n if (!isFirstPaint && !_scrollConfig) {\n this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고)\n return false;\n }\n\n let SS = [], cgi, cgl, di, dl, tri, trl, ci, cl, col, cellHeight, colAlign, isScrolled = (function () {\n // 스크롤값이 변경되거나 처음 호출되었습니까?\n if (typeof _scrollConfig === \"undefined\" || typeof _scrollConfig['paintStartRowIndex'] === \"undefined\") {\n _scrollConfig = {\n paintStartRowIndex: 0,\n paintRowCount: _list.length\n };\n return false;\n } else {\n return true;\n }\n })();\n\n if (isScrolled) {\n SS.push('');\n }\n SS.push('');\n SS.push('');\n for (cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n }\n SS.push('');\n SS.push('');\n\n for (di = _scrollConfig.paintStartRowIndex, dl = (function () {\n let len;\n len = _list.length;\n if (_scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex < len) {\n len = _scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex;\n }\n return len;\n })(); di < dl; di++) {\n\n let isGroupingRow = false, rowTable;\n if (_groupRow && \"__isGrouping\" in _list[di]) {\n rowTable = _groupRow;\n isGroupingRow = true;\n } else {\n rowTable = _bodyRow;\n }\n\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n\n SS.push('');\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push((function (_cellHeight) {\n let lineHeight = (cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth);\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n\n })(cellHeight), (isGroupingRow) ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n }\n SS.push('
');\n\n if (isScrolled && _list.length) {\n SS.push('');\n }\n\n _elTarget.empty().get(0).innerHTML = SS.join('');\n\n this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고)\n return true;\n };\n let repaintSum = function (_elTargetKey, _colGroup, _bodyRow, _list, _scrollConfig) {\n let _elTarget = this.$.panel[_elTargetKey];\n\n if (!isFirstPaint && !_scrollConfig) {\n this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고)\n return false;\n }\n\n let SS = [], cgi, cgl, tri, trl, ci, cl, col, cellHeight, colAlign;\n\n SS.push('');\n SS.push('');\n for (cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n }\n SS.push('');\n SS.push('');\n\n for (tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('');\n for (ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n col = _bodyRow.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push((function (_cellHeight) {\n var lineHeight = (cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth);\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n\n })(cellHeight), getSumFieldValue.call(this, _list, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n\n SS.push('
');\n\n _elTarget.empty().get(0).innerHTML = SS.join('');\n this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고)\n return true;\n };\n let scrollConfig = {\n paintStartRowIndex: paintStartRowIndex,\n paintRowCount: paintRowCount,\n bodyTrHeight: this.xvar.bodyTrHeight\n };\n\n // aside\n if (cfg.asidePanelWidth > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n repaintBody.call(this, \"top-aside-body\", this.asideColGroup, asideBodyRowData, asideBodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n }\n\n repaintBody.call(this, \"aside-body-scroll\", this.asideColGroup, asideBodyRowData, asideBodyGroupingData, list, scrollConfig);\n\n if (cfg.footSum) {\n // 바닥 요약 (footSum에 대한 aside 사용안함)\n //repaintSum.call(this, \"bottom-aside-body\", this.asideColGroup, asideBodyRowData, null, list);\n }\n }\n\n // left\n if (this.xvar.frozenColumnIndex > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n repaintBody.call(this, \"top-left-body\", this.leftHeaderColGroup, leftBodyRowData, leftBodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n }\n\n repaintBody.call(this, \"left-body-scroll\", this.leftHeaderColGroup, leftBodyRowData, leftBodyGroupingData, list, scrollConfig);\n\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-left-body\", this.leftHeaderColGroup, leftFootSumData, list);\n }\n }\n\n // body\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n repaintBody.call(this, \"top-body-scroll\", this.headerColGroup, bodyRowData, bodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n }\n\n repaintBody.call(this, \"body-scroll\", this.headerColGroup, bodyRowData, bodyGroupingData, list, scrollConfig);\n\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-body-scroll\", this.headerColGroup, footSumData, list, scrollConfig);\n }\n\n //todo : repaintBody 에서 footSum 데이터 예외처리\n // right\n if (cfg.rightSum) {\n // todo : right 표현 정리\n }\n\n this.xvar.paintStartRowIndex = paintStartRowIndex;\n this.xvar.paintRowCount = paintRowCount;\n this.xvar.dataRowCount = list.length;\n this.needToPaintSum = false;\n GRID.page.statusUpdate.call(this);\n };\n\n var repaintCell = function (_panelName, _dindex, _rowIndex, _colIndex, _newValue) {\n var self = this;\n var cfg = this.config;\n var list = this.list;\n\n var updateCell = this.$[\"panel\"][_panelName]\n .find('[data-ax5grid-tr-data-index=\"' + _dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + _rowIndex + '\"][data-ax5grid-column-colindex=\"' + _colIndex + '\"]')\n .find('[data-ax5grid-cellholder]');\n var colGroup = this.colGroup;\n var col = colGroup[_colIndex];\n\n updateCell.html(getFieldValue.call(this, list, list[_dindex], _dindex, col));\n\n if (col.editor && col.editor.updateWith) {\n col.editor.updateWith.forEach(function (updateColumnKey) {\n colGroup.forEach(function (col) {\n if (col.key == updateColumnKey) {\n var rowIndex = col.rowIndex;\n var colIndex = col.colIndex;\n var panelName = GRID.util.findPanelByColumnIndex.call(self, _dindex, colIndex, rowIndex).panelName;\n var updateWithCell = self.$[\"panel\"][panelName]\n .find('[data-ax5grid-tr-data-index=\"' + _dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + rowIndex + '\"][data-ax5grid-column-colindex=\"' + colIndex + '\"]')\n .find('[data-ax5grid-cellholder]');\n updateWithCell.html(getFieldValue.call(self, list, list[_dindex], _dindex, col));\n }\n });\n });\n }\n\n /// ~~~~~~\n\n var paintStartRowIndex = Math.floor(Math.abs(this.$.panel[\"body-scroll\"].position().top) / this.xvar.bodyTrHeight) + this.xvar.frozenRowIndex;\n var leftFootSumData = this.leftFootSumData;\n var footSumData = this.footSumData;\n var asideBodyGroupingData = this.asideBodyGroupingData;\n var leftBodyGroupingData = this.leftBodyGroupingData;\n var bodyGroupingData = this.bodyGroupingData;\n var bodyAlign = cfg.body.align;\n var paintRowCount = Math.ceil(this.$.panel[\"body\"].height() / this.xvar.bodyTrHeight) + 1;\n var scrollConfig = {\n paintStartRowIndex: paintStartRowIndex,\n paintRowCount: paintRowCount,\n bodyTrHeight: this.xvar.bodyTrHeight\n };\n\n var repaintSum = function (_elTargetKey, _colGroup, _bodyRow, _list, _scrollConfig) {\n var _elTarget = this.$.panel[_elTargetKey];\n\n var SS = [];\n var cgi, cgl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n\n SS.push('');\n SS.push('');\n for (cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n }\n SS.push('');\n SS.push('');\n\n for (tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('');\n for (ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n col = _bodyRow.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push((function (_cellHeight) {\n var lineHeight = (cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth);\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n\n })(cellHeight), getSumFieldValue.call(this, _list, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n\n SS.push('
');\n\n _elTarget.empty().get(0).innerHTML = SS.join('');\n return true;\n };\n var replaceGroupTr = function (_elTargetKey, _colGroup, _groupRow, _list, _scrollConfig) {\n var _elTarget = this.$.panel[_elTargetKey];\n var SS = [];\n var cgi, cgl;\n var di, dl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n for (di = _scrollConfig.paintStartRowIndex, dl = (function () {\n var len;\n len = _list.length;\n if (_scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex < len) {\n len = _scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex;\n }\n return len;\n })(); di < dl; di++) {\n if (_groupRow && \"__isGrouping\" in _list[di]) {\n var rowTable = _groupRow;\n SS = [];\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push((function (_cellHeight) {\n var lineHeight = (cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth);\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n\n })(cellHeight), getGroupingValue.call(this, _list[di], di, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n }\n _elTarget.find('tr[data-ax5grid-tr-data-index=\"' + di + '\"]').empty().get(0).innerHTML = SS.join('');\n }\n }\n };\n\n // body.grouping tr 다시 그리기..\n if (cfg.body.grouping) {\n // left\n if (this.xvar.frozenColumnIndex > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceGroupTr.call(this, \"top-left-body\", this.leftHeaderColGroup, leftBodyGroupingData, list.slice(0, this.xvar.frozenRowIndex), {\n paintStartRowIndex: 0,\n paintRowCount: this.xvar.frozenRowIndex,\n bodyTrHeight: this.xvar.bodyTrHeight\n });\n }\n replaceGroupTr.call(this, \"left-body-scroll\", this.leftHeaderColGroup, leftBodyGroupingData, list, scrollConfig);\n }\n\n // body\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceGroupTr.call(this, \"top-body-scroll\", this.headerColGroup, bodyGroupingData, list.slice(0, this.xvar.frozenRowIndex), {\n paintStartRowIndex: 0,\n paintRowCount: this.xvar.frozenRowIndex,\n bodyTrHeight: this.xvar.bodyTrHeight\n });\n }\n\n replaceGroupTr.call(this, \"body-scroll\", this.headerColGroup, bodyGroupingData, list, scrollConfig);\n }\n\n if (this.xvar.frozenColumnIndex > 0) {\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-left-body\", this.leftHeaderColGroup, leftFootSumData, list);\n }\n }\n\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-body-scroll\", this.headerColGroup, footSumData, list, scrollConfig);\n }\n };\n\n var repaintRow = function (_dindex) {\n var self = this,\n cfg = this.config,\n list = this.list;\n /// ~~~~~~\n\n var paintStartRowIndex = Math.floor(Math.abs(this.$.panel[\"body-scroll\"].position().top) / this.xvar.bodyTrHeight) + this.xvar.frozenRowIndex;\n var asideBodyRowData = this.asideBodyRowData;\n var leftBodyRowData = this.leftBodyRowData;\n var bodyRowData = this.bodyRowData;\n var leftFootSumData = this.leftFootSumData;\n var footSumData = this.footSumData;\n var asideBodyGroupingData = this.asideBodyGroupingData;\n var leftBodyGroupingData = this.leftBodyGroupingData;\n var bodyGroupingData = this.bodyGroupingData;\n var bodyAlign = cfg.body.align;\n var paintRowCount = Math.ceil(this.$.panel[\"body\"].height() / this.xvar.bodyTrHeight) + 1;\n var scrollConfig = {\n paintStartRowIndex: paintStartRowIndex,\n paintRowCount: paintRowCount,\n bodyTrHeight: this.xvar.bodyTrHeight\n };\n\n var repaintSum = function (_elTargetKey, _colGroup, _bodyRow, _list) {\n var _elTarget = this.$.panel[_elTargetKey];\n\n var SS = [];\n var cgi, cgl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n\n SS.push('');\n SS.push('');\n for (cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n }\n SS.push('');\n SS.push('');\n\n for (tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('');\n for (ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n col = _bodyRow.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push((function (_cellHeight) {\n var lineHeight = (cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth);\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n\n })(cellHeight), getSumFieldValue.call(this, _list, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n\n SS.push('
');\n\n _elTarget.empty().get(0).innerHTML = SS.join('');\n return true;\n };\n var replaceGroupTr = function (_elTargetKey, _colGroup, _groupRow, _list, _scrollConfig) {\n var _elTarget = this.$.panel[_elTargetKey];\n var SS = [];\n var cgi, cgl;\n var di, dl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n for (di = _scrollConfig.paintStartRowIndex, dl = (function () {\n var len;\n len = _list.length;\n if (_scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex < len) {\n len = _scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex;\n }\n return len;\n })(); di < dl; di++) {\n if (_groupRow && \"__isGrouping\" in _list[di]) {\n var rowTable = _groupRow;\n SS = [];\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push((function (_cellHeight) {\n var lineHeight = (cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth);\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n\n })(cellHeight), getGroupingValue.call(this, _list[di], di, col), '');\n\n SS.push(' | ');\n }\n SS.push(' | ');\n }\n _elTarget.find('tr[data-ax5grid-tr-data-index=\"' + di + '\"]').empty().get(0).innerHTML = SS.join('');\n }\n }\n };\n var replaceTr = function (_elTargetKey, _colGroup, _bodyRow, _list, di) {\n var _elTarget = this.$.panel[_elTargetKey];\n var SS = [];\n var cgi, cgl;\n var di, dl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n var rowTable = _bodyRow;\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n cellHeight = cfg.body.columnHeight * col.rowspan - cfg.body.columnBorderWidth;\n colAlign = col.align || bodyAlign;\n\n SS.push('');\n\n SS.push((function (_cellHeight) {\n var lineHeight = (cfg.body.columnHeight - cfg.body.columnPadding * 2 - cfg.body.columnBorderWidth);\n if (!col.multiLine) {\n _cellHeight = cfg.body.columnHeight - cfg.body.columnBorderWidth;\n }\n\n return '';\n\n })(cellHeight), getFieldValue.call(this, _list, _list[di], di, col), '');\n SS.push(' | ');\n }\n SS.push(' | ');\n }\n\n //_elTarget.find('tr[data-ax5grid-tr-data-index=\"' + di + '\"]').html(SS.join(''));\n _elTarget.find('tr[data-ax5grid-tr-data-index=\"' + di + '\"]').empty().get(0).innerHTML = SS.join('');\n };\n\n\n // left\n if (this.xvar.frozenColumnIndex > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceTr.call(this, \"top-left-body\", this.leftHeaderColGroup, leftBodyRowData, list, _dindex);\n\n }\n replaceTr.call(this, \"left-body-scroll\", this.leftHeaderColGroup, leftBodyRowData, list, _dindex);\n }\n\n // body\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceTr.call(this, \"top-body-scroll\", this.headerColGroup, bodyRowData, list, _dindex);\n }\n\n replaceTr.call(this, \"body-scroll\", this.headerColGroup, bodyRowData, list, _dindex);\n\n // body.grouping tr 다시 그리기..\n if (cfg.body.grouping) {\n // left\n if (this.xvar.frozenColumnIndex > 0) {\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceGroupTr.call(this, \"top-left-body\", this.leftHeaderColGroup, leftBodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n\n }\n replaceGroupTr.call(this, \"left-body-scroll\", this.leftHeaderColGroup, leftBodyGroupingData, list, scrollConfig);\n }\n\n // body\n if (this.xvar.frozenRowIndex > 0) {\n // 상단 행고정\n replaceGroupTr.call(this, \"top-body-scroll\", this.headerColGroup, bodyGroupingData, list.slice(0, this.xvar.frozenRowIndex));\n }\n\n replaceGroupTr.call(this, \"body-scroll\", this.headerColGroup, bodyGroupingData, list, scrollConfig);\n }\n\n if (this.xvar.frozenColumnIndex > 0) {\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-left-body\", this.leftHeaderColGroup, leftFootSumData, list);\n }\n }\n\n if (cfg.footSum && this.needToPaintSum) {\n // 바닥 요약\n repaintSum.call(this, \"bottom-body-scroll\", this.headerColGroup, footSumData, list, scrollConfig);\n }\n };\n\n var scrollTo = function (css, noRepaint) {\n var cfg = this.config;\n\n if (this.isInlineEditing) {\n for (var key in this.inlineEditing) {\n //if(this.inlineEditing[key].editor.type === \"select\") {}\n // 인라인 에디팅 인데 스크롤 이벤트가 발생하면 디액티브 처리\n GRID.body.inlineEdit.deActive.call(this, \"ESC\", key);\n }\n }\n\n if (cfg.asidePanelWidth > 0 && \"top\" in css) {\n this.$.panel[\"aside-body-scroll\"].css({top: css.top});\n }\n if (this.xvar.frozenColumnIndex > 0 && \"top\" in css) {\n this.$.panel[\"left-body-scroll\"].css({top: css.top});\n }\n if (this.xvar.frozenRowIndex > 0 && \"left\" in css) {\n this.$.panel[\"top-body-scroll\"].css({left: css.left});\n }\n\n this.$.panel[\"body-scroll\"].css(css);\n\n if (cfg.footSum && \"left\" in css) {\n this.$.panel[\"bottom-body-scroll\"].css({left: css.left});\n }\n\n if (!noRepaint && \"top\" in css) {\n repaint.call(this);\n } else {\n\n }\n };\n\n var blur = function () {\n columnSelect.focusClear.call(this);\n columnSelect.clear.call(this);\n if (this.isInlineEditing) {\n inlineEdit.deActive.call(this);\n }\n };\n\n let moveFocus = function (_position) {\n let focus = {\n \"UD\": function (_dy) {\n let moveResult = true,\n focusedColumn, originalColumn, while_i;\n\n for (let c in this.focusedColumn) {\n focusedColumn = jQuery.extend({}, this.focusedColumn[c], true);\n break;\n }\n\n if (!focusedColumn) return false;\n\n originalColumn = this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex];\n columnSelect.focusClear.call(this);\n columnSelect.clear.call(this);\n\n if (_dy > 0) {\n if (focusedColumn.rowIndex + (originalColumn.rowspan - 1) + _dy > this.bodyRowTable.rows.length - 1) {\n focusedColumn.dindex = focusedColumn.dindex + _dy;\n focusedColumn.rowIndex = 0;\n if (focusedColumn.dindex > this.list.length - 1) {\n focusedColumn.dindex = this.list.length - 1;\n moveResult = false;\n }\n } else {\n focusedColumn.rowIndex = focusedColumn.rowIndex + _dy;\n }\n }\n else {\n if (focusedColumn.rowIndex + _dy < 0) {\n focusedColumn.dindex = focusedColumn.dindex + _dy;\n focusedColumn.rowIndex = this.bodyRowTable.rows.length - 1;\n if (focusedColumn.dindex < 0) {\n focusedColumn.dindex = 0;\n moveResult = false;\n }\n } else {\n focusedColumn.rowIndex = focusedColumn.rowIndex + _dy;\n }\n }\n\n while_i = 0;\n while (typeof this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex] === \"undefined\") {\n if (focusedColumn.rowIndex == 0 || while_i % 2 == ((_dy > 0) ? 0 : 1)) {\n focusedColumn.colIndex--;\n } else {\n focusedColumn.rowIndex--;\n }\n\n if (focusedColumn.rowIndex <= 0 && focusedColumn.colIndex <= 0) {\n // find fail\n moveResult = false;\n break;\n }\n while_i++;\n }\n\n var nPanelInfo = GRID.util.findPanelByColumnIndex.call(this, focusedColumn.dindex, focusedColumn.colIndex);\n focusedColumn.panelName = nPanelInfo.panelName;\n\n // 포커스 컬럼의 위치에 따라 스크롤 처리.\n (function () {\n if (focusedColumn.dindex + 1 > this.xvar.frozenRowIndex) {\n if (focusedColumn.dindex <= this.xvar.paintStartRowIndex) {\n scrollTo.call(this, {top: -(focusedColumn.dindex - this.xvar.frozenRowIndex) * this.xvar.bodyTrHeight});\n GRID.scroller.resize.call(this);\n }\n else if (focusedColumn.dindex + 1 > this.xvar.paintStartRowIndex + (this.xvar.paintRowCount - 2)) {\n scrollTo.call(this, {top: -(focusedColumn.dindex - this.xvar.frozenRowIndex - this.xvar.paintRowCount + 3) * this.xvar.bodyTrHeight});\n GRID.scroller.resize.call(this);\n }\n }\n }).call(this);\n\n this.focusedColumn[focusedColumn.dindex + \"_\" + focusedColumn.colIndex + \"_\" + focusedColumn.rowIndex] = focusedColumn;\n this.$.panel[focusedColumn.panelName]\n .find('[data-ax5grid-tr-data-index=\"' + focusedColumn.dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + focusedColumn.rowIndex + '\"][data-ax5grid-column-colindex=\"' + focusedColumn.colIndex + '\"]')\n .attr('data-ax5grid-column-focused', \"true\");\n\n return moveResult;\n\n },\n \"LR\": function (_dx) {\n var moveResult = true;\n var focusedColumn;\n var originalColumn;\n var while_i = 0;\n var isScrollPanel = false;\n var containerPanelName = \"\";\n\n for (var c in this.focusedColumn) {\n focusedColumn = jQuery.extend({}, this.focusedColumn[c], true);\n break;\n }\n if (!focusedColumn) return false;\n\n originalColumn = this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex];\n\n columnSelect.focusClear.call(this);\n columnSelect.clear.call(this);\n\n if (_dx < 0) {\n focusedColumn.colIndex = focusedColumn.colIndex + _dx;\n if (focusedColumn.colIndex < 0) {\n focusedColumn.colIndex = 0;\n moveResult = false;\n }\n } else {\n focusedColumn.colIndex = focusedColumn.colIndex + (originalColumn.colspan - 1) + _dx;\n if (focusedColumn.colIndex > this.colGroup.length - 1) {\n focusedColumn.colIndex = this.colGroup.length - 1;\n moveResult = false;\n }\n }\n\n if (typeof this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex] === \"undefined\") {\n focusedColumn.rowIndex = 0;\n }\n while_i = 0;\n while (typeof this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex] === \"undefined\") {\n focusedColumn.colIndex--;\n if (focusedColumn.rowIndex <= 0 && focusedColumn.colIndex <= 0) {\n // find fail\n moveResult = false;\n break;\n }\n while_i++;\n }\n\n var nPanelInfo = GRID.util.findPanelByColumnIndex.call(this, focusedColumn.dindex, focusedColumn.colIndex);\n\n focusedColumn.panelName = nPanelInfo.panelName;\n containerPanelName = nPanelInfo.containerPanelName;\n isScrollPanel = nPanelInfo.isScrollPanel;\n\n this.focusedColumn[focusedColumn.dindex + \"_\" + focusedColumn.colIndex + \"_\" + focusedColumn.rowIndex] = focusedColumn;\n\n var $column = this.$.panel[focusedColumn.panelName]\n .find('[data-ax5grid-tr-data-index=\"' + focusedColumn.dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + focusedColumn.rowIndex + '\"][data-ax5grid-column-colindex=\"' + focusedColumn.colIndex + '\"]')\n .attr('data-ax5grid-column-focused', \"true\");\n\n\n if ($column && isScrollPanel) {// 스크롤 패널 이라면~\n var newLeft = (function () {\n if ($column.position().left + $column.outerWidth() > Math.abs(this.$.panel[focusedColumn.panelName].position().left) + this.$.panel[containerPanelName].width()) {\n return $column.position().left + $column.outerWidth() - this.$.panel[containerPanelName].width();\n } else if (Math.abs(this.$.panel[focusedColumn.panelName].position().left) > $column.position().left) {\n return $column.position().left;\n } else {\n return;\n }\n }).call(this);\n\n //console.log(newLeft);\n\n if (typeof newLeft !== \"undefined\") {\n GRID.header.scrollTo.call(this, {left: -newLeft});\n scrollTo.call(this, {left: -newLeft});\n GRID.scroller.resize.call(this);\n }\n }\n\n return moveResult;\n },\n \"INDEX\": function (_dindex) {\n var moveResult = true;\n var focusedColumn;\n var originalColumn;\n var while_i;\n\n for (var c in this.focusedColumn) {\n focusedColumn = jQuery.extend({}, this.focusedColumn[c], true);\n break;\n }\n if (!focusedColumn) {\n focusedColumn = {\n rowIndex: 0,\n colIndex: 0\n }\n }\n originalColumn = this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex];\n\n columnSelect.focusClear.call(this);\n columnSelect.clear.call(this);\n\n\n if (_dindex == \"end\") {\n _dindex = this.list.length - 1;\n }\n\n focusedColumn.dindex = _dindex;\n focusedColumn.rowIndex = 0;\n\n while_i = 0;\n while (typeof this.bodyRowMap[focusedColumn.rowIndex + \"_\" + focusedColumn.colIndex] === \"undefined\") {\n if (focusedColumn.rowIndex == 0 || while_i % 2 == ((_dy > 0) ? 0 : 1)) {\n focusedColumn.colIndex--;\n } else {\n focusedColumn.rowIndex--;\n }\n\n if (focusedColumn.rowIndex <= 0 && focusedColumn.colIndex <= 0) {\n // find fail\n break;\n }\n while_i++;\n }\n\n var nPanelInfo = GRID.util.findPanelByColumnIndex.call(this, focusedColumn.dindex, focusedColumn.colIndex);\n focusedColumn.panelName = nPanelInfo.panelName;\n\n // 포커스 컬럼의 위치에 따라 스크롤 처리.\n (function () {\n if (focusedColumn.dindex + 1 > this.xvar.frozenRowIndex) {\n if (focusedColumn.dindex < this.xvar.paintStartRowIndex) {\n scrollTo.call(this, {top: -(focusedColumn.dindex - this.xvar.frozenRowIndex) * this.xvar.bodyTrHeight});\n GRID.scroller.resize.call(this);\n }\n else if (focusedColumn.dindex + 1 > this.xvar.paintStartRowIndex + (this.xvar.paintRowCount - 2)) {\n scrollTo.call(this, {top: -(focusedColumn.dindex - this.xvar.frozenRowIndex - this.xvar.paintRowCount + 3) * this.xvar.bodyTrHeight});\n GRID.scroller.resize.call(this);\n }\n }\n }).call(this);\n\n this.focusedColumn[focusedColumn.dindex + \"_\" + focusedColumn.colIndex + \"_\" + focusedColumn.rowIndex] = focusedColumn;\n this.$.panel[focusedColumn.panelName]\n .find('[data-ax5grid-tr-data-index=\"' + focusedColumn.dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + focusedColumn.rowIndex + '\"][data-ax5grid-column-colindex=\"' + focusedColumn.colIndex + '\"]')\n .attr('data-ax5grid-column-focused', \"true\");\n\n return moveResult;\n }\n };\n\n let processor = {\n \"UP\": function () {\n return focus[\"UD\"].call(this, -1);\n },\n \"DOWN\": function () {\n return focus[\"UD\"].call(this, 1);\n },\n \"LEFT\": function () {\n return focus[\"LR\"].call(this, -1);\n },\n \"RIGHT\": function () {\n return focus[\"LR\"].call(this, 1);\n },\n \"HOME\": function () {\n return focus[\"INDEX\"].call(this, 0);\n },\n \"END\": function () {\n return focus[\"INDEX\"].call(this, \"end\");\n },\n \"position\": function (_position) {\n return focus[\"INDEX\"].call(this, _position);\n }\n };\n\n if (_position in processor) {\n return processor[_position].call(this);\n } else {\n return processor[\"position\"].call(this, _position);\n }\n };\n\n var inlineEdit = {\n active: function (_focusedColumn, _e, _initValue) {\n var self = this,\n dindex, colIndex, rowIndex, panelName, colspan,\n col, editor;\n\n // this.inlineEditing = {};\n for (var key in _focusedColumn) {\n panelName = _focusedColumn[key].panelName;\n dindex = _focusedColumn[key].dindex;\n colIndex = _focusedColumn[key].colIndex;\n rowIndex = _focusedColumn[key].rowIndex;\n colspan = _focusedColumn[key].colspan;\n\n // 인라인 에디팅을 멈춰야 하는 경우 조건\n col = this.colGroup[colIndex];\n if (!(editor = col.editor)) return this;\n\n // editor disabled 체크\n if (U.isFunction(editor.disabled)) {\n if (editor.disabled.call({\n list: this.list,\n dindex: dindex,\n item: this.list[dindex],\n key: col.key,\n value: _initValue\n })) {\n return this;\n }\n }\n\n // 조건에 맞지 않는 에디팅 타입이면 반응 없음.\n if (!(function (_editor, _type) {\n if (_editor.type in GRID.inlineEditor) {\n return (GRID.inlineEditor[_editor.type].editMode == \"popup\");\n }\n })(editor)) {\n // 체크 박스 타입이면 값 변경 시도\n if (editor.type == \"checkbox\") {\n var checked, newValue;\n if (editor.config && editor.config.trueValue) {\n if (checked = !(_initValue == editor.config.trueValue)) {\n newValue = editor.config.trueValue;\n } else {\n newValue = editor.config.falseValue;\n }\n } else {\n newValue = checked = (_initValue == false || _initValue == \"false\" || _initValue < \"1\") ? \"true\" : \"false\";\n }\n\n GRID.data.setValue.call(self, dindex, col.key, newValue);\n updateRowState.call(self, [\"cellChecked\"], dindex, {\n key: col.key, rowIndex: rowIndex, colIndex: colIndex,\n editorConfig: col.editor.config, checked: checked\n });\n }\n return this;\n }\n\n\n if (this.list[dindex].__isGrouping) {\n return false;\n }\n if (key in this.inlineEditing) {\n return false;\n }\n this.inlineEditing[key] = {\n editor: editor,\n panelName: panelName,\n columnKey: key,\n column: _focusedColumn[key],\n useReturnToSave: GRID.inlineEditor[editor.type].useReturnToSave\n };\n this.isInlineEditing = true;\n }\n if (this.isInlineEditing) {\n\n var originalValue = GRID.data.getValue.call(self, dindex, col.key);\n var initValue = (function (__value, __editor) {\n if (U.isNothing(__value)) {\n __value = U.isNothing(originalValue) ? \"\" : originalValue;\n }\n\n if (__editor.type == \"money\") {\n return U.number(__value, {\"money\": true});\n }\n else {\n return __value;\n }\n }).call(this, _initValue, editor);\n\n this.inlineEditing[key].$inlineEditorCell = this.$[\"panel\"][panelName]\n .find('[data-ax5grid-tr-data-index=\"' + dindex + '\"]')\n .find('[data-ax5grid-column-rowindex=\"' + rowIndex + '\"][data-ax5grid-column-colindex=\"' + colIndex + '\"]')\n .find('[data-ax5grid-cellholder]');\n\n this.inlineEditing[key].$inlineEditor = GRID.inlineEditor[editor.type].init(this, key, editor, this.inlineEditing[key].$inlineEditorCell, initValue);\n\n return true;\n }\n },\n deActive: function (_msg, _key, _value) {\n // console.log(this.inlineEditing.column.dindex, this.inlineEditing.$inlineEditor.val());\n if (!this.inlineEditing[_key]) return this;\n\n var panelName = this.inlineEditing[_key].panelName;\n var dindex = this.inlineEditing[_key].column.dindex;\n var rowIndex = this.inlineEditing[_key].column.rowIndex;\n var colIndex = this.inlineEditing[_key].column.colIndex;\n\n var column = this.bodyRowMap[this.inlineEditing[_key].column.rowIndex + \"_\" + this.inlineEditing[_key].column.colIndex];\n var editorValue = (function ($inlineEditor) {\n if (typeof _value === \"undefined\") {\n if ($inlineEditor.get(0).tagName == \"SELECT\" || $inlineEditor.get(0).tagName == \"INPUT\" || $inlineEditor.get(0).tagName == \"TEXTAREA\") {\n return $inlineEditor.val();\n } else {\n _msg = \"CANCEL\";\n return false;\n }\n } else {\n return _value;\n }\n })(this.inlineEditing[_key].$inlineEditor);\n\n var newValue = (function (__value, __editor) {\n if (__editor.type == \"money\") {\n return U.number(__value);\n }\n else {\n return __value;\n }\n }).call(this, editorValue, column.editor);\n\n var action = {\n \"CANCEL\": function (_dindex, _column, _newValue) {\n action[\"__clear\"].call(this);\n },\n \"RETURN\": function (_dindex, _column, _newValue) {\n if (GRID.data.setValue.call(this, _dindex, _column.key, _newValue)) {\n action[\"__clear\"].call(this);\n GRID.body.repaintCell.call(this, panelName, dindex, rowIndex, colIndex, _newValue);\n } else {\n action[\"__clear\"].call(this);\n }\n },\n \"__clear\": function () {\n this.isInlineEditing = false;\n var bindedAx5ui = this.inlineEditing[_key].$inlineEditor.data(\"binded-ax5ui\");\n if (bindedAx5ui == \"ax5picker\") {\n this.inlineEditing[_key].$inlineEditor.ax5picker(\"close\");\n } else if (bindedAx5ui == \"ax5select\") {\n this.inlineEditing[_key].$inlineEditor.ax5select(\"close\");\n }\n\n this.inlineEditing[_key].$inlineEditor.remove();\n this.inlineEditing[_key].$inlineEditor = null;\n this.inlineEditing[_key].$inlineEditorCell = null;\n this.inlineEditing[_key] = undefined;\n delete this.inlineEditing[_key]; // delete 지원안하는 브라우저 테스트..\n }\n };\n\n if (_msg in action) {\n action[_msg || \"RETURN\"].call(this, dindex, column, newValue);\n } else {\n action[\"__clear\"].call(this);\n }\n },\n keydown: function (key, columnKey, _options) {\n var processor = {\n \"ESC\": function () {\n for (var columnKey in this.inlineEditing) {\n inlineEdit.deActive.call(this, \"CANCEL\", columnKey);\n }\n },\n \"RETURN\": function () {\n if (this.isInlineEditing) {\n if (this.inlineEditing[columnKey] && this.inlineEditing[columnKey].useReturnToSave) { // todo : 네이밍 검증 할 필요있음.\n inlineEdit.deActive.call(this, \"RETURN\", columnKey);\n }\n } else {\n\n for (var k in this.focusedColumn) {\n var _column = this.focusedColumn[k];\n var column = this.bodyRowMap[_column.rowIndex + \"_\" + _column.colIndex];\n var dindex = _column.dindex;\n var value = \"\";\n if (column) {\n if (!this.list[dindex].__isGrouping) {\n value = GRID.data.getValue.call(this, dindex, column.key);\n }\n }\n\n var col = this.colGroup[_column.colIndex];\n\n if (GRID.inlineEditor[col.editor.type].editMode === \"inline\") {\n if (_options && _options.moveFocus) {\n\n }\n else {\n if (column.editor && column.editor.type == \"checkbox\") {\n\n value = GRID.data.getValue.call(this, dindex, column.key);\n\n var checked, newValue;\n if (column.editor.config && column.editor.config.trueValue) {\n if (checked = !(value == column.editor.config.trueValue)) {\n newValue = column.editor.config.trueValue;\n } else {\n newValue = column.editor.config.falseValue;\n }\n } else {\n newValue = checked = (value == false || value == \"false\" || value < \"1\") ? \"true\" : \"false\";\n }\n\n GRID.data.setValue.call(this, _column.dindex, column.key, newValue);\n updateRowState.call(this, [\"cellChecked\"], dindex, {\n key: column.key, rowIndex: _column.rowIndex, colIndex: _column.colIndex,\n editorConfig: column.editor.config, checked: checked\n });\n\n }\n }\n } else {\n GRID.body.inlineEdit.active.call(this, this.focusedColumn, null, value);\n }\n }\n }\n }\n };\n\n if (key in processor) {\n processor[key].call(this, key, columnKey, _options);\n }\n }\n };\n\n let getExcelString = function () {\n let cfg = this.config,\n list = this.list,\n bodyRowData = this.bodyRowTable,\n footSumData = this.footSumTable,\n bodyGroupingData = this.bodyGroupingTable;\n\n // body-scroll 의 포지션에 의존적이므로..\n let getBody = function (_colGroup, _bodyRow, _groupRow, _list) {\n let SS = [],\n di, dl,\n tri, trl,\n ci, cl,\n col;\n\n //SS.push('');\n for (di = 0, dl = _list.length; di < dl; di++) {\n let isGroupingRow = false, rowTable;\n\n if (_groupRow && \"__isGrouping\" in _list[di]) {\n rowTable = _groupRow;\n isGroupingRow = true;\n } else {\n rowTable = _bodyRow;\n }\n\n for (tri = 0, trl = rowTable.rows.length; tri < trl; tri++) {\n SS.push('\\n');\n for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) {\n col = rowTable.rows[tri].cols[ci];\n\n SS.push('', (isGroupingRow) ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col, undefined, \"text\"), ' | ');\n }\n SS.push('\\n
');\n }\n }\n //SS.push('
');\n return SS.join('');\n };\n let getSum = function (_colGroup, _bodyRow, _list) {\n let SS = [],\n tri, trl,\n ci, cl,\n col;\n\n //SS.push('');\n for (tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('\\n');\n for (ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n col = _bodyRow.rows[tri].cols[ci];\n SS.push('', getSumFieldValue.call(this, _list, col), ' | ');\n }\n SS.push('\\n
');\n }\n //SS.push('
');\n\n return SS.join('');\n };\n\n let po = [];\n po.push(getBody.call(this, this.headerColGroup, bodyRowData, bodyGroupingData, list));\n if (cfg.footSum) {\n // 바닥 요약\n po.push(getSum.call(this, this.headerColGroup, footSumData, list));\n }\n\n // right\n if (cfg.rightSum) {\n // todo : right 표현 정리\n }\n\n return po.join('');\n };\n\n GRID.body = {\n init: init,\n repaint: repaint,\n repaintCell: repaintCell,\n repaintRow: repaintRow,\n updateRowState: updateRowState,\n updateRowStateAll: updateRowStateAll,\n scrollTo: scrollTo,\n blur: blur,\n moveFocus: moveFocus,\n inlineEdit: inlineEdit,\n getExcelString: getExcelString\n };\n})();\n","// ax5.ui.grid.collector\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n var sum = function () {\n var value = 0;\n var i = this.list.length;\n while (i--) {\n if(!(\"__groupingList\" in this.list[i])) {\n value += U.number(this.list[i][this.key]);\n }\n }\n return value;\n };\n var avg = function () {\n var value = 0;\n var i = this.list.length, listLength = 0;\n while (i--) {\n if(!(\"__groupingList\" in this.list[i])) {\n value += U.number(this.list[i][this.key]);\n listLength++;\n }\n }\n return U.number(value / (listLength || 1), {\"round\": 2});\n };\n\n GRID.collector = {\n sum: sum,\n avg: avg\n };\n\n})();","// ax5.ui.grid.layout\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var init = function () {\n\n };\n\n var clearGroupingData = function (_list) {\n var i = 0, l = _list.length;\n var returnList = [];\n for (; i < l; i++) {\n if (_list[i] && !_list[i][\"__isGrouping\"]) {\n if (_list[i][this.config.columnKeys.selected]) {\n this.selectedDataIndexs.push(i);\n }\n returnList.push(jQuery.extend({}, _list[i]));\n }\n }\n return returnList;\n };\n\n let initData = function (_list) {\n this.selectedDataIndexs = [];\n let i = 0, l = _list.length,\n returnList = [],\n appendIndex = 0,\n dataRealRowCount = 0;\n\n if (this.config.body.grouping) {\n let groupingKeys = U.map(this.bodyGrouping.by, function () {\n return {\n key: this,\n compareString: \"\",\n grouping: false,\n list: []\n }\n });\n let gi = 0, gl = groupingKeys.length, compareString, appendRow = [], ari;\n for (; i < l + 1; i++) {\n gi = 0;\n if (_list[i] && _list[i][this.config.columnKeys.deleted]) {\n this.deletedList.push(_list[i]);\n } else {\n compareString = \"\";\n appendRow = [];\n for (; gi < gl; gi++) {\n if (_list[i]) {\n compareString += \"$|$\" + _list[i][groupingKeys[gi].key];\n }\n if (appendIndex > 0 && compareString != groupingKeys[gi].compareString) {\n var appendRowItem = {keys: [], labels: [], list: groupingKeys[gi].list};\n for (var ki = 0; ki < gi + 1; ki++) {\n appendRowItem.keys.push(groupingKeys[ki].key);\n appendRowItem.labels.push(_list[i - 1][groupingKeys[ki].key]);\n }\n appendRow.push(appendRowItem);\n groupingKeys[gi].list = [];\n }\n groupingKeys[gi].list.push(_list[i]);\n groupingKeys[gi].compareString = compareString;\n }\n\n ari = appendRow.length;\n while (ari--) {\n returnList.push({__isGrouping: true, __groupingList: appendRow[ari].list, __groupingBy: {keys: appendRow[ari].keys, labels: appendRow[ari].labels}});\n }\n\n if (_list[i]) {\n if (_list[i][this.config.columnKeys.selected]) {\n this.selectedDataIndexs.push(i);\n }\n dataRealRowCount = _list[i][\"__index\"] = i;\n returnList.push(_list[i]);\n appendIndex++;\n }\n }\n }\n }\n else {\n for (; i < l; i++) {\n if (_list[i] && _list[i][this.config.columnKeys.deleted]) {\n this.deletedList.push(_list[i]);\n } else if (_list[i]) {\n if (_list[i][this.config.columnKeys.selected]) {\n this.selectedDataIndexs.push(i);\n }\n // __index변수를 추가하여 lineNumber 에 출력합니다. (body getFieldValue 에서 출력함)\n _list[i][\"__index\"] = i;\n dataRealRowCount++;\n returnList.push(_list[i]);\n }\n }\n }\n\n // 원본 데이터의 갯수\n // grouping은 제외하고 수집됨.\n this.xvar.dataRealRowCount = dataRealRowCount;\n return returnList;\n };\n\n let set = function (data) {\n let self = this;\n\n if (U.isArray(data)) {\n this.page = null;\n this.list = initData.call(this,\n (!this.config.remoteSort && Object.keys(this.sortInfo).length) ? sort.call(this, this.sortInfo, data) : data\n );\n this.deletedList = [];\n } else if (\"page\" in data) {\n this.page = jQuery.extend({}, data.page);\n this.list = initData.call(this,\n (!this.config.remoteSort && Object.keys(this.sortInfo).length) ? sort.call(this, this.sortInfo, data.list) : data.list\n );\n this.deletedList = [];\n }\n\n this.needToPaintSum = true;\n this.xvar.frozenRowIndex = (this.config.frozenRowIndex > this.list.length) ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n\n if (this.config.body.grouping) {\n\n }\n return this;\n };\n\n let get = function (_type) {\n return {\n list: this.list,\n page: this.page\n };\n };\n\n let getList = function (_type) {\n let returnList = [];\n let i = 0, l = this.list.length;\n switch (_type) {\n case \"modified\":\n for (; i < l; i++) {\n if (this.list[i] && !this.list[i][\"__isGrouping\"] && this.list[i][this.config.columnKeys.modified]) {\n returnList.push(jQuery.extend({}, this.list[i]));\n }\n }\n break;\n case \"selected\":\n for (; i < l; i++) {\n if (this.list[i] && !this.list[i][\"__isGrouping\"] && this.list[i][this.config.columnKeys.selected]) {\n returnList.push(jQuery.extend({}, this.list[i]));\n }\n }\n break;\n case \"deleted\":\n //_list = GRID.data.clearGroupingData(this.list);\n returnList = [].concat(this.deletedList);\n break;\n default:\n returnList = GRID.data.clearGroupingData.call(this, this.list);\n }\n return returnList;\n };\n\n let add = function (_row, _dindex, _options) {\n let list = (this.config.body.grouping) ? clearGroupingData.call(this, this.list) : this.list;\n let processor = {\n \"first\": function () {\n list = [].concat(_row).concat(list);\n },\n \"last\": function () {\n list = list.concat([].concat(_row));\n }\n };\n\n if (typeof _dindex === \"undefined\") _dindex = \"last\";\n if (_dindex in processor) {\n _row[this.config.columnKeys.modified] = true;\n processor[_dindex].call(this, _row);\n } else {\n if (!U.isNumber(_dindex)) {\n throw 'invalid argument _dindex';\n }\n //\n list = list.splice(_dindex, [].concat(_row));\n }\n\n if (this.config.body.grouping) {\n list = initData.call(this,\n sort.call(this,\n this.sortInfo,\n list\n )\n );\n } else if (_options && _options.sort && Object.keys(this.sortInfo).length) {\n list = sort.call(this,\n this.sortInfo,\n list\n );\n }\n\n this.list = list;\n\n this.needToPaintSum = true;\n this.xvar.frozenRowIndex = (this.config.frozenRowIndex > this.list.length) ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n return this;\n };\n\n /**\n * list에서 완전 제거 하는 경우 사용.\n * ax5grid.data.remove\n */\n let remove = function (_dindex) {\n let list = (this.config.body.grouping) ? clearGroupingData.call(this, this.list) : this.list;\n let processor = {\n \"first\": function () {\n list.splice(_dindex, 1);\n },\n \"last\": function () {\n var lastIndex = list.length - 1;\n list.splice(lastIndex, 1);\n }\n };\n\n if (typeof _dindex === \"undefined\") _dindex = \"last\";\n if (_dindex in processor) {\n processor[_dindex].call(this, _dindex);\n } else {\n if (!U.isNumber(_dindex)) {\n throw 'invalid argument _dindex';\n }\n //\n list.splice(_dindex, 1);\n }\n\n if (this.config.body.grouping) {\n list = initData.call(this,\n sort.call(this,\n this.sortInfo,\n list\n )\n );\n } else if (Object.keys(this.sortInfo).length) {\n list = initData.call(this,\n sort.call(this,\n this.sortInfo,\n list\n )\n );\n } else {\n list = initData.call(this, list);\n }\n\n this.list = list;\n\n this.needToPaintSum = true;\n this.xvar.frozenRowIndex = (this.config.frozenRowIndex > this.list.length) ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n return this;\n };\n\n\n /**\n * list에서 deleted 처리 repaint\n * ax5grid.data.deleteRow\n */\n let deleteRow = function (_dindex) {\n let list = (this.config.body.grouping) ? clearGroupingData.call(this, this.list) : this.list;\n let processor = {\n \"first\": function () {\n list[0][this.config.columnKeys.deleted] = true;\n },\n \"last\": function () {\n list[list.length - 1][this.config.columnKeys.deleted] = true;\n },\n \"selected\": function () {\n var i = list.length;\n while (i--) {\n if (list[i][this.config.columnKeys.selected]) {\n list[i][this.config.columnKeys.deleted] = true;\n }\n }\n }\n };\n\n if (typeof _dindex === \"undefined\") _dindex = \"last\";\n if (_dindex in processor) {\n processor[_dindex].call(this, _dindex);\n } else {\n if (!U.isNumber(_dindex)) {\n throw 'invalid argument _dindex';\n }\n list[_dindex][this.config.columnKeys.deleted] = true;\n }\n\n if (this.config.body.grouping) {\n list = initData.call(this,\n sort.call(this,\n this.sortInfo,\n list\n )\n );\n } else if (Object.keys(this.sortInfo).length) {\n list = initData.call(this,\n sort.call(this,\n this.sortInfo,\n list\n )\n );\n } else {\n list = initData.call(this, list);\n }\n\n this.list = list;\n\n this.needToPaintSum = true;\n this.xvar.frozenRowIndex = (this.config.frozenRowIndex > this.list.length) ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n return this;\n };\n\n let update = function (_row, _dindex) {\n if (!U.isNumber(_dindex)) {\n throw 'invalid argument _dindex';\n }\n //\n this.needToPaintSum = true;\n this.list.splice(_dindex, 1, _row);\n\n if (this.config.body.grouping) {\n this.list = initData.call(this, clearGroupingData.call(this, this.list));\n }\n };\n\n let setValue = function (_dindex, _key, _value) {\n let originalValue = getValue.call(this, _dindex, _key);\n this.needToPaintSum = true;\n\n if (originalValue !== _value) {\n if (/[\\.\\[\\]]/.test(_key)) {\n try {\n this.list[_dindex][this.config.columnKeys.modified] = true;\n (Function(\"val\", \"this\" + GRID.util.getRealPathForDataItem(_key) + \" = val;\")).call(this.list[_dindex], _value);\n } catch (e) {\n\n }\n } else {\n this.list[_dindex][this.config.columnKeys.modified] = true;\n this.list[_dindex][_key] = _value;\n }\n\n if (this.onDataChanged) {\n this.onDataChanged.call({\n self: this,\n list: this.list,\n dindex: _dindex,\n item: this.list[_dindex],\n key: _key,\n value: _value\n });\n }\n }\n\n return true;\n };\n\n let getValue = function (_dindex, _key, _value) {\n if (/[\\.\\[\\]]/.test(_key)) {\n try {\n _value = (Function(\"\", \"return this\" + GRID.util.getRealPathForDataItem(_key) + \";\")).call(this.list[_dindex]);\n } catch (e) {\n\n }\n } else {\n _value = this.list[_dindex][_key];\n }\n return _value;\n };\n\n let clearSelect = function () {\n this.selectedDataIndexs = [];\n };\n\n let select = function (_dindex, _selected, _options) {\n let cfg = this.config;\n\n if (this.list[_dindex].__isGrouping) return false;\n if (this.list[_dindex][cfg.columnKeys.disableSelection]) return false;\n\n if (typeof _selected === \"undefined\") {\n if (this.list[_dindex][cfg.columnKeys.selected] = !this.list[_dindex][cfg.columnKeys.selected]) {\n this.selectedDataIndexs.push(_dindex);\n }\n } else {\n if (this.list[_dindex][cfg.columnKeys.selected] = _selected) {\n this.selectedDataIndexs.push(_dindex);\n }\n }\n\n if (this.onDataChanged && _options && _options.internalCall) {\n this.onDataChanged.call({\n self: this,\n list: this.list,\n dindex: _dindex,\n item: this.list[_dindex],\n key: cfg.columnKeys.selected,\n value: this.list[_dindex][cfg.columnKeys.selected]\n });\n }\n\n return this.list[_dindex][cfg.columnKeys.selected];\n };\n\n let selectAll = function (_selected, _options) {\n let cfg = this.config,\n dindex = this.list.length;\n\n if (typeof _selected === \"undefined\") {\n while (dindex--) {\n if (this.list[dindex].__isGrouping) continue;\n if (_options && _options.filter) {\n if (_options.filter.call(this.list[dindex]) !== true) {\n continue;\n }\n }\n if (this.list[dindex][cfg.columnKeys.disableSelection]) continue;\n\n if (this.list[dindex][cfg.columnKeys.selected] = !this.list[dindex][cfg.columnKeys.selected]) {\n this.selectedDataIndexs.push(dindex);\n }\n }\n } else {\n while (dindex--) {\n if (this.list[dindex].__isGrouping) continue;\n if (_options && _options.filter) {\n if (_options.filter.call(this.list[dindex]) !== true) {\n continue;\n }\n }\n if (this.list[dindex][cfg.columnKeys.disableSelection]) continue;\n\n if (this.list[dindex][cfg.columnKeys.selected] = _selected) {\n this.selectedDataIndexs.push(dindex);\n }\n }\n }\n\n if (this.onDataChanged && _options && _options.internalCall) {\n this.onDataChanged.call({\n self: this,\n list: this.list\n });\n }\n\n return this.list;\n };\n\n let sort = function (_sortInfo, _list) {\n let self = this, list = _list || this.list, sortInfoArray = [];\n let getKeyValue = function (_item, _key, _value) {\n if (/[\\.\\[\\]]/.test(_key)) {\n try {\n _value = (Function(\"\", \"return this\" + GRID.util.getRealPathForDataItem(_key) + \";\")).call(_item);\n } catch (e) { }\n } else {\n _value = _item[_key];\n }\n return _value;\n };\n\n for (let k in _sortInfo) {\n sortInfoArray[_sortInfo[k].seq] = {key: k, order: _sortInfo[k].orderBy};\n }\n sortInfoArray = U.filter(sortInfoArray, function () {\n return typeof this !== \"undefined\";\n });\n\n let i = 0, l = sortInfoArray.length, _a_val, _b_val;\n\n list.sort(function (_a, _b) {\n for (i = 0; i < l; i++) {\n _a_val = getKeyValue(_a, sortInfoArray[i].key);\n _b_val = getKeyValue(_b, sortInfoArray[i].key);\n\n if (typeof _a_val !== typeof _b_val) {\n _a_val = '' + _a_val;\n _b_val = '' + _b_val;\n }\n if (_a_val < _b_val) {\n return (sortInfoArray[i].order === \"asc\") ? -1 : 1;\n } else if (_a_val > _b_val) {\n return (sortInfoArray[i].order === \"asc\") ? 1 : -1;\n }\n }\n });\n\n if (_list) {\n return list;\n } else {\n this.xvar.frozenRowIndex = (this.config.frozenRowIndex > this.list.length) ? this.list.length : this.config.frozenRowIndex;\n this.xvar.paintStartRowIndex = undefined; // 스크롤 포지션 저장변수 초기화\n GRID.page.navigationUpdate.call(this);\n return this;\n }\n };\n\n GRID.data = {\n init: init,\n set: set,\n get: get,\n getList: getList,\n setValue: setValue,\n getValue: getValue,\n clearSelect: clearSelect,\n select: select,\n selectAll: selectAll,\n add: add,\n remove: remove,\n deleteRow: deleteRow,\n update: update,\n sort: sort,\n initData: initData,\n clearGroupingData: clearGroupingData\n };\n\n})();","/*\n * Copyright (c) 2016. tom@axisj.com\n * - github.com/thomasjang\n * - www.axisj.com\n */\n\n// ax5.ui.grid.excel\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var base64 = function (s) {\n return window.btoa(unescape(encodeURIComponent(s)));\n };\n var uri = \"data:application/vnd.ms-excel;base64,\";\n\n var getExcelTmpl = function () {\n return `\\ufeff\n{{#tables}}{{{body}}}{{/tables}}\n`;\n };\n\n var tableToExcel = function (table, fileName) {\n var link, a, output;\n var tables = [].concat(table);\n\n output = ax5.mustache.render(getExcelTmpl(), {\n worksheet: (function () {\n var arr = [];\n tables.forEach(function (t, ti) {\n arr.push({name: \"Sheet\" + (ti + 1)});\n });\n return arr;\n })(),\n tables: (function () {\n var arr = [];\n tables.forEach(function (t, ti) {\n arr.push({body: t});\n });\n return arr;\n })()\n });\n\n var isChrome = navigator.userAgent.indexOf(\"Chrome\") > -1;\n var isSafari = !isChrome && navigator.userAgent.indexOf(\"Safari\") > -1;\n\n var isIE = /*@cc_on!@*/false || !!document.documentMode; // this works with IE10 and IE11 both :)\n if (navigator.msSaveOrOpenBlob) {\n var blob1 = new Blob([output], {type: \"text/html\"});\n window.navigator.msSaveOrOpenBlob(blob1, fileName);\n }\n else if (isSafari) {\n // 사파리는 지원이 안되므로 그냥 테이블을 클립보드에 복사처리\n //tables\n var blankWindow = window.open('about:blank', this.id + '-excel-export', 'width=600,height=400');\n blankWindow.document.write(output);\n blankWindow = null;\n }\n else {\n if (isIE && typeof Blob === \"undefined\") {\n\n //otherwise use the iframe and save\n //requires a blank iframe on page called txtArea1\n var $iframe = jQuery('');\n jQuery(document.body).append($iframe);\n var iframe = window[this.id + '-excel-export'];\n iframe.document.open(\"text/html\", \"replace\");\n iframe.document.write(output);\n iframe.document.close();\n iframe.focus();\n iframe.document.execCommand(\"SaveAs\", true, fileName);\n $iframe.remove();\n } else {\n // Attempt to use an alternative method\n var anchor = document.body.appendChild(\n document.createElement(\"a\")\n );\n\n // If the [download] attribute is supported, try to use it\n if (\"download\" in anchor) {\n anchor.download = fileName;\n //anchor.href = URL.createObjectURL( blob );\n anchor.href = uri + base64(output);\n anchor.click();\n document.body.removeChild(anchor);\n }\n }\n }\n\n return true;\n };\n\n GRID.excel = {\n export: tableToExcel\n };\n})();","// ax5.ui.grid.formatter\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n var money = function () {\n return U.number(this.value, {\"money\":true});\n };\n\n GRID.formatter = {\n money: money\n };\n\n})();","// ax5.ui.grid.header\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var columnResizerEvent = {\n \"on\": function (_columnResizer, _colIndex) {\n var self = this;\n var $columnResizer = $(_columnResizer);\n var columnResizerPositionLeft = $columnResizer.offset().left;\n var gridTargetOffsetLeft = self.$[\"container\"][\"root\"].offset().left;\n self.xvar.columnResizerIndex = _colIndex;\n var resizeRange = {\n min: -self.colGroup[_colIndex]._width + 2,\n max: (self.colGroup[_colIndex + 1]) ? self.colGroup[_colIndex + 1]._width : self.$[\"container\"][\"root\"].width() - 2,\n };\n //console.log(resizeRange);\n\n jQuery(document.body)\n .bind(GRID.util.ENM[\"mousemove\"] + \".ax5grid-\" + this.instanceId, function (e) {\n var mouseObj = GRID.util.getMousePosition(e);\n self.xvar.__da = mouseObj.clientX - self.xvar.mousePosition.clientX;\n\n if (resizeRange.min > self.xvar.__da) {\n self.xvar.__da = resizeRange.min;\n } else if (resizeRange.max < self.xvar.__da) {\n self.xvar.__da = resizeRange.max;\n }\n\n if (!self.xvar.columnResizerLived) {\n self.$[\"resizer\"][\"horizontal\"].addClass(\"live\");\n }\n self.xvar.columnResizerLived = true;\n self.$[\"resizer\"][\"horizontal\"].css({\n left: columnResizerPositionLeft + self.xvar.__da - gridTargetOffsetLeft\n });\n })\n .bind(GRID.util.ENM[\"mouseup\"] + \".ax5grid-\" + this.instanceId, function (e) {\n columnResizerEvent.off.call(self);\n U.stopEvent(e);\n })\n .bind(\"mouseleave.ax5grid-\" + this.instanceId, function (e) {\n columnResizerEvent.off.call(self);\n U.stopEvent(e);\n });\n\n jQuery(document.body)\n .attr('unselectable', 'on')\n .css('user-select', 'none')\n .on('selectstart', false);\n },\n \"off\": function () {\n this.$[\"resizer\"][\"horizontal\"].removeClass(\"live\");\n this.xvar.columnResizerLived = false;\n\n if (typeof this.xvar.__da === \"undefined\") {\n\n }\n else {\n this.setColumnWidth(this.colGroup[this.xvar.columnResizerIndex]._width + this.xvar.__da, this.xvar.columnResizerIndex);\n }\n\n jQuery(document.body)\n .unbind(GRID.util.ENM[\"mousemove\"] + \".ax5grid-\" + this.instanceId)\n .unbind(GRID.util.ENM[\"mouseup\"] + \".ax5grid-\" + this.instanceId)\n .unbind(\"mouseleave.ax5grid-\" + this.instanceId);\n\n jQuery(document.body)\n .removeAttr('unselectable')\n .css('user-select', 'auto')\n .off('selectstart');\n }\n };\n\n var init = function () {\n // 헤더 초기화\n var self = this;\n\n this.$[\"container\"][\"header\"].on(\"click\", '[data-ax5grid-column-attr]', function (e) {\n let key = this.getAttribute(\"data-ax5grid-column-key\"),\n colIndex = this.getAttribute(\"data-ax5grid-column-colindex\"),\n rowIndex = this.getAttribute(\"data-ax5grid-column-rowindex\"),\n col = self.colGroup[colIndex];\n\n if (key === \"__checkbox_header__\") {\n var selected = this.getAttribute(\"data-ax5grid-selected\");\n selected = (U.isNothing(selected)) ? true : (selected === \"true\") ? false : true;\n\n $(this).attr(\"data-ax5grid-selected\", selected);\n self.selectAll({selected: selected});\n }\n else {\n if (key && col) {\n if ((col.sortable === true || self.config.sortable === true) && col.sortable !== false) {\n if (!col.sortFixed) toggleSort.call(self, col.key);\n }\n }\n }\n\n GRID.body.blur.call(self);\n });\n this.$[\"container\"][\"header\"]\n .on(\"mousedown\", '[data-ax5grid-column-resizer]', function (e) {\n var colIndex = this.getAttribute(\"data-ax5grid-column-resizer\");\n self.xvar.mousePosition = GRID.util.getMousePosition(e);\n columnResizerEvent.on.call(self, this, Number(colIndex));\n U.stopEvent(e);\n })\n .on(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n resetFrozenColumn.call(this);\n };\n\n var resetFrozenColumn = function () {\n let cfg = this.config,\n dividedHeaderObj = GRID.util.divideTableByFrozenColumnIndex(this.headerTable, this.config.frozenColumnIndex);\n this.asideHeaderData = (function (dataTable) {\n var colGroup = [];\n var data = {rows: []};\n for (var i = 0, l = dataTable.rows.length; i < l; i++) {\n data.rows[i] = {cols: []};\n if (i === 0) {\n var col = {\n label: \"\",\n colspan: 1,\n rowspan: dataTable.rows.length,\n colIndex: null\n }, _col = {};\n\n if (cfg.showLineNumber) {\n _col = jQuery.extend({}, col, {\n width: cfg.lineNumberColumnWidth,\n _width: cfg.lineNumberColumnWidth,\n columnAttr: \"lineNumber\",\n key: \"__index_header__\", label: \" \"\n });\n colGroup.push(_col);\n data.rows[i].cols.push(_col);\n }\n if (cfg.showRowSelector) {\n _col = jQuery.extend({}, col, {\n width: cfg.rowSelectorColumnWidth,\n _width: cfg.rowSelectorColumnWidth,\n columnAttr: \"rowSelector\",\n key: \"__checkbox_header__\", label: \"\"\n });\n colGroup.push(_col);\n data.rows[i].cols.push(_col);\n }\n }\n }\n\n this.asideColGroup = colGroup;\n return data;\n }).call(this, this.headerTable);\n this.leftHeaderData = dividedHeaderObj.leftData;\n this.headerData = dividedHeaderObj.rightData;\n };\n\n var getFieldValue = function (_col) {\n let cfg = this.config,\n colGroup = this.colGroup,\n _key = _col.key,\n tagsToReplace = {\n '<': '<',\n '>': '>'\n };\n\n if (_key === \"__checkbox_header__\") {\n return '';\n\n } else {\n return (_col.label || \" \");\n }\n };\n\n var repaint = function (_reset) {\n let cfg = this.config,\n colGroup = this.colGroup;\n\n if (_reset) {\n resetFrozenColumn.call(this);\n this.xvar.paintStartRowIndex = undefined;\n }\n let asideHeaderData = this.asideHeaderData,\n leftHeaderData = this.leftHeaderData,\n headerData = this.headerData,\n headerAlign = cfg.header.align;\n\n // this.asideColGroup : asideHeaderData에서 처리 함.\n this.leftHeaderColGroup = colGroup.slice(0, this.config.frozenColumnIndex);\n this.headerColGroup = colGroup.slice(this.config.frozenColumnIndex);\n\n var repaintHeader = function (_elTarget, _colGroup, _bodyRow) {\n let tableWidth = 0,\n SS = [];\n SS.push('');\n SS.push('');\n for (var cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n SS.push('');\n tableWidth += _colGroup[cgi]._width;\n }\n SS.push('');\n SS.push('');\n\n for (var tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n var trCSS_class = \"\";\n SS.push('');\n for (var ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n var col = _bodyRow.rows[tri].cols[ci];\n var cellHeight = cfg.header.columnHeight * col.rowspan - cfg.header.columnBorderWidth;\n var colAlign = headerAlign || col.align;\n SS.push('');\n\n SS.push((function () {\n var lineHeight = (cfg.header.columnHeight - cfg.header.columnPadding * 2 - cfg.header.columnBorderWidth);\n return '';\n })(), (function () {\n var _SS = \"\";\n\n if (!U.isNothing(col.key) && !U.isNothing(col.colIndex) && (cfg.sortable === true || col.sortable === true) && col.sortable !== false) {\n _SS += '';\n }\n return _SS;\n })(), getFieldValue.call(this, col), '');\n\n if (!U.isNothing(col.colIndex)) {\n if (cfg.enableFilter) {\n SS.push('');\n }\n }\n\n SS.push(' | ');\n }\n SS.push(' | ');\n SS.push('
');\n }\n SS.push('
');\n _elTarget.html(SS.join(''));\n\n /// append column-resizer\n (function () {\n let resizerHeight = cfg.header.columnHeight * _bodyRow.rows.length - cfg.header.columnBorderWidth,\n resizerLeft = 0,\n AS = [];\n\n for (var cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) {\n var col = _colGroup[cgi];\n if (!U.isNothing(col.colIndex)) {\n //_colGroup[cgi]._width\n resizerLeft += col._width;\n AS.push('');\n }\n }\n _elTarget.append(AS);\n }).call(this);\n\n\n return tableWidth;\n };\n\n if (cfg.asidePanelWidth > 0) {\n repaintHeader.call(this, this.$.panel[\"aside-header\"], this.asideColGroup, asideHeaderData);\n }\n if (cfg.frozenColumnIndex > 0) {\n repaintHeader.call(this, this.$.panel[\"left-header\"], this.leftHeaderColGroup, leftHeaderData);\n }\n this.xvar.scrollContentWidth = repaintHeader.call(this, this.$.panel[\"header-scroll\"], this.headerColGroup, headerData);\n\n if (cfg.rightSum) {\n\n }\n };\n\n var scrollTo = function (css) {\n this.$.panel[\"header-scroll\"].css(css);\n return this;\n };\n\n var toggleSort = function (_key) {\n let sortOrder = \"\",\n sortInfo = {},\n seq = 0;\n\n for (var k in this.sortInfo) {\n if (this.sortInfo[k].fixed) {\n sortInfo[k] = this.sortInfo[k];\n seq++;\n }\n }\n\n for (var i = 0, l = this.colGroup.length; i < l; i++) {\n if (this.colGroup[i].key == _key) {\n if (sortOrder == \"\") {\n if (typeof this.colGroup[i].sort === \"undefined\") {\n sortOrder = \"desc\";\n }\n else if (this.colGroup[i].sort === \"desc\") {\n sortOrder = \"asc\";\n }\n else {\n sortOrder = undefined;\n }\n }\n this.colGroup[i].sort = sortOrder;\n } else if (!this.config.multiSort) {\n this.colGroup[i].sort = undefined;\n }\n\n if (typeof this.colGroup[i].sort !== \"undefined\") {\n if (!sortInfo[this.colGroup[i].key]) {\n sortInfo[this.colGroup[i].key] = {\n seq: seq++,\n orderBy: this.colGroup[i].sort\n };\n }\n }\n }\n\n this.setColumnSort(sortInfo);\n return this;\n };\n\n var applySortStatus = function (_sortInfo) {\n for (var i = 0, l = this.colGroup.length; i < l; i++) {\n for (var _key in _sortInfo) {\n if (this.colGroup[i].key == _key) {\n this.colGroup[i].sort = _sortInfo[_key].orderBy;\n }\n }\n }\n return this;\n };\n\n var select = function (_options) {\n GRID.data.select.call(this, dindex, _options && _options.selected);\n GRID.body.updateRowState.call(this, [\"selected\"], dindex);\n };\n\n var getExcelString = function () {\n let cfg = this.config,\n colGroup = this.colGroup,\n headerData = this.headerTable,\n getHeader = function (_colGroup, _bodyRow) {\n var SS = [];\n //SS.push('');\n for (var tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) {\n SS.push('');\n for (var ci = 0, cl = _bodyRow.rows[tri].cols.length; ci < cl; ci++) {\n var col = _bodyRow.rows[tri].cols[ci];\n SS.push('', getFieldValue.call(this, col), ' | ');\n }\n SS.push('
');\n }\n //SS.push('
');\n\n return SS.join('');\n };\n\n return getHeader.call(this, colGroup, headerData);\n };\n\n GRID.header = {\n init: init,\n repaint: repaint,\n scrollTo: scrollTo,\n toggleSort: toggleSort,\n applySortStatus: applySortStatus,\n getExcelString: getExcelString\n };\n\n})();","// ax5.ui.grid.inlineEditor\n(function () {\n\n var GRID = ax5.ui.grid;\n\n var edit_text = {\n useReturnToSave: true,\n editMode: \"popup\",\n getHtml: function (_root, _columnKey, _editor, _value) {\n return '';\n },\n init: function (_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n $el.on(\"blur\", function () {\n GRID.body.inlineEdit.deActive.call(_root, \"RETURN\", _columnKey);\n });\n return $el;\n },\n bindUI: function (_root, _columnKey, _$el, _editor, _$parent, _value) {\n _$el.focus().select();\n }\n };\n\n var edit_money = {\n useReturnToSave: true,\n editMode: \"popup\",\n getHtml: function (_root, _columnKey, _editor, _value) {\n return '';\n },\n init: function (_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n $el.on(\"blur\", function () {\n GRID.body.inlineEdit.deActive.call(_root, \"RETURN\", _columnKey);\n });\n return $el;\n },\n bindUI: function (_root, _columnKey, _$el, _editor, _$parent, _value) {\n _$el.data(\"binded-ax5ui\", \"ax5formater\");\n _$el.ax5formatter({\n pattern: \"money\"\n });\n _$el.focus().select();\n }\n };\n\n var edit_number = {\n useReturnToSave: true,\n editMode: \"popup\",\n getHtml: function (_root, _columnKey, _editor, _value) {\n return '';\n },\n init: function (_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n $el.on(\"blur\", function () {\n GRID.body.inlineEdit.deActive.call(_root, \"RETURN\", _columnKey);\n });\n return $el;\n },\n bindUI: function (_root, _columnKey, _$el, _editor, _$parent, _value) {\n _$el.data(\"binded-ax5ui\", \"ax5formater\");\n _$el.ax5formatter({\n pattern: \"number\"\n });\n _$el.focus().select();\n }\n };\n\n var edit_date = {\n useReturnToSave: true,\n editMode: \"popup\",\n getHtml: function (_root, _columnKey, _editor, _value) {\n return '';\n },\n init: function (_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n return $el;\n },\n bindUI: function (_root, _columnKey, _$el, _editor, _$parent, _value) {\n var self = _root;\n _$el.data(\"binded-ax5ui\", \"ax5picker\");\n _$el.ax5picker({\n direction: \"auto\",\n content: {\n type: 'date',\n formatter: {\n pattern: 'date'\n }\n },\n onStateChanged: function () {\n if (this.state == \"open\") {\n this.self.activePicker.attr(\"data-ax5grid-inline-edit-picker\", \"date\");\n } else if (this.state == \"close\") {\n GRID.body.inlineEdit.deActive.call(self, \"RETURN\", _columnKey);\n }\n }\n });\n _$el.focus().select();\n }\n };\n\n var edit_select = {\n useReturnToSave: false,\n editMode: \"popup\",\n getHtml: function (_root, _columnKey, _editor, _value) {\n var po = [];\n po.push('');\n po.push('
');\n\n return po.join('');\n },\n init: function (_root, _columnKey, _editor, _$parent, _value) {\n var $el;\n _$parent.append($el = jQuery(this.getHtml(_root, _columnKey, _editor, _value)));\n this.bindUI(_root, _columnKey, $el, _editor, _$parent, _value);\n return $el;\n },\n bindUI: function (_root, _columnKey, _$el, _editor, _$parent, _value) {\n var eConfig = {\n columnKeys: {\n optionValue: \"value\",\n optionText: \"text\",\n optionSelected: \"selected\"\n }\n };\n jQuery.extend(true, eConfig, _editor.config);\n\n eConfig.options.forEach(function (n) {\n if (n[eConfig.columnKeys.optionValue] == _value) n[eConfig.columnKeys.optionSelected] = true;\n });\n\n var self = _root;\n _$el.data(\"binded-ax5ui\", \"ax5select\");\n _$el.ax5select({\n direction: \"auto\",\n columnKeys: eConfig.columnKeys,\n options: eConfig.options,\n onStateChanged: function () {\n if (this.state == \"open\") {\n this.self.activeSelectOptionGroup.attr(\"data-ax5grid-inline-edit-picker\", \"select\");\n } else if (this.state == \"changeValue\") {\n GRID.body.inlineEdit.deActive.call(self, \"RETURN\", _columnKey, this.value[0][eConfig.columnKeys.optionValue]);\n } else if (this.state == \"close\") {\n GRID.body.inlineEdit.deActive.call(self, \"ESC\", _columnKey);\n }\n }\n });\n _$el.ax5select(\"open\");\n _$el.ax5select(\"setValue\", _value);\n _$el.find(\"a\").focus();\n }\n };\n\n var edit_checkbox = {\n editMode: \"inline\",\n getHtml: function (_root, _editor, _value) {\n\n var lineHeight = (_root.config.body.columnHeight - _root.config.body.columnPadding * 2 - _root.config.body.columnBorderWidth);\n var checked;\n if (_editor.config && _editor.config.trueValue) {\n checked = (_value == _editor.config.trueValue) ? \"true\" : \"false\";\n } else {\n checked = (_value == false || _value == \"false\" || _value < \"1\") ? \"false\" : \"true\";\n }\n\n var eConfig = {\n marginTop: 2,\n height: lineHeight - 4\n };\n jQuery.extend(true, eConfig, _editor.config);\n eConfig.marginTop = (lineHeight - eConfig.height) / 2;\n\n return '';\n }\n };\n\n GRID.inlineEditor = {\n \"text\": edit_text,\n \"money\": edit_money,\n \"number\": edit_number,\n \"date\": edit_date,\n \"select\": edit_select,\n \"checkbox\": edit_checkbox\n };\n\n})();","// ax5.ui.grid.page\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var onclickPageMove = function (_act) {\n var callback = function (_pageNo) {\n if (this.page.currentPage != _pageNo) {\n this.page.selectPage = _pageNo;\n if (this.config.page.onChange) {\n this.config.page.onChange.call({\n self: this,\n page: this.page,\n data: this.data\n });\n }\n }\n };\n var processor = {\n \"first\": function () {\n callback.call(this, 0);\n },\n \"prev\": function () {\n var pageNo = this.page.currentPage - 1;\n if (pageNo < 0) pageNo = 0;\n callback.call(this, pageNo);\n },\n \"next\": function () {\n var pageNo = this.page.currentPage + 1;\n if (pageNo > this.page.totalPages - 1) pageNo = this.page.totalPages - 1;\n callback.call(this, pageNo);\n },\n \"last\": function () {\n callback.call(this, this.page.totalPages - 1);\n }\n };\n\n if (_act in processor) {\n processor[_act].call(this);\n }\n else {\n callback.call(this, _act-1);\n }\n };\n\n var navigationUpdate = function () {\n var self = this;\n if (this.page) {\n var page = {\n hasPage: false,\n currentPage: this.page.currentPage,\n pageSize: this.page.pageSize,\n totalElements: this.page.totalElements,\n totalPages: this.page.totalPages,\n firstIcon: this.config.page.firstIcon,\n prevIcon: this.config.page.prevIcon || \"«\",\n nextIcon: this.config.page.nextIcon || \"»\",\n lastIcon: this.config.page.lastIcon,\n };\n var navigationItemCount = this.config.page.navigationItemCount;\n\n\n page[\"@paging\"] = (function () {\n var returns = [];\n\n var startI = page.currentPage - Math.floor(navigationItemCount / 2);\n if (startI < 0) startI = 0;\n var endI = page.currentPage + navigationItemCount;\n if (endI > page.totalPages) endI = page.totalPages;\n\n if (endI - startI > navigationItemCount) {\n endI = startI + navigationItemCount;\n }\n\n if(endI - startI < navigationItemCount){\n startI = endI - navigationItemCount;\n }\n if (startI < 0) startI = 0;\n\n for (var p = startI, l = endI; p < l; p++) {\n returns.push({'pageNo': (p + 1), 'selected': page.currentPage == p});\n }\n return returns;\n })();\n\n if(page[\"@paging\"].length > 0){\n page.hasPage = true;\n }\n\n this.$[\"page\"][\"navigation\"].html(GRID.tmpl.get(\"page_navigation\", page));\n this.$[\"page\"][\"navigation\"].find(\"[data-ax5grid-page-move]\").on(\"click\", function () {\n var act = this.getAttribute(\"data-ax5grid-page-move\");\n onclickPageMove.call(self, act);\n });\n } else {\n this.$[\"page\"][\"navigation\"].empty();\n }\n };\n\n var statusUpdate = function () {\n var fromRowIndex = this.xvar.paintStartRowIndex;\n var toRowIndex = this.xvar.paintStartRowIndex + this.xvar.paintRowCount - 1;\n //var totalElements = (this.page && this.page.totalElements) ? this.page.totalElements : this.xvar.dataRowCount;\n var totalElements = this.xvar.dataRowCount;\n if (toRowIndex > totalElements) {\n toRowIndex = totalElements;\n }\n\n this.$[\"page\"][\"status\"].html(GRID.tmpl.get(\"page_status\", {\n fromRowIndex: U.number(fromRowIndex + 1, {\"money\": true}),\n toRowIndex: U.number(toRowIndex, {\"money\": true}),\n totalElements: U.number(totalElements, {\"money\": true}),\n dataRowCount: (totalElements !== this.xvar.dataRealRowCount) ? U.number(this.xvar.dataRealRowCount, {\"money\": true}) : false\n }));\n };\n\n GRID.page = {\n navigationUpdate: navigationUpdate,\n statusUpdate: statusUpdate\n };\n\n})();","// ax5.ui.grid.scroller\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n var convertScrollPosition = {\n \"vertical\": function (css, _var) {\n var _content_height = _var._content_height - _var._panel_height;\n var _scroller_height = _var._vertical_scroller_height - _var.verticalScrollBarHeight;\n var top = (_content_height * css.top) / _scroller_height;\n if (top < 0) top = 0;\n else if (_content_height < top) {\n top = _content_height;\n }\n return {\n top: -top\n }\n },\n \"horizontal\": function (css, _var) {\n var _content_width = _var._content_width - _var._panel_width;\n var _scroller_width = _var._horizontal_scroller_width - _var.horizontalScrollBarWidth;\n var left = (_content_width * css.left) / _scroller_width;\n if (left < 0) left = 0;\n else if (_content_width < left) {\n left = _content_width;\n }\n return {\n left: -left\n }\n }\n };\n var convertScrollBarPosition = {\n \"vertical\": function (_top, _var) {\n\n var type = \"vertical\";\n var _content_height = _var._content_height - _var._panel_height;\n var _scroller_height = _var._vertical_scroller_height - _var.verticalScrollBarHeight;\n var top = (_scroller_height * _top) / _content_height;\n\n if (-top > _scroller_height) {\n top = -_scroller_height;\n\n var scrollPositon = convertScrollPosition[type].call(this, {top: -top}, {\n _content_width: _var._content_width,\n _content_height: _var._content_height,\n _panel_width: _var._panel_width,\n _panel_height: _var._panel_height,\n _horizontal_scroller_width: _var._horizontal_scroller_width,\n _vertical_scroller_height: _var._vertical_scroller_height,\n verticalScrollBarHeight: _var.verticalScrollBarHeight,\n horizontalScrollBarWidth: _var.horizontalScrollBarWidth\n });\n\n GRID.body.scrollTo.call(this, scrollPositon);\n }\n\n return -top\n },\n \"horizontal\": function (_left, _var) {\n var type = \"horizontal\";\n var _content_width = _var._content_width - _var._panel_width;\n var _scroller_width = _var._horizontal_scroller_width - _var.horizontalScrollBarWidth;\n var left = (_scroller_width * _left) / _content_width;\n\n if (-left > _scroller_width) {\n left = -_scroller_width;\n var scrollPositon = convertScrollPosition[type].call(this, {left: -left}, {\n _content_width: _var._content_width,\n _content_height: _var._content_height,\n _panel_width: _var._panel_width,\n _panel_height: _var._panel_height,\n _horizontal_scroller_width: _var._horizontal_scroller_width,\n _vertical_scroller_height: _var._vertical_scroller_height,\n verticalScrollBarHeight: _var.verticalScrollBarHeight,\n horizontalScrollBarWidth: _var.horizontalScrollBarWidth\n });\n\n GRID.header.scrollTo.call(this, scrollPositon);\n GRID.body.scrollTo.call(this, scrollPositon);\n }\n\n return -left\n }\n };\n var scrollBarMover = {\n \"click\": function (track, bar, type, e) {\n\n // 마우스 무브 완료 타임과 클릭타임 차이가 20 보다 작으면 클릭이벤트 막기.\n if ((new Date()).getTime() - GRID.scroller.moveout_timer < 20) {\n return false;\n }\n\n var self = this,\n trackOffset = track.offset(),\n barBox = {\n width: bar.outerWidth(), height: bar.outerHeight()\n },\n trackBox = {\n width: track.innerWidth(), height: track.innerHeight()\n },\n _vertical_scroller_height = self.$[\"scroller\"][\"vertical\"].innerHeight(),\n _panel_height = self.$[\"panel\"][\"body\"].height(),\n _horizontal_scroller_width = self.$[\"scroller\"][\"horizontal\"].innerWidth(),\n _panel_width = self.$[\"panel\"][\"body\"].width(),\n _content_height = self.xvar.scrollContentHeight,\n _content_width = self.xvar.scrollContentWidth,\n verticalScrollBarHeight = self.$[\"scroller\"][\"vertical-bar\"].outerHeight(),\n horizontalScrollBarWidth = self.$[\"scroller\"][\"horizontal-bar\"].outerWidth(),\n getScrollerPosition = {\n \"vertical\": function (e) {\n var mouseObj = GRID.util.getMousePosition(e);\n // track을 벗어 나지 안도록 범위 체크\n var newTop = mouseObj.clientY - trackOffset.top;\n if (newTop < 0) {\n newTop = 0;\n }\n else if ((newTop + barBox.height) > trackBox.height) {\n newTop = trackBox.height - barBox.height;\n }\n return {top: newTop};\n },\n \"horizontal\": function (e) {\n var mouseObj = GRID.util.getMousePosition(e);\n // track을 벗어 나지 안도록 범위 체크\n var newLeft = mouseObj.clientX - trackOffset.left;\n if (newLeft < 0) {\n newLeft = 0;\n }\n else if ((newLeft + barBox.width) > trackBox.width) {\n newLeft = trackBox.width - barBox.width;\n }\n return {left: newLeft};\n }\n };\n\n var css = getScrollerPosition[type](e);\n bar.css(css);\n\n var scrollPositon = convertScrollPosition[type].call(self, css, {\n _content_width: _content_width,\n _content_height: _content_height,\n _panel_width: _panel_width,\n _panel_height: _panel_height,\n _horizontal_scroller_width: _horizontal_scroller_width,\n _vertical_scroller_height: _vertical_scroller_height,\n verticalScrollBarHeight: verticalScrollBarHeight,\n horizontalScrollBarWidth: horizontalScrollBarWidth\n });\n if (type === \"horizontal\") GRID.header.scrollTo.call(self, scrollPositon);\n GRID.body.scrollTo.call(self, scrollPositon);\n },\n \"on\": function (track, bar, type, e) {\n var self = this,\n barOffset = bar.position(),\n barBox = {\n width: bar.outerWidth(), height: bar.outerHeight()\n },\n trackBox = {\n width: track.innerWidth(), height: track.innerHeight()\n },\n\n _vertical_scroller_height = self.$[\"scroller\"][\"vertical\"].innerHeight(),\n _panel_height = self.$[\"panel\"][\"body\"].height(),\n _horizontal_scroller_width = self.$[\"scroller\"][\"horizontal\"].innerWidth(),\n _panel_width = self.$[\"panel\"][\"body\"].width(),\n _content_height = self.xvar.scrollContentHeight,\n _content_width = self.xvar.scrollContentWidth,\n verticalScrollBarHeight = self.$[\"scroller\"][\"vertical-bar\"].outerHeight(),\n horizontalScrollBarWidth = self.$[\"scroller\"][\"horizontal-bar\"].outerWidth(),\n\n getScrollerPosition = {\n \"vertical\": function (e) {\n var mouseObj = GRID.util.getMousePosition(e);\n self.xvar.__da = mouseObj.clientY - self.xvar.mousePosition.clientY;\n // track을 벗어 나지 안도록 범위 체크\n var newTop = barOffset.top + self.xvar.__da;\n if (newTop < 0) {\n newTop = 0;\n }\n else if ((newTop + barBox.height) > trackBox.height) {\n newTop = trackBox.height - barBox.height;\n }\n return {top: newTop};\n },\n \"horizontal\": function (e) {\n var mouseObj = GRID.util.getMousePosition(e);\n self.xvar.__da = mouseObj.clientX - self.xvar.mousePosition.clientX;\n // track을 벗어 나지 안도록 범위 체크\n var newLeft = barOffset.left + self.xvar.__da;\n if (newLeft < 0) {\n newLeft = 0;\n }\n else if ((newLeft + barBox.width) > trackBox.width) {\n newLeft = trackBox.width - barBox.width;\n }\n return {left: newLeft};\n }\n };\n\n self.xvar.__da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n\n jQuery(document.body)\n .bind(GRID.util.ENM[\"mousemove\"] + \".ax5grid-\" + this.instanceId, function (e) {\n var css = getScrollerPosition[type](e);\n bar.css(css);\n\n var scrollPositon = convertScrollPosition[type].call(self, css, {\n _content_width: _content_width,\n _content_height: _content_height,\n _panel_width: _panel_width,\n _panel_height: _panel_height,\n _horizontal_scroller_width: _horizontal_scroller_width,\n _vertical_scroller_height: _vertical_scroller_height,\n verticalScrollBarHeight: verticalScrollBarHeight,\n horizontalScrollBarWidth: horizontalScrollBarWidth\n });\n\n if (type === \"horizontal\") GRID.header.scrollTo.call(self, scrollPositon);\n GRID.body.scrollTo.call(self, scrollPositon);\n })\n .bind(GRID.util.ENM[\"mouseup\"] + \".ax5grid-\" + this.instanceId, function (e) {\n scrollBarMover.off.call(self);\n })\n .bind(\"mouseleave.ax5grid-\" + this.instanceId, function (e) {\n scrollBarMover.off.call(self);\n });\n\n jQuery(document.body)\n .attr('unselectable', 'on')\n .css('user-select', 'none')\n .on('selectstart', false);\n },\n \"off\": function () {\n\n GRID.scroller.moveout_timer = (new Date()).getTime();\n\n jQuery(document.body)\n .unbind(GRID.util.ENM[\"mousemove\"] + \".ax5grid-\" + this.instanceId)\n .unbind(GRID.util.ENM[\"mouseup\"] + \".ax5grid-\" + this.instanceId)\n .unbind(\"mouseleave.ax5grid-\" + this.instanceId);\n\n jQuery(document.body)\n .removeAttr('unselectable')\n .css('user-select', 'auto')\n .off('selectstart');\n }\n };\n var scrollContentMover = {\n \"wheel\": function (delta) {\n let self = this,\n _body_scroll_position = self.$[\"panel\"][\"body-scroll\"].position(),\n _panel_height = self.$[\"panel\"][\"body\"].height(),\n _panel_width = self.$[\"panel\"][\"body\"].width(),\n _content_height = self.xvar.scrollContentHeight,\n _content_width = self.xvar.scrollContentWidth;\n\n if (isNaN(_content_height) || isNaN(_content_width)) {\n return false;\n }\n\n let newLeft, newTop,\n _top_is_end = false,\n _left_is_end = false;\n\n newLeft = _body_scroll_position.left - delta.x;\n newTop = _body_scroll_position.top - delta.y;\n\n // newTop이 범위를 넘었는지 체크\n if (newTop >= 0) {\n newTop = 0;\n _top_is_end = true;\n } else if (newTop <= _panel_height - _content_height) {\n newTop = _panel_height - _content_height;\n if (newTop >= 0) newTop = 0;\n _top_is_end = true;\n } else {\n if (delta.y == 0) _top_is_end = true;\n }\n\n\n // newLeft이 범위를 넘었는지 체크\n if (newLeft >= 0) {\n newLeft = 0;\n _left_is_end = true;\n } else if (newLeft <= _panel_width - _content_width) {\n newLeft = _panel_width - _content_width;\n if (newLeft >= 0) newLeft = 0;\n _left_is_end = true;\n } else {\n if (delta.x == 0) _left_is_end = true;\n }\n\n //self.$[\"panel\"][\"body-scroll\"].css({left: newLeft, top: newTop});\n GRID.header.scrollTo.call(this, {left: newLeft});\n GRID.body.scrollTo.call(this, {left: newLeft, top: newTop});\n resize.call(this);\n\n return !_top_is_end || !_left_is_end;\n },\n \"on\": function () {\n let self = this,\n _body_scroll_position = self.$[\"panel\"][\"body-scroll\"].position(),\n _panel_height = self.$[\"panel\"][\"body\"].height(),\n _panel_width = self.$[\"panel\"][\"body\"].width(),\n _content_height = self.xvar.scrollContentHeight,\n _content_width = self.xvar.scrollContentWidth,\n getContentPosition = function (e) {\n let mouseObj = GRID.util.getMousePosition(e), newLeft, newTop;\n\n self.xvar.__x_da = mouseObj.clientX - self.xvar.mousePosition.clientX;\n self.xvar.__y_da = mouseObj.clientY - self.xvar.mousePosition.clientY;\n\n newLeft = _body_scroll_position.left + self.xvar.__x_da;\n newTop = _body_scroll_position.top + self.xvar.__y_da;\n\n // newTop이 범위를 넘었는지 체크\n if (newTop >= 0) {\n newTop = 0;\n } else if (newTop <= _panel_height - _content_height) {\n newTop = _panel_height - _content_height;\n if (newTop >= 0) newTop = 0;\n }\n\n // newLeft이 범위를 넘었는지 체크\n if (newLeft >= 0) {\n newLeft = 0;\n } else if (newLeft <= _panel_width - _content_width) {\n newLeft = _panel_width - _content_width;\n if (newLeft >= 0) newLeft = 0;\n }\n\n return {\n left: newLeft, top: newTop\n }\n };\n\n\n this.xvar.__x_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n this.xvar.__y_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n this.xvar.touchmoved = false;\n\n jQuery(document.body)\n .on(\"touchmove\" + \".ax5grid-\" + this.instanceId, function (e) {\n\n let css = getContentPosition(e);\n GRID.header.scrollTo.call(self, {left: css.left});\n GRID.body.scrollTo.call(self, css, \"noRepaint\");\n resize.call(self);\n U.stopEvent(e);\n self.xvar.touchmoved = true;\n })\n .on(\"touchend\" + \".ax5grid-\" + this.instanceId, function (e) {\n if(self.xvar.touchmoved) {\n let css = getContentPosition(e);\n GRID.header.scrollTo.call(self, {left: css.left});\n GRID.body.scrollTo.call(self, css);\n resize.call(self);\n U.stopEvent(e);\n scrollContentMover.off.call(self);\n }\n });\n\n jQuery(document.body)\n .attr('unselectable', 'on')\n .css('user-select', 'none')\n .on('selectstart', false);\n },\n \"off\": function () {\n\n jQuery(document.body)\n .off(\"touchmove\" + \".ax5grid-\" + this.instanceId)\n .off(\"touchend\" + \".ax5grid-\" + this.instanceId);\n\n jQuery(document.body)\n .removeAttr('unselectable')\n .css('user-select', 'auto')\n .off('selectstart');\n }\n };\n\n var init = function () {\n let self = this,\n margin = this.config.scroller.trackPadding;\n\n this.$[\"scroller\"][\"vertical-bar\"].css({width: this.config.scroller.size - (margin + 1), left: margin / 2});\n this.$[\"scroller\"][\"horizontal-bar\"].css({height: this.config.scroller.size - (margin + 1), top: margin / 2});\n\n this.$[\"scroller\"][\"vertical-bar\"]\n .on(GRID.util.ENM[\"mousedown\"], (function (e) {\n this.xvar.mousePosition = GRID.util.getMousePosition(e);\n scrollBarMover.on.call(this, this.$[\"scroller\"][\"vertical\"], this.$[\"scroller\"][\"vertical-bar\"], \"vertical\", e);\n }).bind(this))\n .on(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n this.$[\"scroller\"][\"vertical\"]\n .on(\"click\", (function (e) {\n if (e.target.getAttribute(\"data-ax5grid-scroller\") == \"vertical\") {\n scrollBarMover.click.call(this, this.$[\"scroller\"][\"vertical\"], this.$[\"scroller\"][\"vertical-bar\"], \"vertical\", e);\n }\n }).bind(this));\n\n this.$[\"scroller\"][\"horizontal-bar\"]\n .on(GRID.util.ENM[\"mousedown\"], (function (e) {\n this.xvar.mousePosition = GRID.util.getMousePosition(e);\n scrollBarMover.on.call(this, this.$[\"scroller\"][\"horizontal\"], this.$[\"scroller\"][\"horizontal-bar\"], \"horizontal\", e);\n }).bind(this))\n .on(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n this.$[\"scroller\"][\"horizontal\"]\n .on(\"click\", (function (e) {\n if (e.target.getAttribute(\"data-ax5grid-scroller\") == \"horizontal\") {\n scrollBarMover.click.call(this, this.$[\"scroller\"][\"horizontal\"], this.$[\"scroller\"][\"horizontal-bar\"], \"horizontal\", e);\n }\n }).bind(this));\n\n this.$[\"container\"][\"body\"].on('mousewheel DOMMouseScroll', (function (e) {\n let E = e.originalEvent, delta = {x: 0, y: 0};\n\n if (E.detail) {\n delta.y = E.detail * 10;\n } else {\n if (typeof E.deltaY === \"undefined\") {\n delta.y = -E.wheelDelta;\n delta.x = 0;\n } else {\n delta.y = E.deltaY;\n delta.x = E.deltaX;\n }\n }\n\n if (scrollContentMover.wheel.call(this, delta)) {\n U.stopEvent(e);\n }\n }).bind(this));\n\n if (document.addEventListener && ax5.info.supportTouch) {\n this.$[\"container\"][\"body\"]\n .on(\"touchstart\", '[data-ax5grid-panel]', function (e) {\n self.xvar.mousePosition = GRID.util.getMousePosition(e);\n scrollContentMover.on.call(self);\n });\n }\n };\n\n var resize = function () {\n var _vertical_scroller_height = this.$[\"scroller\"][\"vertical\"].height(),\n _horizontal_scroller_width = this.$[\"scroller\"][\"horizontal\"].width(),\n _panel_height = this.$[\"panel\"][\"body\"].height(),\n _panel_width = this.$[\"panel\"][\"body\"].width(),\n _content_height = this.xvar.scrollContentHeight,\n _content_width = this.xvar.scrollContentWidth,\n verticalScrollBarHeight = _panel_height * _vertical_scroller_height / _content_height,\n horizontalScrollBarWidth = _panel_width * _horizontal_scroller_width / _content_width;\n\n if (verticalScrollBarHeight < this.config.scroller.barMinSize) verticalScrollBarHeight = this.config.scroller.barMinSize;\n if (horizontalScrollBarWidth < this.config.scroller.barMinSize) horizontalScrollBarWidth = this.config.scroller.barMinSize;\n\n this.$[\"scroller\"][\"vertical-bar\"].css({\n top: convertScrollBarPosition.vertical.call(this, this.$.panel[\"body-scroll\"].position().top, {\n _content_width: _content_width,\n _content_height: _content_height,\n _panel_width: _panel_width,\n _panel_height: _panel_height,\n _horizontal_scroller_width: _horizontal_scroller_width,\n _vertical_scroller_height: _vertical_scroller_height,\n verticalScrollBarHeight: verticalScrollBarHeight,\n horizontalScrollBarWidth: horizontalScrollBarWidth\n }),\n height: verticalScrollBarHeight\n });\n\n //console.log(horizontalScrollBarWidth);\n\n this.$[\"scroller\"][\"horizontal-bar\"].css({\n left: convertScrollBarPosition.horizontal.call(this, this.$.panel[\"body-scroll\"].position().left, {\n _content_width: _content_width,\n _content_height: _content_height,\n _panel_width: _panel_width,\n _panel_height: _panel_height,\n _horizontal_scroller_width: _horizontal_scroller_width,\n _vertical_scroller_height: _vertical_scroller_height,\n verticalScrollBarHeight: verticalScrollBarHeight,\n horizontalScrollBarWidth: horizontalScrollBarWidth\n }),\n width: horizontalScrollBarWidth\n });\n\n _vertical_scroller_height = null;\n _horizontal_scroller_width = null;\n _panel_height = null;\n _panel_width = null;\n _content_height = null;\n _content_width = null;\n verticalScrollBarHeight = null;\n horizontalScrollBarWidth = null;\n };\n\n GRID.scroller = {\n // 타이머\n moveout_timer: (new Date()).getTime(),\n init: init,\n resize: resize\n };\n\n})();","// ax5.ui.grid.tmpl\n(function () {\n\n var GRID = ax5.ui.grid;\n var main = function () {\n return `\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
`;\n };\n\n\n var page_navigation = function(){\n return `\n {{#hasPage}}\n
\n {{#firstIcon}}{{/firstIcon}}\n \n
\n
\n {{#@paging}}\n \n {{/@paging}}\n
\n
\n \n {{#lastIcon}}{{/lastIcon}}\n
\n {{/hasPage}}\n
`;\n };\n\n\n var page_status = function(){\n return `{{fromRowIndex}} - {{toRowIndex}} of {{totalElements}}{{#dataRowCount}} ({{dataRowCount}}){{/dataRowCount}}`;\n };\n\n\n GRID.tmpl = {\n \"main\": main,\n \"page_navigation\": page_navigation,\n \"page_status\": page_status,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(GRID.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n\n})();","// ax5.ui.grid.util\n(function () {\n\n var GRID = ax5.ui.grid;\n var U = ax5.util;\n\n\n\n /**\n * @method ax5grid.util.divideTableByFrozenColumnIndex\n * @param _table\n * @param _frozenColumnIndex\n * @returns {{leftHeaderData: {rows: Array}, headerData: {rows: Array}}}\n */\n\n var divideTableByFrozenColumnIndex = function (_table, _frozenColumnIndex) {\n var tempTable_l = {rows: []};\n var tempTable_r = {rows: []};\n for (var r = 0, rl = _table.rows.length; r < rl; r++) {\n var row = _table.rows[r];\n\n tempTable_l.rows[r] = {cols: []};\n tempTable_r.rows[r] = {cols: []};\n\n for (var c = 0, cl = row.cols.length; c < cl; c++) {\n var col = jQuery.extend({}, row.cols[c]);\n var colStartIndex = col.colIndex, colEndIndex = col.colIndex + col.colspan;\n\n if (colStartIndex < _frozenColumnIndex) {\n if (colEndIndex <= _frozenColumnIndex) {\n // 좌측편에 변형없이 추가\n tempTable_l.rows[r].cols.push(col);\n } else {\n var leftCol = jQuery.extend({}, col);\n var rightCol = jQuery.extend({}, leftCol);\n leftCol.colspan = _frozenColumnIndex - leftCol.colIndex;\n rightCol.colIndex = _frozenColumnIndex;\n rightCol.colspan = col.colspan - leftCol.colspan;\n\n tempTable_l.rows[r].cols.push(leftCol);\n tempTable_r.rows[r].cols.push(rightCol);\n }\n }\n else {\n // 오른편\n tempTable_r.rows[r].cols.push(col);\n }\n }\n }\n\n return {\n leftData: tempTable_l,\n rightData: tempTable_r\n }\n };\n\n var getMousePosition = function (e) {\n var mouseObj, originalEvent = (e.originalEvent) ? e.originalEvent : e;\n mouseObj = ('changedTouches' in originalEvent) ? originalEvent.changedTouches[0] : originalEvent;\n // clientX, Y 쓰면 스크롤에서 문제 발생\n return {\n clientX: mouseObj.pageX,\n clientY: mouseObj.pageY\n }\n };\n\n var ENM = {\n \"mousedown\": (ax5.info.supportTouch) ? \"touchstart\" : \"mousedown\",\n \"mousemove\": (ax5.info.supportTouch) ? \"touchmove\" : \"mousemove\",\n \"mouseup\": (ax5.info.supportTouch) ? \"touchend\" : \"mouseup\"\n };\n\n var makeHeaderTable = function (_columns) {\n var columns = U.deepCopy(_columns);\n var cfg = this.config;\n var table = {\n rows: []\n };\n var colIndex = 0;\n var maekRows = function (_columns, depth, parentField) {\n var row = {cols: []};\n var i = 0, l = _columns.length;\n\n for (; i < l; i++) {\n var field = _columns[i];\n var colspan = 1;\n\n if (!field.hidden) {\n field.colspan = 1;\n field.rowspan = 1;\n\n field.rowIndex = depth;\n field.colIndex = (function () {\n if (!parentField) {\n return colIndex++;\n } else {\n colIndex = parentField.colIndex + i + 1;\n return parentField.colIndex + i;\n }\n })();\n\n row.cols.push(field);\n\n if ('columns' in field) {\n colspan = maekRows(field.columns, depth + 1, field);\n } else {\n field.width = ('width' in field) ? field.width : cfg.columnMinWidth;\n }\n field.colspan = colspan;\n } else {\n\n }\n }\n\n if (row.cols.length > 0) {\n if (!table.rows[depth]) {\n table.rows[depth] = {cols: []};\n }\n table.rows[depth].cols = table.rows[depth].cols.concat(row.cols);\n return (row.cols.length - 1) + colspan;\n } else {\n return colspan;\n }\n\n };\n maekRows(columns, 0);\n\n // set rowspan\n for (var r = 0, rl = table.rows.length; r < rl; r++) {\n for (var c = 0, cl = table.rows[r].cols.length; c < cl; c++) {\n if (!('columns' in table.rows[r].cols[c])) {\n table.rows[r].cols[c].rowspan = rl - r;\n }\n }\n }\n\n return table;\n };\n\n var makeBodyRowTable = function (_columns) {\n var columns = U.deepCopy(_columns);\n var table = {\n rows: []\n };\n var colIndex = 0;\n var maekRows = function (_columns, depth, parentField) {\n var row = {cols: []};\n var i = 0, l = _columns.length;\n\n var selfMakeRow = function (__columns) {\n var i = 0, l = __columns.length;\n for (; i < l; i++) {\n var field = __columns[i];\n var colspan = 1;\n\n if (!field.hidden) {\n\n if ('key' in field) {\n field.colspan = 1;\n field.rowspan = 1;\n\n field.rowIndex = depth;\n field.colIndex = (function () {\n if (!parentField) {\n return colIndex++;\n } else {\n colIndex = parentField.colIndex + i + 1;\n return parentField.colIndex + i;\n }\n })();\n\n row.cols.push(field);\n if ('columns' in field) {\n colspan = maekRows(field.columns, depth + 1, field);\n }\n field.colspan = colspan;\n }\n else {\n if ('columns' in field) {\n selfMakeRow(field.columns, depth);\n }\n }\n } else {\n\n }\n }\n };\n\n for (; i < l; i++) {\n var field = _columns[i];\n var colspan = 1;\n\n if (!field.hidden) {\n\n if ('key' in field) {\n field.colspan = 1;\n field.rowspan = 1;\n\n field.rowIndex = depth;\n field.colIndex = (function () {\n if (!parentField) {\n return colIndex++;\n } else {\n colIndex = parentField.colIndex + i + 1;\n return parentField.colIndex + i;\n }\n })();\n\n row.cols.push(field);\n if ('columns' in field) {\n colspan = maekRows(field.columns, depth + 1, field);\n }\n field.colspan = colspan;\n }\n else {\n if ('columns' in field) {\n selfMakeRow(field.columns, depth);\n }\n }\n } else {\n\n }\n }\n\n if (row.cols.length > 0) {\n if (!table.rows[depth]) {\n table.rows[depth] = {cols: []};\n }\n table.rows[depth].cols = table.rows[depth].cols.concat(row.cols);\n return (row.cols.length - 1) + colspan;\n } else {\n return colspan;\n }\n\n };\n maekRows(columns, 0);\n\n (function (table) {\n // set rowspan\n for (var r = 0, rl = table.rows.length; r < rl; r++) {\n var row = table.rows[r];\n for (var c = 0, cl = row.cols.length; c < cl; c++) {\n var col = row.cols[c];\n if (!('columns' in col)) {\n col.rowspan = rl - r;\n }\n }\n }\n })(table);\n\n return table;\n };\n\n var makeBodyRowMap = function (_table) {\n var map = {};\n _table.rows.forEach(function (row) {\n row.cols.forEach(function (col) {\n map[col.rowIndex + \"_\" + col.colIndex] = jQuery.extend({}, col);\n });\n });\n return map;\n };\n\n var makeFootSumTable = function (_footSumColumns) {\n var table = {\n rows: []\n };\n\n for (var r = 0, rl = _footSumColumns.length; r < rl; r++) {\n var footSumRow = _footSumColumns[r];\n table.rows[r] = {cols: []};\n var addC = 0;\n for (var c = 0, cl = footSumRow.length; c < cl; c++) {\n if (addC > this.columns.length) break;\n var colspan = footSumRow[c].colspan || 1;\n if (footSumRow[c].label || footSumRow[c].key) {\n table.rows[r].cols.push({\n colspan: colspan,\n rowspan: 1,\n colIndex: addC,\n columnAttr: \"sum\",\n align: footSumRow[c].align,\n label: footSumRow[c].label,\n key: footSumRow[c].key,\n collector: footSumRow[c].collector,\n formatter: footSumRow[c].formatter\n });\n } else {\n table.rows[r].cols.push({\n colIndex: addC,\n colspan: colspan,\n rowspan: 1,\n label: \" \",\n });\n }\n addC += colspan;\n }\n\n if (addC < this.columns.length + 1) {\n for (var c = addC; c < this.colGroup.length; c++) {\n table.rows[r].cols.push({\n colIndex: (c + 1),\n colspan: 1,\n rowspan: 1,\n label: \" \",\n });\n }\n }\n }\n return table;\n };\n\n var makeBodyGroupingTable = function (_bodyGroupingColumns) {\n var table = {\n rows: []\n };\n\n var r = 0;\n table.rows[r] = {cols: []};\n var addC = 0;\n for (var c = 0, cl = _bodyGroupingColumns.length; c < cl; c++) {\n if (addC > this.columns.length) break;\n var colspan = _bodyGroupingColumns[c].colspan || 1;\n if (_bodyGroupingColumns[c].label || _bodyGroupingColumns[c].key) {\n table.rows[r].cols.push({\n colspan: colspan,\n rowspan: 1,\n rowIndex: 0,\n colIndex: addC,\n columnAttr: \"default\",\n align: _bodyGroupingColumns[c].align,\n label: _bodyGroupingColumns[c].label,\n key: _bodyGroupingColumns[c].key,\n collector: _bodyGroupingColumns[c].collector,\n formatter: _bodyGroupingColumns[c].formatter\n });\n } else {\n table.rows[r].cols.push({\n rowIndex: 0,\n colIndex: addC,\n colspan: colspan,\n rowspan: 1,\n label: \" \"\n });\n }\n addC += colspan;\n }\n\n if (addC < this.colGroup.length) {\n for (var c = addC; c < this.colGroup.length; c++) {\n table.rows[r].cols.push({\n rowIndex: 0,\n colIndex: (c + 1),\n colspan: 1,\n rowspan: 1,\n label: \" \",\n });\n }\n }\n\n return table;\n };\n\n var findPanelByColumnIndex = function (_dindex, _colIndex, _rowIndex) {\n var _containerPanelName;\n var _isScrollPanel = false;\n var _panels = [];\n\n if (this.xvar.frozenRowIndex > _dindex) _panels.push(\"top\");\n if (this.xvar.frozenColumnIndex > _colIndex) _panels.push(\"left\");\n _panels.push(\"body\");\n\n if (this.xvar.frozenColumnIndex <= _colIndex || this.xvar.frozenRowIndex <= _dindex) {\n _containerPanelName = _panels.join(\"-\");\n _panels.push(\"scroll\");\n _isScrollPanel = true;\n }\n\n return {\n panelName: _panels.join(\"-\"),\n containerPanelName : _containerPanelName,\n isScrollPanel: _isScrollPanel\n }\n };\n\n var getRealPathForDataItem = function (_dataPath) {\n var path = [];\n var _path = [].concat(_dataPath.split(/[\\.\\[\\]]/g));\n _path.forEach(function (n) {\n if (n !== \"\") path.push(\"[\\\"\" + n.replace(/['\\\"]/g, \"\") + \"\\\"]\");\n });\n _path = null;\n return path.join(\"\");\n };\n\n\n GRID.util = {\n divideTableByFrozenColumnIndex: divideTableByFrozenColumnIndex,\n getMousePosition: getMousePosition,\n ENM: ENM,\n makeHeaderTable: makeHeaderTable,\n makeBodyRowTable: makeBodyRowTable,\n makeBodyRowMap: makeBodyRowMap,\n makeFootSumTable: makeFootSumTable,\n makeBodyGroupingTable: makeBodyGroupingTable,\n findPanelByColumnIndex: findPanelByColumnIndex,\n getRealPathForDataItem: getRealPathForDataItem\n };\n\n})();","// ax5.ui.mediaViewer\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var MEDIAVIEWER;\n\n UI.addClass({\n className: \"mediaViewer\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5mediaViewer\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var myViewer = new ax5.ui.mediaViewer({\n * theme: \"danger\",\n * target: $(\"#media-viewer-target-0\"),\n * loading: {\n * icon: '',\n * text: 'Now Loading
'\n * },\n * media: {\n * width: '11%', height: '11%',\n * prevHandle: '',\n * nextHandle: '',\n * poster: '',\n * list: [\n * {\n * video: {\n * html: '',\n * poster: ''\n * }\n * },\n * {\n * video: {\n * html: '',\n * poster: ''\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg',\n * poster: 'http://www.improgrammer.net/wp-content/uploads/2015/11/top-20-node-js-Frameworks-1.jpg'\n * }\n * },\n * {\n * image: {\n * src: 'https://www.twilio.com/blog/wp-content/uploads/2013/11/Screen-Shot-2013-11-06-at-12.05.36-PM.png',\n * poster: 'https://www.twilio.com/blog/wp-content/uploads/2013/11/Screen-Shot-2013-11-06-at-12.05.36-PM.png'\n * }\n * }\n * ]\n * },\n * onClick: function () {\n * console.log(this);\n * }\n * });\n * ```\n */\n var ax5mediaViewer = function () {\n var self = this,\n cfg,\n ENM = {\n \"mousedown\": (ax5.info.supportTouch) ? \"touchstart\" : \"mousedown\",\n \"mousemove\": (ax5.info.supportTouch) ? \"touchmove\" : \"mousemove\",\n \"mouseup\": (ax5.info.supportTouch) ? \"touchend\" : \"mouseup\"\n },\n getMousePosition = function (e) {\n var mouseObj = ('changedTouches' in e.originalEvent) ? e.originalEvent.changedTouches[0] : e;\n\n return {\n clientX: mouseObj.clientX,\n clientY: mouseObj.clientY,\n time: (new Date()).getTime()\n }\n };\n\n this.instanceId = ax5.getGuid();\n this.config = {\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchend\" : \"click\"),\n theme: 'default',\n animateTime: 250,\n\n columnKeys: {\n src: 'src',\n poster: 'poster',\n html: 'html'\n },\n loading: {\n icon: '',\n text: 'Now Loading'\n },\n viewer: {\n prevHandle: false,\n nextHandle: false,\n ratio: 16 / 9\n },\n media: {\n prevHandle: '<',\n nextHandle: '>',\n width: 36, height: 36,\n list: []\n }\n };\n this.queue = [];\n this.openTimer = null;\n this.closeTimer = null;\n this.selectedIndex = 0;\n this.mousePosition = {};\n\n cfg = this.config;\n\n var\n onStateChanged = function (opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n return true;\n },\n getFrame = function () {\n var\n data = jQuery.extend(true, {id: this.id}, cfg);\n\n try {\n return MEDIAVIEWER.tmpl.get.call(this, \"frame\", data, cfg.columnKeys);\n }\n finally {\n data = null;\n }\n },\n onClick = function (e, target) {\n var\n result,\n elementType = \"\",\n processor = {\n 'thumbnail': function (target) {\n this.select(target.getAttribute(\"data-media-thumbnail\"));\n },\n 'prev': function (target) {\n if (this.selectedIndex > 0) {\n this.select(this.selectedIndex - 1);\n } else {\n this.select(cfg.media.list.length - 1);\n }\n },\n 'next': function (target) {\n if (this.selectedIndex < cfg.media.list.length - 1) {\n this.select(this.selectedIndex + 1);\n } else {\n this.select(0);\n }\n },\n 'viewer': function (target) {\n if (self.onClick) {\n self.onClick.call({\n media: cfg.media.list[this.selectedIndex]\n });\n }\n }\n };\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-media-thumbnail\")) {\n elementType = \"thumbnail\";\n return true;\n }\n else if (target.getAttribute(\"data-media-viewer-els\") == \"media-list-prev-handle\") {\n elementType = \"prev\";\n return true;\n }\n else if (target.getAttribute(\"data-media-viewer-els\") == \"media-list-next-handle\") {\n elementType = \"next\";\n return true;\n }\n else if (target.getAttribute(\"data-media-viewer-els\") == \"viewer\") {\n elementType = \"viewer\";\n return true;\n }\n else if (self.target.get(0) == target) {\n return true;\n }\n });\n\n if (target) {\n for (var key in processor) {\n if (key == elementType) {\n result = processor[key].call(this, target);\n break;\n }\n }\n return this;\n }\n return this;\n },\n getSelectedIndex = function () {\n if (cfg.media && cfg.media.list && cfg.media.list.length > 0) {\n var i = cfg.media.list.length, selecteIndex = 0;\n while (i--) {\n if (cfg.media.list[i].selected) {\n selecteIndex = i;\n break;\n }\n }\n\n if (selecteIndex == 0) {\n cfg.media.list[0].selected = true;\n }\n try {\n return selecteIndex;\n } finally {\n i = null;\n selecteIndex = null;\n }\n }\n else {\n return;\n }\n },\n alignMediaList = function () {\n var thumbnail = this.$[\"list\"].find('[data-media-thumbnail=' + this.selectedIndex + ']'),\n pos = thumbnail.position(), thumbnailWidth = thumbnail.outerWidth(),\n containerWidth = this.$[\"list\"].outerWidth(),\n parentLeft = this.$[\"list-table\"].position().left,\n parentWidth = this.$[\"list-table\"].outerWidth(),\n newLeft = 0;\n\n if (pos.left + thumbnailWidth + parentLeft > containerWidth) {\n newLeft = containerWidth - (pos.left + thumbnailWidth);\n if (parentLeft != newLeft) this.$[\"list-table\"].css({left: parentLeft = newLeft});\n }\n else if (pos.left + parentLeft < 0) {\n newLeft = pos.left;\n if (newLeft > 0) newLeft = 0;\n if (parentLeft != newLeft) this.$[\"list-table\"].css({left: parentLeft = newLeft});\n }\n\n if (parentLeft != newLeft) {\n if (parentLeft + parentWidth < containerWidth) {\n newLeft = containerWidth - parentWidth;\n if (newLeft > 0) newLeft = 0;\n this.$[\"list-table\"].css({left: newLeft});\n }\n }\n\n thumbnail = null;\n pos = null;\n thumbnailWidth = null;\n containerWidth = null;\n parentLeft = null;\n newLeft = null;\n },\n swipeMedia = {\n \"on\": function (mousePosition) {\n // console.log(mousePosition);\n var getSwipePosition = function (e) {\n var mouseObj = e;\n if ('changedTouches' in e.originalEvent) {\n mouseObj = e.originalEvent.changedTouches[0];\n }\n\n mousePosition.__dx = mouseObj.clientX - mousePosition.clientX;\n mousePosition.__dy = mouseObj.clientY - mousePosition.clientY;\n mousePosition.__time = (new Date()).getTime();\n\n if (Math.abs(mousePosition.__dx) > Math.abs(mousePosition.__dy)) {\n return {left: mousePosition.__dx};\n } else {\n return {top: mousePosition.__dy};\n }\n };\n var viewerWidth = this.$[\"viewer\"].width();\n\n jQuery(document.body)\n .bind(ENM[\"mousemove\"] + \".ax5media-viewer-\" + this.instanceId, function (e) {\n var position = getSwipePosition(e);\n\n if ('left' in position) {\n self.$[\"viewer-holder\"].css(position);\n if (Math.abs(self.mousePosition.__dx) > viewerWidth / 3) {\n //console.log(self.mousePosition);\n // trigger nextMedia\n\n var nextIndex = 0;\n\n if (self.mousePosition.__dx > 0) {\n if (self.selectedIndex > 0) {\n nextIndex = self.selectedIndex - 1;\n } else {\n nextIndex = cfg.media.list.length - 1;\n }\n }\n else {\n if (self.selectedIndex < cfg.media.list.length - 1) {\n nextIndex = self.selectedIndex + 1;\n }\n }\n\n self.select(nextIndex);\n swipeMedia.off.call(self);\n\n\n }\n\n U.stopEvent(e);\n }\n })\n .bind(ENM[\"mouseup\"] + \".ax5media-viewer-\" + this.instanceId, function (e) {\n swipeMedia.off.call(self);\n })\n .bind(\"mouseleave.ax5media-viewer-\" + this.instanceId, function (e) {\n swipeMedia.off.call(self);\n });\n\n jQuery(document.body)\n .attr('unselectable', 'on')\n .css('user-select', 'none')\n .on('selectstart', false);\n\n },\n \"off\": function () {\n self.$[\"viewer-holder\"].css({left: 0});\n jQuery(document.body)\n .unbind(ENM[\"mousemove\"] + \".ax5media-viewer-\" + this.instanceId)\n .unbind(ENM[\"mouseup\"] + \".ax5media-viewer-\" + this.instanceId)\n .unbind(\"mouseleave.ax5media-viewer-\" + this.instanceId);\n\n jQuery(document.body)\n .removeAttr('unselectable')\n .css('user-select', 'auto')\n .off('selectstart');\n\n }\n };\n /// private end\n\n /**\n * Preferences of mediaViewer UI\n * @method ax5mediaViewer.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5mediaViewer}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n this.id = 'ax5-media-viewer-' + ax5.getGuid();\n if (cfg.target && (cfg.media && cfg.media.list && cfg.media.list.length > 0)) {\n this.attach(cfg.target);\n }\n };\n\n /**\n * @method ax5mediaViewer.attach\n * @param target\n * @param options\n * @returns {ax5mediaViewer}\n */\n this.attach = function (target, options) {\n if (!target) {\n console.log(ax5.info.getError(\"ax5mediaViewer\", \"401\", \"setConfig\"));\n }\n if (typeof options != \"undefined\") {\n this.setConfig(options, false);\n }\n this.target = jQuery(target);\n this.target.html(getFrame.call(this));\n\n // 파트수집\n this.$ = {\n \"root\": this.target.find('[data-ax5-ui-media-viewer]'),\n \"viewer-holder\": this.target.find('[data-media-viewer-els=\"viewer-holder\"]'),\n \"viewer\": this.target.find('[data-media-viewer-els=\"viewer\"]'),\n \"viewer-loading\": this.target.find('[data-media-viewer-els=\"viewer-loading\"]'),\n \"list-holder\": this.target.find('[data-media-viewer-els=\"media-list-holder\"]'),\n \"list-prev-handle\": this.target.find('[data-media-viewer-els=\"media-list-prev-handle\"]'),\n \"list\": this.target.find('[data-media-viewer-els=\"media-list\"]'),\n \"list-table\": this.target.find('[data-media-viewer-els=\"media-list-table\"]'),\n \"list-next-handle\": this.target.find('[data-media-viewer-els=\"media-list-next-handle\"]')\n };\n\n this.align();\n\n jQuery(window).unbind(\"resize.ax5media-viewer-\" + this.id).bind(\"resize.ax5media-viewer-\" + this.id, (function () {\n this.align();\n alignMediaList.call(this);\n }).bind(this));\n\n this.target.unbind(\"click\").bind(\"click\", (function (e) {\n e = e || window.event;\n onClick.call(this, e);\n U.stopEvent(e);\n }).bind(this));\n\n this.$.viewer\n .unbind(ENM[\"mousedown\"])\n .bind(ENM[\"mousedown\"], (function (e) {\n this.mousePosition = getMousePosition(e);\n swipeMedia.on.call(this, this.mousePosition);\n }).bind(this))\n .unbind(\"dragstart\")\n .bind(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n\n this.select(getSelectedIndex.call(this));\n return this;\n };\n\n /**\n * @method ax5mediaViewer.align\n * @returns {ax5mediaViewer}\n */\n this.align = function () {\n // viewer width, height\n this.$[\"viewer-holder\"].css({height: this.$[\"viewer\"].width() / cfg.viewer.ratio});\n this.$[\"viewer\"].css({height: this.$[\"viewer\"].width() / cfg.viewer.ratio});\n\n if (this.$[\"viewer\"].data(\"media-type\") == \"image\") {\n var $img = this.$[\"viewer\"].find(\"img\");\n $img.css({\n width: this.$[\"viewer\"].height() * this.$[\"viewer\"].data(\"img-ratio\"), height: this.$[\"viewer\"].height()\n });\n setTimeout((function (_img) {\n _img.css({left: (this.$[\"viewer\"].width() - _img.width()) / 2});\n }).bind(this, $img), 1);\n }\n else if (this.$[\"viewer\"].data(\"media-type\") == \"video\") {\n this.$[\"viewer\"].find(\"iframe\").css({width: this.$[\"viewer\"].height() * this.$[\"viewer\"].data(\"img-ratio\"), height: this.$[\"viewer\"].height()});\n }\n this.$[\"viewer-loading\"].css({height: this.$[\"viewer\"].height()});\n\n var mediaThumbnailWidth = (U.right(cfg.media.width, 1) == '%') ? U.number(cfg.media.width) / 100 * this.$[\"viewer\"].width() : U.number(cfg.media.width),\n mediaThumbnailHeight = (U.right(cfg.media.height, 1) == '%') ? U.number(cfg.media.height) / 100 * this.$[\"viewer\"].width() : U.number(cfg.media.height);\n\n mediaThumbnailWidth = Math.floor(mediaThumbnailWidth);\n mediaThumbnailHeight = Math.floor(mediaThumbnailHeight);\n\n this.$[\"list-prev-handle\"].css({width: mediaThumbnailWidth * 1.5});\n this.$[\"list-next-handle\"].css({width: mediaThumbnailWidth * 1.5});\n this.$[\"list\"].css({height: mediaThumbnailHeight});\n this.$[\"list-table\"].find('[data-media-thumbnail]').css({width: mediaThumbnailWidth, height: mediaThumbnailHeight});\n this.$[\"list-table\"].find('[data-media-thumbnail-video]').css({width: mediaThumbnailWidth, height: mediaThumbnailHeight});\n\n\n return this;\n };\n\n /**\n * @method ax5mediaViewer.select\n * @param index\n * @returns {ax5mediaViewer}\n */\n this.select = (function () {\n var mediaView = {\n image: function (obj, callback) {\n self.$[\"viewer-loading\"].show();\n var dim = [this.$[\"viewer\"].width(), this.$[\"viewer\"].height()];\n var img = new Image();\n img.src = obj.image[cfg.columnKeys.src];\n img.onload = function () {\n self.$[\"viewer-loading\"].fadeOut();\n var h = dim[1];\n var w = h * img.width / img.height;\n callback(img, Math.floor(w), h);\n };\n return img;\n },\n video: function (obj, callback) {\n self.$[\"viewer-loading\"].show();\n var dim = [this.$[\"viewer\"].width(), this.$[\"viewer\"].height()];\n var html = jQuery(obj.video[cfg.columnKeys.html]);\n callback(html, dim[0], dim[1]);\n self.$[\"viewer-loading\"].fadeOut();\n }\n };\n var onLoad = {\n image: function (img, w, h) {\n img.width = w;\n img.height = h;\n\n var $img = $(img);\n this.$[\"viewer\"].html($img);\n $img.css({left: (this.$[\"viewer\"].width() - w) / 2});\n\n this.$[\"viewer\"].data(\"media-type\", \"image\");\n this.$[\"viewer\"].data(\"img-ratio\", w / h);\n },\n video: function (html, w, h) {\n html.css({width: w, height: h});\n this.$[\"viewer\"].html(html);\n this.$[\"viewer\"].data(\"media-type\", \"video\");\n this.$[\"viewer\"].data(\"img-ratio\", w / h);\n }\n };\n var select = function (index) {\n this.$[\"list\"].find('[data-media-thumbnail]').removeClass(\"selected\");\n this.$[\"list\"].find('[data-media-thumbnail=' + index + ']').addClass(\"selected\");\n alignMediaList.call(this);\n };\n\n return function (index) {\n if (typeof index === \"undefined\") return this;\n this.selectedIndex = Number(index);\n var media = cfg.media.list[index];\n select.call(this, index);\n\n for (var key in mediaView) {\n if (media[key]) {\n mediaView[key].call(this, media, onLoad[key].bind(this));\n break;\n }\n }\n return this;\n };\n })();\n\n /**\n * @method ax5mediaViewer.setMediaList\n * @param list\n * @returns {ax5mediaViewer}\n */\n this.setMediaList = function (list) {\n cfg.media.list = [].concat(list);\n this.attach(cfg.target);\n return this;\n };\n\n // 클래스 생성자\n this.main = (function () {\n\n UI.mediaViewer_instance = UI.mediaViewer_instance || [];\n UI.mediaViewer_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n else {\n this.init();\n }\n }).apply(this, arguments);\n };\n return ax5mediaViewer;\n })());\n\n MEDIAVIEWER = ax5.ui.mediaViewer;\n})();","// ax5.ui.mediaViewer.tmpl\n(function () {\n var MEDIAVIEWER = ax5.ui.mediaViewer;\n\n var frame = function (columnKeys) {\n return `\n \n
\n
\n {{#media}}\n
\n
{{{prevHandle}}}
\n
\n
\n {{#list}}\n
\n {{#image}}\n
\n
\n
\n {{/image}}\n {{#video}}\n
\n {{/video}}\n
\n {{/list}}\n
\n
\n
{{{nextHandle}}}
\n
\n {{/media}}\n
\n `;\n };\n\n MEDIAVIEWER.tmpl = {\n \"frame\": frame,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(MEDIAVIEWER.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();","// ax5.ui.uploader\n(function () {\n\n let UI = ax5.ui;\n let U = ax5.util;\n let UPLOADER;\n\n UI.addClass({\n className: \"uploader\",\n version: \"1.3.66\"\n }, (function () {\n\n let ax5uploader = function () {\n /**\n * @class ax5uploader\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n *\n * ```\n */\n let self = this, cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n clickEventName: \"click\", //(('ontouchstart' in document.documentElement) ? \"touchend\" : \"click\"),\n theme: 'default', // theme of uploader\n lang: { // 업로더 버튼 랭귀지 설정\n \"upload\": \"Upload\",\n \"abort\": \"Abort\"\n },\n uploadedBox: {\n columnKeys: {\n name: \"name\",\n type: \"type\",\n size: \"size\",\n uploadedName: \"uploadedName\",\n uploadedPath: \"uploadedPath\",\n downloadPath: \"downloadPath\",\n previewPath: \"previewPath\",\n thumbnail: \"thumbnail\"\n }\n },\n animateTime: 100,\n accept: \"*/*\", // 업로드 선택 파일 타입 설정\n multiple: false, // 다중 파일 업로드\n manualUpload: false, // 업로딩 시작 수동처리 여부\n progressBox: true // 업로드 프로그래스 박스 사용여부 false 이면 업로드 진행바를 표시 하지 않습니다. 개발자가 onprogress 함수를 이용하여 직접 구현 해야 합니다.\n };\n this.defaultBtns = {\n \"upload\": {label: this.config.lang[\"upload\"], theme: \"btn-primary\"},\n \"abort\": {label: this.config.lang[\"abort\"], theme: this.config.theme}\n };\n\n /// 업로드된 파일 큐\n this.uploadedFiles = [];\n /// 업로더 타겟\n this.$target = null;\n /// 업로드된 파일 정보들의 input 태그를 담아두는 컨테이너\n this.$inputContainer = null;\n /// input file 태그\n this.$inputFile = null;\n this.$inputFileForm = null;\n /// 파일 선택버튼\n this.$fileSelector = null;\n /// 파일 드랍존\n this.$dropZone = null;\n /// 파일 목록 표시박스\n this.$uploadedBox = null;\n\n this.__uploading = false;\n this.selectedFiles = [];\n this.selectedFilesTotal = 0;\n this.__loaded = 0;\n\n cfg = this.config;\n\n /**\n * UI 상태변경 이벤트 처리자\n * UI의 상태변경 : open, close, upload 등의 변경사항이 발생되면 onStateChanged 함수를 후출하여 이벤트를 처리\n */\n let bound_onStateChanged = (function (that) {\n\n let state = {\n \"open\": function () {\n\n },\n \"close\": function () {\n\n },\n \"upload\": function () {\n\n }\n };\n\n if (cfg.onStateChanged) {\n cfg.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n that = null;\n return true;\n }).bind(this);\n\n let bound_onSelectFile = (function (_evt) {\n let files;\n\n if (!ax5.info.supportFileApi) {\n // file API 지원 안되는 브라우저.\n // input file에 multiple 지원 안됨 그러므로 단일 파일 처리만 하면 됨.\n files = {path: _evt.target.value};\n }\n else if ('dataTransfer' in _evt) {\n files = _evt.dataTransfer.files;\n }\n else if ('target' in _evt) {\n files = _evt.target.files;\n }\n else if (_evt) {\n files = _evt;\n }\n\n if (!files) return false;\n\n /// selectedFiles에 현재 파일 정보 담아두기\n if (length in files) {\n this.selectedFiles = U.toArray(files);\n } else {\n this.selectedFiles = [files];\n }\n\n if (cfg.progressBox) {\n bound_openProgressBox();\n }\n if (!cfg.manualUpload) {\n this.send();\n }\n\n if (!ax5.info.supportFileApi) {\n bound_alignLayout(false);\n }\n }).bind(this);\n\n let bound_bindEvent = (function () {\n this.$fileSelector\n .off(\"click.ax5uploader\")\n .on(\"click.ax5uploader\", (function () {\n this.$inputFile.trigger(\"click\");\n }).bind(this));\n\n if (!ax5.info.supportFileApi) {\n this.$fileSelector\n .off(\"mouseover.ax5uploader\")\n .on(\"mouseover.ax5uploader\", (function () {\n bound_alignLayout(true);\n }).bind(this));\n\n this.$inputFile\n .off(\"mouseover.ax5uploader\")\n .on(\"mouseover.ax5uploader\", (function () {\n this.$fileSelector.addClass(\"active\");\n }).bind(this));\n\n this.$inputFile\n .off(\"mouseout.ax5uploader\")\n .on(\"mouseout.ax5uploader\", (function () {\n this.$fileSelector.removeClass(\"active\");\n\n bound_alignLayout(false);\n }).bind(this));\n }\n\n (function () {\n if (!this.$uploadedBox || !this.$uploadedBox.get(0)) return false;\n\n this.$uploadedBox.on(\"click\", \"[data-uploaded-item-cell]\", function () {\n let $this = jQuery(this),\n cellType = $this.attr(\"data-uploaded-item-cell\"),\n uploadedItemIndex = Number($this.parents('[data-ax5uploader-uploaded-item]').attr('data-ax5uploader-uploaded-item')),\n that = {};\n\n if (cfg.uploadedBox && cfg.uploadedBox.onclick) {\n that = {\n self: self,\n cellType: cellType,\n uploadedFiles: self.uploadedFiles,\n fileIndex: uploadedItemIndex\n };\n cfg.uploadedBox.onclick.call(that, that);\n }\n\n $this = null;\n cellType = null;\n uploadedItemIndex = null;\n that = null;\n });\n }).call(this);\n\n (function () {\n // dropZone 설정 방식 변경\n if (!ax5.info.supportFileApi) return false;\n if (!this.$dropZone || !this.$dropZone.get(0)) return false;\n\n let timer;\n\n this.$dropZone.parent()\n .on(\"click\", \"[data-ax5uploader-dropzone]\", function (e) {\n if (this == e.target || $.contains(this, e.target)) {\n if(U.isFunction(cfg.dropZone.onclick)) {\n cfg.dropZone.onclick.call({\n self: self\n });\n }else{\n self.$inputFile.trigger(\"click\");\n }\n }\n });\n\n this.$dropZone.get(0).addEventListener('dragover', function (e) {\n U.stopEvent(e);\n \n if(U.isFunction(cfg.dropZone.ondragover)) {\n cfg.dropZone.ondragover.call({\n self: self\n });\n }else{\n self.$dropZone.addClass(\"dragover\");\n }\n\n }, false);\n\n this.$dropZone.get(0).addEventListener('dragleave', function (e) {\n U.stopEvent(e);\n\n if(U.isFunction(cfg.dropZone.ondragover)) {\n cfg.dropZone.ondragout.call({\n self: self\n });\n }else{\n self.$dropZone.removeClass(\"dragover\");\n }\n\n }, false);\n\n this.$dropZone.get(0).addEventListener('drop', function (e) {\n U.stopEvent(e);\n\n if(U.isFunction(cfg.dropZone.ondrop)) {\n cfg.dropZone.ondrop.call({\n self: self\n });\n }else{\n self.$dropZone.removeClass(\"dragover\");\n }\n\n bound_onSelectFile(e || window.event);\n }, false);\n\n }).call(this);\n }).bind(this);\n\n let bound_alignLayout = (function (_TF) {\n // 상황이 좋지 않은경우 (만약 버튼 클릭으로 input file click이 되지 않는 다면 z-index값을 높여서 버튼위를 덮는다.)\n if (_TF) {\n if (!ax5.info.supportFileApi) {\n // ie9에서 inputFile을 직접 클릭하지 않으면 submit 오류발생함. submit access denied\n // 그래서 버튼위에 inputFile을 올려두어야 함. (position값을 이용하면 편하지만..)\n // 그런데 form을 안에두면 또 다른 이중폼 문제 발생소지 ㅜㅜ 불가피하게 버튼의 offset 값을 이용.\n let box = this.$fileSelector.offset();\n box.width = this.$fileSelector.outerWidth();\n box.height = this.$fileSelector.outerHeight();\n this.$inputFile.css(box);\n }\n } else {\n this.$inputFile.css({\n left: -1000, top: -1000\n });\n }\n }).bind(this);\n\n let bound_alignProgressBox = (function (append) {\n let _alignProgressBox = function () {\n let $window = jQuery(window), $body = jQuery(document.body);\n let pos = {}, positionMargin = 6,\n dim = {}, pickerDim = {},\n pickerDirection;\n\n // cfg.viewport.selector\n\n pos = (this.$progressBox.parent().get(0) == this.$target.get(0)) ? this.$fileSelector.position() : this.$fileSelector.offset();\n dim = {\n width: this.$fileSelector.outerWidth(),\n height: this.$fileSelector.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), $body.width()),\n winHeight: Math.max($window.height(), $body.height()),\n width: this.$progressBox.outerWidth(),\n height: this.$progressBox.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n if (!cfg.progressBoxDirection || cfg.progressBoxDirection === \"\" || cfg.progressBoxDirection === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = cfg.progressBoxDirection;\n }\n\n if (append) {\n this.$progressBox\n .addClass(\"direction-\" + pickerDirection);\n }\n\n let positionCSS = (function () {\n let css = {left: 0, top: 0};\n switch (pickerDirection) {\n case \"top\":\n css.left = pos.left + dim.width / 2 - pickerDim.width / 2;\n css.top = pos.top + dim.height + positionMargin;\n break;\n case \"bottom\":\n css.left = pos.left + dim.width / 2 - pickerDim.width / 2;\n css.top = pos.top - pickerDim.height - positionMargin;\n break;\n case \"left\":\n css.left = pos.left + dim.width + positionMargin;\n css.top = pos.top - pickerDim.height / 2 + dim.height / 2;\n break;\n case \"right\":\n css.left = pos.left - pickerDim.width - positionMargin;\n css.top = pos.top - pickerDim.height / 2 + dim.height / 2;\n break;\n }\n return css;\n })();\n\n (function () {\n if (pickerDirection == \"top\" || pickerDirection == \"bottom\") {\n if (positionCSS.left < 0) {\n positionCSS.left = positionMargin;\n this.$progressBoxArrow.css({left: (pos.left + dim.width / 2) - positionCSS.left});\n } else if (positionCSS.left + pickerDim.width > pickerDim.winWidth) {\n positionCSS.left = pickerDim.winWidth - pickerDim.width - positionMargin;\n this.$progressBoxArrow.css({left: (pos.left + dim.width / 2) - positionCSS.left});\n }\n }\n }).call(this);\n\n this.$progressBox\n .css(positionCSS);\n };\n\n this.$progressBox.css({top: -999});\n if (append) {\n // progressBox를 append 할 타겟 엘리먼트 펀단 후 결정.\n (function () {\n if (cfg.viewport) {\n return jQuery(cfg.viewport.selector);\n } else {\n return this.$target;\n }\n }).call(this).append(this.$progressBox);\n\n // progressBox 버튼에 이벤트 연결.\n this.$progressBox\n .off(\"click.ax5uploader\")\n .on(\"click.ax5uploader\", \"button\", (function (_evt) {\n let act = _evt.target.getAttribute(\"data-pregressbox-btn\");\n let processor = {\n \"upload\": function () {\n this.send();\n },\n \"abort\": function () {\n this.abort();\n }\n };\n if (processor[act]) processor[act].call(this);\n }).bind(this));\n }\n\n setTimeout((function () {\n _alignProgressBox.call(this);\n }).bind(this));\n }).bind(this);\n\n let bound_openProgressBox = (function () {\n this.$progressBox.removeClass(\"destroy\");\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.removeAttr(\"disabled\");\n\n // apend & align progress box\n bound_alignProgressBox(\"append\");\n\n // state change\n bound_onStateChanged({\n self: this,\n state: \"open\"\n });\n }).bind(this);\n\n let bound_closeProgressBox = (function () {\n this.$progressBox.addClass(\"destroy\");\n setTimeout((function () {\n this.$progressBox\n .remove();\n }).bind(this), cfg.animateTime);\n }).bind(this);\n\n let bound_startUpload = (function () {\n\n let processor = {\n \"html5\": function () {\n\n let uploadFile = this.selectedFiles.shift();\n if (!uploadFile) {\n // 업로드 종료\n bound_uploadComplete();\n return this;\n }\n\n let formData = new FormData();\n //서버로 전송해야 할 추가 파라미터 정보 설정\n\n this.$target.find(\"input\").each(function () {\n formData.append(this.name, this.value);\n });\n // 파일 아이템 추가\n formData.append(cfg.form.fileName, uploadFile);\n\n this.xhr = new XMLHttpRequest();\n this.xhr.open(\"post\", cfg.form.action, true);\n\n this.xhr.onload = function (e) {\n let res = e.target.response;\n try {\n if (typeof res == \"string\") res = U.parseJson(res);\n } catch (e) {\n return false;\n }\n if (cfg.debug) console.log(res);\n\n if (res.error) {\n if (cfg.debug) console.log(res.error);\n if (U.isFunction(cfg.onuploaderror)) {\n cfg.onuploaderror.call({\n self: this,\n error: res.error\n }, res);\n }\n self.send();\n return false;\n }\n\n bound_uploaded(res);\n self.send();\n };\n\n this.xhr.upload.onprogress = function (e) {\n // console.log(e.loaded, e.total);\n bound_updateProgressBar(e);\n if (U.isFunction(cfg.onprogress)) {\n cfg.onprogress.call({\n loaded: e.loaded,\n total: e.total\n }, e);\n }\n };\n this.xhr.send(formData); // multipart/form-data\n\n },\n \"form\": function () {\n\n /// i'm busy\n this.__uploading = true;\n\n // 폼과 iframe을 만들어 페이지 아래에 삽입 후 업로드\n let $iframe = jQuery('');\n jQuery(document.body).append($iframe);\n\n // onload 이벤트 핸들러\n // action에서 파일을 받아 처리한 결과값을 텍스트로 출력한다고 가정하고 iframe의 내부 데이터를 결과값으로 callback 호출\n $iframe.load(function () {\n let doc = this.contentWindow ? this.contentWindow.document : (this.contentDocument ? this.contentDocument : this.document),\n root = doc.documentElement ? doc.documentElement : doc.body,\n result = root.textContent ? root.textContent : root.innerText,\n res;\n\n try {\n res = JSON.parse(result);\n } catch (e) {\n res = {\n error: \"Syntax error\",\n body: result\n };\n }\n\n if (cfg.debug) console.log(res);\n if (res.error) {\n console.log(res);\n }\n else {\n bound_uploaded(res);\n $iframe.remove();\n\n setTimeout(function () {\n bound_uploadComplete();\n }, 300);\n }\n });\n\n this.$inputFileForm\n .attr(\"target\", 'ax5uploader-' + this.instanceId + '-iframe')\n .attr(\"action\", cfg.form.action)\n .submit();\n\n this.selectedFilesTotal = 1;\n bound_updateProgressBar({\n loaded: 1,\n total: 1\n });\n }\n };\n\n if (this.__uploading === false) {\n // 전체 파일 사이즈 구하기\n let filesTotal = 0;\n this.selectedFiles.forEach(function (n) {\n filesTotal += n.size;\n });\n this.selectedFilesTotal = filesTotal;\n this.__loaded = 0;\n\n this.__uploading = true; // 업로드 시작 상태 처리\n this.$progressUpload.attr(\"disabled\", \"disabled\");\n this.$progressAbort.removeAttr(\"disabled\");\n }\n\n processor[ax5.info.supportFileApi ? \"html5\" : \"form\"].call(this);\n\n }).bind(this);\n\n let bound_updateProgressBar = (function (e) {\n this.__loaded += e.loaded;\n this.$progressBar.css({width: U.number(this.__loaded / this.selectedFilesTotal * 100, {round: 2}) + '%'});\n if (e.lengthComputable) {\n if (e.loaded >= e.total) {\n\n }\n }\n }).bind(this);\n\n let bound_uploaded = (function (res) {\n if (cfg.debug) console.log(res);\n this.uploadedFiles.push(res);\n bound_repaintUploadedBox(); // 업로드된 파일 출력\n\n if (U.isFunction(cfg.onuploaded)) {\n cfg.onuploaded.call({\n self: this\n }, res);\n }\n }).bind(this);\n\n let bound_uploadComplete = (function () {\n this.__uploading = false; // 업로드 완료 상태처리\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.attr(\"disabled\", \"disabled\");\n\n if (cfg.progressBox) {\n bound_closeProgressBox();\n }\n if (U.isFunction(cfg.onuploadComplete)) {\n cfg.onuploadComplete.call({\n self: this\n });\n }\n // update uploadedFiles display\n\n /// reset inputFile\n bound_attachFileTag();\n }).bind(this);\n\n let bound_cancelUpload = (function () {\n\n let processor = {\n \"html5\": function () {\n if (this.xhr) {\n this.xhr.abort();\n }\n },\n \"form\": function () {\n\n }\n };\n\n this.__uploading = false; // 업로드 완료 상태처리\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.attr(\"disabled\", \"disabled\");\n\n processor[ax5.info.supportFileApi ? \"html5\" : \"form\"].call(this);\n\n if (cfg.progressBox) {\n bound_closeProgressBox();\n }\n\n //this.$inputFile.val(\"\");\n /// reset inputFile\n bound_attachFileTag();\n\n if (cfg.debug) console.log(\"cancelUpload\");\n // update uploadedFiles display\n }).bind(this);\n\n let bound_repaintUploadedBox = (function () {\n // uploadedBox 가 없다면 아무일도 하지 않음.\n // onuploaded 함수 이벤트를 이용하여 개발자가 직접 업로드디 박스를 구현 한다고 이해 하자.\n if (this.$uploadedBox === null) return this;\n\n this.$uploadedBox.html(\n UPLOADER.tmpl.get(\"upoadedBox\", {\n uploadedFiles: this.uploadedFiles,\n icon: cfg.uploadedBox.icon,\n lang: cfg.uploadedBox.lang,\n supportFileApi: !!ax5.info.supportFileApi\n }, cfg.uploadedBox.columnKeys)\n );\n }).bind(this);\n\n let bound_attachFileTag = (function () {\n if (this.$inputFile && this.$inputFile.get(0)) {\n this.$inputFile.remove();\n }\n if (this.$inputFileForm && this.$inputFileForm.get(0)) {\n this.$inputFileForm.remove();\n }\n\n this.$inputFile = jQuery(UPLOADER.tmpl.get.call(this, \"inputFile\", {\n instanceId: this.instanceId,\n multiple: cfg.multiple,\n accept: cfg.accept,\n name: cfg.form.fileName\n }));\n\n if (ax5.info.supportFileApi) {\n jQuery(document.body).append(this.$inputFile);\n } else {\n this.$fileSelector.attr(\"tabindex\", -1);\n this.$inputFileForm = jQuery(UPLOADER.tmpl.get.call(this, \"inputFileForm\", {\n instanceId: this.instanceId\n }));\n\n this.$inputFileForm.append(this.$inputFile);\n jQuery(document.body).append(this.$inputFileForm);\n }\n\n this.$inputFile\n .off(\"change.ax5uploader\")\n .on(\"change.ax5uploader\", (function (_evt) {\n bound_onSelectFile(_evt);\n }).bind(this));\n\n }).bind(this);\n\n /**\n * Preferences of uploader UI\n * @method ax5uploader.setConfig\n * @param {Object} _config - 클래스 속성값\n * @param {Element} _config.target\n * @param {Object} _config.form\n * @param {String} _config.form.action - upload URL\n * @param {String} _config.form.fileName - The name key of the upload file\n * @param {Boolean} [_config.multiple=false] - Whether multiple files. In a browser where fileApi is not supported (eg IE9), it only works with false.\n * @param {String} [_config.accept=\"\"] - accept mimeType (http://www.w3schools.com/TAgs/att_input_accept.asp)\n * @param {Boolean} [_config.manualUpload=false] - Whether to automatically upload when a file is selected.\n * @param {Boolean} [_config.progressBox=true] - Whether to use progressBox\n * @param {String} [_config.progressBoxDirection=auto] - ProgressBox display direction\n * @param {Object} [_config.dropZone]\n * @param {Element} [_config.dropZone.target]\n * @param {Function} [_config.dropZone.onclick]\n * @param {Function} [_config.dropZone.ondragover]\n * @param {Function} [_config.dropZone.ondragout]\n * @param {Function} [_config.dropZone.ondrop]\n * @param {Object} [_config.uploadedBox]\n * @param {Element} [_config.uploadedBox.target]\n * @param {Element} [_config.uploadedBox.icon]\n * @param {Object} [_config.uploadedBox.columnKeys]\n * @param {String} [_config.uploadedBox.columnKeys.name]\n * @param {String} [_config.uploadedBox.columnKeys.type]\n * @param {String} [_config.uploadedBox.columnKeys.size]\n * @param {String} [_config.uploadedBox.columnKeys.uploadedName]\n * @param {String} [_config.uploadedBox.columnKeys.downloadPath]\n * @param {Object} [_config.uploadedBox.lang]\n * @param {String} [_config.uploadedBox.lang.supportedHTML5_emptyListMsg]\n * @param {String} [_config.uploadedBox.lang.emptyListMsg]\n * @param {Function} [_config.uploadedBox.onchange]\n * @param {Function} [_config.uploadedBox.onclick]\n * @param {Function} [_config.validateSelectedFiles]\n * @param {Function} [_config.onprogress] - return loaded, total\n * @param {Function} [_config.onuploaded] - return self\n * @param {Function} [_config.onuploaderror] - return self, error\n * @param {Function} [_config.onuploadComplete] - return self\n * @returns {ax5uploader}\n * @example\n * ```js\n *\n * ```\n */\n this.init = function (_config) {\n cfg = jQuery.extend(true, {}, cfg, _config);\n if (!cfg.target) {\n console.log(ax5.info.getError(\"ax5uploader\", \"401\", \"init\"));\n return this;\n }\n\n this.$target = jQuery(cfg.target);\n\n // 파일 드랍존은 옵션 사항.\n if (cfg.dropZone && cfg.dropZone.target && ax5.info.supportFileApi) {\n this.$dropZone = jQuery(cfg.dropZone.target);\n this.$dropZone\n .attr(\"data-ax5uploader-dropzone\", this.instanceId);\n }\n\n // uploadedBox 옵션 사항\n if (cfg.uploadedBox && cfg.uploadedBox.target) {\n this.$uploadedBox = jQuery(cfg.uploadedBox.target);\n }\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n cfg = jQuery.extend(true, cfg, data);\n }\n }).call(this, U.parseJson(this.$target.attr(\"data-ax5uploader-config\"), true));\n\n\n // detect element\n /// fileSelector 수집\n this.$fileSelector = this.$target.find('[data-ax5uploader-button=\"selector\"]');\n\n if (this.$fileSelector.length === 0) {\n console.log(ax5.info.getError(\"ax5uploader\", \"402\", \"can not find file selector\"));\n return this;\n }\n\n // input file 추가\n bound_attachFileTag();\n\n // btns 확인\n cfg.btns = jQuery.extend({}, this.defaultBtns, cfg.btns);\n\n this.$progressBox = jQuery(UPLOADER.tmpl.get.call(this, \"progressBox\", {\n instanceId: this.instanceId,\n btns: cfg.btns\n }));\n this.$progressBar = this.$progressBox.find('[role=\"progressbar\"]');\n this.$progressBoxArrow = this.$progressBox.find(\".ax-progressbox-arrow\");\n this.$progressUpload = this.$progressBox.find('[data-pregressbox-btn=\"upload\"]');\n this.$progressAbort = this.$progressBox.find('[data-pregressbox-btn=\"abort\"]');\n\n // file API가 지원되지 않는 브라우저는 중지 기능 제공 못함.\n if (!ax5.info.supportFileApi) {\n this.$progressAbort.hide();\n }\n // 파일버튼 등에 이벤트 연결.\n bound_bindEvent();\n\n bound_repaintUploadedBox();\n return this;\n };\n\n /**\n * @method ax5uploader.send\n * @returns {ax5uploader}\n *\n */\n this.send = (function () {\n return function () {\n // 업로드 시작\n if (U.isFunction(cfg.validateSelectedFiles)) {\n let that = {\n self: this,\n uploadedFiles: this.uploadedFiles,\n selectedFiles: this.selectedFiles\n };\n if (!cfg.validateSelectedFiles.call(that, that)) {\n bound_cancelUpload();\n return false;\n // 전송처리 안함.\n }\n }\n\n bound_startUpload();\n return this;\n }\n })();\n\n /**\n * @method ax5uploader.abort\n * @returns {ax5uploader}\n */\n this.abort = (function () {\n return function () {\n if (!ax5.info.supportFileApi) {\n alert(\"This browser not supported abort method\");\n return this;\n }\n bound_cancelUpload();\n return this;\n };\n })();\n\n /**\n * @method ax5uploader.setUploadedFiles\n * @param {Array} _files - JSON formatting can all be overridden in columnKeys.\n * @returns {ax5uploader}\n * @example\n * ```js\n * var upload1 = new ax5.ui.uploader();\n * upload1.setConfig({\n * ...\n * });\n *\n *\n * $.ajax({\n * url: \"api/fileListLoad.php\",\n * success: function (res) {\n * // res JSON format\n * // [{\n * // \"name\": \"barcode-scan-ani.gif\",\n * // \"saveName\": \"barcode-scan-ani.gif\",\n * // \"type\": \"file\",\n * // \"fileSize\": \"3891664\",\n * // \"uploadedPath\": \"/ax5ui-uploader/test/api/files\",\n * // \"thumbUrl\": \"\"\n * // }]\n * upload1.setUploadedFiles(res);\n * }\n * });\n * ```\n */\n this.setUploadedFiles = function (_files) {\n if (U.isArray(_files)) {\n this.uploadedFiles = _files;\n }\n if (U.isString(_files)) {\n try {\n this.uploadedFiles = JSON.parse(_files);\n } catch (e) {\n\n }\n }\n\n bound_repaintUploadedBox();\n return this;\n };\n\n /**\n * Removes the object corresponding to the index passed to the argument from uploadedFiles.\n * @method ax5uploader.removeFile\n * @param {Number} _index\n * @returns {ax5uploader}\n * @example\n * ```js\n * // The actual file is not deleted\n * upload1.removeFile(fileIndex);\n * ```\n */\n this.removeFile = function (_index) {\n if (!isNaN(Number(_index))) {\n this.uploadedFiles.splice(_index, 1);\n }\n bound_repaintUploadedBox();\n return this;\n };\n\n /**\n * Empty uploadedFiles\n * @method ax5uploader.removeFileAll\n * @returns {ax5uploader}\n * @example\n * ```js\n *\n * ```\n */\n this.removeFileAll = function () {\n this.uploadedFiles = [];\n bound_repaintUploadedBox();\n return this;\n };\n\n /**\n * @method ax5uploader.selectFile\n * @returns {Boolean}\n */\n this.selectFile = function () {\n if (ax5.info.supportFileApi) {\n this.$inputFile.trigger(\"click\");\n return true;\n }\n return false;\n };\n\n // 클래스 생성자\n this.main = (function () {\n UI.uploader_instance = UI.uploader_instance || [];\n UI.uploader_instance.push(this);\n\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n else {\n //this.init();\n }\n }).apply(this, arguments);\n };\n return ax5uploader;\n })());\n\n UPLOADER = ax5.ui.uploader;\n})();\n\n\n// todo :\n// html5용 업로드 - 구현완료\n// abort, 여러개의 파일이 올라가는 중간에 abort 하면 업로드된 파일은 두고. 안올라간 파일만 중지 -- ok\n// set uploded files\n// uploaded files display, needs columnKeys\n// delete file\n\n// dropFile support","// ax5.ui.uploader.tmpl\n(function () {\n\n let UPLOADER = ax5.ui.uploader;\n\n let uploadProgress = function (columnKeys) {\n return `\n `;\n };\n\n let inputFile = function (columnKeys) {\n return ``;\n };\n\n let inputFileForm = function (columnKeys) {\n return ``;\n };\n\n let progressBox = function (columnKeys) {\n return `\n\n
\n
\n {{#btns}}\n
\n {{#btns}}\n {{#@each}}\n \n {{/@each}}\n {{/btns}}\n
\n {{/btns}}\n
\n
\n
\n`;\n };\n\n let upoadedBox = function (columnKeys) {\n return `\n{{#uploadedFiles}}\n
\n
{{{icon.download}}}
\n
{{${columnKeys.name}}}
\n
({{#@fn_get_byte}}{{${columnKeys.size}}}{{/@fn_get_byte}})
\n
{{{icon.delete}}}
\n
\n
{{/uploadedFiles}}\n{{^uploadedFiles}}\n{{#supportFileApi}}{{{lang.supportedHTML5_emptyListMsg}}}{{/supportFileApi}}\n{{^supportFileApi}}{{{lang.emptyListMsg}}}{{/supportFileApi}}\n{{/uploadedFiles}}\n`;\n };\n\n UPLOADER.tmpl = {\n \"uploadProgress\": uploadProgress,\n \"inputFile\": inputFile,\n \"inputFileForm\": inputFileForm,\n \"progressBox\": progressBox,\n \"upoadedBox\": upoadedBox,\n\n get: function (tmplName, data, columnKeys) {\n data[\"@fn_get_byte\"] = function() {\n return function (text, render) {\n return ax5.util.number(render(text), {round: 2, byte: true});\n }\n };\n return ax5.mustache.render(UPLOADER.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n\n})();","// ax5.ui.combobox\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var COMBOBOX;\n\n UI.addClass({\n className: \"combobox\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5combobox\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var options = [];\n * options.push({value: \"1\", text: \"string\"});\n * options.push({value: \"2\", text: \"number\"});\n * options.push({value: \"3\", text: \"substr\"});\n * options.push({value: \"4\", text: \"substring\"});\n * options.push({value: \"search\", text: \"search\"});\n * options.push({value: \"parseInt\", text: \"parseInt\"});\n * options.push({value: \"toFixed\", text: \"toFixed\"});\n * options.push({value: \"min\", text: \"min\"});\n * options.push({value: \"max\", text: \"max\"});\n *\n * var myCombo = new ax5.ui.combobox({\n * theme: \"danger\",\n * removeIcon: ''\n * });\n * ```\n */\n var ax5combobox = function () {\n var\n self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 250,\n removeIcon: 'X',\n lang: {\n noSelected: '',\n noOptions: 'no options',\n loading: 'now loading..'\n },\n columnKeys: {\n optionValue: 'value',\n optionText: 'text',\n optionSelected: 'selected'\n }\n };\n\n this.queue = [];\n this.activecomboboxOptionGroup = null;\n this.activecomboboxQueueIndex = -1;\n this.openTimer = null;\n this.closeTimer = null;\n this.waitOptionsCallback = null;\n this.keyUpTimer = null;\n\n cfg = this.config;\n\n var $window = jQuery(window);\n var\n ctrlKeys = {\n \"18\": \"KEY_ALT\",\n \"8\": \"KEY_BACKSPACE\",\n \"17\": \"KEY_CONTROL\",\n \"46\": \"KEY_DELETE\",\n \"40\": \"KEY_DOWN\",\n \"35\": \"KEY_END\",\n \"187\": \"KEY_EQUAL\",\n \"27\": \"KEY_ESC\",\n \"36\": \"KEY_HOME\",\n \"45\": \"KEY_INSERT\",\n \"37\": \"KEY_LEFT\",\n \"189\": \"KEY_MINUS\",\n \"34\": \"KEY_PAGEDOWN\",\n \"33\": \"KEY_PAGEUP\",\n // \"190\": \"KEY_PERIOD\",\n \"13\": \"KEY_RETURN\",\n \"39\": \"KEY_RIGHT\",\n \"16\": \"KEY_SHIFT\",\n // \"32\": \"KEY_SPACE\",\n \"9\": \"KEY_TAB\",\n \"38\": \"KEY_UP\",\n \"91\": \"KEY_WINDOW\"\n //\"107\" : \"NUMPAD_ADD\",\n //\"194\" : \"NUMPAD_COMMA\",\n //\"110\" : \"NUMPAD_DECIMAL\",\n //\"111\" : \"NUMPAD_DIVIDE\",\n //\"12\" : \"NUMPAD_EQUAL\",\n //\"106\" : \"NUMPAD_MULTIPLY\",\n //\"109\" : \"NUMPAD_SUBTRACT\"\n },\n onStateChanged = function (item, that) {\n if (item && item.onStateChanged) {\n item.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n if (that.state == \"changeValue\") {\n if (item && item.onChange) {\n item.onChange.call(that, that);\n }\n else if (this.onChange) {\n this.onChange.call(that, that);\n }\n }\n\n item = null;\n that = null;\n return true;\n },\n alignComboboxDisplay = function () {\n var i = this.queue.length, w;\n\n while (i--) {\n var item = this.queue[i];\n if (item.$display) {\n w = Math.max(item.$select.outerWidth(), U.number(item.minWidth));\n item.$display.css({\n \"min-width\": w\n });\n if (item.reset) {\n item.$display.find(\".addon-icon-reset\").css({\n \"line-height\": this.queue[i].$display.height() + \"px\"\n });\n }\n\n // 높이조절 처리\n if (item.multiple) {\n var displayTableHeightAdjust = (function () {\n return U.number(item.$display.css(\"border-top-width\")) + U.number(item.$display.css(\"border-bottom-width\"));\n }).call(this);\n item.$target.height('');\n item.$display.height('');\n\n var displayTableHeight = item.$displayTable.outerHeight();\n if (Math.abs(displayTableHeight - item.$target.height()) > displayTableHeightAdjust) {\n item.$target.css({height: displayTableHeight + displayTableHeightAdjust + 4});\n item.$display.css({height: displayTableHeight + displayTableHeightAdjust + 4});\n }\n }\n }\n }\n\n i = null;\n w = null;\n return this;\n },\n alignComboboxOptionGroup = function (append) {\n if (!this.activecomboboxOptionGroup) return this;\n\n var item = this.queue[this.activecomboboxQueueIndex],\n pos = {}, positionMargin = 0,\n dim = {}, pickerDim = {},\n pickerDirection;\n\n if (append) jQuery(document.body).append(this.activecomboboxOptionGroup);\n\n pos = item.$target.offset();\n dim = {\n width: item.$target.outerWidth(),\n height: item.$target.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), jQuery(document.body).width()),\n winHeight: Math.max($window.height(), jQuery(document.body).height()),\n width: this.activecomboboxOptionGroup.outerWidth(),\n height: this.activecomboboxOptionGroup.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n if (!item.direction || item.direction === \"\" || item.direction === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = item.direction;\n }\n\n if (append) {\n this.activecomboboxOptionGroup\n .addClass(\"direction-\" + pickerDirection);\n }\n this.activecomboboxOptionGroup\n .css((function () {\n if (pickerDirection == \"top\") {\n if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n\n var newTop = pos.top + dim.height / 2 - pickerDim.height / 2;\n if (newTop + pickerDim.height + positionMargin > pickerDim.winHeight) {\n newTop = 0;\n }\n if (newTop < 0) {\n newTop = 0;\n }\n\n return {\n left: pos.left,\n top: newTop,\n width: dim.width\n }\n }\n return {\n left: pos.left,\n top: pos.top + dim.height + 1,\n width: dim.width\n }\n }\n else if (pickerDirection == \"bottom\") {\n return {\n left: pos.left,\n top: pos.top - pickerDim.height - 1,\n width: dim.width\n }\n }\n }).call(this));\n },\n onBodyClick = function (e, target) {\n if (!this.activecomboboxOptionGroup) return this;\n\n var\n item = this.queue[this.activecomboboxQueueIndex],\n clickEl = \"display\"\n ;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-option-value\")) {\n clickEl = \"optionItem\";\n return true;\n }\n else if (item.$target.get(0) == target) {\n clickEl = \"display\";\n return true;\n }\n });\n\n if (!target) {\n this.close();\n return this;\n }\n else if (clickEl === \"optionItem\") {\n \n setOptionSelect.call(this, item.id, {\n index: {\n gindex: target.getAttribute(\"data-option-group-index\"),\n index: target.getAttribute(\"data-option-index\")\n }\n }, undefined, true);\n\n alignComboboxDisplay.call(this);\n alignComboboxOptionGroup.call(this);\n\n if (!item.multiple) {\n this.close();\n }\n }\n else {\n\n }\n\n return this;\n },\n\n getLabel = function (queIdx) {\n var item = this.queue[queIdx];\n\n // 템플릿에 전달 해야할 데이터 선언\n var data = {};\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5combobox-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n data.selected = item.selected;\n data.hasSelected = (data.selected && data.selected.length > 0);\n data.removeIcon = item.removeIcon;\n\n return COMBOBOX.tmpl.get.call(this, \"label\", data, item.columnKeys);\n },\n printLabel = function (queIdx) {\n var item = this.queue[queIdx];\n\n item.$displayLabel.find('[data-ax5combobox-selected-label]').remove();\n item.$displayLabelInput.before(getLabel.call(this, queIdx));\n },\n focusLabel = function (queIdx) {\n if (this.queue[queIdx].disabled) return this;\n\n this.queue[queIdx].$displayLabel.trigger(\"focus\");\n this.queue[queIdx].$displayLabelInput.focus();\n },\n clearLabel = function (queIdx) {\n this.queue[queIdx].$displayLabelInput.val('');\n },\n blurLabel = function (queIdx) {\n this.queue[queIdx].$displayLabel.trigger(\"blur\");\n this.queue[queIdx].$displayLabelInput.trigger(\"blur\");\n },\n onSearch = function (queIdx, searchWord) {\n this.queue[queIdx].waitOptions = true;\n\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(\n COMBOBOX.tmpl.get.call(this, \"option\", this.queue[queIdx], this.queue[queIdx].columnKeys)\n ));\n\n this.queue[queIdx].onSearch.call({\n self: this,\n item: this.queue[queIdx],\n searchWord: searchWord\n }, (function (O) {\n\n var data = {};\n var item = this.queue[this.activecomboboxQueueIndex];\n if (!item) return false;\n\n /// 현재 selected 검증후 처리\n (function (item, O) {\n var optionsMap = {};\n O.options.forEach(function (_O, _OIndex) {\n _O[\"@index\"] = _OIndex;\n optionsMap[_O[item.columnKeys.optionValue]] = _O;\n });\n if (U.isArray(item.selected)) {\n item.selected.forEach(function (_O) {\n if (optionsMap[_O[item.columnKeys.optionValue]]) {\n O.options[optionsMap[_O[item.columnKeys.optionValue]][\"@index\"]][item.columnKeys.optionSelected] = true;\n }\n });\n }\n })(item, O);\n\n item.options = syncComboboxOptions.call(this, this.activecomboboxQueueIndex, O.options);\n\n alignComboboxDisplay.call(this);\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5combobox-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(\n COMBOBOX.tmpl.get.call(this, \"options\", data, item.columnKeys)\n ));\n\n }).bind(this));\n },\n focusWord = function (queIdx, searchWord) {\n //console.log(searchWord);\n\n if (this.activecomboboxQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n var options = [], i = -1, l = this.queue[queIdx].indexedOptions.length - 1, n;\n\n if (searchWord != \"\") {\n var regExp = /[\\{\\}\\[\\]\\/?.,;:|\\)*~`!^\\-_+<>@\\#$%&\\\\\\=\\(\\'\\\"]/gi;\n searchWord = searchWord.replace(regExp, \"\");\n if (this.queue[queIdx].onSearch) {\n onSearch.call(this, queIdx, searchWord);\n\n try {\n return options;\n } finally {\n options = null;\n i = null;\n l = null;\n n = null;\n }\n // if there is a \"onSearch\", to end this process\n }\n\n while (l - i++) {\n n = this.queue[queIdx].indexedOptions[i];\n\n if (('' + n.text).toLowerCase() == searchWord.toLowerCase()) {\n options = [{'@findex': n['@findex'], optionsSort: 0}];\n break;\n } else {\n var sort = ('' + n.text).toLowerCase().search(searchWord.toLowerCase());\n if (sort > -1) {\n options.push({'@findex': n['@findex'], optionsSort: sort});\n if (options.length > 2) break;\n }\n sort = null;\n }\n }\n options.sort(function (a, b) {\n return a.optionsSort - b.optionsSort;\n });\n }\n\n if (options && options.length > 0) {\n focusMove.call(this, queIdx, undefined, options[0]['@findex']);\n } else {\n focusClear.call(this, queIdx);\n }\n\n try {\n return options;\n } finally {\n options = null;\n i = null;\n l = null;\n n = null;\n }\n },\n focusClear = function (queIdx) {\n if (this.activecomboboxOptionGroup) {\n this.activecomboboxOptionGroup\n .find('[data-option-focus-index]')\n .removeClass(\"hover\")\n .removeAttr(\"data-option-selected\");\n }\n\n this.queue[queIdx].optionFocusIndex = -1;\n },\n focusMove = function (queIdx, direction, findex) {\n var _focusIndex,\n _prevFocusIndex,\n focusOptionEl,\n optionGroupScrollContainer;\n var item = this.queue[queIdx];\n\n if (this.activecomboboxOptionGroup && item.options && item.options.length > 0) {\n\n if (typeof findex !== \"undefined\") {\n _focusIndex = findex\n }\n else {\n _prevFocusIndex = (item.optionFocusIndex == -1) ? item.optionSelectedIndex || -1 : item.optionFocusIndex;\n if (_prevFocusIndex == -1) {\n _focusIndex = 0;\n //_focusIndex = (direction > 0) ? 0 : item.optionItemLength - 1; // 맨 끝으로 보낼것인가 말 것인가.\n }\n else {\n _focusIndex = _prevFocusIndex + direction;\n if (_focusIndex < 0) _focusIndex = 0;\n else if (_focusIndex > item.optionItemLength - 1) _focusIndex = item.optionItemLength - 1;\n }\n }\n\n item.optionFocusIndex = _focusIndex;\n\n // 포커스 인덱스가 hide아이템을 만나면 hide 아이템이 안나올 때까지 루프를 순회 합니다.\n // todo : editable 로 추가된 options가 제거 되지 않으므로. 인덱스 검색을 좀 더 보강 해야함.\n if (item.options[_focusIndex] && item.options[_focusIndex].hide) { // 옵션이 없는 값이 선택된 경우\n if (typeof direction === \"undefined\") {\n return this;\n }\n else {\n var isStrop = false;\n while (item.options[_focusIndex].hide) {\n _focusIndex = _focusIndex + direction;\n if (_focusIndex < 0) {\n _focusIndex = 0;\n break;\n }\n else if (_focusIndex > item.optionItemLength - 1) {\n _focusIndex = item.optionItemLength - 1;\n break;\n }\n }\n }\n }\n\n if (typeof _focusIndex !== \"undefined\") {\n this.activecomboboxOptionGroup\n .find('[data-option-focus-index]')\n .removeClass(\"hover\");\n\n focusOptionEl = this.activecomboboxOptionGroup\n .find('[data-option-focus-index=\"' + _focusIndex + '\"]')\n .addClass(\"hover\");\n\n optionGroupScrollContainer = this.activecomboboxOptionGroup.find('[data-els=\"content\"]');\n\n if (focusOptionEl.get(0)) {\n let focusOptionElHeight = focusOptionEl.outerHeight(),\n optionGroupScrollContainerHeight = optionGroupScrollContainer.innerHeight(),\n optionGroupScrollContainerScrollTop = optionGroupScrollContainer.scrollTop(),\n focusOptionElTop = focusOptionEl.position().top + optionGroupScrollContainer.scrollTop();\n\n if (optionGroupScrollContainerHeight + optionGroupScrollContainerScrollTop < focusOptionElTop + focusOptionElHeight) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop + focusOptionElHeight - optionGroupScrollContainerHeight);\n }\n else if (optionGroupScrollContainerScrollTop > focusOptionElTop) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop);\n }\n // optionGroup scroll check\n\n if (typeof direction !== \"undefined\") {\n item.$displayLabelInput.val(item.options[_focusIndex].text);\n }\n }\n }\n }\n },\n syncComboboxOptions = (function () {\n var setSelected = function (queIdx, O) {\n if (!O) {\n this.queue[queIdx].selected = [];\n }\n else {\n this.queue[queIdx].selected.push(jQuery.extend({}, O));\n /*\n 콤보박스는 selected가 없을 때 options의 첫번째 아이템이 selected가 되지 않는다.\n if (this.queue[queIdx].multiple) this.queue[queIdx].selected.push(jQuery.extend({}, O));\n else this.queue[queIdx].selected[0] = jQuery.extend({}, O);\n */\n }\n };\n\n return function (queIdx, options) {\n var item = this.queue[queIdx];\n var po, elementOptions, newOptions, focusIndex = 0;\n setSelected.call(this, queIdx, false); // item.selected 초기화\n\n if (options) {\n item.options = options;\n item.indexedOptions = [];\n\n // combobox options 태그 생성\n po = [];\n po.push('');\n\n item.options.forEach(function (O, OIndex) {\n /// @gindex : index of optionGroup\n /// @index : index of options (if you use optionGroup then the index is not unique)\n if (O.optgroup) {\n O['@gindex'] = OIndex;\n O.options.forEach(function (OO, OOIndex) {\n OO['@index'] = OOIndex;\n OO['@findex'] = focusIndex;\n po.push('');\n if (OO[item.columnKeys.optionSelected]) {\n setSelected.call(self, queIdx, OO);\n }\n\n item.indexedOptions.push({\n '@gindex': OIndex,\n '@index': OOIndex,\n '@findex': focusIndex,\n value: OO[item.columnKeys.optionValue],\n text: OO[item.columnKeys.optionText]\n });\n focusIndex++;\n });\n }\n else {\n O['@index'] = OIndex;\n O['@findex'] = focusIndex;\n po.push('');\n if (O[item.columnKeys.optionSelected]) {\n setSelected.call(self, queIdx, O);\n }\n\n item.indexedOptions.push({\n '@index': OIndex,\n '@findex': focusIndex,\n value: O[item.columnKeys.optionValue],\n text: O[item.columnKeys.optionText]\n });\n focusIndex++;\n }\n });\n item.optionItemLength = focusIndex;\n item.$select.html(po.join(''));\n }\n else {\n /// select > options 태그로 스크립트 options를 만들어주는 역할\n if (item.$select.get(0).options && item.$select.get(0).options.length) item.$select.get(0).options[0].selected = false;\n elementOptions = U.toArray(item.$select.get(0).options);\n\n // select option 스크립트 생성\n newOptions = [];\n elementOptions.forEach(function (O, OIndex) {\n var option = {};\n option[item.columnKeys.optionValue] = O.value;\n option[item.columnKeys.optionText] = O.text;\n option[item.columnKeys.optionSelected] = O.selected;\n option['@index'] = OIndex;\n option['@findex'] = focusIndex;\n if (O.selected) setSelected.call(self, queIdx, option);\n newOptions.push(option);\n focusIndex++;\n\n option = null;\n });\n item.options = newOptions;\n item.indexedOptions = newOptions;\n\n item.$select.prepend('');\n item.$select.get(0).options[0].selected = true;\n }\n\n po = null;\n elementOptions = null;\n newOptions = null;\n return item.options;\n }\n })(),\n getQueIdx = function (boundID) {\n if (boundID instanceof jQuery) {\n boundID = boundID.data(\"data-ax5combobox-id\");\n } else if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-ax5combobox-id\");\n }\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"getQueIdx\"));\n return;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n },\n getSelected = function (_item, o, selected) {\n if (typeof selected === \"undefined\") {\n return (_item.multiple) ? !o : true;\n } else {\n return selected;\n }\n },\n clearSelected = function (queIdx) {\n this.queue[queIdx].options.forEach(function (n) {\n if (n.optgroup) {\n n.options.forEach(function (nn) {\n nn.selected = false;\n });\n }\n else {\n n.selected = false;\n }\n });\n },\n setOptionSelect = (function () {\n var processor = {\n 'index': function (queIdx, value, selected, setValueType) {\n // 클래스 내부에서 호출된 형태, 그런 이유로 옵션그룹에 대한 상태를 변경 하고 있다.\n var item = this.queue[queIdx];\n\n if (U.isString(value.index.gindex)) {\n if (typeof item.options[value.index.gindex] !== \"undefined\") {\n\n item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected] = getSelected(item, item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected], selected);\n\n if (self.activecomboboxOptionGroup) {\n self.activecomboboxOptionGroup\n .find('[data-option-group-index=\"' + value.index.gindex + '\"][data-option-index=\"' + value.index.index + '\"]')\n .attr(\"data-option-Selected\", item.options[value.index.gindex].options[value.index.index][item.columnKeys.optionSelected].toString());\n }\n }\n }\n else {\n if (typeof item.options[value.index.index] !== \"undefined\") {\n\n item.options[value.index.index][item.columnKeys.optionSelected] =\n getSelected(item, item.options[value.index.index][item.columnKeys.optionSelected], selected);\n\n if (self.activecomboboxOptionGroup) {\n self.activecomboboxOptionGroup\n .find('[data-option-index=\"' + value.index.index + '\"]')\n .attr(\"data-option-Selected\", item.options[value.index.index][item.columnKeys.optionSelected].toString());\n }\n }\n }\n\n if (typeof setValueType === \"undefined\" || setValueType !== \"justSetValue\") {\n syncComboboxOptions.call(this, queIdx, item.options);\n alignComboboxOptionGroup.call(this);\n }\n },\n 'arr': function (queIdx, values, selected, setValueType) {\n values.forEach(function (value) {\n if (U.isString(value) || U.isNumber(value)) {\n processor.text.call(self, queIdx, value, selected, \"justSetValue\");\n }\n else {\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(self, queIdx, value, selected, \"justSetValue\");\n break;\n }\n }\n }\n });\n\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n alignComboboxOptionGroup.call(this);\n },\n 'value': function (queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx];\n var addOptions;\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionValue] == value[item.columnKeys.optionValue];\n });\n\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected]\n = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n }\n else {\n // 새로운 값 추가\n optionIndex = item.options.length;\n addOptions = {\n \"@index\": optionIndex,\n hide: true,\n addedOption: true\n };\n addOptions[item.columnKeys.optionValue] = value;\n addOptions[item.columnKeys.optionText] = value;\n item.options.push(addOptions);\n item.options[optionIndex][item.columnKeys.optionSelected]\n = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n }\n if (typeof setValueType === \"undefined\" || setValueType !== \"justSetValue\") {\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n alignComboboxOptionGroup.call(this);\n }\n },\n 'text': function (queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx];\n var addOptions;\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionText] == value;\n });\n\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected]\n = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n }\n else {\n // 새로운 값 추가\n optionIndex = item.options.length;\n addOptions = {\n \"@index\": optionIndex,\n hide: true,\n addedOption: true\n };\n addOptions[item.columnKeys.optionValue] = value;\n addOptions[item.columnKeys.optionText] = value;\n item.options.push(addOptions);\n item.options[optionIndex][item.columnKeys.optionSelected]\n = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n }\n if (typeof setValueType === \"undefined\" || setValueType !== \"justSetValue\") {\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n alignComboboxOptionGroup.call(this);\n }\n },\n 'clear': function (queIdx) {\n clearSelected.call(this, queIdx);\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n //focusLabel.call(this, queIdx);\n focusClear.call(this, queIdx);\n\n if (this.activecomboboxOptionGroup) {\n this.activecomboboxOptionGroup\n .find('[data-option-index]')\n .attr(\"data-option-Selected\", \"false\");\n }\n this.queue[queIdx].optionSelectedIndex = -1;\n }\n };\n return function (boundID, value, selected, _option) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n\n if (typeof value == \"undefined\") {\n throw \"error not found value\";\n }\n else if (U.isArray(value)) {\n processor.clear.call(this, queIdx);\n processor.arr.call(this, queIdx, (this.queue[queIdx].multiple || value.length == 0) ? value : [value[value.length - 1]], selected);\n }\n else if (U.isString(value) || U.isNumber(value)) {\n if (typeof value !== \"undefined\" && value !== null && !this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n processor.text.call(this, queIdx, value, selected, \"justSetValue\");\n }\n else {\n if (value === null) {\n processor.clear.call(this, queIdx);\n }\n else {\n if (!this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(this, queIdx, value, selected, \"justSetValue\");\n break;\n }\n }\n }\n }\n\n syncComboboxOptions.call(this, queIdx, this.queue[queIdx].options);\n printLabel.call(this, queIdx);\n focusLabel.call(this, queIdx);\n\n if (typeof value !== \"undefined\") {\n if (_option && (!_option.noStateChange)) {\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n item: this.queue[queIdx],\n state: \"changeValue\",\n value: this.queue[queIdx].selected\n });\n }\n }\n\n boundID = null;\n return this;\n };\n })();\n\n /// private end\n\n /**\n * Preferences of combobox UI\n * @method ax5combobox.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5combobox}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onChange = cfg.onChange;\n jQuery(window).bind(\"resize.ax5combobox-display-\" + this.instanceId, (function () {\n alignComboboxDisplay.call(this);\n }).bind(this));\n };\n\n /**\n * bind combobox\n * @method ax5combobox.bind\n * @param {Object} item\n * @param {String} [item.id]\n * @param {String} [item.theme]\n * @param {Boolean} [item.multiple]\n * @param {Element} item.target\n * @param {Object[]} item.options\n * @returns {ax5combobox}\n */\n this.bind = function (item) {\n var bindComboboxTarget = (function () {\n var debouncedFocusWord = U.debounce(function (queIdx) {\n if (this.activecomboboxQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n focusWord.call(self, queIdx, this.queue[queIdx].$displayLabelInput.val());\n }, 150);\n\n var blurLabel = function (queIdx) {\n clearLabel.call(this, queIdx);\n };\n\n var comboboxEvent = {\n 'click': function (queIdx, e) {\n var clickEl;\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-ax5combobox-remove\")) {\n clickEl = \"optionItemRemove\";\n return true;\n }\n else if (target.getAttribute(\"data-selected-clear\")) {\n clickEl = \"clear\";\n return true;\n }\n });\n\n if (target) {\n if (clickEl === \"optionItemRemove\") {\n var selectedIndex = target.getAttribute(\"data-ax5combobox-remove-index\");\n var option = this.queue[queIdx].selected[selectedIndex];\n setOptionSelect.call(this, queIdx, {\n index: {\n gindex: option['@gindex'],\n index: option['@index']\n }\n }, false, true);\n alignComboboxDisplay.call(this);\n alignComboboxOptionGroup.call(this);\n focusLabel.call(this, queIdx);\n U.stopEvent(e);\n return this;\n } else if (clickEl === \"clear\") {\n setOptionSelect.call(this, queIdx, {clear: true});\n alignComboboxDisplay.call(this);\n alignComboboxOptionGroup.call(this);\n focusLabel.call(this, queIdx);\n }\n }\n else {\n if (self.activecomboboxQueueIndex == queIdx) {\n if (this.queue[queIdx].optionFocusIndex == -1) { // 아이템에 포커스가 활성화 된 후, 마우스 이벤트 이면 무시\n self.close();\n }\n }\n else {\n self.open(queIdx);\n focusLabel.call(this, queIdx);\n }\n }\n },\n 'keyUp': function (queIdx, e) {\n /// 약속된 키 이벤트가 발생하면 stopEvent를 통해 keyUp 이벤트가 발생되지 않도록 막아주는 센스\n if (e.which == ax5.info.eventKeys.ESC && self.activecomboboxQueueIndex === -1) { // ESC키를 누르고 옵션그룹이 열려있지 않은 경우\n U.stopEvent(e);\n return this;\n }\n if (self.activecomboboxQueueIndex != queIdx) { // 닫힌 상태 인경우\n self.open(queIdx);\n U.stopEvent(e);\n }\n\n var disableCtrlKeys = {\n \"40\": \"KEY_DOWN\",\n \"38\": \"KEY_UP\"\n };\n if (!disableCtrlKeys[e.which]) {\n\n // backspace 감지 하여 input 값이 없으면 스탑이벤트 처리 할 것\n if (e.which == ax5.info.eventKeys.BACKSPACE && this.queue[queIdx].$displayLabelInput.val() == \"\") {\n // 마지막 아이템을 제거.\n if(this.queue[queIdx].selected.length > 0) {\n var option = this.queue[queIdx].selected[this.queue[queIdx].selected.length - 1];\n setOptionSelect.call(this, queIdx, {\n index: {\n gindex: option['@gindex'],\n index: option['@index']\n }\n }, false, true);\n }\n alignComboboxDisplay.call(this);\n alignComboboxOptionGroup.call(this);\n U.stopEvent(e);\n } else {\n debouncedFocusWord.call(this, queIdx);\n }\n }\n },\n 'keyDown': function (queIdx, e) {\n if (e.which == ax5.info.eventKeys.ESC) {\n clearLabel.call(this, queIdx);\n this.close();\n U.stopEvent(e);\n }\n else if (e.which == ax5.info.eventKeys.RETURN) {\n\n setOptionSelect.call(this, item.id, {\n index: {\n gindex: item.indexedOptions[item.optionFocusIndex][\"@gindex\"],\n index: item.indexedOptions[item.optionFocusIndex][\"@index\"]\n }\n }, undefined, true);\n clearLabel.call(this, queIdx);\n alignComboboxDisplay.call(this);\n\n this.close();\n //alignComboboxOptionGroup.call(this);\n\n U.stopEvent(e);\n }\n else if (e.which == ax5.info.eventKeys.DOWN) {\n focusMove.call(this, queIdx, 1);\n U.stopEvent(e);\n }\n else if (e.which == ax5.info.eventKeys.UP) {\n focusMove.call(this, queIdx, -1);\n U.stopEvent(e);\n }\n },\n 'focus': function (queIdx, e) {\n //console.log(e);\n },\n 'blur': function (queIdx, e) {\n blurLabel.call(this, queIdx);\n U.stopEvent(e);\n },\n 'selectChange': function (queIdx, e) {\n setOptionSelect.call(this, queIdx, {value: this.queue[queIdx].$select.val()}, true);\n }\n };\n\n return function (queIdx) {\n var item = this.queue[queIdx];\n var data = {};\n // 현재 선택된 값을 담아두는 저장소, syncComboboxOptions를 통해 options와 selected값을 동기화 처리 한다.\n item.selected = [];\n\n if (!item.$display) {\n /// 템플릿에 전달할 오브젝트 선언\n data.instanceId = this.instanceId;\n data.id = item.id;\n data.name = item.name;\n data.theme = item.theme;\n data.tabIndex = item.tabIndex;\n data.multiple = item.multiple;\n data.reset = item.reset;\n\n data.label = getLabel.call(this, queIdx);\n data.formSize = (function () {\n return (item.size) ? \"input-\" + item.size : \"\";\n })();\n\n //item.$display = jQuery(ax5.mustache.render(COMBOBOX.tmpl[\"comboboxDisplay\"].call(this, queIdx), data));\n item.$display = jQuery(COMBOBOX.tmpl.get.call(this, \"comboboxDisplay\", data, item.columnKeys));\n item.$displayTable = item.$display.find('[data-els=\"display-table\"]');\n item.$displayLabel = item.$display.find('[data-ax5combobox-display=\"label\"]');\n item.$displayLabelInput = item.$display.find('[data-ax5combobox-display=\"input\"]');\n\n\n if (item.$target.find(\"select\").get(0)) {\n item.$select = item.$target.find(\"select\");\n item.$select\n .attr(\"tabindex\", \"-1\")\n .attr(\"class\", \"form-control \" + data.formSize);\n if (data.name) {\n item.$select.attr(\"name\", \"name\");\n }\n if (data.multiple) {\n item.$select.attr(\"multiple\", \"multiple\");\n }\n }\n else {\n //item.$select = jQuery(ax5.mustache.render(COMBOBOX.tmpl[\"formSelect\"].call(this, queIdx), data));\n item.$select = jQuery(COMBOBOX.tmpl.get.call(this, \"formSelect\", data, item.columnKeys));\n item.$target.append(item.$select);\n }\n\n item.$target.append(item.$display);\n // 라벨에 사용자 입력 필드가 있으므로 displayInput은 필요 없음.\n // select.options로 item.options를 만들어내거나 item.options로 select.options를 만들어냄\n item.options = syncComboboxOptions.call(this, queIdx, item.options);\n }\n else {\n item.$displayLabel\n .html(getLabel.call(this, queIdx));\n item.options = syncComboboxOptions.call(this, queIdx, item.options);\n }\n\n\n alignComboboxDisplay.call(this);\n\n item.$display\n .unbind('click.ax5combobox')\n .bind('click.ax5combobox', comboboxEvent.click.bind(this, queIdx));\n\n // combobox 태그에 대한 이벤트 감시\n\n\n item.$displayLabelInput\n .unbind(\"focus.ax5combobox\")\n .bind(\"focus.ax5combobox\", comboboxEvent.focus.bind(this, queIdx))\n .unbind(\"blur.ax5combobox\")\n .bind(\"blur.ax5combobox\", comboboxEvent.blur.bind(this, queIdx))\n .unbind('keyup.ax5combobox')\n .bind('keyup.ax5combobox', comboboxEvent.keyUp.bind(this, queIdx))\n .unbind(\"keydown.ax5combobox\")\n .bind(\"keydown.ax5combobox\", comboboxEvent.keyDown.bind(this, queIdx));\n\n // select 태그에 대한 change 이벤트 감시\n\n item.$select\n .unbind('change.ax5combobox')\n .bind('change.ax5combobox', comboboxEvent.selectChange.bind(this, queIdx));\n\n data = null;\n item = null;\n queIdx = null;\n return this;\n };\n })();\n\n var\n comboboxConfig = {},\n queIdx;\n\n item = jQuery.extend(true, comboboxConfig, cfg, item);\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5combobox\", \"401\", \"bind\"));\n return this;\n }\n\n item.$target = jQuery(item.target);\n\n if (!item.id) item.id = item.$target.data(\"data-ax5combobox-id\");\n if (!item.id) {\n item.id = 'ax5combobox-' + ax5.getGuid();\n item.$target.data(\"data-ax5combobox-id\", item.id);\n }\n item.name = item.$target.attr(\"data-ax5combobox\");\n if (item.options) {\n item.options = JSON.parse(JSON.stringify(item.options));\n }\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n item = jQuery.extend(true, item, data);\n }\n })(U.parseJson(item.$target.attr(\"data-ax5combobox-config\"), true));\n\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindComboboxTarget.call(this, this.queue.length - 1);\n }\n else {\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindComboboxTarget.call(this, queIdx);\n }\n\n comboboxConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * open the optionBox of combobox\n * @method ax5combobox.open\n * @param {(String|Number|Element)} boundID\n * @param {Number} [tryCount]\n * @returns {ax5combobox}\n */\n this.open = (function () {\n var onExpand = function (item) {\n item.onExpand.call({\n self: this,\n item: item\n }, (function (O) {\n if (this.waitOptionsCallback) {\n var data = {};\n var item = this.queue[this.activecomboboxQueueIndex];\n\n /// 현재 selected 검증후 처리\n (function (item, O) {\n var optionsMap = {};\n O.options.forEach(function (_O, _OIndex) {\n _O[\"@index\"] = _OIndex;\n optionsMap[_O[item.columnKeys.optionValue]] = _O;\n });\n if (U.isArray(item.selected)) {\n item.selected.forEach(function (_O) {\n if (optionsMap[_O[item.columnKeys.optionValue]]) {\n O.options[optionsMap[_O[item.columnKeys.optionValue]][\"@index\"]][item.columnKeys.optionSelected] = true;\n }\n });\n }\n })(item, O);\n\n item.options = syncComboboxOptions.call(this, this.activecomboboxQueueIndex, O.options);\n printLabel.call(this, this.activecomboboxQueueIndex);\n alignComboboxDisplay.call(this);\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5combobox-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n /*\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(\n ax5.mustache.render(COMBOBOX.tmpl[\"options\"].call(this, item.columnKeys), data)\n ));\n */\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(\n COMBOBOX.tmpl.get.call(this, \"options\", data, item.columnKeys)\n ));\n }\n }).bind(this));\n };\n return function (boundID, tryCount) {\n this.waitOptionsCallback = null;\n\n /**\n * open combobox from the outside\n */\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n var data = {}, focusTop, selectedOptionEl;\n\n if (item.$display.attr(\"disabled\")) return this;\n\n if (this.openTimer) clearTimeout(this.openTimer);\n if (this.activecomboboxOptionGroup) {\n if (this.activecomboboxQueueIndex == queIdx) {\n return this;\n }\n\n if (tryCount > 2) return this;\n this.close();\n this.openTimer = setTimeout((function () {\n this.open(queIdx, (tryCount || 0) + 1);\n }).bind(this), cfg.animateTime);\n\n return this;\n }\n\n item.optionFocusIndex = -1; // optionGroup이 열리면 포커스 인덱스 초기화 -1로\n if (item.selected && item.selected.length > 0) {\n item.optionSelectedIndex = item.selected[0][\"@findex\"];\n }\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5combobox-option-group-\" + item.size;\n data.multiple = item.multiple;\n\n data.lang = item.lang;\n item.$display.attr(\"data-combobox-option-group-opened\", \"true\");\n\n if (item.onExpand) {\n // onExpand 인 경우 UI 대기모드 추가\n data.waitOptions = true;\n }\n data.options = U.filter(item.options, function () {\n return !this.hide;\n });\n\n //this.activecomboboxOptionGroup = jQuery(ax5.mustache.render(COMBOBOX.tmpl[\"optionGroup\"].call(this, item.columnKeys), data));\n this.activecomboboxOptionGroup = jQuery(COMBOBOX.tmpl.get.call(this, \"optionGroup\", data, item.columnKeys));\n //this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(ax5.mustache.render(COMBOBOX.tmpl[\"options\"].call(this, item.columnKeys), data)));\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]').html(jQuery(\n COMBOBOX.tmpl.get.call(this, \"options\", data, item.columnKeys)\n ));\n this.activecomboboxQueueIndex = queIdx;\n\n alignComboboxOptionGroup.call(this, \"append\"); // alignComboboxOptionGroup 에서 body append\n jQuery(window).bind(\"resize.ax5combobox-\" + this.instanceId, (function () {\n alignComboboxOptionGroup.call(this);\n }).bind(this));\n\n if (item.selected && item.selected.length > 0) {\n selectedOptionEl = this.activecomboboxOptionGroup.find('[data-option-index=\"' + item.selected[0][\"@index\"] + '\"]');\n if (selectedOptionEl.get(0)) {\n focusTop = selectedOptionEl.position().top - this.activecomboboxOptionGroup.height() / 3;\n this.activecomboboxOptionGroup.find('[data-els=\"content\"]')\n .stop().animate({scrollTop: focusTop}, item.animateTime, 'swing', function () {\n });\n }\n }\n\n jQuery(window).bind(\"click.ax5combobox-\" + this.instanceId, (function (e) {\n e = e || window.event;\n onBodyClick.call(this, e);\n U.stopEvent(e);\n }).bind(this));\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"open\",\n item: item\n });\n\n // waitOption timer\n if (item.onExpand) {\n this.waitOptionsCallback = true;\n onExpand.call(this, item);\n }\n\n data = null;\n focusTop = null;\n selectedOptionEl = null;\n return this;\n }\n })();\n\n /**\n * @method ax5combobox.update\n * @param {(Object|String)} item\n * @returns {ax5combobox}\n */\n this.update = function (_item) {\n this.bind(_item);\n return this;\n };\n\n /**\n * @method ax5combobox.setValue\n * @param {(jQueryObject|Element|Number)} _boundID\n * @param {(String|Array)} _value\n * @param {Boolean} [_selected]\n * @return {ax5combobox}\n * @example\n * ```js\n * myCombo.setValue($('[data-ax5combobox=\"combo1\"]'), \"1\");\n * myCombo.setValue($('[data-ax5combobox=\"combo1\"]'), [\"1\", \"2\"]);\n * ```\n */\n this.setValue = function (_boundID, _value, _selected) {\n var queIdx = (U.isNumber(_boundID)) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n\n clearSelected.call(this, queIdx);\n\n if (U.isArray(_value)) {\n var _values = U.map(_value, function () {\n return {value: this};\n });\n setOptionSelect.call(this, queIdx, _values, _selected || true, {noStateChange: true});\n }\n else if (U.isString(_value) || U.isNumber(_value)) {\n setOptionSelect.call(this, queIdx, {value: _value}, _selected || true, {noStateChange: true});\n } else {\n printLabel.call(this, queIdx);\n }\n\n blurLabel.call(this, queIdx);\n alignComboboxDisplay.call(this);\n\n return this;\n };\n\n /**\n * @method ax5combobox.setText\n * @param {(jQueryObject|Element|Number)} _boundID\n * @param {(String|Array)} _text\n * @param {Boolean} [_selected]\n * @returns {ax5combobox}\n * @example\n * ```js\n * myCombo.setText($('[data-ax5combobox=\"combo1\"]'), \"string\");\n * myCombo.setText($('[data-ax5combobox=\"combo1\"]'), [\"substring\", \"search\"]);\n * ```\n */\n this.setText = function (_boundID, _text, _selected) {\n var queIdx = (U.isNumber(_boundID)) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n clearSelected.call(this, queIdx);\n setOptionSelect.call(this, queIdx, _text, true, {noStateChange: true});\n blurLabel.call(this, queIdx);\n alignComboboxDisplay.call(this);\n\n return this;\n };\n\n /**\n * @method ax5combobox.getSelectedOption\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {Array}\n */\n this.getSelectedOption = function (_boundID) {\n var queIdx = (U.isNumber(_boundID)) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n return U.deepCopy(this.queue[queIdx].selected);\n };\n\n /**\n * @method ax5combobox.close\n * @returns {ax5combobox}\n */\n this.close = function (item) {\n if (this.closeTimer) clearTimeout(this.closeTimer);\n if (!this.activecomboboxOptionGroup) return this;\n\n item = this.queue[this.activecomboboxQueueIndex];\n item.optionFocusIndex = -1;\n item.$display.removeAttr(\"data-combobox-option-group-opened\").trigger(\"focus\");\n item.$displayLabel.attr(\"contentEditable\", \"false\");\n\n this.activecomboboxOptionGroup.addClass(\"destroy\");\n\n\n jQuery(window)\n .unbind(\"resize.ax5combobox-\" + this.instanceId)\n .unbind(\"click.ax5combobox-\" + this.instanceId)\n .unbind(\"keyup.ax5combobox-\" + this.instanceId);\n\n this.closeTimer = setTimeout((function () {\n if (this.activecomboboxOptionGroup) this.activecomboboxOptionGroup.remove();\n this.activecomboboxOptionGroup = null;\n this.activecomboboxQueueIndex = -1;\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"close\"\n });\n\n }).bind(this), cfg.animateTime);\n this.waitOptionsCallback = null;\n return this;\n };\n\n /**\n * @method ax5combobox.blur\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5combobox}\n */\n this.blur = function (_boundID) {\n var queIdx = (U.isNumber(_boundID)) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5combobox\", \"402\", \"val\"));\n return;\n }\n\n blurLabel.call(this, queIdx);\n return this;\n };\n\n /**\n * @method ax5combobox.enable\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5combobox}\n */\n this.enable = function (_boundID) {\n var queIdx = getQueIdx.call(this, _boundID);\n\n if (typeof queIdx !== \"undefined\") {\n this.queue[queIdx].disabled = false;\n if (this.queue[queIdx].$display[0]) {\n this.queue[queIdx].$display.removeAttr(\"disabled\");\n this.queue[queIdx].$displayLabelInput.removeAttr(\"disabled\");\n }\n if (this.queue[queIdx].$select[0]) {\n this.queue[queIdx].$select.removeAttr(\"disabled\");\n }\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"enable\"\n });\n }\n\n return this;\n };\n\n /**\n * @method ax5combobox.disable\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5combobox}\n */\n this.disable = function (_boundID) {\n var queIdx = getQueIdx.call(this, _boundID);\n\n if (typeof queIdx !== \"undefined\") {\n this.queue[queIdx].disabled = true;\n if (this.queue[queIdx].$display[0]) {\n this.queue[queIdx].$display.attr(\"disabled\", \"disabled\");\n this.queue[queIdx].$displayLabelInput.attr(\"disabled\", \"disabled\");\n }\n if (this.queue[queIdx].$select[0]) {\n this.queue[queIdx].$select.attr(\"disabled\", \"disabled\");\n }\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"disable\"\n });\n }\n return this;\n };\n\n /**\n * @method ax5combobox.align\n */\n this.align = function () {\n alignComboboxDisplay.call(this);\n return this;\n };\n\n // 클래스 생성자\n this.main = (function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n else {\n this.init();\n }\n }).apply(this, arguments);\n };\n return ax5combobox;\n })());\n\n COMBOBOX = ax5.ui.combobox;\n})();\n\n/**\n * ax5combobox jquery extends\n * @namespace jQueryExtends\n */\n\n/**\n * @method jQueryExtends.ax5combobox\n * @param {String} methodName\n * @param [arguments]\n * @param [arguments]\n * @example\n * ```html\n * \n * \n * ```\n */\n\nax5.ui.combobox_instance = new ax5.ui.combobox();\njQuery.fn.ax5combobox = (function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"open\":\n return ax5.ui.combobox_instance.open(this);\n break;\n case \"close\":\n return ax5.ui.combobox_instance.close(this);\n break;\n case \"setValue\":\n return ax5.ui.combobox_instance.setValue(this, arguments[1], arguments[2], arguments[3], arguments[4] || \"justSetValue\");\n break;\n case \"setText\":\n return ax5.ui.combobox_instance.setText(this, arguments[1], arguments[2], arguments[3], arguments[4] || \"justSetValue\");\n break;\n case \"getSelectedOption\":\n return ax5.ui.combobox_instance.getSelectedOption(this);\n break;\n case \"enable\":\n return ax5.ui.combobox_instance.enable(this);\n break;\n case \"disable\":\n return ax5.ui.combobox_instance.disable(this);\n break;\n case \"blur\":\n return ax5.ui.combobox_instance.blur(this);\n default:\n return this;\n }\n }\n else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.combobox_instance.bind(config);\n });\n }\n return this;\n }\n})();\n","// ax5.ui.combobox.tmpl\n(function () {\n\n var COMBOBOX = ax5.ui.combobox;\n var U = ax5.util;\n\n var optionGroup = function (columnKeys) {\n return `\n \n `;\n };\n\n var comboboxDisplay = function (columnKeys) {\n return `\n\n `;\n };\n\n var formSelect = function (columnKeys) {\n return `\n \n `;\n };\n\n var formSelectOptions = function (columnKeys) {\n return `\n{{#selected}}\n\n{{/selected}}\n`;\n };\n\n var options = function (columnKeys) {\n return `\n {{#waitOptions}}\n \n
\n \n {{{lang.loading}}}\n \n
\n
\n {{/waitOptions}}\n {{^waitOptions}}\n {{#options}}\n {{#optgroup}}\n \n
\n \n {{{.}}}\n \n
\n {{#options}}\n {{^hide}}\n
\n
\n {{#multiple}}\n \n \n \n {{/multiple}}\n {{${columnKeys.optionText}}}\n
\n
\n {{/hide}}\n {{/options}}\n
\n {{/optgroup}}\n {{^optgroup}}\n {{^hide}}\n \n
\n {{#multiple}}\n \n \n \n {{/multiple}}\n {{${columnKeys.optionText}}}\n
\n
\n {{/hide}}\n {{/optgroup}}\n {{/options}}\n {{^options}}\n \n
\n \n {{{lang.noOptions}}}\n \n
\n
\n {{/options}}\n {{/waitOptions}}\n `;\n };\n\n var label = function (columnKeys) {\n return `{{#selected}}{{/selected}}`;\n };\n\n COMBOBOX.tmpl = {\n \"comboboxDisplay\": comboboxDisplay,\n \"formSelect\": formSelect,\n \"formSelectOptions\": formSelectOptions,\n \"optionGroup\": optionGroup,\n \"options\": options,\n \"label\": label,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(COMBOBOX.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();","/*\n * Copyright (c) 2016. tom@axisj.com\n * - github.com/thomasjang\n * - www.axisj.com\n */\n\n// ax5.ui.combobox.util\n(function () {\n\n var COMBOBOX = ax5.ui.combobox;\n var U = ax5.util;\n\n var nodeTypeProcessor = {\n '1': function (queIdx, node, editable) {\n var cfg = this.config;\n var textNode = node;\n\n if ($(node).find(\"span\").get(0)) {\n textNode = $(node).find(\"span\").get(0);\n }\n\n var text = (textNode.textContent || textNode.innerText).replace(/^[\\s\\r\\n\\t]*|[\\s\\r\\n\\t]*$/g, '');\n var item = this.queue[queIdx];\n\n var selectedIndex, option;\n if (item.selected && item.selected.length > 0 && node.getAttribute(\"data-ax5combobox-selected-text\") == text) {\n selectedIndex = node.getAttribute(\"data-ax5combobox-selected-label\");\n option = item.selected[selectedIndex];\n return {\n index: {\n gindex: option[\"@gindex\"],\n index: option[\"@index\"],\n value: option[cfg.columnKeys.optionValue]\n }\n };\n }\n else if (!node.getAttribute(\"data-ax5combobox-selected-text\")) {\n if (text != \"\") {\n if (editable) {\n return text;\n } else {\n var $option;\n if (item.optionFocusIndex > -1) $option = this.activecomboboxOptionGroup.find('[data-option-focus-index=\"' + item.optionFocusIndex + '\"]');\n if (item.optionFocusIndex > -1 && $option.get(0) && $option.attr(\"data-option-value\")) {\n return {\n index: {\n gindex: $option.attr(\"data-option-group-index\"),\n index: $option.attr(\"data-option-index\")\n }\n }\n } else {\n return (item.editable) ? text : undefined;\n }\n }\n } else {\n return undefined;\n }\n }\n else {\n return text;\n }\n },\n '3': function (queIdx, node, editable) {\n var cfg = this.config;\n var text = (node.textContent || node.innerText).replace(/^[\\s\\r\\n\\t]*|[\\s\\r\\n\\t]*$/g, '');\n var item = this.queue[queIdx];\n\n if (text != \"\") {\n if (editable) {\n return text;\n } else {\n var $option;\n if (item.optionFocusIndex > -1) $option = this.activecomboboxOptionGroup.find('[data-option-focus-index=\"' + item.optionFocusIndex + '\"]');\n if (item.optionFocusIndex > -1 && $option.get(0) && $option.attr(\"data-option-value\")) {\n return {\n index: {\n gindex: $option.attr(\"data-option-group-index\"),\n index: $option.attr(\"data-option-index\")\n }\n }\n } else {\n return (item.editable) ? text : undefined;\n }\n }\n } else {\n return undefined;\n }\n }\n };\n\n COMBOBOX.util = {\n nodeTypeProcessor: nodeTypeProcessor\n };\n})();","// ax5.ui.layout\n(function () {\n var UI = ax5.ui;\n var U = ax5.util;\n\n UI.addClass({\n className: \"layout\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5layout\n * @alias ax5.ui.layout\n * @author tom@axisj.com\n * @example\n * ```js\n * jQuery('[data-ax5layout=\"ax1\"]').ax5layout({\n * onResize: function () {\n * }\n * });\n *\n * jQuery('[data-ax5layout=\"ax1\"]').ax5layout(\"resize\", {\n * top: {height: 100},\n * bottom: 100,\n * left: 100,\n * right: 100\n * });\n * ```\n */\n var ax5layout = function () {\n var self = this,\n cfg,\n ENM = {\n \"mousedown\": (ax5.info.supportTouch) ? \"touchstart\" : \"mousedown\",\n \"mousemove\": (ax5.info.supportTouch) ? \"touchmove\" : \"mousemove\",\n \"mouseup\": (ax5.info.supportTouch) ? \"touchend\" : \"mouseup\"\n },\n getMousePosition = function (e) {\n var mouseObj = ('changedTouches' in e.originalEvent) ? e.originalEvent.changedTouches[0] : e;\n return {\n clientX: mouseObj.clientX,\n clientY: mouseObj.clientY\n }\n };\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 250,\n splitter: {\n size: 4\n },\n autoResize: true\n };\n this.queue = [];\n\n this.openTimer = null;\n this.closeTimer = null;\n this.resizer = null;\n\n cfg = this.config;\n\n var\n onStateChanged = function (opts, that) {\n if (opts && opts.onStateChanged) {\n opts.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n return true;\n },\n alignLayoutAll = function () {\n var i = this.queue.length;\n while (i--) {\n if (typeof this.queue[i].parentQueIdx === \"undefined\" && this.queue[i].autoResize) {\n alignLayout.call(this, i, null, \"windowResize\");\n }\n }\n },\n getDockPanelOuterSize = {\n \"width\": function (item, panel) {\n return (panel ? panel.__width + ((panel.split) ? item.splitter.size : 0) : 0);\n },\n \"height\": function (item, panel) {\n return (panel ? panel.__height + ((panel.split) ? item.splitter.size : 0) : 0);\n }\n },\n getPixel = function (size, parentSize) {\n if (size == \"*\") {\n return;\n }\n else if (U.right(size, 1) == \"%\") {\n return parentSize * U.number(size) / 100;\n }\n else {\n return Number(size);\n }\n },\n alignLayout = (function () {\n\n var beforeSetCSS = {\n \"split\": {\n \"horizontal\": function (item, panel, panelIndex) {\n if (panel.splitter) {\n panel.__height = item.splitter.size;\n }\n else {\n if (panelIndex == item.splitPanel.length - 1) {\n if (item.splitPanel.asteriskLength == 0) {\n panel.height = \"*\";\n panel.__height = undefined;\n item.splitPanel.asteriskLength++;\n }\n else {\n if (panel.height == \"*\") {\n item.splitPanel.asteriskLength++;\n } else {\n //panel.__height = getPixel(panel.height, item.targetDimension.height);\n }\n }\n }\n else {\n if (panel.height == \"*\") {\n item.splitPanel.asteriskLength++;\n } else {\n //panel.__height = getPixel(panel.height, item.targetDimension.height);\n }\n }\n }\n },\n \"vertical\": function (item, panel, panelIndex) {\n if (panel.splitter) {\n panel.__width = item.splitter.size;\n }\n else {\n if (panelIndex == item.splitPanel.length - 1) {\n if (item.splitPanel.asteriskLength == 0) {\n panel.width = \"*\";\n panel.__width = undefined;\n item.splitPanel.asteriskLength++;\n } else {\n if (panel.width == \"*\") {\n item.splitPanel.asteriskLength++;\n }\n }\n }\n else {\n if (panel.width == \"*\") {\n item.splitPanel.asteriskLength++;\n } else {\n //panel.__width = getPixel(panel.width, item.targetDimension.width);\n }\n }\n }\n }\n }\n };\n var setCSS = {\n \"top\": function (item, panel) {\n panel.$target.css({height: panel.__height || 0});\n if (panel.split) {\n panel.$splitter.css({height: item.splitter.size, top: (panel.__height || 0)});\n }\n },\n \"bottom\": function (item, panel) {\n panel.$target.css({height: panel.__height || 0});\n if (panel.split) {\n panel.$splitter.css({height: item.splitter.size, bottom: (panel.__height || 0)});\n }\n },\n \"left\": function (item, panel) {\n var css = {\n width: panel.__width || 0,\n height: item.targetDimension.height\n };\n\n if (item.dockPanel.top) {\n css.height -= item.dockPanel.top.__height;\n css.top = item.dockPanel.top.__height;\n if (item.dockPanel.top.split) {\n css.height -= item.splitter.size;\n css.top += item.splitter.size;\n }\n }\n if (item.dockPanel.bottom) {\n css.height -= item.dockPanel.bottom.__height;\n if (item.dockPanel.bottom.split) {\n css.height -= item.splitter.size;\n }\n }\n\n panel.$target.css(css);\n\n if (panel.split) {\n panel.$splitter.css({width: item.splitter.size, height: css.height, top: css.top, left: css.width});\n }\n },\n \"right\": function (item, panel) {\n var css = {\n width: panel.__width || 0,\n height: item.targetDimension.height\n };\n\n if (item.dockPanel.top) {\n css.height -= item.dockPanel.top.__height;\n css.top = item.dockPanel.top.__height;\n if (item.dockPanel.top.split) {\n css.height -= item.splitter.size;\n css.top += item.splitter.size;\n }\n }\n if (item.dockPanel.bottom) {\n css.height -= item.dockPanel.bottom.__height;\n if (item.dockPanel.bottom.split) {\n css.height -= item.splitter.size;\n }\n }\n\n panel.$target.css(css);\n\n if (panel.split) {\n panel.$splitter.css({width: item.splitter.size, height: css.height, top: css.top, right: css.width});\n }\n },\n \"center\": function (item, panel) {\n var css = {\n width: item.targetDimension.width,\n height: item.targetDimension.height\n };\n\n if (item.dockPanel.top) {\n css.height -= item.dockPanel.top.__height || 0;\n css.top = item.dockPanel.top.__height || 0;\n if (item.dockPanel.top.split) {\n css.height -= item.splitter.size;\n css.top += item.splitter.size;\n }\n }\n if (item.dockPanel.bottom) {\n css.height -= item.dockPanel.bottom.__height || 0;\n if (item.dockPanel.bottom.split) {\n css.height -= item.splitter.size;\n }\n }\n if (item.dockPanel.left) {\n css.width -= item.dockPanel.left.__width || 0;\n css.left = item.dockPanel.left.__width || 0;\n if (item.dockPanel.left.split) {\n css.width -= item.splitter.size;\n css.left += item.splitter.size;\n }\n }\n if (item.dockPanel.right) {\n css.width -= item.dockPanel.right.__width || 0;\n if (item.dockPanel.right.split) {\n css.width -= item.splitter.size;\n }\n }\n\n var minWidth = panel.minWidth || 0;\n var minHeight = panel.minHeight || 0;\n\n // 레이아웃의 최소 너비 높이를 주어 레이아웃 덕패널이 겹치는 일이 없게 합니다\n if (css.width < minWidth) {\n css.width = minWidth;\n item.$target.css({minWidth: minWidth + getDockPanelOuterSize[\"width\"](item.dockPanel.left, item.splitter.size) + getDockPanelOuterSize[\"width\"](item.dockPanel.right, item.splitter.size)});\n }\n if (css.height < minHeight) {\n css.height = minHeight;\n item.$target.css({minHeight: minHeight + getDockPanelOuterSize[\"height\"](item.dockPanel.top, item.splitter.size) + getDockPanelOuterSize[\"height\"](item.dockPanel.bottom, item.splitter.size)});\n }\n\n panel.$target.css(css);\n },\n \"split\": {\n \"horizontal\": function (item, panel, panelIndex, withoutAsteriskSize, windowResize) {\n var css = {\n display: \"block\"\n };\n var prevPosition = (panelIndex) ? Number(item.splitPanel[panelIndex - 1].offsetEnd) : 0;\n if (panel.splitter) {\n css.height = item.splitter.size;\n }\n else {\n if (panel.height == \"*\" && (typeof panel.__height === \"undefined\" || windowResize)) {\n // 남은 전체 공간을 사용\n css.height = panel.__height = (item.targetDimension.height - withoutAsteriskSize) / item.splitPanel.asteriskLength;\n }\n else {\n css.height = panel.__height || 0;\n }\n }\n css.top = prevPosition;\n panel.offsetStart = prevPosition;\n panel.offsetEnd = Number(prevPosition) + Number(css.height);\n panel.$target.css(css);\n },\n \"vertical\": function (item, panel, panelIndex, withoutAsteriskSize, windowResize) {\n var css = {\n display: \"block\"\n };\n var prevPosition = (panelIndex) ? Number(item.splitPanel[panelIndex - 1].offsetEnd) : 0;\n\n if (panel.splitter) {\n css.width = item.splitter.size;\n }\n else {\n if (panel.width == \"*\" && (typeof panel.__width === \"undefined\" || windowResize)) {\n // 남은 전체 공간을 사용\n css.width = panel.__width = (item.targetDimension.width - withoutAsteriskSize) / item.splitPanel.asteriskLength;\n }\n else {\n css.width = panel.__width || 0;\n }\n }\n css.left = prevPosition;\n panel.offsetStart = prevPosition;\n panel.offsetEnd = Number(prevPosition) + Number(css.width);\n\n panel.$target.css(css);\n }\n }\n };\n var layoutProcessor = {\n \"dock-panel\": function (item) {\n for (var panel in item.dockPanel) {\n if (item.dockPanel[panel].$target && item.dockPanel[panel].$target.get(0)) {\n if (panel in setCSS) {\n setCSS[panel].call(this, item, item.dockPanel[panel]);\n }\n }\n }\n },\n \"split-panel\": function (item, windowResize) {\n //console.log(item.splitPanel);\n var withoutAsteriskSize;\n item.splitPanel.asteriskLength = 0;\n item.splitPanel.forEach(function (panel, panelIndex) {\n beforeSetCSS[\"split\"][item.orientation].call(this, item, panel, panelIndex);\n });\n\n if (item.orientation == \"horizontal\") {\n withoutAsteriskSize = U.sum(item.splitPanel, function (n) {\n if (n.height != \"*\") return U.number(n.__height);\n });\n }\n else {\n withoutAsteriskSize = U.sum(item.splitPanel, function (n) {\n if (n.width != \"*\") return U.number(n.__width);\n });\n }\n\n item.splitPanel.forEach(function (panel, panelIndex) {\n setCSS[\"split\"][item.orientation].call(this, item, panel, panelIndex, withoutAsteriskSize, windowResize);\n });\n }\n };\n var childResize = function (item) {\n var i = item.childQueIdxs.length;\n while (i--) {\n alignLayout.call(this, item.childQueIdxs[i]);\n }\n };\n\n return function (queIdx, callback, windowResize) {\n var item = this.queue[queIdx];\n\n // 레이아웃 타겟의 CSS속성을 미리 저장해 둡니다. 왜? 패널별로 크기 계산 할 때 쓰려고\n item.targetDimension = {\n height: item.$target.innerHeight(),\n width: item.$target.innerWidth()\n };\n\n if (item.layout in layoutProcessor) {\n layoutProcessor[item.layout].call(this, item, windowResize);\n }\n\n if (item.childQueIdxs) childResize.call(this, item, windowResize);\n if (item.onResize) {\n setTimeout((function () {\n this.onResize.call(this, this);\n }).bind(item), 1)\n\n }\n if (callback) {\n callback.call(item, item);\n }\n }\n })(),\n resizeSplitter = {\n \"on\": function (queIdx, panel, $splitter) {\n var item = this.queue[queIdx];\n var splitterOffset = $splitter.position();\n var splitterBox = {\n width: $splitter.width(), height: $splitter.height()\n };\n var getResizerPosition = {\n \"left\": function (e) {\n var mouseObj = ('changedTouches' in e.originalEvent) ? e.originalEvent.changedTouches[0] : e;\n\n panel.__da = mouseObj.clientX - panel.mousePosition.clientX;\n var minWidth = panel.minWidth || 0;\n var maxWidth = panel.maxWidth || (item.targetDimension.width - getDockPanelOuterSize[\"width\"](item, item.dockPanel.left) - getDockPanelOuterSize[\"width\"](item, item.dockPanel.right));\n\n if (panel.__width + panel.__da < minWidth) {\n panel.__da = -panel.__width + minWidth;\n }\n else if (maxWidth < panel.__width + panel.__da) {\n panel.__da = maxWidth - panel.__width;\n }\n return {left: panel.$splitter.position().left + panel.__da};\n },\n \"right\": function (e) {\n var mouseObj = ('changedTouches' in e.originalEvent) ? e.originalEvent.changedTouches[0] : e;\n\n panel.__da = mouseObj.clientX - panel.mousePosition.clientX;\n var minWidth = panel.minWidth || 0;\n var maxWidth = panel.maxWidth || (item.targetDimension.width - getDockPanelOuterSize[\"width\"](item, item.dockPanel.left) - getDockPanelOuterSize[\"width\"](item, item.dockPanel.right));\n\n if (panel.__width - panel.__da < minWidth) {\n panel.__da = panel.__width - minWidth;\n }\n else if (maxWidth < panel.__width - panel.__da) {\n panel.__da = -maxWidth + panel.__width;\n }\n return {left: panel.$splitter.position().left + panel.__da};\n },\n \"top\": function (e) {\n var mouseObj = ('changedTouches' in e.originalEvent) ? e.originalEvent.changedTouches[0] : e;\n\n panel.__da = mouseObj.clientY - panel.mousePosition.clientY;\n var minHeight = panel.minHeight || 0;\n var maxHeight = panel.maxHeight || (item.targetDimension.height - getDockPanelOuterSize[\"height\"](item, item.dockPanel.top) - getDockPanelOuterSize[\"height\"](item, item.dockPanel.bottom));\n\n if (panel.__height + panel.__da < minHeight) {\n panel.__da = -panel.__height + minHeight;\n }\n else if (maxHeight < panel.__height + panel.__da) {\n panel.__da = maxHeight - panel.__height;\n }\n return {top: panel.$splitter.position().top + panel.__da};\n },\n \"bottom\": function (e) {\n var mouseObj = ('changedTouches' in e.originalEvent) ? e.originalEvent.changedTouches[0] : e;\n\n panel.__da = mouseObj.clientY - panel.mousePosition.clientY;\n var minHeight = panel.minHeight || 0;\n var maxHeight = panel.maxHeight || (item.targetDimension.height - getDockPanelOuterSize[\"height\"](item, item.dockPanel.top) - getDockPanelOuterSize[\"height\"](item, item.dockPanel.bottom));\n\n if (panel.__height - panel.__da < minHeight) {\n panel.__da = panel.__height - minHeight;\n }\n else if (maxHeight < panel.__height - panel.__da) {\n panel.__da = -maxHeight + panel.__height;\n }\n return {top: panel.$splitter.position().top + panel.__da};\n },\n \"split\": function (e) {\n var mouseObj = ('changedTouches' in e.originalEvent) ? e.originalEvent.changedTouches[0] : e;\n\n if (item.orientation == \"horizontal\") {\n panel.__da = mouseObj.clientY - panel.mousePosition.clientY;\n\n var prevPanel = item.splitPanel[panel.panelIndex - 1];\n var nextPanel = item.splitPanel[panel.panelIndex + 1];\n\n var prePanelMinHeight = prevPanel.minHeight || 0;\n var nextPanelMinHeight = nextPanel.minHeight || 0;\n\n if (panel.offsetStart + panel.__da < prevPanel.offsetStart + prePanelMinHeight) {\n panel.__da = prevPanel.offsetStart - panel.offsetStart + prePanelMinHeight;\n }\n else if (panel.offsetStart + panel.__da > nextPanel.offsetEnd - nextPanelMinHeight) {\n panel.__da = nextPanel.offsetEnd - panel.offsetEnd - nextPanelMinHeight;\n }\n\n return {top: panel.$target.position().top + panel.__da};\n }\n else {\n /// todo : min & max 범위 정하기\n panel.__da = mouseObj.clientX - panel.mousePosition.clientX;\n\n var prevPanel = item.splitPanel[panel.panelIndex - 1];\n var nextPanel = item.splitPanel[panel.panelIndex + 1];\n var prePanelMinWidth = prevPanel.minWidth || 0;\n var nextPanelMinWidth = nextPanel.minWidth || 0;\n\n if (panel.offsetStart + panel.__da < prevPanel.offsetStart + prePanelMinWidth) {\n panel.__da = prevPanel.offsetStart - panel.offsetStart + prePanelMinWidth;\n }\n else if (panel.offsetStart + panel.__da > nextPanel.offsetEnd - nextPanelMinWidth) {\n panel.__da = nextPanel.offsetEnd - panel.offsetEnd - nextPanelMinWidth;\n }\n return {left: Number(panel.$target.position().left) + Number(panel.__da)};\n }\n }\n };\n panel.__da = 0; // 패널의 변화량\n\n jQuery(document.body)\n .bind(ENM[\"mousemove\"] + \".ax5layout-\" + this.instanceId, function (e) {\n if (!self.resizer) {\n\n self.resizer = jQuery('');\n self.resizer.css({\n left: splitterOffset.left,\n top: splitterOffset.top,\n width: splitterBox.width,\n height: splitterBox.height\n });\n item.$target.append(self.resizer);\n }\n self.resizer.css(getResizerPosition[panel.resizerType](e));\n })\n .bind(ENM[\"mouseup\"] + \".ax5layout-\" + this.instanceId, function (e) {\n resizeSplitter.off.call(self, queIdx, panel, $splitter);\n })\n .bind(\"mouseleave.ax5layout-\" + this.instanceId, function (e) {\n resizeSplitter.off.call(self, queIdx, panel, $splitter);\n });\n\n jQuery(document.body)\n .attr('unselectable', 'on')\n .css('user-select', 'none')\n .on('selectstart', false);\n\n },\n \"off\": function (queIdx, panel, $splitter) {\n var item = this.queue[queIdx];\n var setPanelSize = {\n \"dock-panel\": {\n \"left\": function (queIdx, panel) {\n panel.__width += panel.__da;\n },\n \"right\": function () {\n panel.__width -= panel.__da;\n },\n \"top\": function () {\n panel.__height += panel.__da;\n },\n \"bottom\": function () {\n panel.__height -= panel.__da;\n }\n },\n \"split-panel\": {\n \"split\": function () {\n if (item.orientation == \"horizontal\") {\n // 앞과 뒤의 높이 조절\n item.splitPanel[panel.panelIndex - 1].__height += panel.__da;\n item.splitPanel[panel.panelIndex + 1].__height -= panel.__da;\n }\n else {\n // 앞과 뒤의 높이 조절\n\n item.splitPanel[panel.panelIndex - 1].__width += panel.__da;\n item.splitPanel[panel.panelIndex + 1].__width -= panel.__da;\n }\n }\n },\n \"tab-panel\": {}\n };\n\n if (self.resizer) {\n self.resizer.remove();\n self.resizer = null;\n setPanelSize[this.queue[queIdx].layout][panel.resizerType].call(this, queIdx, panel);\n alignLayout.call(this, queIdx);\n }\n\n jQuery(document.body)\n .unbind(ENM[\"mousemove\"] + \".ax5layout-\" + this.instanceId)\n .unbind(ENM[\"mouseup\"] + \".ax5layout-\" + this.instanceId)\n .unbind(\"mouseleave.ax5layout-\" + this.instanceId);\n\n jQuery(document.body)\n .removeAttr('unselectable')\n .css('user-select', 'auto')\n .off('selectstart');\n\n }\n },\n tabControl = {\n \"open\": function (queIdx, layout, panelIndex) {\n if (layout.activePanelIndex != panelIndex) {\n layout.tabPanel[panelIndex].active = true;\n layout.tabPanel[layout.activePanelIndex].active = false;\n layout.$target.find('[data-tab-panel-label=\"' + panelIndex + '\"]').attr(\"data-tab-active\", \"true\");\n layout.$target.find('[data-tab-panel-label=\"' + layout.activePanelIndex + '\"]').removeAttr(\"data-tab-active\");\n layout.tabPanel[panelIndex].$target.attr(\"data-tab-active\", \"true\");\n layout.tabPanel[layout.activePanelIndex].$target.removeAttr(\"data-tab-active\");\n layout.activePanelIndex = panelIndex;\n\n if (layout.onOpenTab) {\n var that = {\n '$target': layout.$target,\n name: layout.name,\n id: layout.id,\n layout: layout.layout,\n activePanelIndex: layout.activePanelIndex,\n activePanel: layout.tabPanel[layout.activePanelIndex],\n tabPanel: layout.tabPanel\n };\n layout.onOpenTab.call(that);\n }\n }\n }\n },\n\n getTabLabesTmpl = function () {\n return `\n\n
\n
\n
\n {{#tabPanel}}\n
\n {{/tabPanel}}\n
\n
\n
\n`;\n },\n bindLayoutTarget = (function () {\n\n var applyLayout = {\n \"dock-panel\": function (queIdx) {\n var item = this.queue[queIdx];\n item.dockPanel = {};\n item.$target.find('>[data-dock-panel]').each(function () {\n\n var panelInfo = {};\n (function (data) {\n if (U.isObject(data) && !data.error) {\n panelInfo = jQuery.extend(true, panelInfo, data);\n }\n })(U.parseJson(this.getAttribute(\"data-dock-panel\"), true));\n\n if ('dock' in panelInfo) {\n panelInfo.$target = jQuery(this);\n panelInfo.$target.addClass(\"dock-panel-\" + panelInfo.dock);\n\n if (panelInfo.split = (panelInfo.split && panelInfo.split.toString() == \"true\")) {\n panelInfo.$splitter = jQuery('');\n panelInfo.$splitter\n .bind(ENM[\"mousedown\"], function (e) {\n panelInfo.mousePosition = getMousePosition(e);\n resizeSplitter.on.call(self, queIdx, panelInfo, panelInfo.$splitter);\n })\n .bind(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n item.$target.append(panelInfo.$splitter);\n }\n\n if (panelInfo.dock == \"top\" || panelInfo.dock == \"bottom\") {\n panelInfo.__height = getPixel(panelInfo.height, item.targetDimension.height);\n }\n else {\n panelInfo.__width = getPixel(panelInfo.width, item.targetDimension.width);\n }\n panelInfo.resizerType = panelInfo.dock;\n item.dockPanel[panelInfo.dock] = panelInfo;\n }\n });\n\n },\n \"split-panel\": function (queIdx) {\n var item = this.queue[queIdx];\n item.splitPanel = [];\n item.$target.find('>[data-split-panel], >[data-splitter]').each(function (ELIndex) {\n\n var panelInfo = {};\n (function (data) {\n if (U.isObject(data) && !data.error) {\n panelInfo = jQuery.extend(true, panelInfo, data);\n }\n })(U.parseJson(this.getAttribute(\"data-split-panel\") || this.getAttribute(\"data-splitter\"), true));\n\n panelInfo.$target = jQuery(this);\n panelInfo.$target\n .addClass(\"split-panel-\" + item.orientation);\n panelInfo.panelIndex = ELIndex;\n\n if (this.getAttribute(\"data-splitter\")) {\n\n panelInfo.splitter = true;\n panelInfo.$target\n .bind(ENM[\"mousedown\"], function (e) {\n if (panelInfo.panelIndex > 0 && panelInfo.panelIndex < item.splitPanel.length - 1) {\n panelInfo.mousePosition = getMousePosition(e);\n resizeSplitter.on.call(self, queIdx, panelInfo, panelInfo.$target);\n }\n })\n .bind(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\n panelInfo.resizerType = \"split\";\n\n } else {\n\n if (item.orientation == \"horizontal\") {\n panelInfo.__height = getPixel(panelInfo.height, item.targetDimension.height);\n }\n else {\n item.orientation = \"vertical\";\n panelInfo.__width = getPixel(panelInfo.width, item.targetDimension.width);\n }\n\n }\n\n item.splitPanel.push(panelInfo);\n });\n },\n \"tab-panel\": function (queIdx) {\n var item = this.queue[queIdx];\n\n var hasActivePanel = false;\n var activePanelIndex = -1;\n item.tabPanel = [];\n item.$target.find('>[data-tab-panel]').each(function (ELIndex) {\n var panelInfo = {};\n (function (data) {\n if (U.isObject(data) && !data.error) {\n panelInfo = jQuery.extend(true, panelInfo, data);\n }\n })(U.parseJson(this.getAttribute(\"data-tab-panel\"), true));\n\n if (hasActivePanel) {\n panelInfo.active = false;\n }\n\n panelInfo.$target = jQuery(this);\n\n if (panelInfo.active && panelInfo.active != \"false\") {\n hasActivePanel = true;\n item.activePanelIndex = ELIndex;\n panelInfo.$target.attr(\"data-tab-active\", \"true\");\n }\n\n panelInfo.panelIndex = ELIndex;\n item.tabPanel.push(panelInfo);\n });\n\n if (!hasActivePanel) {\n item.tabPanel[0].active = true;\n item.tabPanel[0].$target.attr(\"data-tab-active\", \"true\");\n item.activePanelIndex = 0;\n }\n\n // make tabLabel\n item.$target.append(jQuery(ax5.mustache.render(getTabLabesTmpl.call(this, queIdx), item)));\n item.$target.on(\"click\", '[data-tab-panel-label]', function (e) {\n var index = this.getAttribute(\"data-tab-panel-label\");\n tabControl.open.call(self, queIdx, item, index);\n });\n }\n };\n\n return function (queIdx) {\n var item = this.queue[queIdx];\n var data = {};\n\n // 레이아웃 타겟의 CSS속성을 미리 저장해 둡니다. 왜? 패널별로 크기 계산 할 때 쓰려고\n item.targetDimension = {\n height: item.$target.innerHeight(),\n width: item.$target.innerWidth()\n };\n\n // 부모 컨테이너가 ax5layout인지 판단 필요.\n if (item.$target.parents(\"[data-ax5layout]\").get(0)) {\n hooksResizeLayout.call(\n this,\n item.$target.parents(\"[data-ax5layout]\").get(0),\n queIdx\n );\n }\n\n if (item.layout in applyLayout) {\n applyLayout[item.layout].call(this, queIdx);\n }\n alignLayout.call(this, queIdx);\n }\n })(),\n getQueIdx = function (boundID) {\n if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-ax5layout-id\");\n }\n if (!U.isString(boundID)) {\n //console.log(ax5.info.getError(\"ax5layout\", \"402\", \"getQueIdx\"));\n return -1;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n },\n hooksResizeLayout = function (boundID, childQueIdx) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n if (!this.queue[queIdx].childQueIdxs) this.queue[queIdx].childQueIdxs = [];\n this.queue[queIdx].childQueIdxs.push(childQueIdx);\n this.queue[childQueIdx].parentQueIdx = queIdx;\n };\n/// private end\n /**\n * Preferences of layout UI\n * @method ax5layout.setConfig\n * @param {Object} config - 클래스 속성값\n * @param {Number} [config.animateTime=250]\n * @param {Object} [config.splitter]\n * @param {Number} [config.splitter.size=4]\n * @param {Boolean} [config.autoResize=true]\n * @returns {ax5layout}\n * @example\n * ```js\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onClick = cfg.onClick;\n jQuery(window).bind(\"resize.ax5layout-\" + this.instanceId, (function () {\n alignLayoutAll.call(this);\n }).bind(this));\n };\n\n /**\n * @method ax5layout.bind\n * @param {Object} item\n * @param {String} [item.layout]\n * @param {String} [item.theme]\n * @param {Element} item.target\n * @param {Object[]} item.options\n * @param {Object} [item.splitter]\n * @param {Number} [item.splitter.size=4]\n * @param {Boolean} [item.autoResize=true]\n * @returns {ax5layout}\n */\n this.bind = function (item) {\n var\n UIConfig = {},\n queIdx;\n\n item = jQuery.extend(true, UIConfig, cfg, item);\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5layout\", \"401\", \"bind\"));\n return this;\n }\n\n item.$target = jQuery(item.target);\n\n if (!item.id) item.id = item.$target.data(\"data-ax5layout-id\");\n if (!item.id) {\n item.id = 'ax5layout-' + ax5.getGuid();\n item.$target.data(\"data-ax5layout-id\", item.id);\n }\n item.name = item.$target.attr(\"data-ax5layout\");\n if (item.options) {\n item.options = JSON.parse(JSON.stringify(item.options));\n }\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n item = jQuery.extend(true, item, data);\n }\n })(U.parseJson(item.$target.attr(\"data-config\"), true));\n\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindLayoutTarget.call(this, this.queue.length - 1);\n }\n else {\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindLayoutTarget.call(this, queIdx);\n }\n\n UIConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * @method ax5layout.align\n * @param boundID\n * @param {Function} [callback]\n * @param {String} [windowResize]\n * @returns {ax5layout}\n */\n this.align = function (boundID, windowResize) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n\n if (queIdx === -1) {\n var i = this.queue.length;\n while (i--) {\n alignLayout.call(this, i, null, windowResize);\n }\n } else {\n alignLayout.call(this, queIdx, null, windowResize);\n }\n return this;\n };\n\n /**\n * @method ax5layout.onResize\n * @param boundID\n * @param fn\n * @returns {ax5layout}\n */\n this.onResize = function (boundID, fn) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5layout\", \"402\", \"onResize\"));\n return;\n }\n this.queue[queIdx].onResize = fn;\n return this;\n };\n\n /**\n * @method ax5layout.resize\n * @param boundID\n * @param {Object} resizeOption\n * @param {Function} [callback]\n * @returns {ax5layout}\n */\n this.resize = (function () {\n\n var resizeLayoutPanel = {\n \"dock-panel\": function (item, resizeOption) {\n [\"top\", \"bottom\", \"left\", \"right\"].forEach(function (dock) {\n if (resizeOption[dock] && item.dockPanel[dock]) {\n if (dock == \"top\" || dock == \"bottom\") {\n item.dockPanel[dock].__height = (U.isObject(resizeOption[dock])) ? resizeOption[dock].height : resizeOption[dock];\n }\n else if (dock == \"left\" || dock == \"right\") {\n item.dockPanel[dock].__width = (U.isObject(resizeOption[dock])) ? resizeOption[dock].width : resizeOption[dock];\n }\n }\n });\n },\n \"split-panel\": function () {\n\n },\n \"tab-panel\": function () {\n\n }\n };\n\n return function (boundID, resizeOption, callback) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n var i = this.queue.length;\n while (i--) {\n resizeLayoutPanel[this.queue[i].layout].call(this, this.queue[i], resizeOption);\n alignLayout.call(this, i, callback);\n }\n } else {\n if (this.queue[queIdx]) {\n resizeLayoutPanel[this.queue[queIdx].layout].call(this, this.queue[queIdx], resizeOption);\n alignLayout.call(this, queIdx, callback);\n }\n }\n\n return this;\n };\n\n })();\n\n this.reset = (function () {\n\n var resetLayoutPanel = {\n \"dock-panel\": function (item) {\n [\"top\", \"bottom\", \"left\", \"right\"].forEach(function (dock) {\n if (item.dockPanel[dock]) {\n if (dock == \"top\" || dock == \"bottom\") {\n item.dockPanel[dock].__height = item.dockPanel[dock].height;\n }\n else if (dock == \"left\" || dock == \"right\") {\n item.dockPanel[dock].__width = item.dockPanel[dock].width;\n }\n }\n });\n },\n \"split-panel\": function (item) {\n item.splitPanel.forEach(function (panel) {\n if (item.orientation == \"vertical\") {\n panel.__width = getPixel(panel.width, item.targetDimension.width);\n } else if (item.orientation == \"horizontal\") {\n panel.__height = getPixel(panel.height, item.targetDimension.height);\n }\n });\n },\n \"tab-panel\": function () {\n\n }\n };\n\n return function (boundID, callback) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n\n } else {\n resetLayoutPanel[this.queue[queIdx].layout].call(this, this.queue[queIdx]);\n alignLayout.call(this, queIdx, callback);\n }\n\n return this;\n };\n\n })();\n\n this.hide = function () {\n\n };\n\n /**\n * @method ax5layout.tabOpen\n * @param boundID\n * @param tabIndex\n * @returns {ax5.ui.ax5layout}\n */\n this.tabOpen = (function () {\n return function (boundID, tabIndex) {\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5layout\", \"402\", \"tabOpen\"));\n return;\n }\n\n tabControl.open.call(this, queIdx, this.queue[queIdx], tabIndex);\n return this;\n }\n })();\n\n /// 클래스 생성자\n this.main = (function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n else {\n this.init();\n }\n }).apply(this, arguments);\n };\n return ax5layout;\n })());\n})();\n\nax5.ui.layout_instance = new ax5.ui.layout();\n\n/**\n * ax5layout jquery extends\n * @namespace jQueryExtends\n */\n\n/**\n * @method jQueryExtends.ax5layout\n * @param {String} methodName\n * @example\n * ```js\n * jQuery('[data-ax5layout=\"ax1\"]').ax5layout();\n * ```\n */\n\njQuery.fn.ax5layout = (function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"align\":\n return ax5.ui.layout_instance.align(this, arguments[1]);\n break;\n case \"resize\":\n return ax5.ui.layout_instance.resize(this, arguments[1], arguments[2]);\n break;\n case \"reset\":\n return ax5.ui.layout_instance.reset(this, arguments[1]);\n break;\n case \"hide\":\n return ax5.ui.layout_instance.hide(this, arguments[1]);\n break;\n case \"onResize\":\n return ax5.ui.layout_instance.onResize(this, arguments[1]);\n break;\n case \"tabOpen\":\n return ax5.ui.layout_instance.tabOpen(this, arguments[1]);\n break;\n default:\n return this;\n }\n }\n else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.layout_instance.bind(config);\n });\n }\n return this;\n }\n})();","// ax5.ui.binder\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n\n UI.addClass({\n className: \"binder\",\n version: \"1.3.66\"\n }, (function () {\n\n /**\n * @class ax5binder\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var obj = {\n * name: \"Thomas Jang\",\n * alias: \"tom\",\n * tel: \"010-8881-9137\",\n * email: \"tom@axisj.com\",\n * sex: \"M\",\n * hobby: [\"sport\"],\n * useYn: \"N\",\n * description: \"http://www.axisj.com\",\n * list: [\n * {\n * name: \"thomas\",\n * tel: \"010-8881-9000\",\n * email: \"tom@axisj.com\",\n * sex: \"M\",\n * description: \"\",\n * child: [{name:\"값1\"},{name:\"값2\"}],\n * qty: 10,\n * cost: 100\n * },\n * {\n * name: \"thomas\",\n * tel: \"010-8881-9000\",\n * email: \"tom@axisj.com\",\n * sex: \"M\",\n * description: \"\",\n * child: [{name:\"값1\"},{name:\"값2\"}],\n * qty: 20,\n * cost: 100\n * }\n * ]\n * };\n *\n * var myBinder = new ax5.ui.binder();\n * myBinder.setModel(obj, $('#form-target'));\n * ```\n */\n var ax5binder = function () {\n\n var self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {};\n cfg = this.config;\n\n this.model = {};\n this.tmpl = {};\n this.view_target = null;\n this.change_trigger = {};\n this.click_trigger = {};\n this.update_trigger = {};\n this.onerror = null;\n\n var\n _toString = Object.prototype.toString,\n get_type = function (O) {\n var typeName;\n if (O != null && O == O.window) {\n typeName = \"window\";\n }\n else if (!!(O && O.nodeType == 1)) {\n typeName = \"element\";\n }\n else if (!!(O && O.nodeType == 11)) {\n typeName = \"fragment\";\n }\n else if (typeof O === \"undefined\") {\n typeName = \"undefined\";\n }\n else if (_toString.call(O) == \"[object Object]\") {\n typeName = \"object\";\n }\n else if (_toString.call(O) == \"[object Array]\") {\n typeName = \"array\";\n }\n else if (_toString.call(O) == \"[object String]\") {\n typeName = \"string\";\n }\n else if (_toString.call(O) == \"[object Number]\") {\n typeName = \"number\";\n }\n else if (_toString.call(O) == \"[object NodeList]\") {\n typeName = \"nodelist\";\n }\n else if (typeof O === \"function\") {\n typeName = \"function\";\n }\n return typeName;\n },\n get_mix_path = function (dataPath, index, item_path) {\n return dataPath + \"[\" + index + \"]\" + ((item_path == \".\") ? \"\" : \".\" + item_path);\n },\n get_real_path = function (_dataPath) {\n var path = [];\n var _path = [].concat(_dataPath.split(/[\\.\\[\\]]/g));\n _path.forEach(function (n) {\n if (n !== \"\") path.push(\"[\\\"\" + n.replace(/['\\\"]/g, \"\") + \"\\\"]\");\n });\n _path = null;\n return path.join(\"\");\n /*\n var path = [];\n var _path = [].concat(dataPath.split(/[\\.\\[\\]]/g));\n\n _path.forEach(function (n) {\n if (n !== \"\") path.push(n);\n });\n _path = null;\n return \"'\" + path.join(\"']['\") + \"'\";\n */\n };\n\n /**\n * 바인딩할 자바스크립트 오브젝트로 제이쿼리로 검색된 HTML dom 엘리먼트 에 바인딩합니다. 바인딩된 모델을 반환합니다.\n * @method ax5binder.setModel\n * @param {Object} model\n * @param {jQueryObject} [view_target]\n * @returns {ax5binder}\n * @example\n * ```js\n * var myModel = new ax5.ui.binder();\n * myModel.setModel({}, $(\"#...\"));\n * ```\n */\n this.setModel = function (model, view_target) {\n this.model = model;\n if (!this.view_target && view_target) {\n this.view_target = view_target;\n this._binding();\n }\n else {\n this._binding(\"update\");\n }\n return this;\n };\n\n /**\n * data_path에 값을 변경한다. value의 타입은 (String, Number, Array, Object)를 지원.\n * @method ax5binder.set\n * @param {String} dataPath\n * @param {Object} value\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.set(\"name\", \"Seowoo\");\n * myModel.set(\"obj.path\", {a:1});\n * ```\n */\n this.set = function (dataPath, value) {\n var _this = this, obj_type, i, this_type;\n\n (Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\")).call(this.model, value);\n obj_type = get_type(value);\n\n if (obj_type == \"object\") {\n for (var k in value) {\n this.set(dataPath + \".\" + k, value[k]);\n }\n }\n else if (obj_type == \"array\") {\n this.view_target.find('[data-ax-path=\"' + (dataPath) + '\"]').each(function () {\n this_type = (this.type || \"\").toLowerCase();\n if (this_type == \"checkbox\" || this_type == \"radio\")\n _this.set_els_value(this, this.tagName.toLowerCase(), this_type, value, dataPath, \"change\");\n });\n i = value.length;\n while (i--) {\n this.set(dataPath + \"[\" + i + \"]\", value[i]);\n }\n }\n else {\n // apply data value to els\n this.view_target.find('[data-ax-path=\"' + (dataPath) + '\"]').each(function () {\n _this.set_els_value(this, this.tagName.toLowerCase(), (this.type || \"\").toLowerCase(), value, dataPath, \"change\");\n });\n }\n return this;\n };\n\n /**\n * data_path에 값을 반환한다. data_path 가 없으면 전체 Object를 반환한다.\n * @method ax5binder.get\n * @param dataPath\n * @returns {*}\n */\n this.get = function (dataPath) {\n if (typeof dataPath == \"undefined\") {\n return this.model;\n }\n else {\n return (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(this.model);\n }\n };\n\n\n /**\n * data_path에 값이 변경되는 이벤트 발생하면 callback을 실행합니다.\n * @method ax5binder.onChange\n * @param dataPath\n * @param callback\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.onChange(\"name\", function () {\n * console.log(this);\n * // el: domElement - 변경이 발생한 엘리먼트, 엘리먼트로 부터 다양한 속성을 추출할 수 있다.\n * // jquery : jQueryObject\n * // tagname: \"input\"\n * // value: \"changed value\"\n * console.log(this.el.id);\n * });\n * myModel.onChange(\"*\", function (n) {\n * console.log(n);\n * // console.log(this); 와 동일\n * });\n * ```\n */\n this.onChange = function (dataPath, callback) {\n this.change_trigger[dataPath || \"*\"] = callback;\n return this;\n };\n\n /**\n * data-ax-repeat=\"list\" 속성이 부여된 엘리먼트 하위에 태그중에 data-ax-repeat-click 속성을 가진 아이템에 대해 클릭 이벤트 발생하면 callback을 실행합니다.\n * @method ax5binder.onClick\n * @param dataPath\n * @param callback\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.onclick(\"list\", function () {\n * console.log(this);\n * // el: domElement\n * // jquery: jQueryObject\n * // item: Object - repeat item\n * // item_index: \"0\" - index of item\n * // item_path: \"list[0]\" - repeat data_path\n * // repeat_path: \"list\"\n * // tagname: \"button\"\n * // value: \"add\"\n * });\n * ```\n */\n this.onClick = function (dataPath, callback) {\n this.click_trigger[dataPath] = callback;\n return this;\n };\n\n /**\n * data-ax-repeat=\"list\" 하위아이템을 추가합니다.\n * @method ax5binder.add\n * @param dataPath\n * @param item\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.add(\"list\", {a:1});\n * ```\n */\n this.add = function (dataPath, item) {\n var list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(this.model);\n var tmpl = this.tmpl[dataPath];\n item['@i'] = list.length;\n item['@r'] = list.length;\n item.__ADDED__ = true;\n (Function(\"val\", \"this\" + get_real_path(dataPath) + \".push(val);\")).call(this.model, item);\n\n // 다중 템플릿 처리\n for (var t in tmpl) {\n var fragdom = $(ax5.mustache.render(tmpl[t].content, item));\n fragdom.attr(\"data-ax-repeat-path\", dataPath);\n fragdom.attr(\"data-ax-repeat-i\", item['@i']);\n this.bind_event_tmpl(fragdom, dataPath);\n tmpl[t].container.append(fragdom);\n }\n\n this.change(\"*\");\n\n var callback = this.update_trigger[dataPath];\n if (callback) {\n var that = {\n repeat_path: dataPath,\n tmpl : tmpl,\n list : list\n };\n callback.call(that, that);\n }\n\n return this;\n };\n\n /**\n * data-ax-repeat=\"list\" 하위 아이템을 제거합니다. 단! 이 때 ADDED 값을 가진 아이템은 제거하고 그렇지 않은 아이템은 DELETED 값을 아이템에 추가합니다.\n * @method ax5binder.remove\n * @param dataPath\n * @param index\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.remove(\"list\", 0);\n * ```\n */\n this.remove = function (dataPath, index) {\n var list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(this.model);\n var tmpl = this.tmpl[dataPath];\n if (typeof index == \"undefined\") index = list.length - 1;\n var remove_item = list[index];\n if (remove_item.__ADDED__) {\n list.splice(index, 1);\n }\n else {\n list[index].__DELETED__ = true;\n }\n\n for (var t in tmpl) {\n tmpl[t].container.empty();\n this.print_tmpl(dataPath, tmpl[t]);\n }\n\n this.change(\"*\");\n\n var callback = this.update_trigger[dataPath];\n if (callback) {\n var that = {\n repeat_path: dataPath,\n tmpl : tmpl,\n list : list\n };\n callback.call(that, that);\n }\n\n return this;\n };\n\n /**\n * data-ax-repeat=\"list\" 하위 아이템을 교체합니다.\n * @method ax5binder.update\n * @param dataPath\n * @param index\n * @param item\n * @returns {ax5binder}\n * @example\n * ```js\n * myModel.update(\"list\", 0, {a:1});\n * ```\n */\n this.update = function (dataPath, index, item) {\n var list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(this.model);\n var tmpl = this.tmpl[dataPath];\n if (typeof index != \"undefined\" && item) list.splice(index, 1, item);\n\n for (var t in tmpl) {\n tmpl[t].container.empty();\n this.print_tmpl(dataPath, tmpl[t]);\n }\n\n this.change(\"*\");\n\n var callback = this.update_trigger[dataPath];\n if (callback) {\n var that = {\n repeat_path: dataPath,\n tmpl : tmpl,\n list : list\n };\n callback.call(that, that);\n }\n\n return this;\n };\n\n /**\n * @method ax5binder.childAdd\n * @param dataPath\n * @param index\n * @param child_path\n * @param child_item\n */\n this.childAdd = function (dataPath, index, child_path, child_item) {\n var _list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(this.model);\n var list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \"[\" + index + \"].\" + child_path + \";\")).call(this.model);\n child_item.__ADDED__ = true;\n list.push(child_item);\n this.update(dataPath, index, _list[index]);\n };\n\n /**\n * ax5binder.childRemove\n * @param dataPath\n * @param index\n * @param child_path\n * @param child_index\n */\n this.childRemove = function (dataPath, index, child_path, child_index) {\n var _list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(this.model);\n var list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \"[\" + index + \"].\" + child_path + \";\")).call(this.model);\n var remove_item = list[child_index];\n if (remove_item.__ADDED__) {\n list.splice(child_index, 1);\n }\n else {\n list[child_index].__DELETED__ = true;\n }\n this.update(dataPath, index, _list[index]);\n };\n\n /**\n * @method ax5binder.childUpdate\n * @param dataPath\n * @param index\n * @param child_path\n * @param child_index\n * @param child_item\n */\n this.childUpdate = function (dataPath, index, child_path, child_index, child_item) {\n var _list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(this.model);\n var list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \"[\" + index + \"].\" + child_path + \";\")).call(this.model);\n list[child_index] = child_item;\n this.update(dataPath, index, _list[index]);\n };\n\n /**\n * @method ax5binder.childSet\n * @param dataPath\n * @param index\n * @param child_path\n * @param value\n * @returns {ax5binder}\n */\n this.childSet = function (dataPath, index, child_path, value) {\n var _this = this, i;\n (Function(\"val\", \"this\" + get_real_path(dataPath) + \"[\" + index + \"].\" + child_path + \" = val;\")).call(this.model, value);\n\n // apply data value to els\n this.view_target.find('[data-ax-repeat=\"' + (dataPath) + '\"]').find('[data-ax-repeat-i=\"' + index + '\"]').find('[data-ax-item-path=\"' + child_path + '\"]').each(function () {\n _this.set_els_value(this, this.tagName.toLowerCase(), (this.type || \"\").toLowerCase(), value, dataPath + \"[\" + index + \"].\" + child_path);\n });\n return this;\n };\n\n /**\n * @method ax5binder.onUpdate\n * @param dataPath\n * @param callback\n * @returns {ax5binder}\n * @example\n * ```js\n * this.model.onupdate(\"moderator\", function () {\n * $('#moderator-add').val('');\n * $moderator.find('[data-role-user-btn]')\n * .unbind(\"click\")\n * .bind(\"click\", role_user_btn_onclick);\n * });\n * ```\n */\n this.onUpdate = function (dataPath, callback) {\n this.update_trigger[dataPath] = callback;\n return this;\n };\n\n\n this._binding = function (isupdate) {\n var _this = this;\n\n // apply data value to els\n this.view_target.find('[data-ax-path]').each(function () {\n var dom = $(this), dataPath = dom.attr(\"data-ax-path\"), this_type = (this.type || \"\").toLowerCase();\n\n var val;\n try {\n val = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(_this.model);\n } catch (e) {\n /**\n * onerror를 선언 한 경우에만 에러 출력\n * */\n if (_this.onerror) _this.onerror(\"not found target [model.\" + get_real_path(dataPath) + \"]\");\n }\n\n _this.set_els_value(this, this.tagName.toLowerCase(), this_type, val || \"\", dataPath);\n });\n\n if (typeof isupdate == \"undefined\") {\n // collect tmpl\n this.view_target.find('[data-ax-repeat]').each(function () {\n var dom = $(this), dataPath = dom.attr(\"data-ax-repeat\"), repeat_idx = dom.attr(\"data-ax-repeat-idx\");\n\n if (typeof _this.tmpl[dataPath] == \"undefined\") _this.tmpl[dataPath] = {};\n if (typeof repeat_idx != \"undefined\") {\n _this.tmpl[dataPath][repeat_idx] = {\n container: dom, content: dom.find(\"script\").html()\n };\n }\n else {\n _this.tmpl[dataPath][\"0\"] = {\n container: dom, content: dom.find(\"script\").html()\n };\n }\n //dom.empty().show();\n dom.empty();\n });\n }\n else {\n this.view_target.find('[data-ax-repeat]').each(function () {\n var dom = $(this);\n dom.empty().show();\n });\n }\n\n // binding event to els\n this.view_target.find('[data-ax-path]').unbind(\"change.axbinder\").bind(\"change.axbinder\", function (e) {\n\n var\n i,\n hasItem = false,\n checked,\n new_value = [],\n dom = $(e.target),\n dataPath = dom.attr(\"data-ax-path\"),\n origin_value = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(_this.model),\n this_type = (this.type || \"\").toLowerCase(),\n value_type = get_type(origin_value),\n setAllow = true\n ;\n\n\n if (value_type == \"object\" || value_type == \"array\") {\n setAllow = false;\n }\n\n if (this_type == \"checkbox\") {\n // 동일한 체크박스가 여러개 인지 판단합니다.\n if (_this.view_target.find('[data-ax-path=\"' + (dataPath) + '\"]').length > 1) {\n\n if (get_type(origin_value) != \"array\") {\n if (typeof origin_value === \"undefined\" || origin_value == \"\") origin_value = [];\n else origin_value = [].concat(origin_value);\n }\n i = origin_value.length, hasItem = false, checked = this.checked;\n while (i--) {\n if (origin_value[i] == this.value) {\n hasItem = true;\n }\n }\n\n if (checked) {\n if (!hasItem) origin_value.push(this.value);\n }\n else {\n i = origin_value.length;\n while (i--) {\n if (origin_value[i] == this.value) {\n //hasItemIndex = i;\n }\n else {\n new_value.push(origin_value[i]);\n }\n }\n origin_value = new_value;\n }\n }\n else {\n origin_value = (this.checked) ? this.value : \"\";\n }\n\n (Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\")).call(_this.model, origin_value);\n _this.change(dataPath, {\n el: this, jquery: dom, tagname: this.tagName.toLowerCase(), value: origin_value\n });\n }\n else {\n if (setAllow) {\n (Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\")).call(_this.model, this.value);\n _this.change(dataPath, {\n el: this, jquery: dom, tagname: this.tagName.toLowerCase(), value: this.value\n });\n }\n }\n\n dom.data(\"changedTime\", (new Date()).getTime());\n });\n /*\n this.view_target.find('[data-ax-path]').unbind(\"blur.axbinder\").bind(\"blur.axbinder\", function (e) {\n var dom = $(e.target);\n if (typeof dom.data(\"changedTime\") == \"undefined\" || dom.data(\"changedTime\") < (new Date()).getTime() - 10) dom.trigger(\"change\");\n });\n */\n\n //_this.tmpl\n var callback;\n for (var tk in _this.tmpl) {\n for (var ix in _this.tmpl[tk]) {\n // console.log(_this.tmpl[tk][ix].content);\n this.print_tmpl(tk, _this.tmpl[tk][ix], \"isInit\");\n }\n\n if (callback = this.update_trigger[tk]) {\n var that = {\n repeat_path: tk,\n tmpl : _this.tmpl[tk],\n list : (Function(\"\", \"return this.\" + tk + \";\")).call(this.model)\n };\n callback.call(that, that);\n }\n }\n };\n\n this.set_els_value = function (el, tagname, type, value, dataPath, callChange) {\n if (typeof value === \"undefined\") value = [];\n else value = [].concat(value);\n var options, i;\n\n if (tagname == \"input\") {\n if (type == \"checkbox\" || type == \"radio\") {\n i = value.length;\n var checked = false;\n try {\n if (i > 0) {\n while (i--) {\n if (typeof value[i] !== \"undefined\" && el.value === value[i].toString()) {\n checked = true;\n }\n }\n }\n } catch (e) {\n console.log(e);\n }\n\n el.checked = checked;\n }\n else {\n el.value = value.join('');\n }\n }\n else if (tagname == \"select\") {\n options = el.options, i = options.length;\n var vi, option_matched = false;\n\n while (i--) {\n vi = value.length;\n while (vi--) {\n if (typeof value[vi] !== \"undefined\" && options[i].value === value[vi].toString()) {\n options[i].selected = true;\n option_matched = true;\n break;\n }\n }\n if (option_matched) break;\n }\n if (!option_matched) {\n if (options[0]) {\n options[0].selected = true;\n (Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\")).call(this.model, options[0].value);\n }\n else {\n (Function(\"val\", \"this\" + get_real_path(dataPath) + \" = val;\")).call(this.model, \"\");\n }\n }\n\n if (window.AXSelect) { // AXISJ 사용가능\n $(typeof value !== \"undefined\" && el).bindSelectSetValue(value[value.length - 1]);\n }\n }\n else if (tagname == \"textarea\") {\n el.value = value.join('') || \"\";\n }\n else {\n if (el.innerText) {\n el.innerText = value.join(\"\");\n }\n else {\n el.innerHTML = value.join(\"\");\n }\n }\n\n if (callChange) {\n this.change(dataPath, {el: el, tagname: tagname, value: value});\n }\n return this;\n };\n\n this.change = function (dataPath, that) {\n var callback = this.change_trigger[dataPath];\n if (callback) {\n callback.call(that, that);\n }\n if (dataPath != \"*\" && this.change_trigger[\"*\"]) {\n this.change_trigger[\"*\"].call(that, that);\n }\n };\n\n this.click = function (dataPath, that) {\n var callback = this.click_trigger[dataPath];\n if (callback) {\n callback.call(that, that);\n }\n };\n\n this.sync_model = function () {\n\n };\n\n this.print_tmpl = function (dataPath, tmpl, isInit) {\n var list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(this.model);\n if (list && get_type(list) == \"array\") {\n for (var i = 0, l = list.length; i < l; i++) {\n var item = list[i];\n if (jQuery.isPlainObject(item)) {\n item['@i'] = i;\n item['@r'] = i;\n if (i === 0) item['@first'] = true;\n }\n else {\n item = {\n \"@i\" : i,\n \"@value\": item\n };\n if (i === 0) item['@first'] = true;\n console.log(item);\n }\n\n if (!item.__DELETED__) {\n var fragdom = $(ax5.mustache.render(tmpl.content, item));\n fragdom.attr(\"data-ax-repeat-path\", dataPath);\n fragdom.attr(\"data-ax-repeat-i\", item['@i']);\n this.bind_event_tmpl(fragdom, dataPath);\n tmpl.container.append(fragdom);\n }\n }\n }\n };\n\n this.bind_event_tmpl = function (target, dataPath) {\n var _this = this, index = target.attr(\"data-ax-repeat-i\");\n var list = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(this.model);\n\n target.find('[data-ax-repeat-click]').unbind(\"click.axbinder\").bind(\"click.axbinder\", function (e) {\n var target = ax5.util.findParentNode(e.target, function (el) {\n return el.getAttribute(\"data-ax-repeat-click\");\n });\n if (target) {\n var dom = $(target), value = dom.attr(\"data-ax-repeat-click\"), repeat_path = dom.attr(\"data-ax-repeat-path\");\n\n var that = {\n el : target,\n jquery : dom,\n tagname : target.tagName.toLowerCase(),\n value : value,\n repeat_path: dataPath,\n item : list[index],\n item_index : index,\n item_path : dataPath + \"[\" + index + \"]\"\n };\n _this.click(dataPath, that);\n }\n });\n\n // apply data value to els\n target.find('[data-ax-item-path]').each(function () {\n var\n dom = $(this),\n item_path = dom.attr(\"data-ax-item-path\"),\n mix_path = get_mix_path(dataPath, index, item_path),\n val,\n this_type = (this.type || \"\").toLowerCase();\n\n try {\n val = (Function(\"\", \"return this.\" + mix_path + \";\")).call(_this.model);\n } catch (e) {\n /**\n * onerror를 선언 한 경우에만 에러 출력\n * */\n if (_this.onerror) _this.onerror(\"not found target [model.\" + mix_path + \"]\");\n }\n //if (typeof val !== \"undefined\") _this.set_els_value(this, this.tagName.toLowerCase(), this_type, val, mix_path);\n _this.set_els_value(this, this.tagName.toLowerCase(), this_type, val || \"\", mix_path);\n });\n\n // binding event to els\n target.find('[data-ax-item-path]').unbind(\"change.axbinder\").bind(\"change.axbinder\", function (e) {\n var\n i,\n hasItem = false,\n checked,\n new_value = [],\n this_type = (this.type || \"\").toLowerCase(),\n dom = $(e.target),\n item_path = dom.attr(\"data-ax-item-path\"),\n mix_path = get_mix_path(dataPath, index, item_path),\n origin_value = (Function(\"\", \"return this.\" + mix_path + \";\")).call(_this.model),\n value_type = get_type(origin_value),\n setAllow = true\n ;\n\n if (value_type == \"object\" || value_type == \"array\") {\n setAllow = false;\n }\n\n if (this_type == \"checkbox\") {\n if (target.find('[data-ax-item-path=\"' + item_path + '\"]').length > 1) {\n if (get_type(origin_value) != \"array\") {\n if (typeof origin_value === \"undefined\" || origin_value == \"\") origin_value = [];\n else origin_value = [].concat(origin_value);\n }\n i = origin_value.length, hasItem = false, checked = this.checked;\n while (i--) {\n if (origin_value[i] == this.value) {\n hasItem = true;\n }\n }\n\n if (checked) {\n if (!hasItem) origin_value.push(this.value);\n }\n else {\n i = origin_value.length;\n while (i--) {\n if (origin_value[i] == this.value) {\n //hasItemIndex = i;\n }\n else {\n new_value.push(origin_value[i]);\n }\n }\n origin_value = new_value;\n }\n }\n else {\n origin_value = (this.checked) ? this.value : \"\";\n }\n\n (Function(\"val\", \"this.\" + mix_path + \" = val;\")).call(_this.model, origin_value);\n _this.change(mix_path, {\n el: this, jquery: dom, tagname: this.tagName.toLowerCase(), value: origin_value\n });\n }\n else {\n if (setAllow) {\n (Function(\"val\", \"this.\" + mix_path + \" = val;\")).call(_this.model, this.value);\n _this.change(mix_path, {\n el: this, jquery: dom, tagname: this.tagName.toLowerCase(), value: this.value\n });\n }\n }\n\n dom.data(\"changedTime\", (new Date()).getTime());\n });\n target.find('[data-ax-item-path]').unbind(\"blur.axbinder\").bind(\"blur.axbinder\", function (e) {\n var dom = $(e.target);\n if (typeof dom.data(\"changedTime\") == \"undefined\" || dom.data(\"changedTime\") < (new Date()).getTime() - 10) dom.trigger(\"change\");\n });\n };\n\n /**\n * @method ax5binder.focus\n * @param dataPath\n * @returns {ax5binder}\n */\n this.focus = function (dataPath) {\n this.view_target.find('[data-ax-path=\"' + (dataPath) + '\"]').focus();\n //this.view_target.find('[data-ax-item-path=\"' + get_real_path(dataPath) + '\"]').focus();\n return this;\n };\n\n /**\n * @method ax5binder.validate\n * @returns {*}\n * @example\n * ```html\n * \n * ```\n * ```js\n * var rs = myModel.validate(), _s;\n * console.log(rs); // 결과를 체크 해보세요\n * if(rs.error) {\n * _s = rs.error[0].jquery.attr(\"title\");\n * alert(\"\" + _s + \"(은)는 필수 입력사항입니다.\" + _s + \"(을)를 입력하세요\");\n * rs.error[0].el.focus();\n * return;\n * }\n * ```\n */\n this.validate = function () {\n var _this = this;\n var errors = [];\n this.view_target.find('[data-ax-path]').each(function () {\n var dom = $(this), \n dataPath = dom.attr(\"data-ax-path\"), \n is_validate = dom.attr(\"data-ax-validate\"),\n pattern = dom.attr(\"pattern\");\n \n if (is_validate) {\n var val, _val, is_error;\n\n val = (Function(\"\", \"return this\" + get_real_path(dataPath) + \";\")).call(_this.model);\n if (typeof val === \"undefined\") val = \"\";\n _val = val.toString();\n is_error = false;\n\n if (is_validate == \"required\" && _val.trim() == \"\") {\n is_error = true;\n }\n else if(is_validate == \"pattern\"){\n is_error = !(new RegExp(pattern)).test(_val);\n }\n else if(is_validate == \"email\"){\n is_error = !(/[a-z0-9._%+-]+@[a-z0-9.-]+\\.[a-z]{2,4}$/).test(_val);\n }\n else if (!(/\\D.?/g).test(is_validate) && _val.trim().length < is_validate.number()) {\n is_error = true;\n }\n\n if (is_error) {\n errors.push({\n type : is_validate,\n dataPath: dataPath,\n el : this,\n jquery : dom,\n value : val\n });\n }\n }\n });\n this.view_target.find('[data-ax-repeat-path]').each(function () {\n\n var dom = $(this),\n dataPath = dom.attr(\"data-ax-repeat-path\"),\n repeat_idx = dom.attr(\"data-ax-repeat-i\");\n\n dom.find('[data-ax-validate]').each(function () {\n var dom = $(this), is_validate = dom.attr(\"data-ax-validate\"), item_path = dom.attr(\"data-ax-item-path\");\n var val = (Function(\"\", \"return this\" + get_real_path(dataPath) + \"[\" + repeat_idx + \"].\" + item_path + \";\")).call(_this.model);\n if (typeof val === \"undefined\") val = \"\";\n var _val = val.toString();\n\n if (is_validate) {\n var is_error = false;\n if (is_validate == \"required\" && _val.trim() == \"\") {\n is_error = true;\n }\n else if(is_validate == \"pattern\"){\n is_error = !(new RegExp(pattern)).test(_val);\n }\n else if(is_validate == \"email\"){\n is_error = !(/[a-z0-9._%+-]+@[a-z0-9.-]+\\.[a-z]{2,4}$/).test(_val);\n }\n else if (!(/\\D.?/g).test(is_validate) && _val.trim().length < is_validate.number()) {\n is_error = true;\n }\n\n if (is_error) {\n errors.push({\n type : is_validate,\n dataPath: dataPath,\n el : this,\n jquery : dom,\n value : val\n });\n }\n }\n });\n });\n\n if (errors.length > 0) {\n return {\n error: errors\n }\n }\n else {\n return {};\n }\n\n };\n\n\n // 클래스 생성자\n this.main = (function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n }).apply(this, arguments);\n\n };\n return ax5binder;\n })());\n\n})();","// ax5.ui.autocomplete\n(function () {\n\n var UI = ax5.ui;\n var U = ax5.util;\n var AUTOCOMPLETE;\n\n UI.addClass({\n className: \"autocomplete\",\n version: \"1.3.66\"\n }, (function () {\n /**\n * @class ax5autocomplete\n * @classdesc\n * @author tom@axisj.com\n * @example\n * ```js\n * var options = [];\n * options.push({value: \"1\", text: \"string\"});\n * options.push({value: \"2\", text: \"number\"});\n * options.push({value: \"3\", text: \"substr\"});\n * options.push({value: \"4\", text: \"substring\"});\n * options.push({value: \"5\", text: \"search\"});\n * options.push({value: \"6\", text: \"parseInt\"});\n * options.push({value: \"7\", text: \"toFixed\"});\n * options.push({value: \"8\", text: \"min\"});\n * options.push({value: \"9\", text: \"max\"});\n * options.push({value: \"10\", text: \"장기영\"});\n * options.push({value: \"11\", text: \"장서우\"});\n * options.push({value: \"12\", text: \"이영희\"});\n * options.push({value: \"13\", text: \"황인서\"});\n * options.push({value: \"14\", text: \"황세진\"});\n * options.push({value: \"15\", text: \"이서연\"});\n * options.push({value: \"16\", text: \"액시스제이\"});\n * options.push({value: \"17\", text: \"ax5\"});\n * options.push({value: \"18\", text: \"ax5grid\"});\n * options.push({value: \"19\", text: \"ax5combobox\"});\n * options.push({value: \"20\", text: \"ax5autocomplete\"});\n * options.push({value: \"21\", text: \"ax5binder\"});\n * options.push({value: \"22\", text: \"ax5select\"});\n * options.push({value: \"23\", text: \"ax5mask\"});\n * options.push({value: \"24\", text: \"ax5toast\"});\n * options.push({value: \"25\", text: \"ax5dialog\"});\n * options.push({value: \"26\", text: \"ax5modal\"});\n\n * var myUI = new ax5.ui.autocomplete({\n * theme: \"danger\",\n * removeIcon: ''\n * });\n * ```\n */\n var ax5autocomplete = function () {\n var\n self = this,\n cfg;\n\n this.instanceId = ax5.getGuid();\n this.config = {\n theme: 'default',\n animateTime: 250,\n removeIcon: 'X',\n lang: {\n noSelected: '',\n noOptions: 'no options',\n loading: 'Now Processing'\n },\n columnKeys: {\n optionValue: 'value',\n optionText: 'text',\n optionSelected: 'selected'\n }\n };\n\n this.queue = [];\n this.activeautocompleteOptionGroup = null;\n this.activeautocompleteQueueIndex = -1;\n this.openTimer = null;\n this.closeTimer = null;\n this.waitOptionsCallback = null;\n this.keyUpTimer = null;\n\n cfg = this.config;\n\n var $window = jQuery(window);\n var\n ctrlKeys = {\n \"18\": \"KEY_ALT\",\n //\"8\": \"KEY_BACKSPACE\",\n \"17\": \"KEY_CONTROL\",\n \"46\": \"KEY_DELETE\",\n \"40\": \"KEY_DOWN\",\n \"35\": \"KEY_END\",\n \"187\": \"KEY_EQUAL\",\n //\"27\": \"KEY_ESC\",\n \"36\": \"KEY_HOME\",\n \"45\": \"KEY_INSERT\",\n \"37\": \"KEY_LEFT\",\n \"189\": \"KEY_MINUS\",\n \"34\": \"KEY_PAGEDOWN\",\n \"33\": \"KEY_PAGEUP\",\n // \"190\": \"KEY_PERIOD\",\n //\"13\": \"KEY_RETURN\",\n \"39\": \"KEY_RIGHT\",\n \"16\": \"KEY_SHIFT\",\n // \"32\": \"KEY_SPACE\",\n \"9\": \"KEY_TAB\",\n \"38\": \"KEY_UP\",\n \"91\": \"KEY_WINDOW\"\n //\"107\" : \"NUMPAD_ADD\",\n //\"194\" : \"NUMPAD_COMMA\",\n //\"110\" : \"NUMPAD_DECIMAL\",\n //\"111\" : \"NUMPAD_DIVIDE\",\n //\"12\" : \"NUMPAD_EQUAL\",\n //\"106\" : \"NUMPAD_MULTIPLY\",\n //\"109\" : \"NUMPAD_SUBTRACT\"\n },\n onStateChanged = function (item, that) {\n if (item && item.onStateChanged) {\n item.onStateChanged.call(that, that);\n }\n else if (this.onStateChanged) {\n this.onStateChanged.call(that, that);\n }\n\n if (that.state == \"changeValue\") {\n if (item && item.onChange) {\n item.onChange.call(that, that);\n }\n else if (this.onChange) {\n this.onChange.call(that, that);\n }\n }\n\n item = null;\n that = null;\n return true;\n },\n alignAutocompleteDisplay = function () {\n var i = this.queue.length, w;\n\n while (i--) {\n var item = this.queue[i];\n if (item.$display) {\n w = Math.max(item.$select.outerWidth(), U.number(item.minWidth));\n item.$display.css({\n \"min-width\": w\n });\n if (item.reset) {\n item.$display.find(\".addon-icon-reset\").css({\n \"line-height\": this.queue[i].$display.height() + \"px\"\n });\n }\n\n // 높이조절 처리\n if (item.multiple) {\n var displayTableHeightAdjust = (function () {\n return U.number(item.$display.css(\"border-top-width\")) + U.number(item.$display.css(\"border-bottom-width\"));\n }).call(this);\n item.$target.height('');\n item.$display.height('');\n\n var displayTableHeight = item.$displayTable.outerHeight();\n if (Math.abs(displayTableHeight - item.$target.height()) > displayTableHeightAdjust) {\n item.$target.css({height: displayTableHeight + displayTableHeightAdjust + 4});\n item.$display.css({height: displayTableHeight + displayTableHeightAdjust + 4});\n }\n }\n }\n }\n\n i = null;\n w = null;\n return this;\n },\n alignAutocompleteOptionGroup = function (append) {\n if (append && !this.activeautocompleteOptionGroup) return this;\n\n var item = this.queue[this.activeautocompleteQueueIndex],\n pos = {}, positionMargin = 0,\n dim = {}, pickerDim = {},\n pickerDirection;\n\n if (!item) return this;\n if (append) jQuery(document.body).append(this.activeautocompleteOptionGroup);\n\n pos = item.$target.offset();\n dim = {\n width: item.$target.outerWidth(),\n height: item.$target.outerHeight()\n };\n pickerDim = {\n winWidth: Math.max($window.width(), jQuery(document.body).width()),\n winHeight: Math.max($window.height(), jQuery(document.body).height()),\n width: this.activeautocompleteOptionGroup.outerWidth(),\n height: this.activeautocompleteOptionGroup.outerHeight()\n };\n\n // picker css(width, left, top) & direction 결정\n if (!item.direction || item.direction === \"\" || item.direction === \"auto\") {\n // set direction\n pickerDirection = \"top\";\n\n if (pos.top - pickerDim.height - positionMargin < 0) {\n pickerDirection = \"top\";\n } else if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n pickerDirection = \"bottom\";\n }\n } else {\n pickerDirection = item.direction;\n }\n\n if (append) {\n this.activeautocompleteOptionGroup\n .addClass(\"direction-\" + pickerDirection);\n }\n this.activeautocompleteOptionGroup\n .css((function () {\n if (pickerDirection == \"top\") {\n if (pos.top + dim.height + pickerDim.height + positionMargin > pickerDim.winHeight) {\n\n var newTop = pos.top + pickerDim.height;\n if (newTop + pickerDim.height + positionMargin > pickerDim.winHeight) {\n newTop = 0;\n }\n if (newTop < 0) {\n newTop = 0;\n }\n\n return {\n left: pos.left,\n top: newTop,\n width: dim.width\n }\n }\n return {\n left: pos.left,\n top: pos.top + dim.height + 1,\n width: dim.width\n }\n }\n else if (pickerDirection == \"bottom\") {\n return {\n left: pos.left,\n top: pos.top - pickerDim.height - 1,\n width: dim.width\n }\n }\n }).call(this));\n },\n onBodyClick = function (e, target) {\n if (!this.activeautocompleteOptionGroup) return this;\n\n var\n item = this.queue[this.activeautocompleteQueueIndex],\n clickEl = \"display\"\n ;\n\n target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-option-value\")) {\n clickEl = \"optionItem\";\n return true;\n }\n else if (item.$target.get(0) == target) {\n clickEl = \"display\";\n return true;\n }\n });\n\n if (!target) {\n this.close();\n return this;\n }\n else if (clickEl === \"optionItem\") {\n setSelected.call(this, item.id, {\n optionIndex: {\n index: target.getAttribute(\"data-option-index\")\n }\n }, undefined, \"optionItemClick\");\n alignAutocompleteDisplay.call(this);\n alignAutocompleteOptionGroup.call(this);\n if (!item.multiple) {\n this.close();\n }\n }\n else {\n\n }\n\n return this;\n },\n\n getLabel = function (queIdx) {\n var item = this.queue[queIdx];\n\n // 템플릿에 전달 해야할 데이터 선언\n var data = {};\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5autocomplete-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n data.selected = item.selected;\n data.hasSelected = (data.selected && data.selected.length > 0);\n data.removeIcon = item.removeIcon;\n\n return AUTOCOMPLETE.tmpl.get.call(this, \"label\", data, item.columnKeys);\n },\n syncLabel = function (queIdx) {\n var item = this.queue[queIdx];\n\n if (!item.multiple && item.selected && item.selected.length > 0) {\n item.selected = [].concat(item.selected[item.selected.length - 1]);\n }\n\n item.selected.forEach(function (n, nindex) {\n n[\"@index\"] = nindex;\n });\n\n item.$select.html(AUTOCOMPLETE.tmpl.get.call(this, \"formSelectOptions\", {\n selected: item.selected\n }, item.columnKeys));\n },\n printLabel = function (queIdx) {\n var item = this.queue[queIdx];\n\n item.$displayLabel.find('[data-ax5autocomplete-selected-label]').remove();\n item.$displayLabelInput.before(getLabel.call(this, queIdx));\n },\n focusLabel = function (queIdx) {\n if (this.queue[queIdx].disabled) return this;\n\n this.queue[queIdx].$displayLabel.trigger(\"focus\");\n this.queue[queIdx].$displayLabelInput.focus();\n },\n clearLabel = function (queIdx) {\n this.queue[queIdx].$displayLabelInput.val('');\n },\n blurLabel = function (queIdx) {\n this.queue[queIdx].$displayLabel.trigger(\"blur\");\n },\n onSearch = function (queIdx, searchWord) {\n if (this.activeautocompleteQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n var regExp = /[\\{\\}\\[\\]\\/?.,;:|\\)*~`!^\\-_+<>@\\#$%&\\\\\\=\\(\\'\\\"]/gi;\n searchWord = searchWord.replace(regExp, \"\");\n\n this.queue[queIdx].waitOptions = true;\n this.queue[queIdx].onSearch.call({\n self: this,\n item: this.queue[queIdx],\n searchWord: searchWord\n }, (function (O) {\n\n var data = {};\n var item = this.queue[this.activeautocompleteQueueIndex];\n if (!item) return false;\n\n /// 현재 selected 검증후 처리\n (function (item, O) {\n var optionsMap = {};\n O.options.forEach(function (_O, _OIndex) {\n _O[\"@index\"] = _OIndex;\n _O[\"@findex\"] = _OIndex;\n optionsMap[_O[item.columnKeys.optionValue]] = _O;\n });\n if (U.isArray(item.selected)) {\n item.selected.forEach(function (_O) {\n if (optionsMap[_O[item.columnKeys.optionValue]]) {\n O.options[optionsMap[_O[item.columnKeys.optionValue]][\"@index\"]][item.columnKeys.optionSelected] = true;\n }\n });\n }\n })(item, O);\n\n item.options = O.options;\n\n alignAutocompleteDisplay.call(this);\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5autocomplete-option-group-\" + item.size;\n data.multiple = item.multiple;\n data.lang = item.lang;\n data.options = item.options;\n this.activeautocompleteOptionGroup.find('[data-els=\"content\"]').html(jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"options\", data, item.columnKeys)));\n\n focusWord.call(this, this.activeautocompleteQueueIndex, searchWord);\n alignAutocompleteOptionGroup.call(this);\n\n setTimeout((function () {\n alignAutocompleteOptionGroup.call(this);\n }).bind(this));\n\n\n }).bind(this));\n },\n focusWord = function (queIdx, searchWord) {\n if (this.activeautocompleteQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n var collect_options = [], i = -1, l = this.queue[queIdx].options.length - 1, n;\n if (searchWord != \"\") {\n while (l - i++) {\n n = this.queue[queIdx].options[i];\n\n if (('' + n.text).toLowerCase() == searchWord.toLowerCase()) {\n collect_options = [{'@findex': n['@findex'], optionsSort: 0}];\n break;\n } else {\n var sort = ('' + n.text).toLowerCase().search(searchWord.toLowerCase());\n if (sort > -1) {\n collect_options.push({'@findex': n['@findex'], optionsSort: sort});\n if (collect_options.length > 2) break;\n }\n sort = null;\n }\n }\n collect_options.sort(function (a, b) {\n return a.optionsSort - b.optionsSort;\n });\n }\n\n if (collect_options && collect_options.length > 0) {\n focusMove.call(this, queIdx, undefined, collect_options[0]['@findex']);\n } else {\n focusClear.call(this, queIdx);\n }\n },\n focusClear = function (queIdx) {\n if (this.activeautocompleteOptionGroup) {\n this.activeautocompleteOptionGroup\n .find('[data-option-focus-index]')\n .removeClass(\"hover\")\n .removeAttr(\"data-option-selected\");\n }\n\n this.queue[queIdx].optionFocusIndex = -1;\n },\n focusMove = function (queIdx, direction, findex) {\n var _focusIndex,\n _prevFocusIndex,\n focusOptionEl,\n optionGroupScrollContainer;\n var item = this.queue[queIdx];\n\n if (this.activeautocompleteOptionGroup && item.options && item.options.length > 0) {\n\n if (typeof findex !== \"undefined\") {\n _focusIndex = findex\n }\n else {\n _prevFocusIndex = (item.optionFocusIndex == -1) ? item.optionSelectedIndex || -1 : item.optionFocusIndex;\n if (_prevFocusIndex == -1) {\n _focusIndex = 0;\n //_focusIndex = (direction > 0) ? 0 : item.optionItemLength - 1; // 맨 끝으로 보낼것인가 말 것인가.\n }\n else {\n _focusIndex = _prevFocusIndex + direction;\n if (_focusIndex < 0) _focusIndex = 0;\n else if (_focusIndex > item.optionItemLength - 1) _focusIndex = item.optionItemLength - 1;\n }\n }\n\n item.optionFocusIndex = _focusIndex;\n\n // 포커스 인덱스가 hide아이템을 만나면 hide 아이템이 안나올 때까지 루프를 순회 합니다.\n if (item.options[_focusIndex] && item.options[_focusIndex].hide) { // 옵션이 없는 값이 선택된 경우\n if (typeof direction === \"undefined\") {\n return this;\n }\n else {\n var isStrop = false;\n while (item.options[_focusIndex].hide) {\n _focusIndex = _focusIndex + direction;\n if (_focusIndex < 0) {\n _focusIndex = 0;\n break;\n }\n else if (_focusIndex > item.optionItemLength - 1) {\n _focusIndex = item.optionItemLength - 1;\n break;\n }\n }\n }\n }\n\n if (typeof _focusIndex !== \"undefined\") {\n this.activeautocompleteOptionGroup\n .find('[data-option-focus-index]')\n .removeClass(\"hover\");\n\n focusOptionEl = this.activeautocompleteOptionGroup\n .find('[data-option-focus-index=\"' + _focusIndex + '\"]')\n .addClass(\"hover\");\n\n optionGroupScrollContainer = this.activeautocompleteOptionGroup.find('[data-els=\"content\"]');\n\n if (focusOptionEl.get(0)) {\n let focusOptionElHeight = focusOptionEl.outerHeight(),\n optionGroupScrollContainerHeight = optionGroupScrollContainer.innerHeight(),\n optionGroupScrollContainerScrollTop = optionGroupScrollContainer.scrollTop(),\n focusOptionElTop = focusOptionEl.position().top + optionGroupScrollContainer.scrollTop();\n\n if (optionGroupScrollContainerHeight + optionGroupScrollContainerScrollTop < focusOptionElTop + focusOptionElHeight) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop + focusOptionElHeight - optionGroupScrollContainerHeight);\n }\n else if (optionGroupScrollContainerScrollTop > focusOptionElTop) {\n optionGroupScrollContainer.scrollTop(focusOptionElTop);\n }\n // optionGroup scroll check\n\n if (typeof direction !== \"undefined\") {\n item.$displayLabelInput.val(item.options[_focusIndex].text);\n }\n }\n }\n }\n },\n getQueIdx = function (boundID) {\n if (boundID instanceof jQuery) {\n boundID = boundID.data(\"data-ax5autocomplete-id\");\n } else if (!U.isString(boundID)) {\n boundID = jQuery(boundID).data(\"data-ax5autocomplete-id\");\n }\n if (!U.isString(boundID)) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"getQueIdx\"));\n return;\n }\n return U.search(this.queue, function () {\n return this.id == boundID;\n });\n },\n getSelected = function (_item, o, selected) {\n if (typeof selected === \"undefined\") {\n return (_item.multiple) ? !o : true;\n } else {\n return selected;\n }\n },\n clearSelected = function (queIdx) {\n this.queue[queIdx].options.forEach(function (n) {\n if (n.optgroup) {\n n.options.forEach(function (nn) {\n nn.selected = false;\n });\n }\n else {\n n.selected = false;\n }\n });\n\n this.queue[queIdx].selected = [];\n this.queue[queIdx].$select.html(AUTOCOMPLETE.tmpl.get.call(this, \"formSelectOptions\", {\n selected: this.queue[queIdx].selected\n }, this.queue[queIdx].columnKeys));\n },\n setSelected = (function () {\n var processor = {\n 'selectedIndex': function (queIdx, value, selected, setValueType) {\n\n },\n 'removeSelectedIndex': function (queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx], addOptions = {};\n var newSelectedArray = [], optionIndex = 0;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i]['@index'] != value.removeSelectedIndex.index) {\n addOptions = {'@index': optionIndex, '@findex': optionIndex};\n addOptions[item.columnKeys.optionValue] = item.selected[i][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.selected[i][item.columnKeys.optionText];\n newSelectedArray.push(addOptions);\n optionIndex++;\n }\n }\n item.selected = newSelectedArray;\n },\n 'optionIndex': function (queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx], addOptions = {};\n var optionIndex = item.selected.length;\n var pushOk = true;\n\n addOptions = {\n '@index': optionIndex, '@findex': optionIndex\n };\n addOptions[item.columnKeys.optionValue] = item.options[value.optionIndex.index][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.options[value.optionIndex.index][item.columnKeys.optionText];\n\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][item.columnKeys.optionValue] == addOptions[item.columnKeys.optionValue]) {\n pushOk = false;\n }\n }\n if (pushOk) item.selected.push(addOptions);\n },\n 'arr': function (queIdx, values, selected, setValueType) {\n values.forEach(function (value) {\n if (U.isString(value) || U.isNumber(value)) {\n processor.text.call(self, queIdx, value, selected, \"justSetValue\");\n }\n else {\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(self, queIdx, value, selected, \"justSetValue\");\n break;\n }\n }\n }\n });\n },\n 'value': function (queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx];\n var addOptions;\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionValue] == value.value[item.columnKeys.optionValue];\n });\n\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected]\n = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n\n if (item.options[optionIndex][item.columnKeys.optionSelected]) {\n var appendOk = true;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionValue] == item.options[optionIndex][cfg.columnKeys.optionValue]) {\n appendOk = false;\n break;\n }\n }\n if (appendOk) {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = item.options[optionIndex][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.options[optionIndex][item.columnKeys.optionText];\n item.selected.push(addOptions);\n }\n }\n else {\n var newSelectedArray = [];\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionValue] == item.options[optionIndex][cfg.columnKeys.optionValue]) {\n\n }\n else {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = item.selected[i][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.selected[i][item.columnKeys.optionText];\n newSelectedArray.push(addOptions);\n }\n }\n item.selected = newSelectedArray;\n }\n\n }\n else {\n // 새로운 값 추가\n var appendOk = true;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionValue] == value.value[cfg.columnKeys.optionValue]) {\n appendOk = false;\n break;\n }\n }\n\n if (appendOk) {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = value.value[cfg.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = value.value[cfg.columnKeys.optionText];\n item.selected.push(addOptions);\n }\n }\n },\n 'text': function (queIdx, value, selected, setValueType) {\n var item = this.queue[queIdx];\n var addOptions;\n var optionIndex = U.search(item.options, function () {\n return this[item.columnKeys.optionText] == value;\n });\n\n if (optionIndex > -1) {\n item.options[optionIndex][item.columnKeys.optionSelected]\n = getSelected(item, item.options[optionIndex][item.columnKeys.optionSelected], selected);\n\n if (item.options[optionIndex][item.columnKeys.optionSelected]) {\n var appendOk = true;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionText] == item.options[optionIndex][cfg.columnKeys.optionText]) {\n appendOk = false;\n break;\n }\n }\n if (appendOk) {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = item.options[optionIndex][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.options[optionIndex][item.columnKeys.optionText];\n item.selected.push(addOptions);\n }\n }\n else {\n var newSelectedArray = [];\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionText] == item.options[optionIndex][cfg.columnKeys.optionText]) {\n\n }\n else {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = item.selected[i][item.columnKeys.optionValue];\n addOptions[item.columnKeys.optionText] = item.selected[i][item.columnKeys.optionText];\n newSelectedArray.push(addOptions);\n }\n }\n item.selected = newSelectedArray;\n }\n }\n else {\n // 새로운 값 추가\n var appendOk = true;\n for (var i = 0; i < item.selected.length; i++) {\n if (item.selected[i][cfg.columnKeys.optionText] == value) {\n appendOk = false;\n break;\n }\n }\n\n if (appendOk) {\n addOptions = {};\n addOptions[item.columnKeys.optionValue] = value;\n addOptions[item.columnKeys.optionText] = value;\n item.selected.push(addOptions);\n }\n }\n },\n 'clear': function (queIdx) {\n clearSelected.call(this, queIdx);\n focusClear.call(this, queIdx);\n\n if (this.activeautocompleteOptionGroup) {\n this.activeautocompleteOptionGroup\n .find('[data-option-index]')\n .attr(\"data-option-Selected\", \"false\");\n }\n this.queue[queIdx].optionSelectedIndex = -1;\n }\n };\n return function (boundID, value, selected, _option) {\n\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n\n if (typeof value == \"undefined\") {\n throw \"error not found value\";\n }\n else if (U.isArray(value)) {\n processor.clear.call(this, queIdx);\n processor.arr.call(this, queIdx, (this.queue[queIdx].multiple || value.length == 0) ? value : [value[value.length - 1]], selected);\n }\n else if (U.isString(value) || U.isNumber(value)) {\n if (typeof value !== \"undefined\" && value !== null && !this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n processor.text.call(this, queIdx, value, selected);\n }\n else {\n if (value === null) {\n processor.clear.call(this, queIdx);\n }\n else {\n if (!this.queue[queIdx].multiple) {\n clearSelected.call(this, queIdx);\n }\n for (var key in processor) {\n if (value[key]) {\n processor[key].call(this, queIdx, value, selected);\n break;\n }\n }\n }\n }\n\n syncLabel.call(this, queIdx);\n printLabel.call(this, queIdx);\n focusLabel.call(this, queIdx);\n alignAutocompleteOptionGroup.call(this);\n\n if (typeof value !== \"undefined\") {\n if (_option && !_option.noStateChange) {\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n item: this.queue[queIdx],\n state: \"changeValue\",\n value: this.queue[queIdx].selected\n });\n }\n }\n\n boundID = null;\n return this;\n };\n })();\n\n /// private end\n\n /**\n * Preferences of autocomplete UI\n * @method ax5autocomplete.setConfig\n * @param {Object} config - 클래스 속성값\n * @returns {ax5autocomplete}\n * @example\n * ```\n * ```\n */\n this.init = function () {\n this.onStateChanged = cfg.onStateChanged;\n this.onChange = cfg.onChange;\n jQuery(window).bind(\"resize.ax5autocomplete-display-\" + this.instanceId, (function () {\n alignAutocompleteDisplay.call(this);\n }).bind(this));\n };\n\n /**\n * bind autocomplete\n * @method ax5autocomplete.bind\n * @param {Object} item\n * @param {String} [item.id]\n * @param {String} [item.theme]\n * @param {Boolean} [item.multiple]\n * @param {Element} item.target\n * @returns {ax5autocomplete}\n */\n this.bind = function (item) {\n var bindAutocompleteTarget = (function () {\n var debouncedFocusWord = U.debounce(function (queIdx) {\n if (this.activeautocompleteQueueIndex == -1) return this; // 옵션박스가 닫힌상태이면 진행안함.\n onSearch.call(self, queIdx, this.queue[queIdx].$displayLabelInput.val());\n }, 150);\n\n var blurLabel = function (queIdx) {\n clearLabel.call(this, queIdx);\n };\n\n var autocompleteEvent = {\n 'click': function (queIdx, e) {\n var clickEl;\n var target = U.findParentNode(e.target, function (target) {\n if (target.getAttribute(\"data-ax5autocomplete-remove\")) {\n clickEl = \"optionItemRemove\";\n return true;\n }\n else if (target.getAttribute(\"data-selected-clear\")) {\n clickEl = \"clear\";\n return true;\n }\n });\n\n if (target) {\n if (clickEl === \"optionItemRemove\") {\n var removeIndex = target.getAttribute(\"data-ax5autocomplete-remove-index\");\n this.queue[queIdx].selected.splice(removeIndex, 1);\n syncLabel.call(this, queIdx);\n printLabel.call(this, queIdx);\n focusLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n alignAutocompleteOptionGroup.call(this);\n U.stopEvent(e);\n return this;\n } else if (clickEl === \"clear\") {\n setSelected.call(this, queIdx, {clear: true});\n alignAutocompleteDisplay.call(this);\n alignAutocompleteOptionGroup.call(this);\n }\n }\n else {\n if (self.activeautocompleteQueueIndex == queIdx) {\n if (this.queue[queIdx].optionFocusIndex == -1) { // 아이템에 포커스가 활성화 된 후, 마우스 이벤트 이면 무시\n self.close();\n }\n }\n else {\n focusLabel.call(this, queIdx);\n }\n }\n },\n 'keyUp': function (queIdx, e) {\n /// 약속된 키 이벤트가 발생하면 stopEvent를 통해 keyUp 이벤트가 발생되지 않도록 막아주는 센스\n if (e.which == ax5.info.eventKeys.ESC && self.activeautocompleteQueueIndex === -1) { // ESC키를 누르고 옵션그룹이 열려있지 않은 경우\n U.stopEvent(e);\n return this;\n }\n if (e.which == ax5.info.eventKeys.TAB) {\n // nothing\n\n this.close();\n return this;\n }\n if (self.activeautocompleteQueueIndex != queIdx) { // 닫힌 상태 인경우\n self.open(queIdx); // open and align\n }\n if (ctrlKeys[e.which]) {\n U.stopEvent(e);\n }\n else {\n // backspace 감지 하여 input 값이 없으면 스탑이벤트 처리 할 것\n if (e.which == ax5.info.eventKeys.BACKSPACE && this.queue[queIdx].$displayLabelInput.val() == \"\") {\n // 마지막 아이템을 제거.\n this.queue[queIdx].selected.pop();\n syncLabel.call(this, queIdx);\n printLabel.call(this, queIdx);\n focusLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n alignAutocompleteOptionGroup.call(this);\n U.stopEvent(e);\n } else {\n debouncedFocusWord.call(this, queIdx);\n }\n }\n },\n 'keyDown': function (queIdx, e) {\n if (e.which == ax5.info.eventKeys.ESC) {\n clearLabel.call(this, queIdx);\n this.close();\n U.stopEvent(e);\n }\n else if (e.which == ax5.info.eventKeys.RETURN) {\n var inputValue = this.queue[queIdx].$displayLabelInput.val();\n if(item.optionFocusIndex > -1) {\n setSelected.call(this, item.id, {\n optionIndex: {\n index: item.optionFocusIndex\n }\n }, undefined, \"optionItemClick\");\n }else if(inputValue != \"\"){\n setSelected.call(this, queIdx, inputValue, true);\n }\n clearLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n this.close();\n\n U.stopEvent(e);\n }\n else if (e.which == ax5.info.eventKeys.DOWN) {\n focusMove.call(this, queIdx, 1);\n U.stopEvent(e);\n }\n else if (e.which == ax5.info.eventKeys.UP) {\n focusMove.call(this, queIdx, -1);\n U.stopEvent(e);\n }\n },\n 'focus': function (queIdx, e) {\n // console.log(e);\n\n },\n 'blur': function (queIdx, e) {\n blurLabel.call(this, queIdx);\n U.stopEvent(e);\n },\n 'selectChange': function (queIdx, e) {\n setSelected.call(this, queIdx, {value: this.queue[queIdx].$select.val()}, true);\n }\n };\n\n return function (queIdx) {\n var item = this.queue[queIdx];\n var data = {};\n\n if (!item.$display) {\n /// 템플릿에 전달할 오브젝트 선언\n data.instanceId = this.instanceId;\n data.id = item.id;\n data.name = item.name;\n data.theme = item.theme;\n data.tabIndex = item.tabIndex;\n data.multiple = item.multiple;\n data.reset = item.reset;\n\n data.label = getLabel.call(this, queIdx);\n data.formSize = (function () {\n return (item.size) ? \"input-\" + item.size : \"\";\n })();\n\n item.$display = jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"autocompleteDisplay\", data, item.columnKeys));\n item.$displayTable = item.$display.find('[data-els=\"display-table\"]');\n item.$displayLabel = item.$display.find('[data-ax5autocomplete-display=\"label\"]');\n item.$displayLabelInput = item.$display.find('[data-ax5autocomplete-display=\"input\"]');\n\n if (item.$target.find(\"select\").get(0)) {\n item.$select = item.$target.find(\"select\");\n item.$select\n .attr(\"tabindex\", \"-1\")\n .attr(\"class\", \"form-control \" + data.formSize);\n\n if (data.name) {\n item.$select.attr(\"name\", \"name\");\n }\n item.$select.attr(\"multiple\", \"multiple\");\n }\n else {\n item.$select = jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"formSelect\", data, item.columnKeys));\n item.$target.append(item.$select);\n }\n\n item.$target.append(item.$display);\n\n }\n else {\n printLabel.call(this, queIdx);\n }\n\n alignAutocompleteDisplay.call(this);\n\n item.$display\n .unbind('click.ax5autocomplete')\n .bind('click.ax5autocomplete', autocompleteEvent.click.bind(this, queIdx));\n\n // autocomplete 태그에 대한 이벤트 감시\n\n item.$displayLabelInput\n .off(\"focus.ax5autocomplete\")\n .on(\"focus.ax5autocomplete\", autocompleteEvent.focus.bind(this, queIdx))\n .off(\"blur.ax5autocomplete\")\n .on(\"blur.ax5autocomplete\", autocompleteEvent.blur.bind(this, queIdx))\n .off(\"keydown.ax5autocomplete\")\n .on(\"keydown.ax5autocomplete\", autocompleteEvent.keyUp.bind(this, queIdx))\n .off(\"keyup.ax5autocomplete\")\n .on(\"keyup.ax5autocomplete\", autocompleteEvent.keyDown.bind(this, queIdx));\n\n // select 태그에 대한 change 이벤트 감시\n\n item.$select\n .unbind('change.ax5autocomplete')\n .bind('change.ax5autocomplete', autocompleteEvent.selectChange.bind(this, queIdx));\n\n data = null;\n item = null;\n queIdx = null;\n return this;\n };\n })();\n\n var\n autocompleteConfig = {},\n queIdx;\n\n item = jQuery.extend(true, autocompleteConfig, cfg, item);\n if (!item.target) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"401\", \"bind\"));\n return this;\n }\n\n item.$target = jQuery(item.target);\n\n if (!item.id) item.id = item.$target.data(\"data-ax5autocomplete-id\");\n if (!item.id) {\n item.id = 'ax5autocomplete-' + ax5.getGuid();\n item.$target.data(\"data-ax5autocomplete-id\", item.id);\n }\n item.name = item.$target.attr(\"data-ax5autocomplete\");\n\n item.options = [];\n item.selected = [];\n\n // target attribute data\n (function (data) {\n if (U.isObject(data) && !data.error) {\n item = jQuery.extend(true, item, data);\n }\n })(U.parseJson(item.$target.attr(\"data-ax5autocomplete-config\"), true));\n\n queIdx = U.search(this.queue, function () {\n return this.id == item.id;\n });\n\n if (queIdx === -1) {\n this.queue.push(item);\n bindAutocompleteTarget.call(this, this.queue.length - 1);\n }\n else {\n this.queue[queIdx] = jQuery.extend(true, {}, this.queue[queIdx], item);\n bindAutocompleteTarget.call(this, queIdx);\n }\n\n autocompleteConfig = null;\n queIdx = null;\n return this;\n };\n\n /**\n * open the optionBox of autocomplete\n * @method ax5autocomplete.open\n * @param {(String|Number|Element)} boundID\n * @param {Number} [tryCount]\n * @returns {ax5autocomplete}\n */\n this.open = (function () {\n\n return function (boundID, tryCount) {\n this.waitOptionsCallback = null;\n\n /**\n * open autocomplete from the outside\n */\n var queIdx = (U.isNumber(boundID)) ? boundID : getQueIdx.call(this, boundID);\n var item = this.queue[queIdx];\n var data = {}, focusTop, selectedOptionEl;\n\n if (item.$display.attr(\"disabled\")) return this;\n\n if (this.openTimer) clearTimeout(this.openTimer);\n if (this.activeautocompleteOptionGroup) {\n if (this.activeautocompleteQueueIndex == queIdx) {\n return this;\n }\n\n if (tryCount > 2) return this;\n this.close();\n this.openTimer = setTimeout((function () {\n this.open(queIdx, (tryCount || 0) + 1);\n }).bind(this), cfg.animateTime);\n\n return this;\n }\n\n item.optionFocusIndex = -1; // optionGroup이 열리면 포커스 인덱스 초기화 -1로\n if (item.selected && item.selected.length > 0) {\n item.optionSelectedIndex = item.selected[0][\"@findex\"];\n }\n\n /// 템플릿에 전달할 오브젝트 선언\n data.id = item.id;\n data.theme = item.theme;\n data.size = \"ax5autocomplete-option-group-\" + item.size;\n data.multiple = item.multiple;\n\n data.lang = item.lang;\n item.$display.attr(\"data-autocomplete-option-group-opened\", \"true\");\n\n data.waitOptions = true;\n data.options = [];\n\n this.activeautocompleteOptionGroup = jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"optionGroup\", data, item.columnKeys));\n this.activeautocompleteOptionGroup.find('[data-els=\"content\"]').html(jQuery(AUTOCOMPLETE.tmpl.get.call(this, \"options\", data, item.columnKeys)));\n this.activeautocompleteQueueIndex = queIdx;\n\n alignAutocompleteOptionGroup.call(this, \"append\"); // alignAutocompleteOptionGroup 에서 body append\n jQuery(window).bind(\"resize.ax5autocomplete-\" + this.instanceId, (function () {\n alignAutocompleteOptionGroup.call(this);\n }).bind(this));\n\n\n if (item.selected && item.selected.length > 0) {\n selectedOptionEl = this.activeautocompleteOptionGroup.find('[data-option-index=\"' + item.selected[0][\"@index\"] + '\"]');\n if (selectedOptionEl.get(0)) {\n focusTop = selectedOptionEl.position().top - this.activeautocompleteOptionGroup.height() / 3;\n this.activeautocompleteOptionGroup.find('[data-els=\"content\"]')\n .stop().animate({scrollTop: focusTop}, item.animateTime, 'swing', function () {\n });\n }\n }\n\n jQuery(window).bind(\"click.ax5autocomplete-\" + this.instanceId, (function (e) {\n e = e || window.event;\n onBodyClick.call(this, e);\n U.stopEvent(e);\n }).bind(this));\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"open\",\n item: item\n });\n\n data = null;\n focusTop = null;\n selectedOptionEl = null;\n return this;\n }\n })();\n\n /**\n * @method ax5autocomplete.setValue\n * @param {(jQueryObject|Element|Number)} _boundID\n * @param {(String|Array)} _value\n * @return {ax5autocomplete}\n * @example\n * ```js\n * myAutocomplete.setValue($('[data-ax5autocomplete=\"autocomplete1\"]'), {value:\"test\", text:\"test\"});\n * myAutocomplete.setValue($('[data-ax5autocomplete=\"autocomplete1\"]'), [{value:\"test1\", text:\"test1\"}, {value:\"test2\", text:\"test2\"}]);\n * myAutocomplete.setValue($('[data-ax5autocomplete=\"autocomplete1\"]'), null);\n * ```\n */\n this.setValue = function (_boundID, _value) {\n var queIdx = (U.isNumber(_boundID)) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n\n clearSelected.call(this, queIdx);\n\n if (U.isArray(_value)) {\n var _values = U.map(_value, function () {\n return {value: this};\n });\n setSelected.call(this, queIdx, _values, true, {noStateChange: true});\n }\n else if (U.isObject(_value)) {\n setSelected.call(this, queIdx, {value: _value}, true, {noStateChange: true});\n } else {\n printLabel.call(this, queIdx);\n }\n\n blurLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n\n return this;\n };\n\n /**\n * @method ax5autocomplete.setText\n * @param {(jQueryObject|Element|Number)} _boundID\n * @param {(String|Array)} _text\n * @returns {ax5autocomplete}\n * @example\n * ```js\n * myAutocomplete.setText($('[data-ax5autocomplete=\"autocomplete1\"]'), \"string\");\n * myAutocomplete.setText($('[data-ax5autocomplete=\"autocomplete1\"]'), [\"substring\", \"search\"]);\n * ```\n */\n this.setText = function (_boundID, _text) {\n var queIdx = (U.isNumber(_boundID)) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n this.queue[queIdx].selected = [];\n clearSelected.call(this, queIdx);\n setSelected.call(this, queIdx, _text, true, {noStateChange: true});\n blurLabel.call(this, queIdx);\n alignAutocompleteDisplay.call(this);\n\n return this;\n };\n\n /**\n * @method ax5autocomplete.getSelectedOption\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {Array}\n */\n this.getSelectedOption = function (_boundID) {\n var queIdx = (U.isNumber(_boundID)) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n return U.deepCopy(this.queue[queIdx].selected);\n };\n\n /**\n * @method ax5autocomplete.close\n * @returns {ax5autocomplete}\n */\n this.close = function (item) {\n if (this.closeTimer) clearTimeout(this.closeTimer);\n if (!this.activeautocompleteOptionGroup) return this;\n\n item = this.queue[this.activeautocompleteQueueIndex];\n item.optionFocusIndex = -1;\n item.$display.removeAttr(\"data-autocomplete-option-group-opened\").trigger(\"focus\");\n\n this.activeautocompleteOptionGroup.addClass(\"destroy\");\n\n jQuery(window)\n .unbind(\"resize.ax5autocomplete-\" + this.instanceId)\n .unbind(\"click.ax5autocomplete-\" + this.instanceId)\n .unbind(\"keyup.ax5autocomplete-\" + this.instanceId);\n\n this.closeTimer = setTimeout((function () {\n if (this.activeautocompleteOptionGroup) this.activeautocompleteOptionGroup.remove();\n this.activeautocompleteOptionGroup = null;\n this.activeautocompleteQueueIndex = -1;\n\n onStateChanged.call(this, item, {\n self: this,\n state: \"close\"\n });\n\n }).bind(this), cfg.animateTime);\n this.waitOptionsCallback = null;\n return this;\n };\n\n /**\n * @method ax5autocomplete.blur\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5autocomplete}\n */\n this.blur = function (_boundID) {\n var queIdx = (U.isNumber(_boundID)) ? _boundID : getQueIdx.call(this, _boundID);\n if (queIdx === -1) {\n console.log(ax5.info.getError(\"ax5autocomplete\", \"402\", \"val\"));\n return;\n }\n\n blurLabel.call(this, queIdx);\n return this;\n };\n\n /**\n * @method ax5autocomplete.enable\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5autocomplete}\n */\n this.enable = function (_boundID) {\n var queIdx = getQueIdx.call(this, _boundID);\n\n if (typeof queIdx !== \"undefined\") {\n this.queue[queIdx].disable = false;\n if (this.queue[queIdx].$display[0]) {\n this.queue[queIdx].$display.removeAttr(\"disabled\");\n this.queue[queIdx].$displayLabelInput.removeAttr(\"disabled\");\n }\n if (this.queue[queIdx].$select[0]) {\n this.queue[queIdx].$select.removeAttr(\"disabled\");\n\n }\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"enable\"\n });\n }\n\n return this;\n };\n\n /**\n * @method ax5autocomplete.disable\n * @param {(jQueryObject|Element|Number)} _boundID\n * @returns {ax5autocomplete}\n */\n this.disable = function (_boundID) {\n var queIdx = getQueIdx.call(this, _boundID);\n\n if (typeof queIdx !== \"undefined\") {\n this.queue[queIdx].disable = true;\n if (this.queue[queIdx].$display[0]) {\n this.queue[queIdx].$display.attr(\"disabled\", \"disabled\");\n this.queue[queIdx].$displayLabelInput.attr(\"disabled\", \"disabled\");\n }\n if (this.queue[queIdx].$select[0]) {\n this.queue[queIdx].$select.attr(\"disabled\", \"disabled\");\n }\n\n onStateChanged.call(this, this.queue[queIdx], {\n self: this,\n state: \"disable\"\n });\n }\n\n return this;\n };\n\n /**\n * @method ax5autocomplete.align\n */\n this.align = function () {\n alignAutocompleteDisplay.call(this);\n return this;\n };\n\n // 클래스 생성자\n this.main = (function () {\n if (arguments && U.isObject(arguments[0])) {\n this.setConfig(arguments[0]);\n }\n else {\n this.init();\n }\n }).apply(this, arguments);\n };\n return ax5autocomplete;\n })());\n\n AUTOCOMPLETE = ax5.ui.autocomplete;\n})();\n\n/**\n * autocomplete jquery extends\n * @namespace jQueryExtends\n */\n\n/**\n * @method jQueryExtends.ax5autocomplete\n * @param {String} methodName\n * @param [arguments]\n * @param [arguments]\n * @example\n * ```html\n * \n * \n * ```\n */\nax5.ui.autocomplete_instance = new ax5.ui.autocomplete();\njQuery.fn.ax5autocomplete = (function () {\n return function (config) {\n if (ax5.util.isString(arguments[0])) {\n var methodName = arguments[0];\n\n switch (methodName) {\n case \"open\":\n return ax5.ui.autocomplete_instance.open(this);\n break;\n case \"close\":\n return ax5.ui.autocomplete_instance.close(this);\n break;\n case \"setValue\":\n return ax5.ui.autocomplete_instance.setValue(this, arguments[1], arguments[2], arguments[3], arguments[4] || \"justSetValue\");\n break;\n case \"setText\":\n return ax5.ui.autocomplete_instance.setText(this, arguments[1], arguments[2], arguments[3], arguments[4] || \"justSetValue\");\n break;\n case \"getSelectedOption\":\n return ax5.ui.autocomplete_instance.getSelectedOption(this);\n break;\n case \"enable\":\n return ax5.ui.autocomplete_instance.enable(this);\n break;\n case \"disable\":\n return ax5.ui.autocomplete_instance.disable(this);\n break;\n case \"blur\":\n return ax5.ui.autocomplete_instance.blur(this);\n default:\n return this;\n }\n }\n else {\n if (typeof config == \"undefined\") config = {};\n jQuery.each(this, function () {\n var defaultConfig = {\n target: this\n };\n config = jQuery.extend({}, config, defaultConfig);\n ax5.ui.autocomplete_instance.bind(config);\n });\n }\n return this;\n }\n})();\n\n\n// todo : editable 지원.\n// 아이템 박스 안에서 제거 할때 디스플레이 정렬","// ax5.ui.autocomplete.tmpl\n(function () {\n var AUTOCOMPLETE = ax5.ui.autocomplete;\n var U = ax5.util;\n\n var optionGroup = function (columnKeys) {\n return `\n\n`;\n };\n\n var autocompleteDisplay = function (columnKeys) {\n return ` \n\n\n
\n
\n
\n {{#multiple}}{{#reset}}\n {{{.}}}\n {{/reset}}{{/multiple}}\n
\n
\n\n`;\n };\n\n var formSelect = function (columnKeys) {\n return `\n
\n`;\n };\n\n var formSelectOptions = function (columnKeys) {\n return `\n{{#selected}}\n
\n{{/selected}}\n`;\n };\n\n\n var options = function (columnKeys) {\n return `\n{{#waitOptions}}\n
\n
\n \n {{{lang.loading}}}\n \n
\n
\n{{/waitOptions}}\n{{^waitOptions}}\n {{#options}}\n {{^hide}}\n
\n
\n {{${columnKeys.optionText}}}\n
\n
\n {{/hide}}\n {{/options}}\n {{^options}}\n
\n
\n \n {{{lang.noOptions}}}\n \n
\n
\n {{/options}}\n{{/waitOptions}}\n`;\n };\n\n var label = function (columnKeys) {\n return `{{#selected}}
{{/selected}}`;\n };\n\n AUTOCOMPLETE.tmpl = {\n \"autocompleteDisplay\": autocompleteDisplay,\n \"formSelect\": formSelect,\n \"formSelectOptions\": formSelectOptions,\n \"optionGroup\": optionGroup,\n \"options\": options,\n \"label\": label,\n\n get: function (tmplName, data, columnKeys) {\n return ax5.mustache.render(AUTOCOMPLETE.tmpl[tmplName].call(this, columnKeys), data);\n }\n };\n})();"]}
\ No newline at end of file
diff --git a/karma.conf.js b/karma.conf.js
index d2594443..222a71a6 100644
--- a/karma.conf.js
+++ b/karma.conf.js
@@ -1,74 +1,60 @@
-// Karma configuration
-// Generated on Wed Sep 28 2016 23:32:27 GMT+0900 (KST)
-
-module.exports = function(config) {
- config.set({
-
- // base path that will be used to resolve all patterns (eg. files, exclude)
- basePath: '',
-
-
- // frameworks to use
- // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
- frameworks: ['mocha'],
-
-
- // list of files / patterns to load in the browser
- files: [
- 'node_modules/jquery/dist/jquery.min.js',
- 'node_modules/lodash/lodash.min.js',
- 'node_modules/should/should.js',
- 'dist/ax5ui.all.css',
- 'dist/ax5ui.all.min.js',
- 'src/**/test/test.*.js'
- ],
-
-
- // list of files to exclude
- exclude: [
- ],
-
-
- // preprocess matching files before serving them to the browser
- // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
- preprocessors: {
- },
-
-
- // test results reporter to use
- // possible values: 'dots', 'progress'
- // available reporters: https://npmjs.org/browse/keyword/karma-reporter
- reporters: ['progress'],
-
-
- // web server port
- port: 9876,
-
-
- // enable / disable colors in the output (reporters and logs)
- colors: true,
-
-
- // level of logging
- // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
- logLevel: config.LOG_INFO,
-
-
- // enable / disable watching file and executing tests whenever any file changes
- autoWatch: true,
-
-
- // start these browsers
- // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
- browsers: ['PhantomJS'],
-
+module.exports = function (config) {
+ var configuration = {
+ // base path that will be used to resolve all patterns (eg. files, exclude)
+ basePath: '',
+
+ // frameworks to use
+ // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
+ frameworks: ['mocha'],
+
+ // list of files / patterns to load in the browser
+ files: [
+ 'node_modules/jquery/dist/jquery.min.js',
+ 'node_modules/lodash/lodash.min.js',
+ 'node_modules/should/should.js',
+ 'dist/ax5ui.all.css',
+ 'dist/ax5ui.all.min.js',
+ 'src/ax5core/test/test.*.js',
+ 'src/ax5ui-autocomplete/test/test.*.js',
+ 'src/ax5ui-binder/test/test.*.js'
+ ],
+ // list of files to exclude
+ exclude: [],
+ // preprocess matching files before serving them to the browser
+ // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
+ preprocessors: {},
+ // test results reporter to use
+ // possible values: 'dots', 'progress'
+ // available reporters: https://npmjs.org/browse/keyword/karma-reporter
+ reporters: ['progress'],
+ // web server port
+ port: 9876,
+ // enable / disable colors in the output (reporters and logs)
+ colors: true,
+ // level of logging
+ // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
+ logLevel: config.LOG_INFO,
+ // enable / disable watching file and executing tests whenever any file changes
+ autoWatch: true,
+ // start these browsers
+ // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
+ //browsers: ['PhantomJS'],
+ browsers: ['Chrome'],
+ customLaunchers: {
+ Chrome_travis_ci: {
+ base: 'Chrome',
+ flags: ['--no-sandbox']
+ }
+ },
+ singleRun: true,
+ concurrency: Infinity
+ };
+
+ if (process.env.TRAVIS) {
+ configuration.browsers = ['PhantomJS'];
+ }
+
+ config.set(configuration);
+}
- // Continuous Integration mode
- // if true, Karma captures browsers, runs the tests and exits
- singleRun: false,
- // Concurrency level
- // how many browser should be started simultaneous
- concurrency: Infinity
- })
-}
diff --git a/src/ax5ui-calendar/test/test.calendar.html b/src/ax5ui-calendar/test/test.calendar.html
index 00602119..70cb6ad7 100644
--- a/src/ax5ui-calendar/test/test.calendar.html
+++ b/src/ax5ui-calendar/test/test.calendar.html
@@ -3,12 +3,13 @@
ax5.util calendar testing
-
-
-
-
-
-
+
+
+
+
+
+
+